mirror of
https://github.com/Helium314/HeliBoard.git
synced 2025-04-26 09:36:50 +00:00
don't align keys off-center if hints are disabled, fixes #155
This commit is contained in:
parent
3d0e590852
commit
bca519efe4
1 changed files with 3 additions and 2 deletions
|
@ -412,8 +412,9 @@ public class KeyboardView extends View {
|
|||
labelBaseline = centerY + labelCharHeight / 2.0f;
|
||||
|
||||
// Horizontal label text alignment
|
||||
if (key.isAlignLabelOffCenter()) {
|
||||
// The label is placed off center of the key. Used mainly on "phone number" layout.
|
||||
if (key.isAlignLabelOffCenter() && mShowsHints) {
|
||||
// The label is placed off center of the key. Currently used only on "phone number" layout
|
||||
// to have letter hints shown nicely. We don't want to align it off center if hints are off.
|
||||
labelX = centerX + params.mLabelOffCenterRatio * labelCharWidth;
|
||||
paint.setTextAlign(Align.LEFT);
|
||||
} else {
|
||||
|
|
Loading…
Add table
Reference in a new issue