Using this now since some 6 weeks and it is a lot better than using lots of B4XPages with layouts to show and alter all the settings I have.
I have some problems though altering the text sizes of the simple text item title (B4XFloatTextField) and the dialog buttons (OK and Cancel)
at the bottom. Ideally I would like to do this by adding Private variables to PreferencesDialog.bas as I did for the simple text value edit text (B4XFloatTextField.TextField).
Having trouble though doing the same for the 2 mentioned items.
Any suggestions how to do this?
RBS
I have some problems though altering the text sizes of the simple text item title (B4XFloatTextField) and the dialog buttons (OK and Cancel)
at the bottom. Ideally I would like to do this by adding Private variables to PreferencesDialog.bas as I did for the simple text value edit text (B4XFloatTextField.TextField).
B4X:
Sub Class_Globals
Private xui As XUI
Public mBase As B4XView
Private miTextFieldFontSize As Int = 14 '14 is the default as set by B4XDialog
Public Sub getTextFieldFontSize As Int
Return miTextFieldFontSize
End Sub
Public Sub setTextFieldFontSize(iFontSize As Int)
miTextFieldFontSize = iFontSize
End Sub
Public Sub ShowDialog (Data As Map, Yes As Object, Cancel As Object) As ResumableSub
If CustomListView1.Size = 0 Then
Dim LastTextField As B4XFloatTextField
For Each pi As B4XPrefItem In PrefItems
Dim pnl As B4XView = CreateLayouts(pi)
CustomListView1.Add (pnl, pi)
If pnl.GetView(0).Tag Is B4XFloatTextField Then
Dim tf As B4XFloatTextField = pnl.GetView(0).Tag
If LastTextField.IsInitialized Then
LastTextField.NextField = tf
End If
LastTextField = tf
tf.TextField.TextSize = miTextFieldFontSize 'If not set then this will be default 14
Having trouble though doing the same for the 2 mentioned items.
Any suggestions how to do this?
RBS