I see there is a "command history" tabpage . Unfortunately I don't find what feature this windows offers. You can't click anything or perform any action. Would it be possible, because this history is already made, to make an undo feature based on this? SOFTWARE/OS VERSIONS Windows 10 git
You could right click an item in "command history" to undo it (not sure if you can undo an item which is NOT the last one) Or File -> Undo removes last added command
Quite mysterious. Umbrello used to have an undo feature when I was last active (2014) but sometime between then and now is seems to have got lost. Ralf, could you shed some light on this?
(In reply to Oliver Kellogg from comment #2) > Quite mysterious. > Umbrello used to have an undo feature when I was last active (2014) but > sometime between then and now is seems to have got lost. The undo feature is present and functional for many drawing objects, but is not 100% complete.
(In reply to Ralf Habacker from comment #3) > (In reply to Oliver Kellogg from comment #2) > > Quite mysterious. > > Umbrello used to have an undo feature when I was last active (2014) but > > sometime between then and now is seems to have got lost. > > The undo feature is present and functional for many drawing objects, but is > not 100% complete. So then the bug is that the Undo button got lost.
(In reply to Oliver Kellogg from comment #4) > (In reply to Ralf Habacker from comment #3) > > (In reply to Oliver Kellogg from comment #2) > [...] > So then the bug is that the Undo button got lost. We are talking about the toolbar between the main menu bar (File, Edit, Diagram, Code, Settings, Help) and the work toolbar with the arrow and the UML symbols (Note, Anchor, Label(XYZ) etc). In the Qt4/KDE4 build of git master, the Undo/Redo icons are present in that toolbar: New, Open, Save, Print, Print Preview, Undo, Redo, Cut, Copy, Paste, Find. In the Qt5/KF5 build, the Undo/Redo icons are missing completely, i.e. there are not even fallback icons in those positions. How this has been working in KDE4 I do not know. The only mentions I find are: 1) In umbrello/umbrelloui.rc.cmake the line <ToolBar name="mainToolBar" fullWidth="true" newline="true"> 2) in umbrello/uml.cpp function UMLApp::saveOptions() : toolBar(QLatin1String("mainToolBar"))->saveSettings(cg); function UMLApp::readOptions() : toolBar(QLatin1String("mainToolBar"))->applySettings(m_config->group("toolbar")); How that toolbar is filled with icons is not visible from the source code. I must be missing something.
> In the Qt5/KF5 build, the Undo/Redo icons are missing completely, > 1) In umbrello/umbrelloui.rc.cmake the line This is probably caused by KF5 expecting that file on a different path as it is installed. You may try to run umbrello with 'strace -e trace=file' to see, where it is expected.
Created attachment 146906 [details] logfile from `strace -e trace=file umbrello` on a KF5 build (In reply to Ralf Habacker from comment #6) > > In the Qt5/KF5 build, the Undo/Redo icons are missing completely, > > > 1) In umbrello/umbrelloui.rc.cmake the line > > This is probably caused by KF5 expecting that file on a different path as it > is installed. You may try to run umbrello with 'strace -e trace=file' to > see, where it is expected. I tried that and to my amazement, on KF5 it isn't even trying to look up the icon file (see attachment). On the KDE4 build, I get lines like this: stat("/usr/share/icons/oxygen/16x16/actions/edit-undo.png", {st_mode=S_IFREG|0644, st_size=866, ...}) = 0 stat("/usr/share/icons/oxygen/22x22/actions/edit-undo.png", {st_mode=S_IFREG|0644, st_size=1220, ...}) = 0 stat("/usr/share/icons/oxygen/32x32/actions/edit-undo.png", {st_mode=S_IFREG|0644, st_size=2020, ...}) = 0 stat("/usr/share/icons/oxygen/48x48/actions/edit-undo.png", {st_mode=S_IFREG|0644, st_size=3440, ...}) = 0 stat("/usr/share/icons/oxygen/22x22/actions/edit-undo.png", {st_mode=S_IFREG|0644, st_size=1220, ...}) = 0 open("/usr/share/icons/oxygen/22x22/actions/edit-undo.png", O_RDONLY|O_CLOEXEC) = 13 In your KF5 build, do you get the Undo/Redo buttons?
(In reply to Oliver Kellogg from comment #7) > [...] > On the KDE4 build, I get lines like this: > > stat("/usr/share/icons/oxygen/16x16/actions/edit-undo.png", > {st_mode=S_IFREG|0644, st_size=866, ...}) = 0 I forgot to write: On my KF5 system, these are the actually installed icons, /usr/share/icons/Adwaita/32x32/legacy/edit-undo.png /usr/share/icons/Adwaita/22x22/legacy/edit-undo.png /usr/share/icons/Adwaita/48x48/legacy/edit-undo.png /usr/share/icons/Adwaita/16x16/legacy/edit-undo.png /usr/share/icons/Adwaita/24x24/legacy/edit-undo.png /usr/share/icons/oxygen/base/32x32/actions/edit-undo.png /usr/share/icons/oxygen/base/22x22/actions/edit-undo.png /usr/share/icons/oxygen/base/48x48/actions/edit-undo.png /usr/share/icons/oxygen/base/16x16/actions/edit-undo.png /usr/share/icons/breeze/actions/16/edit-undo.svg /usr/share/icons/breeze/actions/24/edit-undo.svg /usr/share/icons/breeze/actions/22/edit-undo.svg /usr/share/icons/breeze/actions/32/edit-undo.svg /usr/share/icons/breeze-dark/actions/16/edit-undo.svg /usr/share/icons/breeze-dark/actions/24/edit-undo.svg /usr/share/icons/breeze-dark/actions/22/edit-undo.svg /usr/share/icons/breeze-dark/actions/32/edit-undo.svg /usr/share/icons/HighContrast/16x16/actions/edit-undo.png /usr/share/icons/HighContrast/22x22/actions/edit-undo.png /usr/share/icons/HighContrast/24x24/actions/edit-undo.png /usr/share/icons/HighContrast/256x256/actions/edit-undo.png /usr/share/icons/HighContrast/32x32/actions/edit-undo.png /usr/share/icons/HighContrast/48x48/actions/edit-undo.png /usr/share/icons/HighContrast/scalable/actions/edit-undo.svg
(In reply to Oliver Kellogg from comment #7) > [...] > I tried that and to my amazement, on KF5 it isn't even trying to look up the > icon file (see attachment). After some debugging, I guess this may have to do with QIcon caching. Apparently, Qt somehow manages to fabricate an icon, e.g. for "edit-undo", without searching for icon files in that moment. For better understanding, I patched UMLApp::readOptions() as follows: diff --git a/umbrello/uml.cpp b/umbrello/uml.cpp index 7d094290b..6a81139d1 100644 --- a/umbrello/uml.cpp +++ b/umbrello/uml.cpp @@ -1131,7 +1132,12 @@ void UMLApp::saveOptions() void UMLApp::readOptions() { // bar status settings - toolBar(QLatin1String("mainToolBar"))->applySettings(m_config->group("toolbar")); + KToolBar *mainToolBar = toolBar(QLatin1String("mainToolBar")); + mainToolBar->applySettings(m_config->group("toolbar")); + QIcon qi = QIcon::fromTheme(QLatin1String("edit-undo")); + editUndo->setIcon(qi); + mainToolBar->addAction(editUndo); + // do config for work toolbar m_toolsbar->applySettings(m_config->group("workbar")); fileOpenRecent->loadEntries(m_config->group("Recent Files")); ... and with that patch, the Undo icon does appear! IMHO the Undo/Redo actions are no longer automatically filled into toolBar(QLatin1String("mainToolBar")) as they were in KDE4. BTW, if the editUndo->setIcon(qi) call is left out then instead of the Undo icon there appears the text "Undo".
*** Removed by KDE Sysadmin for violation of the KDE Community Code of Conduct ***
Git commit 23349c46cc5f9c3b0e8ef090e518ba50dcda826d by Oliver Kellogg. Committed on 19/02/2022 at 08:20. Pushed by okellogg into branch 'master'. Fix "request: restore undo/redo buttons missing in KF5 build" umbrello/uml.cpp - In constructor, for symmetry with other members pre-initialize member m_undoEnabled. - In function readOptions : - Factor toolBar(QLatin1String("mainToolBar")) into local mainToolBar pointer to KToolBar. - If QT_VERSION major is 5 or larger then - add seperator in mainToolBar; - set "edit-undo" / "edit-redo" in local QStrings undoIconName and redoIconName; - set local QIcons undoIcon and redoIcon using QIcon::fromTheme() with undoIconName and redoIconName; - set undoIcon in editUndo and set redoIcon in editRedo; - call mainToolBar->addAction() with argument editUndo and editRedo. FIXED-IN:2.33.80 (KDE releases 22.03.80) M +23 -2 umbrello/uml.cpp https://invent.kde.org/sdk/umbrello/commit/23349c46cc5f9c3b0e8ef090e518ba50dcda826d