The default shortcut for "Save as..." hasn't changed since 412ca454 , back on Mai 26th 2012, the initial commit to GitHub, and probably even longer, when it was on SourceForge.
See shortcuts.xml, line 19-22
Still, I can confirm that after a factory reset, my build of 2.2 shows the same issue. So something went wrong elsewhere (the above link is for master, but I can confirm shortcuts.xml for 2.2 doesn't show any obviously relevant changes either). Might be a Qt difference, as the shortcuts for "standard" commands like this are handled differently by Qt compared to our own shortcuts.
OK, then I guess it may have been a change elsewhere. Can anyone else confirm? Because of how this is handled, it might well be OS-dependent. I see the problem on Windows 10. I also get a warning, though, on startup (to the terminal, so only visible when starting from the command line), saying "Qt: Untested Windows version 10.0 detected", maybe that somehow gets in the way of it setting up the proper shortcuts. It appears we rely on Qt to tell us the standard OS shortcut based for Save As (as well as many other shortcuts) and somehow this isn't registering. If Qt can't tell us the standard OS shortcut for the command, we are stuck, and it appears that this is what is happening for some reason.
Distribution package of v2.1 is using QT 5.6.1 and the shortcut appears and works by default.
In the AppImage of as both v2.1 an v2.2 (both are using QT 5.4.2) the shortcut isn't available by default.
AppImage master (QT 5.9.3) the shortcut is available by default.
Just downloaded OS: openSUSE Leap 42.1 (x86_64), Arch.: x86_64, MuseScore version (64-bit): 2.2.0, revision: 9799b90, shortcut ctrl+shift+s is still missing by default (and Linux).
OK, I will try to investigate further. Does anyone know anything about the "Qt: Untested Windows version 10.0 detected" message? I mean, I can see from searching online that it is normal for a newer version of Windows to trigger this with an older version of Qt. My question is, could this be the cause of the problem - that Qt doesn't know the default shortcut to use? But then, it shouldn't have known in earlier versions either, and it worked before. So I do suspect it will turn out to be something about the fix for #235406: Regression: essential keyboard shortcuts missing.
And it doesn't work on Windows 7 either, this is known to Qt, only Windows 10 is not
Hmm, before that change _standardKey just got set. The change basically adds _action->setShortcuts(_standardKey); and if I get it right the 2nd part just takes care of displaying these standard shortcuts in the preferences dialog
You are correct, and tracing thre code, _action->setShortcuts(_standardKey) is getting called anyhow, in Shortcut::action(), later on during initialization. That is definitely happening here, I see it being called for save as:
But for some reason the call is failing, and I can't say why, because it returns void so there is no error code to check. All I know is, when we try retrieving the list of shrotcuts after calling setShortcuts(), it is coming up empty here:
This appears to be the only shortcut call that is failing.
Possibly related but probably not - all of the other standard shortcuts have flags of NONE, but this one is A_SCORE. It is also set to Qt::WindowShortcut but ordinary Save is not. Still, none of this is new, and changing it doesn't help.
Doh! I just realized it doesn't work for me in 2.1 either. I had defined a shortcut myself long ago I guess and forgot, but after a factory reset, I see it is gone.
So, I'm going with my hypothesis that Qt 5.4 just doesn't think there is an OS-defined default shortcut for save as on Window 10. And I think it may be right about that - I don't see any reference to one.
I suppose we could add a fall-back to the shortcut definition file, and alter our implementation to use the fallback if the initial attempt at installing the standard key fails.
It's an option, sure. I suppose the concern is that some OS we support might either have a different default their users would be accustomed to, or they might provide a way for users to customize that shortcut across applications and it would be good if we didn't ignore that. But in practice, I don't know if this actually happens - for all I know, it really is just Ctrl+Shift+S on all supported systems.
Comments
It is possible to define this shortcut in preferences.
In reply to It is possible to define… by mike320
Indeed, but it's defined in v2.1 and the master too by default.
Yes, of course. But there should be a default
Closed in error
The default shortcut for "Save as..." hasn't changed since 412ca454 , back on Mai 26th 2012, the initial commit to GitHub, and probably even longer, when it was on SourceForge.
See shortcuts.xml, line 19-22
Still, I can confirm that after a factory reset, my build of 2.2 shows the same issue. So something went wrong elsewhere (the above link is for master, but I can confirm shortcuts.xml for 2.2 doesn't show any obviously relevant changes either). Might be a Qt difference, as the shortcuts for "standard" commands like this are handled differently by Qt compared to our own shortcuts.
Still all MuseScore 2.x use the the same Qt, 5.4
OK, then I guess it may have been a change elsewhere. Can anyone else confirm? Because of how this is handled, it might well be OS-dependent. I see the problem on Windows 10. I also get a warning, though, on startup (to the terminal, so only visible when starting from the command line), saying "Qt: Untested Windows version 10.0 detected", maybe that somehow gets in the way of it setting up the proper shortcuts. It appears we rely on Qt to tell us the standard OS shortcut based for Save As (as well as many other shortcuts) and somehow this isn't registering. If Qt can't tell us the standard OS shortcut for the command, we are stuck, and it appears that this is what is happening for some reason.
OpenSuse Leap 42.1
Distribution package of v2.1 is using QT 5.6.1 and the shortcut appears and works by default.
In the AppImage of as both v2.1 an v2.2 (both are using QT 5.4.2) the shortcut isn't available by default.
AppImage master (QT 5.9.3) the shortcut is available by default.
See https://github.com/musescore/MuseScore/commit/99a9c65807743fa5ad032fa3b…, to fix #235406: Regression: essential keyboard shortcuts missing. My guess is this is what triggered this.
I can't reproduce on Mac with 2.2 9799b9030936b30b89b688f2f8c02e15f13451a4
Is it windows / linux only ?
In reply to I can't reproduce on Mac… by [DELETED] 5
Just downloaded OS: openSUSE Leap 42.1 (x86_64), Arch.: x86_64, MuseScore version (64-bit): 2.2.0, revision: 9799b90, shortcut ctrl+shift+s is still missing by default (and Linux).
Does not work in the latest 2.2 development build, after a factory reset, on Windows 7
OK, I will try to investigate further. Does anyone know anything about the "Qt: Untested Windows version 10.0 detected" message? I mean, I can see from searching online that it is normal for a newer version of Windows to trigger this with an older version of Qt. My question is, could this be the cause of the problem - that Qt doesn't know the default shortcut to use? But then, it shouldn't have known in earlier versions either, and it worked before. So I do suspect it will turn out to be something about the fix for #235406: Regression: essential keyboard shortcuts missing.
And it doesn't work on Windows 7 either, this is known to Qt, only Windows 10 is not
Hmm, before that change
_standardKey
just got set. The change basically adds_action->setShortcuts(_standardKey);
and if I get it right the 2nd part just takes care of displaying these standard shortcuts in the preferences dialogYou are correct, and tracing thre code, _action->setShortcuts(_standardKey) is getting called anyhow, in Shortcut::action(), later on during initialization. That is definitely happening here, I see it being called for save as:
https://github.com/musescore/MuseScore/blob/2.2/mscore/shortcut.cpp#L36…
But for some reason the call is failing, and I can't say why, because it returns void so there is no error code to check. All I know is, when we try retrieving the list of shrotcuts after calling setShortcuts(), it is coming up empty here:
https://github.com/musescore/MuseScore/blob/2.2/mscore/shortcut.cpp#L36…
This appears to be the only shortcut call that is failing.
Possibly related but probably not - all of the other standard shortcuts have flags of NONE, but this one is A_SCORE. It is also set to Qt::WindowShortcut but ordinary Save is not. Still, none of this is new, and changing it doesn't help.
Doh! I just realized it doesn't work for me in 2.1 either. I had defined a shortcut myself long ago I guess and forgot, but after a factory reset, I see it is gone.
So, I'm going with my hypothesis that Qt 5.4 just doesn't think there is an OS-defined default shortcut for save as on Window 10. And I think it may be right about that - I don't see any reference to one.
I suppose we could add a fall-back to the shortcut definition file, and alter our implementation to use the fallback if the initial attempt at installing the standard key fails.
In reply to Doh! It doesn't work for me… by Marc Sabatella
Is it an option to just hardcode CTRL(CMD)-SHIFT-S as a Save as... shortcut and do not rely on default system shortcuts?
It's an option, sure. I suppose the concern is that some OS we support might either have a different default their users would be accustomed to, or they might provide a way for users to customize that shortcut across applications and it would be good if we didn't ignore that. But in practice, I don't know if this actually happens - for all I know, it really is just Ctrl+Shift+S on all supported systems.
came up again in #277218: Bind Ctrl+Shift+S to 'Save As...'
Hmm, I didn't set S1?
Seems to be a Qt bug. https://bugreports.qt.io/browse/QTBUG-72916
But seems to be available again within the released version, at least for Linux (Qt 5.9.3 resp. 5.9.4).
Not for me or Marc.
The AppImage is using 5.9.3 the distribution package 5.9.4:
In reply to The AppImage is using 5.9.3… by kuwitt
What distribution / environment are you on?
OpenSuse Leap 15.0 with XFCE.
See also #288679: Can't add shortcut for save as
and https://github.com/musescore/MuseScore/pull/4991
Fixed in branch master, commit guthub-musescore-musescore-e065bf9a27
Automatically closed -- issue fixed for 2 weeks with no activity.