Helium314 / HeliBoard

Customizable and privacy-conscious open-source keyboard
Apache License 2.0
2.47k stars 97 forks source link

Make zero-width space and non-breaking space available #1195

Open novoid opened 2 weeks ago

novoid commented 2 weeks ago

I'd like to have at least two space variants available using HeliBoard:

https://en.wikipedia.org/wiki/Zero_width_space

https://en.wikipedia.org/wiki/Non-breaking_space

Is your feature request related to a problem? Please describe.

Zero-width spaces are getting more and more important with modern social networks using hashtags. However, they are not available to be used in HeliBoard yet.

For example, you could write "Today's #weather​s forecast is fine" where there is a zero-width space in-between "#weather" and "s" such that the reader is able to read "#weathers" but the hashtag ends with "#weather" without the ending "s".

There are also very good use-cases for non-breaking spaces if you work closely with Android plattform apps.

Describe the solution you'd like

I can think of several implementations of getting those characters exposed. The most obvious to me personally would be a long-press action on the space bar as there isn't any particular feature associated on my HeliBoard v2.2.

Maybe there are more https://en.wikipedia.org/wiki/Control_character that could be added here in future if there are valid use-cases. Maybe also custom keyboard shortcut combinations like Ctrl-c or ESC which are available in special keyboards. However, this might be far fetched and at least worth a separate feature request.

Describe alternatives you've considered (if any)

The only workaround to get, e.g., the zero-width space I can think of is:

  1. switching to a web browser
  2. visit https://en.wikipedia.org/wiki/Zero_width_space
  3. try to mark the opening parenthesis until the closing one which encapsulates the character at hand
  4. copy it to the clipboard
  5. switch back to the app you were using before
  6. paste the three characters (that look like two)
  7. remove the opening parenthesis and the closing parenthesis
  8. continue

Well, that's very tedious, especially on a mobile device.

Samscryption commented 2 weeks ago

All of the features you described are technically already in heliboard. You just need to add them in the advanced section. Zero width space could be like: { "label": "zwsp", "code": 8203, "type": "function" }, Ctrl: { "label": "Ctrl", "code": -1, "type": "function" }, Escape: { "label": "ESC", "code": -10017, "type": "function" },

As for non-breaking spaces there are different variations for it. Look for the unicode of the one you want and check the layouts section of the wiki on how to add them. The tips section describes how to use unicodes.

novoid commented 2 weeks ago

@Samscryption Oh, that's great to read!

However, I searched through the app, through the Github documentation and the web and could not find out how to access the "functional keys" I can see in the Customize section: "shift", "delete", "symbol_alpha", ... while typing.

How am I able to enable/reach those keys within HeliBoard?

I would have guessed this should be part of the great https://github.com/Helium314/HeliBoard/wiki/Hidden-functionality page but "functional keys" are not mentioned here as well.

Samscryption commented 2 weeks ago

@novoid It can be found near the bottom of the advanced menue above experimental 1000194130.jpg

novoid commented 2 weeks ago

@novoid Sorry, I was not clear enough: I found this "Customize functional key layouts" entry in the settings. However, I could not find how to type the keys which are defined in this config section. I don't see the defined keys anywhere. I guess I need to enable something I did not find so far in order to be able to access those keys.