Krunner Coding Questions

David Baron d_baron at 012.net.il
Tue Aug 17 08:36:35 CEST 2010


On Tuesday 17 August 2010 02:13:44 Sebastian Kügler wrote:
> On Monday 16 August 2010 12:13:10 David Baron wrote:
> > I have a krunner coded with "run" actions.
> > 
> > 1. I add the actions. Their icons overwrite the "wrench" icon on the
> > right. I actually prefer the icons rather than a the dropdown usually
> > shown when clicking that icon. So I want to not have the "wrench" icon
> > at all, just mine. How?

If I do not set the run options true, I only get my icons and they are 
active--i.e activities to trigger.

> > 
> > 2. The action I have in mind would open the configuration dialog normally
> > opened for my runner in the dropdown list of all the runners. Since this
> > is a separate "kcm-module," how do I load it and exercise it, getting
> > the configuration changed signal to my runner (the parent)?
> > 
> > (I could simply locally create the UI with my own default/apply/cancel
> > buttonbox and do this brute force. But why?)
> > 
> > 3. I do not want the krunner window to close when I click this action. I
> > want to re-perform the match with any new options. How do I keep krunner
> > "live" and accomplish this?
> > 
> > Any help or pointers to documentations would be greatly appreciated. Many
> > thanks in advance.
> > 
> > (To try current version of recollrunner, get it from kde-apps.org.
> > Recollindex runs nicely in the background and does not bog down my system
> > as does the "default" kde indexer :-) )
> 
> Sounds like what you actually want to do is implement a completely
> different KRunner UI. In that case, a good start is the RunnerManager
> class.

I found this. I need to know how to get to the instance that has access to the 
runners rather than just a "new" one I new. Similarly, I need get to the 
configuration UI for my runner. Then, if I change the config, I would 
launchQuery().

Not really such a radically different interface per se. In my runner, I am 
tweaking a search engine so want to be able to do this "live." Runners like 
recent docs and execs do not need this. Nepomukers and recollrunners might, 
and there may be more that might take this code once it works :-)


More information about the Plasma-devel mailing list