Re: Color questions

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

Luis wrote:

> but...when i setBackgroundColor of text
> in a window,the color it's always white!

I've fixed the problem. Add the constants:

    constant
        TRANSPARENT = 1,
        OPAQUE      = 2

and the following code to the end of the putFontIntoHDC function:

    -- use transparent mode when writing text
    if not c_func(xSetBkMode, {hdc, TRANSPARENT} ) then
        -- unable to set background mode
        warnErr( "SetBkMode in putFontIntoHDC failed." )
    end if

This should take care of the problem.

-- David Cuny

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

Search



Quick Links

User menu

Not signed in.

Misc Menu