Re: Two TabPanels, different CSS styles

2009-03-26 Thread rookie

Thanks a lot Gregor. I was struggling with remove the default styles
from the tabpanel. This is very helpful.

On Feb 27, 7:12 am, gregor  wrote:
> CSS is often hierarchical in GWT widgets. You have a primary style
> name and then additional secondary styles that are swapped out
> according to user actions (like select, hover etc). With a Tab panel
> the tabs are controlled by the TabBar class, and you can see it has a
> primary style gwt-TabBar and a selection of additional styles.
>
> .gwt-TabBar {
>
> }
>
> .gwt-TabBar .gwt-TabBarFirst {
>
> }
>
> .gwt-TabBar .gwt-TabBarRest {
>
> }
>
> .gwt-TabBar .gwt-TabBarItem {
>
> }
>
> .gwt-TabBar .gwt-TabBarItem-selected {
>
> }
>
> To custom style TabBars differently all you have to do is copy this
> template CSS and replace gwt-TabBar with my-TabBar. Then you set the
> style as:
>
> myTabPanel.getTabBar().setPrimaryStyleName("my-TabBar");
>
> Do not change the gwt- part of the secondary style names as the
> internal TabBar code won't recognize them. E.g. you end up with
>
> .my-TabBar .gwt-TabBarItem-selected {
>
> }
>
> So you can have as many different styles for the same GWT widget class
> within the same application as you like.
>
> On Feb 27, 4:25 am, Ananda  wrote:
>
> > I belive you can do it..
> > Use the different style name , it will work
>
> > Regards,
> > AR
>
> > -Original Message-
> > From: Google-Web-Toolkit@googlegroups.com
>
> > [mailto:google-web-tool...@googlegroups.com] On Behalf Of Master Shake
> > Sent: Friday, February 27, 2009 8:18 AM
> > To: Google Web Toolkit
> > Subject: Two TabPanels, different CSS styles
>
> > Is there a way to have different css styles for two of the same GWT
> > composite types (i.e. TabPanels) in the same document? I have two
> > TabPanels and I want one TabPanel to have larger tabs...
>
> > Thanks,
> > -ms
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to Google-Web-Toolkit@googlegroups.com
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/Google-Web-Toolkit?hl=en
-~--~~~~--~~--~--~---



Re: Two TabPanels, different CSS styles

2009-02-27 Thread gregor

CSS is often hierarchical in GWT widgets. You have a primary style
name and then additional secondary styles that are swapped out
according to user actions (like select, hover etc). With a Tab panel
the tabs are controlled by the TabBar class, and you can see it has a
primary style gwt-TabBar and a selection of additional styles.

.gwt-TabBar {
}

.gwt-TabBar .gwt-TabBarFirst {
}

.gwt-TabBar .gwt-TabBarRest {
}

.gwt-TabBar .gwt-TabBarItem {
}

.gwt-TabBar .gwt-TabBarItem-selected {
}

To custom style TabBars differently all you have to do is copy this
template CSS and replace gwt-TabBar with my-TabBar. Then you set the
style as:

myTabPanel.getTabBar().setPrimaryStyleName("my-TabBar");

Do not change the gwt- part of the secondary style names as the
internal TabBar code won't recognize them. E.g. you end up with

.my-TabBar .gwt-TabBarItem-selected {
}

So you can have as many different styles for the same GWT widget class
within the same application as you like.


On Feb 27, 4:25 am, Ananda  wrote:
> I belive you can do it..
> Use the different style name , it will work
>
> Regards,
> AR
>
> -Original Message-
> From: Google-Web-Toolkit@googlegroups.com
>
> [mailto:google-web-tool...@googlegroups.com] On Behalf Of Master Shake
> Sent: Friday, February 27, 2009 8:18 AM
> To: Google Web Toolkit
> Subject: Two TabPanels, different CSS styles
>
> Is there a way to have different css styles for two of the same GWT
> composite types (i.e. TabPanels) in the same document? I have two
> TabPanels and I want one TabPanel to have larger tabs...
>
> Thanks,
> -ms
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to Google-Web-Toolkit@googlegroups.com
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/Google-Web-Toolkit?hl=en
-~--~~~~--~~--~--~---



RE: Two TabPanels, different CSS styles

2009-02-26 Thread Ananda

I belive you can do it..
Use the different style name , it will work

Regards,
AR


-Original Message-
From: Google-Web-Toolkit@googlegroups.com
[mailto:google-web-tool...@googlegroups.com] On Behalf Of Master Shake
Sent: Friday, February 27, 2009 8:18 AM
To: Google Web Toolkit
Subject: Two TabPanels, different CSS styles


Is there a way to have different css styles for two of the same GWT
composite types (i.e. TabPanels) in the same document? I have two
TabPanels and I want one TabPanel to have larger tabs...

Thanks,
-ms



--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to Google-Web-Toolkit@googlegroups.com
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/Google-Web-Toolkit?hl=en
-~--~~~~--~~--~--~---