Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix #209331: Updated Descriptions of Enharmonic shortcuts to reflect current implementation #3190

Merged
merged 2 commits into from
Jun 4, 2017
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions mscore/data/shortcuts.xml
Original file line number Diff line number Diff line change
Expand Up @@ -687,11 +687,11 @@
<seq>R</seq>
</SC>
<SC>
<key>enh-up</key>
<key>enh-both</key>
<seq>J</seq>
</SC>
<SC>
<key>enh-down</key>
<key>enh-current</key>
<seq>Ctrl+J</seq>
</SC>
<SC>
Expand Down
10 changes: 5 additions & 5 deletions mscore/scoreview.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2009,9 +2009,9 @@ void ScoreView::cmd(const QAction* a)
changeVoice(2);
else if (cmd == "voice-4")
changeVoice(3);
else if (cmd == "enh-up")
else if (cmd == "enh-both")
cmdChangeEnharmonic(true);
else if (cmd == "enh-down")
else if (cmd == "enh-current")
cmdChangeEnharmonic(false);
else if (cmd == "revision") {
Score* s = _score->masterScore();
Expand Down Expand Up @@ -3271,7 +3271,7 @@ void ScoreView::cmdAddHairpin(HairpinType type)
// cmdChangeEnharmonic
//---------------------------------------------------------

void ScoreView::cmdChangeEnharmonic(bool up)
void ScoreView::cmdChangeEnharmonic(bool both)
{
_score->startCmd();
Selection selection = _score->selection();
Expand All @@ -3281,7 +3281,7 @@ void ScoreView::cmdChangeEnharmonic(bool up)
if (staff->part()->instrument()->useDrumset())
continue;
if (staff->isTabStaff(n->tick())) {
int string = n->line() + (up ? 1 : -1);
int string = n->line() + (both ? 1 : -1);
int fret = staff->part()->instrument()->stringData()->fret(n->pitch(), string, staff, n->chord()->tick());
if (fret != -1) {
score()->undoChangeProperty(n, P_ID::FRET, fret);
Expand Down Expand Up @@ -3324,7 +3324,7 @@ void ScoreView::cmdChangeEnharmonic(bool up)
}
else {
n->undoSetTpc(tpc);
if (up || staff->part()->instrument(n->chord()->tick())->transpose().isZero()) {
if (both || staff->part()->instrument(n->chord()->tick())->transpose().isZero()) {
// change both spellings
int t = n->transposeTpc(tpc);
if (n->concertPitch())
Expand Down
14 changes: 8 additions & 6 deletions mscore/shortcut.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2548,16 +2548,18 @@ Shortcut Shortcut::_sc[] = {
{
MsWidget::MAIN_WINDOW,
STATE_NORMAL | STATE_NOTE_ENTRY_STAFF_PITCHED | STATE_NOTE_ENTRY_STAFF_DRUM,
"enh-up",
QT_TRANSLATE_NOOP("action","Enharmonic Up"),
QT_TRANSLATE_NOOP("action","Enharmonic up")
"enh-both",
QT_TRANSLATE_NOOP("action","Change Enharmonic Spelling (Both Modes)"),
QT_TRANSLATE_NOOP("action","Change enharmonic spelling (both modes)"),
QT_TRANSLATE_NOOP("action","Change enharmonic note (alters the spelling in concert pitch and transposed mode)")
},
{
MsWidget::MAIN_WINDOW,
STATE_NORMAL | STATE_NOTE_ENTRY_STAFF_PITCHED | STATE_NOTE_ENTRY_STAFF_DRUM,
"enh-down",
QT_TRANSLATE_NOOP("action","Enharmonic Down"),
QT_TRANSLATE_NOOP("action","Enharmonic down")
"enh-current",
QT_TRANSLATE_NOOP("action","Change Enharmonic Spelling (Current Mode)"),
QT_TRANSLATE_NOOP("action","Change enharmonic spelling (current mode)"),
QT_TRANSLATE_NOOP("action","Change enharmonic note (alters the spelling in the current mode only)")
},
{
MsWidget::MAIN_WINDOW,
Expand Down