Skip to content

Azerty changes #42

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

Merged

Conversation

CHiPs44
Copy link
Contributor

@CHiPs44 CHiPs44 commented Nov 2, 2023

  • Correct bug for Oem5 to get </> instead of */µ (Oem7)
  • Add support for ¹/³ on ² and / for </> with AltGr / AltGr + Shift with CP437/CP850 support note
  • Add comments on other keys for possible AltGr / AltGr + Shift bindings with CP437/CP850 support note

NB:

  • These bindings come from the french keyboard variant I use on my Ubuntu 22.04 LTS.
  • I stopped adding bindings for these as I would like to know if it is desirable to have all of them.

@thejpster
Copy link
Member

thejpster commented Nov 2, 2023

I don't think CodePages are relevant here, because Rust has full Unicode support.

If you have a photograph showing these symbols on your keyboard, I'll happily add them. If they are not printed on the keycaps, but instead something your OS has decided to generate, then we'll have to think a bit more carefully about whether other OSes do the same thing.

@thejpster
Copy link
Member

Looking at https://en.wikipedia.org/wiki/AZERTY, I certainly agree that on an ISO keyboard Oem5 should produce < (and > when shifted).

@CHiPs44
Copy link
Contributor Author

CHiPs44 commented Nov 2, 2023

They don't appear on the keyboard, effectively, but are handy.

That's why I just added comments for now, as I was a little reluctant to implement them.

The only ones that are printed on a standard AZERTY keyboard are on E key, and belgian AZERTY variant has ³ on the ² top left key.

Another use of this is that it would delay the necessary management of dead keys.

For CP437/CP850, it is because Neotron is using 256 characters CP850 fonts by default and something related to PS/2 like this keyboard driver has now chances to be used in projects that deal with code pages.

@thejpster
Copy link
Member

For CP437/CP850, it is because Neotron is using 256 characters CP850 fonts by default

Right, but that's entirely Neotron OS's problem in mapping unicode to whatever the screen can display. We don't need to note it here.

As noted above, I can take a PR for the symbols printed on the keycaps. For symbols not on the keycaps, I'll need to see some documentation that the proposed symbols are what people "usually" get when they press that key combination. Ideally evidence that that is what Windows does.

@thejpster
Copy link
Member

Also, this may be a good time to split Azerty into French Azerty, Belgian Azerty and Dutch Azerty.

@CHiPs44
Copy link
Contributor Author

CHiPs44 commented Nov 2, 2023

This PR is now reduced to the bare minimum.

About using Windows as a reference about AZERTY keyboard layout, many french speaking people tend to consider it as terrible.

About variants, I was only aware of 3: French, Belgian and recent AFNOR French (which resembles to the variant I use on Linux but has a few keys moved or redefined and thus is not compatible with existing keyboards).

https://en.wikipedia.org/wiki/AZERTY seems to be exhaustive and authoritative.

@thejpster
Copy link
Member

And I thought QWERTY was confusing!

LGTM. Perhaps you could open an issue proposing additional key mappings, citing precedent (and I'm happy to accept Windows might not be a good precedent, although I've never used it outside of US or UK locales). We can discuss them there, and then do one PR that implements them?

@thejpster thejpster marked this pull request as ready for review November 3, 2023 08:28
@thejpster thejpster merged commit 9acb8ca into rust-embedded-community:main Nov 3, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants