2 * Acess GUI (AxWin) Version 2
3 * By John Hodge (thePowersGang)
8 int giInterface_Width = 0;
9 tElement *gpInterface_Sidebar;
10 tElement *gpInterface_MainArea;
11 tElement *gpInterface_HeaderBar;
12 tElement *gpInterface_TabBar;
13 tElement *gpInterface_TabContent;
16 void Interface_Init(void)
20 giInterface_Width = giScreenWidth/16;
22 WM_SetFlags(NULL, ELEFLAG_HORIZONTAL);
25 gpInterface_Sidebar = WM_CreateElement(NULL, ELETYPE_TOOLBAR, ELEFLAG_VERTICAL);
26 WM_SetSize( gpInterface_Sidebar, giInterface_Width );
27 // Create Main Area and regions within
28 gpInterface_MainArea = WM_CreateElement(NULL, ELETYPE_BOX, ELEFLAG_VERTICAL);
29 gpInterface_HeaderBar = WM_CreateElement(gpInterface_MainArea, ELETYPE_BOX, ELEFLAG_HORIZONTAL);
30 gpInterface_TabBar = WM_CreateElement(gpInterface_MainArea, ELETYPE_TABBAR, 0);
31 gpInterface_TabContent = WM_CreateElement(gpInterface_MainArea, ELETYPE_BOX, 0);
34 btn = WM_CreateElement(gpInterface_Sidebar, ELETYPE_BUTTON, 0);
35 WM_SetSize(btn, giInterface_Width);
36 //text = WM_CreateElement(btn, ELETYPE_IMAGE, ELEFLAG_SCALE);
37 //WM_SetText(text, "asset://LogoSmall.png");
38 text = WM_CreateElement(btn, ELETYPE_TEXT, 0);
39 WM_SetText(text, "Acess");
41 // Plain <hr/> style spacer
42 WM_CreateElement(gpInterface_Sidebar, ELETYPE_SPACER, 0);
44 // Create spacing gap (aligns the rest to the bottom/right)
45 WM_CreateElement(gpInterface_Sidebar, ELETYPE_GAP, 0);
47 // Plain <hr/> style spacer
48 WM_CreateElement(gpInterface_Sidebar, ELETYPE_SPACER, 0);
51 text = WM_CreateElement(gpInterface_Sidebar, ELETYPE_TEXT, ELEFLAG_WRAP);
52 WM_SetText(text, "AxWin 1.0");
55 void Interface_Update(void)
57 giInterface_Width = giScreenWidth/16;
58 WM_SetSize( gpInterface_Sidebar, giInterface_Width );
61 void Interface_Render(void)
66 giInterface_Width, giScreenHeight,