1. [WIN] Win32Lib tab items: programmatically select; and disable?

In Win32Lib, is there any way to programmatically select a tab item?

And is there a way to "disable" a specified tab item, so as to make its
title "gray out"?   When I try, it disables the whole tabcontrol (so *no*
tab items at all work), not just the specified tabitem, and doesn't change
the tab title(s) appearance.  Works similarly for setVisible: set a tabitem
to invisible, and the whole tabcontrol disappears.

Dan Moyer

new topic     » topic index » view message » categorize

2. Re: [WIN] Win32Lib tab items: programmatically select; and disable?

Hi Dan,

> In Win32Lib, is there any way to programmatically select a tab item?

Have you tried setFocus(TabItem)

This should set the focus to the tabitem you want selected programmatically.

> And is there a way to "disable" a specified tab item, so as to make its
> title "gray out"?   When I try, it disables the whole tabcontrol (so *no*
> tab items at all work), not just the specified tabitem, and doesn't change
> the tab title(s) appearance.  Works similarly for setVisible: set a tabitem
> to invisible, and the whole tabcontrol disappears.
> 
> Dan Moyer 

As for the gray-out effect, I havent a clue....
I dont think that's possible with the current Win32lib....

Euman
euman at bellsouth.net

new topic     » goto parent     » topic index » view message » categorize

3. Re: [WIN] Win32Lib tab items: programmatically select; and disable?

Hi Dan,
use setFocus() to select a specific tab item.

The standard Windows tab control does not support disabling a given tab
item. Your best bet would be to create a sequence that contains all the IDs
for the controls in each tab item and then use setEnabled(tabitemseq,
False). This would still allow people to click on the tab item, but all the
controls in there would be gray.

In a way, this is analagous to having a menu selectable but all its menu
items disabled.

If there is a pressing need to really disable a tab item, I'll work on a way
to do that in future.

----
Derek.

----- Original Message -----
From: "Dan Moyer" <DANIELMOYER at prodigy.net>
To: "EUforum" <EUforum at topica.com>
Sent: Saturday, October 06, 2001 11:40 AM
Subject: [WIN] Win32Lib tab items: programmatically select; and disable?


>
> In Win32Lib, is there any way to programmatically select a tab item?
>
> And is there a way to "disable" a specified tab item, so as to make its
> title "gray out"?   When I try, it disables the whole tabcontrol (so *no*
> tab items at all work), not just the specified tabitem, and doesn't change
> the tab title(s) appearance.  Works similarly for setVisible: set a
tabitem
> to invisible, and the whole tabcontrol disappears.
>
> Dan Moyer
>
>
>

new topic     » goto parent     » topic index » view message » categorize

4. Re: [WIN] Win32Lib tab items: programmatically select; and disable?

Euman,

No, I didn't even think of, let alone try,  setFocus; don't know why I
didn't, thanks!

Dan

----- Original Message -----
From: <euman at bellsouth.net>
To: "EUforum" <EUforum at topica.com>
Subject: Re: [WIN] Win32Lib tab items: programmatically select; and disable?


>
> Hi Dan,
>
> > In Win32Lib, is there any way to programmatically select a tab item?
>
> Have you tried setFocus(TabItem)
>
> This should set the focus to the tabitem you want selected
programmatically.
>
> > And is there a way to "disable" a specified tab item, so as to make its
> > title "gray out"?   When I try, it disables the whole tabcontrol (so
*no*
> > tab items at all work), not just the specified tabitem, and doesn't
change
> > the tab title(s) appearance.  Works similarly for setVisible: set a
tabitem
> > to invisible, and the whole tabcontrol disappears.
> >
> > Dan Moyer
>
> As for the gray-out effect, I havent a clue....
> I dont think that's possible with the current Win32lib....
>
> Euman
> euman at bellsouth.net
>
>
>

new topic     » goto parent     » topic index » view message » categorize

5. Re: [WIN] Win32Lib tab items: programmatically select; and disable?

Derek,

