![]() |
Fréchet View
1.6.0
A Tool for Exploring Fréchet Distance Algorithms
|
a QGraphicsLitem that can handle mouse hover events. It is used to highlight mouse sensitve polygon segments.
Each line segment has a "logical" identifier within a polygonal curve, or feasible paht.
Definition at line 239 of file baseview.h.
#include <baseview.h>
Inherits QGraphicsLineItem.
Public Types | |
enum | Location { None, P, Q, Pdiag, Qdiag, FS } |
location of the polygon segment More... | |
Public Member Functions | |
GraphicsHoverLineItem (QLineF line, Location loc, int a, int b, QGraphicsItemGroup *group) | |
default constructor More... | |
void | update (int a, int b) |
update identifiers More... | |
bool | is_close_to (QPointF scene_pos, int distance) const |
check if the mouse is close to the line segment More... | |
Public Attributes | |
const Location | loc |
location on screen More... | |
const int | a |
parameters loc,a, and b identify a segment. More... | |
const int | b |
location of the polygon segment
Definition at line 243 of file baseview.h.
GraphicsHoverLineItem::GraphicsHoverLineItem | ( | QLineF | line, |
Location | loc, | ||
int | a, | ||
int | b, | ||
QGraphicsItemGroup * | group | ||
) |
default constructor
line | a line |
loc | location on screen |
a | segment identifier |
b | segment identifier |
group | group to add to |
Definition at line 661 of file baseview.cpp.
bool GraphicsHoverLineItem::is_close_to | ( | QPointF | scene_pos, |
int | distance | ||
) | const |
check if the mouse is close to the line segment
scene_pos | mouse position in scene coordinates |
distance | max. distance to accept as hover |
Definition at line 674 of file baseview.cpp.
void GraphicsHoverLineItem::update | ( | int | a, |
int | b | ||
) |
update identifiers
Definition at line 669 of file baseview.cpp.
const int frechet::view::GraphicsHoverLineItem::a |
parameters loc,a, and b identify a segment.
Definition at line 257 of file baseview.h.
const int frechet::view::GraphicsHoverLineItem::b |
Definition at line 257 of file baseview.h.
const Location frechet::view::GraphicsHoverLineItem::loc |
location on screen
Definition at line 251 of file baseview.h.