Fill in missing zone properties.

Also fixes some bugs with hatch properties being available
on rule areas.
This commit is contained in:
Jeff Young
2024-02-04 23:01:31 +00:00
parent b08f1ee6bf
commit 77c19fa99a
6 changed files with 160 additions and 41 deletions
+19 -2
View File
@@ -41,7 +41,7 @@ wxPGProperty* PGPropertyFactory( const PROPERTY_BASE* aProperty, EDA_DRAW_FRAME*
class PGPROPERTY_DISTANCE
{
public:
PGPROPERTY_DISTANCE( EDA_DRAW_FRAME* aParentFrame, const wxString& aRegEx,
PGPROPERTY_DISTANCE( EDA_DRAW_FRAME* aParentFrame,
ORIGIN_TRANSFORMS::COORD_TYPES_T aCoordType );
virtual ~PGPROPERTY_DISTANCE() = 0;
@@ -53,11 +53,28 @@ protected:
protected:
EDA_DRAW_FRAME* m_parentFrame;
std::unique_ptr<REGEX_VALIDATOR> m_regExValidator;
ORIGIN_TRANSFORMS::COORD_TYPES_T m_coordType;
};
class PGPROPERTY_AREA : public wxIntProperty
{
public:
PGPROPERTY_AREA( EDA_DRAW_FRAME* aParentFrame );
protected:
bool StringToValue( wxVariant& aVariant, const wxString& aText,
int aArgFlags = 0 ) const override;
wxString ValueToString( wxVariant& aVariant, int aArgFlags = 0 ) const override;
wxValidator* DoGetValidator() const override;
protected:
EDA_DRAW_FRAME* m_parentFrame;
};
class PGPROPERTY_SIZE : public wxUIntProperty, public PGPROPERTY_DISTANCE
{
public:
+1
View File
@@ -55,6 +55,7 @@ enum PROPERTY_DISPLAY
{
PT_DEFAULT, ///< Default property for a given type
PT_SIZE, ///< Size expressed in distance units (mm/inch)
PT_AREA, ///< Area expressed in distance units-squared (mm/inch)
PT_COORD, ///< Coordinate expressed in distance units (mm/inch)
PT_DEGREE, ///< Angle expressed in degrees
PT_DECIDEGREE ///< Angle expressed in decidegrees