author | hegyi |
Wed, 15 Jun 2005 13:05:32 +0000 | |
changeset 1498 | 352b1ee13bc0 |
child 1499 | 9316dcc0a355 |
permissions | -rw-r--r-- |
hegyi@1497 | 1 |
#include <broken_edge.h> |
hegyi@1497 | 2 |
|
hegyi@1497 | 3 |
BrokenEdge::BrokenEdge(Gnome::Canvas::Group & g, Gnome::Canvas::Points p) : Line(g) |
hegyi@1497 | 4 |
{ |
hegyi@1497 | 5 |
if(p.size()==2) |
hegyi@1497 | 6 |
{ |
hegyi@1497 | 7 |
Gnome::Canvas::Points points_with_center; |
hegyi@1497 | 8 |
points_with_center.push_back(p[0]); |
hegyi@1497 | 9 |
points_with_center.push_back(Gnome::Art::Point( (p[0].get_x()+p[1].get_x())/2+30 , (p[0].get_y()+p[1].get_y())/2 )+30 ); |
hegyi@1497 | 10 |
points_with_center.push_back(p[1]); |
hegyi@1497 | 11 |
|
hegyi@1497 | 12 |
property_points().set_value(points_with_center); |
hegyi@1497 | 13 |
} |
hegyi@1497 | 14 |
} |