Drawing lines above windowed controls 
Author Message
 Drawing lines above windowed controls

I have 2 treecontrols on my form and I want to draw a line between a
treeitem on the one side to a treeitem on the other. When I use the line
object, the line is drawn behind the treecontrol. I have tried changing the
zorder but it doesn't seem to do anything.

I also read something on the msdn site that said that line objects are
automatically 1 layer behind the "windowed controls" like the treecontrol.

Does anyone have any suggestions/solutions for this problem?

Thanks,

Drew Morris

Note: I need to not only draw the line, but also reference the line object
later to do things such as move or hide the line.



Sat, 07 Feb 2004 15:29:40 GMT  
 Drawing lines above windowed controls
The "line" is a "windowless" control, and as such unsuitable
for what you want to do.

You might try to make your own "line-control" as a user-control.
There you can decide if it have a window-handle or not...

HTH...

Dag.


Quote:
> I have 2 treecontrols on my form and I want to draw a line between a
> treeitem on the one side to a treeitem on the other. When I use the line
> object, the line is drawn behind the treecontrol. I have tried changing
the
> zorder but it doesn't seem to do anything.

> I also read something on the msdn site that said that line objects are
> automatically 1 layer behind the "windowed controls" like the treecontrol.

> Does anyone have any suggestions/solutions for this problem?

> Thanks,

> Drew Morris

> Note: I need to not only draw the line, but also reference the line object
> later to do things such as move or hide the line.



Sat, 07 Feb 2004 18:41:45 GMT  
 Drawing lines above windowed controls

Actually you can use a borderless frame and align the two boxes inside
with a small gap in between them, and to then resize the frame so it's
wrapped tight around the boxes.
Trap the mouse in the frame's mouse_move event and the rest is just
programming. :)

Quote:
>The "line" is a "windowless" control, and as such unsuitable
>for what you want to do.

>You might try to make your own "line-control" as a user-control.
>There you can decide if it have a window-handle or not...

>HTH...

>Dag.



>> I have 2 treecontrols on my form and I want to draw a line between a
>> treeitem on the one side to a treeitem on the other. When I use the line
>> object, the line is drawn behind the treecontrol. I have tried changing
>the
>> zorder but it doesn't seem to do anything.

>> I also read something on the msdn site that said that line objects are
>> automatically 1 layer behind the "windowed controls" like the treecontrol.

>> Does anyone have any suggestions/solutions for this problem?

>> Thanks,

>> Drew Morris

>> Note: I need to not only draw the line, but also reference the line object
>> later to do things such as move or hide the line.

Regards, Frank.


Sat, 07 Feb 2004 20:56:59 GMT  
 
 [ 3 post ] 

 Relevant Pages 

1. Drawing lines above windowed controls

2. PB Direct Draw and windowed mode

3. DirectX 9, Direct Draw, windowed mode

4. Drawing on the Desktop (above my application)

5. Draw a Rectangle above MSChart-Object

6. RTB - auto indent to match the tab stop of the line above

7. Exporting to .DOC puts a blank line above + below subreports

8. ActiveX Control Won't Draw Line

9. Drawing lines on a Flexgrid control

10. Drawing lines on an MSflexgrid control

11. Drawing a line across controls...help!

12. How to Draw a Line in RichText Control

 

 
Powered by phpBB® Forum Software