A new theme from Sarcasmo, and fondue's ever growing collection of E2 Themes are impressive. We should have them in the system.

but...

It's a lot of work right now to impliment a new theme. I should be able to use HTML from jukka container, replacing things like image URLs and colors as needed -- as well as style sheets, and body and table tag attributes...

An Extremely Brief Tutorial on Everything Themeability

Everything's themeability requires that a developer use the settings in the theme or themesettings nodes. Best way to Theme-ify is to reuse the containers, but add new color schemes or graphics:

Examples:

  • classic theme -- the basic, horrible design that E2 started out on
  • classic theme water settings
  • classic theme wired settings
  • classic theme goth settings
  • classic theme charred settings

    The way themesettings work -- they have a "parent theme" value. When this themesetting is selected as a theme, its settings override the parent's, and are available for developers in the $THEME hashref.

    UPDATE -- N-Wing said that the users should be able to override $THEME settings directly, and indeed they can. If there is a setting in $VARS such as $$VARS{themenodeletTitleColor}, that automatically will appear as $$THEME{nodeletTitleColor} -- therefore a user can specify settings (if you build a form which lets them do so)
    $THEME variables work like so:

       7:  <TD bgcolor=[%
       8:    return $$THEME{nodeletTitleColor} if $$THEME{nodeletTitleColor};
       9:     "#CC99FF";
      10:   %]>
    
    from nodelet container

    This builds a table-cell tag for the classic theme's nodelets. The theme variable $$THEME{nodeletTitleColor} specifies the color. If it doesn't #CC99FF is used.

    Nate Hangs his Head

    When I was coding up the e2 jukka theme (and associated pieces -- check out the theme's node) I hard coded many of the images. Colors too. And the nodelet's title image isn't sensitive to $THEME settings. I was in a hurry.

    The Assignment

    If I wanted to take Sarcasmo's theme
    http://www.junktext.com/everything/index.html

    and turn it into Sarcasmo's Hacker Theme (a themesetting based on e2 jukka theme) what would I need to do?

    Quest: replacing hard coded components with $THEME values

    The most devpoints will be awarded for solutions that:

    1. Can isolate differences between the target theme and the current E2 source
    2. Give the code snippets and the source nodes that generate the part that needs to be modified
    3. Have ideas on how make the theme more flexible for future settings

    Feel free to invent new $THEME fields.
    Example: using $THEME->{nodeletIcon_NODELETNAME} to store img url's would allow a new setting to change the nodelet title images.

    Questions, Problems, or moral outrage? /msg nate

  • Log in or registerto write something here or to contact authors.