From c0152d256b48b17b4b51f7913214e1291e061070 Mon Sep 17 00:00:00 2001 From: Ludovic Courtès Date: Sat, 7 Apr 2018 16:22:17 +0200 Subject: doc: Improve Lout style. * doc/modules/skribilo/documentation/api.scm (le): Change 'initial-font and 'initial-break. Use 9p font in @SkribiloExample. Add writer for 'prog. --- doc/modules/skribilo/documentation/api.scm | 17 +++++++++++++++-- 1 file changed, 15 insertions(+), 2 deletions(-) (limited to 'doc/modules') diff --git a/doc/modules/skribilo/documentation/api.scm b/doc/modules/skribilo/documentation/api.scm index 46f1d14..73c8a43 100644 --- a/doc/modules/skribilo/documentation/api.scm +++ b/doc/modules/skribilo/documentation/api.scm @@ -2,7 +2,7 @@ ;;; -*- coding: iso-8859-1 -*- ;;; ;;; Copyright 2005, 2006, 2007, 2008, 2009, 2012, -;;; 2015 Ludovic Courtès +;;; 2015, 2018 Ludovic Courtès ;;; Copyright 2003, 2004 Manuel Serrano ;;; ;;; @@ -92,6 +92,13 @@ ;*---------------------------------------------------------------------*/ (let ((le (find-engine 'lout))) + (engine-custom-set! le 'initial-font "Palatino Base 11p") + + ;; XXX: Adding 'marginkerning' makes Lout 3.40 segfault. + (engine-custom-set! le 'initial-break + "unbreakablefirst unbreakablelast \ +hyphen adjust 1.3fx") + (let ((defs (engine-custom le 'inline-definitions-proc))) (engine-custom-set! le 'inline-definitions-proc (lambda (e) @@ -115,13 +122,19 @@ def @SkribiloExample named @Title {} right x { @Diag { @CurveBox outlinestyle { noline } paint { rgb 0.95 0.95 0.87 } - font { 0.9f } + font { 9p } break { 0.9fx } @HExpand @Body } } { x } }\n\n" )))) + ;; Compared to the default 'prog' writer, this one uses a smaller font. + (markup-writer 'prog le + :options '(:line :mark) + :before "\n{ Courier Base 9p } @Font { lines nohyphen 0.9fx } @Break lout @Space {\n" + :after "\n} # @Break\n") + (markup-writer 'doc-markup :action (lambda (n e) (let ((protos (markup-option n 'prototypes)) -- cgit v1.2.3