Geerios

March 18, 2009

I’ve been throwing around a little code inbetween personal projects lately that I use for debugging, and maybe it will be useful for a few other people also.

Essentially it’s a few functions and macros to pretty-print enums and structs based on introspection data, and then also a few convenience things to spawn REPLs to play with objects.

Examples:
GEERIOS_PRINT_ENUM (GdkEventType, event->type)
GEERIOS_PRINT_STRUCT (GdkRectangle, rect)

repl = geerios_repl_new (ctx);

geerios_repl_add_object (repl, "button", button);

// later

geerois_repl_run (repl);

// Now you have a JavaScript REPL to play with the button object, connect signals, check properties, etc...

The code’s a mess, and probably just suited to being copy pasted around…but it’s been useful for me a few times, a nd I don’t have any intention to clean it up much in the near future. So here it is

http://rpi.edu/~carrr/geerios.tar.gz

Leave a Reply