fu: Close-up of Fu, bringing a scoop of water to her mouth (Default)
fu ([personal profile] fu) wrote in [site community profile] changelog2010-09-04 09:45 am

[dw-free] Refried Tablet: custom colors on Reading page not working

[commit: http://hg.dwscoalition.org/dw-free/rev/dee65e4f7923]

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

Treat the custom reading page colors template as CSS, not as normal text, so
that we don't run into any trouble if there are newlines in there.

Patch by [personal profile] fu.

Files modified:
  • bin/upgrading/s2layers/core2.s2
  • bin/upgrading/s2layers/refriedtablet/layout.s2
--------------------------------------------------------------------------------
diff -r fcf85d9cf6a0 -r dee65e4f7923 bin/upgrading/s2layers/core2.s2
--- a/bin/upgrading/s2layers/core2.s2	Thu Sep 02 22:07:27 2010 +0800
+++ b/bin/upgrading/s2layers/core2.s2	Sat Sep 04 17:44:59 2010 +0800
@@ -1903,6 +1903,7 @@ property string custom_colors_template {
            Each CSS rule should begin with %%new%%";
     example = "%%new%% div.special {border: 1px dotted %%background%%; font-size: 120%; color: %%foreground%%}";
     noui = 1;
+    string_mode = "css";
     }
 
 set custom_foreground_element = "";
diff -r fcf85d9cf6a0 -r dee65e4f7923 bin/upgrading/s2layers/refriedtablet/layout.s2
--- a/bin/upgrading/s2layers/refriedtablet/layout.s2	Thu Sep 02 22:07:27 2010 +0800
+++ b/bin/upgrading/s2layers/refriedtablet/layout.s2	Sat Sep 04 17:44:59 2010 +0800
@@ -12,8 +12,7 @@ set layout_authors = [ { "name" => "zvi"
 ##===============================
 
 set use_custom_friend_colors = true;
-set custom_colors_template =  "%%new%% .userpic img { border-color: %%background%% %%foreground%%; border: 1px solid;
-}";
+set custom_colors_template =  "%%new%% .userpic img { border-color: %%background%% %%foreground%%; border: 1px solid;} ";
 
 ##===============================
 ## Journal style - colors
--------------------------------------------------------------------------------