VBen
Sat Feb 19 16:19:56 CST 2005
If anyone is interested, I tried this solution.
It's great, since it does exactly that: Draw the nodes cascade in a right to
left cascade... There's just one problem: Wether you establish
"WS_EX_NOINHERITLAYOUT" or not, the images in the treeview are drawn
mirrored, and the text is drawn correctly (I tried establishing also
WS_EX_RTLREADING with the same results).
The solution is as simple as mirroring images before loading them into the
ImageList control, but if anyone has the correct solution for that
particular problem, I'd like to know about it (just curious)...
Regards,
VBen.
"VBen" <bmorayta@compucaremexico.com> escribió en el mensaje
news:u7UnLNeFFHA.2508@TK2MSFTNGP10.phx.gbl...
> That's the cleanest, most direct and most elegant solution I've EVER seen
> for a problem this potentially complicated....
> Wow!!
> VBen.
>
> "Mick Doherty"
> <EXCHANGE#WITH@AND.REMOVE.SQUAREBRACKETS.[mdaudi100#ntlworld.com]>
escribió
> en el mensaje news:#EsrNxcFFHA.2828@TK2MSFTNGP09.phx.gbl...
> > Quick hack in VB.Net
> >
> > Inherit from Treeview and add the following code:
> > \\\
> > Protected Overrides ReadOnly Property CreateParams() As CreateParams
> > Get
> > Dim cp As CreateParams = MyBase.CreateParams
> > Const WS_EX_LAYOUTRTL As Integer = &H400000
> > Const WS_EX_NOINHERITLAYOUT As Integer = &H100000
> > If Me.Mirror Then
> > cp.ExStyle += WS_EX_LAYOUTRTL Or WS_EX_NOINHERITLAYOUT
> > End If
> > Return cp
> > End Get
> > End Property
> >
> > Private m_Mirror As Boolean = False
> >
> > <DefaultValue(False)> _
> > Public Property Mirror() As Boolean
> > Get
> > Return m_Mirror
> > End Get
> > Set(ByVal Value As Boolean)
> > If m_Mirror = Value Then Return
> > m_Mirror = Value
> > MyBase.UpdateStyles()
> > End Set
> > End Property
> > ///
> >
> > --
> > Mick Doherty
> >
http://dotnetrix.co.uk/nothing.html
> >
> >
> > "Allen Anderson" <albruan@comcast.net> wrote in message
> > news:SYadnUwKFs0BQojfRVn-3Q@comcast.com...
> > >I haven't received an answer to my question of a few days ago regarding
a
> > >flipped treeview control posted in the
> > >dotnet.framework.windowsforms.control newsgroup, so I thought I'd ask
it
> > >again. Sorry about the cross-posting, but I'm getting desperate as the
> > >drop-dead date, the 25th of this month, on my project approaches.
> > >
> > > I'm attempting to create a TreeView similar to the one on the
right-hand
> > > side of the BizTalk Mapper screen. I'm able to create a mirror image
of
> a
> > > normal TreeView with everything swapped left-for-right, kind of like
> > > looking at the reflection of the tree in a mirror; unfortunately, that
> > > everything also includes the text for each node. Is there a way of
> > > creating a bitmap of each visible node and performing a
> > > Bitmap.RotateFlip(RotateFlipType.RotateNoneFlipX) on it prior to
> > > performing a Bitmap.RotateFlip(RotateFlipType.RotateNoneFlipX) on the
> > > bitmap of the entire tree? Is there another way of accomplishing the
> same
> > > thing?
> > >
> > > Any help would be greatly appreciated.
> > >
> >
> >
>
>