I wanted to have a quick way to rotate the images I take with my digital camera. The Olympus Camedia C-4000 always writes "1" als orientation into the EXIF data (either it doesn't have an orientaiton sensor or it is broken), therefore I cannot rotate the images automatically by the command
jhead -autorot *.jpg
So I created a desktop file ~/bin/rotate90clockwise.desktpop with the following content
[Desktop Entry] ServiceTypes=image/jpeg Actions=rotate90clockwise [Desktop Action rotate90clockwise] Name=Rotate 90 clockwise Icon=/opt/kde3/share/icons/crystalsvg/22x22/actions/rotate_cw.png Exec=/usr/bin/jhead -cmd "jpegtran -rot 90 &i > &o" %U
Then I made a symbolic link
sudo ln -sf ~/bin/rotate90clockwise.desktop /opt/kde3/share/apps/konqueror/servicemenus/rotate90clockwise.desktop
Now when I browse files in Konqueror, I get by right-clicking a jpeg file the additonal option of rotating it. The rotation is lossless BTW and the EXIF information in maintaned. It is also possible to integrate rotation commands into image viewing software. E.g. if the following script is located in ~/bin
!/bin/sh jhead -cmd "jpegtran -rot 90 &i > &o" $*
you can call it from within GQView by adding the scriptname in one of the free slots below the "big" image editors:
Menu name Command line Rotate clockwise rotate_clockwise %f
Edit -> Options -> Editors