canvas-arena.cpp revision 18e68262f518fed952fcf08b7235576dc5a5ed7b
/*
* RGBA display list system for inkscape
*
* Author:
* Lauris Kaplinski <lauris@kaplinski.com>
* Jon A. Cruz <jon@joncruz.org>
*
* Copyright (C) 2001-2002 Lauris Kaplinski
* Copyright (C) 2001 Ximian, Inc.
*
* Released under GNU GPL, read the file 'COPYING' for more information
*/
#include <gtkmm.h>
#include "display/sp-canvas-util.h"
#include "helper/sp-marshal.h"
#include "display/canvas-arena.h"
#include "display/cairo-utils.h"
#include "display/drawing-context.h"
#include "display/drawing-item.h"
#include "display/drawing-group.h"
#include "display/drawing-surface.h"
#include "preferences.h"
using namespace Inkscape;
enum {
};
static void sp_canvas_arena_update (SPCanvasItem *item, Geom::Affine const &affine, unsigned int flags);
static double sp_canvas_arena_point (SPCanvasItem *item, Geom::Point p, SPCanvasItem **actual_item);
{
for (unsigned i=0; i<v.size(); ++i) {
notify(v[i]);
}
prefs->addObserver(*this);
}
if (name == "size") {
}
}
};
static void
{
}
static void
{
root->setPickChildren(true);
arena));
arena));
arena));
}
{
}
static void
{
if (b) {
}
/* fixme: */
}
}
}
}
}
static void
{
}
}
static void
{
// todo: handle NR_ARENA_ITEM_RENDER_NO_CACHE
if (!r || r->hasZeroArea()) return;
}
static double
{
arena->drawing.update(Geom::IntRect::infinite(), arena->ctx, DrawingItem::STATE_PICK | DrawingItem::STATE_BBOX);
if (picked) {
*actual_item = item;
return 0.0;
}
return 1e18;
}
static void
{
// make the cache limit larger than screen to facilitate smooth scrolling
}
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) */
}
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) */
/* fixme: */
}
}
}
break;
case GDK_SCROLL: {
/* Zoom is emitted by the canvas as well, ignore here */
return FALSE;
}
break;
}
default:
/* Just send event */
break;
}
return ret;
}
static gint
{
/* Send event to arena */
return ret;
}
static void
{
}
{
}
void
{
/* fixme: repick? */
}
void
{
/* fixme: repick? */
}
void
sp_canvas_arena_render_surface (SPCanvasArena *ca, cairo_surface_t *surface, Geom::IntRect const &r)
{
}
/*
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:fileencoding=utf-8:textwidth=99 :