| View previous topic :: View next topic |
| Author |
Message |
tinyabs Guest
|
Posted: Wed Apr 06, 2005 5:28 am Post subject: Painting in TScrollingWinControl |
|
|
How to I draw custom graphics in TScrollingWinControl? I'm doing a custom
control that requires scrollbars.
|
|
| Back to top |
|
 |
Hans Galema Guest
|
Posted: Wed Apr 06, 2005 6:51 am Post subject: Re: Painting in TScrollingWinControl |
|
|
tinyabs wrote:
| Quote: | How to I draw custom graphics in TScrollingWinControl? I'm doing a custom
control that requires scrollbars.
|
You could supply it with a TControlCanvas. Or just a TPaintBox maybe.
Hans,
|
|
| Back to top |
|
 |
tinyabs Guest
|
Posted: Wed Apr 06, 2005 9:29 pm Post subject: Re: Painting in TScrollingWinControl |
|
|
Do you mean setting TPaintBox as a child of TScrollingWinControl? Currently,
I paint after the control processed WM_PAINT.
I think I just use TWinControl with WS_EX_RIGHTSCROLLBAR to do it.
"Hans Galema" <notused (AT) notused (DOT) nl> wrote
| Quote: | tinyabs wrote:
How to I draw custom graphics in TScrollingWinControl? I'm doing a custom
control that requires scrollbars.
You could supply it with a TControlCanvas. Or just a TPaintBox maybe.
Hans,
|
|
|
| Back to top |
|
 |
Hans Galema Guest
|
Posted: Thu Apr 07, 2005 8:05 am Post subject: Re: Painting in TScrollingWinControl |
|
|
tinyabs wrote:
| Quote: | Do you mean setting TPaintBox as a child of TScrollingWinControl? Currently,
I paint after the control processed WM_PAINT.
|
But where do you paint on ? Which canvas ? You asked "How to draw..".
Maybe I did not understand what you needed.
| Quote: | I think I just use TWinControl with WS_EX_RIGHTSCROLLBAR to do it.
|
To draw a graphic on/or what ??
Hans.
|
|
| Back to top |
|
 |
tinyabs Guest
|
Posted: Thu Apr 07, 2005 6:42 pm Post subject: Re: Painting in TScrollingWinControl |
|
|
It's a specialized control. Try imagine MS Paint using this control as its
drawing area (with scrollbars). I draw other things on my control.
| Quote: | But where do you paint on ? Which canvas ? You asked "How to draw..".
Maybe I did not understand what you needed.
I draw directly to the HDC created during WM_PAINT. |
My original intention was to find out which control supports custom painting
and scrollbars. Cos I think TScrollingWinControl don't support custom
painting, it's only for placing child controls.
|
|
| Back to top |
|
 |
|