Go
Decent Blogging using Foswiki Read on
26 Oct 2005 - 21:47 in tagged , , , by Michael Daum
Header Art was quite static before. Now you can attach your flicker graphics and a related css file to the NatSkin and select it from within the NatSkin style browser.
Note, however, that not every header art matches every style loaded into the NatSkin. But find out yourself which combinations play well and which not. Right now there are seven predefined header settings:
  1. BlueField
  2. BlueTechCherry
  3. Nuozek
  4. PlasticLove
  5. RedWoman
  6. SepiaField
  7. Subway
The latter is the current site default. As selecting skin variations is - as usual - settable via url params, web preferences and user preferences everybody can customize the site as he likes it to digest once logged in.

Some of the header variants try to fix colors and backgrounds of the other stuff that is in the top according to the background image. Well, that does not success in any case but in most of them and trying to cover every is not worth it if doable at all.

To get the searchbox out of the way I made its position a skin state variable as well. So if you don't want your header art being swapped with the search box input field then just toggle it down and it will be put into the top of the sidebar. Or switch it of completely.

As said before, selecting just an arbitrary header art does interfer heavily with the colors of the style it is combined with. This really bothers me. Maybe I will add an extra style section in the scope of the TWiki render engine so that we can have some IFSKINSTATEs to fix obvious glitches dynamically.

Anyway, try it yourself on the Main.WebHome.


2 Comments

1 AntonAylward replied 1 week, 2 days later

How do you do that?

So how do you make the header art? … reply
1.1 MichaelDaum, 57 minutes later: By adding style variations
First, create a nice header image. To use it in all the layout modes of the NatSkin the image should have an appropriate width, so that it will always fill the screen up to a certain width that you want to support. Currently header images have a dimension of up to 1280x200 pixel. But for example the Subway image is smaller and backs off to pure black to the right being covered by the background html color of the header so that you don't notice that it does not span the complete width in styleborder=off layout mode.

Second, you attach the image to the NatSkin topic.

Third, create a stylesheet named "FooBarVariation.css". Note, it must end on *Variation.css to be recognized as such by the NatSkin. Here's a minimal skeleton:

.natHeaderArt {
  background-image:url(FooBarBar.jpg);
  background-repeat:no-repeat;
  background-position:top left;
}
.natTopBarSizer {
  height:140px;
  max-height:140px;
}

Fourth, attach the FooBarVariation.css to the NatSkin. That's it. From now on you will get it in the TWiki.NatSkinStyleBrowser. Take a look at the stylevariations in pub/TWiki/Natskin/*Variations.css for more examples.

… reply

Leave a Reply

You may have to login or register to comment if you haven't already.
r4 - 04 Sep 2006 - 14:40:41 - Main.MichaelDaum
Copyright © 1999-2012 Michael Daum Consulting. All rights reserved. Impressum.