Re: Windows vertical retrace

new topic     » goto parent     » topic index » view thread      » older message » newer message

ags wrote:

> One question though.. why is there no non-erasing equivalent for paintRect?

Because nobody asked for it.

global procedure redrawRect( integer id, integer x1, integer y1, integer x2,
integer y2 )

    -- Redraws only a portion of the window
    atom hWnd
    atom rect

    -- Allocate rectangle
    rect = w32acquire_mem( 0, SIZEOF_RECT )
    poke4(rect, {x1,y1,x2,y2})

    hWnd = getHandle( id )

    -- invalidate sub-window of the current window
    if w32Func( xInvalidateRect, {hWnd, rect, 0} ) then
        VOID = w32Func(xSendMessage,{hWnd, WM_PAINT, 0, 0 })
    end if

    -- Free the rectangle structure
    w32release_mem( rect )

end procedure

-- 
Derek Parnell
Melbourne, Australia
Skype name: derek.j.parnell

new topic     » goto parent     » topic index » view thread      » older message » newer message

Search



Quick Links

User menu

Not signed in.

Misc Menu