\font\fetanumber = feta-nummer12
\font\fetafinger = feta-nummer5
\font\fetadyn = feta-din10 scaled \magstep 2
+\font\title = cmbx12 scaled \magstep 4
+\font\subtitle = cmr9
-\def\setchar#1#2{\hbox to\charwidth{\hss{#1\char#2}}}
+\def\lilyfooter{Lily was here, 1.1.0}
+\def\setchar#1#2{\hbox to\charwidth{\hss{#1\char#2}\hss}}
\def\charsperline{6}
\def\charheight{55pt}
\loop\ifnum\n<#3
\advance\n by\charsperline
\i=0
- \vbox to\charheight{\vss\hbox{
+ {\vbox to\charheight{\vss\centerline{
{\loop\ifnum\i<\charsperline
\advance\i by1
\advance\n by1
{\setchar{#1}{\number\n}}
- \repeat}}}\repeat}
+ \repeat}}}}\repeat}
+
+
+\centerline{\title FETA}
+
+\centerline{\subtitle (definately not an abbreviation for Font-En-Tja)}
+
+\vskip5mm
\listfont{\fetatwenty}{0}{78}
% urg
\listfont{\fetadyn}{0}{6}
\vskip-\charheight
+\lilyfooter
+
\bye
+pl 0.jcn4
+ -set:
+ export GUILE_LOAD_PATH=$HOME/usr/src/lilypond/init
+ - dstream: Score_element, Column_info
+ - -fscm debug hack: lilypond -fscm a; guile a.scm > a.tex; tex a
+ - init/lily.scm
+
pl 0.uu5
- fixed MIDI output.
MAJOR_VERSION=1
MINOR_VERSION=1
PATCH_LEVEL=1
-MY_PATCH_LEVEL=
+MY_PATCH_LEVEL=jcn1
# use the above to send patches: MY_PATCH_LEVEL is always empty for a
# released version.
Clef_change_req 1
Col_configuration 1
Col_hpositions 1
-Colinfo 1
-Colinfo 1
Collision 1
+Column_info 1
Column_rod 1
Duration_identifier 1
Engraver 0
Scope 1
Score 0
Score_column 0
-Score_elem 0
+Score_element 0
Score_engraver 0
Score_performer 1
Script_column 1
depth = ..
INI_FILES = $(FLY_FILES) $(LY_FILES)
-# DIST_FILES = Makefile $(INI_FILES)
+SCM_FILES = $(wildcard *.scm)
+EXTRA_DIST_FILES = $(SCM_FILES)
INSTALLATION_DIR=$(datadir)/ly/
INSTALLATION_FILES=$(INI_FILES)
--- /dev/null
+; lily.scm -- implement Scheme output routines for TeX and PostScript
+;
+; source file of the GNU LilyPond music typesetter
+;
+; (c) 1998 Jan Nieuwenhuizen <janneke@gnu.org>
+
+;;; graphical lisp element
+(define (add-column p) (display "adding column (in guile): ") (display p) (newline))
+
+;;; library funtions
+(define
+ (numbers->string l)
+ (apply string-append
+ (map (lambda (n) (string-append (number->string n) " ")) l)))
+
+(define (number->octal-string x)
+ (let* ((n (inexact->exact x))
+ (n64 (quotient n 64))
+ (n8 (quotient (- n (* n64 64)) 8)))
+ (string-append
+ (number->string n64)
+ (number->string n8)
+ (number->string (remainder (- n (+ (* n64 64) (* n8 8))) 8)))))
+
+(define (inexact->string x radix)
+ (let ((n (inexact->exact x)))
+ (number->string n radix)))
+
+(define
+ (number->dim-tex x)
+ (string-append
+ (number->string x) "pt "))
+
+(define
+ (control->string c)
+ (string-append
+ (string-append (number->string (car c)) " ")
+ (string-append (number->string (cadr c)) " ")))
+
+(define
+ (invoke-output o s)
+ (eval-string (string-append s "-" o)))
+
+;;; output definitions
+
+(define
+ (beam o width slope thick)
+ ((invoke-output o "beam") width slope thick))
+
+(define
+ (beam-ps width slope thick)
+ (string-append
+ (numbers->string (list width slope thick)) " draw_beam " ))
+
+(define
+ (beam-tex width slope thick)
+ (string-append
+ "\\embeddedps{"
+ (beam-ps width slope thick)
+ "}"))
+
+(define
+ (char o n)
+ ((invoke-output o "char") n))
+
+(define
+ (char-ps n)
+ (string-append
+ "(\\" (inexact->string n 8) ") show"))
+
+(define
+ (char-tex n)
+ (string-append
+ "\\char" (inexact->string n 10)))
+
+(define
+ (dashed-slur o thick dash l)
+ ((invoke-output o "dashed-slur") thick dash l))
+
+(define
+ (dashed-slur-ps thick dash l)
+ (string-append
+ (apply string-append (map control->string l))
+ (number->string thick)
+ " [ "
+ (if (> 1 dash) (number->string (- (* thick dash) thick)) "0") " "
+ (number->string (* 2 thick))
+ " ] 0 draw_dashed_slur"))
+
+(define
+ (dashed-slur-tex thick dash l)
+ (string-append
+ "\\embeddedps{"
+ (dashed-slur-ps thick dash l)
+ "}"))
+
+(define
+ (empty o)
+ ((invoke-output o "empty")))
+
+(define
+ (empty-ps)
+ "\n empty\n")
+
+(define
+ (empty-tex)
+ "%\n\\empty%\n")
+
+(define
+ (end-output o)
+ ((invoke-output o "end-output")))
+
+(define
+ (end-output-ps)
+ "\nshowpage\n")
+
+(define
+ (end-output-tex)
+ "\n\\EndLilyPondOutput")
+
+(define
+ (experimental-on o)
+ ((invoke-output o "experimental-on")))
+
+(define
+ (experimental-on-ps) "")
+
+(define
+ (experimental-on-tex) "\\turnOnExperimentalFeatures")
+
+(define
+ (finishbar o h) (empty o))
+
+(define
+ (font i)
+ (string-append
+ "font"
+ (make-string 1 (integer->char (+ (char->integer #\A) i)))
+ ))
+
+(define
+ (font-def o i s)
+ (empty o))
+; ((invoke-output o "font-def") i s))
+
+(define
+ (font-def-ps i s)
+ (string-append
+ "\n/" (font i) " {/"
+ (substring s 0 (- (string-length s) 3))
+ " findfont 12 scalefont setfont} bind def\n"))
+
+(define
+ (font-def-tex i s)
+ (string-append
+ "\\font" (font-switch-tex i) "=" s "\n"))
+
+(define
+ (font-switch o i)
+ ((invoke-output o "font-switch") i))
+
+(define
+ (font-switch-ps i)
+ (string-append (font i) " "))
+
+(define
+ (font-switch-tex i)
+ (string-append
+ "\\" (font i) "\n"))
+
+(define
+ (generalmeter o num den)
+ ((invoke-output o "generalmeter") num den))
+
+(define
+ (generalmeter-ps num den)
+ (string-append (number->string (inexact->exact num)) " " (number->string (inexact->exact den)) " generalmeter "))
+
+(define
+ (generalmeter-tex num den)
+ (string-append
+ "\\generalmeter{" (number->string (inexact->exact num)) "}{" (number->string (inexact->exact den)) "}"))
+
+(define
+ (header o creator generate)
+ ((invoke-output o "header") creator generate))
+
+(define
+ (header-ps creator generate)
+ (string-append
+ "%!PS-Adobe-3.0\n"
+ "%%Creator: " creator generate "\n"))
+
+(define
+ (header-tex creator generate)
+ (string-append
+ "%created by: " creator generate "\n"))
+
+(define
+ (header-end o)
+ ((invoke-output o "header-end")))
+
+(define
+ (header-end-ps) "")
+
+(define
+ (header-end-tex) "\\turnOnPostScript")
+
+(define
+ (lily-def o key val)
+ ((invoke-output o "lily-def") key val))
+
+(define
+ (lily-def-ps key val)
+ (string-append
+ "/" key " {" val "} bind def\n"))
+
+(define
+ (lily-def-tex key val)
+ (string-append
+ "\\def\\" key "{" val "}\n"))
+
+(define
+ (maatstreep o h)
+ ((invoke-output o "maatstreep") h))
+
+(define
+ (maatstreep-ps h)
+ (string-append
+ (number->string h) " maatstreep " ))
+
+(define
+ (maatstreep-tex h)
+ (string-append
+ "\n\\maatstreep{" (number->dim-tex h) "}"))
+
+(define
+ (pianobrace o h) (empty o))
+
+(define
+ (placebox o x y b)
+ ((invoke-output o "placebox") x y (b o)))
+
+(define
+ (placebox-ps x y s)
+ (string-append
+ (number->string x) " " (number->string y) " {" s "} placebox "))
+
+(define
+ (placebox-tex x y s)
+ (string-append
+ "\\placebox{"
+ (number->dim-tex y) "}{" (number->dim-tex x) "}{" s "}"))
+
+(define
+ (repeatbar o h) (empty o))
+
+(define
+ (rulesym o x y)
+ ((invoke-output o "rulesym") x y))
+
+(define
+ (rulesym-ps x y)
+ (string-append
+ (number->string x) " "
+ (number->string y) " "
+ "rulesym"))
+
+(define
+ (rulesym-tex x y)
+ (string-append
+ "\\rulesym{" (number->dim-tex x) "}{" (number->dim-tex y) "}"))
+
+(define
+ (setbold o s)
+ ((invoke-output o "text") "bold" s))
+
+(define
+ (setfinger o s)
+ ((invoke-output o "text") "finger" s))
+
+(define
+ (sethuge o s)
+ ((invoke-output o "text") "huge" s))
+
+(define
+ (setitalic o s)
+ ((invoke-output o "text") "italic" s))
+
+(define
+ (setlarge o s)
+ ((invoke-output o "text") "large" s))
+
+(define
+ (setLarge o s)
+ ((invoke-output o "text") "Large" s))
+
+(define
+ (settext o s)
+ ((invoke-output o "text") "text" s))
+
+(define
+ (slur o l)
+ ((invoke-output o "slur") l))
+
+(define
+ (slur-ps l)
+ (string-append
+ (apply string-append (map control->string l))
+ " draw_slur"))
+
+(define
+ (slur-tex l)
+ (string-append
+ "\\embeddedps{"
+ (slur-ps l)
+ "}"))
+
+(define
+ (stem o kern width height depth)
+ ((invoke-output o "stem") kern width height depth))
+
+(define
+ (stem-ps kern width height depth)
+ (string-append (numbers->string (list kern width height depth))
+ "draw_stem" ))
+
+(define
+ (stem-tex kern width height depth)
+ (string-append
+ "\\kern" (number->dim-tex kern)
+ "\\vrule width " (number->dim-tex width)
+ "depth " (number->dim-tex depth)
+ "height " (number->dim-tex height) " "))
+
+(define
+ (start-line o)
+ ((invoke-output o "start-line")))
+
+(define
+ (start-line-ps)
+ (string-append
+ (urg-fix-font-ps)
+ "\nstart_line {\n"))
+
+(define
+ (start-line-tex)
+ (string-append
+ (urg-fix-font-tex)
+ "\\hbox{%\n"))
+
+(define
+ (startrepeat o h) (empty o))
+
+(define
+ (stop-line o)
+ ((invoke-output o "stop-line")))
+
+(define
+ (stop-line-ps)
+ "}\nstop_line\n")
+
+(define
+ (stop-line-tex)
+ "}\\interscoreline")
+
+(define
+ (stoprepeat o h) (empty o))
+
+(define
+ (text-ps f s)
+ (string-append "(" s ") set" f " "))
+
+(define
+ (text-tex f s)
+ (string-append "\\set" f "{" s "}"))
+
+(define
+ (urg-fix-font-ps)
+ "/fontA { /feta20 findfont 12 scalefont setfont} bind def fontA\n")
+
+(define
+ (urg-fix-font-tex)
+ "\\font\\fontA=feta20.afm\\fontA\n")
+
+(define
+ (urg-font-switch-ps i)
+ "\n/feta20 findfont 12 scalefont setfont \n")
+
arithmetic_multiplier = 4.8\pt;
texsetting = "\\input lilyponddefs \\musixsixteendefs ";
pssetting = "(lilyponddefs.ps) findlibfile {exch pop //systemdict /run get exec} { /undefinedfilename signalerror } ifelse\n";
+ scmsetting = "(display \"(lilyponddefs.ps) findlibfile {exch pop //systemdict /run get exec} { /undefinedfilename signalerror } ifelse\");\n";
+ scmsetting = "(display \"\\\\input lilyponddefs \\\\musixsixteendefs\");\n";
0 = \symboltables { \table_sixteen }
-1 = \symboltables { \table_thirteen }
texsetting = "\\input lilyponddefs \\musixtwentydefs ";
pssetting = "(lilyponddefs.ps) findlibfile {exch pop //systemdict /run get exec} { /undefinedfilename signalerror } ifelse\n";
% urg, debugging only
- scmsetting = "(lilyponddefs.ps) findlibfile {exch pop //systemdict /run get exec} { /undefinedfilename signalerror } ifelse\n";
+ scmsetting = "(display \"(lilyponddefs.ps) findlibfile {exch pop //systemdict /run get exec} { /undefinedfilename signalerror } ifelse\");\n";
+ scmsetting = "(display \"\\\\input lilyponddefs \\\\musixtwentydefs\");\n";
-2 = \symboltables { \table_thirteen }
-1 = \symboltables { \table_sixteen }
% (c) 1998 Jan Nieuwenhuizen <janneke@gnu.org>
\scm "
-
-;;; graphical lisp element
-(define (add-column p) (display \"adding column (in guile): \") (display p) (newline))
-
-;;; library funtions
-(define
- (numbers->string l)
- (apply string-append
- (map (lambda (n) (string-append (number->string n) \" \")) l)))
-
-(define (number->octal-string x)
- (let* ((n (inexact->exact x))
- (n64 (quotient n 64))
- (n8 (quotient (- n (* n64 64)) 8)))
- (string-append
- (number->string n64)
- (number->string n8)
- (number->string (remainder (- n (+ (* n64 64) (* n8 8))) 8)))))
-
-(define (inexact->string x radix)
- (let ((n (inexact->exact x)))
- (number->string n radix)))
-
-(define
- (number->dim-tex x)
- (string-append
- (number->string x) \"pt \"))
-
-(define
- (control->string c)
- (string-append
- (string-append (number->string (car c)) \" \")
- (string-append (number->string (cadr c)) \" \")))
-
-(define
- (invoke-output o s)
- (eval-string (string-append s \"-\" o)))
-
-;;; output definitions
-
-(define
- (beam o width slope thick)
- ((invoke-output o \"beam\") width slope thick))
-
-(define
- (beam-ps width slope thick)
- (string-append
- (numbers->string (list width slope thick)) \" draw_beam \" ))
-
-(define
- (beam-tex width slope thick)
- (string-append
- \"\\\\embeddedps{\"
- (beam-ps width slope thick)
- \"}\"))
-
-(define
- (char o n)
- ((invoke-output o \"char\") n))
-
-(define
- (char-ps n)
- (string-append
- \"(\\\\\" (inexact->string n 8) \") show\"))
-
-(define
- (char-tex n)
- (string-append
- \"\\\\char\" (inexact->string n 10)))
-
-(define
- (dashed-slur o thick dash l)
- ((invoke-output o \"dashed-slur\") thick dash l))
-
-(define
- (dashed-slur-ps thick dash l)
- (string-append
- (apply string-append (map control->string l))
- (number->string thick)
- \" [ \"
- (if (> 1 dash) (number->string (- (* thick dash) thick)) \"0\") \" \"
- (number->string (* 2 thick))
- \" ] 0 draw_dashed_slur\"))
-
-(define
- (dashed-slur-tex thick dash l)
- (string-append
- \"\\\\embeddedps{\"
- (dashed-slur-ps thick dash l)
- \"}\"))
-
-(define
- (empty o)
- ((invoke-output o \"empty\")))
-
-(define
- (empty-ps)
- \"\n empty\n\")
-
-(define
- (empty-tex)
- \"%\n\\\\empty%\n\")
-
-(define
- (end-output o)
- ((invoke-output o \"end-output\")))
-
-(define
- (end-output-ps)
- \"\nshowpage\n\")
-
-(define
- (end-output-tex)
- \"\n\\\\EndLilyPondOutput\")
-
-(define
- (experimental-on o)
- ((invoke-output o \"experimental-on\")))
-
-(define
- (experimental-on-ps) \"\")
-
-(define
- (experimental-on-tex) \"\\\\turnOnExperimentalFeatures\")
-
-(define
- (finishbar o h) (empty o))
-
-(define
- (font i)
- (string-append
- \"font\"
- (make-string 1 (integer->char (+ (char->integer #\\A) i)))
- ))
-
-(define
- (font-def o i s)
- (empty o))
-; ((invoke-output o \"font-def\") i s))
-
-(define
- (font-def-ps i s)
- (string-append
- \"\n/\" (font i) \" {/\"
- (substring s 0 (- (string-length s) 3))
- \" findfont 12 scalefont setfont} bind def\n\"))
-
-(define
- (font-def-tex i s)
- (string-append
- \"\\\\font\" (font-switch-tex i) \"=\" s \"\n\"))
-
-(define
- (font-switch o i)
- ((invoke-output o \"font-switch\") i))
-
-(define
- (font-switch-ps i)
- (string-append (font i) \" \"))
-
-(define
- (font-switch-tex i)
- (string-append
- \"\\\\\" (font i) \"\n\"))
-
-(define
- (generalmeter o num den)
- ((invoke-output o \"generalmeter\") num den))
-
-(define
- (generalmeter-ps num den)
- (string-append (number->string (inexact->exact num)) \" \" (number->string (inexact->exact den)) \" generalmeter \"))
-
-(define
- (generalmeter-tex num den)
- (string-append
- \"\\\\generalmeter{\" (number->string (inexact->exact num)) \"}{\" (number->string (inexact->exact den)) \"}\"))
-
-(define
- (header o creator generate)
- ((invoke-output o \"header\") creator generate))
-
-(define
- (header-ps creator generate)
- (string-append
- \"%!PS-Adobe-3.0\n\"
- \"%%Creator: \" creator generate \"\n\"))
-
-(define
- (header-tex creator generate)
- (string-append
- \"%created by: \" creator generate \"\n\"))
-
-(define
- (header-end o)
- ((invoke-output o \"header-end\")))
-
-(define
- (header-end-ps) \"\")
-
-(define
- (header-end-tex) \"\\\\turnOnPostScript\")
-
-(define
- (lily-def o key val)
- ((invoke-output o \"lily-def\") key val))
-
-(define
- (lily-def-ps key val)
- (string-append
- \"/\" key \" {\" val \"} bind def\n\"))
-
-(define
- (lily-def-tex key val)
- (string-append
- \"\\\\def\\\\\" key \"{\" val \"}\n\"))
-
-(define
- (maatstreep o h)
- ((invoke-output o \"maatstreep\") h))
-
-(define
- (maatstreep-ps h)
- (string-append
- (number->string h) \" maatstreep \" ))
-
-(define
- (maatstreep-tex h)
- (string-append
- \"\n\\\\maatstreep{\" (number->dim-tex h) \"}\"))
-
-(define
- (pianobrace o h) (empty o))
-
-(define
- (placebox o x y b)
- ((invoke-output o \"placebox\") x y (b o)))
-
-(define
- (placebox-ps x y s)
- (string-append
- (number->string x) \" \" (number->string y) \" {\" s \"} placebox \"))
-
-(define
- (placebox-tex x y s)
- (string-append
- \"\\\\placebox{\"
- (number->dim-tex y) \"}{\" (number->dim-tex x) \"}{\" s \"}\"))
-
-(define
- (repeatbar o h) (empty o))
-
-(define
- (rulesym o x y)
- ((invoke-output o \"rulesym\") x y))
-
-(define
- (rulesym-ps x y)
- (string-append
- (number->string x) \" \"
- (number->string y) \" \"
- \"rulesym\"))
-
-(define
- (rulesym-tex x y)
- (string-append
- \"\\\\rulesym{\" (number->dim-tex x) \"}{\" (number->dim-tex y) \"}\"))
-
-(define
- (setbold o s)
- ((invoke-output o \"text\") \"bold\" s))
-
-(define
- (setfinger o s)
- ((invoke-output o \"text\") \"finger\" s))
-
-(define
- (sethuge o s)
- ((invoke-output o \"text\") \"huge\" s))
-
-(define
- (setitalic o s)
- ((invoke-output o \"text\") \"italic\" s))
-
-(define
- (setlarge o s)
- ((invoke-output o \"text\") \"large\" s))
-
-(define
- (setLarge o s)
- ((invoke-output o \"text\") \"Large\" s))
-
-(define
- (settext o s)
- ((invoke-output o \"text\") \"text\" s))
-
-(define
- (slur o l)
- ((invoke-output o \"slur\") l))
-
-(define
- (slur-ps l)
- (string-append
- (apply string-append (map control->string l))
- \" draw_slur\"))
-
-(define
- (slur-tex l)
- (string-append
- \"\\\\embeddedps{\"
- (slur-ps l)
- \"}\"))
-
-(define
- (stem o kern width height depth)
- ((invoke-output o \"stem\") kern width height depth))
-
-(define
- (stem-ps kern width height depth)
- (string-append (numbers->string (list kern width height depth))
- \"draw_stem\" ))
-
-(define
- (stem-tex kern width height depth)
- (string-append
- \"\\\\kern\" (number->dim-tex kern)
- \"\\\\vrule width \" (number->dim-tex width)
- \"depth \" (number->dim-tex depth)
- \"height \" (number->dim-tex height) \" \"))
-
-(define
- (start-line o)
- ((invoke-output o \"start-line\")))
-
-(define
- (start-line-ps)
- (string-append
- (urg-fix-font-ps)
- \"\nstart_line {\n\"))
-
-(define
- (start-line-tex)
- (string-append
- (urg-fix-font-tex)
- \"\\\\hbox{%\n\"))
-
-(define
- (stop-line o)
- ((invoke-output o \"stop-line\")))
-
-(define
- (stop-line-ps)
- \"}\nstop_line\n\")
-
-(define
- (stop-line-tex)
- \"}\\\\interscoreline\")
-
-(define
- (text-ps f s)
- (string-append \"(\" s \") set\" f \" \"))
-
-(define
- (text-tex f s)
- (string-append \"\\\\set\" f \"{\" s \"}\"))
-
-(define
- (urg-fix-font-ps)
- \"/fontA { /feta20 findfont 12 scalefont setfont} bind def fontA\n\")
-
-(define
- (urg-fix-font-tex)
- \"\\\\font\\\\fontA=feta20.afm\\\\fontA\n\")
-
-(define
- (urg-font-switch-ps i)
- \"\n/feta20 findfont 12 scalefont setfont \n\")
-
+; huh?
+;(append %load-path 'init)
+;(load-patch 'lily.scm)
+(load 'init/lily.scm)
";
-
-
Atom
Lookup::accidental (int j) const
{
- return afm_find (String ("accidentals") + String ("-") + to_str (j));
+ Atom a = afm_find (String ("accidentals") + String ("-") + to_str (j));
+ return a;
}
void
Array<Real> arr;
arr.push (m.code ());
a.lambda_ = (lambda_scm ("char", arr));
+ a.str_ = "afm_find: " + s;
a.font_ = font_;
return a;
}
arr.push (h);
Atom a = (*symtables_p_) ("bars")->lookup (str);
a.lambda_ = (lambda_scm (a.str_, arr));
+ a.str_ = "bar";
a.dim_.y () = Interval (-h/2, h/2);
a.font_ = font_;
return a;
Atom a;
a.lambda_ = (lambda_scm ("beam", arr));
+ a.str_ = "beam";
a.dim_[X_AXIS] = Interval (0, width);
a.dim_[Y_AXIS] = Interval (min_y, max_y);
return a;
gh_cons (ly_list2 (gh_double2scm (controls[0].x ()), gh_double2scm (controls[0].y ())),
SCM_EOL))))))))))));
+ a.str_ = "dashed_slur";
return a;
}
Lookup::flag (int j, Direction d) const
{
char c = (d == UP) ? 'u' : 'd';
- return afm_find (String ("flags") + String ("-") + to_str (c) + to_str (j));
+ Atom a = afm_find (String ("flags") + String ("-") + to_str (c) + to_str (j));
+ return a;
}
void
Atom
Lookup::rule_symbol (Real height, Real width) const
{
- Atom bs= (*symtables_p_) ("param")->lookup ("rule");
- Array<Real> args;
- args.push (height);
- args.push (width);
- bs.lambda_ = (lambda_scm (bs.str_, args));
- bs.dim_.x () = Interval (0, width);
- bs.dim_.y () = Interval (0, height);
- return bs;
+ Atom a = (*symtables_p_) ("param")->lookup ("rule");
+ Array<Real> arr;
+ arr.push (height);
+ arr.push (width);
+ a.lambda_ = lambda_scm (a.str_, arr);
+ a.str_ = "rule_symbol";
+ a.dim_.x () = Interval (0, width);
+ a.dim_.y () = Interval (0, height);
}
Atom
y1 = y2;
y2 = t;
}
- Atom s;
+ Atom a;
- s.dim_.x () = Interval (0,0);
- s.dim_.y () = Interval (y1,y2);
+ a.dim_.x () = Interval (0,0);
+ a.dim_.y () = Interval (y1,y2);
- Array<Real> a;
+ Array<Real> arr;
Real stem_width = paper_l_->get_var ("stemthickness");
- a.push (-stem_width /2);
- a.push (stem_width);
- a.push (y2);
- a.push (-y1);
-
- s.lambda_ = (lambda_scm ("stem", a));
- s.font_ = font_;
- return s;
+ arr.push (-stem_width /2);
+ arr.push (stem_width);
+ arr.push (y2);
+ arr.push (-y1);
+
+ a.lambda_ = lambda_scm ("stem", arr);
+ a.str_ = "stem";
+ a.font_ = font_;
}
Atom
if (type > 2)
type = 2;
- return afm_find ("balls" + String ("-") +to_str (type) + "l");
+ Atom a = afm_find ("balls" + String ("-") + to_str (type) + "l");
+ return a;
}
Atom
Lookup::text (String style, String text) const
{
- Array<Scalar> a;
-
- a.push (text);
- Atom s = (*symtables_p_) ("style")->lookup (style);
- s.lambda_ = (lambda_scm (s.str_, a));
- s.font_ = font_;
+ Array<Scalar> arr;
- return s;
+ arr.push (text);
+ Atom a = (*symtables_p_) ("style")->lookup (style);
+ a.lambda_ = lambda_scm (a.str_, arr);
+ a.str_ = "text";
+ a.font_ = font_;
}
Atom
Lookup::time_signature (Array<Real> a) const
{
- Atom s ((*symtables_p_) ("param")->lookup ("time_signature"));
- s.lambda_ = (lambda_scm (s.str_, a));
-
- return s;
+ Atom a ((*symtables_p_) ("param")->lookup ("time_signature"));
+ a.lambda_ = lambda_scm (a.str_, arr);
+ a.str_ = "time_signature";
}
/*
Atom
Lookup::vbrace (Real &y) const
{
- Atom brace = (*symtables_p_) ("param")->lookup ( "brace");
- Interval ydims = brace.dim_[Y_AXIS];
+ Atom a = (*symtables_p_) ("param")->lookup ( "brace");
+ Interval ydims = a.dim_[Y_AXIS];
Real min_y = ydims[LEFT];
Real max_y = ydims[RIGHT];
Real step = 1.0 PT;
int idx = int (rint ( (y- min_y)/step)) + 1;
- Array<Real> a;
- a.push (idx);
- brace.lambda_ = (lambda_scm (brace.str_, a));
- brace.dim_[Y_AXIS] = Interval (-y/2,y/2);
-
- brace.font_ = font_;
-
- return brace;
+ Array<Real> arr;
+ arr.push (idx);
+ a.lambda_ = lambda_scm (a.str_, arr);
+ a.str_ = "brace";
+ a.dim_[Y_AXIS] = Interval (-y/2,y/2);
+ a.font_ = font_;
+ return a;
}
Atom
+ String_convert::int_str ( (int)dir) +
" draw_plet ";
- Atom s;
- s.str_ = ps;
- return s;
+ Atom a;
+ a.str_ = ps;
+ return a;
}
Atom
gh_cons (ly_list2 (gh_double2scm (controls[3].x ()), gh_double2scm (controls[3].y ())),
gh_cons (ly_list2 (gh_double2scm (controls[0].x ()), gh_double2scm (controls[0].y ())),
SCM_EOL))))))))))))));
+ a.str_ = "slur";
a.dim_[X_AXIS] = Interval (0, dx);
a.dim_[Y_AXIS] = Interval (0 <? dy, 0 >? dy);
Array<Real> arr;
arr.push (y);
a.lambda_ = (lambda_scm ("bracket", arr));
+ a.str_ = "vbracket";
a.dim_[Y_AXIS] = Interval (-y/2,y/2);
a.dim_[X_AXIS] = Interval (0,4 PT);
return a;
Paper_outputter* p = new Paper_outputter (os_p);
output_header (p, header_global_p);
+#if 0
+ // for now; breaks -fscm output
p->output_comment (_ ("outputting Score, defined at: "));
p->output_comment (origin_str);
+#endif
output_header (p, header_l);
*/
#include <time.h>
+#include <fstream.h>
#include "paper-outputter.hh"
#include "paper-stream.hh"
#include "molecule.hh"
#ifndef NPRINT
if (check_debug && !monitor->silent_b ("Guile"))
{
+ DOUT << i->str_ << "\n";
gh_display (i->lambda_); gh_newline ();
}
#endif
// urg; temporary hack to debug scheme error #unknown
if (String (output_global_ch) == "scm")
{
-// char* c = gh_scm2newstr (scm, NULL);
-// *outstream_l_ << c << "\n";
-// free (c);
- gh_display (scm); gh_newline ();
+ static SCM port = 0;
+ // urg
+ if (!port)
+ {
+ int fd = 1;
+ ofstream * of = dynamic_cast <ofstream*> (outstream_l_->os);
+ if (of)
+ fd = of->rdbuf()->fd();
+ FILE *file = fdopen (fd, "a");
+ port = scm_standard_stream_to_port (file, "a", "");
+ scm_display (gh_str02scm ("(load 'lily.scm)\n"), port);
+ }
+#if 0
+ *outstream_l_ << "(display ((eval ";
+ scm_write (scm, port);
+ *outstream_l_ << ") 'tex))\n";
+#else
+ scm_display (gh_str02scm ("(display ((eval "), port);
+ scm_write (scm, port);
+ scm_display (gh_str02scm (") 'tex))\n"), port);
+ scm_newline (port);
+ scm_fflush (port);
+#endif
return;
}
SCM str_scm = gh_call1 (ly_eval (scm), gh_eval_str (o.ch_l ()));