Add Display Origin Transform data to the PCB_DISPLAY_OPTIONS class

This commit adds the user configuration options to support display
origin transforms to the PCB_DISPLAY_OPTIONS class. This data is
configured by the "Origins & Axes" preferences panel added in a
later commit.
This commit is contained in:
Reece R. Pollack 2020-07-04 13:37:59 -04:00 committed by Seth Hillbrand
parent 6e25b7d455
commit 2895d664e6
2 changed files with 20 additions and 0 deletions

View File

@ -102,6 +102,22 @@ public:
double m_PadOpacity; ///< Opacity override for SMD pads and PTHs
double m_ZoneOpacity; ///< Opacity override for filled zone areas
/**
* Enum PCB_DISPLAY_ORIGIN_OPTIONS_T
* is the set of values for DISPLAY_OPTIONS.DisplayOrigin parameter option.
* This parameter controls what is used as the origin point for location values
*/
enum PCB_DISPLAY_ORIGIN_OPTIONS_T {
PCB_ORIGIN_PAGE = 0,
PCB_ORIGIN_AUX,
PCB_ORIGIN_GRID,
};
/// Which origin is used for display transforms
PCB_DISPLAY_ORIGIN_OPTIONS_T m_DisplayOrigin;
bool m_DisplayInvertXAxis; //< true: Invert the X axis for display
bool m_DisplayInvertYAxis; //< true: Invert the Y axis for display
public:
PCB_DISPLAY_OPTIONS();

View File

@ -59,4 +59,8 @@ PCB_DISPLAY_OPTIONS::PCB_DISPLAY_OPTIONS()
m_ViaOpacity = 1.0;
m_PadOpacity = 1.0;
m_ZoneOpacity = 1.0;
m_DisplayOrigin = PCB_ORIGIN_PAGE;
m_DisplayInvertXAxis = false;
m_DisplayInvertYAxis = false;
}