diff options
author | Ludovic Courtès | 2012-05-17 23:37:43 +0200 |
---|---|---|
committer | Ludovic Courtès | 2012-05-17 23:37:43 +0200 |
commit | 1c445dd093cb6a02289f25324039ce1cba358145 (patch) | |
tree | e420e91ef8345c6918af7133911a58c9746dcfc8 /src/guile/skribilo/package/slide.scm | |
parent | f59dc186a84504715faf141d1d7bcc9e3ca9d2e7 (diff) | |
download | skribilo-1c445dd093cb6a02289f25324039ce1cba358145.tar.gz skribilo-1c445dd093cb6a02289f25324039ce1cba358145.tar.lz skribilo-1c445dd093cb6a02289f25324039ce1cba358145.zip |
Change `define-markup' to generate a macro, to capture location syntactically.
* src/guile/skribilo/lib.scm (dsssl->guile-formals): New procedure,
formerly `fix-rest-arg' procedure in `define-markup'.
(define-markup)[guile-2]: Turn into a macro-generating macro, such
that markups capture their invocation location syntactically.
* src/guile/skribilo/location.scm (source-properties->location): New
procedure.
(invocation-location): Use it.
* src/guile/skribilo/package/base.scm (handle): Move above first use,
since it's now a macro on Guile 2.0.
* src/guile/skribilo/package/slide.scm (slide-vspace): Likewise.
* src/guile/skribilo/package/eq.scm: Use (skribilo package base) instead
of autoloading it.
* tests/Makefile.am (TESTS): Add `location.test'.
* tests/location.test: New file.
Diffstat (limited to 'src/guile/skribilo/package/slide.scm')
-rw-r--r-- | src/guile/skribilo/package/slide.scm | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/src/guile/skribilo/package/slide.scm b/src/guile/skribilo/package/slide.scm index 60e11b0..9ba0692 100644 --- a/src/guile/skribilo/package/slide.scm +++ b/src/guile/skribilo/package/slide.scm @@ -1,7 +1,7 @@ ;;; slide.scm -- Overhead transparencies. ;;; -*- coding: iso-8859-1 -*- ;;; -;;; Copyright 2006, 2007, 2008, 2009 Ludovic Courtès <ludo@gnu.org> +;;; Copyright 2006, 2007, 2008, 2009, 2012 Ludovic Courtès <ludo@gnu.org> ;;; Copyright 2003, 2004 Manuel Serrano ;;; ;;; @@ -52,6 +52,16 @@ (define %slide-the-counter 0) ;*---------------------------------------------------------------------*/ +;* slide-vspace ... */ +;*---------------------------------------------------------------------*/ +(define-markup (slide-vspace :rest opt :key (unit 'cm)) + (new markup + (markup 'slide-vspace) + (loc &invocation-location) + (options `((:unit ,unit) ,@(the-options opt :unit))) + (body (the-body opt)))) + +;*---------------------------------------------------------------------*/ ;* slide ... */ ;*---------------------------------------------------------------------*/ (define-markup (slide :rest opt @@ -152,16 +162,6 @@ (markup 'slide-pause))) ;*---------------------------------------------------------------------*/ -;* slide-vspace ... */ -;*---------------------------------------------------------------------*/ -(define-markup (slide-vspace :rest opt :key (unit 'cm)) - (new markup - (markup 'slide-vspace) - (loc &invocation-location) - (options `((:unit ,unit) ,@(the-options opt :unit))) - (body (the-body opt)))) - -;*---------------------------------------------------------------------*/ ;* slide-embed ... */ ;*---------------------------------------------------------------------*/ (define-markup (slide-embed :rest opt |