lilypond-user
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: consolidate code


From: MING TSANG
Subject: Re: consolidate code
Date: Tue, 11 Feb 2014 14:28:20 -0800 (PST)

Hi all, 
I further reduce the code to 53 lines.  line 4 - 20 & line 24 - 40  are identical except line 14 vs line  34.   The actual code for notes is only 8 lines ( 45 - 52).  I think I cannot reduce anymore in order to show my problem and request.
Again  to ask:
problem 1: I am expecting all numbers (jianpu) on top of the letters (solfege) - on bar 1 and bar 3 they are reversed; is it possible to solve?
request 2: Is it possible to combine lins 4-20 & lines 24-40 into one define variable so that line 14 and line 34 can be access by parameter or by if statement?
Emmanuel,
Ming.


On Tuesday, February 11, 2014 5:00:02 PM, David Nalesnik <address@hidden> wrote:
Hi,


On Tue, Feb 11, 2014 at 3:35 PM, Phil Holmes <address@hidden> wrote:
OK - so this "tiny" example is 107 lines of code.  
 
 
----- Original Message -----
From: MING TSANG
Sent: Tuesday, February 11, 2014 9:07 PM
Subject: Re: consolidate code

From:Eluze
Subject:Re: consolidate code
Date:Tue, 11 Feb 2014 11:57:54 -0800 (PST)

MING TSANG wrote
> I hope the attached .ly file qualifies as tiny snippet.

>>certainly not - please reduce it to one or two notes to show the >>unexpected
>>behavior, and define clearly what you'd expect!
In this case, I think that there might be a misunderstanding.  Cutting the example down further wouldn't convey one of the problems the OP is having, I think.  Namely, that the .ly file contains a function which he has had to repeat several times for the sake of tiny modifications.  He's wondering if it can be expressed more simply as a function that takes arguments to cut down on the repetition.

Unfortunately, I'm not at a machine where I can help at the moment.

Best,
David 

P.S. @Ming: I found the source of your code very rapidly with a simple search: http://www.mail-archive.com/address@hidden/msg73062.html



Attachment: test_num-solfege(2).ly
Description: Text Data

Attachment: test_num-solfege(2).pdf
Description: Adobe PDF document


reply via email to

[Prev in Thread] Current Thread [Next in Thread]