[dw-nonfree] Sunday Morning & Skittlish Dreams: changing the sidebar width fails and/or causes w
[commit: http://hg.dwscoalition.org/dw-nonfree/rev/1855a52913b5]
http://bugs.dwscoalition.org/show_bug.cgi?id=3003
Make sidebar width work right when adjusted. Also, don't make the background
image padding rely on the sidebar width, since these are separate
measurements.
Patch by
ninetydegrees.
Files modified:
http://bugs.dwscoalition.org/show_bug.cgi?id=3003
Make sidebar width work right when adjusted. Also, don't make the background
image padding rely on the sidebar width, since these are separate
measurements.
Patch by
![[personal profile]](https://www.dreamwidth.org/img/silk/identity/user.png)
Files modified:
- bin/upgrading/s2layers/sundaymorning/layout.s2
-------------------------------------------------------------------------------- diff -r 95c4ad611e5b -r 1855a52913b5 bin/upgrading/s2layers/sundaymorning/layout.s2 --- a/bin/upgrading/s2layers/sundaymorning/layout.s2 Wed Oct 27 13:55:00 2010 +0800 +++ b/bin/upgrading/s2layers/sundaymorning/layout.s2 Wed Oct 27 14:37:23 2010 +0800 @@ -245,6 +245,10 @@ function Page::print() } function Page::print_default_stylesheet() { + + var int sidebarw = int($*sidebar_width); + var string wrap_margin = $sidebarw + 60 + "px"; + var string sidebar_position = ""; var string sidebar_position_alt = ""; var string image_background_page_position = "100% 70px"; @@ -367,21 +371,21 @@ q { font-style: italic; #wrap { $page_colors - padding-$sidebar_position_alt: $*sidebar_width; + padding-$sidebar_position_alt: 200px; /* Fixed: to display the bkg image */ padding-top: 10px; } .one-column #wrap { margin-left: 2em; + margin-right: 2em; } .two-columns #wrap { - margin-$sidebar_position: 250px; + margin-$sidebar_position: $wrap_margin; } #content { width: 100%; - margin-$sidebar_position: 10px; z-index: 20; } @@ -399,17 +403,15 @@ q { font-style: italic; .module-section-two { width: $*sidebar_width; - max-width: 220px; + max-width: $*sidebar_width; height: 200px; $module_base_colors - padding-$sidebar_position_alt: 5px; } .two-columns .module-section-two { position: absolute; $sidebar_position: 2em; top: 8em; - margin-$sidebar_position_alt: -230px; } .module-section-one ul { @@ -421,10 +423,14 @@ q { font-style: italic; .one-column .module-section-one ul { margin-left: 2em; + padding-left: 0; + padding-right: 0; } .two-columns .module-section-one ul { - margin-$sidebar_position: 250px; + margin-$sidebar_position: $wrap_margin; + padding-left: 0; + padding-right: 0; } .two-columns-right .module-section-one ul { --------------------------------------------------------------------------------