Hey Guatier,

2010/10/15 Gautier Hankenne <[email protected]>:
> The problem I come across quite often is that there are lots of styles
> defined in the code directly (example: <td style="overflow: hidden;
> height: 17px; padding: 9px 3px 9px 9px;">) which, from my little
> knowledge, oblige the designer to come with stylesheets with "!important".
> Indeed, if you look at the selector's specificity of elements on
> http://www.w3.org/TR/CSS2/cascade.html#specificity you can see that '
> style="" ' override everything else.

Sometimes though, this is because some the styling is through the API
or from some functionality like in this case for your example, a
standard layout manager. There, the 3px 9px ... etc come from
WGridLayout::setHorizontalSpacing(), setVerticalSpacing() and
setContentsMargins(). Other examples are widget->decorationStyle() and
widget->resize(): they all result in a style attribute.

We usually try to limit setting a style attribute unless it is really
some API-defined property that has to apply to the single widget.

But of course you can point out exceptions that we can get rid of !

> Also, is there a documentation on how to make a theme or is it just copy
> the polished one and make another folder with the theme name and ask my
> dear collegue Guy to apply it? ;-)

We do document some of the selectors in a CSS block in our reference
documentation. Starting from an existing wt.css file is probably a
good idea for a new theme -- or including it using @include in a new
themes/gautier/wt.css file and specializing those selectors which you
want to override ?

Regards,
koen

------------------------------------------------------------------------------
Download new Adobe(R) Flash(R) Builder(TM) 4
The new Adobe(R) Flex(R) 4 and Flash(R) Builder(TM) 4 (formerly 
Flex(R) Builder(TM)) enable the development of rich applications that run
across multiple browsers and platforms. Download your free trials today!
http://p.sf.net/sfu/adobe-dev2dev
_______________________________________________
witty-interest mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/witty-interest

Reply via email to