These functions are new:
Code: Select all
SG_OpenWindow(SG_WindowID_L.l, xPos_L.l, yPos_L.l, Width_L.l, Height_L.l, Title_S.s)
SG_CloseWindow(WindowNr_L.l)
SG_HideWindow(WindowNr_L.l, State_L.l)
SG_DisableWindow(WindowNr_L.l, Status_L.l)
SG_CreateGadgetList(SG_WindowID_L.l)
SG_SetActiveWindow(WindowNr_L.l) ; sets the currently active window
SG_IsWindow(SG_WindowID_L.l) ; returns 0, if the window does not exist, else a value <> 0 (= Window ID)
SG_GetWindowBackGround(WindowNr_L.l) ; returns the background of the window - 0 = no Background 1= Color 2 = image
SG_GetWindowBackgroundDetail(WindowNr_L.l) ; returns the Backround - Value (Color or imageID)
SG_SetWindowBackGround(WindowNr_L.l, State_L.l); change the background of the window - 0 = no Background 1= Color 2 = image
SG_SetWindowBackgroundDetail(WindowNr_L.l, Value_L.l) ; sets the ImageID of the background of the window
SG_SetWindowState(WindowNr_L.l, Status_L.l)
SG_SetWindowTitle(WindowNr_L.l, Title_S.s)
SG_ResizeWindow(WindowNr_L.l, xPos_L.l, yPos_L.l, Width_L.l, Height_L.l) ; set the window to a new position and and size
SG_StickyWindow(WindowNr_L.l, Status_L.l)
SG_WindowID(WindowNr_L.l)
SG_WindowHeight(WindowNr_L.l)
SG_WindowWidth(WindowNr_L.l)
SG_WindowMouseX(WindowNr_L.l)
SG_WindowMouseY(WindowNr_L.l)
SG_WindowX(WindowNr_L.l)
SG_WindowY(WindowNr_L.l)
SG_GetActiveWindow() ; return the currently active window
SG_GetWindowState(WindowNr_L.l)

and here you can find the source code and the compiled demo (87k zipped)
http://purebasic.stdojedmahr.de/projekt ... etDemo.zip
The source is written for PB 4.2
If someone is using Linux, maybe (s)he can test the code under linux, if it runs. (I hope so, but have no change of testing it). Same with Mac.
I have use a rather old PC, so the fps (upper left corner) are more or less low. Can someone post his configuration and fps?
I got 52 fps with the demo.
If someone found any bugs, please report.