Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(780)

Issue 6730044: Issue 2445: Add measure counter to LilyPond

Can't Edit
Can't Publish+Mail
Start Review
Created:
11 years, 6 months ago by david.nalesnik
Modified:
11 years, 6 months ago
Reviewers:
pkx166h, janek, dak
CC:
lilypond-devel_gnu.org
Base URL:
http://git.savannah.gnu.org/gitweb/?p=lilypond.git/trunk/
Visibility:
Public.

Description

Issue 2445: Add measure counter to LilyPond This patch allows the user to number groups of successive measures, which is useful as an aid to the performer in keeping track of repetitions. There is no requirement that the counted measures be repeated, however. The number is centered on the measure (discounting prefatory material), above the staff by default. In the case of a measure split across a line break, all segments are numbered. The first number has its normal appearance, while the following numbers are enclosed in parentheses. A new grob, a spanner called `MeasureCounter,' is defined. Each element of a count is an independent instance of this grob. A new event-class, `measure-counter-event,' and a new interface, `measure-counter-interface,' are also defined. The engraver, `Measure_counter_engraver,' must be added to the relevant context (probably Staff) in the .ly file. This engraver has been written in Scheme, following the precedent of `Span_stem_engraver.' The user frames the measures to count with the commands `\startMeasureCount' and `\stopMeasureCount.' The initial number is read from a new grob-property, 'count-from, which may be overridden.

Patch Set 1 #

Patch Set 2 : engraver moved to .scm file #

Patch Set 3 : fix for broken measures #

Total comments: 12

Patch Set 4 : fixes based on Janek's review #

Patch Set 5 : add engraver to Staff context #

Patch Set 6 : revert addition to Staff context #

Total comments: 3

Patch Set 7 : fixes based on David's review #

Total comments: 1
Unified diffs Side-by-side diffs Delta from patch set Stats (+276 lines, -3 lines) Patch
A input/regression/measure-counter.ly View 1 2 3 4 5 6 1 chunk +41 lines, -0 lines 0 comments Download
A input/regression/measure-counter-broken.ly View 1 2 3 4 5 6 1 chunk +30 lines, -0 lines 0 comments Download
M ly/engraver-init.ly View 1 2 3 4 5 6 1 chunk +1 line, -0 lines 1 comment Download
M ly/spanners-init.ly View 1 chunk +4 lines, -0 lines 0 comments Download
M scm/define-event-classes.scm View 1 2 3 1 chunk +5 lines, -3 lines 0 comments Download
M scm/define-grob-interfaces.scm View 1 chunk +5 lines, -0 lines 0 comments Download
M scm/define-grob-properties.scm View 1 2 3 1 chunk +3 lines, -0 lines 0 comments Download
M scm/define-grobs.scm View 1 2 3 4 5 6 1 chunk +18 lines, -0 lines 0 comments Download
M scm/define-music-types.scm View 1 chunk +5 lines, -0 lines 0 comments Download
M scm/lily.scm View 1 2 3 4 5 6 1 chunk +1 line, -0 lines 0 comments Download
M scm/music-functions.scm View 1 2 3 4 5 6 1 chunk +60 lines, -0 lines 0 comments Download
A scm/scheme-engravers.scm View 1 2 3 4 1 chunk +103 lines, -0 lines 0 comments Download

Messages

Total messages: 15
david.nalesnik
Please review. Thanks! -David
11 years, 6 months ago (2012-10-17 13:34:45 UTC) #1
janek
I found some ambiguities in descriptions. Janek http://codereview.appspot.com/6730044/diff/10001/input/regression/measure-counter-broken.ly File input/regression/measure-counter-broken.ly (right): http://codereview.appspot.com/6730044/diff/10001/input/regression/measure-counter-broken.ly#newcode6 input/regression/measure-counter-broken.ly:6: enclosed in ...
11 years, 6 months ago (2012-10-24 10:37:08 UTC) #2
david.nalesnik
Thanks for your review, Janek! https://codereview.appspot.com/6730044/diff/10001/input/regression/measure-counter-broken.ly File input/regression/measure-counter-broken.ly (right): https://codereview.appspot.com/6730044/diff/10001/input/regression/measure-counter-broken.ly#newcode6 input/regression/measure-counter-broken.ly:6: enclosed in parentheses." On ...
11 years, 6 months ago (2012-10-24 12:19:54 UTC) #3
janek
much clearer now, thanks! LGTM Janek
11 years, 6 months ago (2012-10-24 12:47:15 UTC) #4
pkx166h
I've opened http://code.google.com/p/lilypond/issues/detail?id=2924 for the Documentation in the NR
11 years, 6 months ago (2012-10-24 14:05:35 UTC) #5
pkx166h
Also, should we include Measure_counter_engraver in the Staff context by default? (it'd make documenting it ...
11 years, 6 months ago (2012-10-24 14:10:03 UTC) #6
janek
On Wed, Oct 24, 2012 at 4:10 PM, <pkx166h@gmail.com> wrote: > Also, should we include ...
11 years, 6 months ago (2012-10-24 20:28:36 UTC) #7
david.nalesnik
On 2012/10/24 20:28:36, janek wrote: > On Wed, Oct 24, 2012 at 4:10 PM, <mailto:pkx166h@gmail.com> ...
11 years, 6 months ago (2012-10-25 11:51:04 UTC) #8
dak
Please make the indicated convert-ly-like changes. Thanks! http://codereview.appspot.com/6730044/diff/32001/input/regression/measure-counter.ly File input/regression/measure-counter.ly (right): http://codereview.appspot.com/6730044/diff/32001/input/regression/measure-counter.ly#newcode20 input/regression/measure-counter.ly:20: \override Staff.MeasureCounter ...
11 years, 6 months ago (2012-10-31 05:32:15 UTC) #9
dak
http://codereview.appspot.com/6730044/diff/32001/input/regression/measure-counter.ly File input/regression/measure-counter.ly (right): http://codereview.appspot.com/6730044/diff/32001/input/regression/measure-counter.ly#newcode1 input/regression/measure-counter.ly:1: \version "2.17.5" Oops: also change version header, or just ...
11 years, 6 months ago (2012-10-31 05:35:53 UTC) #10
david.nalesnik
David, I don't mind making the changes, but I'm running into some problems. I used ...
11 years, 6 months ago (2012-10-31 11:41:19 UTC) #11
dak
On 2012/10/31 11:41:19, david.nalesnik wrote: > David, > > I don't mind making the changes, ...
11 years, 6 months ago (2012-10-31 11:47:37 UTC) #12
david.nalesnik
Thank you--I am a bit worried! Speaking of "patch," when I run git format-patch I ...
11 years, 6 months ago (2012-10-31 11:55:12 UTC) #13
dak
http://codereview.appspot.com/6730044/diff/40002/ly/engraver-init.ly File ly/engraver-init.ly (right): http://codereview.appspot.com/6730044/diff/40002/ly/engraver-init.ly#newcode88 ly/engraver-init.ly:88: \consists "Footnote_engraver" Any idea where this line is from? ...
11 years, 6 months ago (2012-10-31 11:58:42 UTC) #14
dak
11 years, 6 months ago (2012-10-31 12:01:15 UTC) #15
On 2012/10/31 11:55:12, david.nalesnik wrote:
> Thank you--I am a bit worried!
> 
> Speaking of "patch," when I run git format-patch I get six separate patches. 
Is
> there any way to compress them into one so this is more convenient for you?
> 
> -David

Try if you can git send-email to work for you.  That still results in 6
different messages, but applying them with git am is easy.
Sign in to reply to this message.

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld f62528b