2#include <Curve/Segment/CurveSegmentData.hpp>
4#include <score/command/Dispatchers/SingleOngoingCommandDispatcher.hpp>
5#include <score/model/Identifier.hpp>
6#include <score/model/path/Path.hpp>
7#include <score/tools/IdentifierGeneration.hpp>
8#include <score/tools/std/Optional.hpp>
10#include <ossia/detail/hash_map.hpp>
16#include <score_plugin_curve_export.h>
23class CommandStackFacade;
51using SegmentMapImpl = ossia::hash_map<Id<SegmentModel>, SegmentData, CurveDataHash>;
52void checkValidity(std::span<SegmentData> segts);
53void checkValidity(SegmentMapImpl& segts);
71 void submit(std::vector<SegmentData>&&);
73 auto find(std::vector<SegmentData>& segments,
const OptionalId<SegmentModel>&
id)
76 segments.begin(), segments.end(), [&](
const auto& seg) { return seg.id == id; });
78 auto find(
const std::vector<SegmentData>& segments,
const OptionalId<SegmentModel>&
id)
80 return std::find_if(segments.cbegin(), segments.cend(), [&](
const auto& seg) {
85 virtual void on_press() = 0;
87 QVector<QByteArray> m_oldCurveData;
88 QPointF m_originalPress;
97 std::vector<SegmentData> m_startSegments;
100 double m_xmin{-1}, m_xmax{2}, m_xLastPoint{2};
Definition CurveCommandObjectBase.hpp:56
Definition CurveModel.hpp:25
Definition CurvePresenter.hpp:32
Definition CurvePaletteBaseStates.hpp:20
The SingleOngoingCommandDispatcher class.
Definition SingleOngoingCommandDispatcher.hpp:17
A small abstraction layer over the score::CommandStack.
Definition CommandStackFacade.hpp:20
Utilities and base classes for 1D curves.
Definition FocusDispatcher.hpp:12
Base toolkit upon which the software is built.
Definition Application.cpp:90