summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/guile/skribilo/package/slide.scm8
-rw-r--r--src/guile/skribilo/package/slide/base.scm17
-rw-r--r--src/guile/skribilo/package/slide/html.scm1
3 files changed, 21 insertions, 5 deletions
diff --git a/src/guile/skribilo/package/slide.scm b/src/guile/skribilo/package/slide.scm
index 5a5f73d..380fdc5 100644
--- a/src/guile/skribilo/package/slide.scm
+++ b/src/guile/skribilo/package/slide.scm
@@ -226,9 +226,11 @@
;* slide-topic ... */
;*---------------------------------------------------------------------*/
(define-markup (slide-topic #!rest opt
- #!key (outline? #t) (title "") (ident #f))
+ #!key title (outline? #t)
+ (ident #f) (class "slide-topic"))
(new container
(markup 'slide-topic)
+ (required-options '(:title :outline?))
(ident (or ident (symbol->string (gensym 'slide-topic))))
(options (the-options opt))
(body (the-body opt))))
@@ -237,9 +239,11 @@
;* slide-subtopic ... */
;*---------------------------------------------------------------------*/
(define-markup (slide-subtopic #!rest opt
- #!key (outline? #f) (title "") (ident #f))
+ #!key title (outline? #f)
+ (ident #f) (class "slide-subtopic"))
(new container
(markup 'slide-subtopic)
+ (required-options '(:title :outline?))
(ident (or ident (symbol->string (gensym 'slide-subtopic))))
(options (the-options opt))
(body (the-body opt))))
diff --git a/src/guile/skribilo/package/slide/base.scm b/src/guile/skribilo/package/slide/base.scm
index 8c95881..c8e652c 100644
--- a/src/guile/skribilo/package/slide/base.scm
+++ b/src/guile/skribilo/package/slide/base.scm
@@ -137,7 +137,7 @@
;; Title for the automatically-generated outline slide.
(define %slide-outline-title "")
-;; Circular list of symbols to be passed to `itemize' in pointers.
+;; Circular list of symbols to be passed to `itemize' in outlines.
(define %slide-outline-itemize-symbols
(let loop ((names '(#t "-" "bullet" "->" "middot")))
(if (null? names)
@@ -148,13 +148,14 @@
(loop (cdr names))))))
-(define (make-topic-slide topic engine)
+(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))))
(output (slide :title %slide-outline-title :toc #f
+ :class (markup-option topic :class)
;; The mark below is needed for cross-referencing by PDF
;; bookmarks.
(if (markup-ident topic) (mark (markup-ident topic)) "")
@@ -164,9 +165,19 @@
(markup-writer 'slide-topic (find-engine 'base)
+ :options '(:title :outline? :class :ident)
:action (lambda (n e)
(if (markup-option n :outline?)
- (make-topic-slide n e))
+ (make-outline-slide n e))
+
+ (output (markup-body n) e)))
+
+(markup-writer 'slide-subtopic (find-engine 'base)
+ ;; FIXME: Largely untested.
+ :options '(:title :outline? :class :ident)
+ :action (lambda (n e)
+ (if (markup-option n :outline?)
+ (make-outline-slide n e))
(output (markup-body n) e)))
diff --git a/src/guile/skribilo/package/slide/html.scm b/src/guile/skribilo/package/slide/html.scm
index ef2642b..d47ef82 100644
--- a/src/guile/skribilo/package/slide/html.scm
+++ b/src/guile/skribilo/package/slide/html.scm
@@ -110,6 +110,7 @@
;;;
(markup-writer 'slide-topic (find-engine 'html)
+ :options '(:title :outline? :class :ident)
:action (lambda (n e)
(let ((title (markup-option n :title))
(body (markup-body n)))