From 33fbb8c45d56f160569cc4e171c75850534b9fd2 Mon Sep 17 00:00:00 2001 From: Mike Kestner Date: Tue, 12 Apr 2005 03:39:23 +0000 Subject: [PATCH] 2005-04-11 Mike Kestner * gdk/Pixbuf.custom : fix out params on RenderPixmapAndMask* methods. svn path=/trunk/gtk-sharp/; revision=42817 --- ChangeLog | 4 +++ doc/en/Gdk/Pixbuf.xml | 55 ++++++++++++++++++----------------------- doc/en/Gtk/TreePath.xml | 16 +++++++++++- gdk/Pixbuf.custom | 20 ++++++++++----- 4 files changed, 57 insertions(+), 38 deletions(-) diff --git a/ChangeLog b/ChangeLog index 1f6e47f92..627dddc24 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,7 @@ +2005-04-11 Mike Kestner + + * gdk/Pixbuf.custom : fix out params on RenderPixmapAndMask* methods. + 2005-04-11 Dan Winship * generator/ClassBase.cs (ParseImplements): record both managed diff --git a/doc/en/Gdk/Pixbuf.xml b/doc/en/Gdk/Pixbuf.xml index 5b535fe2b..cf3749d69 100644 --- a/doc/en/Gdk/Pixbuf.xml +++ b/doc/en/Gdk/Pixbuf.xml @@ -1460,75 +1460,68 @@ Gdk.Pixbuf pb = new Gdk.Pixbuf(memorystream); - + Method System.Void - - + + - - Creates a pixmap and a mask bitmap which are returned in the - and - arguments, respectively, and renders a pixbuf and its - corresponding thresholded alpha mask to them. This is merely a convenience - function; applications that need to render pixbufs with dither offsets or to - given drawables should use - or and - . - + Creates pixmap and mask bitmaps for a given alpha threshold. a a a , threshold value for opacity. + + This is merely a convenience function; applications that need to render pixbufs with dither offsets or to + given drawables should use + or and . + + The pixmap that is created is created for the colormap returned by . You normally will want to instead use the actual colormap for a widget, and use , If the pixbuf does not have an alpha channel, then will be set to . + - + Method System.Void - - + + - - Creates a pixmap and a mask bitmap which are returned in the - and - arguments, respectively, and renders a pixbuf and its - corresponding thresholded alpha mask to them. - This is merely a convenience - function; applications that need to render pixbufs with dither offsets or to - given drawables should use - or and - . - + Creates pixmap and mask bitmaps for a given alpha threshold using a specified colormap. a a a - a + a , threshold value for opacity. + + This is merely a convenience function; applications that need to render pixbufs with dither offsets or to + given drawables should use or and . + + The pixmap that is created uses the specified by . - This colormap must match the colormap of the window where the pixmap - will eventually be used or an error will result. + This colormap must match the colormap of the window where the pixmap will eventually be used or an error will result. If the pixbuf does not have an alpha channel, then will be set to . - + + diff --git a/doc/en/Gtk/TreePath.xml b/doc/en/Gtk/TreePath.xml index 16b59e8b8..c050348af 100644 --- a/doc/en/Gtk/TreePath.xml +++ b/doc/en/Gtk/TreePath.xml @@ -281,5 +281,19 @@ Returns the native value for . + + + Constructor + + + + + + Creates a path for a set of indices. + a + a + + + - \ No newline at end of file + diff --git a/gdk/Pixbuf.custom b/gdk/Pixbuf.custom index ac7e68ee9..79dc3bb20 100644 --- a/gdk/Pixbuf.custom +++ b/gdk/Pixbuf.custom @@ -58,17 +58,25 @@ } [DllImport("libgdk-win32-2.0-0.dll")] - static extern void gdk_pixbuf_render_pixmap_and_mask(IntPtr raw, IntPtr pixmap_return, IntPtr mask_return, int alpha_threshold); + static extern void gdk_pixbuf_render_pixmap_and_mask (IntPtr raw, out IntPtr pixmap_return, out IntPtr mask_return, int alpha_threshold); - public void RenderPixmapAndMask(Gdk.Pixmap pixmap_return, Gdk.Pixmap mask_return, int alpha_threshold) { - gdk_pixbuf_render_pixmap_and_mask(Handle, pixmap_return.Handle, mask_return.Handle, alpha_threshold); + public void RenderPixmapAndMask (out Pixmap pixmap_return, out Pixmap mask_return, int alpha_threshold) + { + IntPtr mask_handle, pixmap_handle; + gdk_pixbuf_render_pixmap_and_mask (Handle, out pixmap_handle, out mask_handle, alpha_threshold); + pixmap_return = GLib.Object.GetObject (pixmap_handle) as Pixmap; + mask_return = GLib.Object.GetObject (mask_handle) as Pixmap; } [DllImport("libgdk-win32-2.0-0.dll")] - static extern void gdk_pixbuf_render_pixmap_and_mask_for_colormap(IntPtr raw, IntPtr colormap, IntPtr pixmap_return, IntPtr mask_return, int alpha_threshold); + static extern void gdk_pixbuf_render_pixmap_and_mask_for_colormap (IntPtr raw, IntPtr colormap, out IntPtr pixmap_return, out IntPtr mask_return, int alpha_threshold); - public void RenderPixmapAndMaskForColormap(Gdk.Colormap colormap, Gdk.Pixmap pixmap_return, Gdk.Pixmap mask_return, int alpha_threshold) { - gdk_pixbuf_render_pixmap_and_mask_for_colormap(Handle, colormap.Handle, pixmap_return.Handle, mask_return.Handle, alpha_threshold); + public void RenderPixmapAndMaskForColormap (Colormap colormap, out Pixmap pixmap_return, out Pixmap mask_return, int alpha_threshold) + { + IntPtr mask_handle, pixmap_handle; + gdk_pixbuf_render_pixmap_and_mask_for_colormap (Handle, colormap == null ? IntPtr.Zero : colormap.Handle, out pixmap_handle, out mask_handle, alpha_threshold); + pixmap_return = GLib.Object.GetObject (pixmap_handle) as Pixmap; + mask_return = GLib.Object.GetObject (mask_handle) as Pixmap; } [DllImport("libgdk-win32-2.0-0.dll")]