Sub Class_Globals
Private Root As B4XView
Private xui As XUI
Private Pane1 As Pane
End Sub
'This event will be called once, before the page becomes visible.
Private Sub B4XPage_Created (Root1 As B4XView)
Root = Root1
Root.LoadLayout("MainPage")
Dim pn As Pane
pn.Initialize("")
pn.LoadLayout("ly1")
Dim Thumb As ImageView=pn.GetNode(0)
Thumb.SetImage(xui.LoadBitmap(File.DirAssets,"girl.jpg"))
'Thumb.SetImage(xui.LoadBitmapResize(File.DirAssets,"girl.jpg",400,400,True)) 'void
Thumb.Left=50 'void
Thumb.Top=50 'void
Thumb.SetSize(400,400) 'void
pn.GetNode(0).PrefWidth=400 'void
pn.GetNode(0).PrefHeight=400 'void
Thumb.Width=400 'void
Thumb.Height=400 'void
CSSUtils.SetStyleProperty(Thumb,"-fx-pref-width","400") 'void
CSSUtils.SetStyleProperty(Thumb,"-fx-pref-height","400") 'void
Pane1.AddNode(pn,0,0,400,400)
End Sub