From 5e4ca892097b1adc64c12cb75e4057e091994e04 Mon Sep 17 00:00:00 2001 From: Mike Solomon Date: Mon, 9 Jan 2012 08:26:09 +0100 Subject: [PATCH] Rewrites some embedded PostScript using markup commands --- ...-notation-for-guitar--with-text-spanner.ly | 23 +++++-------------- .../snippets/formatting-lyrics-syllables.ly | 1 - Documentation/snippets/hymn-template.ly | 1 - ...-notation-for-guitar--with-text-spanner.ly | 21 ++++------------- .../snippets/partcombine-and-autobeamoff.ly | 2 -- 5 files changed, 11 insertions(+), 37 deletions(-) diff --git a/Documentation/snippets/bar-chords-notation-for-guitar--with-text-spanner.ly b/Documentation/snippets/bar-chords-notation-for-guitar--with-text-spanner.ly index a34f7fae08..a40fbd4ab5 100644 --- a/Documentation/snippets/bar-chords-notation-for-guitar--with-text-spanner.ly +++ b/Documentation/snippets/bar-chords-notation-for-guitar--with-text-spanner.ly @@ -4,8 +4,8 @@ % and then run scripts/auxiliar/makelsr.py % % This file is in the public domain. -%% Note: this file works from version 2.15.20 -\version "2.15.20" +%% Note: this file works from version 2.15.24 +\version "2.15.24" \header { lsrtags = "chords, fretted-strings" @@ -27,20 +27,9 @@ The syntax is @code{\\bbarre #'fret_number' @{ notes @} } %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %% %%%%%%% Cut here ----- Start 'bbarred.ly' -%% PostScript ------------------------------- -pScript= \markup { - \with-dimensions #'(0 . 0.8) #'(0 . 2.0) - \postscript #" - 0.15 setlinewidth - /Times-Roman findfont - 2.0 scalefont - setfont - (C)show %%change with B if you prefer - %(B)show %%change with C if you prefer - stroke - 0.7 -0.5 moveto - 0.7 1.7 lineto - stroke" +%% C with slash ------------------------------- +cWithSlash = \markup { + \combine \roman C \translate #'(0.6 . -0.4) \draw-line #'(0 . 2.0) } %% Span ----------------------------------- %% Syntax: \bbarre #"text" { notes } - text = any number of box @@ -78,7 +67,7 @@ bbarre= #(define-music-function (barre location str music) (string? ly:music?) \once \override TextSpanner #'to-barline = ##f \once \override TextSpanner #'bound-details = #'((left (Y . 0) (padding . 0.25) (attach-dir . -2)) (right (Y . 0) (padding . 0.25) (attach-dir . 2))) \once \override TextSpanner #'bound-details #'right #'text = \markup { \draw-line #'( 0 . -.5) } - \once \override TextSpanner #'bound-details #'left #'text = \markup { \pScript #str } + \once \override TextSpanner #'bound-details #'left #'text = \markup { \cWithSlash #str } %% uncomment this line for make full barred % \once \override TextSpanner #'bound-details #'left #'text = \markup { "B" #str } #} diff --git a/Documentation/snippets/formatting-lyrics-syllables.ly b/Documentation/snippets/formatting-lyrics-syllables.ly index fa99151b8e..f64e9f012a 100644 --- a/Documentation/snippets/formatting-lyrics-syllables.ly +++ b/Documentation/snippets/formatting-lyrics-syllables.ly @@ -16,7 +16,6 @@ zu formatieren. " doctitlede = "Silben im Gesangstext formatieren" - %% Translation of GIT committish: d9d1da30361a0bcaea1ae058eb1bc8dd3a5b2e4c texidocfr = " Le mode markup permet d'individualiser la mise en forme de certaines syllabes. diff --git a/Documentation/snippets/hymn-template.ly b/Documentation/snippets/hymn-template.ly index c121eed510..00ddc15638 100644 --- a/Documentation/snippets/hymn-template.ly +++ b/Documentation/snippets/hymn-template.ly @@ -27,7 +27,6 @@ strofe come testo separato sotto la musica. " doctitleit = "Modello per inno" - %% Translation of GIT committish: ab9e3136d78bfaf15cc6d77ed1975d252c3fe506 texidocde = " diff --git a/Documentation/snippets/new/bar-chords-notation-for-guitar--with-text-spanner.ly b/Documentation/snippets/new/bar-chords-notation-for-guitar--with-text-spanner.ly index 0c1100af4b..3775949b05 100644 --- a/Documentation/snippets/new/bar-chords-notation-for-guitar--with-text-spanner.ly +++ b/Documentation/snippets/new/bar-chords-notation-for-guitar--with-text-spanner.ly @@ -1,4 +1,4 @@ -\version "2.15.20" +\version "2.15.24" \header { lsrtags = "chords, fretted-strings" @@ -19,20 +19,9 @@ The syntax is @code{\\bbarre #'fret_number' @{ notes @} } %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %% %%%%%%% Cut here ----- Start 'bbarred.ly' -%% PostScript ------------------------------- -pScript= \markup { - \with-dimensions #'(0 . 0.8) #'(0 . 2.0) - \postscript #" - 0.15 setlinewidth - /Times-Roman findfont - 2.0 scalefont - setfont - (C)show %%change with B if you prefer - %(B)show %%change with C if you prefer - stroke - 0.7 -0.5 moveto - 0.7 1.7 lineto - stroke" +%% C with slash ------------------------------- +cWithSlash = \markup { + \combine \roman C \translate #'(0.6 . -0.4) \draw-line #'(0 . 2.0) } %% Span ----------------------------------- %% Syntax: \bbarre #"text" { notes } - text = any number of box @@ -70,7 +59,7 @@ bbarre= #(define-music-function (barre location str music) (string? ly:music?) \once \override TextSpanner #'to-barline = ##f \once \override TextSpanner #'bound-details = #'((left (Y . 0) (padding . 0.25) (attach-dir . -2)) (right (Y . 0) (padding . 0.25) (attach-dir . 2))) \once \override TextSpanner #'bound-details #'right #'text = \markup { \draw-line #'( 0 . -.5) } - \once \override TextSpanner #'bound-details #'left #'text = \markup { \pScript #str } + \once \override TextSpanner #'bound-details #'left #'text = \markup { \cWithSlash #str } %% uncomment this line for make full barred % \once \override TextSpanner #'bound-details #'left #'text = \markup { "B" #str } #} diff --git a/Documentation/snippets/partcombine-and-autobeamoff.ly b/Documentation/snippets/partcombine-and-autobeamoff.ly index bb6f54ba50..d5b3340110 100644 --- a/Documentation/snippets/partcombine-and-autobeamoff.ly +++ b/Documentation/snippets/partcombine-and-autobeamoff.ly @@ -47,7 +47,6 @@ necesario hacer tres llamadas a @code{\\autoBeamOff}. " doctitlees = "Partcombine y autoBeamOff" - %% Translation of GIT committish: ab9e3136d78bfaf15cc6d77ed1975d252c3fe506 texidocde = " @@ -79,7 +78,6 @@ wenn man es mit @code{\\partcombine} verwendet, muss @code{\\autoBeamOff} " doctitlede = "Partcombine und autoBeamOff" - %% Translation of GIT committish: e1a149d0cc60b02e86209387958f4028567dd366 texidocfr = " Le fonction @code{@bs{}autoBeamOff} dans le cadre d'un -- 2.39.2