icon special variables for exec

Terry td3201 at gmail.com
Fri Jul 9 15:07:30 BST 2004


Mmm, that is close.  I don't want an action.

I want a single Icon that looks something like this:

[Desktop Entry]
Comment=
Comment[en_US]=
Encoding=UTF-8
Exec=rdesktop -g 1280x1024 %f 
GenericName=
GenericName[en_US]=
Icon=samba
MimeType=
Name=
Name[en_US]=
Path=
StartupNotify=true
Terminal=false
TerminalOptions=
Type=Application
X-DCOP-ServiceType=
X-KDE-SubstituteUID=false
X-KDE-Username=

The name of this icon is 'foobar' as determined by the rename action
when I right click on the icon.  So I want the command to be 'rdesktop
-g 1280x1024 foobar'.

I hope this clears up some confusion.  :)


On Wed, 07 Jul 2004 23:13:17 -0700, James Richard Tyrer <tyrerj at acm.org> wrote:
> 
> 
> Terry wrote:
> > On Tue, 06 Jul 2004 19:18:13 -0700, James Richard Tyrer <tyrerj at acm.org> wrote:
> >
> >>
> >>Terry wrote:
> >>
> >>>Hello,
> >>>
> >>>I created an icon in a folder within KDE.  I named it foobar.   I gave
> >>>it an exec command line.  However, I want it to be something like
> >>>Exec=rdesktop -g 1280x1024 $0
> >>>where $0 is the name of the icon, foobar, like in shell.  How can I do
> >>>this?  Come to think of it, I could have it invoke a single shell
> >>>script and do my magic there but I guess it would be nice to know if
> >>>there are special variables for this type of function available.
> >>
> >>IIUC, $0 would give you rdesktop.  If that is what you want, use %i
> >>
> >>Otherwise:
> >>
> >>        Exec=rdesktop -g 1280x1024 --icon <icon>
> >>
> >>or
> >>
> >>        Exec=rdesktop -g 1280x1024  -- --icon <icon>
> >>
> >>--
> >>JRT
> >
> >
> > I don't want to set the icon or the name of it, i just want to read
> > it.  For example, I created a new 'Link to Application'.  I right
> > clicked this and did a rename and named it to 'foobar'.  I right click
> > on it again and go to properties.  I click on the application tab.  In
> > the command box, I want to put something like:
> > rdesktop -g 1280x1024 <SOMETHING>   where <SOMETHING> is a special
> > variable that contains the name of the object, in this case, 'foobar'.
> >   :)
> > 
> OK, I have done that.  This is for a service menu item? correct?  Or, perhaps I
> still don't know exactly what you want to do.
> 
> Handy hint: the service menus are in:
> 
>         $HOME/share/apps/konqueror/servicemenus
> 
> You might want to look at some of them.
> 
> You use: %f for a service menu 'desktop' file.  At least this one that I created
> works:
> 
> ------8<------8<------8<------8<------8<------8<------8<------8<
> [Desktop Entry]
> Encoding=UTF-8
> ServiceTypes=all/allfiles
> Actions=bzip2_file
> 
> [Desktop Action bzip2_file]
> Name=Create Bzip2 File
> Icon=zip
> Exec=bzip2 %f
> 
> ------8<------8<------8<------8<------8<------8<------8<------8<
> 
> 
> 
> --
> JRT
> 
> ___________________________________________________
> This message is from the kde mailing list.
> Account management:  https://mail.kde.org/mailman/listinfo/kde.
> Archives: http://lists.kde.org/.
> More info: http://www.kde.org/faq.html.
>
___________________________________________________
This message is from the kde mailing list.
Account management:  https://mail.kde.org/mailman/listinfo/kde.
Archives: http://lists.kde.org/.
More info: http://www.kde.org/faq.html.




More information about the kde mailing list