[f-spot] oups, missing file
- From: Stephane Delcroix <sdelcroix src gnome org>
- To: svn-commits-list gnome org
- Subject: [f-spot] oups, missing file
- Date: Wed, 17 Jun 2009 10:41:04 -0400 (EDT)
commit 53c12eb3fe312010d5c287bdcad7d03fac108273
Author: Stephane Delcroix <stephane delcroix org>
Date: Wed Jun 17 16:37:26 2009 +0200
oups, missing file
src/Utils/PixbufOrientation.cs | 65 ++++++++++++++++++++++++++++++++++++++++
1 files changed, 65 insertions(+), 0 deletions(-)
---
diff --git a/src/Utils/PixbufOrientation.cs b/src/Utils/PixbufOrientation.cs
new file mode 100644
index 0000000..3bed592
--- /dev/null
+++ b/src/Utils/PixbufOrientation.cs
@@ -0,0 +1,65 @@
+//
+// FSpot.PixbufUtils.cs
+//
+// Author(s):
+// Ettore Perazzoli
+// Larry Ewing <lewing novell com>
+// Stephane Delcroix <stephane declroix org>
+//
+// This is free softwae. See cOPYING for details
+//
+
+/**
+ 1 2 3 4 5 6 7 8
+
+888888 888888 88 88 8888888888 88 88 8888888888
+88 88 88 88 88 88 88 88 88 88 88 88
+8888 8888 8888 8888 88 8888888888 8888888888 88
+88 88 88 88
+88 88 888888 888888
+
+t-l t-r b-r b-l l-t r-t r-b l-b
+
+**/
+
+namespace FSpot.Utils
+{
+ public enum PixbufOrientation {
+ TopLeft = 1,
+ TopRight = 2,
+ BottomRight = 3,
+ BottomLeft = 4,
+ LeftTop = 5,
+ RightTop = 6,
+ RightBottom = 7,
+ LeftBottom = 8
+ }
+
+ public static class PixbufUtils
+ {
+ static public PixbufOrientation Rotate270 (PixbufOrientation orientation)
+ {
+ PixbufOrientation [] rot = new PixbufOrientation [] {
+ PixbufOrientation.LeftBottom,
+ PixbufOrientation.LeftTop,
+ PixbufOrientation.RightTop,
+ PixbufOrientation.RightBottom,
+ PixbufOrientation.BottomLeft,
+ PixbufOrientation.TopLeft,
+ PixbufOrientation.TopRight,
+ PixbufOrientation.BottomRight
+ };
+
+ orientation = rot [((int)orientation) -1];
+ return orientation;
+ }
+
+ static public PixbufOrientation Rotate90 (PixbufOrientation orientation)
+ {
+ orientation = Rotate270 (orientation);
+ orientation = Rotate270 (orientation);
+ orientation = Rotate270 (orientation);
+ return orientation;
+ }
+ }
+}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]