Re: Breakpoints

Lauris Kaplinski <[email protected]> Sat, 28 Feb 2004 21:25:43 +0200
Newsgroups gmane.comp.graphics.sodipodi
Message-ID <[email protected]>
Hello!

Russell Shaw kirjutas R, 27.02.2004 kell 18:17:
> I'm trying to figure out how sodipodi works. I want to trace the
> path of execution for something like placing and editing a
> rectangle. I've looked thru the cvs sources. Where is a good
> place to put a gdb breakpoint to start?

Rects are built in rect-context.c, look at
  sp_rect_context_root_handler
it processes mouse events, and creates rectangle in
GDK_MOTION_NOTIFY handler, more specifically in
function sp_rect_drag

BUT

keep in mind, that most drag operations use pointer
capture. Depending on your window manager breaking
application while mouse is captured may made it
impossible to focus gdb terminal.
To overcome this, comment out
sp_canvas_item_grab and sp_canvas_item_ungrab
temporarily while debugging.

Best wishes,
Lauris Kaplinski





-------------------------------------------------------
SF.Net is sponsored by: Speed Start Your Linux Apps Now.
Build and deploy apps & Web services for Linux with
a free DVD software kit from IBM. Click Now!
http://ads.osdn.com/?ad_id=1356&alloc_id=3438&op=click