Blame c++/vector/outlinearea.h

Ivan Mahonin 145120
#ifndef OUTLINEAREA_H
Ivan Mahonin 145120
#define OUTLINEAREA_H
Ivan Mahonin 145120
Ivan Mahonin 145120
Ivan Mahonin 145120
#include "activearea.h"
Ivan Mahonin 145120
#include "activecurve.h"
Ivan Mahonin 145120
Ivan Mahonin 145120
Ivan Mahonin 145120
class OutlineArea: public ActiveArea {
Ivan Mahonin 145120
protected:
Ivan Mahonin 145120
	ActiveCurve curve;
Ivan Mahonin 145120
	ActivePoint::Handle w;
Ivan Mahonin 145120
Ivan Mahonin 145120
	Real get_width() const;
Ivan Mahonin 145120
	void set_width(const Real &width);
Ivan Mahonin 145120
Ivan Mahonin 145120
	void put_bezier(const Context &context, const Bezier &bezier, const Real &width = 0, bool jump = false);
Ivan Mahonin 145120
	void put_hermite(const Context &context, const Hermite &hermite, const Real &width = 0, bool jump = false)
Ivan Mahonin 145120
		{ put_bezier(context, hermite.get_bezier(), width, jump); }
Ivan Mahonin 145120
	void put_curve(const Context &context, const ActiveCurve &curve, const Real &width);
Ivan Mahonin 145120
	void draw_curve(const Context &context, const ActiveCurve &curve, const Real &width);
Ivan Mahonin 145120
Ivan Mahonin 145120
	void on_point_move(const ActivePoint::Handle &point, const Vector &oldposition, const Vector &newposition) override;
Ivan Mahonin 145120
	void on_draw_content(const Context &context) override;
Ivan Mahonin 145120
	
Ivan Mahonin 145120
public:
Ivan Mahonin 145120
	OutlineArea();
Ivan Mahonin 145120
};
Ivan Mahonin 145120
Ivan Mahonin 145120
Ivan Mahonin 145120
#endif