mark: A photo of Mark kneeling on top of the Taal Volcano in the Philippines. It was a long hike. (Default)
Mark Smith ([staff profile] mark) wrote in [site community profile] changelog2009-08-11 06:11 am

[dw-nonfree] Font properties in the wizard

[commit: http://hg.dwscoalition.org/dw-nonfree/rev/b6821c013ce5]

http://bugs.dwscoalition.org/show_bug.cgi?id=1283

Add font properties for wizard for Transmogrified.

Patch by [personal profile] av8rmike.

Files modified:
  • bin/upgrading/s2layers/transmogrified/layout.s2
--------------------------------------------------------------------------------
diff -r 4a8a8dd39c49 -r b6821c013ce5 bin/upgrading/s2layers/transmogrified/layout.s2
--- a/bin/upgrading/s2layers/transmogrified/layout.s2	Tue Aug 11 06:02:30 2009 +0000
+++ b/bin/upgrading/s2layers/transmogrified/layout.s2	Tue Aug 11 06:11:09 2009 +0000
@@ -234,13 +234,21 @@ set image_background_module_url = "";
 
 
 # Fonts
-property string font_size { des = "Font size"; noui = 1; }
-property string font_sidebar_title_size { des = "Font size of sidebar titles"; noui = 1; }
+property use font_base;
+property use font_fallback;
+property use font_base_size;
+property use font_base_units;
+property use font_module_heading;
+property use font_module_heading_size;
+property use font_module_heading_units;
 
 set font_base = "Verdana";
-set font_fallback = "Sans Serif";
-set font_size = "10pt";
-set font_sidebar_title_size = "1.1em";
+set font_fallback = "sans-serif";
+set font_base_size = "10";
+set font_base_units = "pt";
+set font_module_heading = "";
+set font_module_heading_size = "1.1";
+set font_module_heading_units = "em";
 
 propgroup customcss {
     property use external_stylesheet;
@@ -323,6 +331,9 @@ function Page::print_default_stylesheet 
     var string page_link_hover_colors = generate_color_css($*color_page_link_hover, new Color, new Color);
     var string page_link_visited_colors = generate_color_css($*color_page_link_visited, new Color, new Color);
 
+    var string page_font = generate_font_css($*font_base, $*font_fallback, $*font_base_size, $*font_base_units);
+    var string module_title_font = generate_font_css($*font_module_heading, $*font_fallback, $*font_module_heading_size, $*font_module_heading_units);
+
     var string userpic_css = "";
     if($*userpics_position == "left") {
          $userpic_css = """.entry-title, .comment-title {margin: 0; } 
@@ -348,8 +359,7 @@ function Page::print_default_stylesheet 
 
     body {
         background-color: $*color_page_background;
-        font-family: $*font_base , $*font_fallback;
-        font-size: $*font_size;
+        $page_font
         margin: 0;
         padding: 0;
     }
@@ -480,7 +490,7 @@ function Page::print_default_stylesheet 
     .module-section-two h2 {
 		margin: 0;
         margin-bottom: 7px;
-		font-size: $*font_sidebar_title_size;
+		$module_title_font
 		padding: 0.2em;
 		background-color: $*color_module_title_background;
 		color: $*color_module_title;
@@ -862,7 +872,7 @@ function Page::print_default_stylesheet 
         font-weight: bold;
     }
     #archive-month .entry-title {
-        font-size: $*font_size;
+        font-size: $*font_base_size$*font_base_units;
         display: inline-block;
         padding-left: 5px;
     }
--------------------------------------------------------------------------------