maihannijat/AndroidKeyboard

Latin Shift Keys Problem

bha2020 opened this issue · 6 comments

If I increase number of keys in pashto_latin.xml keyboard as well as in pashto_latin_shift.xml then number of keys visible in pashto_latin_shift keyboard is only 10 and other keys gets hide.because width of the keys gets increase in pashto_latin_shift.
I detected one thing that if number of keys increase in pashto_latin_shift then width of the keys increases automatically.But not getting from where this width gets increase.

please help

The width of the keys is in the XML layouts. Change the width when you are adding or removing the key.

/app/src/main/res/xml/pashto.xml

android:keyWidth="10%p"

Thank you for your reply

files.zip

I changed width also but if i place 12 keys in a row for pashto_latin it works but 12 keys for pashto_latin_shift it not work.
and i want same key width and height for pashto_latin and pashto_latin_shift .

mainly problem occurs in capslock row .delete char symbol gets hide if i included 12 keys in that row
i increased the width of shift and unshift key also.
After debugging the code one thing which i got is key.width in onDraw method.
when keyboard is pashto_latin then key.width is 66 and in pashto_latin_shift characters width increases to 80.
In pashto_latin android:keyHeight="50" and pashto_latin_shift android:keyHeight="55" then key width remains same but height of keyborad increases

pashto_latin.xml
pashto_latin_shift.xml

please find attached files.zip

pashto_latin_shift

Changing the width of the following allows 12 keys in a row. Please see attached the screenshot.
android:keyWidth="8%p"

I used the file provided by you and only changed the width.

onDraw method draws on the top of keys.

Note: The one key in the screenshot doesn't appear because my phone doesn't support it.

android:keyWidth="8%p"
Yes I have donre these changes also. But Still there is a problem
Im attaching some sceenshots .
Backspace key is still invisible in pashto_latin_shift
screenshot_2018-01-18-10-58-57p

and same is woking fine with pashto_latin
screenshot_2018-01-18-11-01-24

attached xml files also
files.zip

In the first screenshot, the width of shift key seems increased, however, in both files it is 15%. Decrease the width of the shift key. Use different XML files for different screen sizes if it appears differently.

This seems a glitch as I don't see this happening on my device.

This happens for pashto_latin_shift only .pashto_latin is working fine
I changed key shift key width to ="10%p" for pashto_latin_shft still the last button from 3rd row i.e delete character symbol is not visible