+1.3.32.jcn3
+===========
+
+* Embedded newlines in text items are now allowed. This helps avoiding
+ TeX-hacking in some cases. See input/test/coriolan-margin.ly
+
+* Fixed stupid x-y interchange bug for staff-bracket. This fixes
+ placement of staff-brackets.
+
+* Fixed bracket/arch-thickness interchange bug, and made bracket a bit
+ thinner.
+
+* Fixed slur/bezier-beautiful name mismatch. This should fix the steep
+ slurs that were apparently reintroduced in 1.3.29.
+
1.3.32.jcn2
===========
MAJOR_VERSION=1
MINOR_VERSION=3
PATCH_LEVEL=32
-MY_PATCH_LEVEL=jcn2
+MY_PATCH_LEVEL=jcn3
# use the above to send patches: MY_PATCH_LEVEL is always empty for a
# released version.
--- /dev/null
+
+\header{
+%% URG
+Clarinetti ="\\vbox to0pt{\vss\\hbox to0pt{\\hss2 Clarinetti\\hss}\\hbox to0pt{\\hss (B\\textflat)\\hss}\vss}";
+Cl ="\\vbox to0pt{\vss\\hbox to0pt{\\hss Cl.\\hss}\\hbox to0pt{\\hss (B\\textflat)\\hss}\vss}";
+Corni ="\\vbox to0pt{\vss\\hbox to0pt{\\hss2 Corni\\hss}\\hbox to0pt{\\hss (E\\textflat)\\hss}\vss}";
+Cor ="\\vbox to0pt{\vss\\hbox to0pt{\\hss Cor.\\hss}\\hbox to0pt{\\hss (E\\textflat)\\hss}\vss}";
+Trombe ="\\vbox to0pt{\vss\\hbox to0pt{\\hss2 Trombe\\hss}\\hbox to0pt{\\hss (C)\\hss}\vss}";
+Tbe ="\\vbox to0pt{\vss\\hbox to0pt{\\hss Tbe.\\hss}\\hbox to0pt{\\hss (C)\\hss}\vss}";
+Timpani ="\\vbox to0pt{\vss\\hbox to0pt{\\hss Timpani\\hss}\\hbox to0pt{\\hss (C-G)\\hss}\vss}";
+VioloncelloContrabasso ="\\hss\\vbox to0pt{\vss\\hbox to0pt{\\hss Violoncello\\hss}\\hbox to0pt{\\hss e\\hss}\\hbox to0pt{\\hss Contrabasso\\hss}\vss}";
+VcCb ="\\hss\\vbox to0pt{\vss\\hbox to0pt{\\hss Vc.\\hss}\\hbox to0pt{\\hss Cb.\\hss}\vss}";
+}
+
+flauti = \notes \relative c' {
+ \property Staff.instrument = #"2 Flauti"
+ \property Staff.instr = #"Fl."
+ c1 \break c
+ \bar"|.";
+}
+
+oboi = \notes \relative c' {
+ \property Staff.instrument = #"2 Oboi"
+ \property Staff.instr = #"Ob."
+ c1 c
+}
+
+clarinetti = \notes \relative c' {
+ %%\property Staff.instrument = #"\\mudelaClarinetti "
+ %%\property Staff.instr = #"\\mudelaCl "
+
+ \property Staff.instrument = #"2 Clarinetti\n(B\\textflat)"
+ \property Staff.instr = #"Cl.\n(B\\textflat)"
+
+ c1 c
+}
+
+fagotti = \notes \relative c' {
+ \property Staff.instrument = #"2 Fagotti"
+ \property Staff.instr = #"Fg."
+ c1 c
+}
+
+corni = \notes \relative c' {
+ %%\property Staff.instrument = #"\\mudelaCorni "
+ %%\property Staff.instr = #"\\mudelaCor "
+
+ \property Staff.instrument = #"2 Corni\n(E\\textflat)"
+ \property Staff.instr = #"Cor.\n(E\\textflat)"
+
+ c1 c
+}
+
+trombe = \notes \relative c' {
+ %%\property Staff.instrument = #"\\mudelaTrombe "
+ %%\property Staff.instr = #"\\mudelaTbe "
+
+ \property Staff.instrument = #"2 Trombe\n(C)"
+ \property Staff.instr = #"Tbe.\n(C)"
+
+ c1 c
+}
+
+timpani = \notes \relative c' {
+ %%\property Staff.instrument = #"\\mudelaTimpani "
+ %%\property Staff.instr = #"Timp."
+
+ \property Staff.instrument = #"Timpani\n(C-G)"
+ \property Staff.instr = #"Timp."
+
+ c1 c
+}
+
+violino1 = \notes \relative c' {
+ \property Staff.instrument = #"Violino I"
+ \property Staff.instr = #"Vl. I"
+ c1 c
+}
+
+violino2 = \notes \relative c' {
+ \property Staff.instrument = #"Violino II"
+ \property Staff.instr = #"Vl. II"
+ c1 c
+}
+
+viola = \notes \relative c' {
+ \property Staff.instrument = #"Viola"
+ \property Staff.instr = #"Vla."
+ c1 c
+}
+
+violoncello = \notes \relative c' {
+ %%\property Staff.instrument = #"\\mudelaVioloncelloContrabasso "
+ %%\property Staff.instr = #"\\mudelaVcCb "
+
+ \property Staff.instrument = #"Violoncello\ne\nContrabasso"
+ \property Staff.instr = #"Vc.\nCb."
+ c1 c
+}
+
+\score {
+ <
+ \context StaffGroup ="legni" <
+ \context Staff ="flauti" \flauti
+ \context Staff ="oboi" \oboi
+ \context Staff ="clarinetti" \clarinetti
+ \context Staff ="fagotti" \fagotti
+ >
+ \context StaffGroup ="ottoni" <
+ \context Staff ="corni" \corni
+ \context Staff ="trombe" \trombe
+ >
+ \context StaffGroup ="timpani" <
+ \context Staff ="timpani" \timpani
+ >
+ \context StaffGroup ="archi" <
+ \context GrandStaff ="violini" <
+ \context Staff ="violino1" \violino1
+ \context Staff ="violino2" \violino2
+ >
+ \context Staff ="viola" \viola
+ \context Staff ="violoncello" \violoncello
+ >
+ >
+ \header{
+ title = "Coriolan";
+ subtitle = "Ouverture";
+ opus = "Opus 62";
+ composer = "Ludwig van Beethoven (1770-1827)";
+ enteredby = "JCN";
+ copyright = "public domain";
+ }
+
+ \paper {
+ indent=100.0\mm;
+ linewidth=150.0\mm;
+ \translator {
+ \StaffContext
+ \consists Staff_margin_engraver;
+ staffMarginHorizontalPadding = #-12
+ }
+ }
+}
+
--- /dev/null
+\score
+{
+ \context StaffGroup = a <
+ \context PianoStaff = b <
+ \context Staff = "c" \notes\relative c'' { b1 }
+ \context Staff = "d" \notes\relative c'' { b1 }
+ >
+ >
+
+ \paper {
+ indent=100.0\mm;
+ linewidth=150.0\mm;
+ \translator
+ {
+ \StaffContext
+ \consists Staff_margin_engraver;
+ numberOfStaffLines = #1
+
+ }
+ }
+}
#if 0
/*
urg. Why did I implement this? And did I implement this so
- clumsily? */
+ clumsily?
+
+ input/test/just-friends.ly
+ Maybe a staffgroup of just one staff would be a better solution.
+ */
SCM prop = get_property ("barAtLineStart");
if (to_boolean (prop))
{
/*
- TODO: THIS IS UGLY. Since the user has direct access to TeX
- strings, we try some halfbaked attempt to detect TeX trickery.
+ TODO: THIS IS UGLY.
+ Since the user has direct access to TeX marcos,
+ that currently provide the only way to do
+ font selection, accents etc,
+ we try some halfbaked attempt to detect this TeX trickery.
*/
String
sanitise_TeX_string (String text)
metric_l = all_fonts_global_p->find_font (style);
- if (output_global_ch == "tex")
- text = sanitise_TeX_string (text);
- else if (output_global_ch == "ps")
- text = sanitise_PS_string (text);
+ int i = text.index_i ("\\n");
+ while (i >=0 )
+ {
+ text = text.left_str (i) + "\n" + text.right_str (text.length_i () - i - 2);
+ i = text.index_i ("\\n");
+ }
- SCM at = (gh_list (ly_symbol2scm ("text"),
- ly_str02scm (text.ch_C()),
- SCM_UNDEFINED));
- at = fontify_atom (metric_l,at);
- return Molecule ( metric_l->text_dimension (text),
- at);
+ Array<String> lines = String_convert::split_arr (text, '\n');
+
+ Molecule mol;
+
+ Real kern = paper_l->get_var ("line_kern");
+
+ for (i = 0; i< lines.size (); i++)
+ {
+ /*
+ Huh? This way we'll still see \foo sequences in ps output.
+ */
+ String str = lines[i];
+ if (output_global_ch == "tex")
+ str = sanitise_TeX_string (str);
+ else if (output_global_ch == "ps")
+ str = sanitise_PS_string (str);
+
+ SCM line = (gh_list (ly_symbol2scm ("text"),
+ ly_str02scm (str.ch_C ()),
+ SCM_UNDEFINED));
+ line = fontify_atom (metric_l, line);
+ mol.add_at_edge (Y_AXIS, DOWN,
+ Molecule (metric_l->text_dimension (str), line),
+ kern);
+ }
+
+ return mol;
}
gh_double2scm (paper_l->get_var("bracket_thick")),
SCM_UNDEFINED));
- Box b ( Interval (-height/2,height/2), Interval (0,4 PT));
- Molecule m (b, at);
+ Real staff_space = paper_l->get_var ("interline");
+ Box b (Interval (0, 1.5 * staff_space), Interval (-height/2,height/2));
+ Molecule mol (b, at);
- m.translate_axis (- 4. / 3. * m.dim_[X_AXIS].length (), X_AXIS);
- return m;
+ mol.translate_axis (- mol.dim_[X_AXIS].length () / 2, X_AXIS);
+ return mol;
}
Real default_height)
{
Real length = curve_.control_[3][X_AXIS];
- Real bbc = paper_l->get_var ("bezier_beautiful");
- Real beautiful = length * default_height / bbc;
+ Real sb = paper_l->get_var ("slur_beautiful");
+ Real beautiful = length * default_height * sb;
DEBUG_OUT << to_str ("Beautiful: %f\n", beautiful);
DEBUG_OUT << to_str ("Length: %f\n", length);
#include "timing-translator.hh"
#include "text-item.hh"
#include "side-position-interface.hh"
+#include "staff-symbol-referencer.hh"
ADD_THIS_TRANSLATOR (Staff_margin_engraver);
*/
Interval iv(text_p_->extent (Y_AXIS));
text_p_->translate_axis (- iv.center (), Y_AXIS);
+
+ Real staff_space = Staff_symbol_referencer_interface (text_p_).staff_space ();
+ SCM s = get_property ("staffMarginHorizontalPadding");
+ if (gh_number_p (s))
+ {
+ text_p_->translate_axis (gh_scm2double (s) * staff_space, X_AXIS);
+ }
+ s = get_property ("staffMarginVerticalPadding");
+ if (gh_number_p (s))
+ {
+ text_p_->translate_axis (gh_scm2double (s) * staff_space, Y_AXIS);
+ }
}
}
slur_thickness = 1.2 * \stafflinethickness;
+slur_force_blowfit = 0.5;
+slur_beautiful = 0.5;
+
%{
Horizontal space between centre of notehead and slur.
slur_x_minimum = 1.5 * \staffspace;
-bezier_asymmetry = 1.0;
-bezier_beautiful = 2.0;
-
% The constants that define the valid areas for the middle control points
% Used in de_uglyfy. Bit empirical.
bezier_control1 = 1.5;
bezier_pct_in_max = 1.2;
bezier_area_steps = 1.0;
-slur_force_blowfit = 0.5;
-slur_beautiful = 0.5;
-
%{
Tie parameters
gourlay_maxmeasures = 10.;
+line_kern = \staffspace;
+
%{ Ross. page 151 lists these values, but we think that thick lines
and kernings are too thick.
barthick_thin = 1.6*\stafflinethickness;
barthick_score = 1.6*\stafflinethickness;
-bracket_arch_thick = \staffspace / 3.0;
+bracket_arch_thick = \staffspace / 4.0;
bracket_width = 2.0 * \staffspace;
-bracket_thick = 2.0 * \stafflinethickness;
+bracket_thick = \staffspace / 4.0;
bracket_arch_height = 1.5 * \staffspace;
bracket_arch_width = \bracket_arch_height;
bracket_arch_angle = 50.0;
$clarinetti_staff = \context Staff = clarinetti <
\property Staff.midiInstrument = #"clarinet"
- \property Staff.instrument = #"2 Clarinetti (B\\textflat)"
- \property Staff.instr = #"Cl. (B\\textflat)"
+ \property Staff.instrument = #"2 Clarinetti\n(B\\textflat)"
+ \property Staff.instr = #"Cl.\n(B\\textflat)"
% urg: can't; only My_midi_lexer:<non-static> () parses pitch?
%\property Staff.transposing = "bes"
\property Staff.transposing = #-2
\score{
<
- %%? \property Score . textStyle = "italic"
\legni
\ottoni
\$timpani_g
\archi
>
+ \header{
+ title = "Coriolan";
+ subtitle = "Ouverture";
+ opus = "Opus 62";
+ composer = "Ludwig van Beethoven (1770-1827)";
+ enteredby = "JCN";
+ copyright = "public domain";
+ }
\include "coriolan-paper.ly"
\include "coriolan-midi.ly"
}
$corni_staff = \context Staff = corni <
\property Staff.midiInstrument = #"french horn"
- \property Staff.instrument = #"2 Corni (E\\textflat)"
- \property Staff.instr = #"Cor. (E\\textflat)"
+ \property Staff.instrument = #"2 Corni\n(E\\textflat)"
+ \property Staff.instr = #"Cor.\n(E\\textflat)"
% urg: can't; only My_midi_lexer:<non-static> () parses pitch?
%\property Staff.transposing = "es"
\property Staff.transposing = #3
\version "1.3.4";
flauto1 = \notes \relative c {
- % do silly bar request to fix Staff_margin_engraver
- \bar ".|";
-
R1 *2 |
c'''4-.\ff r r2 |
R1 *3 |
$timpani_staff = \context Staff = timpani <
\property Staff.midiInstrument = #"timpani"
- \property Staff.instrument = #"2 Timpani (C-G)"
+ \property Staff.instrument = #"2 Timpani\n(C-G)"
\property Staff.instr = #"Timp."
\clef "bass";
\notes<
$trombe_staff = \context Staff = trombe <
\property Staff.midiInstrument = #"trumpet"
- \property Staff.instrument = #"2 Trombe (C)"
- \property Staff.instr = #"Tbe."
+ \property Staff.instrument = #"2 Trombe\n(C)"
+ \property Staff.instr = #"Tbe.\n(C)"
%\notes \context Voice=trombe <
\notes \context Staff=trombe <
% \global
c'1\ff ~ |
c |
f,4-. r r2 |
- \property Staff.instr = #"Vc. \\& Cb."
+ \property Staff.instr = #"Vc.\nCb."
r1 |
c'1\ff ~ |
c |
$violoncello_staff = \context Staff = violoncello <
\property Staff.midiInstrument = #"cello"
- \property Staff.instrument = #"Violoncello"
+ \property Staff.instrument = #"Violoncello\ne\nContrabasso"
\property Staff.instr = #"Vc."
\clef "bass";
\notes \context Voice=one<
%6
0 0
%5a
- arch_thick arch_height add half_height bracket_thick sub arch_width add
+ bracket_thick arch_height add half_height arch_thick sub arch_width add
arch_angle arch_height -0.15 mul bracket_traject
%5b
1 half_height
%5c
0 half_height
%4a
- arch_thick half_height bracket_thick sub
+ bracket_thick half_height arch_thick sub
0 arch_height 0.4 mul bracket_traject
%4b
- arch_thick arch_height add half_height bracket_thick sub arch_width add
+ bracket_thick arch_height add half_height arch_thick sub arch_width add
arch_angle arch_height -0.25 mul bracket_traject
%4c
- arch_thick arch_height add half_height bracket_thick sub arch_width add
+ bracket_thick arch_height add half_height arch_thick sub arch_width add
%3
- arch_thick half_height bracket_thick sub
+ bracket_thick half_height arch_thick sub
%2
- arch_thick 0
+ bracket_thick 0
%1
0 0
} bind def
/arch_width exch def
/arch_angle exch def
%
- bracket_height 2 div arch_thick add /half_height exch def
+ bracket_height 2 div bracket_thick add /half_height exch def
% urg: the only Level-2 PS, check effect in print
% true setstrokeadjust
1 setlinecap
(list 'tupletBracketVisibility symbol-or-boolean? 'tuplet-bracket-visibility)
))
)
-
+
(define generic-voice-properties
(list
generic-stem-properties
; fixed in 1.3.4
;(ly-gulp-file "lily.ps")
+ ;; URG: now we can't use scm output without Lily
(regexp-substitute/global #f "\n" (ly-gulp-file "lily.ps") 'pre " %\n" 'post)
"}"
"\\input lilyponddefs \\turnOnPostScript"))
(define (header-end)
(string-append
+ ;; URG: now we can't use scm output without Lily
(ly-gulp-file "lilyponddefs.ps")
" {exch pop //systemdict /run get exec} "
(ly-gulp-file "lily.ps")
(close port)
content))
+;; urg: Use when standalone, do:
+;; (define (ly-gulp-file name) (scm-gulp-file name))
(define (scm-gulp-file name)
(set! %load-path
- (cons (string-append
- (getenv 'LILYPONDPREFIX) "/ps") %load-path))
+ (cons (string-append (getenv 'LILYPONDPREFIX) "/ly")
+ (cons (string-append (getenv 'LILYPONDPREFIX) "/ps")
+ %load-path)))
(let ((path (%search-load-path name)))
(if path
(gulp-file path)