+pl5.jcn4
+ - scm additions: plet, hairpin
+ - website fixes
+
pl5.jcn3
- website fixes
MAJOR_VERSION=1
MINOR_VERSION=1
PATCH_LEVEL=5
-MY_PATCH_LEVEL=jcn3
+MY_PATCH_LEVEL=jcn4
# use the above to send patches: MY_PATCH_LEVEL is always empty for a
# released version.
(char o n)
((invoke-output o "invoke-char") "show" n))
+(define
+ (crescendo o w h cont)
+ ((invoke-output o "crescendo") w h cont))
+
+(define
+ (crescendo-ps w h cont)
+ (string-append
+ (numbers->string (list w h (inexact->exact cont)))
+ "draw_crescendo"))
+
+(define
+ (crescendo-tex w h cont)
+ (embedded-ps-tex (crescendo-ps w h cont)))
+
(define
(dashed-slur o thick dash l)
((invoke-output o "dashed-slur") thick dash l))
+(define
+ (decrescendo o w h cont)
+ ((invoke-output o "decrescendo") w h cont))
+
+(define
+ (decrescendo-ps w h cont)
+ (string-append
+ (numbers->string (list w h (inexact->exact cont)))
+ "draw_decrescendo"))
+
+(define
+ (decrescendo-tex w h cont)
+ (embedded-ps-tex (decrescendo-ps w h cont)))
+
(define
(dashed-slur-ps thick dash l)
(string-append
(string-append "\\set" f "{" s "}"))
+(define
+ (tuplet o dx dy dir)
+ ((invoke-output o "tuplet") dx dy dir))
+
+(define
+ (tuplet-ps dx dy dir)
+ (string-append
+ (numbers->string (list dx dy (inexact->exact dir)))
+ "draw_tuplet"))
+
+(define
+ (tuplet-tex dx dy dir)
+ (embedded-ps-tex (tuplet-ps dx dy dir)))
# input/test/Makefile
depth = ../..
-examples=font20 hara-kiri grace mark denneboom slurs
+examples=font20 hara-kiri grace mark denneboom sleur
LOCALSTEPMAKE_TEMPLATES=mutopia
include $(depth)/make/stepmake.make
\score{
< \global \one \two >
\paper {
- \translator { \BarNumberingStaffContext }
+ \translator { \OrchestralPartStaffContext }
}
}
{
Atom a;
Real height = paper_l_->staffheight_f () / 6;
- String ps;
- ps += to_str (width) + " "
- + to_str (height) + " "
- + to_str (continued ? height/2 : 0) +
- + " draw_" + String (decresc ? "de" : "") + "cresc\n";
- a.str_ = ps;
+ Array<Real> arr;
+ arr.push (width);
+ arr.push (height);
+ arr.push (continued ? height/2 : 0);
+ String hairpin = String (decresc ? "de" : "") + "crescendo\n";
+ a.lambda_ = (lambda_scm (hairpin, arr));
+ a.str_ = "hairpin";
a.dim_.x () = Interval (0, width);
a.dim_.y () = Interval (-2*height, 2*height);
a.font_ = font_;
Atom
Lookup::plet (Real dy , Real dx, Direction dir) const
{
- String ps;
-
- ps += String_convert::double_str (dx) + " "
- + String_convert::double_str (dy) + " "
- + String_convert::int_str ( (int)dir) +
- " draw_plet ";
-
+ Array<Real> arr;
+ arr.push (dx);
+ arr.push (dy);
+ arr.push (dir);
Atom a;
- a.str_ = ps;
+ a.lambda_ = (lambda_scm ("tuplet", arr));
+ a.str_ = "plet";
return a;
}
{
assert (controls.size () == 8);
- String ps;
-
Real dx = controls[3].x () - controls[0].x ();
Real dy = controls[3].y () - controls[0].y ();
Atom a;
closepath fill
} bind def
%
-/draw_decresc
+/draw_decrescendo % cont height width
{
stafflinethickness setlinewidth
/cresc_cont exch def
stroke
} bind def
%
-/draw_cresc
+/draw_crescendo % cont height width
{
stafflinethickness setlinewidth
/cresc_cont exch def
1 copy mul exch 1 copy mul add sqrt
} bind def
%
-stafflinethickness 1.2 mul /plet_t exch def
-/draw_plet
+stafflinethickness 1.2 mul /tuplet_t exch def
+/draw_tuplet
{
- plet_t setlinewidth
+ tuplet_t setlinewidth
% urg: the only Level-2 PS, check effect in print
% true setstrokeadjust
1 setlinecap
1 setlinejoin
/dir exch def
- /plet_dy exch def
- /plet_dx exch def
- staffheight 2 div /plet_gapx exch def
- plet_dy plet_dx div plet_gapx mul /plet_gapy exch def
- staffheight 4 div dir mul /plet_h exch def
+ /tuplet_dy exch def
+ /tuplet_dx exch def
+ staffheight 2 div /tuplet_gapx exch def
+ tuplet_dy tuplet_dx div tuplet_gapx mul /tuplet_gapy exch def
+ staffheight 4 div dir mul /tuplet_h exch def
%
0 0 moveto
- 0 plet_h lineto
- plet_dx plet_gapx sub 2 div
- plet_dy plet_gapy sub 2 div plet_h add lineto
- plet_dx plet_gapx add 2 div
- plet_dy plet_gapy add 2 div plet_h add moveto
- plet_dx plet_dy plet_h add lineto
- plet_dx plet_dy lineto
+ 0 tuplet_h lineto
+ tuplet_dx tuplet_gapx sub 2 div
+ tuplet_dy tuplet_gapy sub 2 div tuplet_h add lineto
+ tuplet_dx tuplet_gapx add 2 div
+ tuplet_dy tuplet_gapy add 2 div tuplet_h add moveto
+ tuplet_dx tuplet_dy tuplet_h add lineto
+ tuplet_dx tuplet_dy lineto
stroke
} bind def
%