Range-based annotation implementation

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
Report Content as Inappropriate

Range-based annotation implementation

Marc Sabatella
As part of the GSoC, Ruchit (shredpub) is implementing support for score annotations, with me as mentor.  For annotations that attach to a single element - like text or a shape - the implementation seems straightforward.  But one type of annotation probably deserves some discussion, and that is the range-based annotation - basically allowing you to highlight a passage across one or more staves.  It's essentially a spanner, but not one that requires the user to be able to edit the individual segments, so we are hoping to come up with a relatively low weight implementation.  It would basically be a rectangle much like the selection rectangle, but with possibility of defining background color etc.

I knew a reasonable amount about the implementation of spanners for 2.0, but nothing about the changes made or planned for 3.0.  I'm trying to understand whether it will make sense to implement these annotations as actual spanners, or whetehr we could potentially come up with an even more simplified implementation.  I guess the same issue probably exists for the LyricsLine, which currently are "unmanaged spanners" that do dervie from Spanner but don't have quite the same persistence as other spanners.  My understanding is this might go away for 3.0, but I'm not sure if there is a plan for what might replace it, and if there is, if it is something we could use for range annotations.

Any thoughts anyone would like to share about this?