[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

'mm' scaling value on top-level

From: Werner LEMBERG
Subject: 'mm' scaling value on top-level
Date: Tue, 28 Sep 2021 13:14:58 +0000 (UTC)


This is a comment of mine from !929:


The change to enable pairs [in `#(set-default-paper-size)`] is almost

--- a/scm/paper.scm
+++ b/scm/paper.scm
@@ -314,7 +314,9 @@ unless explicitly overridden in the name."
 (define (internal-set-paper-size module name landscape?)
-  (let* ((entry (lookup-paper-name module name landscape?))
+  (let* ((entry (if (pair? name)
+                    name
+                    (lookup-paper-name module name landscape?)))
          (is-paper? (module-defined? module 'is-paper)))
      ((not is-paper?)

Using it with

#(set-default-paper-size (cons 100 50)))

works like a charm.  However, code like

#(set-default-paper-size (cons (* 100 mm) (* 50 mm)))

doesn't work; I get the error message

error: GUILE signaled an error for the expression beginning here
 (set-default-paper-size (cons (* 100 mm) (* 50 mm)))
Unbound variable: mm

What must I do to make 'mm' and similar dimension scale values
available at the top level?


I guess not everyone is reading the MR tracker stuff, so I ask here
directly.  Any help is greatly appreciated.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]