seltrans.h revision d61d2d7858ded67cc041d49e7c81a10a84c9e164
#ifndef SEEN_SELTRANS_H
#define SEEN_SELTRANS_H
/*
* Helper object for transforming selected items
*
* Authors:
* Lauris Kaplinski <lauris@kaplinski.com>
* Carl Hetherington <inkscape@carlh.net>
* Diederik van Lierop <mail@diedenrezi.nl>
*
* Copyright (C) 2006 Johan Engelen <johan@shouraizou.nl>
* Copyright (C) 1999-2002 Lauris Kaplinski
*
* Released under GNU GPL, read the file 'COPYING' for more information
*/
#include <stddef.h>
#include "knot.h"
#include "selcue.h"
#include "message-context.h"
#include <vector>
#include "sp-item.h"
struct SPKnot;
struct SPCanvasItem;
struct SPCtrlLine;
struct SPSelTransHandle;
{
Geom::Scale calcScaleFactors(Geom::Point const &initial_point, Geom::Point const &new_point, Geom::Point const &origin, bool const skew = false);
{
}
{
~SelTrans();
return _message_context;
}
void increaseState();
void resetState();
void ungrab();
void stamp();
gboolean handleRequest(SPKnot *knot, Geom::Point *position, guint state, SPSelTransHandle const &handle);
void handleNewEvent(SPKnot *knot, Geom::Point *position, guint state, SPSelTransHandle const &handle);
enum Show
{
};
_show = s;
}
bool isEmpty() {
return _empty;
}
bool isGrabbed() {
return _grabbed;
}
bool centerIsVisible() {
}
void getNextClosestPoint(bool reverse);
void _updateHandles();
void _updateVolatileState();
enum State {
STATE_SCALE, //scale or stretch
STATE_ROTATE //rotate or skew
};
bool _grabbed;
bool _show_handles;
bool _empty;
bool _changed;
/* According to Merriam - Webster's online dictionary
* Affine: a transformation (as a translation, a rotation, or a uniform stretching) that carries straight
* lines into straight lines and parallel lines into parallel lines but may alter distance between points
* and angles between lines <affine geometry>
*/
bool _center_is_set; ///< we've already set _center, no need to reread it from items
};
}
#endif // SEEN_SELTRANS_H
/*
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 :