From: shubhishubhi on
I want to display normal and state images in my tree control from image list.
Generally, treectrl displays checkbox first in a row and it then displays the
normal image. Is it possible to reverse this order i.e. to show normal image
before the state image ?
From: Ajay Kalra on
On Jan 6, 10:44 am, shubhishubhi
<shubhishu...(a)discussions.microsoft.com> wrote:
> I want to display normal and state images in my tree control from image list.
> Generally, treectrl displays checkbox first in a row and it then displays the
> normal image. Is it possible to reverse this order i.e. to show normal image
> before the state image ?

I am not fully certain but you may be able to do it using
NM_CUSTOMDRAW.

--
Ajay
From: Tom Serface on
Maybe something like this would work for you, or at least give you some
ideas:

http://www.codeproject.com/KB/tree/CRHTree.aspx

Tom

"shubhishubhi" <shubhishubhi(a)discussions.microsoft.com> wrote in message
news:650D2A4F-CD66-47A3-B1F5-AC64EE9BFA68(a)microsoft.com...
> I want to display normal and state images in my tree control from image
> list.
> Generally, treectrl displays checkbox first in a row and it then displays
> the
> normal image. Is it possible to reverse this order i.e. to show normal
> image
> before the state image ?

From: rahul on
On Jan 6, 11:16 pm, "Tom Serface" <t...(a)camaswood.com> wrote:
> Maybe something like this would work for you, or at least give you some
> ideas:
>
> http://www.codeproject.com/KB/tree/CRHTree.aspx
>
> Tom
>
> "shubhishubhi" <shubhishu...(a)discussions.microsoft.com> wrote in message
>
> news:650D2A4F-CD66-47A3-B1F5-AC64EE9BFA68(a)microsoft.com...
>
> > I want to display normal and state images in my tree control from image
> > list.
> > Generally, treectrl displays checkbox first in a row and it then displays
> > the
> > normal image. Is it possible to reverse this order i.e. to show normal
> > image
> > before the state image ?
>
>

U can subclass CTreeCtrl and do your own painting for each item in
your own way
From: Ajay Kalra on
On Jan 6, 11:50 pm, rahul <hyrahu...(a)gmail.com> wrote:

> U can subclass CTreeCtrl and do your own painting for each item in
> your own way

Thats precisely why NM_CUSTOMDRAW was introduced. Its more structured
and lets you draw the portion of the control that you want to draw as
opposed to the painting of the whole control.

--
Ajay