How do I add stuff to the convert menu in Konqueror? - KDE
This is a discussion on How do I add stuff to the convert menu in Konqueror? - KDE ; I sometimes receive tiff files that I would like to convert to pdf.
The way I do it now is to drop into a command line then tiff2ps -a infile > outfile.ps followed by ps2pdf outfile.ps > infile.pdf
Is there ...
-
How do I add stuff to the convert menu in Konqueror?
I sometimes receive tiff files that I would like to convert to pdf.
The way I do it now is to drop into a command line then tiff2ps -a infile > outfile.ps followed by ps2pdf outfile.ps > infile.pdf
Is there a way to add this as an option to Konqueror's context menu (right click on .tif files and you get a convert option).
Thanks
Brendan
-
Re: How do I add stuff to the convert menu in Konqueror?
Brendan S (Scratch User) wrote:
> I sometimes receive tiff files that I would like to convert to pdf.
>
> The way I do it now is to drop into a command line then tiff2ps -a infile
> > outfile.ps followed by ps2pdf outfile.ps > infile.pdf
>
> Is there a way to add this as an option to Konqueror's context menu (right
> click on .tif files and you get a convert option).
>
> Thanks
>
> Brendan
Yes ther is, using the servicemenus.
You just have to create a .desktop file and place it in in `kde-config
--prefix`/share/apps/konqueror/servicemenus/ (or
~/.kde/share/apps/konqueror/servicemenus/).
I gave it a try, here is the result.
### tiffconverter.desktop ###
[Desktop Entry]
ServiceTypes=image/tiff
Actions=ToPS;ToPDF
X-KDE-Submenu=Convert to
X-KDE-Submenu[fr]=Convertir en
TryExec=tiff2ps
TryExec=tiff2pdf
[Desktop Action ToPS]
Name=PS
Exec=tiff2ps -a %f -O "`echo %f | perl -pe 's/\.[^.]+$//'`.ps"
[Desktop Action ToPDF]
Name=PDF
Exec=tiff2pdf %f -o "`echo %f | perl -pe 's/\.[^.]+$//'`.pdf"
### end of tiffconverter.desktop ###
a tutorial
http://developer.kde.org/documentati...vicemenus.html
standard specifs
http://standards.freedesktop.org/des...y-spec/latest/
-
Re: How do I add stuff to the convert menu in Konqueror?
Thank you. I will give it a go.
Brendan
alex svetos wrote:
> Brendan S (Scratch User) wrote:
>
>
>>I sometimes receive tiff files that I would like to convert to pdf.
>>
>>The way I do it now is to drop into a command line then tiff2ps -a infile
>>
>>>outfile.ps followed by ps2pdf outfile.ps > infile.pdf
>>
>>Is there a way to add this as an option to Konqueror's context menu (right
>>click on .tif files and you get a convert option).
>>
>>Thanks
>>
>>Brendan
>
>
> Yes ther is, using the servicemenus.
>
> You just have to create a .desktop file and place it in in `kde-config
> --prefix`/share/apps/konqueror/servicemenus/ (or
> ~/.kde/share/apps/konqueror/servicemenus/).
>
> I gave it a try, here is the result.
>
> ### tiffconverter.desktop ###
> [Desktop Entry]
> ServiceTypes=image/tiff
> Actions=ToPS;ToPDF
> X-KDE-Submenu=Convert to
> X-KDE-Submenu[fr]=Convertir en
> TryExec=tiff2ps
> TryExec=tiff2pdf
>
>
> [Desktop Action ToPS]
> Name=PS
> Exec=tiff2ps -a %f -O "`echo %f | perl -pe 's/\.[^.]+$//'`.ps"
>
> [Desktop Action ToPDF]
> Name=PDF
> Exec=tiff2pdf %f -o "`echo %f | perl -pe 's/\.[^.]+$//'`.pdf"
>
> ### end of tiffconverter.desktop ###
>
>
>
> a tutorial
> http://developer.kde.org/documentati...vicemenus.html
>
> standard specifs
> http://standards.freedesktop.org/des...y-spec/latest/