Horizon
tool_place_power_symbol.hpp
1 #pragma once
2 #include "core.hpp"
3 #include "schematic/power_symbol.hpp"
4 #include "tool_place_junction.hpp"
5 #include <forward_list>
6 
7 namespace horizon {
8 
10 public:
11  ToolPlacePowerSymbol(Core *c, ToolID tid);
12  bool can_begin() override;
13 
14 protected:
15  void create_attached() override;
16  void delete_attached() override;
17  bool begin_attached() override;
18  bool update_attached(const ToolArgs &args) override;
19  bool check_line(LineNet *li) override;
20  PowerSymbol *sym = nullptr;
21  std::forward_list<PowerSymbol *> symbols_placed;
22  Net *net = nullptr;
23 
24 private:
25  bool do_merge(Net *other);
26 };
27 } // namespace horizon
horizon::LineNet
LineNet is similar to Line, except it denotes electrical connection.
Definition: line_net.hpp:24
horizon::Net
Definition: net.hpp:16
horizon::ToolPlacePowerSymbol::can_begin
bool can_begin() override
Definition: tool_place_power_symbol.cpp:13
horizon::Core
Where Tools and and documents meet.
Definition: core.hpp:240
horizon::ToolPlaceJunction
Definition: tool_place_junction.hpp:7
horizon::ToolArgs
This is what a Tool receives when the user did something.
Definition: core.hpp:26
horizon::ToolPlacePowerSymbol
Definition: tool_place_power_symbol.hpp:9
horizon::PowerSymbol
GND symbols and the like.
Definition: power_symbol.hpp:23