
Code: Select all
LoadFont(0, "Verdana", 10 )
LoadFont(1, "Verdana", 10 , #PB_Font_Bold )
Enumeration FormWindow
#Window_0
EndEnumeration
Enumeration FormGadget
#Container_1
#Container_2
#Container_3
#ExplorerList_0
#Calendar_0
#Button_0
#Button_1
#Button_2
#Button_3
EndEnumeration
Procedure OpenWindow_0(x = 0, y = 0, width = 600, height = 400)
OpenWindow(#Window_0, x, y, width, height, "", #PB_Window_SystemMenu | #PB_Window_MinimizeGadget | #PB_Window_MaximizeGadget | #PB_Window_ScreenCentered)
SetWindowColor(#Window_0, RGB(239,235,219))
ContainerGadget(#Container_1, 75, 114, 374, 219, #PB_Container_Flat)
SetGadgetColor(#Container_1, #PB_Gadget_BackColor,RGB(255,255,255))
ButtonGadget(#Button_0, 98, 77, 197, 102, "Tab 1 's Button")
CloseGadgetList()
ContainerGadget(#Container_2, 75, 114, 374, 219, #PB_Container_Flat)
SetGadgetColor(#Container_2, #PB_Gadget_BackColor,RGB(255,255,100))
CalendarGadget(#Calendar_0, 23, 20, 332, 176, 0)
CloseGadgetList()
HideGadget(#Container_2,1)
ContainerGadget(#Container_3, 75, 114, 374, 219, #PB_Container_Flat)
SetGadgetColor(#Container_3, #PB_Gadget_BackColor,RGB(240,240,200))
ExplorerListGadget(#ExplorerList_0, 17, 20, 331, 187, "")
CloseGadgetList()
HideGadget(#Container_3,1)
ButtonGadget(#Button_1, 87, 88, 93, 28, "Tab 1")
ButtonGadget(#Button_2, 179, 92, 93, 24, "Calendar")
ButtonGadget(#Button_3, 271, 92, 93, 24, "Files")
SetGadgetFont(#Button_0, FontID(0))
SetGadgetFont(#Button_1, FontID(1)) ;--------- Set Tab 1 Button As Default
SetGadgetFont(#Button_2, FontID(0))
SetGadgetFont(#Button_3, FontID(0))
EndProcedure
Procedure Tabs()
ButtonGadget(#Button_1, 87, 92, 93, 24, "Tab 1")
ButtonGadget(#Button_2, 179, 92, 93, 24, "Calendar")
ButtonGadget(#Button_3, 271, 92, 93, 24, "Files")
SetGadgetFont(#Button_1, FontID(0)) : SetGadgetFont(#Button_2, FontID(0)) : SetGadgetFont(#Button_3, FontID(0))
HideGadget(#Container_1,1) : HideGadget(#Container_2,1) : HideGadget(#Container_3,1)
EndProcedure
Procedure Window_0_Events(event)
Select event
Case #PB_Event_CloseWindow
ProcedureReturn #False
Case #PB_Event_Gadget
Select EventGadget()
Case #Button_1
Tabs()
ButtonGadget(#Button_1, 87, 88, 93, 28, "Tab 1")
SetGadgetFont(#Button_1, FontID(1))
HideGadget(#Container_1,0)
Case #Button_2
Tabs()
ButtonGadget(#Button_2, 179, 88, 93, 28, "Calendar")
SetGadgetFont(#Button_2, FontID(1))
HideGadget(#Container_2,0)
Case #Button_3
Tabs()
ButtonGadget(#Button_3, 271, 88, 93, 28, "Files")
SetGadgetFont(#Button_3, FontID(1))
HideGadget(#Container_3,0)
EndSelect
EndSelect
ProcedureReturn #True
EndProcedure
OpenWindow_0()
Repeat : event = WaitWindowEvent() : Until Window_0_Events(event) = #False
End