From 219a3a4a408ed91105ff9dd05b390f90190f17c1 Mon Sep 17 00:00:00 2001 From: Slava Pestov Date: Fri, 7 Mar 2008 02:28:45 -0600 Subject: [PATCH] Fix style nesting bug in help --- extra/help/markup/markup.factor | 6 +++--- extra/help/stylesheet/stylesheet.factor | 8 ++++++-- 2 files changed, 9 insertions(+), 5 deletions(-) mode change 100644 => 100755 extra/help/stylesheet/stylesheet.factor diff --git a/extra/help/markup/markup.factor b/extra/help/markup/markup.factor index 32e29db7db..d81e9cd81e 100755 --- a/extra/help/markup/markup.factor +++ b/extra/help/markup/markup.factor @@ -1,4 +1,4 @@ -! Copyright (C) 2005, 2007 Slava Pestov. +! Copyright (C) 2005, 2008 Slava Pestov. ! See http://factorcode.org/license.txt for BSD license. USING: arrays definitions generic io kernel assocs hashtables namespaces parser prettyprint sequences strings io.styles @@ -42,9 +42,9 @@ M: f print-element drop ; [ print-element ] with-style ; : with-default-style ( quot -- ) - default-style get [ + default-span-style get [ last-element off - default-style get swap with-nesting + default-block-style get swap with-nesting ] with-style ; inline : print-content ( element -- ) diff --git a/extra/help/stylesheet/stylesheet.factor b/extra/help/stylesheet/stylesheet.factor old mode 100644 new mode 100755 index 3c5271d381..945d9a4ce1 --- a/extra/help/stylesheet/stylesheet.factor +++ b/extra/help/stylesheet/stylesheet.factor @@ -3,13 +3,17 @@ USING: io.styles namespaces ; IN: help.stylesheet -SYMBOL: default-style +SYMBOL: default-span-style H{ { font "sans-serif" } { font-size 12 } { font-style plain } +} default-span-style set-global + +SYMBOL: default-block-style +H{ { wrap-margin 500 } -} default-style set-global +} default-block-style set-global SYMBOL: link-style H{