tofi icon indicating copy to clipboard operation
tofi copied to clipboard

Feature: Template to configure drun .desktop contents to display

Open muchgitsuchwow opened this issue 1 year ago • 2 comments

Hey there. I'm currently using rofi (lbonn wayland fork) and like to switch to tofi. There is one thing I do which will not work well for me with tofi. I have several .desktop files that all run "Firefox". I can distinguish them with rofi based on "GenericName" attribute from desktop specification. rofi shows this as (e.g.) Firefox (bwrap), or Firefox (work), Firefox (customer), ...

In hope that this is an easy thing to do, I'd love to have some configuration variable how to display contents from a .desktop file in drun mode. Something like e.g. (!) drun_display = "{{.Name}} (<i>{{.GenericName}}</i>)"

muchgitsuchwow avatar Nov 02 '23 10:11 muchgitsuchwow

Hm. Clever people would just update their .desktop files to include this in the Name attribute. Anyway, I'll keep this open. Perhaps this makes sense for other people in other regards. If in doubt feel free to close this one.

muchgitsuchwow avatar Nov 03 '23 05:11 muchgitsuchwow

Hey, yeah I'm not so sure about this. In principle I agree with it, but making the format customisable with things like markup is probably not going to happen anytime soon (if at all). It might be doable though, I'll have to think about it some more when I get the time.

If I did add this soon, it'd probably just be in the form --drun-display=<name|generic_name|comment>, or something like that. I think this is still a fairly niche use-case, though.

Thanks for the suggestion!

philj56 avatar Nov 28 '23 23:11 philj56