An additional ResizeWindow() is needed too:
Code: Select all
OpenWindow(0, 0, 0, 100, 100, "", #PB_Window_SystemMenu | #PB_Window_ScreenCentered)
Debug Str(WindowWidth(0)) + "x" + Str(WindowHeight(0))
WindowBounds(0, 1, 1, #PB_Ignore, #PB_Ignore)
ResizeWindow(0, #PB_Ignore, #PB_Ignore, 100, 100)
Debug Str(WindowWidth(0)) + "x" + Str(WindowHeight(0))
Repeat : Until WaitWindowEvent() = #PB_Event_CloseWindow
But then I think it is a bug.
This should be the default, or it should be mentioned in the help.
I checked 15 minutes why my image was not centered correctly