Horizon
entity_preview.hpp
1 #pragma once
2 #include <gtkmm.h>
3 #include <set>
4 #include "common/common.hpp"
5 #include "util/uuid.hpp"
6 #include "preview_base.hpp"
7 
8 namespace horizon {
9 class EntityPreview : public Gtk::Box, public PreviewBase {
10 public:
11  EntityPreview(class Pool &pool, bool show_goto = true);
12 
13  void load(const class Entity *entity);
14  void load(const class Part *part);
15  void clear();
16 
17 private:
18  void load(const class Entity *entity, const class Part *part);
19  class Pool &pool;
20  const class Entity *entity = nullptr;
21  const class Part *part = nullptr;
22  class PreviewCanvas *canvas_symbol = nullptr;
23  Gtk::ComboBoxText *combo_gate = nullptr;
24  Gtk::ComboBoxText *combo_symbol = nullptr;
25 
26  void handle_gate_sel();
27  void handle_symbol_sel();
28 };
29 } // namespace horizon
Definition: preview_canvas.hpp:5
Definition: entity_preview.hpp:9
Definition: part.hpp:13
Definition: entity.hpp:13
Definition: preview_base.hpp:9
Stores objects (Unit, Entity, Symbol, Part, etc.) from the pool.
Definition: pool.hpp:19
Definition: block.cpp:9