Author: jbevain
Date: 2007-10-06 09:33:55 -0400 (Sat, 06 Oct 2007)
New Revision: 87031
Modified:
trunk/moon/src/ChangeLog
trunk/moon/src/media.cpp
Log:
2007-10-06 Jb Evain <[EMAIL PROTECTED]>
* media.cpp (Image::Render): Deal with clipping.
Modified: trunk/moon/src/ChangeLog
===================================================================
--- trunk/moon/src/ChangeLog 2007-10-06 09:34:34 UTC (rev 87030)
+++ trunk/moon/src/ChangeLog 2007-10-06 13:33:55 UTC (rev 87031)
@@ -1,3 +1,7 @@
+2007-10-06 Jb Evain <[EMAIL PROTECTED]>
+
+ * media.cpp (Image::Render): Deal with clipping.
+
2007-10-05 Chris Toshok <[EMAIL PROTECTED]>
* animation.cpp (KeyFrameComparer): fix airlines (and probably a
Modified: trunk/moon/src/media.cpp
===================================================================
--- trunk/moon/src/media.cpp 2007-10-06 09:34:34 UTC (rev 87030)
+++ trunk/moon/src/media.cpp 2007-10-06 13:33:55 UTC (rev 87031)
@@ -24,6 +24,7 @@
#include "error.h"
#include "downloader.h"
#include "playlist.h"
+#include "geometry.h"
// still too ugly to be exposed in the header files ;-)
cairo_pattern_t *image_brush_create_pattern (cairo_t *cairo, cairo_surface_t
*surface, int sw, int sh, double opacity);
@@ -1282,6 +1283,13 @@
cairo_set_matrix (cr, &absolute_xform);
+ Value *value = GetValue (UIElement::ClipProperty);
+ if (value) {
+ Geometry *geometry = value->AsGeometry ();
+ geometry->Draw (NULL, cr);
+ cairo_clip (cr);
+ }
+
Stretch stretch = media_base_get_stretch (this);
double w = framework_element_get_width (this);
_______________________________________________
Mono-patches maillist - [email protected]
http://lists.ximian.com/mailman/listinfo/mono-patches