]> git.donarmstrong.com Git - lilypond.git/commit
Implements unpure-pure-containers in LilyPond.
authorMike Solomon <mike@apollinemike.com>
Thu, 1 Sep 2011 12:57:48 +0000 (14:57 +0200)
committerMike Solomon <mike@apollinemike.com>
Thu, 1 Sep 2011 12:57:48 +0000 (14:57 +0200)
commit69622b49b7a5a9c992e36ef11ba60c1fdd3c34b6
treec92eee65dd0843fda458d438348596a622fc379a
parentf5647e3f12454fed076a673bfc8f7972cfd9a4c3
Implements unpure-pure-containers in LilyPond.

These structures free functions from needing to be pre-registered as
pure in define-grobs.scm.  For example, if one has a function foo
that is the unpure callback for a given property and bar that is the
pure callback, the generalized syntax for these containers is:

\override Grob #'property = #(ly:make-unpure-pure-container foo bar)

All of the pure/unpure distinctions that require a back and forth
between .scm and .cc files can, in theory, be eliminated by
using these containers.  Furthermore, all of the functions whose
pure equivalents are hard-coded can now take different pure equivalents
(see input/regression/unpure-pure-container.ly).
input/regression/unpure-pure-container.ly [new file with mode: 0644]
lily/axis-group-interface.cc
lily/context-property.cc
lily/function-documentation.cc
lily/grob-property.cc
lily/include/unpure-pure-container.hh [new file with mode: 0644]
lily/system.cc
lily/unpure-pure-container.cc [new file with mode: 0644]
scm/define-grobs.scm