From: David Kastrup Date: Sun, 23 Oct 2011 16:50:46 +0000 (+0200) Subject: Rename \markuplines to \markuplist (before running convert-ly) X-Git-Tag: release/2.15.17-1~42 X-Git-Url: https://git.donarmstrong.com/?a=commitdiff_plain;h=2e7e9b0b2bb077c3ec621c049555ddaed1724eb3;p=lilypond.git Rename \markuplines to \markuplist (before running convert-ly) --- diff --git a/lily/lily-lexer.cc b/lily/lily-lexer.cc index 6c1336744b..1298604f12 100644 --- a/lily/lily-lexer.cc +++ b/lily/lily-lexer.cc @@ -67,7 +67,7 @@ static Keyword_ent the_key_tab[] {"lyricsto", LYRICSTO}, {"mark", MARK}, {"markup", MARKUP}, - {"markuplines", MARKUPLINES}, + {"markuplist", MARKUPLIST}, {"midi", MIDI}, {"name", NAME}, {"new", NEWCONTEXT}, diff --git a/lily/parser.yy b/lily/parser.yy index f2ef9b0cb5..9b2f2683e7 100644 --- a/lily/parser.yy +++ b/lily/parser.yy @@ -58,7 +58,7 @@ or %right FUNCTION_ARGUMENTS MARKUP LYRICS_STRING MARKUP_IDENTIFIER STRING STRING_IDENTIFIER - MARKUPLINES WITH CONTEXT_MOD_IDENTIFIER MARKUPLINES_IDENTIFIER + MARKUPLIST WITH CONTEXT_MOD_IDENTIFIER MARKUPLIST_IDENTIFIER SCORE BOOK BOOKPART PAPER LAYOUT MIDI SEQUENTIAL SIMULTANEOUS DOUBLE_ANGLE_OPEN MUSIC_IDENTIFIER '{' PITCH_IDENTIFIER NOTENAME_PITCH TONICNAME_PITCH @@ -225,7 +225,7 @@ void set_music_properties (Music *p, SCM a); %token LYRICSTO "\\lyricsto" %token MARK "\\mark" %token MARKUP "\\markup" -%token MARKUPLINES "\\markuplines" +%token MARKUPLIST "\\markuplist" %token MIDI "\\midi" %token NAME "\\name" %token NOTEMODE "\\notemode" @@ -322,7 +322,7 @@ If we give names, Bison complains. %token MARKUP_FUNCTION %token MARKUP_LIST_FUNCTION %token MARKUP_IDENTIFIER -%token MARKUPLINES_IDENTIFIER +%token MARKUPLIST_IDENTIFIER %token MUSIC_FUNCTION %token MUSIC_IDENTIFIER %token NOTENAME_PITCH @@ -2642,10 +2642,10 @@ lyric_markup: ; full_markup_list: - MARKUPLINES_IDENTIFIER { + MARKUPLIST_IDENTIFIER { $$ = $1; } - | MARKUPLINES + | MARKUPLIST { PARSER->lexer_->push_markup_state (); } markup_list { $$ = $3; @@ -2678,7 +2678,7 @@ markup_top: ; markup_list: - MARKUPLINES_IDENTIFIER { + MARKUPLIST_IDENTIFIER { $$ = $1; } | markup_composed_list { @@ -2879,7 +2879,7 @@ Lily_lexer::try_special_identifiers (SCM *destination, SCM sid) return MARKUP_IDENTIFIER; } else if (Text_interface::is_markup_list (sid)) { *destination = sid; - return MARKUPLINES_IDENTIFIER; + return MARKUPLIST_IDENTIFIER; } return -1; diff --git a/python/convertrules.py b/python/convertrules.py index f1fab5c0a2..bbba578e48 100644 --- a/python/convertrules.py +++ b/python/convertrules.py @@ -3257,6 +3257,17 @@ def conv (str): r"#(define \g<2> #{ \\stringTuning\g<3> #})", str) return str +@rule ((2, 15, 17), "\\markuplines -> \\markuplist") +def conv (str): + str = re.sub (r""" +\\markuplines( +)([^ ].*) + \1([^ ])""", r""" +\\markuplist\g<1>\g<2> + \g<1>\g<3>""", str) + str = re.sub (r"\\markuplines", r"\\markuplist", str) + str = re.sub (r"@funindex markuplines", r"@funindex markuplist", str) + return str + # Guidelines to write rules (please keep this at the end of this file) # # - keep at most one rule per version; if several conversions should be done,