huydq92 / hackerskeyboard

Automatically exported from code.google.com/p/hackerskeyboard
0 stars 0 forks source link

Add ZWNJ to Persian 4-row layout #215

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
Here I tried to add ZWNJ (ZERO WIDTH NON-JOINER) character as a pop-up 
character for space key. I hope it doesn't break the rest of space key features.

There is something inside quotations in the second line I added, but since the 
character is invisible, you (and me!) can't see it by eye. This ZWNJ character 
(Unicode: U+200C) has almost the same usage in Persian as hyphen in English, 
and in a normal keyboard is typed by pressing Shift+Space.

Original issue reported on code.google.com by amp...@gmail.com on 27 Mar 2012 at 2:54

Attachments:

GoogleCodeExporter commented 9 years ago
Maybe it's a better idea to code this character with its Unicode number: \u200c

Original comment by amp...@gmail.com on 8 Apr 2012 at 3:37

GoogleCodeExporter commented 9 years ago
Adding popup characters to "space" is probably not a good idea, it breaks 
auto-repeat for that key and may also interfere with language selection via 
sliding the space bar.

I've tried adding it as an alternate on "ک", but this isn't very user friendly 
since the character appears to be invisible, and it just shows up as an empty 
area in the popup keyboard.

How is this key usually labeled on physical keyboards?

Original comment by Klaus.We...@gmail.com on 14 Jun 2012 at 7:48

GoogleCodeExporter commented 9 years ago

Original comment by Klaus.We...@gmail.com on 14 Jun 2012 at 7:49

GoogleCodeExporter commented 9 years ago
Issue 217 has been merged into this issue.

Original comment by Klaus.We...@gmail.com on 14 Jun 2012 at 7:49

GoogleCodeExporter commented 9 years ago
Thanks for trying my suggestion. Regarding your question, this character is not 
labeled on physical keyboards. But if you want to name it, and if it's possible 
to write something on the soft button other than the (invisible) character 
itself, let's label it as 
فاصلهٔ مجازی
(meaning "virtual space" as it is usually called in Persian) or you just name 
it "ZWNJ"

Original comment by amp...@gmail.com on 14 Jun 2012 at 10:06

GoogleCodeExporter commented 9 years ago
Actually, the simplest version may be to just map Shift-Space to ZWNJ directly, 
instead of via long-press. This may need some larger changes since the current 
setup assumes that the special keys don't have separate shifted mappings, but 
that should be doable.

Original comment by Klaus.We...@gmail.com on 15 Jun 2012 at 5:51

GoogleCodeExporter commented 9 years ago
I've experimented a bit, the Shift-Space mapping seems to work fine for the 
5-row mode. I assume the expected effect is that it breaks ligatures without 
inserting extra space?

Unfortunately the 4-row mode doesn't have a Shift key, so that needs a 
different method. Which key do you think would be useful to put this on? One 
that doesn't currently have alternates and is near the space bar may be 
easiest, maybe "پ"?

Adding a label that's different from the inserted text is currently not 
directly supported, though an icon could work. فاصلهٔ مجازی would be 
way too long though, that would be hard to fit in a key space. But the label 
can wait, especially if physical keyboards don't label the key.

Do you happen to know if the Arabic layout also uses ZWNJ?

Original comment by Klaus.We...@gmail.com on 15 Jun 2012 at 6:19

GoogleCodeExporter commented 9 years ago
For 5-row keyboard, mapping Shift+Space to ZWNJ is a very good idea :)

From your description, it seems that ZWNJ is working fine. Which version of 
Android did you tested it on? I ask because I remember Android 2.3 had 
rendering problems with ZWNJ. Could you please test that also?

I thought about where to put ZWNJ in the 4-row layout. I found an app called 
"MultiLing Keyboard" from Honso that has ZWNJ support. I didn't test the app, 
but according to this page (http://goo.gl/0iMJO) the ZWNJ is put on the 
punctuation keys. I think this is a good idea and we can put ZWNJ on the 
punctuation key as well.

Original comment by amp...@gmail.com on 15 Jun 2012 at 8:23

GoogleCodeExporter commented 9 years ago
Although the usage of ZWNJ is of course relevant in Arabic typography, I 
couldn't find any Arabic layout on Google image search that has it written 
somewhere on the layout map. Better to ask from a native. I don't have access 
to any!

I checked the Wikipedia page: 
http://en.wikipedia.org/wiki/Zero-width_non-joiner There it seems there is a 
symbol for ZWNJ that I never knew! Let's use this symbol or a new symbol made 
from ZWNJ.

Original comment by amp...@gmail.com on 15 Jun 2012 at 8:43

GoogleCodeExporter commented 9 years ago
I made this simple ZWNJ.svg as a starting point. I have no strong preference in 
using either of them. The fact is that, ZWNJ is more known (at least among 
techies) but it is longer and is not really a "symbol". The symbol in 
Wikipedia, on the other hand, is very good and nice, but it's not so well-known.

Original comment by amp...@gmail.com on 15 Jun 2012 at 9:09

Attachments:

GoogleCodeExporter commented 9 years ago
Sorry about the delay, I've now built a release with ZWNJ added to shift-Space 
(5-row) and "پ" long-press (4-row). Didn't get a chance to look into the icon 
yet, it'll probably show a blank space for now.

Can you try 1.34rc2 (or later) from 
https://code.google.com/p/hackerskeyboard/downloads/list and let me know if the 
functionality is as expected? If it works, I'll look into adding the icon so 
that it looks more discoverable.

Revision: bf6b4942317b

Original comment by Klaus.We...@gmail.com on 4 Jul 2012 at 5:29

GoogleCodeExporter commented 9 years ago
[bulk bug update]

The changes from the 1.34rcX prerelease series are included in version 1.37 as 
published on the Play Store, and this bug should be fixed. If it's still not 
working for you, please reopen or file a new bug. Thanks to everyone who helped 
with finding bugs and testing!

Original comment by Klaus.We...@gmail.com on 26 Dec 2013 at 7:12