Is there a possibility to automatically resize the text of a button? make it “responsive” to the size of the button? Thank you
How you change button size.
The problem is that the key is set in percentage to fit all the screens while the text has a fixed depth, so I was looking for a method or to automatically wrap the text or resize it
I haven’t found a way to dynamically resize the text size yet. Hopefully Thunkable can add a percentage property like width/height.
Just to be clear you can dynamically resize the text size by setting the FontSize property of the button using the
'from Button set FontSize to' block. What we don’t currently have is a way to set that FontSize to a percentage or to get the size of the button, which would allow you to compute the FontSize to match the button size.
One workaround will be to set the button fontSize to the percentage of the button Width or Height. On screen initialized,
from Button set FontSzie to
from Button get Width * percentage.
Use the block that you tell me that I set a size in any case of the font, the problem is that this device to device failure and between ios and android, you should be able to calculate, starting from a certain size, the optimal size for the screen in use, is there a block that will return the screen resolution in use? if we think that a trivial equivalence solves our problem
There is no beautiful block for determining the screen resolution, but there is an example of obtaining information using a web service on the scrSystemInfo screen.