aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorLudovic Court`es2007-04-04 16:22:32 +0000
committerLudovic Court`es2007-04-04 16:22:32 +0000
commit23f211f16da7d70fd2049bcc5f3565ca6602c81f (patch)
tree4f4d6678ca2acf7a428f82ea8437cfab75ee53f9 /src
parenta619f2d4c984af86bac0fdf8deb26ad7d72faaca (diff)
downloadskribilo-23f211f16da7d70fd2049bcc5f3565ca6602c81f.tar.gz
skribilo-23f211f16da7d70fd2049bcc5f3565ca6602c81f.tar.lz
skribilo-23f211f16da7d70fd2049bcc5f3565ca6602c81f.zip
`eq' package: Properly handle auto-inlining.
* src/guile/skribilo/package/eq.scm (inline-equation?): Use `find1-up' instead of `find-up'. This fixes a bug. (eq): Properly pass the `:inline?' options through the `options' slot. * src/guile/skribilo/package/eq/lout.scm (eq): When inline, enclose equation in `@OneRow @OneCol' so that it is not breakable. git-archimport-id: lcourtes@laas.fr--2006-libre/skribilo--devo--1.2--patch-46
Diffstat (limited to 'src')
-rw-r--r--src/guile/skribilo/package/eq.scm12
-rw-r--r--src/guile/skribilo/package/eq/lout.scm2
2 files changed, 7 insertions, 7 deletions
diff --git a/src/guile/skribilo/package/eq.scm b/src/guile/skribilo/package/eq.scm
index 7ad39d8..8b4d325 100644
--- a/src/guile/skribilo/package/eq.scm
+++ b/src/guile/skribilo/package/eq.scm
@@ -19,7 +19,7 @@
;;; USA.
(define-module (skribilo package eq)
- :autoload (skribilo ast) (markup? find-up)
+ :autoload (skribilo ast) (markup? find1-up)
:autoload (skribilo output) (output)
:use-module (skribilo writer)
:use-module (skribilo engine)
@@ -124,9 +124,9 @@ a symbol representing the mathematical operator denoted by @var{m} (e.g.,
(let ((i (markup-option m :inline?)))
(case i
((auto)
- (not (find-up (lambda (n)
- (is-markup? n 'eq-display))
- m)))
+ (not (find1-up (lambda (n)
+ (is-markup? n 'eq-display))
+ m)))
((#t) #t)
(else #f)))))
@@ -217,9 +217,9 @@ a symbol representing the mathematical operator denoted by @var{m} (e.g.,
(class class)
(loc &invocation-location)
(options `((:div-style ,div-style) (:align-with ,align-with)
- (:mul-style ,mul-style)
+ (:mul-style ,mul-style) (:inline? ,inline?)
,@(the-options opts
- :ident :class
+ :ident :class :inline?
:div-style :mul-style :align-with)))
(body (let loop ((body (the-body opts))
(result '()))
diff --git a/src/guile/skribilo/package/eq/lout.scm b/src/guile/skribilo/package/eq/lout.scm
index 5633ae4..d0d9570 100644
--- a/src/guile/skribilo/package/eq/lout.scm
+++ b/src/guile/skribilo/package/eq/lout.scm
@@ -66,7 +66,7 @@
"\n@IAD " ""))))
:action (lambda (node engine)
(display (if (inline-equation? node)
- "@E { "
+ "@OneRow @OneCol @E { "
"@Eq { "))
(let ((eq (markup-body node)))
;;(fprint (current-error-port) "eq=" eq)