Has anyone made a color gradient for the background of the page / pages?
How to do it?
I also have a problem with understanding how to build new pages in the application:
The first "Start" page is created like this (in the class module: B4XMainPage):
The second page is already being created (in the code module):
Which way is better? When to use class modules to add more pages in the application, and when to use regular code modules?
And the question about the background gradient. In B4i Visual Designer there are no such settings as in B4A:
GradientDrawable -> Orientation, First Color and Second Color
I found an example on the forum, but it works only on objects already on the page, but the background of the page itself does not apply.
And it only works in the "Main" regular and basic code module (in Private Sub Application_Start)
How to do it?
I also have a problem with understanding how to build new pages in the application:
The first "Start" page is created like this (in the class module: B4XMainPage):
First page "Start":
Private Sub B4XPage_Created (Root1 As B4XView)
Root = Root1
Root.LoadLayout("StartPage")
B4XPages.SetTitle(Me, "Start")
End Sub
The second page is already being created (in the code module):
Second page "Setings":
Public Sub Show
If pg.IsInitialized = False Then
pg.Initialize("pg")
pg.RootPanel.LoadLayout("Setings")
pg.HideBackButton = True '<-- don't want to allow the user to return to the login screen
End If
Main.NavControl.ShowPage(pg)
End Sub
Which way is better? When to use class modules to add more pages in the application, and when to use regular code modules?
And the question about the background gradient. In B4i Visual Designer there are no such settings as in B4A:
GradientDrawable -> Orientation, First Color and Second Color
I found an example on the forum, but it works only on objects already on the page, but the background of the page itself does not apply.
And it only works in the "Main" regular and basic code module (in Private Sub Application_Start)