[MaxGUI] How to force gadget refresh?

BlitzMax Forums/BlitzMax Beginners Area/[MaxGUI] How to force gadget refresh?

Hi,

While doing some tasks, I fill a textarea with lines each time a single task is done. But all lines are drawn after the last task. Anyone knows how I can force MaxGUI to refresh it's gadgets?

"RedrawGadget"

But it is buggy and doesn't always work!

Thanks, I'll give this a try!

Made a progress on this one:

RedrawGadget doesn't work at all (not even sometimes), but this works under Win32:

Extern "win32"
Function UpdateWindow:Int(hwnd:int)="UpdateWindow@4"
end extern

'call this to update the window immediately
UpdateWindow (Querygadget(win,QUERY_HWND)) 'win is the window-gadget, of course



Maybe anyone with Mac or Linux-knowledge can provide a solution working on this platforms?

Are you using hooks in your program? If not, try rewriting your program to use hook. Sometimes it'll solve problems with windows not updating when you want them to.