diff options
author | Ludovic Courtès | 2007-11-15 16:11:46 +0100 |
---|---|---|
committer | Ludovic Courtès | 2007-11-15 16:11:46 +0100 |
commit | 0c26136279ec0f360483fa4a347ff3383a57401d (patch) | |
tree | 9035df1b6ecbb83f865e10ea78e11cbbabfdb8d9 /src | |
parent | 925c7dc89981ca88ee0bcea73c28668338beece9 (diff) | |
download | skribilo-0c26136279ec0f360483fa4a347ff3383a57401d.tar.gz skribilo-0c26136279ec0f360483fa4a347ff3383a57401d.tar.lz skribilo-0c26136279ec0f360483fa4a347ff3383a57401d.zip |
slide: Add `:unfold?' option to `slide-topic'.
* doc/user/slide.skb: Update.
* src/guile/skribilo/package/slide.scm (slide-topic,
slide-subtopic)[:unfold?]: New argument.
* src/guile/skribilo/package/slide/base.scm (make-outline-slide): Honor
`:unfold?'.
(slide-topic, slide-subtopic): Mark `:unfold?' as supported.
Diffstat (limited to 'src')
-rw-r--r-- | src/guile/skribilo/package/slide.scm | 8 | ||||
-rw-r--r-- | src/guile/skribilo/package/slide/base.scm | 17 |
2 files changed, 14 insertions, 11 deletions
diff --git a/src/guile/skribilo/package/slide.scm b/src/guile/skribilo/package/slide.scm index 2f5d8a8..3195515 100644 --- a/src/guile/skribilo/package/slide.scm +++ b/src/guile/skribilo/package/slide.scm @@ -251,7 +251,7 @@ ;* slide-topic ... */ ;*---------------------------------------------------------------------*/ (define-markup (slide-topic :rest opt - :key title (outline? #t) + :key title (outline? #t) (unfold? #t) (ident #f) (class #f)) (new container (markup 'slide-topic) @@ -260,14 +260,15 @@ (class class) (loc &invocation-location) (options `((:outline? ,outline?) - ,@(the-options opt :outline? :class))) + (:unfold? ,unfold?) + ,@(the-options opt :outline? :unfold? :class))) (body (the-body opt)))) ;*---------------------------------------------------------------------*/ ;* slide-subtopic ... */ ;*---------------------------------------------------------------------*/ (define-markup (slide-subtopic :rest opt - :key title (outline? #f) + :key title (outline? #f) (unfold? #f) (ident #f) (class #f)) (new container (markup 'slide-subtopic) @@ -276,6 +277,7 @@ (class class) (loc &invocation-location) (options `((:outline? ,outline?) + (:unfold? ,unfold?) ,@(the-options opt :outline? :class))) (body (the-body opt)))) diff --git a/src/guile/skribilo/package/slide/base.scm b/src/guile/skribilo/package/slide/base.scm index 2532221..f2d0209 100644 --- a/src/guile/skribilo/package/slide/base.scm +++ b/src/guile/skribilo/package/slide/base.scm @@ -148,23 +148,24 @@ (define (make-outline-slide topic engine) - (let ((parent-topic (if (is-markup? topic 'slide-topic) - topic - (find1-up (lambda (n) - (is-markup? n 'slide-topic)) - topic)))) + (let* ((parent-topic (if (is-markup? topic 'slide-topic) + topic + (find1-up (lambda (n) + (is-markup? n 'slide-topic)) + topic))) + (unfold? (markup-option topic :unfold?))) (output (slide :title %slide-outline-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 #t + (p (make-topic-list parent-topic unfold? make-topic-entry))) engine))) (markup-writer 'slide-topic (find-engine 'base) - :options '(:title :outline? :class :ident) + :options '(:title :outline? :class :ident :unfold?) :action (lambda (n e) (if (markup-option n :outline?) (make-outline-slide n e)) @@ -173,7 +174,7 @@ (markup-writer 'slide-subtopic (find-engine 'base) ;; FIXME: Largely untested. - :options '(:title :outline? :class :ident) + :options '(:title :outline? :class :ident :unfold?) :action (lambda (n e) (if (markup-option n :outline?) (make-outline-slide n e)) |