Don't know why I didn't even think of and try setFocus, thanks.

There's no pressing need for disabling a tabitem, I just made the controls
in it invisible when they're empty;  I wanted to make it easier/quicker for
the user to know when there wasn't anything in a tabitem which had content,
and when there was, so they'd know at a glance whether to click on one or
not.  Might be useful, though.

Dan


----- Original Message -----
From: "Derek Parnell" <ddparnell at bigpond.com>
To: "EUforum" <EUforum at topica.com>
Sent: Friday, October 05, 2001 7:37 PM
Subject: Re: [WIN] Win32Lib tab items: programmatically select; and disable?


>
> Hi Dan,
> use setFocus() to select a specific tab item.
>
> The standard Windows tab control does not support disabling a given tab
> item. Your best bet would be to create a sequence that contains all the
IDs
> for the controls in each tab item and then use setEnabled(tabitemseq,
> False). This would still allow people to click on the tab item, but all
the
> controls in there would be gray.
>
> In a way, this is analagous to having a menu selectable but all its menu
> items disabled.
>
> If there is a pressing need to really disable a tab item, I'll work on a
way
> to do that in future.
>
> ----
> Derek.
>
> ----- Original Message -----
> From: "Dan Moyer" <DANIELMOYER at prodigy.net>
> To: "EUforum" <EUforum at topica.com>
> Sent: Saturday, October 06, 2001 11:40 AM
> Subject: [WIN] Win32Lib tab items: programmatically select; and disable?
>
>
> > In Win32Lib, is there any way to programmatically select a tab item?
> >
> > And is there a way to "disable" a specified tab item, so as to make its
> > title "gray out"?   When I try, it disables the whole tabcontrol (so
*no*
> > tab items at all work), not just the specified tabitem, and doesn't
change
> > the tab title(s) appearance.  Works similarly for setVisible: set a
> tabitem
> > to invisible, and the whole tabcontrol disappears.
> >
> > Dan Moyer
> >
> >
>
>

new topic     » goto parent     » topic index » view message » categorize

6. Re: [WIN] Win32Lib tab items: programmatically select; and disable?

Derek,

I made the controls in a tab item invisible because each tab item has one
combo & nothing else, and they either have content, or don't, so there's no
reason to show them when they're empty.

I like the idea of adding [] around tab text for tabs which don't have
anything currently useable in them, but if I can change the color of just
the text in one tab, I'll probably use that suggestion, thanks.

Dan

----- Original Message -----
From: "Derek Parnell" <ddparnell at bigpond.com>
To: "EUforum" <EUforum at topica.com>
Sent: Sunday, October 07, 2001 11:22 PM
Subject: RE: [WIN] Win32Lib tab items: programmatically select; and disable?


>
> Dan Moyer wrote:
> >
> > There's no pressing need for disabling a tabitem, I just made the
> > controls
> > in it invisible when they're empty;  I wanted to make it easier/quicker
> > for
> > the user to know when there wasn't anything in a tabitem which had
> > content,
> > and when there was, so they'd know at a glance whether to click on one
> > or
> > not.  Might be useful, though.
>
> Dan,
> it might be better to disable the controls rather than hide them. That
> way the user can at least see what controls might be possible later.
> Also, you might like to give a visual clue by changing the text of the
> tab item , for example place square brackets around them text when it is
> "disabled". Possibly even changing the text color to
> getSysColor(COLOR_GRAYTEXT).
> ----
> Derek.
>
>
>

new topic     » goto parent     » topic index » view message » categorize

7. Re: [WIN] Win32Lib tab items: programmatically select; and disable?

Tony,

Thanks, that's an idea too, but if I can change the text color for just one
tab, I think I'll probably do that.

Dan

----- Original Message -----
From: "Tony Steward" <tony at locksdownunder.com>
To: "EUforum" <EUforum at topica.com>
Subject: RE: [WIN] Win32Lib tab items: programmatically select; and disable?


