Re: creating your own GWT theme or a pluggable look and feel
Do you know if there are there any proposals close to completion? I enjoy writing parsers, but I don't want to write my own if something new is about to be published. I don't know of any parser that accomplishes that (googled it). There are though many proposed protocols (still none is related to GWT), all based on XML files. --~--~-~--~~~---~--~~ 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: creating your own GWT theme or a pluggable look and feel
Hi hobbyist, AFAIK, styles are set in each class, when they are constructed (so, via constructor). I have tried to change the stylename for TabPanel and TabItem (to match at least the style cascading conventions my app used), but found it impossible. Still, what you actually want is some sort of UIDL (User Interface Definition Language) parser. There are many proposals, you could implement a simple one that only handles stylenames. Alex --~--~-~--~~~---~--~~ 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: creating your own GWT theme or a pluggable look and feel
On 30 Jun., 11:15, hobbyist bindingserv...@gmail.com wrote: I am new to GWT and I went through a couple of the tutorials on the GWT website. I've started using GWT to make a webapp just for fun, and I one of the first things that I had difficulty with was styling the application in its entirety. I want to give the website a certain look, but I also want it to be easy to change the style of the webapp in the future, and maybe even dynamically while the app is running (so that logged in users could each have their own personal style applied to the website, for example). I noticed on the UIObject javadoc it says By convention, GWT style names are of the form [project]-[widget], so that, for example, the default Button class name is gwt-Button. Is there a way to change the [project] part of this name, so that, for example, I could change all Button class names to, say, my-Button without having to call setStyleName() on every Button individually? Just override .gwt-Button in your MyApp.css and all buttons will have your style. If there is no way to do this dynamically, is there at least a way to create my own GWT theme so that I can reference in the Project.gwt.xml file, so if I want to change the look and feel of my webapp later, I can do it by creating a new stylesheet and changing one line in Project.gwt.xml rather calling setStyleName() on every widget? --~--~-~--~~~---~--~~ 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: creating your own GWT theme or a pluggable look and feel
On Jul 2, 9:09 am, alex.d alex.dukhov...@googlemail.com wrote: Just override .gwt-Button in your MyApp.css and all buttons will have your style. Thanks! This achieves the effect I was aiming for. I still wish there were a way to change widget class names, but this certainly gets the job done. Thanks again for the answer; this solution is so simple that it makes my question sound silly. On Jul 2, 5:29 am, djd alex.dobjans...@gmail.com wrote: AFAIK, styles are set in each class, when they are constructed (so, via constructor). I checked this, and unfortunately it looks like this is true: http://code.google.com/p/google-web-toolkit/source/browse/branches/snapshot-2009.06.16-r5570/user/src/com/google/gwt/user/client/ui/Button.java#74 On line 80 (inside the Button() constructor), you see the string gwt- Button is hard-coded. I assume the same is true in other widgets. Is there any good reason why GWT widgets class names are initialized this way, for performance maybe? Without a compelling performance gain, hard-coding this string just seems like bad practice. Still, what you actually want is some sort of UIDL (User Interface Definition Language) parser. There are many proposals, you could implement a simple one that only handles stylenames. Do you know if there are there any proposals close to completion? I enjoy writing parsers, but I don't want to write my own if something new is about to be published. --~--~-~--~~~---~--~~ 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: creating your own GWT theme or a pluggable look and feel
I still wish there were a way to change widget class names There is myButton.setStyleName(foo); Or myButton.addStyleName(foo); There's also the concept of primary style names and dependent style names, if you want to dig into that. On Thu, Jul 2, 2009 at 2:00 PM, hobbyistbindingserv...@gmail.com wrote: On Jul 2, 9:09 am, alex.d alex.dukhov...@googlemail.com wrote: Just override .gwt-Button in your MyApp.css and all buttons will have your style. Thanks! This achieves the effect I was aiming for. I still wish there were a way to change widget class names, but this certainly gets the job done. Thanks again for the answer; this solution is so simple that it makes my question sound silly. On Jul 2, 5:29 am, djd alex.dobjans...@gmail.com wrote: AFAIK, styles are set in each class, when they are constructed (so, via constructor). I checked this, and unfortunately it looks like this is true: http://code.google.com/p/google-web-toolkit/source/browse/branches/snapshot-2009.06.16-r5570/user/src/com/google/gwt/user/client/ui/Button.java#74 On line 80 (inside the Button() constructor), you see the string gwt- Button is hard-coded. I assume the same is true in other widgets. Is there any good reason why GWT widgets class names are initialized this way, for performance maybe? Without a compelling performance gain, hard-coding this string just seems like bad practice. Still, what you actually want is some sort of UIDL (User Interface Definition Language) parser. There are many proposals, you could implement a simple one that only handles stylenames. Do you know if there are there any proposals close to completion? I enjoy writing parsers, but I don't want to write my own if something new is about to be published. --~--~-~--~~~---~--~~ 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 -~--~~~~--~~--~--~---
creating your own GWT theme or a pluggable look and feel
I am new to GWT and I went through a couple of the tutorials on the GWT website. I've started using GWT to make a webapp just for fun, and I one of the first things that I had difficulty with was styling the application in its entirety. I want to give the website a certain look, but I also want it to be easy to change the style of the webapp in the future, and maybe even dynamically while the app is running (so that logged in users could each have their own personal style applied to the website, for example). I noticed on the UIObject javadoc it says By convention, GWT style names are of the form [project]-[widget], so that, for example, the default Button class name is gwt-Button. Is there a way to change the [project] part of this name, so that, for example, I could change all Button class names to, say, my-Button without having to call setStyleName() on every Button individually? If there is no way to do this dynamically, is there at least a way to create my own GWT theme so that I can reference in the Project.gwt.xml file, so if I want to change the look and feel of my webapp later, I can do it by creating a new stylesheet and changing one line in Project.gwt.xml rather calling setStyleName() on every widget? --~--~-~--~~~---~--~~ 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 -~--~~~~--~~--~--~---