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;
56SCORE_PLUGIN_CURVE_EXPORT
57void createPointAt(std::vector<SegmentData>& segments, Curve::Point pt);
62SCORE_PLUGIN_CURVE_EXPORT
64 const Model& model,
const ossia::hash_set<int32_t>& removed,
bool fill);
82 void submit(
const std::vector<SegmentData>&);
84 auto find(std::vector<SegmentData>& segments,
const OptionalId<SegmentModel>&
id)
87 segments.begin(), segments.end(), [&](
const auto& seg) { return seg.id == id; });
89 auto find(
const std::vector<SegmentData>& segments,
const OptionalId<SegmentModel>&
id)
91 return std::find_if(segments.cbegin(), segments.cend(), [&](
const auto& seg) {
96 virtual void on_press() = 0;
98 QPointF m_originalPress;
100 const Model& m_model;
107 std::vector<SegmentData> m_startSegments;
112 double m_xmin{-1}, m_xmax{2}, m_xLastPoint{2};
Definition CurveCommandObjectBase.hpp:67
std::vector< SegmentData > m_segments
The curve being submitted: kept across moves for its storage.
Definition CurveCommandObjectBase.hpp:109
Definition CurveModel.hpp:26
Definition CurvePresenter.hpp:34
Definition CurvePaletteBaseStates.hpp:20
The SingleOngoingCommandDispatcher class.
Definition SingleOngoingCommandDispatcher.hpp:18
A small abstraction layer over the score::CommandStack.
Definition CommandStackFacade.hpp:21
Utilities and base classes for 1D curves.
Definition FocusDispatcher.hpp:12
void checkValidity(std::span< const SegmentData > segts)
Debug builds: asserts that segts is a valid curve.
Definition CurveCommandObjectBase.cpp:99
std::vector< SegmentData > removeSegments(const Model &model, const ossia::hash_set< int32_t > &removed, bool fill)
Definition CurveCommandObjectBase.cpp:281
void createPointAt(std::vector< SegmentData > &segments, Curve::Point pt)
Definition CurveCommandObjectBase.cpp:152
Base toolkit upon which the software is built.
Definition Application.cpp:83