Bug 428308

Summary: Limit ksysguard to a single instance
Product: [Unmaintained] ksysguard Reporter: Henrique Sant'Anna <hsantanna>
Component: ksysguardAssignee: KSysGuard Developers <ksysguard-bugs>
Status: RESOLVED UNMAINTAINED    
Severity: wishlist CC: nate, plasma-bugs-null
Priority: NOR    
Version First Reported In: 5.20.1   
Target Milestone: ---   
Platform: Other   
OS: Linux   
Latest Commit: Version Fixed/Implemented In:
Sentry Crash Report:

Description Henrique Sant'Anna 2020-10-26 22:43:40 UTC
SUMMARY

Can't limit ksysguard to a single instance.


STEPS TO REPRODUCE

1. Set a shortcut to open ksysguard, like Ctrl + Shift + Esc (like MS Windows's Task Manager).
2. Press the shortcut and open ksysguard.
3. Change focus to another window.
4. Press the shortcut again and you will get a new instance of ksysguard, instead of getting the first instance back.


OBSERVED RESULT

You will have multiple instances of ksysguard running at the same time.


EXPECTED RESULT

The shortcut could turn back to front the current running ksysguard instance, instead of starting a new instance.

Maybe having an command line option like dolphin haves (--new-window), can be nice. Or the inverse, --single-window.


SOFTWARE/OS VERSIONS

Linux/KDE Plasma: 

KDE Plasma Version: 5.20.1
KDE Frameworks Version: 5.75.0
Qt Version: 5.15.1


ADDITIONAL INFORMATION

- Mouse click over System Load Viewer applet will also open new instance of ksysguard.

- As dirty workaround this command line can do the trick to have a single instance (editing the window title 'System Monitor' to match your language):

bash -c "([ \"$(xdotool getwindowfocus getwindowname)\" == 'System Monitor' ] && pkill ksysguard) || (pgrep '^ksysguard$' && wmctrl -x -R ksysguard) || (ksysguard && pkill ksysguard)"
Comment 1 Christoph Cullmann 2024-09-23 21:01:24 UTC
ksysguard is no longer maintained, in Plasma 6 there is the Plasma system monitor for this task.

If your wish is still valid for the Plasma 6 replacement, please re-open and we can move this bug to the new product, thanks!