From 4e19d181c953cf339721426ff72ff9d44e2d605b Mon Sep 17 00:00:00 2001 From: Duncan Mak Date: Mon, 6 Jan 2003 00:50:42 +0000 Subject: [PATCH] 2003-01-05 Pedro Abelleira Seco * gdk/Drawable.custom: Add Size get property 2003-01-05 Duncan Mak * pango/GlyphString.custom: Add some nicer overloads to avoid explicit passing in the string length. svn path=/trunk/gtk-sharp/; revision=10193 --- ChangeLog | 9 +++++++++ gdk/Drawable.custom | 17 +++++++++++++++++ pango/GlyphString.custom | 20 ++++++++++++++++++++ 3 files changed, 46 insertions(+) create mode 100644 gdk/Drawable.custom create mode 100644 pango/GlyphString.custom diff --git a/ChangeLog b/ChangeLog index 492496dd8..1dc26e08e 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,12 @@ +2003-01-05 Pedro Abelleira Seco + + * gdk/Drawable.custom: Add Size get property + +2003-01-05 Duncan Mak + + * pango/GlyphString.custom: Add some nicer overloads to avoid + explicit passing in the string length. + 2003-01-05 Duncan Mak * generator/GenBase.cs (AppendCustom): Add #region to code from diff --git a/gdk/Drawable.custom b/gdk/Drawable.custom new file mode 100644 index 000000000..01744c3af --- /dev/null +++ b/gdk/Drawable.custom @@ -0,0 +1,17 @@ +// Gdk.Drawble.custom - Gdk Drawble class customizations +// +// Author: Pedro Abelleira Seco +// +// This code is inserted after the automatically generated code. + + +/// Size property +/// Returns the size of the Drawble +public System.Drawing.Size Size { + get { + int x, y; + GetSize(ref x, ref y); + return new System.Drawing.Size(x, y); + } +} + diff --git a/pango/GlyphString.custom b/pango/GlyphString.custom new file mode 100644 index 000000000..808775df7 --- /dev/null +++ b/pango/GlyphString.custom @@ -0,0 +1,20 @@ +// +// Pango.GlyphString.custom - Allow customization of values in the GtkAdjustment +// +// This code is inserted after the automatically generated code. +// + +public void GetLogicalWidths (string text, int embedding_level, int logical_widths) +{ + pango_glyph_string_get_logical_widths(ref this, text, text.Length, embedding_level, logical_widths); +} + +public void XToIndex (string text, Pango.Analysis analysis, int x_pos, int index, int trailing) +{ + pango_glyph_string_x_to_index(ref this, text, text.Length, ref analysis, x_pos, index, trailing); +} + +public void IndexToX (string text, Pango.Analysis analysis, int index, bool trailing, int x_pos) +{ + pango_glyph_string_index_to_x(ref this, text, text.Length, ref analysis, index, trailing, x_pos); +}