Hi Everybody,
I'm running into a problem with Max GUI: Whenever I create a canvas inside a window, and then resize the window, the canvas doesn't update its size, even tough it's set with "Edge_Relative". Its borders actually follow the Window, but nothing gets rendered in the newly created area.
Here, an example code:
Help!
Leo.
I'm running into a problem with Max GUI: Whenever I create a canvas inside a window, and then resize the window, the canvas doesn't update its size, even tough it's set with "Edge_Relative". Its borders actually follow the Window, but nothing gets rendered in the newly created area.
Here, an example code:
'----------------------------------------------------------------------- Strict Local WindowMain:Tgadget = CreateWindow ("Test",50,50, 320,240, Null, Window_Titlebar|Window_Resizable|WIndow_Status) Local Viewport:TGadget = CreateCanvas (10, 10, 290, 140, WindowMain, 1) SetGadgetLayout Viewport,1,1,1,1 Local Timer:TTimer=CreateTimer(60) Local X:Int=0 Repeat WaitEvent() Select EventID() Case Event_WindowCLose End Case Event_TimerTick x=x+1 RedrawGadget(viewport) Case Event_GadgetPaint SetGraphics CanvasGraphics (Viewport) Cls DrawRect (X,10,30,30) Flip End Select Forever '--------------------------------------------------------------------
Help!
Leo.