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

[Docs] Improve Unicode documentation #8676

Merged
merged 10 commits into from
Jun 20, 2020

Conversation

vomindoraan
Copy link
Contributor

Description

This is one that I've been meaning to do for a while. This PR rewrites several sections of the Unicode feature doc, with the intent of making it easier to understand, promoting best practices and providing more examples for users.

Some minor reformatting was also done to the Macros feature doc.

Types of Changes

  • Core
  • Bugfix
  • New feature
  • Enhancement/optimization
  • Keyboard (addition or update)
  • Keymap/layout/userspace (addition or update)
  • Documentation

Checklist

  • My code follows the code style of this project.
  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.
  • I have read the CONTRIBUTING document.
  • I have added tests to cover my changes.
  • I have tested the changes and verified that they work and don't break anything (as well as I can manage).

@drashna drashna requested a review from a team April 5, 2020 05:16
@drashna drashna requested a review from noroadsleft April 5, 2020 05:16
@vomindoraan
Copy link
Contributor Author

Added a short summary of steps needed to get Unicode working to the start of the doc. This makes the doc more suitable for quick reference, and also makes it less likely that users will skip a step when setting up Unicode on their board (seems to happen somewhat frequently).

@vomindoraan
Copy link
Contributor Author

@ridingqwerty Have you had a chance to finish reviewing this yet?

@zvecr zvecr mentioned this pull request May 7, 2020
3 tasks
Copy link
Contributor

@ridingqwerty ridingqwerty left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me. Sorry for the delay getting back to this.

@vomindoraan
Copy link
Contributor Author

No worries, thanks a lot for reviewing!

docs/feature_macros.md Outdated Show resolved Hide resolved
Copy link
Member

@noroadsleft noroadsleft left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't like the numbers being in the section headers of docs/feature_unicode.md (## 1. Methods..., ### 1.1. Basic Unicode..., etc.), but this looks good to me otherwise.

@vomindoraan
Copy link
Contributor Author

I had tried several different markup variations for the section headers before ending up with the current one. I think it's the clearest in terms of showing the three main steps that need to be taken to enable Unicode input on a board, as well as giving an overview of the three different methods supported under the first step.

@drashna
Copy link
Member

drashna commented May 18, 2020

If you haven't seen it qmk docs will start a doc server rendering it how it shows in docs.qmk.fm.

If you need to fine tune formatting/markdown, that is probably the best way to do so.

@vomindoraan
Copy link
Contributor Author

vomindoraan commented May 18, 2020

Thanks, yeah, I used the doc server to test and fine-tune these changes.

@vomindoraan
Copy link
Contributor Author

Is there anything else I need to add/update to help get this merged?

@drashna drashna requested a review from noroadsleft May 25, 2020 04:09
@drashna
Copy link
Member

drashna commented May 25, 2020

Sorry, no, shouldn't be anything else. Though, I would like @noroadsleft to give it a check at least, since he's the resident wordsmith.

Comment on lines -211 to +243
send_unicode_hex_string("0028 30CE 0CA0 75CA 0CA0 0029 30CE 5F61 253B 2501 253B");
```
## Additional Language Support

An easy way to convert your Unicode string to this format is by using [this site](https://r12a.github.io/app-conversion/), and taking the result in the "Hex/UTF-32" section.
In `quantum/keymap_extras`, you'll see various language files — these work the same way as the ones for alternative layouts such as Colemak or BÉPO. When you include one of these language headers, you gain access to keycodes specific to that language / national layout. Such keycodes are defined by a 2-letter country/language code, followed by an underscore and a 4-letter abbreviation of the character to which the key corresponds. For example, including `keymap_french.h` and using `FR_UGRV` in your keymap will output `ù` when typed on a system with a native French AZERTY layout.

## Additional Language Support
If the primary system layout you use on your machine is different from US ANSI, using these language-specific keycodes can help your QMK keymaps better match what will actually be output on the screen. However, keep in mind that these keycodes are just aliases for the corresponding default US keycodes under the hood, and that the HID protocol used by keyboards is itself inherently based on US ANSI.
Copy link
Member

@noroadsleft noroadsleft May 25, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm struggling to offer good advice for this section. I actually followed your doc to enable Unicode Map on my KC60 (using WinCompose), but I haven't yet worked out the magic solution to get this to work fully, because I mainly use English Dvorak at the OS level, and something about that seems to break the feature. It wasn't clear to me from this that it only works with US ANSI arrangement.

Enabling this to work with other keys in unicode_input_start() would be a good improvement for the future, but that's out of scope for this PR.

@vomindoraan
Copy link
Contributor Author

Updated to latest master after #8770 was merged.

@Erovia Erovia merged commit 0278197 into qmk:master Jun 20, 2020
jakobaa pushed a commit to jakobaa/qmk_firmware that referenced this pull request Jul 7, 2020
BorisTestov pushed a commit to BorisTestov/qmk_firmware that referenced this pull request May 23, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants