]> gitweb.factorcode.org Git - factor.git/commitdiff
help.stylesheet: provide a mechanism to adjust the help fonts.
authorJohn Benediktsson <mrjbq7@gmail.com>
Tue, 7 Aug 2012 15:36:16 +0000 (08:36 -0700)
committerJohn Benediktsson <mrjbq7@gmail.com>
Tue, 7 Aug 2012 15:36:16 +0000 (08:36 -0700)
basis/help/stylesheet/stylesheet.factor

index 254b65e5ac177d0a1943f55e95723e2819d9aead..90eb32d841f0f11ec15415237c4926b680714737 100644 (file)
@@ -1,6 +1,7 @@
 ! Copyright (C) 2005, 2009 Slava Pestov.
 ! See http://factorcode.org/license.txt for BSD license.
-USING: colors colors.constants io.styles namespaces ;
+USING: assocs colors colors.constants fry io.styles kernel
+math namespaces sequences ;
 IN: help.stylesheet
 
 SYMBOL: default-span-style
@@ -124,3 +125,12 @@ H{ { table-gap { 10 2 } } } list-style set-global
 
 SYMBOL: bullet
 "• " bullet set-global
+
+: adjust-help-font-size ( delta -- )
+    [
+        font-size
+        {
+            default-span-style title-style heading-style
+            subsection-style snippet-style code-char-style
+        }
+    ] dip '[ get-global [ _ + ] change-at ] with each ;