After some considerable pain, I finally solved this one.  I was getting all 
screwed up in my head trying to think about the math for this.  As Magnus 
pointed out, I was thinking in fifths, not semitones.  I got into a brain 
damage spiral because for trumpet parts in -2, the two "scales" happen to 
overlap the same way degrees C and degrees F overlap at -40.  I'll spare the 
horror story about what an incredibly arduous ordeal it was for me to finally 
work all of this out, but it sucked, Beavis.

Anyway, here is where we stand now.  The testbed for this has a C major scale 
written out for various transposing instruments, with appropriate transpose 
set as a segment property (-2 +2 -6 +5 -33 and random others) and 
appropriately written notation in every staff, so they all look different, 
but sound identical.

The key we want to move to here is C major, so you put a key change in any of 
these segments, call it C major, and check [x] Apply to all segments at this 
time.  Click OK, and presto, all the accidentals in every segment go away.
You wind up with appropriate key signatures in all the other parts, regardles 
of which one, in whatever transposition, you put the C major change into.

The only thing that worries me about this is that if I am putting a key change 
into a -2 part that looks like it wants to be D major (because it does, 
ultimately) then I might want to put a D major in here, an expect it to fall 
into place in the other segments.

I tried to get that behavior to work, and I just couldn't quite puzzle it out.  
I already spent a miserable couple of days off getting to here, and I 
discovered to my delight that if I backed all of that junk out and did away 
with it, that I could put "C major," the real concert pitch key, into any of 
these parts, and get the same result as if I had put "C major" into the 
actual C major part at 0 transposition.

I'm debating whether to put in some kind of warningContinueCancel dialog with 
a [x] don't show this option, and warn people about this.

        if the user is inserting multiple keys at this time
        if the active segment is not at transpose 0
                warn them to be sure the key they are inserting is concert pitch

What do you users think?

I suppose most people are probably going to be thinking in terms of the 
concert pitch parts anyway, and they will be thinking "I'm doing a key change 
to A minor" here, even though the key written for Bb and Eb instruments will 
differ from this.

Would someone be sitting on a trumpet part and try to insert an "A minor" key 
change with the expectation that it would wind up as A minor "right here" in 
the target segment, and everything else would adjust from there?

I could also just refuse to do the insert if the transpose of the active 
segment is not 0, and say "Please select a non-transposing segment before 
performing this operation," but that feels like the annoyance of having to 
stop and go start over somewhere else would be worse than any confusion this 
current behavior causes until people get accustomed to how it works.

Also, I suppose there is a question whether this transposing behavior should 
be the default and only behavior, as it is currently, or whether there should 
be an additional "[x] Take segment transpose into account" checkbox.  I think 
we should have always been doing this the way it works now, and our behavior 
was broken before.  Would anybody ever want to put in a "C major" that came 
out as a literal C major for any transposed parts?  I don't think that is 
likely at all.  For my own part, I never used the "insert into all segments 
at this time" before, because it would have done stupid things for my 
transposing parts.  So I did the key inserts one by one, which sucked.  I 
think this is better, and a bug fix, not a new feature.

Opinions?

Another long week at work (at the current/old job), so I will be out of things 
until Wednesday this time, it looks like.  I detest August.

Anyway, people, do play with this.  Also check for bugs with going to wrong 
keys.  I have it all laid out, and it should work, but I might have made a 
typo somewhere.  I was up until dawn working on this last night/this morning.  
This turned out to be the worst 15 minute hack of my life.  15 hours plus.  
Ugh.

-- 
D. Michael 'Silvan' McIntyre  ----   Silvan <[EMAIL PROTECTED]>
Linux fanatic, and certified Geek;  registered Linux user #243621

Author of Rosegarden Companion http://rosegarden.sourceforge.net/tutorial/

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys -- and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Rosegarden-devel mailing list
Rosegarden-devel@lists.sourceforge.net - use the link below to unsubscribe
https://lists.sourceforge.net/lists/listinfo/rosegarden-devel

Reply via email to