* sources/Gtk.metadata:
* api/gtk-api.xml: Gtk.Editable.InsertText should have the position be marked 'ref', not 'out', because it is an in-out parameter. * gtk/Entry.custom: Overload for InsertText. * gtk/Clipboard.custom: New overload for SetText. svn path=/trunk/gtk-sharp/; revision=11430
This commit is contained in:
parent
7a1734be34
commit
fdaa84817e
5 changed files with 28 additions and 2 deletions
|
@ -1,5 +1,12 @@
|
|||
2003-02-09 Duncan Mak <duncan@ximian.com>
|
||||
|
||||
* sources/Gtk.metadata:
|
||||
* api/gtk-api.xml: Gtk.Editable.InsertText should have the
|
||||
position be marked 'ref', not 'out', because it is an in-out parameter.
|
||||
|
||||
* gtk/Entry.custom: Overload for InsertText.
|
||||
* gtk/Clipboard.custom: New overload for SetText.
|
||||
|
||||
* sources/Gtk.metadata: Mark out params for methods in GtkCalendar,
|
||||
GtkCellRenderer, GtkWindow, GtkRuler, GtkLayout, GtkScrolledWindow
|
||||
and GtkSpinButton. Monotalk is very useful for this kind of work.
|
||||
|
|
|
@ -887,7 +887,7 @@
|
|||
<parameters>
|
||||
<parameter type="const-gchar*" name="new_text"/>
|
||||
<parameter type="gint" name="new_text_length"/>
|
||||
<parameter type="gint*" name="position" pass_as="out"/>
|
||||
<parameter type="gint*" name="position" pass_as="ref"/>
|
||||
</parameters>
|
||||
</method>
|
||||
<method name="PasteClipboard" cname="gtk_editable_paste_clipboard">
|
||||
|
|
|
@ -51,4 +51,9 @@
|
|||
return ret;
|
||||
}
|
||||
|
||||
public void SetText (string new_text)
|
||||
{
|
||||
SetText (new_text, new_text.Length);
|
||||
}
|
||||
|
||||
|
||||
|
|
14
gtk/Entry.custom
Normal file
14
gtk/Entry.custom
Normal file
|
@ -0,0 +1,14 @@
|
|||
//
|
||||
// Gtk.Entry.custom - Allow customization of values in the GtkEntry
|
||||
//
|
||||
// This code is inserted after the automatically generated code.
|
||||
//
|
||||
|
||||
public int InsertText (string new_text)
|
||||
{
|
||||
int position = 0;
|
||||
|
||||
InsertText (new_text, new_text.Length, ref position);
|
||||
|
||||
return position;
|
||||
}
|
|
@ -53,7 +53,7 @@
|
|||
<attribute target="param">
|
||||
<filter level="type">gint*</filter>
|
||||
<name>pass_as</name>
|
||||
<value>out</value>
|
||||
<value>ref</value>
|
||||
</attribute>
|
||||
</data>
|
||||
</rule>
|
||||
|
|
Loading…
Reference in a new issue