Commit Graph

17 Commits

Author SHA1 Message Date
Mike Kestner
30e653825c This is an enormous commit of stuff that I've been working on for several
weeks.  I'll be posting an update to gtk-sharp-list in a bit to describe my
latest psychosis.

svn path=/trunk/gtk-sharp/; revision=1797
2002-01-04 02:02:28 +00:00
Mike Kestner
e1c553c646 2001-12-31 Mike Kestner <mkestner@speakeasy.net>
* codegen/defs-parse.pl : Fix EOL handling for DOS \r\n patterns as
	reported by David Dawkins.

svn path=/trunk/gtk-sharp/; revision=1763
2001-12-31 10:40:48 +00:00
Mike Kestner
354b306274 2001-12-04 Mike Kestner <mkestner@speakeasy.net>
* codegen/defs-parse.pl : Index %structs by cname, not name. Derive
	  structs from class to facilitate marshalling since Value types can't
	  use the Marshal.PtrToStructure method. Generate StructLayout attr
	  for struct class defs. Stuff the signal args into a SignalArgs inst
	  to pass to the EventHandlers.
	* sample/HelloWorld.cs : some cleanup and temporary signal playcode.

svn path=/trunk/gtk-sharp/; revision=1526
2001-12-04 19:34:26 +00:00
Mike Kestner
372e7ef7de 2001-11-25 Mike Kestner <mkestner@speakeasy.net>
* codegen/defs-parse.pl (get_sighandler): gen the helper class. arg
	  passing and return value handling need beefing up still.
	* glib/SignalArgs.cs : New arg passing/ return value handling class.
	* glib/SignalCallback.cs (dtor): kill, this will be gen'd in the
	  subclasses. (ctor): prune down to two params.

svn path=/trunk/gtk-sharp/; revision=1438
2001-11-25 17:06:27 +00:00
Mike Kestner
bb8d2c4ee9 2001-11-24 Mike Kestner <mkestner@speakeasy.net>
* codegen/defs-parse.pl : mkdir the glib/generated dir.
	(gen_signal): Call new get_sighandler sub. Doesn't use the returned
	  value yet.  s/event/ev3nt on arg names.
	(get_sighandler): new sub to lookup or gen a signal helper/delegate.
	  Only generates the delegate so far.
	* codegen/hardcoded.defs : Added a stub for Gdk.Event.
	* gdk/Event.cs : Killed, now a generated struct.
	* gdk/SimpleEvent.cs (SimpleEventCallback): Use Marshal.PtrToStructure
	  to create the Event, not a ctor(IntPtr).
	* glib/SignalCallback.cs : New abstract base class for signal helpers.

svn path=/trunk/gtk-sharp/; revision=1437
2001-11-25 00:25:47 +00:00
Mike Kestner
2ce0c470c2 2001-11-14 Mike Kestner <mkestner@speakeasy.net>
* codegen/defs-parse.pl : Add System.Collections to usings.
	s/event/signal. Add gen_signal sub and call it from gen_object.
	Mangle method names that collide with signal names by prepending
	Emit to the method name.
	* codegen/makefile : add gtk-signals.defs to the build.

svn path=/trunk/gtk-sharp/; revision=1359
2001-11-14 23:45:44 +00:00
Mike Kestner
2af291dc52 2001-11-10 Mike Kestner <mkestner@speakeasy.net>
* codegen/defs-parse.pl : Fix String prop generation code.
	* gtk/Window.custom : Fix ctor param casting error.

svn path=/trunk/gtk-sharp/; revision=1319
2001-11-10 16:32:12 +00:00
Mike Kestner
c9a40e80bc 2001-11-09 Mike Kestner <mkestner@speakeasy.net>
* codegen/defs-parse.pl : Use the @ctors list to determine if a class
	is abstract.  There is an abstract indicator in the new defs format
	description, but it doesn't appear in the defs files currently. This
	method should be reliable though, even in the long term. Use the same
	check to determine if ctor(IntPtr obj) should be gen'd.

svn path=/trunk/gtk-sharp/; revision=1315
2001-11-10 02:35:15 +00:00
Mike Kestner
200f01ad2d 2001-11-09 Mike Kestner <mkestner@speakeasy.net>
* codegen/defs-parse.pl : Now genning Window, AccelGroup, Bin, and
	GdkPixbuf classes to peel the csc error onion. Explicitly add GObject
	to the "exists ($objects{...})" branches, since GObject is a hard
	coded Class.

