canvas-arena.cpp revision 650b8590beba4fbf309a9b8a8c7c785d0fc2d49b
#define __SP_CANVAS_ARENA_C__
/*
* RGBA display list system for inkscape
*
* Author:
* Lauris Kaplinski <lauris@kaplinski.com>
*
* Copyright (C) 2001-2002 Lauris Kaplinski
* Copyright (C) 2001 Ximian, Inc.
*
* Released under GNU GPL, read the file 'COPYING' for more information
*/
#include <gtk/gtksignal.h>
#include <display/display-forward.h>
#include <display/sp-canvas-util.h>
#include <helper/sp-marshal.h>
#include <display/nr-arena.h>
#include <display/nr-arena-group.h>
#include <display/canvas-arena.h>
#include <display/inkscape-cairo.h>
enum {
};
static void sp_canvas_arena_update (SPCanvasItem *item, NR::Matrix const &affine, unsigned int flags);
{NULL},
};
static SPCanvasItemClass *parent_class;
sp_canvas_arena_get_type (void)
{
if (!type) {
GtkTypeInfo info = {
(gchar *)"SPCanvasArena",
sizeof (SPCanvasArena),
sizeof (SPCanvasArenaClass),
};
}
return type;
}
static void
{
}
static void
{
nr_active_object_add_listener ((NRActiveObject *) arena->arena, (NRObjectEventVector *) &carenaev, sizeof (carenaev), arena);
}
static void
{
}
}
}
}
static void
{
NRArenaItem *new_arena = nr_arena_item_invoke_pick (arena->root, arena->c, arena->arena->delta, arena->sticky);
/* fixme: */
}
/* fixme: This is not optimal - better track ::destroy (Lauris) */
}
}
}
}
static void
{
cairo_destroy (ct);
}
static double
{
NRArenaItem *picked = nr_arena_item_invoke_pick (arena->root, p, arena->arena->delta, arena->sticky);
if (picked) {
*actual_item = item;
return 0.0;
}
return 1e18;
}
static gint
{
case GDK_ENTER_NOTIFY:
//g_warning ("Cursor entered to arena with already active item");
}
/* TODO ... event -> arena transform? */
/* fixme: Not sure abut this, but seems the right thing (Lauris) */
nr_arena_item_invoke_update (arena->root, NULL, &arena->gc, NR_ARENA_ITEM_STATE_PICK, NR_ARENA_ITEM_STATE_NONE);
arena->active = nr_arena_item_invoke_pick (arena->root, arena->c, arena->arena->delta, arena->sticky);
}
break;
case GDK_LEAVE_NOTIFY:
}
break;
case GDK_MOTION_NOTIFY:
/* TODO ... event -> arena transform? */
/* fixme: Not sure abut this, but seems the right thing (Lauris) */
nr_arena_item_invoke_update (arena->root, NULL, &arena->gc, NR_ARENA_ITEM_STATE_PICK, NR_ARENA_ITEM_STATE_NONE);
/* fixme: */
}
}
}
break;
default:
/* Just send event */
break;
}
return ret;
}
static gint
{
/* Send event to arena */
return ret;
}
static void
{
}
static void
{
}
void
{
/* fixme: repick? */
}
void
{
/* fixme: repick? */
}
void
{
/* fixme: */
}
/*
Local Variables:
mode:c++
c-file-style:"stroustrup"
c-file-offsets:((innamespace . 0)(inline-open . 0)(case-label . +))
indent-tabs-mode:nil
fill-column:99
End:
*/
// vim: filetype=cpp:expandtab:shiftwidth=4:tabstop=8:softtabstop=4:encoding=utf-8:textwidth=99 :