;;;;
;;;; source file of the GNU LilyPond music typesetter
;;;;
-;;;; (c) 1998--2004 Jan Nieuwenhuizen <janneke@gnu.org>
+;;;; (c) 1998--2005 Jan Nieuwenhuizen <janneke@gnu.org>
;;;; Han-Wen Nienhuys <hanwen@cs.uu.nl>
-;; (debug-enable 'backtrace)
-
;; The public interface is tight.
;; It has to be, because user-code is evalled with this module.
;; JUNK this -- see lily.scm: ly:all-output-backend-commands
#:export (unknown
blank
+ circle
dot
white-dot
beam
round-filled-box
text
white-text
+ setcolor
+ resetcolor
polygon
draw-line
no-origin
(define (unknown)
"%\n\\unknown\n")
-
+(define (url-link url x y)
+ "")
(define (blank)
"")
+(define (circle radius thick)
+ (embedded-ps (list 'circle radius thick)))
+
(define (dot x y radius)
(embedded-ps (list 'dot x y radius)))
-
(define (embedded-ps string)
(embedded-ps (list 'embedded-ps string)))
(define (white-text scale s)
(embedded-ps (list 'white-text scale s)))
+(define (setcolor r g b)
+ (string-append "\\color[rgb]{"
+ (number->string r) ", "
+ (number->string g) ", "
+ (number->string b) "}"))
+
+;; FIXME
+;; The PostScript backend saves the current color
+;; during setcolor and restores it during resetcolor.
+;; We don't do that here.
+(define (resetcolor)
+ (string-append "\\color[rgb]{0,0,0}\n"))
+
(define (polygon points blotdiameter)
(embedded-ps (list 'polygon `(quote ,points) blotdiameter)))