Page 1 of 1

change color of part of a screen

Posted: Sat Mar 17, 2007 2:39 am
by Jeff Barnes
Hi Everybody,


I would like to change the background color of "part" of my screen.

In the following screen shot clip, I would like to change the background whenever the waveform dips below the red line. I need to still see the waveform. I can get the screen co-ordinates, I just need to know the color changing part.

Is this possible?

Thanks,

Jeff


[img]
www.can-soft.net/dl/ScreenShot.JPG
[/img]

Posted: Sat Mar 17, 2007 6:32 am
by Antonio Linares
Jeff,

If you don't use a dooted red line (use a continuous one) then you can use FloodFill()

Posted: Sat Mar 17, 2007 4:24 pm
by Jeff Barnes
Antonio,

Take a look at this second screen shot ... This is an idea of what I am trying to do.


[img]
www.can-soft.net/dl/ScreenShot2.JPG
[/img]


Thanks,
Jeff

Posted: Sat Mar 17, 2007 4:55 pm
by James Bott
Jeff,

Try drawing a box then use floodFill(). Use the same color pen for both.

Maybe you will have to redraw the gridlines and graph afterward.

James

Posted: Sat Mar 17, 2007 5:53 pm
by Antonio Linares
Jeff,

Do you mean those vertical gray rectangles ?

Posted: Sat Mar 17, 2007 6:12 pm
by Jeff Barnes
Antonio,

Yes, the grey areas are what I would like to add when needed.


Jeff

Posted: Sun Mar 18, 2007 12:12 am
by Antonio Linares
Jeff,

You may paint them using Rectangle() before painting the lines