Skip to content
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

Mods Customisations and Changes #33

Open
8 tasks
manna-harbour opened this issue Nov 25, 2021 · 6 comments
Open
8 tasks

Mods Customisations and Changes #33

manna-harbour opened this issue Nov 25, 2021 · 6 comments

Comments

@manna-harbour
Copy link
Owner

manna-harbour commented Nov 25, 2021

Support various mods customisations. E.g.

  • Ctrl / Gui swap for Mac for implementations lacking that feature
  • Reordering mods for user preference
  • Disabling mod-tap to prevent accidental mods (use mods on sub layers)
  • Enabling one shot mods on sub layers
  • Removing AltGr when not needed
  • Per-key tapping term
  • Per-key mod tap behaviour

Fix mods issues:

@manna-harbour manna-harbour changed the title Mods Customisations Mods Customisations and Changes Nov 30, 2021
@manna-harbour
Copy link
Owner Author

manna-harbour commented Feb 21, 2022

Ctrl / Gui swap for Mac might not be necessary as per keyboard mod remapping is supported in macOS: https://support.apple.com/en-az/guide/mac-help/mchlp1011/mac

Ctrl / Gui swap is also supported in QMK with magic keycodes.

An additional pre-swapped Mac clipboard option might be necessary.

@damirda
Copy link

damirda commented Dec 7, 2022

How to use magic keycode to achieve Ctrl/Gui swap? I was thinking something similar to how there is a layer lock now on double tap?

@manna-harbour
Copy link
Owner Author

How to use magic keycode to achieve Ctrl/Gui swap? I was thinking something similar to how there is a layer lock now on double tap?

@damirda It's not built-in at the moment, but you can use #85 to substitute a custom layer and add e.g. CG_TOGG. If you can't find somewhere to put it, it could be done as a key override or a tap dance.

@bijou-code
Copy link

bijou-code commented May 1, 2023

I'm new to the community (this weekend), and I don't know if there is a better place to put this (like in discussions), but I wanted to share my workaround for editing the home row mod order after being redirected from this reddit post and one of the discussions in this repo. This modification was done in my QMK installation since I prefer GASC to GACS (using colemak-dh), which isn't generally/easily OS configurable.

Notes:

  • I understand that it would be better to set up the babel repository and use tangled, but I have never used emacs before and the setup cost seemed high.
  • I performed these changes against the babel files so that all keyboards I create
  • I have not tried these modifications in ZMK, but it looks like the same commands should work if the sed strings are tweaked.
  • These commands rely on the default ordering of the home row mods, but can easily be modified to account for existing changes in the *layer_alternatives.h file.
  • These commands are not idempotent and may result in a different/ random state if executed multiple times without a reset.
  • These commands appear to be repeatable, and should be able to be re-applied after accepting a force-update from upstream.
# get to the qmk installation root
cd && qmk cd

# set each of the mods to a temporary value and repopulate with the mods in the preferred order
sed -e 's/LGUI/TMP0/g' -e 's/LALT/TMP1/g' -e 's/LCTL/TMP2/g' -e 's/LSFT/TMP3/g' \
-e 's/TMP0/LGUI/g' \
-e 's/TMP1/LALT/g' \
-e 's/TMP2/LSFT/g' \
-e 's/TMP3/LCTL/g' \
users/manna-harbour_miryoku/miryoku_babel/miryoku_layer_alternatives.h > miryoku_layer_alternatives_temp.h

# verify the results are what you expected. If you're in a clean git state, you can copy first and use git diff instead
diff users/manna-harbour_miryoku/miryoku_babel/miryoku_layer_alternatives.h  miryoku_layer_alternatives_temp.h | less

# move the results over top of the original
mv miryoku_layer_alternatives_temp.h users/manna-harbour_miryoku/miryoku_babel/miryoku_layer_alternatives.h

# if something goes wrong, revert to "master" version. You can use a specific commit or "HEAD" instead
git checkout master -- users/manna-harbour_miryoku/miryoku_babel/miryoku_layer_alternatives.h

@postylem
Copy link

postylem commented Dec 8, 2023

Ctrl / Gui swap for Mac might not be necessary as per keyboard mod remapping is supported in macOS: https://support.apple.com/en-az/guide/mac-help/mchlp1011/mac

An additional pre-swapped Mac clipboard option might be necessary.

I am using macOS, and I swapped control and command in macOS for my keyboard, as you suggested. But then I found that the clipboard commands no longer worked (because U_UNDO sent control+z rather than command+z, etc.). So I added the following, and now it works:

  • in manna-harbour_miryoku.h I defined a new clipboard option "MIRYOKU_CLIPBOARD_MACSWAP"

    Screenshot 2023-12-08 at 10 58 50
  • in custom_rules.mk I specified to use it:

    MIRYOKU_CLIPBOARD=MACSWAP

It took me a little while to figure out how to do that, so I'm posting it here in case it's helpful for others. Perhaps this clipboard option could be included by default? I would imagine other mac users want to do similarly.

rvogt79 pushed a commit to rvogt79/miryoku_zmk that referenced this issue Mar 11, 2024
matthewtodd added a commit to matthewtodd/qmk_firmware that referenced this issue May 5, 2024
@manna-harbour
Copy link
Owner Author

Consider:

  • Supporting right mods on bottom row: Right modifiers #262 (comment).
  • Option to remove HRM and add bottom row mods.
  • Moving layer lock to inner index column.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants