I would need to access KIGFX::PCB_RENDER_SETTINGS::GetGlobalRatsnestLinesEnabled ()
In
BOARD_NETLIST_UPDATER::addNewComponent()
where I could simply set the local ratsnest setting for each pad to the global setting.
The function I need,GetGlobalRatsnestLinesEnabled (), is defined in:
-PCB_RENDER_SETTINGS::PCB_RENDER_SETTINGS
I don't know much of Kicad source code yet, but I don't see any way to get the KIGFX::PCB_RENDER_SETTINGS instance from a BOARD
-----------------
Alternatively, I could use the class that sets the KIGFX::PCB_RENDER_SETTINGS using PCB_RENDER_SETTINGS::LoadDisplayOptions. That function is used by:
-PANEL_PCBNEW_DISPLAY_OPTIONS::TransferDataFromWindow-> A window frame
-FOOTPRINT_VIEWER_FRAME::ApplyDisplaySettingsToGAL -> A window frame
Once again, I am not sure how to link any these class to the board or the netlist updater.
-----------------
PCB_EDIT_FRAME::Exchange_Module does not access the global ratsnest settings, but only copies local settings.
------------------
One solution I can think of, is having a class variable in KIGFX::PCB_RENDER_SETTINGS, shared among all instances, so the netlist updater could instantiate one of them, and then getting the global setting value. But I have no idea what the side effects could be.
That was my first approach.
I would need to access KIGFX:: PCB_RENDER_ SETTINGS: :GetGlobalRatsn estLinesEnabled () UPDATER: :addNewComponen t()
In
BOARD_NETLIST_
where I could simply set the local ratsnest setting for each pad to the global setting.
The function I need,GetGlobalR atsnestLinesEna bled (), is defined in: SETTINGS: :PCB_RENDER_ SETTINGS
-PCB_RENDER_
I don't know much of Kicad source code yet, but I don't see any way to get the KIGFX:: PCB_RENDER_ SETTINGS instance from a BOARD
-----------------
Alternatively, I could use the class that sets the KIGFX:: PCB_RENDER_ SETTINGS using PCB_RENDER_ SETTINGS: :LoadDisplayOpt ions. That function is used by:
-PANEL_ PCBNEW_ DISPLAY_ OPTIONS: :TransferDataFr omWindow- > A window frame VIEWER_ FRAME:: ApplyDisplaySet tingsToGAL -> A window frame
-FOOTPRINT_
Once again, I am not sure how to link any these class to the board or the netlist updater.
-----------------
PCB_EDIT_ FRAME:: Exchange_ Module does not access the global ratsnest settings, but only copies local settings.
------------------
One solution I can think of, is having a class variable in KIGFX:: PCB_RENDER_ SETTINGS, shared among all instances, so the netlist updater could instantiate one of them, and then getting the global setting value. But I have no idea what the side effects could be.