[dokuwiki] Re: Proposal: theme colour control
- From: Anika Henke <a.c.henke@xxxxxxxx>
- To: dokuwiki@xxxxxxxxxxxxx
- Date: Sun, 12 Mar 2006 19:53:30 +0100
Chris Smith wrote:
Anika Henke wrote:
You are absolutely right about this! But I can tell you what Andi will
answer (because I asked him the same thing right after the css
dispatcher was out): "That's what templates are for ..." :-(
So, I for one, did the only reasonable thing to *my* template: I used
variables such as __text_1__, __text_headline__, __link_normal__,
__link_existent__, __background_3__, __border_2__ and such.
Also see my other note. I think you are trying to duplicate CSS
functionality with styles.ini. I would argue that isn't its purpose.
Its purpose is to simplify and standardise styles across the plethora of
Dokuwiki stylesheets and to avoid repititive use of "magic colour codes"
and any other common values. That is to allow all elements which share
a colour or value to use one name for that colour/value.
I agree partly.
I think it would be bad, if you defined just one color "__black__ =
#000" in every case when a css value is black ... You have to apply
/some/ *function* to a pattern.
I agree that things would be overdone when making patterns for too many
special cases.
I think that the approach in my template is quite good. Let me explain ...
I have 9 patterns for the overall look and feel (text1-3, background1-3
and border1-3). Whereas each pattern is used in a way that makes sense
and which doesn't let them clash with each other (or: Of course, it
would, if you defined all of them as black. ;-) ).
Then I have 5 more specific patterns for headlines and links. And 5 more
for the TOC (which may be the only thing, that's a bit overdone in my
template, but I felt the TOC deserves to look different from the rest of
the site). The last 5 patterns are only for section indenting (because I
like to have section indenting turned off, but I didn't want to break
the habit of the everyday DokuWiki user).
The section indenting is the only thing that is not a colour.
All in all they are 14 colours for the essential colouring (the same
amount that DokuWiki currently has), 5 more for -- okay, I admit --
overdone styling, and the last 5 do not really belong to the colour
patterns ...
Now, enough of self praise ... ;-)
Back to the original style.ini example of Matthias:
IMHO, those examples of __link_extern__, __text_headline__ and
__bar_line__ are *not* overdone and make perfectly sense.
But __link_visited__, __button_something__ and __input_something__ most
probably are overdone (at least in that diversity) ...
But a problem will occur, when Matthias sends the patch for the buttons:
For a 3D effect he *needs* at least three different additional colours
... And that will be difficult without an overload of patterns!
There is still the possibility of css "border-style"s (like "groove",
"ridge", etc.). Those won't need any extra colours (probably just one),
but would look differently in many browsers ...
Any opinions on that?
The final control of an individual element's presentation should remain
in CSS. Making styles.ini too large would make the process of template
building more complex not less. As you have to first deduce what style
Yes. I totally agree.
But define "too large", please.
I would say: Simple styles need at least 10 different patterns, more
complicated ones could work well with up to 25 ...
Anika
--
DokuWiki mailing list - more info at
http://wiki.splitbrain.org/wiki:mailinglist
Other related posts: