I noticed a curious (and annoying) detail: in a NavigationBar created using the sampled BuildNavigationBar :
I added 2 menu items using visibility=true
The result on my browser is this:
As you can see the title is centered. If I reduce just a little the browser's window the result is this:
Now the title is left aligned. There is no reason to save right space. At the opposite when the browser's window is larger should be better to left align the title to have more space for menu items. Don't you agree? Is there a workaround to force title to be left aligned?
thank you
Roberto
B4X:
Sub BuildNavigationBar(page As ABMPage, Title As String, logo As String, ActiveTopReturnName As String, ActiveSideReturnName As String, ActiveSideSubReturnName As String) 'ignore
' we have to make an ABMImage from our logo url
Dim sbtopimg As ABMImage
sbtopimg.Initialize(page, "sbtopimg", logo, 1)
sbtopimg.SetFixedSize(236, 49)
' page.NavigationBar.Initialize(page, "nav1", ABM.SIDEBAR_MANUAL_HIDEMEDIUMSMALL, Title, True, True, 330, 48, sbtopimg, ABM.COLLAPSE_ACCORDION, "nav1theme")
' page.NavigationBar.Initialize(page, "nav1", ABM.SIDEBAR_AUTO, Title, True, True, 330, 54, sbtopimg, ABM.COLLAPSE_ACCORDION, "nav1theme")
page.NavigationBar.Initialize(page, "nav1", ABM.SIDEBAR_MANUAL_ALWAYSHIDE, Title, True, True, 330, 54, sbtopimg, ABM.COLLAPSE_ACCORDION, "nav1theme")
page.NavigationBar.TopBarDropDownConstrainWidth = False
page.NavigationBar.ActiveTopReturnName = ActiveTopReturnName
page.NavigationBar.ActiveSideReturnName = ActiveSideReturnName
page.NavigationBar.ActiveSideSubReturnName = ActiveSideSubReturnName
' you must add at least ONE dummy item if you want to add items to the topbar in ConnectNaviagationBar
page.NavigationBar.AddTopItem("DUMMY", "{NBSP}", "", "", False)
' you must add at least ONE dummy item if you want to add items to the sidebar
page.NavigationBar.AddSideBarItem("DUMMY", "{NBSP}", "", "")
End Sub
The result on my browser is this:
As you can see the title is centered. If I reduce just a little the browser's window the result is this:
Now the title is left aligned. There is no reason to save right space. At the opposite when the browser's window is larger should be better to left align the title to have more space for menu items. Don't you agree? Is there a workaround to force title to be left aligned?
thank you
Roberto