Page 1 of 1

Input Text field auto Resize

Posted: Sun Jul 27, 2014 2:41 pm
by donizeti.borges
Hi

I am working in a mobile project that will run on Iphone and Ipad using LC independence resizing + MobGui controls .

On Iphone the font size works fine in Input text, but when I try to run on Ipad the control resize in terms of width and height but the font keep small.

I tried to mark Auto Fit Property, but without success.

Re: Input Text field auto Resize

Posted: Sun Jul 27, 2014 10:29 pm
by Mark
Hi,

Change the textSize of the field to a bigger value or change the textSize of the text. You can do this in the IDE or by script:

Code: Select all

set the textSize of fld x to 24
set the textSize of char 1 to -1 of fld x to 36
Kind regards,

Mark

Re: Input Text field auto Resize

Posted: Tue Jul 29, 2014 3:39 am
by donizeti.borges
Hi Mark

Thank you for the answer! but I think that isn't the solution for my issue.

Mobgui use a native text control to implement input text and the way to change the size is using mobilecontrolset.

The LC independence resolution resize automatically all controls of my card including fonts too, just mobgui text input was not resized.

Kind regards,

Donizeti

Re: Input Text field auto Resize

Posted: Wed Jul 30, 2014 8:29 am
by Mark
Hi Donizeti,

If you can find out which ID MobGUI uses for the text input control, you can use the following syntax to change the text size:

Code: Select all

mobileControlSet gMobileControlID,"textSize",36
More useful is probably the autoFit property:

Code: Select all

mobileControlSet gMobileControlID,"autoFit",true
mobileControlSet gMobileControlID,"minimumFontSize",10
but note that this works on iOS only.

Kind regards,

Mark

Re: Input Text field auto Resize

Posted: Wed Jul 30, 2014 7:48 pm
by splash21
Hi Donizeti, I'm abroad until 9th August. If you follow Mark's advice, everything should work 8)