Git Product home page Git Product logo

Comments (7)

benblazak avatar benblazak commented on July 19, 2024

I think the way to do this would be to make num-lock a layer mask key (i.e. a layer key that only switches the layers of the specific keys it's dealing with; there's not an example in the code right now, but I can write the function in a bit; a numpad was one of the primary things I was thinking of when I implemented the functionality).

  • Where would you like the numpad to be? Unless I implement it as a standard layer key, it'll take modifying the new num-lock function (in key-functions.c) to move it, which won't be too hard, but I may as well put it where you like from the beginning :) .
  • Would you like the key to send the num-lock keycode as well as switch the keys? It would be possible to make a numpad that doesn't send any modifiers, by using the keycodes for the numbers from the main keyboard and symbols from the keypad, if that were desirable.
  • Do you think anything extra should be included? As in, A-F for hex numbers, or 'x', 'b', 'o', or such for programming (if so, where, in relation to 0-9?)?

from ergodox-firmware.

doxkb avatar doxkb commented on July 19, 2024

Yes, that's what I was thinking. Only the affected keys would change compared to the default layer.

Position:
7 8 9
u i o
j k l
m
and the operators on the right side.

I think that the num-lock will activate the layer. That way, we can use the numpad keycode and they are always in "number mode".

I don't think we should put the hex numbers on that layer but if someone needs them, he we probably be able to modify the layout and recompile the firmware.

from ergodox-firmware.

benblazak avatar benblazak commented on July 19, 2024

in 'dev'

from ergodox-firmware.

doxkb avatar doxkb commented on July 19, 2024

It's working great when I hold the fn+left shift but it should also work when I just put the num lock ON. I placed a num lock key on the fn layer and when I lock it, the keypad layer isn't activated.

from ergodox-firmware.

benblazak avatar benblazak commented on July 19, 2024

sorry.. i had implemented it as a press|release function, where press activated it (always), and release deactivated it (always), which wasn't the right thing to do.

i'm not sure if i should call the functions (especially the function names) stable, but i'll be sure to keep the functionality around in some form (unless it's not useful to you and i end up not liking it either) -- there are now 3 numpad related functions:

  • kbfun_layermask_numpad_toggle()
  • kbfun_layermask_numpad_on()
  • kbfun_layermask_numpad_off()

numpad "modifier" style keys (on when pressed, off when released) should have ...on() assigned to their press function, and ...off() assigned to their release function. numpad "lock" style keys (toggle when pressed) should have ...toggle() assigned to their press function, and NULL assigned to their release function. i put it in the 'dev' qwerty layout file (though probably not where you want it) if you wish to see.

thanks for letting me know :) . please let me know how this revision works out too.

from ergodox-firmware.

doxkb avatar doxkb commented on July 19, 2024

I forgot to get back to you on this but everything is working fine. Thanks!

from ergodox-firmware.

benblazak avatar benblazak commented on July 19, 2024

:D

from ergodox-firmware.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.