After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 676696 - Automatic EXIF image rotation doesn't work
Automatic EXIF image rotation doesn't work
Status: RESOLVED FIXED
Product: evolution
Classification: Applications
Component: Mailer
3.2.x (obsolete)
Other Linux
: Normal normal
: ---
Assigned To: evolution-mail-maintainers
Evolution QA team
Depends on:
Blocks:
 
 
Reported: 2012-05-24 03:23 UTC by Jean-François Fortin Tam
Modified: 2013-03-14 22:36 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
sample (212.23 KB, application/mbox)
2012-05-24 03:23 UTC, Jean-François Fortin Tam
Details

Description Jean-François Fortin Tam 2012-05-24 03:23:15 UTC
Created attachment 214828 [details]
sample

Supposedly implemented in bug 598305, but the following email does not show the attachment properly rotated in Evolution 3.2. Opening the image file in Eye of GNOME displays the correct orientation.

Attached is the sample email file that exhibits this behavior.
Comment 1 Matthew Barnes 2012-05-24 03:57:52 UTC
It was implemented as part of the "image-inline" module which used GtkImageView.  Unfortunately GtkImageView has yet to be ported to gtk3 so we had to disable the module.
Comment 2 Jean-François Fortin Tam 2012-05-24 04:13:07 UTC
In any case, I suspect everything will probably change again with the port to webkit?
Comment 3 Dan Vrátil 2012-05-25 08:37:51 UTC
I guess we could use some libexif to detect orientation and then rotate the image through native CSS3 

-webkit-transform: rotate(180deg);

From what I can see that's all what the image-inline can do (+ autoscaling the image to match the window, but WebKit handles that automatically already).
Comment 4 Matthew Barnes 2012-05-25 11:42:21 UTC
It scaled the image to the window size, but for really large images GtkImageView also let you click the image to get a full size but clipped view and then click and drag to pan around like in Google Maps.

But sadly I think GtkImageView is a dead project and won't see a gtk3 port.

You don't need to ask libexif directly to get orientation, you can just query a GdkPixbuf for an "orientation" option like this:

http://git.gnome.org/browse/evolution/tree/plugins/image-inline/image-inline.c#n50

I assume you would work that directly into EMFormatHTML or EWebView?  After which we could probably just kill the "image-inline" plugin.
Comment 5 Matthew Barnes 2013-03-03 19:19:34 UTC
I discovered that WebCore is capable of handling EXIF orientations automatically, but the feature is disabled by default and the setting that controls it is not exposed through WebKitWebSettings.

I put in a plea on the mailing list for a new GObject property:
https://lists.webkit.org/pipermail/webkit-gtk/2013-March/001372.html
Comment 6 Matthew Barnes 2013-03-14 22:36:31 UTC
My request made it into WebKitGTK+ 2.0.  I'm having Evolution test for the new WebKit setting and enable it if present, so this should start working again in Evolution 3.8 once WebKitGTK+ 2.0 is installed.

Fixed in:
https://git.gnome.org/browse/evolution/commit/?id=035fa295cd121615924fb64a219a8cbb06df9155