Files
Upsilon/kandinsky/src/point.cpp
Romain Goyet 5de28e01db Migrate Kandinsky to C++
Change-Id: I2752a8db84ad0bb817119cf6c2993c1622621150
2016-07-21 13:42:32 +02:00

13 lines
299 B
C++

#include <kandinsky/point.h>
KDCoordinate KDPoint::x() const { return m_x; }
KDCoordinate KDPoint::y() const { return m_y; }
KDPoint KDPoint::translatedBy(KDPoint other) const {
return KDPoint(m_x+other.x(), m_y+other.y());
}
KDPoint KDPoint::opposite() const {
return KDPoint(-m_x, -m_y);
}