2 #include "canvas/appearance.hpp"
3 #include "nlohmann/json_fwd.hpp"
4 #include <sigc++/sigc++.h>
6 #include "imp/action_catalog.hpp"
17 void load_from_json(
const json &j);
18 void load_colors_from_json(
const json &j);
19 json serialize()
const;
20 json serialize_colors()
const;
25 bool show_all_junctions =
false;
26 bool drag_start_net_line =
true;
28 void load_from_json(
const json &j);
29 json serialize()
const;
34 bool drag_start_track =
true;
35 bool highlight_on_top =
true;
36 bool show_text_in_tracks =
true;
38 void load_from_json(
const json &j);
39 json serialize()
const;
44 std::map<std::pair<ActionID, ToolID>, std::map<ActionCatalogItem::Availability, std::vector<KeySequence>>> keys;
46 void load_from_json(
const json &j);
47 void append_from_json(
const json &j);
48 json serialize()
const;
53 bool smooth_zoom_2d =
true;
54 bool smooth_zoom_3d =
false;
55 bool touchpad_pan =
false;
57 void load_from_json(
const json &j);
58 json serialize()
const;
64 std::string url =
"https://dev-partinfo.kitspace.org/graphql";
65 std::string preferred_distributor;
66 bool ignore_moq_gt_1 =
true;
67 unsigned int max_price_breaks = 3;
68 unsigned int cache_days = 5;
69 bool is_enabled()
const;
71 void load_from_json(
const json &j);
72 json serialize()
const;
78 void set_filename(
const std::string &filename);
81 void load_from_json(
const json &j);
83 static std::string get_preferences_filename();
84 json serialize()
const;
92 bool capture_output =
false;
95 typedef sigc::signal<void> type_signal_changed;
96 type_signal_changed signal_changed()
98 return s_signal_changed;
102 std::string filename;
103 type_signal_changed s_signal_changed;