Difference between revisions of "S2 Cookbook: Blank Layout and Theme Layers"
From Dreamwidth Notes
Foxfirefey (Talk | contribs) m |
Foxfirefey (Talk | contribs) m |
||
Line 1: | Line 1: | ||
== Layout == | == Layout == | ||
+ | |||
+ | This layout will print out the base HTML of core2, with a blank stylesheet function. | ||
<syntaxhighlight lang="s2">layerinfo "type" = "layout"; | <syntaxhighlight lang="s2">layerinfo "type" = "layout"; |
Revision as of 05:22, 12 June 2011
Layout
This layout will print out the base HTML of core2, with a blank stylesheet function.
layerinfo "type" = "layout"; # put the layout's name here layerinfo "name" = ""; # put your username here layerinfo "author_name" = ""; # makes it so others can preview your layout and see its source layerinfo "is_public" = 1; layerinfo "source_viewable" = 1; # add propgroups: presentation, colors, fonts, images, modules, customcss, text # Tabula Rasa source is a good example: http://www.dreamwidth.org/customize/advanced/layersource?id=551 # this is the function that prints out the stylesheet of the layout function Page::print_default_stylesheet() { }
Themes
If you want to override an existing layout's CSS using a theme layer:
layerinfo "type" = "theme"; # put the theme's name here layerinfo "name" = ""; # put your username here layerinfo "author_name" = ""; # makes it so others can preview your theme and see its source layerinfo "is_public" = 1; layerinfo "source_viewable" = 1; # this is the function that prints out theme specific CSS function Page::function print_theme_stylesheet() { }
If you want to redo a theme's CSS entirely from scratch:
layerinfo "type" = "theme"; # put the theme's name here layerinfo "name" = ""; # put your username here layerinfo "author_name" = ""; # makes it so others can preview your theme and see its source layerinfo "is_public" = 1; layerinfo "source_viewable" = 1; # this overrides the layout's stylesheet CSS function Page::print_default_stylesheet() { }
If you are just creating a plan theme for your layout, use this:
layerinfo "type" = "theme"; # put the theme's name here layerinfo "name" = ""; # put your username here layerinfo "author_name" = ""; # makes it so others can preview your theme and see its source layerinfo "is_public" = 1; layerinfo "source_viewable" = 1;