diff options
-rw-r--r-- | NEWS | 5 | ||||
-rw-r--r-- | doc/user/slide.skb | 21 | ||||
-rw-r--r-- | src/guile/skribilo/package/slide.scm | 4 | ||||
-rw-r--r-- | src/guile/skribilo/package/slide/base.scm | 26 |
4 files changed, 41 insertions, 15 deletions
@@ -20,6 +20,11 @@ These harmless warnings looked like: WARNING: (skribilo ast): imported module (srfi srfi-34) overrides core binding `raise' +** The `slide' package supports additional customs + +Namely, `slide-outline-title' and +`slide-outline-{active,inactive}-color'. See manual for details. + * New in Skribilo 0.9.0 (user-visible changes compared to Skribe 1.2d) diff --git a/doc/user/slide.skb b/doc/user/slide.skb index cb411ab..fa1534f 100644 --- a/doc/user/slide.skb +++ b/doc/user/slide.skb @@ -122,7 +122,21 @@ different subtopics, as well as the titles of the slides under the current subtopic.]) (:unfold? [If ,(code [#t]), then the outline will also show the contents of the current subtopic.])) - :source "skribilo/package/slide.scm")) + :source "skribilo/package/slide.scm") + + (p [This package understands the following additional customs (see +Section ,(ref :subsection "Engine Customs" :page #t)): + +,(description + (item :key (tt [slide-outline-title]) + [The title of outline slides. By default, no title is +produced.]) + (item :key (tt [slide-outline-active-color]) + [The color in which the current slide topic is displayed in +outline slides.]) + (item :key (tt [slide-outline-inactive-color]) + [The color in which inactive slide topics are displayed in +outline slides.]))])) ;*---------------------------------------------------------------------*/ ;* slide-pause */ @@ -208,3 +222,8 @@ output format does not support embedded application.])) ;; Show only the example (i.e. don't produce a document in a document) (example :legend "Example of Skribilo slides" (prgm :file "src/slides.skb"))))) + +;;; Local Variables: +;;; coding: latin-1 +;;; ispell-local-dictionary: "american" +;;; End: diff --git a/src/guile/skribilo/package/slide.scm b/src/guile/skribilo/package/slide.scm index 5a62a20..86cfb90 100644 --- a/src/guile/skribilo/package/slide.scm +++ b/src/guile/skribilo/package/slide.scm @@ -1,7 +1,7 @@ ;;; slide.scm -- Overhead transparencies. ;;; +;;; Copyright 2006, 2007, 2008 Ludovic Courtès <ludo@gnu.org> ;;; Copyright 2003, 2004 Manuel Serrano -;;; Copyright 2006, 2007 Ludovic Courtès <ludo@gnu.org> ;;; ;;; ;;; This program is free software; you can redistribute it and/or modify @@ -288,8 +288,6 @@ ;;; Initialization. ;;; -(format (current-error-port) "Slides initializing...~%") - ;; Register specific implementations for lazy loading. (when-engine-is-loaded 'base (lambda () diff --git a/src/guile/skribilo/package/slide/base.scm b/src/guile/skribilo/package/slide/base.scm index f2d0209..45657c5 100644 --- a/src/guile/skribilo/package/slide/base.scm +++ b/src/guile/skribilo/package/slide/base.scm @@ -1,7 +1,7 @@ ;;; base.scm -- Overhead transparencies, `base' engine. ;;; +;;; Copyright 2006, 2008 Ludovic Courtès <ludo@gnu.org> ;;; Copyright 2003, 2004 Manuel Serrano -;;; Copyright 2006 Ludovic Courtès <ludovic.courtes@laas.fr> ;;; ;;; ;;; This program is free software; you can redistribute it and/or modify @@ -31,7 +31,7 @@ :use-module (srfi srfi-1) - :export (%slide-outline-title %slide-outline-itemize-symbols)) + :export (%slide-outline-itemize-symbols)) (fluid-set! current-reader %skribilo-module-reader) @@ -119,12 +119,16 @@ (make-entry-proc t current-topic)) %slide-outline-itemize-symbols))) -(define (make-topic-entry topic current-topic) +(define (make-topic-entry topic current-topic engine) ;; Produce an entry for `topic'. Colorize it based on the fact ;; that the current topic is `current-topic' (it may need to be ;; hightlighted). - (let ((current? (eq? topic current-topic))) - (color :fg (if current? "#000000" "#666666") + (let ((current? (eq? topic current-topic)) + (active (or (engine-custom engine 'slide-outline-active-color) + "#000000")) + (inactive (or (engine-custom engine 'slide-outline-inactive-color) + "#666666"))) + (color :fg (if current? active inactive) (apply (if current? bold (lambda (x) x)) (list (markup-option topic :title)))))) @@ -133,9 +137,6 @@ ;;; Default topic/subtopic handling. ;;; -;; Title for the automatically-generated outline slide. -(define %slide-outline-title "") - ;; Circular list of symbols to be passed to `itemize' in outlines. (define %slide-outline-itemize-symbols (let loop ((names '(#t "-" "bullet" "->" "middot"))) @@ -153,14 +154,17 @@ (find1-up (lambda (n) (is-markup? n 'slide-topic)) topic))) - (unfold? (markup-option topic :unfold?))) - (output (slide :title %slide-outline-title :toc #f + (unfold? (markup-option topic :unfold?)) + (title (or (engine-custom engine 'slide-outline-title) ""))) + (output (slide :title title :toc #f :class (markup-class topic) ;; The mark below is needed for cross-referencing by PDF ;; bookmarks. (if (markup-ident topic) (mark (markup-ident topic)) "") (p (make-topic-list parent-topic unfold? - make-topic-entry))) + (lambda (topic current) + (make-topic-entry topic current + engine))))) engine))) |