>
> Hi Dan,
> Just an idea, Rename a tab with a preceding * if that tab contains info.
> This way users will know at a glance that a tab has info on it.
>
> Regards
> Tony Steward
>
> Dan Moyer wrote:
> > Derek,
> >
> > Don't know why I didn't even think of and try setFocus, thanks.
> >
> > There's no pressing need for disabling a tabitem, I just made the
> > controls
> > in it invisible when they're empty;  I wanted to make it easier/quicker
> > for
> > the user to know when there wasn't anything in a tabitem which had
> > content,
> > and when there was, so they'd know at a glance whether to click on one
> > or
> > not.  Might be useful, though.
> >
> > Dan
> >
> >
> > ----- Original Message -----
> > From: "Derek Parnell" <ddparnell at bigpond.com>
> > To: "EUforum" <EUforum at topica.com>
> > Sent: Friday, October 05, 2001 7:37 PM
> > Subject: Re: [WIN] Win32Lib tab items: programmatically select; and
> > disable?
> >
> >
> > > Hi Dan,
> > > use setFocus() to select a specific tab item.
> > >
> > > The standard Windows tab control does not support disabling a given
tab
> > > item. Your best bet would be to create a sequence that contains all
the
> > IDs
> > > for the controls in each tab item and then use setEnabled(tabitemseq,
> > > False). This would still allow people to click on the tab item, but
all
> > the
> > > controls in there would be gray.
> > >
> > > In a way, this is analagous to having a menu selectable but all its
menu
> > > items disabled.
> > >
> > > If there is a pressing need to really disable a tab item, I'll work on
 a
> > way
> > > to do that in future.
> > >
> > > ----
> > > Derek.
> > >
> > > ----- Original Message -----
> > > From: "Dan Moyer" <DANIELMOYER at prodigy.net>
> > > To: "EUforum" <EUforum at topica.com>
> > > Sent: Saturday, October 06, 2001 11:40 AM
> > > Subject: [WIN] Win32Lib tab items: programmatically select; and
disable?
> > >
> > >
> > > > In Win32Lib, is there any way to programmatically select a tab item?
> > > >
> > > > And is there a way to "disable" a specified tab item, so as to make
its
> > > > title "gray out"?   When I try, it disables the whole tabcontrol (so
> > *no*
> > > > tab items at all work), not just the specified tabitem, and doesn't
> > change
> > > > the tab title(s) appearance.  Works similarly for setVisible: set a
> > > tabitem
> > > > to invisible, and the whole tabcontrol disappears.
> > > >
> > > > Dan Moyer
> > > >
> > > >

new topic     » goto parent     » topic index » view message » categorize

8. Re: [WIN] Win32Lib tab items: programmatically select; and disable?

Derek,

setText doesn't seem to work for tab text; is that the wrong way to put new
text onto a tabitem?

And setTextColor only seems to work for wPuts, which writes onto a tabItem,
but not correctly (doesn't erase existing text).

Dan

----- Original Message -----
From: "Derek Parnell" <ddparnell at bigpond.com>
To: "EUforum" <EUforum at topica.com>
Sent: Sunday, October 07, 2001 11:22 PM
Subject: RE: [WIN] Win32Lib tab items: programmatically select; and disable?


>
> Dan Moyer wrote:
> >
> > There's no pressing need for disabling a tabitem, I just made the
> > controls
> > in it invisible when they're empty;  I wanted to make it easier/quicker
> > for
> > the user to know when there wasn't anything in a tabitem which had
> > content,
> > and when there was, so they'd know at a glance whether to click on one
> > or
> > not.  Might be useful, though.
>
> Dan,
> it might be better to disable the controls rather than hide them. That
> way the user can at least see what controls might be possible later.
> Also, you might like to give a visual clue by changing the text of the
> tab item , for example place square brackets around them text when it is
> "disabled". Possibly even changing the text color to
> getSysColor(COLOR_GRAYTEXT).
> ----
> Derek.
>
> >

new topic     » goto parent     » topic index » view message » categorize

Search



Quick Links

User menu

Not signed in.

Misc Menu