From: Chris Cannam <cannam@al...> - 2009-06-18 14:19:27
Although quite a few of the notation editor functions now work, there
are quite a few still in need of reconnection. Many of them are very
easy to reconnect -- could be a good task for anyone with a moment to
spare (I think Michael may have been hinting to me in an email earlier
that he might do a few of these?)
I've just committed (rev 10401) a single example, the Interpret...
function. Here are some notes about it:
The basic principle is to look for actions created in
NewNotationView::setupActions() that are connected to slots that do
not exist in that file. In this case the action is set up as:
but slotTransformsInterpret() did not appear anywhere else in the file.
(If you know what command will be used to implement this function,
perhaps also check that it doesn't appear in
NotationCommandRegistry.cpp -- if it appears there, then it may be the
case that the action should not have been constructed at all in
NotationView, rather than that it needs to be connected. I expect
there will be few or no instances of that though.)
Then, once you've found an action that needs connecting, look in
OldNotationView.cpp for the slot function that implements it in the
old code. If it's very long and complicated, perhaps bring it to the
attention of the list rather than trying to attack it straight away.
Or try it and ask if you get stuck -- some of the long & complicated
functions are probably quite simple to convert in fact.
Anyway, once you've found it, just plonk that slot code into the new
notation view, change the class name from NotationView to
NewNotationView, and switch over anything that now works
differently... not that there is any thorough documentation of that,
but for example:
* replace m_currentEventSelection with getSelection() -- the notation
view no longer contains its own selection object
* replace addCommandToHistory() with
* replace the form "staff = getCurrentStaff(); segment =
staff->getSegment()" with "segment = getCurrentSegment()"
and, um, probably some others.
Check out that diff for rev 10401 for a simple example.
Get latest updates about Open Source Projects, Conferences and News.