
Run Command
Source (link to git-repo or to original if based on someone elses unmodified work): Add the source-code for this project on opencode.net
Simple plasmoid to run commands with support for runners.
Developed and tested on KDE 4.8 with Qt 4.7 (Kubuntu 11.10).
Features:
- optional use of runners;
- possibility to open web addresses (including searching, example: gg:query), invoke mailer, open directories and files (including use of KIO);
- possibility to run command in terminal (by prepending it by dollar sign - $);
- simple calculator (example: =2+2);
- simple numbers converter (to binary, octal and hexadecimal systems; examples: bin=12, oct=10, hex=8);
- commands to manage session (logout, lock, switch, shutdown, reboot);
- auto run of command after selecting;
- commands history shared with KRunner;
- activation shortcut.
If you have found bugs or have suggestions you can contact me via email, message or using comments, before you will vote bad. And remember that not everybody has enough time for fast replying. ;-)
9 years ago
2.5 (04.02.2012):
- fix resizing in KDE 4.8;
- some other fixes and small changes.
2.4 (04.01.2012):
- implement configChanged() method (useful for scripting);
- do not advertise resizing if panel toolbox is open.
9 years ago
2.5 (04.02.2012):
- fix resizing in KDE 4.8;
- some other fixes and small changes.
2.4 (04.01.2012):
- implement configChanged() method (useful for scripting);
- do not advertise resizing if panel toolbox is open.
datamaskinen
2 years ago
Report
Emdek
2 years ago
Right now there are no plans to port it, if someone would like to help with that then feel free to contact me.
Personally I find KRunner acceptable, but not perfect.
Report
msx
7 years ago
Still, Run Commander seems to dislike thinner panels, please have a look:
https://copy.com/nZIMRoZxJn3v
I would be most grateful if you could tweak it to fit well on a -24px panel.
Cheers.
Report
Emdek
7 years ago
The only way to fix this (and other visual glitches) would be to reimplement whole combo box widget, but I'm not sure if this is possible (it requires access to Plasma style classes etc., I'm not sure if all needed API is public).
It may make more sense to produce version that simply doesn't use Plasma styled widget, fancy background isn't worth numerous painting bugs (incorrect colors, clipped text etc.). Or try to do custom combo box like widget directly in QML (since it will be required anyway for KDE5/Plasma2).
Report
pprkut
8 years ago
I was trying the widget on 4.10 and while it generally works fine, I noticed a few things that tarnish the experience a bit:
- The input field where you type the command has a padding inside, which when the height is small causes the characters to only show partially. That could be a limitation on the input field itself, but maybe there is a way to remove the padding?
- I can't scroll though the history. Dragging the scrollbar does nothing and scrolling with the mouse wheel only scrolls the selected item (all others stay where they are)
- The widget showing the results has a static size, and elements are vertically centered. Maybe this could be done similar to how the notification widget or the device notifier work? (ie, have it expand from the panel rather than just appear and have it dynamically resize according to the number of results)
- It would be nice if you could navigate with the arrow keys through the results. Currently it just scrolls the list without changing the selection
Would be great if you could have a look at these things :)
Report
dotNet
8 years ago
Report
Emdek
8 years ago
Also, could you please post here link to some screenshot showing this issue?
Report
dotNet
8 years ago
It's 2.5-0, on kubuntu 12.10
and like i said, I can't increase the size vertically, I can just drag to extend it horizontally.
thanks for any tips
Report
Emdek
8 years ago
I think that I should stop using them and go for standard line edit and add custom history popup, the main drawback is that there would be need to some kind of button to trigger it.
Report
msx
8 years ago
First, I want to make you aware about this issue that occurs some times with Run Command, please take a look at them here:
http://i.imgur.com/njgWu.png
http://i.imgur.com/FYpk5.png
As you see this probably happens because I have a very thin panel (something in the ~24px order).
I would like to know if this is directly related to Run Command or more of a limitation of the Plasma Panel itself so if it is I can place a bug report to it's devs.
Second: is there any way to implement the use of Esc key to return focus to the previous application I was working in before I called Run Command?
As I use Run Command as a substitute of KRunner I usually call it via a hotkey (Super+z), the problem is that once I accomplish the task I was looking for - like translating a word using http://kde-apps.org/content/show.php/krunner-googletranslate?content=144348 - there's no way to go back to the document/email/code I was editing with the keyboard, I just have to go there with the mouse - somewhat akward if you ask.
So if this is possible I would love if you implement a way to 'give-back' the focus to the last application used before calling RC :)
Report
Emdek
8 years ago
https://bugs.kde.org/show_bug.cgi?id=292879
2. That would be surely useful, but I'm not sure if possible.
Maybe this would work, but not necessarily, due to hack needed to give it focus in first place (applies to all applets placed on panels):
http://doc.qt.digia.com/qt/qwidget.html#clearFocus
Another possible solution could be to remember previously active window and set it as active using KWindowSystem API.
Report
msx
8 years ago
nice you post the link to the bug report, I will add my own entry there.
I will check aswell the other link and find out a workaround.
Best.
Report
msx
8 years ago
I completely replaced KRunner with Run Command, congratz!
Report
Emdek
8 years ago
Report
msx
8 years ago
This is the correct link:
https://plus.google.com/u/0/111794870164633905684/posts/HwuutCf6oNM
Report
msx
8 years ago
Report
kbios
9 years ago
- Cut text (as reported above) -> fixed by adding
m_comboBox->setFixedHeight(30);
in
RunCommandApplet::init()
- I cannot resize it whatever I try (panel settings opened or closed, objects locked or unlocked). The resize cursor appears, but nothing happens. Since by default it takes all the space on the panel, I have put
setPreferredWidth(200);
and it seems to work.
I am under KDE 4.8.0 amd64
Thanks again for this great applet
Report
Emdek
9 years ago
Report
kbios
9 years ago
Report
Emdek
9 years ago
2. Sadly I must confirm this, something got changed in 4.8. :-/
I'll try to find solution for this issue or ask devs what can cause this (maybe this is Plasma bug).
Report
google01103
9 years ago
1) when it runs the text typed does not show in the text box, but does in the popup display
2) the text box at sometimes displays gradients of blue in blocks
3) it freezes and with it freezes the plasma-desktop, killing and and restarting plasma-desktop or KDE resolves it
Report
Emdek
9 years ago
Do you have screenshots for these visual issues?
Report
google01103
9 years ago
It seems that if I remove, compile and then reinstall (or maybe just reinstall) it will maybe work once but then it jut freezes when clicked.
Report
Emdek
9 years ago
plasmoidviewer runcommand
I've briefly seen there that gradient issue, this is new Plasma bug, looks like wrong painting of hover background.
Report
Emdek
9 years ago
http://simplest-image-hosting.net/png-0-plasma-desktopkh1921
Hover and focus state backgrounds are not properly drawn (probably are cached) until plasmoid is resized.
Report