2009/8/1 Mark Polesky <markpole...@yahoo.com>: >> These are things I've not done before, but perhaps I'll give it a >> try!
Precisely, it's a good opportunity for you to learn :-) Feel free to send me a link to your committish if you want me to review your work. > Okay, looking at earlier rules for guidance, I'm surprised to see so > many different formats for this. Here are some examples that I see > that I thought might > be similar to the convert-rule in question: > > str = str.replace ("setHairpinDim", "dimHairpin") > str = re.sub (r"([\\:]+)center-align", r"\1center-column", str) > str = re.sub (r"hcenter(\s+)", r"center-align\1", str) > str = re.sub (r"([\\:])bigger", r"\1larger", str) > > Are some of these better than others? Should some of these be changed? > I can guess what they all mean, but I don't know python, so I'll ask > someone to recommend one of the following (preferably with a little > explanation for future reference). > > str = str.replace ("pad-markup", "pad-around") > str = re.sub (r"pad-markup(\s+)", r"pad-around\1", str) > str = re.sub (r"([\\:])pad-markup", r"\1pad-around", str) > str = re.sub (r"([\\:]+)pad-markup", r"\1pad-around", str) I'd use the last one. The first one is probably deprecated now. Neil, thoughts? Mark, don't forget to search through the source code for any file that use the \pad-markup command: http://git.savannah.gnu.org/gitweb/?p=lilypond.git&a=search&h=HEAD&st=grep&s=pad-markup And please add a NEWS item so we we can go "RTF-NEWS-page" if any user complaints about the command having been removed :-) Regards, Valentin _______________________________________________ lilypond-devel mailing list lilypond-devel@gnu.org http://lists.gnu.org/mailman/listinfo/lilypond-devel