CVSROOT: /cvsroot/lilypond
Module name: lilypond
Branch:
Changes by: Han-Wen Nienhuys <[EMAIL PROTECTED]> 05/05/28 13:43:24
Modified files:
. : ChangeLog
input/regression: backend-excercise.ly easy-notation.ly
lily : line-spanner.cc lookup.cc note-head.cc
stencil-scheme.cc stencil.cc
system-start-delimiter.cc
lily/include : stencil.hh
ly : engraver-init.ly property-init.ly
ps : music-drawing-routines.ps
scm : lily.scm output-gnome.scm output-ps.scm
output-svg.scm output-tex.scm
Added files:
lily : easy-notation.cc
Log message:
* lily/stencil-scheme.cc (LY_DEFINE): ly:stencil-in-color
* ps/music-drawing-routines.ps:
* scm/output-ps.scm: remove draw ez_ball.
* ly/engraver-init.ly (AncientRemoveEmptyStaffContext): remove
EasyNotation context definition.
* lily/easy-notation.cc (brew_ez_stencil): new file. Use
Text_interface and color for making easy note heads.
* lily/stencil.cc (with_color): new function.
* ps/music-drawing-routines.ps: remove draw_zigzag_line
* lily/line-spanner.cc (zigzag_stencil): rewrite to use draw-line
output routine. Zigzag now works in SVG too.
* scm/output-tex.scm (filledbox): idem.
* scm/output-svg.scm (filledbox): idem.
* scm/output-ps.scm (lily-def): remove horizontal-line.
* lily/lookup.cc (horizontal_line): use draw-line.
* lily/system-start-delimiter.cc: remove old staff bracket code.
* lily/system-start-delimiter.cc (staff_bracket): use glyphs.
CVSWeb URLs:
http://savannah.gnu.org/cgi-bin/viewcvs/lilypond/lilypond/ChangeLog.diff?tr1=1.3671&tr2=1.3672&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/lilypond/lilypond/input/regression/backend-excercise.ly.diff?tr1=1.3&tr2=1.4&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/lilypond/lilypond/input/regression/easy-notation.ly.diff?tr1=1.34&tr2=1.35&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/lilypond/lilypond/lily/easy-notation.cc?rev=1.1
http://savannah.gnu.org/cgi-bin/viewcvs/lilypond/lilypond/lily/line-spanner.cc.diff?tr1=1.61&tr2=1.62&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/lilypond/lilypond/lily/lookup.cc.diff?tr1=1.185&tr2=1.186&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/lilypond/lilypond/lily/note-head.cc.diff?tr1=1.138&tr2=1.139&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/lilypond/lilypond/lily/stencil-scheme.cc.diff?tr1=1.43&tr2=1.44&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/lilypond/lilypond/lily/stencil.cc.diff?tr1=1.40&tr2=1.41&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/lilypond/lilypond/lily/system-start-delimiter.cc.diff?tr1=1.98&tr2=1.99&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/lilypond/lilypond/lily/include/stencil.hh.diff?tr1=1.17&tr2=1.18&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/lilypond/lilypond/ly/engraver-init.ly.diff?tr1=1.233&tr2=1.234&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/lilypond/lilypond/ly/property-init.ly.diff?tr1=1.72&tr2=1.73&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/lilypond/lilypond/ps/music-drawing-routines.ps.diff?tr1=1.34&tr2=1.35&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/lilypond/lilypond/scm/lily.scm.diff?tr1=1.347&tr2=1.348&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/lilypond/lilypond/scm/output-gnome.scm.diff?tr1=1.92&tr2=1.93&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/lilypond/lilypond/scm/output-ps.scm.diff?tr1=1.140&tr2=1.141&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/lilypond/lilypond/scm/output-svg.scm.diff?tr1=1.27&tr2=1.28&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/lilypond/lilypond/scm/output-tex.scm.diff?tr1=1.91&tr2=1.92&r1=text&r2=text
Patches:
Index: lilypond/ChangeLog
diff -u lilypond/ChangeLog:1.3671 lilypond/ChangeLog:1.3672
--- lilypond/ChangeLog:1.3671 Sat May 28 12:09:37 2005
+++ lilypond/ChangeLog Sat May 28 13:43:23 2005
@@ -1,5 +1,34 @@
2005-05-28 Han-Wen Nienhuys <[EMAIL PROTECTED]>
+ * lily/stencil-scheme.cc (LY_DEFINE): ly:stencil-in-color
+
+ * ps/music-drawing-routines.ps:
+
+ * scm/output-ps.scm: remove draw ez_ball.
+
+ * ly/engraver-init.ly (AncientRemoveEmptyStaffContext): remove
+ EasyNotation context definition.
+
+ * lily/easy-notation.cc (brew_ez_stencil): new file. Use
+ Text_interface and color for making easy note heads.
+
+ * lily/stencil.cc (with_color): new function.
+
+ * ps/music-drawing-routines.ps: remove draw_zigzag_line
+
+ * lily/line-spanner.cc (zigzag_stencil): rewrite to use draw-line
+ output routine. Zigzag now works in SVG too.
+
+ * scm/output-tex.scm (filledbox): idem.
+
+ * scm/output-svg.scm (filledbox): idem.
+
+ * scm/output-ps.scm (lily-def): remove horizontal-line.
+
+ * lily/lookup.cc (horizontal_line): use draw-line.
+
+ * lily/system-start-delimiter.cc: remove old staff bracket code.
+
* mf/feta-haak.mf: further tweaks.
* lily/system-start-delimiter.cc (staff_bracket): use glyphs.
@@ -16,7 +45,8 @@
* scm/output-svg.scm (circle): support circle.
(bracket): stub for bracket.
- * scripts/lilypond-book.py (main): make sure --psfonts warning is
correct.
+ * scripts/lilypond-book.py (main): make sure --psfonts warning is
+ correct.
2005-05-26 Graham Percival <[EMAIL PROTECTED]>
Index: lilypond/input/regression/backend-excercise.ly
diff -u lilypond/input/regression/backend-excercise.ly:1.3
lilypond/input/regression/backend-excercise.ly:1.4
--- lilypond/input/regression/backend-excercise.ly:1.3 Tue Apr 5 22:52:49 2005
+++ lilypond/input/regression/backend-excercise.ly Sat May 28 13:43:23 2005
@@ -4,8 +4,10 @@
\version "2.5.0"
+\paper { raggedright = ##t }
+
\relative {
- \new StaffGroup <<
+ \new StaffGroup \new PianoStaff <<
\new Staff <<
{
#(set-octavation 1)
@@ -16,6 +18,12 @@
\skip 1 >>
\new Staff \relative c'' {
\makeClusters { <g a>8 <e a> }
+ \override Glissando #'style = #'zigzag
+ f2 \glissando f'
+ \override NoteHead #'print-function = #Note_head::brew_ez_stencil
+ \override NoteHead #'Y-extent-callback = #'()
+ \override NoteHead #'X-extent-callback = #'()
+ f e
}
>>
}
Index: lilypond/input/regression/easy-notation.ly
diff -u lilypond/input/regression/easy-notation.ly:1.34
lilypond/input/regression/easy-notation.ly:1.35
--- lilypond/input/regression/easy-notation.ly:1.34 Sat Oct 30 20:55:15 2004
+++ lilypond/input/regression/easy-notation.ly Sat May 28 13:43:23 2005
@@ -5,15 +5,18 @@
You also get ledger lines, of course."
}
-\score {
- {
- \setEasyHeads
- c'2 g'2 | g'1
- \override NoteHead #'note-names = ##("U" "V" "W" "X" "Y" "Z" "z")
- c'2 e'4 f' | b'1
- }
- \layout {
- raggedright = ##t
- }
+
+\layout {
+ raggedright = ##t
+}
+
+\relative {
+ \setEasyHeads
+ f1 e
+ f2 e
+ f4 e
+
+ \override NoteHead #'note-names = ##("U" "V" "W" "X" "Y" "Z" "z")
+ c2 d4 e
}
Index: lilypond/lily/include/stencil.hh
diff -u lilypond/lily/include/stencil.hh:1.17
lilypond/lily/include/stencil.hh:1.18
--- lilypond/lily/include/stencil.hh:1.17 Thu Mar 10 14:36:12 2005
+++ lilypond/lily/include/stencil.hh Sat May 28 13:43:24 2005
@@ -80,6 +80,7 @@
Interval extent (Axis) const;
Box extent_box () const;
bool is_empty () const;
+ Stencil in_color (Real r, Real g, Real b) const;
static SCM ly_get_stencil_extent (SCM mol, SCM axis);
static SCM ly_set_stencil_extent_x (SCM, SCM, SCM);
@@ -97,4 +98,5 @@
Stencil create_stencil (SCM print);
SCM find_expression_fonts (SCM expr);
+
#endif /* STENCIL_HH */
Index: lilypond/lily/line-spanner.cc
diff -u lilypond/lily/line-spanner.cc:1.61 lilypond/lily/line-spanner.cc:1.62
--- lilypond/lily/line-spanner.cc:1.61 Mon Apr 18 12:29:24 2005
+++ lilypond/lily/line-spanner.cc Sat May 28 13:43:23 2005
@@ -26,33 +26,46 @@
Offset to)
{
Offset dz = to -from;
- Real dx = dz[X_AXIS];
- Real dy = dz[Y_AXIS];
Real thick = Staff_symbol_referencer::line_thickness (me);
thick *= robust_scm2double (me->get_property ("thickness"), 1.0); // todo:
staff sym referencer?
Real staff_space = Staff_symbol_referencer::staff_space (me);
- double w = robust_scm2double (me->get_property ("zigzag-width"), 1) *
staff_space;
- double l = robust_scm2double (me->get_property ("zigzag-length"), 1) * w;
- double h = l > w / 2 ? sqrt (l * l - w * w / 4) : 0;
-
- SCM list = scm_list_n (ly_symbol2scm ("zigzag-line"),
- ly_bool2scm (true),
- scm_make_real (w),
- scm_make_real (h),
- scm_make_real (thick),
- scm_make_real (dx),
- scm_make_real (dy),
- SCM_UNDEFINED);
+ Real w = robust_scm2double (me->get_property ("zigzag-width"), 1) *
staff_space;
+ int count = (int) ceil (dz.length() / w);
+ w = dz.length () / count;
+
+ Real l = robust_scm2double (me->get_property ("zigzag-length"), 1) * w;
+ Real h = l > w / 2 ? sqrt (l * l - w * w / 4) : 0;
+
+ Offset rotation_factor = complex_exp (Offset (0, dz.arg ()));
+
+ Offset points[3];
+ points[0] = Offset (0, -h/2);
+ points[1] = Offset (w/2, h/2);
+ points[2] = Offset (w, -h/2);
+ for (int i = 0; i < 3; i++)
+ points[i] = complex_multiply (points[i], rotation_factor);
+
+ Stencil squiggle (Line_interface::make_line (thick,points[0], points[1]));
+ squiggle.add_stencil (Line_interface::make_line (thick,points[1],
points[2]));
+
+ Stencil total;
+ for (int i = 0; i < count; i++)
+ {
+ Stencil moved_squiggle (squiggle);
+ moved_squiggle.translate (from + Offset (i * w, 0) * rotation_factor);
+ total.add_stencil (moved_squiggle);
+ }
+
Box b;
b.add_point (Offset (0, 0));
b.add_point (dz);
b[X_AXIS].widen (thick / 2);
b[Y_AXIS].widen (thick / 2);
- return Stencil (b, list);
+ return Stencil (b, total.expr ());
}
MAKE_SCHEME_CALLBACK (Line_spanner, after_line_breaking, 1);
Index: lilypond/lily/lookup.cc
diff -u lilypond/lily/lookup.cc:1.185 lilypond/lily/lookup.cc:1.186
--- lilypond/lily/lookup.cc:1.185 Tue May 3 22:22:56 2005
+++ lilypond/lily/lookup.cc Sat May 28 13:43:23 2005
@@ -100,10 +100,12 @@
Stencil
Lookup::horizontal_line (Interval w, Real th)
{
- SCM at = scm_list_n (ly_symbol2scm ("horizontal-line"),
+ SCM at = scm_list_n (ly_symbol2scm ("draw-line"),
+ scm_make_real (th),
scm_make_real (w[LEFT]),
+ scm_make_real (0),
scm_make_real (w[RIGHT]),
- scm_make_real (th),
+ scm_make_real (0),
SCM_UNDEFINED);
Box box;
@@ -644,6 +646,19 @@
Stencil
Lookup::repeat_slash (Real w, Real s, Real t)
{
+#if 0
+ // TODO
+ Array<Offset> points ;
+ Real blotdiameter = 0.0;
+
+ Offset p1(0, 0);
+ Offset p2(w, w*s);
+
+
+
+ return Lookup::round_filled_polygon (points, blotdiameter);
+#endif
+
SCM wid = scm_make_real (w);
SCM sl = scm_make_real (s);
SCM thick = scm_make_real (t);
Index: lilypond/lily/note-head.cc
diff -u lilypond/lily/note-head.cc:1.138 lilypond/lily/note-head.cc:1.139
--- lilypond/lily/note-head.cc:1.138 Thu May 5 22:13:58 2005
+++ lilypond/lily/note-head.cc Sat May 28 13:43:23 2005
@@ -86,43 +86,6 @@
return internal_print (me, &idx).smobbed_copy ();
}
-MAKE_SCHEME_CALLBACK (Note_head, brew_ez_stencil, 1);
-SCM
-Note_head::brew_ez_stencil (SCM smob)
-{
- Grob *me = unsmob_grob (smob);
- int l = Note_head::get_balltype (me);
-
- int b = (l >= 2);
-
- SCM cause = me->get_property ("cause");
- SCM spitch = unsmob_music (cause)->get_property ("pitch");
- Pitch *pit = unsmob_pitch (spitch);
-
- SCM idx = scm_int2num (pit->get_notename ());
- SCM names = me->get_property ("note-names");
- SCM charstr = SCM_EOL;
- if (scm_is_vector (names))
- charstr = scm_vector_ref (names, idx);
- else
- {
- char s[2] = "a";
- s[0] = (pit->get_notename () + 2)%7 + 'a';
- s[0] = toupper (s[0]);
- charstr = scm_makfrom0str (s);
- }
-
- SCM at = scm_list_n (ly_symbol2scm ("ez-ball"),
- charstr,
- scm_int2num (b),
- scm_int2num (1 - b),
- SCM_UNDEFINED);
- Box bx (Interval (0, 1.0), Interval (-0.5, 0.5));
- Stencil m (bx, at);
-
- return m.smobbed_copy ();
-}
-
Real
Note_head::stem_attachment_coordinate (Grob *me, Axis a)
{
Index: lilypond/lily/stencil-scheme.cc
diff -u lilypond/lily/stencil-scheme.cc:1.43
lilypond/lily/stencil-scheme.cc:1.44
--- lilypond/lily/stencil-scheme.cc:1.43 Fri Apr 8 18:34:41 2005
+++ lilypond/lily/stencil-scheme.cc Sat May 28 13:43:24 2005
@@ -258,6 +258,20 @@
return find_expression_fonts (stil->expr ());
}
+
+LY_DEFINE (ly_stencil_in_color, "ly:stencil-in-color",
+ 4, 0, 0, (SCM stc, SCM r, SCM g, SCM b),
+ "Put @var{stc} in a different color.")
+{
+ Stencil *stil = unsmob_stencil (stc);
+ SCM_ASSERT_TYPE (stil, stc, SCM_ARG1, __FUNCTION__, "Stencil");
+ return Stencil (stil->extent_box (),
+ scm_list_3 (ly_symbol2scm ("color"),
+ scm_list_3 (r, g, b),
+ stil->expr ())).smobbed_copy ();
+}
+
+
struct Stencil_interpret_arguments
{
SCM func;
Index: lilypond/lily/stencil.cc
diff -u lilypond/lily/stencil.cc:1.40 lilypond/lily/stencil.cc:1.41
--- lilypond/lily/stencil.cc:1.40 Tue May 3 11:31:50 2005
+++ lilypond/lily/stencil.cc Sat May 28 13:43:24 2005
@@ -190,6 +190,20 @@
add_stencil (moved_to_edge (a, d, s, padding, minimum));
}
+
+
+Stencil
+Stencil::in_color (Real r, Real g, Real b) const
+{
+ Stencil new_stencil (extent_box (),
+ scm_list_3 (ly_symbol2scm ("color"),
+ scm_list_3 (scm_from_double (r),
+ scm_from_double (g),
+ scm_from_double (b)),
+ expr ()));
+ return new_stencil;
+}
+
/****************************************************************/
void
@@ -289,4 +303,3 @@
return fl.fonts_;
}
-
Index: lilypond/lily/system-start-delimiter.cc
diff -u lilypond/lily/system-start-delimiter.cc:1.98
lilypond/lily/system-start-delimiter.cc:1.99
--- lilypond/lily/system-start-delimiter.cc:1.98 Sat May 28 01:12:41 2005
+++ lilypond/lily/system-start-delimiter.cc Sat May 28 13:43:24 2005
@@ -19,45 +19,6 @@
#include "lookup.hh"
#include "item.hh"
-Stencil
-System_start_delimiter::old_staff_bracket (Grob *me, Real height)
-{
- Real arc_height = scm_to_double (me->get_property ("arch-height"));
-
- SCM at = scm_list_n (ly_symbol2scm ("bracket"),
- me->get_property ("arch-angle"),
- me->get_property ("arch-width"),
- scm_make_real (arc_height),
- scm_make_real (height),
- me->get_property ("arch-thick"),
- me->get_property ("thickness"),
- SCM_UNDEFINED);
-
- /*
- TODO: sort this out.
-
- Another thing:
- In system-start-delimiter.cc I see the line
-
- Real h = height + 2 * arc_height;
-
- But I really think that you mean
-
- Real h = height + 2 * arc_width;
-
- (arc_height changes the x-axis-size of arc ; arc_width changes the
- y-axis-size)
- Will not fix it since I'm not sure.
-
- */
-
- Real h = height + 2 * arc_height;
- Box b (Interval (0, 1.5), Interval (-h / 2, h / 2));
- Stencil mol (b, at);
- mol.align_to (X_AXIS, CENTER);
- return mol;
-}
-
Stencil
Index: lilypond/ly/engraver-init.ly
diff -u lilypond/ly/engraver-init.ly:1.233 lilypond/ly/engraver-init.ly:1.234
--- lilypond/ly/engraver-init.ly:1.233 Sun May 15 16:39:24 2005
+++ lilypond/ly/engraver-init.ly Sat May 28 13:43:24 2005
@@ -575,12 +575,6 @@
verticallySpacedContexts = #'(Staff)
}
-EasyNotation = \context { %% TODO: why \context override?
- \Score
- \override NoteHead #'print-function = #Note_head::brew_ez_stencil
- \override NoteHead #'Y-extent-callback = #'()
- \override NoteHead #'X-extent-callback = #'()
-}
Index: lilypond/ly/property-init.ly
diff -u lilypond/ly/property-init.ly:1.72 lilypond/ly/property-init.ly:1.73
--- lilypond/ly/property-init.ly:1.72 Mon May 23 18:23:56 2005
+++ lilypond/ly/property-init.ly Sat May 28 13:43:24 2005
@@ -49,8 +49,8 @@
setEasyHeads = \sequential {
\override NoteHead #'print-function = #Note_head::brew_ez_stencil
- \override NoteHead #'Y-extent-callback = #'()
- \override NoteHead #'X-extent-callback = #'()
+ \override NoteHead #'font-size = #-7
+ \override NoteHead #'font-family = #'sans
}
aikenHeads = \set shapeNoteStyles = ##(do re mi fa #f la ti)
Index: lilypond/ps/music-drawing-routines.ps
diff -u lilypond/ps/music-drawing-routines.ps:1.34
lilypond/ps/music-drawing-routines.ps:1.35
--- lilypond/ps/music-drawing-routines.ps:1.34 Tue May 3 22:22:56 2005
+++ lilypond/ps/music-drawing-routines.ps Sat May 28 13:43:24 2005
@@ -196,72 +196,6 @@
closepath fill
} bind def
-
-/draw_white_text % text scale font
-{
- %font
- findfont
- %scale
- exch scalefont setfont
- 1 setgray
- 0 0 moveto
- %-0.05 -0.05 moveto
- % text
- show
-} bind def
-
-/draw_ez_ball % ch letter_col ball_col font
-{
- % font
- findfont 0.7 scalefont setfont
- 0.1 setlinewidth
- 0 0 moveto
- 0 setgray
- 0.5 0 0.5 0 360 arc closepath fill stroke
- % ball_col
- 1 eq {
- 0.01 setlinewidth
- 1 setgray
- 0.5 0 0.4 0 360 arc closepath
- fill stroke
- } if
- % letter_col
- setgray
- % 0.25 is empiric centering. Change to taste
- 0.25 -0.25 moveto
- % ch
- show
-} bind def
-
-% Simple, but does it work everywhere?
-% Han-Wen reports that one printer (brand?) at cs.uu.nl chokes on this,
-% reverted for now -- jcn
-%
-% The filled circles are drawn by setting the linewidth
-% to 2*radius and drawing a point.
-/simple_draw_ez_ball % ch letter_col ball_col font
-{
- % font
- findfont 0.85 scalefont setfont
- /origin { 0.45 0 } def
- 0 setgray
- 1.1 setlinewidth
- origin moveto
- origin lineto stroke
- % ball_col
- setgray
- 0.9 setlinewidth
- origin moveto
- origin lineto stroke
- % letter_col
- setgray
- % 0.25 is empiric centering. Change to taste
- origin moveto
- -0.28 -0.30 rmoveto
- % ch
- show
-} bind def
-
% this is for drawing slurs.
/draw_bezier_sandwich % thickness controls
{
@@ -296,16 +230,7 @@
filled { fill } if
} bind def
-/draw_white_dot % x1 y2 R
-{
-% 0 360 arc fill stroke
- 0 360 arc closepath % fill stroke
-gsave
- 1 setgray fill
-grestore
-% 0 360 arc closepath % fill stroke
- 0.05 setlinewidth 0 setgray stroke
-} bind def
+
/draw_dashed_line % dash thickness dx dy
{
@@ -331,126 +256,4 @@
} bind def
-% a b c d subvec == a-c b-d
-/subvec {
- 3 2 roll exch sub
- 3 1 roll
- sub exch
-} bind def
-
-
-% centre? zzwidth zzheight thickness x0 y0 x1 y1
-/draw_zigzag_line {
- newpath
- 6 dict begin
-
- 4 2 roll % zzuw zzh th x1 y1 x0 y0
- 2 copy
- moveto
- subvec % zzuw zzh th dx dy
-
- 2 copy euclidean_length /l exch def
- l div /uy exch def
- l div /ux exch def
- setlinewidth
- /zzh exch def
- l exch div round /n exch def
- n 0 gt { %if
- /zzw l n 2 mul div def
- {
- uy zzh mul 2 div ux zzh mul -2 div rmoveto
- } if
- 1 1 n {
- ux zzw mul uy zzh mul sub
- uy zzw mul ux zzh mul add
- rlineto
- ux zzw mul uy zzh mul add
- uy zzw mul ux zzh mul sub
- rlineto
- } bind for
- }{ %else
- pop
- ux l mul uy l mul rlineto
- } ifelse
- stroke
- end
-} bind def
-
-/bracket_traject
-{
- /traject_ds exch def
- /traject_alpha exch def
- traject_ds traject_alpha sin mul add
- exch
- traject_ds traject_alpha cos mul add
- exch
-} bind def
-
-
-
-/half_bracket
-{
-%6
- 0 0
-%5a
- bracket_thick arch_height add half_height arch_thick sub arch_width add
- arch_angle arch_height -0.15 mul bracket_traject
-%5b
- bracket_thick 0.5 mul half_height
- 0 arch_height 0.5 mul bracket_traject
-%5c
- 0 half_height
-%4a
- bracket_thick half_height arch_thick sub
- 0 arch_height 0.4 mul bracket_traject
-%4b
- bracket_thick arch_height add half_height arch_thick sub arch_width add
- arch_angle arch_height -0.25 mul bracket_traject
-%4c
- bracket_thick arch_height add half_height arch_thick sub arch_width add
-%3
- bracket_thick half_height arch_thick sub
-%2
- bracket_thick 0
-%1
- 0 0
-} bind def
-
-/draw_half_bracket {
- moveto
- lineto
- lineto
- curveto
- curveto
- lineto
- gsave
- fill
- grestore
-} bind def
-
-/draw_bracket % arch_angle arch_width arch_height bracket_height arch_thick
bracket_thick
-{
- % urg
-
- /bracket_thick exch def
- /arch_thick exch def
- /bracket_height exch def
- /arch_height exch def
- /arch_width exch def
- /arch_angle exch def
-
- bracket_height 2 div bracket_thick add /half_height exch def
- bracket_thick 0.5 mul setlinewidth
- 1 setlinecap
- 1 setlinejoin
- half_bracket
- 20 copy
- 1 -1 scale
- draw_half_bracket
- stroke
- 1 -1 scale
- draw_half_bracket
- stroke
-} bind def
-
%end music-drawing-routines.ps
Index: lilypond/scm/lily.scm
diff -u lilypond/scm/lily.scm:1.347 lilypond/scm/lily.scm:1.348
--- lilypond/scm/lily.scm:1.347 Fri May 27 12:00:15 2005
+++ lilypond/scm/lily.scm Sat May 28 13:43:24 2005
@@ -165,10 +165,8 @@
dashed-slur
dot
draw-line
- ez-ball
filledbox
glyph-string
- horizontal-line
named-glyph
polygon
repeat-slash
Index: lilypond/scm/output-gnome.scm
diff -u lilypond/scm/output-gnome.scm:1.92 lilypond/scm/output-gnome.scm:1.93
--- lilypond/scm/output-gnome.scm:1.92 Tue May 3 11:31:51 2005
+++ lilypond/scm/output-gnome.scm Sat May 28 13:43:24 2005
@@ -327,9 +327,6 @@
(define (grob-cause offset grob)
grob)
-;; WTF is this in every backend?
-(define (horizontal-line x1 x2 thickness)
- (filledbox (- x1) (- x2 x1) (* .5 thickness) (* .5 thickness)))
(define (named-glyph font name)
(text font (ly:font-glyph-name-to-charcode font name)))
Index: lilypond/scm/output-ps.scm
diff -u lilypond/scm/output-ps.scm:1.140 lilypond/scm/output-ps.scm:1.141
--- lilypond/scm/output-ps.scm:1.140 Fri May 20 18:45:44 2005
+++ lilypond/scm/output-ps.scm Sat May 28 13:43:24 2005
@@ -23,7 +23,6 @@
dot
white-dot
beam
- bracket
dashed-slur
char
setcolor
@@ -31,12 +30,10 @@
named-glyph
dashed-line
zigzag-line
- ez-ball
comment
repeat-slash
placebox
bezier-sandwich
- horizontal-line
embedded-ps
filledbox
round-filled-box
@@ -100,12 +97,6 @@
(ly:number->string thick)
" draw_bezier_sandwich"))
-(define (bracket arch_angle arch_width arch_height height arch_thick thick)
- (string-append
- (ly:numbers->string
- (list arch_angle arch_width arch_height height arch_thick thick))
- " draw_bracket"))
-
(define (char font i)
(string-append
(ps-font-command font) " setfont "
@@ -158,15 +149,6 @@
(define (embedded-ps string)
string)
-;; FIXME.
-(define (ez-ball ch letter-col ball-col)
- (string-append
- " (" ch ") "
- (ly:numbers->string (list letter-col ball-col))
- ;; FIXME: barf
- " /Helvetica-Bold "
- " draw_ez_ball"))
-
;; FIXME: use draw_round_box
(define (filledbox breapth width depth height)
(string-append (ly:numbers->string (list breapth width depth height))
@@ -229,10 +211,6 @@
(caddr location))
"")))))
-;; WTF is this in every backend?
-(define (horizontal-line x1 x2 th)
- (draw-line th x1 0 x2 0))
-
(define (lily-def key val)
(let ((prefix "lilypondlayout"))
(if (string=?
@@ -316,6 +294,9 @@
(define (utf8-string pango-font-description string)
(ly:warning (_ "utf8-string encountered in PS backend")))
+
+;; TODO: FIX THIS.
+;;
(define (white-dot x y radius)
(string-append
" "
Index: lilypond/scm/output-svg.scm
diff -u lilypond/scm/output-svg.scm:1.27 lilypond/scm/output-svg.scm:1.28
--- lilypond/scm/output-svg.scm:1.27 Fri May 27 12:00:15 2005
+++ lilypond/scm/output-svg.scm Sat May 28 13:43:24 2005
@@ -279,10 +279,6 @@
(define (dashed-line thick on off dx dy)
(draw-line thick 0 0 dx dy `(style . ,(format "stroke-dasharray:~a,~a;" on
off))))
-;; WTF is this in every backend?
-(define (horizontal-line x1 x2 th)
- (filledbox (- x1) (- x2 x1) (* .5 th) (* .5 th)))
-
(define (filledbox breapth width depth height)
(round-filled-box breapth width depth height 0))
@@ -345,7 +341,3 @@
(define (utf8-string pango-font-description string)
(dispatch `(fontify ,pango-font-description ,(entity 'tspan string))))
-(define (bracket arch_angle arch_width arch_height height arch_thick thick)
- ;; FIXME.
- ""
- )
Index: lilypond/scm/output-tex.scm
diff -u lilypond/scm/output-tex.scm:1.91 lilypond/scm/output-tex.scm:1.92
--- lilypond/scm/output-tex.scm:1.91 Tue May 3 22:22:56 2005
+++ lilypond/scm/output-tex.scm Sat May 28 13:43:24 2005
@@ -26,17 +26,14 @@
dot
white-dot
beam
- bracket
dashed-slur
named-glyph
dashed-line
zigzag-line
- ez-ball
comment
repeat-slash
placebox
bezier-sandwich
- horizontal-line
filledbox
round-filled-box
text
@@ -91,9 +88,6 @@
(define (beam width slope thick blot)
(embedded-ps (list 'beam width slope thick blot)))
-(define (bracket arch_angle arch_width arch_height height arch_thick thick)
- (embedded-ps (list 'bracket arch_angle arch_width arch_height height
arch_thick thick)))
-
(define (dashed-slur thick on off lst)
(embedded-ps (list 'dashed-slur thick on off `(quote ,lst))))
@@ -120,9 +114,6 @@
(define (zigzag-line centre? zzw zzh thick dx dy)
(embedded-ps (list 'zigzag-line centre? zzw zzh thick dx dy)))
-(define (ez-ball c lst b)
- (embedded-ps (list 'ez-ball c lst b)))
-
(define (embedded-ps expr)
(let ((ps-string
(with-output-to-string
@@ -144,10 +135,6 @@
(define (bezier-sandwich lst thick)
(embedded-ps (list 'bezier-sandwich `(quote ,lst) thick)))
-;; WTF is this in every backend?
-(define (horizontal-line x1 x2 th)
- (filledbox (- x1) (- x2 x1) (* .5 th) (* .5 th)))
-
(define (filledbox breapth width depth height)
(if (and #f (defined? 'ps-testing))
(embedded-ps
_______________________________________________
Lilypond-cvs mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/lilypond-cvs