-
-
Notifications
You must be signed in to change notification settings - Fork 2.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(display): Add modifiers widget #1556
base: main
Are you sure you want to change the base?
Conversation
aa3a31d
to
d19da71
Compare
I tested the current version on real hardware and it's working as intended. |
Thanks for testing! I'll publish it to mark as ready for review then. |
c15e40b
to
6207bad
Compare
bdd4f45
to
7b4e679
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A few thoughts. Thanks for working on this!
Does it make sense to keep each mod in a static location instead of shifting in from the right? |
Thanks for the review!
That was my initial plan but I didn't find a good way to implement it. The font is not monospaced so using a single label with placeholders like |
Hmm.... All painful points. I think to do it right will need to wait on https://docs.lvgl.io/master/layouts/flex.html?highlight=flexbox when we get the Zephyr 3.2 update in. Put each label as a child of a container object using flex layout... and it might just work? |
Thanks for pointing that out -- I'll definitely experiment with that when I get a chance. |
Where can I find directions for testing a pr like this on my hardware? |
Edit your |
Awesome! Thank you!
…On Sun, Feb 12, 2023, 3:32 PM Duccio ***@***.***> wrote:
I tested the current version on real hardware and it's working as intended.
Where can I find directions for testing a pr like this on my hardware?
Edit your west.yml like so:
https://github.com/duckyb/zmk-urchin/blob/b97f8c669eb78be670b0254605888b3322f76639/config/west.yml
—
Reply to this email directly, view it on GitHub
<#1556 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AEAGGGNVMAGU57YXRWW2AOTWXFJGNANCNFSM6AAAAAASM5GYGQ>
.
You are receiving this because you commented.Message ID:
***@***.***>
|
So, is it more complicated to bring in more than one of these? I've already got one PR for split encoders. Can this one be added, or is it one at a time? `FATAL ERROR: Malformed manifest file: /__w/Klein-zmk/Klein-zmk/config/west.yml
|
Make you own fork with all the changes you want and add it to |
Great feature, thank you. One thing to consider: Users may also want to display caps lock and caps word in the same widget. To accommodate that, you might need more than one character and separator after all. |
Is caps word a native modifier? If it isn't I don't think it would make sense to add it, however good point about caps lock, and also num lock could be an interesting addition. |
The current implementation uses shift under the hood, but hopefully #1485 will be merged soon which will implement caps word by toggling capslock. Despite that, I still think there is value in seeing whether capslock or capsword is enabled and I think it's better to have it all in one widget than to force the user to use one for modifiers and one for locks. |
Those two would indeed be very useful to have. Caps lock and other locks would ideally need #999 to get the status of the lock from the computer properly. Caps word is internal to the keyboard so that's easier but it doesn't expose an event to subscribe to or a function to check its status, as far as I can tell? I think it would be good if the basic modifier functionality gets merged first, then can be extended to these over time. When I get a chance to update this, my plan in order of priority is:
|
b9ea8b8
to
a452039
Compare
49cc132
to
9924e68
Compare
@caksoylar sorry for the ping. Are you planning to bringing this to finish line with the current capabilities? |
Hey, thanks for the reminder. I will rebase this in the next day or two and test locally, I think it should be working OK. I actually implemented the config option and ported to Zephyr 3.2 sometime ago. Still haven't checked out "Experiment with flex layouts in the new LVGL to fix positioning" item, I'll do that if I find some time. |
9924e68
to
20131e4
Compare
This is a barebones modifiers widget for showing the status of active modifiers on the bottom right of the status screen (thus it should not be enabled together with the WPM widget). It only tracks explicit modifiers (is showing implicit modifiers desirable?) but it seems to work well with sticky keys so it should be useful for tracking their state.
The widget can be enabled with
CONFIG_ZMK_WIDGET_MODS_STATUS=y
in your.conf
file. You can useCONFIG_ZMK_WIDGET_MODS_STATUS_CHARACTERS
to change the characters displayed for each modifier (one char each, default is"CSAG"
).Since Zephyr 3.2 has some LVGL changes affecting widgets I'd happy to revisit once it is merged in as well.This has been completed.Small demo: