Lumiera  0.pre.03
»edit your freedom«
marker-widget.cpp
Go to the documentation of this file.
1 /*
2  MarkerWidget - display of a marker in timeline or within clips
3 
4  Copyright (C)
5  2016, Hermann Vosseler <Ichthyostega@web.de>
6 
7   **Lumiera** is free software; you can redistribute it and/or modify it
8   under the terms of the GNU General Public License as published by the
9   Free Software Foundation; either version 2 of the License, or (at your
10   option) any later version. See the file COPYING for further details.
11 
12 * *****************************************************************/
13 
14 
24 #include "stage/gtk-base.hpp"
25 #include "include/ui-protocol.hpp"
27 
28 //#include "stage/ui-bus.hpp"
29 //#include "lib/format-string.hpp"
30 //#include "lib/format-cout.hpp"
31 
32 //#include "lib/util.hpp"
33 
34 //#include <algorithm>
35 //#include <vector>
36 
37 
38 
39 //using util::_Fmt;
41 //using util::contains;
42 //using Gtk::Widget;
43 //using sigc::mem_fun;
44 //using sigc::ptr_fun;
45 //using std::cout;
46 //using std::endl;
47 
48 
49 namespace stage {
50 namespace timeline {
51 
52 
53 
54 
55 
57  : model::Widget{identity, nexus}
59  , kind_{MARK}
60  , name_{identity.getSym()} // ID symbol as name fallback
61  {
62  UNIMPLEMENTED ("how to attach the Marker, depending on the actual context");
63  }
64 
65 
66  MarkerWidget::~MarkerWidget()
67  {
68  }
69 
70 
71 
72 
73  void
75  {
76  buffer.emplace(
78  .change(ATTR_name, [&](string val)
79  {
80  name_ = val;
81  })
82  .change(META_kind, [&](string val)
83  {
84  if (val == "LOOP") kind_ = LOOP;
85  else kind_ = MARK;
86  }));
87  }
88 
96  void
98  {
99  UNIMPLEMENTED ("how to re-attach the Marker, depending on the actual context");
100  }
101 
102 
103 
104 
105 }}// namespace stage::timeline
Hard wired key constants and basic definitions for communication with the GUI.
Widget to show a marker at various places.
connection point at the UI-Bus.
Definition: bus-term.hpp:96
ElementBoxWidget(Kind kind, Type type, QS ...qualifiers)
setup an ElementBoxWidget with suitable presentation style.
void relink()
update and re-attach the presentation widget into its presentation context.
MarkerWidget(ID identity, ctrl::BusTerm &nexus)
static Builder< TreeMutator > build()
DSL: start building a custom adapted tree mutator, where the operations are tied by closures or wrapp...
SUB & emplace(SUB &&implementation)
move-construct an instance of a subclass into the opaque buffer
A handle to allow for safe »remote implantation« of an unknown subclass into a given opaque InPlaceBu...
Definition: record.hpp:104
Lumiera GTK UI implementation root.
Definition: guifacade.cpp:37
Widget is a pin or marks a position.
virtual void buildMutator(lib::diff::TreeMutator::Handle) override
set up a binding to respond to mutation messages via UiBus
represents a label or descriptor
A set of basic GTK includes for the UI.
Customisable intermediary to abstract mutating operations on arbitrary, hierarchical object-like data...