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

Issue 126280043: Issue 2507: Stop the entanglement of context properties and grob property internals (Closed)

Can't Edit
Can't Publish+Mail
Start Review
Created:
9 years, 8 months ago by dak
Modified:
9 years, 6 months ago
Reviewers:
Keith, lemzwerg
CC:
lilypond-devel_gnu.org, Graham Percival
Visibility:
Public.

Description

Issue 2507: Stop the entanglement of context properties and grob property internals This introduces a semi-opaque structure Grob_properties meeting the predicate ly:grob-properties? that is algorithmically handled at the C++ level via a wrapper structure Grob_property_info. Encapsulating grob properties in that manner reduces the potential for clashes and makes it easier to change algorithms and/or internal representation. While the principal distinction between context properties (one value per context) and context-based grob property templates (one stack per context) remains, at least the separation of the handling is more pronounced.

Patch Set 1 #

Patch Set 2 : Fix the internals-meddling scheme-text-spanner regtest #

Patch Set 3 : Fix incredibly reckless context/grob property mixup in event-listener #

Total comments: 1

Patch Set 4 : When Grob_property_info::pop removes a Grob_properties, drop the reference #

Unified diffs Side-by-side diffs Delta from patch set Stats (+262 lines, -154 lines) Patch
M input/regression/scheme-text-spanner.ly View 1 2 chunks +2 lines, -2 lines 0 comments Download
M lily/auto-beam-engraver.cc View 2 chunks +2 lines, -1 line 0 comments Download
M lily/context-property.cc View 1 2 3 9 chunks +178 lines, -128 lines 0 comments Download
M lily/context-scheme.cc View 2 chunks +2 lines, -1 line 0 comments Download
M lily/engraver.cc View 2 chunks +2 lines, -1 line 0 comments Download
M lily/engraver-group.cc View 3 chunks +6 lines, -8 lines 0 comments Download
M lily/include/context.hh View 1 chunk +1 line, -6 lines 0 comments Download
A lily/include/grob-properties.hh View 1 chunk +59 lines, -0 lines 0 comments Download
M lily/include/lily-proto.hh View 1 chunk +1 line, -0 lines 0 comments Download
M lily/score-engraver.cc View 2 chunks +2 lines, -1 line 0 comments Download
M lily/span-bar-stub-engraver.cc View 2 chunks +2 lines, -1 line 0 comments Download
M ly/event-listener.ly View 1 2 1 chunk +2 lines, -2 lines 0 comments Download
M ly/music-functions-init.ly View 1 chunk +2 lines, -2 lines 0 comments Download
M scm/define-grobs.scm View 1 chunk +1 line, -1 line 0 comments Download

Messages

Total messages: 9
dak
Fix the internals-meddling scheme-text-spanner regtest
9 years, 8 months ago (2014-08-14 20:29:24 UTC) #1
dak
Fix incredibly reckless context/grob property mixup in event-listener
9 years, 8 months ago (2014-08-14 23:41:45 UTC) #2
lemzwerg
> Fix incredibly reckless context/grob property mixup in event-listener I would rather call this clueless ...
9 years, 8 months ago (2014-08-15 06:11:31 UTC) #3
dak
On 2014/08/15 06:11:31, lemzwerg wrote: > > Fix incredibly reckless context/grob property mixup in event-listener ...
9 years, 8 months ago (2014-08-15 07:44:08 UTC) #4
dak
At any rate, putting Graham in the Cc since event-listener.ly or equivalent code is purportedly ...
9 years, 8 months ago (2014-08-15 07:58:26 UTC) #5
dak
When Grob_property_info::pop removes a Grob_properties, drop the reference
9 years, 8 months ago (2014-08-15 09:42:15 UTC) #6
Graham Percival
On Fri, Aug 15, 2014 at 07:58:26AM +0000, dak@gnu.org wrote: > At any rate, putting ...
9 years, 8 months ago (2014-08-15 15:07:07 UTC) #7
Keith
Big change, looks good, just one question. https://codereview.appspot.com/126280043/diff/40001/lily/context-property.cc File lily/context-property.cc (right): https://codereview.appspot.com/126280043/diff/40001/lily/context-property.cc#newcode152 lily/context-property.cc:152: Don't mess ...
9 years, 8 months ago (2014-08-18 05:51:22 UTC) #8
dak
9 years, 8 months ago (2014-08-18 08:30:22 UTC) #9
On 2014/08/18 05:51:22, Keith wrote:
> Big change, looks good, just one question.
> 
> https://codereview.appspot.com/126280043/diff/40001/lily/context-property.cc
> File lily/context-property.cc (right):
> 
>
https://codereview.appspot.com/126280043/diff/40001/lily/context-property.cc#...
> lily/context-property.cc:152: Don't mess with MIDI.
> I am confused by this comment.  MIDI output does not create any grobs, so I
> figured the code would return false after finding no definition of symbol_,
same
> as if I type \override Bogus.color =#red
> What is the special case for MIDI ?

The special case for MIDI is that the \override is actually accepted in the
input (rather than an error getting flagged).  Consequently the code is able to
arrive here in the normal course of events.  I don't think that \override
Bogus.color = #red even makes it into the music.  You probably have to revert to
Scheme-created music in order to smuggle it in.

This comment is actually taken unchanged from the original code.
Sign in to reply to this message.

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