@lilypondfile[printfilename]{triplets.ly}
+
@section Slurs
@lilypondfile[printfilename]{slur-nice.ly}
@lilypondfile[printfilename]{slur-attachment-override.ly}
+@lilypondfile[printfilename]{slur-stem-broken.ly}
+
@lilypondfile[printfilename]{drarn-slurs.ly}
@lilypondfile[printfilename]{phrasing-slur.ly}
+@lilypondfile[printfilename]{slur-staccato.ly}
+
+
@section Ties
@lilypondfile[printfilename]{tie.ly}
-@ifinfo
+@ifnottex
@macro reng {word}
-@ref{ (lilypond-internals)Engraver \word\, \word\ },
+@ref{ (lilypond-internals)\word\, \word\ },
@end macro
-@end ifinfo
+@end ifnottex
-@ifnotinfo
+@iftex
@macro reng {word}
-@ref{ (lilypond-internals)Engraver \word\, \word\ }
+\word\
@end macro
-@end ifnotinfo
+@end iftex
+
+
+@ifnottex
+@macro rgrob {word}
+@ref{ (lilypond-internals)\word\, \word\ },
+
+@end macro
+@end ifnottex
+
+@iftex
+@macro rgrob {word}
+\word\
+
+@end macro
+@end iftex
+
+
+@ifnottex
+@macro rint {word}
+@ref{ (lilypond-internals)\word\, \word\ },
+
+@end macro
+@end ifnottex
+
+@iftex
+@macro rint {word}
+\word\
+
+@end macro
+@end iftex
@macro separate
@tex
-\\hbox to\\hsize{\\hfill\\vrule width1.4 cm height1.0pt\\hfill}
+\\hbox to\\hsize{\\hfill\\smallrm*\\textrm*\\smallrm*\\hfill}
@end tex
@end macro
can be forced by adding an exclamation mark @code{!} after the pitch. A
cautionary accidental,
@cindex cautionary accidental
+@cindex parenthesized accidental
i.e., an accidental within parentheses can be obtained by adding the
question mark `@code{?}' after the pitch.
@cindex @code{\key}
-Changing the key signature is done with the @code{\key} command.
+Setting or changing the key signature is done with the @code{\key}
+command.
@example
@code{\key} @var{pitch} @var{type}
@end example
This command sets the context property @code{Staff.keySignature}.
Non-standard key signatures can be specified by setting this property
-directly, see the generated documentation.
+directly, see the generated documentation for @rgrob{KeySignature}.
The printed signature is a @code{KeySignature} grob.
@node Clef
@subsection Clef
@cindex @code{\clef}
+
+The clef can be set or changed with the @code{\clef} command.
@example
- \clef @var{clefname} @code{;}
+ \clef @var{clefname}
@end example
Shortcut for
@cindex meter
@cindex @code{\time}
-The time signature is changed by the @code{\time} command. Syntax:
+The time signature is set or changed by the @code{\time}
+command. Syntax:
@example
\time @var{n}@code{/}@var{d}
@end example
generated.
Changing the value of @code{timeSignatureFraction} also causes a
-fraction to be printed. This grob is @code{TimeSignature}. There are
-many options for the layout of this grob. They are selected through the
-@code{style} grob property. See @file{input/test/time.ly} for examples.
+fraction to be printed. This grob is @code{TimeSignature}.
+
+The actual symbol that's printed can be customised with the style
+property.
+@lilypond[fragment, verbatim, singleline]
+\time 3/4 s2
+\property Staff.TimeSignature \override #'style = #'C
+\time 4/4 s2
+\property Staff.TimeSignature \override #'style = #'()
+\time 4/4 s2
+\property Staff.TimeSignature \override #'style = #'C
+\time 2/2 s2
+@end lilypond
+
+There are many more options for the layout of this grob. They are
+selected through the @code{style} grob property.
+
+@c FIXME: this isn't documented except in example?
+See
+@file{input/test/time.ly} for examples.
@c . {Partial}
@subsection Partial
\tempo @var{duration} = @var{perminute}
@end example
-For example, @code{\tempo 4 = 76;} requests output with 76 quarter notes
+For example, @code{\tempo 4 = 76} requests output with 76 quarter notes
per minute.
@refbugs
The symbols that are printed can be modified by setting
@code{pedal@var{X}Strings}, where @var{X} is one of the pedal
-types. Refer to the generated documentation for more information.
+types. Refer to the generated documentation of @rgrob{PianoPedal} for
+more information.
@refbugs
There are a number of other properties that you can use to tweak the
behavior of part combining, refer to the automatically generated
-documentation. Look at the documentation of the responsible engravers,
-@code{Thread_devnull_engraver}, @code{Voice_devnull_engraver} and
-@code{A2_engraver}.
+documentation of @reng{Thread_devnull_engraver} and
+@reng{Voice_devnull_engraver}. Look at the documentation of the
+responsible engravers, @code{Thread_devnull_engraver},
+@code{Voice_devnull_engraver} and @code{A2_engraver}.
@refbugs
The markup is broken down and converted into a list of grob properties,
which are prepended to the property list. The @var{key}-@var{value}
pair is a grob property. A list of properties available is included in
-the generated documentation for @code{text-interface}
+the generated documentation for @rint{Text_interface}.
The following abbreviations are currently defined:
@table @code
music notation. The syntax is
@example
- @code{\paper @{} @var{[paperidentifier]} @var{items} @code{@}}
+ @code{\paper @{} [@var{paperidentifier}] @var{items} @code{@}}
@end example
where each of the items is one of
If you want to build a context from scratch, you must also supply the
following extra information:
@itemize @bullet
- @item A name, specified by @code{\name @var{contextname};}.
+ @item A name, specified by @code{\name @var{contextname}}.
@item A cooperation module. This is specified by @code{\type
-@var{typename};}.
+@var{typename}}.
@end itemize
This is an example:
--- /dev/null
+\header {
+texidoc="Manual hack for slur and staccato."
+}
+
+\paper { linewidth = -1.0 }
+
+\score {
+ \context Staff \notes\relative c'' {
+ \property Voice.Slur \override
+ #'attachment-offset = #'((0 . 1) . (0 . 1))
+ a-.( g-. )a-.
+ \property Voice.Slur \override
+ #'attachment-offset = #'((0 . 1.5) . (0 . 1.5))
+ b-.( a-. )b-.
+ }
+}
\ No newline at end of file
fragment = \notes {
+ \property Voice.noAutoBeaming = ##t
\property Voice.Stem \set #'direction = #1
\property Voice.Slur \set #'direction = #1
- d'32( d'4 )d8..
+ d'32( f'4 )d8..
\property Voice.Slur \set #'attachment = #'(stem . stem)
- d,32( d'4 )d8..
+ d,32( f'4 )d8.
}
\paper { linewidth = -1. }
/*
[TODO]
- * fix broken interstaff slurs
* should avoid stafflines with horizontal part.
* begin and end should be treated as a/acknowledge Scripts.
* smart changing of endings
o[LEFT] = ly_scm2offset (index_cell (a, LEFT));
o[RIGHT] = ly_scm2offset (index_cell (a, RIGHT));
o[d][Y_AXIS] -= (limit - slope) * dx * dir / staff_space;
- //o[d][Y_AXIS] = attachment[-d][Y_AXIS] + (dx * limit * dir / staff_space);
+
+ o[d][Y_AXIS] *= Directional_element_interface::get (me);
+
me->set_grob_property ("attachment-offset",
gh_cons (ly_offset2scm (o[LEFT]),
ly_offset2scm (o[RIGHT])));
Grob * n =sp->get_bound (dir);
if ((stem = Note_column::stem_l (n)))
{
+ Real x_extent;
+ if (Grob *head = Note_column::first_head (n))
+ x_extent = head->extent (head, X_AXIS).length ();
+ else
+ x_extent = n->extent (n, X_AXIS).length ();
if (str == "head")
{
/*
Default position is centered in X, on outer side of head Y
*/
- o += Offset (0.5 * n->extent (n,X_AXIS).length (),
+ o += Offset (0.5 * x_extent,
0.5 * staff_space
* Directional_element_interface::get (me));
}
/*
Default position is on stem X, on outer side of head Y
*/
- o += Offset (n->extent (n,X_AXIS).length ()
- * (1 + Stem::get_direction (stem)),
+ o += Offset (x_extent * (1 + Stem::get_direction (stem)),
0.5 * staff_space
* Directional_element_interface::get (me));
}
Default position is on stem X, at stem end Y
*/
o += Offset (0.5 *
- (n->extent (n,X_AXIS).length ()
- - stem->extent (stem,X_AXIS).length ())
- * (1 + Stem::get_direction (stem)),
- 0);
+ x_extent * (1 + Stem::get_direction (stem)),
+ 0);
}
}
}
- else if (str == "loose-end")
+ /*
+ If we're not a note_column, we can't be anything but a loose-end.
+ But if user has set (attachment . (stem . stem)), our string is
+ stem, not loose-end.
+
+ Hmm, maybe after-line-breaking should set this to loose-end? */
+ else // if (str == "loose-end")
{
SCM other_a = dir == LEFT ? gh_cdr (s) : gh_car (s);
if (ly_symbol2string (other_a) != "loose-end")
- {
-#if 0
- /*
- The braindead way: horizontal
- */
- o = Offset (0, get_attachment (me, -dir, common)[Y_AXIS]);
-#else
- o = broken_trend_offset (me, dir);
-#endif
-
-
- }
-
+ o = broken_trend_offset (me, dir);
}
SCM alist = me->get_grob_property ("extremity-offset-alist");
-int stemdir = stem ? Stem::get_direction (stem) : 1;
+ int stemdir = stem ? Stem::get_direction (stem) : 1;
int slurdir = gh_scm2int (me->get_grob_property ("direction"));
SCM l = scm_assoc
- (scm_listify (a,
- gh_int2scm (stemdir * dir),
- gh_int2scm (slurdir * dir),
+ (scm_listify (a,
+ gh_int2scm (stemdir * dir),
+ gh_int2scm (slurdir * dir),
SCM_UNDEFINED), alist);
if (l != SCM_BOOL_F)
{
- o += ly_scm2offset (gh_cdr (l)) * staff_space * dir;
+ Offset off = ly_scm2offset (gh_cdr (l)) * staff_space;
+ off[X_AXIS] *= dir;
+ off[Y_AXIS] *= Directional_element_interface::get (me);
+ o += off;
}
/*
- me->relative_coordinate (common[Y_AXIS], Y_AXIS);
}
- o += ly_scm2offset (index_cell (me->get_grob_property ("attachment-offset"),
- dir)) * staff_space;
+ Offset off = ly_scm2offset (index_cell (me->get_grob_property
+ ("attachment-offset"),
+ dir)) * staff_space;
+
+ off[Y_AXIS] *= Directional_element_interface::get (me);
+ o += off;
return o;
}
/*
Simply set x to middle of notehead
*/
-
- o[X_AXIS] -= 0.5 * stem_dir * col->extent (col,X_AXIS).length ();
+ Real x_extent;
+ if (Grob *head = Note_column::first_head (col))
+ x_extent = head->extent (head, X_AXIS).length ();
+ else
+ x_extent = col->extent (col, X_AXIS).length ();
+ o[X_AXIS] -= 0.5 * stem_dir * x_extent;
if ((stem_dir == dir)
&& !stem_l->extent (stem_l, Y_AXIS).empty_b ())
\property Voice.Script \revert #'direction
}
+tupletUp = {
+ \property Voice.TupletBracket \override #'direction = #1
+ \property Voice.TupletBracket \override #'direction = #1
+}
+tupletDown = {
+ \property Voice.TupletBracket \override #'direction = #-1
+ \property Voice.TupletBracket \override #'direction = #-1
+}
+tupletBoth = {
+ \property Voice.TupletBracket \revert #'direction
+ \property Voice.TupletBracket \revert #'direction
+}
+
+
cadenzaOn = \property Score.timing = ##f
cadenzaOff = {
(define default-slur-extremity-offset-alist
'(
((head 1 1) . (-0.25 . 0.25))
- ((head 1 -1) . (-0.25 . -0.25))
+ ((head 1 -1) . (-0.25 . 0.25))
((head -1 1) . (-0.25 . 0.25))
- ((head -1 -1) . (-0.85 . -0.25))
+ ((head -1 -1) . (-0.85 . 0.25))
((stem 1 1) . (0 . 0.5))
- ((stem -1 -1) . (0 . -0.5))
+ ((stem -1 -1) . (0 . 0.5))
((loose-end 1 1) . (-0.4 . 0))
((loose-end 1 -1) . (-0.4 . 0))
(define default-phrasing-slur-extremity-offset-alist
'(
((head 1 1) . (-0.25 . 1.25))
- ((head 1 -1) . (-0.25 . -1.25))
+ ((head 1 -1) . (-0.25 . 1.25))
((head -1 1) . (-0.25 . 1.25))
- ((head -1 -1) . (-0.85 . -1.25))
+ ((head -1 -1) . (-0.85 . 1.25))
((stem 1 1) . (0 . 1.5))
- ((stem -1 -1) . (0 . -1.5))
+ ((stem -1 -1) . (0 . 1.5))
((loose-end 1 1) . (-0.4 . 0))
((loose-end 1 -1) . (-0.4 . 0))
if 1:
def conv (str):
- str = re.sub ('([Cc])horda', '\\1orda', str)
+ str = re.sub ('([Cc])hord([ea])', '\\1ord\\2', str)
return str
conversions.append (((1,3,144), conv, 'Chorda -> Corda'))