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

A way to specify what layout your chordes are using #1329

Open
Kommynct opened this issue Nov 5, 2024 Discussed in #1328 · 3 comments
Open

A way to specify what layout your chordes are using #1329

Kommynct opened this issue Nov 5, 2024 Discussed in #1328 · 3 comments
Labels
PRs welcome jtroo has no plans to work on this at present, but PRs are welcome

Comments

@Kommynct
Copy link

Kommynct commented Nov 5, 2024

Discussed in #1328

Originally posted by Kommynct November 4, 2024
I currently have an actual dvorak keyboard, but sometimes use other keyboards, I have two dedicated config files for that dvorak keyboard and all other keyboards, but want to use the same list of chordes

currently, the chordes on the qwerty keyboard use the qwerty layout, and the chordes on the dvorak keyboard use the dvorak layout, i'd like a way to merge these two into one, that way i don't have to maintain two separate lists of chords, any ideas?

config files here:

https://gitlab.com/that1communist/dotfiles/-/blob/master/etc/nixos/main.kbd
https://gitlab.com/that1communist/dotfiles/-/blob/master/etc/nixos/ergodox.kbd
https://gitlab.com/that1communist/dotfiles/-/blob/master/etc/nixos/chords.kbd

It'd be nice if there was a defcfg option that specifies what layout you're using the chordes in, that way you could have many files like this, and many different keyboards with different layouts that just work automatically.

@jtroo
Copy link
Owner

jtroo commented Nov 5, 2024

You can probably use deflocalkeys for this to redefine defsrc symbols.

@jtroo jtroo added the PRs welcome jtroo has no plans to work on this at present, but PRs are welcome label Nov 5, 2024
@Kommynct
Copy link
Author

Kommynct commented Nov 5, 2024

Can you give me a simple example? I'm not really understanding how that applies here

@jtroo
Copy link
Owner

jtroo commented Nov 5, 2024

Thinking about it some more you can't actually redefine the defsrc symbols, because then outputs would be broken.

But you can redefine new input symbols that are defined differently for qwerty and dvorak. Then define everything according to the new inputs.

Example for dvorak left hand home row: simulator.

(defsrc)
(deflocalkeys-linux
  aa 30
  ss 24
  dd 18
  ff 22
)
(deflayermap (base)
  aa a
  ss o
  dd e
  ff u
)

Example for qwerty left hand home row: simulator

(defsrc)
(deflocalkeys-linux
  aa 30
  ss 31
  dd 32
  ff 33
)
(deflayermap (base)
  aa a
  ss o
  dd e
  ff u
)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
PRs welcome jtroo has no plans to work on this at present, but PRs are welcome
Projects
None yet
Development

No branches or pull requests

2 participants