3 #include <Process/HeaderDelegate.hpp>
4 #include <Process/LayerPresenter.hpp>
6 #include <Scenario/Document/Interval/LayerData.hpp>
7 #include <Scenario/Document/Interval/SlotHeader.hpp>
9 #include <ossia/detail/variant.hpp>
20 std::vector<LayerData> layers;
22 void cleanupHeaderFooter();
23 void cleanup(QGraphicsScene* sc);
27 double headerHeight()
const noexcept
30 return SlotHeader::headerHeight();
33 return header->headerHeight();
35 return headerDelegate->boundingRect().height();
38 double footerHeight()
const noexcept {
return SlotFooter::footerHeight(); }
51 struct SlotPresenter : ossia::variant<LayerSlotPresenter, NodalSlotPresenter>
63 : ossia::variant<LayerSlotPresenter, NodalSlotPresenter>{std::move(l)}
67 : ossia::variant<LayerSlotPresenter, NodalSlotPresenter>{std::move(l)}
73 return ossia::get_if<LayerSlotPresenter>((variant*)
this);
77 return ossia::get_if<NodalSlotPresenter>((variant*)
this);
80 template <
typename Layer,
typename Nodal>
81 auto visit(
const Layer& lfun,
const Nodal& nfun)
89 } visitor{lfun, nfun};
90 return ossia::visit(visitor, (variant&)*
this);
93 template <
typename Layer,
typename Nodal>
94 auto visit(
const Layer& lfun,
const Nodal& nfun)
const
102 } visitor{lfun, nfun};
103 return ossia::visit(visitor, (
const variant&)*
this);
106 template <
typename F>
107 auto visit(
const F& fun)
109 return ossia::visit(fun, (variant&)*
this);
112 template <
typename F>
113 auto visit(
const F& fun)
const
115 return ossia::visit(fun, (
const variant&)*
this);
118 void cleanup(QGraphicsScene* sc)
120 if(
auto p = getLayerSlot())
122 else if(
auto p = getNodalSlot())
Definition: NodalIntervalView.hpp:20
The id_base_t class.
Definition: Identifier.hpp:57
Main plug-in of score.
Definition: score-plugin-dataflow/Dataflow/PortItem.hpp:14
Definition: SlotPresenter.hpp:15
Definition: SlotPresenter.hpp:43
Definition: SlotPresenter.hpp:52