svn path=/trunk/gtk-sharp/; revision=1314
2001-11-10 02:17:57 +00:00
Mike Kestner
1351a509e6 2001-11-08 Mike Kestner <mkestner@speakeasy.net>
* codegen/defs-parse.pl : Build a structs hash and gen the structs
	after the first pass of the defs.  For structs and functions, mangle
	the 100s of params/fields named object to objekt. Insert using stmnts
	for structs too.
	* codegen/hardcoded.defs : Add GtkAccelEntry struct.

svn path=/trunk/gtk-sharp/; revision=1286
2001-11-08 01:35:11 +00:00
Mike Kestner
807b6ea645 2001-11-07 Mike Kestner <mkestner@speakeasy.net>
* codegen/defs-parse.pl (gen_object): Insert using statements. Insert
	class members from corresponding .custom file.
	* gtk/Window.custom : Renamed file from Window.cs.  Removed all the
	automatically generated members.  This will be the mechanism used to
	improve upon the mechanically generated binding.

svn path=/trunk/gtk-sharp/; revision=1282
2001-11-07 23:13:05 +00:00
Mike Kestner
4fbf115083 2001-11-05 Mike Kestner <mkestner@speakeasy.net>
* codegen/defs-parse.pl (gen_object): Generate a ctor (IntPtr obj) for
	every object.  This is a wrapper constructor for use by an Object
	manager which will be called by GLib.Object.GetObject eventually to
	wrap raw GObject pointers returned by methods/props.

svn path=/trunk/gtk-sharp/; revision=1270
2001-11-06 01:08:51 +00:00
Mike Kestner
aba851645c 2001-11-04 Mike Kestner <mkestner@speakeasy.net>
* codegen/defs-parse.pl : struct generation.  Added float and double
	type mapping entries.
	* codegen/hardcoded.defs : GdkGeometry definition.  define-struct
	doesn't appear to be supported in the current defs files.  This file
	will be used for manual definition of unsupported defs.
	* codegen/makefile : add hardcoded.defs.

svn path=/trunk/gtk-sharp/; revision=1256
2001-11-04 15:42:46 +00:00
Mike Kestner
408db7677c 2001-11-02 Mike Kestner <mkestner@speakeasy.net>
* codegen/defs-parse.pl : define-struct detection.  Partial ctor
	support.  Still need to deal with ctor signature collisions.
	Refactored gen_method to share get_param_strings with ctors.

svn path=/trunk/gtk-sharp/; revision=1245
2001-11-03 00:45:15 +00:00
Mike Kestner
c3b0ed58d9 2001-10-30 Mike Kestner <mkestner@speakeasy.net>
* codegen/defs-parse.pl : streamline mkdir stuff.  Prune the object
	list back to just Window for now. Suppress generation of the Prop
	get/set accessor methods.
	* codegen/gdk-types.defs : Updated the 2button/3button event types
	since I don't feel like automangling them now.
	* gdk/Event.cs : Killed the now redundant EventType declaration.
	* glib/Object.cs : Override the Equals and GetHashCode methods.

svn path=/trunk/gtk-sharp/; revision=1231
2001-10-31 01:31:05 +00:00
Mike Kestner
d7df5fa0ca 2001-10-25 Mike Kestner <mkestner@speakeasy.net>
* codegen/get-props-from-source.pl : Temporary (possibly) defs
	generator for props. Will probably kill this when the official
	defs support props.
	* codegen/defs-parse.pl : Added object-based aggregation of
	defs. Generate the class shells, methods, and props.
	* codegen/gdk-types.defs : ripped from pygtk.
	* codegen/gtk.defs : ripped from pygtk.
	* codegen/gtk-props.defs : some props defs.
	* codegen/makefile : add the new defs files.

svn path=/trunk/gtk-sharp/; revision=1203
2001-10-25 22:16:10 +00:00
Mike Kestner
bd567cdd45 2001-10-11 Mike Kestner <mkestner@speakeasy.net>
* makefile : Add the codegen directory
	* codegen/defs-parse.pl : Moved here from topdir and updated to parse
	the new defs format for enums and flags.
	* codegen/gtk-types.defs : Borrowed from pygtk.
	* codegen/makefile : new
	* gtk/makefile : remove generation step.
	* gtk/gtk.defs : removed, now in codegen dir.

svn path=/trunk/gtk-sharp/; revision=1139
2001-10-11 10:14:14 +00:00