From ae32937afe6f0bdaf24faf1a57ff3d3537e08b34 Mon Sep 17 00:00:00 2001 From: Valentin Villenave Date: Fri, 29 Oct 2010 10:24:04 +0200 Subject: [PATCH] Allow predefined diagrams regardless of note names language. This should make the @warning in NR 1.1.1 "note names" no longer needed. --- Documentation/de/notation/pitches.itely | 6 ------ Documentation/es/notation/pitches.itely | 6 ------ Documentation/fr/notation/pitches.itely | 6 ------ Documentation/notation/pitches.itely | 5 ----- ly/declarations-init.ly | 2 ++ ly/language-init.ly | 5 ++--- ly/predefined-guitar-fretboards.ly | 4 ++++ ly/predefined-ukulele-fretboards.ly | 5 +++++ 8 files changed, 13 insertions(+), 26 deletions(-) diff --git a/Documentation/de/notation/pitches.itely b/Documentation/de/notation/pitches.itely index 807d9116df..6946922777 100644 --- a/Documentation/de/notation/pitches.itely +++ b/Documentation/de/notation/pitches.itely @@ -477,12 +477,6 @@ Zum Beispiel fügt man mit @code{@w{\include "deutsch.ly"}} die Notendefinitionen für die deutsche Sprache am Anfang der Datei hinzu -@warning{Weil in einigen @code{\include}-Dateien (wie -beispielsweise @code{@w{predefined-fretboards.ly}}) die niederländischen -(Standard-)Notenbezeichnungen benutzt werden, muss der -@code{@bs{}include}-Befehl für die Sprachdatei nach allen -anderen LilyPond-eigenen Dateien gesetzt werden.} - In der Tabelle sind die existierenden Sprachdefinitionen mit den dazugehörigen Notenbezeichnungen dargestellt. diff --git a/Documentation/es/notation/pitches.itely b/Documentation/es/notation/pitches.itely index 08b8d30605..97552a367b 100644 --- a/Documentation/es/notation/pitches.itely +++ b/Documentation/es/notation/pitches.itely @@ -450,12 +450,6 @@ archivo de inicio específico del idioma según aparece relacionado más abajo. Por ejemplo, para usar los nombres de las notas en español, inserte @code{@w{\include "espanol.ly"}} en el archivo de entrada. -@warning{A causa de que alguno de los otros archivos de inclusión -(como @code{@w{predefined-fretboards.ly}}) utilizan los nombres de -nota predeterminados (holandeses), la instrucción @code{@bs{}include} -para el archivo de idioma se debe colocar después de todos los demás -archivos de la distribución de LilyPond.} - Los archivos de idioma disponibles y los nombres de las notas que definen son los siguientes: diff --git a/Documentation/fr/notation/pitches.itely b/Documentation/fr/notation/pitches.itely index 4eda2db296..3468713eb4 100644 --- a/Documentation/fr/notation/pitches.itely +++ b/Documentation/fr/notation/pitches.itely @@ -440,12 +440,6 @@ langues. Pour les utiliser, incluez le fichier d'initialisation spécifique à la langue voulue. Par exemple, pour les langues romanes, ajoutez @w{@code{\include "italiano.ly"}} au début du fichier source. -@warning{Dans la mesure où certains fichiers d'initialisation, comme -@w{@code{predefined-fretboards.ly}}, utilisent les conventions bataves, -la commande @code{@bs{}include} concernant la langue que vous désirez -utiliser doît intervenir après toutes les autres inclusions de fichier -d'initialisation de LilyPond.} - Les fichiers de langue disponibles ainsi que les noms de note utilisés sont les suivants@tie{}: diff --git a/Documentation/notation/pitches.itely b/Documentation/notation/pitches.itely index 0451385176..f63a815316 100644 --- a/Documentation/notation/pitches.itely +++ b/Documentation/notation/pitches.itely @@ -443,11 +443,6 @@ other languages. To use them, include the language-specific init file listed below. For example, to use English note names, add @code{@w{\include "english.ly"}} to the input file. -@warning{Because some other include files (such as @code{@w{predefined-fretboards.ly}}) -use default (Nederlands) note names, the @code{@bs{}include} -command for the language file should be placed after all other -LilyPond distribution files.} - The available language files and the note names they define are: @quotation diff --git a/ly/declarations-init.ly b/ly/declarations-init.ly index 5faf35bee0..bddd34e582 100644 --- a/ly/declarations-init.ly +++ b/ly/declarations-init.ly @@ -30,6 +30,8 @@ maxima = #(ly:make-duration -3 0) \include "toc-init.ly" \include "language-init.ly" +pitchnames = #default-language +#(ly:parser-set-note-names parser pitchnames) \include "drumpitch-init.ly" \include "chord-modifiers-init.ly" diff --git a/ly/language-init.ly b/ly/language-init.ly index 17a3aa7cb1..4ead6005ad 100644 --- a/ly/language-init.ly +++ b/ly/language-init.ly @@ -956,6 +956,5 @@ )) %% default note names are dutch -pitchnames = #(ly:assoc-get 'nederlands language-pitch-names '()) -#(ly:parser-set-note-names parser pitchnames) - +#(define default-language + (ly:assoc-get 'nederlands language-pitch-names '())) diff --git a/ly/predefined-guitar-fretboards.ly b/ly/predefined-guitar-fretboards.ly index c6d30b0dc2..0211ca98a7 100644 --- a/ly/predefined-guitar-fretboards.ly +++ b/ly/predefined-guitar-fretboards.ly @@ -15,6 +15,9 @@ %%%% You should have received a copy of the GNU General Public License %%%% along with LilyPond. If not, see . +% chord definitions require default pitchnames +#(define prev-pitchnames pitchnames) +#(set! pitchnames default-language) \include "predefined-guitar-ninth-fretboards.ly" @@ -449,3 +452,4 @@ #guitar-tuning #(offset-fret 1 (chord-shape 'bes:m7 guitar-tuning)) +#(set! pitchnames prev-pitchnames) diff --git a/ly/predefined-ukulele-fretboards.ly b/ly/predefined-ukulele-fretboards.ly index 554c828fe4..827b04da12 100644 --- a/ly/predefined-ukulele-fretboards.ly +++ b/ly/predefined-ukulele-fretboards.ly @@ -21,6 +21,9 @@ %%%% ukulele hall of fame museum website (http://www.ukulele.org/), %%%% kiwi ukulele website (http://www.kiwiukulele.co.nz/) +% chord definitions require default pitchnames +#(define prev-pitchnames pitchnames) +#(set! pitchnames default-language) %%% a chords @@ -803,3 +806,5 @@ \storePredefinedDiagram #default-fret-table \chordmode {aes:9} #ukulele-tuning #"1-1;o;2-3;1-2;" + +#(set! pitchnames prev-pitchnames) -- 2.39.2