aboutsummaryrefslogtreecommitdiffhomepage
path: root/lib/sisu/v3/sysenv.rb
diff options
context:
space:
mode:
authorRalph Amissah <ralph@amissah.com>2011-10-03 21:09:09 -0400
committerRalph Amissah <ralph@amissah.com>2011-10-03 21:09:11 -0400
commit7fb6acc0702e4e6a05390be063d433b088d9cc0d (patch)
tree8b3e35532b5909f4da9617415d0712cb415af2e3 /lib/sisu/v3/sysenv.rb
parentv3: defaults, (sisu) home page, link to git repo, minor fixes (diff)
v3: texpdf, fonts, Liberation series default (main: Sans, mono: Mono)
* (mono) improved with selection of Liberation Mono as default * font (main font, mono) configurable in sisurc.yml under default: (texpdf_font:|texpdf_font_mono:) or within document under @make: (:texpdf_font:|:texpdf_font_mono:)
Diffstat (limited to 'lib/sisu/v3/sysenv.rb')
-rw-r--r--lib/sisu/v3/sysenv.rb29
1 files changed, 25 insertions, 4 deletions
diff --git a/lib/sisu/v3/sysenv.rb b/lib/sisu/v3/sysenv.rb
index 9d4fa887..aaf210e0 100644
--- a/lib/sisu/v3/sysenv.rb
+++ b/lib/sisu/v3/sysenv.rb
@@ -1529,10 +1529,31 @@ WOK
end
def font
def texpdf
- (defined? @rc['default']['texpdf_font']) \
- && (@rc['default']['texpdf_font']=~/\S{3,}/) \
- ? @rc['default']['texpdf_font']
- : 'Liberation Sans' #'Liberation Sans' #'Liberation Serif'
+ def main
+ (defined? @rc['default']['texpdf_font']) \
+ && (@rc['default']['texpdf_font']=~/\S{3,}/) \
+ ? @rc['default']['texpdf_font']
+ : 'Liberation Sans'
+ end
+ def sans # not used
+ (defined? @rc['default']['texpdf_font_sans']) \
+ && (@rc['default']['texpdf_font_sans']=~/\S{3,}/) \
+ ? @rc['default']['texpdf_font_sans']
+ : 'Liberation Sans'
+ end
+ def serif # not used
+ (defined? @rc['default']['texpdf_font_serif']) \
+ && (@rc['default']['texpdf_font_serif']=~/\S{3,}/) \
+ ? @rc['default']['texpdf_font_serif']
+ : 'Liberation Serif'
+ end
+ def mono
+ (defined? @rc['default']['texpdf_font_mono']) \
+ && (@rc['default']['texpdf_font_mono']=~/\S{3,}/) \
+ ? @rc['default']['texpdf_font_mono']
+ : 'Liberation Mono'
+ end
+ self
end
self
end