klaus Expert Licensed User Longtime User Oct 31, 2014 #1 Is it possible to set the TextSize or FontSize in the code. In the Designer there is a Font / Size property, but I haven't found how to change in the code.
Is it possible to set the TextSize or FontSize in the code. In the Designer there is a Font / Size property, but I haven't found how to change in the code.
Erel B4X founder Staff member Licensed User Longtime User Oct 31, 2014 #2 The text size is part of the Font in B4i (modeled after iOS API). Code: Copy lbl.Font = Font.CreateNew(20) 'default font lbl.Font = Font.CreateNew2(lbl.Font.Name, 20) 'keep current font if it was changed with the designer Upvote 0
The text size is part of the Font in B4i (modeled after iOS API). Code: Copy lbl.Font = Font.CreateNew(20) 'default font lbl.Font = Font.CreateNew2(lbl.Font.Name, 20) 'keep current font if it was changed with the designer
klaus Expert Licensed User Longtime User Nov 16, 2014 #3 How can we get the current font size from a view? In the previous post we can change the font size knowing the value. But I would like to multply the current size by a scale factor. Upvote 0
How can we get the current font size from a view? In the previous post we can change the font size knowing the value. But I would like to multply the current size by a scale factor.
stevel05 Expert Licensed User Longtime User Nov 16, 2014 #4 pointSize is not (yet) exposed in the Font Object, we can use the NativeObject to get it. Code: Copy Dim FNo As NativeObject = Label1.Font Log(FNo.GetField("pointSize")) Upvote 0
pointSize is not (yet) exposed in the Font Object, we can use the NativeObject to get it. Code: Copy Dim FNo As NativeObject = Label1.Font Log(FNo.GetField("pointSize"))
Erel B4X founder Staff member Licensed User Longtime User Nov 16, 2014 #5 Font.Size property will be added. Upvote 0