/*
* Simple non-transformed rectangle, usable for rubberband
*
* Author:
* Lauris Kaplinski <lauris@ximian.com>
* bulia byak <buliabyak@users.sf.net>
* Carl Hetherington <inkscape@carlh.net>
* Jon A. Cruz <jon@joncruz.org>
*
* Copyright (C) 1999-2001 Lauris Kaplinski
* Copyright (C) 2000-2001 Ximian, Inc.
*
* Released under GNU GPL
*
*/
#include "sodipodi-ctrlrect.h"
#include "sp-canvas-util.h"
#include "display/cairo-utils.h"
#include "display/sp-canvas.h"
/*
* Currently we do not have point method, as it should always be painted
* during some transformation, which takes care of events...
*
* Corner coords can be in any order - i.e. x1 < x0 is allowed
*/
{
}
{
}
{
}
}
{
}
{
}
{
_has_fill = false;
_dashed = false;
_checkerboard = false;
_shadow = 0;
_shadow_size = 0;
_border_color = 0x000000ff;
_fill_color = 0xffffffff;
_shadow_color = 0x000000ff;
}
{
using Geom::X;
using Geom::Y;
if (!_area) {
return;
}
{
if (_checkerboard) {
}
if (_has_fill) {
}
if (_dashed) {
} else {
}
}
}
}
{
using Geom::X;
using Geom::Y;
}
sp_canvas_item_reset_bounds(this);
if (_area_old) { // this weird construction is because the code below assumes _area_old to be 'valid'
}
// FIXME: we don't process a possible change in _has_fill
if (_has_fill) {
if (_area_old) {
}
if (_area) {
}
} else { // clear box, be smart about what part of the frame to redraw
/* Top */
} else { // same level, redraw only the ends
}
}
}
/* Left */
} else { // same level, redraw only the ends
}
}
}
/* Right */
} else { // same level, redraw only the ends
}
}
}
/* Bottom */
} else { // same level, redraw only the ends
}
}
}
}
// update SPCanvasItem box
if (_area) {
}
}
{
_border_color = b;
_has_fill = h;
_fill_color = f;
}
{
_shadow = s;
_shadow_color = c;
}
{
_rect = r;
}
{
_dashed = d;
}
{
_checkerboard = d;
}
{
}
/*
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 :