2004-01-25 Mike Kestner <mkestner@ximian.com>

* art/art-api.xml : regen
	* gdk/gdk-api.xml : regen
	* generator/SymbolTable.cs : add unsigned char mapping
	* gnome/gnome-api.xml : regen
	* parser/gapi2xml.pl : handle unsigned keyword in fields,
	typedefs, and parameter types.
	[Fixes #53055]

svn path=/trunk/gtk-sharp/; revision=22487
This commit is contained in:
Mike Kestner 2004-01-26 04:53:05 +00:00
parent 336bb6a786
commit 2340cb040e
6 changed files with 42 additions and 26 deletions

View file

@ -1,9 +1,19 @@
2004-01-25 Mike Kestner <mkestner@ximian.com>
* art/art-api.xml : regen
* gdk/gdk-api.xml : regen
* generator/SymbolTable.cs : add unsigned char mapping
* gnome/gnome-api.xml : regen
* parser/gapi2xml.pl : handle unsigned keyword in fields,
typedefs, and parameter types.
[Fixes #53055]
2004-01-25 Mike Kestner <mkestner@ximian.com>
* gdk/gdk-api.xml : regen
* gnome/gnome-api.xml : regen
* gtk/gtk-api.xml : regen
* parser/gapi2.xml.pl : handle typedef struct {...} Foo;
* parser/gapi2xml.pl : handle typedef struct {...} Foo;
[Fixes #53312]
2004-01-22 Martin Willemoes Hansen <mwh@sysrq.dk>

View file

@ -299,7 +299,7 @@
</parameters>
</constructor>
</struct>
<alias name="PixMaxDepth" cname="ArtPixMaxDepth" type="art_u8" />
<alias name="PixMaxDepth" cname="ArtPixMaxDepth" type="unsigned char" />
<struct name="Point" cname="ArtPoint">
<field cname="x" type="double" />
<field cname="y" type="double" />
@ -686,7 +686,7 @@
</parameters>
</method>
</struct>
<alias name="UtaBbox" cname="ArtUtaBbox" type="art_u32" />
<alias name="UtaBbox" cname="ArtUtaBbox" type="unsigned int" />
<struct name="Vpath" cname="ArtVpath">
<field cname="code" type="ArtPathcode" />
<field cname="x" type="double" />
@ -748,6 +748,9 @@
<field cname="dash" type="double*" />
</struct>
<alias name="ArtBoolean" cname="art_boolean" type="int" />
<alias name="ArtU16" cname="art_u16" type="unsigned short" />
<alias name="ArtU32" cname="art_u32" type="unsigned int" />
<alias name="ArtU8" cname="art_u8" type="unsigned char" />
<class name="Affine" cname="ArtAffine_">
<method name="Equal" cname="art_affine_equal" shared="true">
<return-type type="int" />

View file

@ -4285,8 +4285,8 @@
</callback>
</struct>
<struct name="PixbufModulePattern" cname="GdkPixbufModulePattern">
<field cname="char* prefix" type="unsigned" />
<field cname="char* mask" type="unsigned" />
<field cname="prefix" type="unsigned char*" />
<field cname="mask" type="unsigned char*" />
<field cname="relevance" type="int" />
</struct>
<struct name="Pixdata" cname="GdkPixdata">

View file

@ -56,6 +56,7 @@ namespace GtkSharp.Generation {
AddType (new SimpleGen ("guint1", "bool"));
AddType (new SimpleGen ("gpointer", "IntPtr"));
AddType (new SimpleGen ("guchar", "byte"));
AddType (new SimpleGen ("unsigned char", "byte"));
AddType (new SimpleGen ("short", "short"));
AddType (new SimpleGen ("long", "long"));
AddType (new SimpleGen ("ulong", "ulong"));

View file

@ -729,13 +729,13 @@
<field cname="state" type="int" />
<field cname="grabbed_event_mask" type="guint" />
<field cname="close_enough" type="int" />
<field cname="center_scroll_region" bits="1" type="unsigned" />
<field cname="need_update" bits="1" type="unsigned" />
<field cname="need_redraw" bits="1" type="unsigned" />
<field cname="need_repick" bits="1" type="unsigned" />
<field cname="left_grabbed_item" bits="1" type="unsigned" />
<field cname="in_repick" bits="1" type="unsigned" />
<field cname="aa" bits="1" type="unsigned" />
<field cname="center_scroll_region" bits="1" type="unsigned int" />
<field cname="need_update" bits="1" type="unsigned int" />
<field cname="need_redraw" bits="1" type="unsigned int" />
<field cname="need_repick" bits="1" type="unsigned int" />
<field cname="left_grabbed_item" bits="1" type="unsigned int" />
<field cname="in_repick" bits="1" type="unsigned int" />
<field cname="aa" bits="1" type="unsigned int" />
<field cname="dither" type="GdkRgbDither" />
<property name="Aa" cname="aa" type="gboolean" readable="true" writeable="true" construct-only="true" />
<signal name="DrawBackground" cname="draw_background" when="LAST">
@ -1073,7 +1073,7 @@
<method name="Grab" cname="gnome_canvas_item_grab">
<return-type type="int" />
<parameters>
<parameter type="unsigned" name="int" />
<parameter type="unsigned int" name="event_mask" />
<parameter type="GdkCursor*" name="cursor" />
<parameter type="guint32" name="etime" />
</parameters>
@ -1285,7 +1285,7 @@
<field cname="y1" type="double" />
<field cname="x2" type="double" />
<field cname="y2" type="double" />
<field cname="path_dirty" bits="1" type="unsigned" />
<field cname="path_dirty" bits="1" type="unsigned int" />
<property name="X1" cname="x1" type="gdouble" readable="true" writeable="true" />
<property name="Y1" cname="y1" type="gdouble" readable="true" writeable="true" />
<property name="X2" cname="x2" type="gdouble" readable="true" writeable="true" />
@ -1497,8 +1497,8 @@
<field cname="rect" type="ArtIRect" />
<field cname="buf_rowstride" type="int" />
<field cname="bg_color" type="guint32" />
<field cname="is_bg" bits="1" type="unsigned" />
<field cname="is_buf" bits="1" type="unsigned" />
<field cname="is_bg" bits="1" type="unsigned int" />
<field cname="is_buf" bits="1" type="unsigned int" />
<method name="EnsureBuf" cname="gnome_canvas_buf_ensure_buf">
<return-type type="void" />
</method>
@ -3748,11 +3748,11 @@
<field cname="width" type="int" />
<field cname="fontname" type="char*" />
<field cname="text" type="char*" />
<field cname="editing" bits="1" type="unsigned" />
<field cname="selected" bits="1" type="unsigned" />
<field cname="focused" bits="1" type="unsigned" />
<field cname="is_editable" bits="1" type="unsigned" />
<field cname="is_text_allocated" bits="1" type="unsigned" />
<field cname="editing" bits="1" type="unsigned int" />
<field cname="selected" bits="1" type="unsigned int" />
<field cname="focused" bits="1" type="unsigned int" />
<field cname="is_editable" bits="1" type="unsigned int" />
<field cname="is_text_allocated" bits="1" type="unsigned int" />
<field cname="_priv" type="GnomeIconTextItemPrivate*" />
<signal name="TextChanged" cname="text_changed" when="LAST">
<return-type type="gboolean" />

View file

@ -64,6 +64,8 @@ while ($line = <STDIN>) {
$sdef =~ s!/\*.*?(\*/|\n)!!g;
$sdef =~ s/\n\s*//g;
$types{$1} = $sdef if ($sdef =~ /.*\}\s*(\w+);/);
} elsif ($line =~ /typedef\s+(unsigned\s+\w+)\s+(\**)(\w+);/) {
$types{$3} = $1 . $2;
} elsif ($line =~ /typedef\s+(\w+)\s+(\**)(\w+);/) {
$types{$3} = $1 . $2;
} elsif ($line =~ /typedef\s+enum\s+(\w+)\s+(\w+);/) {
@ -443,8 +445,8 @@ sub addFieldElems
$elem = addNameElem($parent, 'callback', $2);
addReturnElem($elem, $1);
addParamsElem($elem, $3);
} elsif ($field =~ /(\S+)\s+(.+)/) {
$type = $1; $symb = $2;
} elsif ($field =~ /(unsigned )?(\S+)\s+(.+)/) {
$type = $1 . $2; $symb = $3;
foreach $tok (split (/,\s*/, $symb)) {
if ($tok =~ /(\w+)\s*\[(.*)\]/) {
$elem = addNameElem($parent, 'field', $1);
@ -689,9 +691,9 @@ sub addParamsElem
if ($parm =~ /struct\s+(\S+)\s+(\S+)/) {
$parm_elem->setAttribute('type', $1);
$name = $2;
}elsif ($parm =~ /(\S+)\s+(\S+)/) {
$parm_elem->setAttribute('type', $1);
$name = $2;
}elsif ($parm =~ /(unsigned )?(\S+)\s+(\S+)/) {
$parm_elem->setAttribute('type', $1 . $2);
$name = $3;
} elsif ($parm =~ /(\S+)/) {
$parm_elem->setAttribute('type', $1);
$name = "arg" . $parm_num;