3 #include "core/core_schematic.hpp"
4 #include "search/searcher_schematic.hpp"
7 class ImpSchematic :
public ImpBase {
10 ImpSchematic(
const std::string &schematic_filename,
const std::string &block_filename,
11 const std::string &pictures_dir,
const PoolParams ¶ms);
12 void update_highlights()
override;
15 void construct()
override;
16 bool handle_broadcast(
const json &j)
override;
17 void handle_maybe_drag()
override;
18 void update_action_sensitivity()
override;
20 ActionCatalogItem::Availability get_editor_type_for_action()
const override
22 return ActionCatalogItem::AVAILABLE_IN_SCHEMATIC;
25 std::string get_hud_text(std::set<SelectableRef> &sel)
override;
26 void search_center(
const Searcher::SearchResult &res)
override;
27 ActionToolID get_doubleclick_action(ObjectType type,
const UUID &uu)
override;
28 void expand_selection_for_property_panel(std::set<SelectableRef> &sel_extra,
29 const std::set<SelectableRef> &sel)
override;
31 Searcher *get_searcher_ptr()
override
36 ToolID get_tool_for_drag_move(
bool ctrl,
const std::set<SelectableRef> &sel)
const override;
40 void canvas_update()
override;
41 CoreSchematic core_schematic;
42 const std::string project_dir;
43 SearcherSchematic searcher;
45 int handle_ask_net_merge(
class Net *net,
class Net *into);
46 int handle_ask_delete_component(
class Component *comp);
47 void handle_select_sheet(Sheet *sh);
48 void handle_remove_sheet(Sheet *sh);
49 void handle_core_rebuilt();
50 void handle_tool_change(ToolID
id)
override;
51 void handle_move_to_other_sheet(
const ActionConnection &conn);
52 void handle_highlight_group_tag(
const ActionConnection &conn);
53 std::string last_pdf_filename;
55 std::map<UUID, std::pair<float, Coordf>> sheet_views;
56 std::map<UUID, std::set<SelectableRef>> sheet_selections;
57 class SheetBox *sheet_box;
58 void handle_selection_cross_probe();
59 bool cross_probing_enabled =
false;
61 Coordf cursor_pos_drag_begin;
62 Target target_drag_begin;
64 class BOMExportWindow *bom_export_window;
65 class PDFExportWindow *pdf_export_window;
66 class UnplacedBox *unplaced_box =
nullptr;
67 void update_unplaced();
71 Glib::RefPtr<Gio::SimpleAction> toggle_snap_to_targets_action;
75 UUID net_from_selectable(
const SelectableRef &sr);