#include #include #include #include #include #include "gen_qline.h" #include "_cgo_export.h" void QLine_new(QLine** outptr_QLine) { QLine* ret = new QLine(); *outptr_QLine = ret; } void QLine_new2(QPoint* pt1, QPoint* pt2, QLine** outptr_QLine) { QLine* ret = new QLine(*pt1, *pt2); *outptr_QLine = ret; } void QLine_new3(int x1, int y1, int x2, int y2, QLine** outptr_QLine) { QLine* ret = new QLine(static_cast(x1), static_cast(y1), static_cast(x2), static_cast(y2)); *outptr_QLine = ret; } void QLine_new4(QLine* param1, QLine** outptr_QLine) { QLine* ret = new QLine(*param1); *outptr_QLine = ret; } bool QLine_IsNull(const QLine* self) { return self->isNull(); } QPoint* QLine_P1(const QLine* self) { return new QPoint(self->p1()); } QPoint* QLine_P2(const QLine* self) { return new QPoint(self->p2()); } int QLine_X1(const QLine* self) { return self->x1(); } int QLine_Y1(const QLine* self) { return self->y1(); } int QLine_X2(const QLine* self) { return self->x2(); } int QLine_Y2(const QLine* self) { return self->y2(); } int QLine_Dx(const QLine* self) { return self->dx(); } int QLine_Dy(const QLine* self) { return self->dy(); } void QLine_Translate(QLine* self, QPoint* p) { self->translate(*p); } void QLine_Translate2(QLine* self, int dx, int dy) { self->translate(static_cast(dx), static_cast(dy)); } QLine* QLine_Translated(const QLine* self, QPoint* p) { return new QLine(self->translated(*p)); } QLine* QLine_Translated2(const QLine* self, int dx, int dy) { return new QLine(self->translated(static_cast(dx), static_cast(dy))); } QPoint* QLine_Center(const QLine* self) { return new QPoint(self->center()); } void QLine_SetP1(QLine* self, QPoint* p1) { self->setP1(*p1); } void QLine_SetP2(QLine* self, QPoint* p2) { self->setP2(*p2); } void QLine_SetPoints(QLine* self, QPoint* p1, QPoint* p2) { self->setPoints(*p1, *p2); } void QLine_SetLine(QLine* self, int x1, int y1, int x2, int y2) { self->setLine(static_cast(x1), static_cast(y1), static_cast(x2), static_cast(y2)); } bool QLine_OperatorEqual(const QLine* self, QLine* d) { return (*self == *d); } bool QLine_OperatorNotEqual(const QLine* self, QLine* d) { return (*self != *d); } QLineF* QLine_ToLineF(const QLine* self) { return new QLineF(self->toLineF()); } void QLine_Delete(QLine* self, bool isSubclass) { if (isSubclass) { delete dynamic_cast( self ); } else { delete self; } } void QLineF_new(QLineF** outptr_QLineF) { QLineF* ret = new QLineF(); *outptr_QLineF = ret; } void QLineF_new2(QPointF* pt1, QPointF* pt2, QLineF** outptr_QLineF) { QLineF* ret = new QLineF(*pt1, *pt2); *outptr_QLineF = ret; } void QLineF_new3(double x1, double y1, double x2, double y2, QLineF** outptr_QLineF) { QLineF* ret = new QLineF(static_cast(x1), static_cast(y1), static_cast(x2), static_cast(y2)); *outptr_QLineF = ret; } void QLineF_new4(QLine* line, QLineF** outptr_QLineF) { QLineF* ret = new QLineF(*line); *outptr_QLineF = ret; } void QLineF_new5(QLineF* param1, QLineF** outptr_QLineF) { QLineF* ret = new QLineF(*param1); *outptr_QLineF = ret; } QLineF* QLineF_FromPolar(double length, double angle) { return new QLineF(QLineF::fromPolar(static_cast(length), static_cast(angle))); } bool QLineF_IsNull(const QLineF* self) { return self->isNull(); } QPointF* QLineF_P1(const QLineF* self) { return new QPointF(self->p1()); } QPointF* QLineF_P2(const QLineF* self) { return new QPointF(self->p2()); } double QLineF_X1(const QLineF* self) { qreal _ret = self->x1(); return static_cast(_ret); } double QLineF_Y1(const QLineF* self) { qreal _ret = self->y1(); return static_cast(_ret); } double QLineF_X2(const QLineF* self) { qreal _ret = self->x2(); return static_cast(_ret); } double QLineF_Y2(const QLineF* self) { qreal _ret = self->y2(); return static_cast(_ret); } double QLineF_Dx(const QLineF* self) { qreal _ret = self->dx(); return static_cast(_ret); } double QLineF_Dy(const QLineF* self) { qreal _ret = self->dy(); return static_cast(_ret); } double QLineF_Length(const QLineF* self) { qreal _ret = self->length(); return static_cast(_ret); } void QLineF_SetLength(QLineF* self, double lenVal) { self->setLength(static_cast(lenVal)); } double QLineF_Angle(const QLineF* self) { qreal _ret = self->angle(); return static_cast(_ret); } void QLineF_SetAngle(QLineF* self, double angle) { self->setAngle(static_cast(angle)); } double QLineF_AngleTo(const QLineF* self, QLineF* l) { qreal _ret = self->angleTo(*l); return static_cast(_ret); } QLineF* QLineF_UnitVector(const QLineF* self) { return new QLineF(self->unitVector()); } QLineF* QLineF_NormalVector(const QLineF* self) { return new QLineF(self->normalVector()); } int QLineF_Intersects(const QLineF* self, QLineF* l) { QLineF::IntersectionType _ret = self->intersects(*l); return static_cast(_ret); } QPointF* QLineF_PointAt(const QLineF* self, double t) { return new QPointF(self->pointAt(static_cast(t))); } void QLineF_Translate(QLineF* self, QPointF* p) { self->translate(*p); } void QLineF_Translate2(QLineF* self, double dx, double dy) { self->translate(static_cast(dx), static_cast(dy)); } QLineF* QLineF_Translated(const QLineF* self, QPointF* p) { return new QLineF(self->translated(*p)); } QLineF* QLineF_Translated2(const QLineF* self, double dx, double dy) { return new QLineF(self->translated(static_cast(dx), static_cast(dy))); } QPointF* QLineF_Center(const QLineF* self) { return new QPointF(self->center()); } void QLineF_SetP1(QLineF* self, QPointF* p1) { self->setP1(*p1); } void QLineF_SetP2(QLineF* self, QPointF* p2) { self->setP2(*p2); } void QLineF_SetPoints(QLineF* self, QPointF* p1, QPointF* p2) { self->setPoints(*p1, *p2); } void QLineF_SetLine(QLineF* self, double x1, double y1, double x2, double y2) { self->setLine(static_cast(x1), static_cast(y1), static_cast(x2), static_cast(y2)); } bool QLineF_OperatorEqual(const QLineF* self, QLineF* d) { return (*self == *d); } bool QLineF_OperatorNotEqual(const QLineF* self, QLineF* d) { return (*self != *d); } QLine* QLineF_ToLine(const QLineF* self) { return new QLine(self->toLine()); } int QLineF_Intersects2(const QLineF* self, QLineF* l, QPointF* intersectionPoint) { QLineF::IntersectionType _ret = self->intersects(*l, intersectionPoint); return static_cast(_ret); } void QLineF_Delete(QLineF* self, bool isSubclass) { if (isSubclass) { delete dynamic_cast( self ); } else { delete self; } }