2 #include "core/tool.hpp"
3 #include "canvas/selectables.hpp"
4 #include "util/placement.hpp"
8 class ToolRotateArbitrary :
public ToolBase {
10 ToolRotateArbitrary(IDocument *c, ToolID tid);
19 std::set<InToolActionID> get_actions()
const override
21 using I = InToolActionID;
23 I::LMB, I::CANCEL, I::RMB, I::ENTER_DATUM, I::TOGGLE_ANGLE_SNAP,
33 void expand_selection();
35 void save_placements();
36 void apply_placements_rotation(
int angle);
37 void apply_placements_scale(
double sc);
38 enum class State { ORIGIN, ROTATE, REF, SCALE };
39 State state = State::ORIGIN;
40 std::map<SelectableRef, Placement> placements;
41 class CanvasAnnotation *annotation =
nullptr;