Commit a3f48bf2 authored by charras's avatar charras

pcbnew Added: control of masks clearance. See changelog for more info

parent 1a4d2389
...@@ -4,6 +4,24 @@ KiCad ChangeLog 2009 ...@@ -4,6 +4,24 @@ KiCad ChangeLog 2009
Please add newer entries at the top, list the date and your name with Please add newer entries at the top, list the date and your name with
email address. email address.
2009-Nov-04 UPDATE Jean-Pierre Charras <jean-pierre.charras@gipsa-lab.inpg.fr>
================================================================================
++pcbnew
Added: control of masks clearance
- Solder mask clearance can be now defined at footprint and pad level
- Solder paste clearance can be now defined as a global value
and also at footprint and pad level.
The clearance is defined by a constant value and a value proportional to the pad size.
The final value is the sum of the 2 partial values
Note: this is a work in progress:
currently, the pad dialog is not finished and does not
have an option to enter the mask values
Planned:
option to define a net clearance at pad level and footprint level,
as an alternate value to the Netclasses values.
this option could be useful to create fiducials, and for very small footprints.
2009-Nov-1 UPDATE Dick Hollenbeck <dick@softplc.com> 2009-Nov-1 UPDATE Dick Hollenbeck <dick@softplc.com>
================================================================================ ================================================================================
++pcbnew ++pcbnew
......
...@@ -9,22 +9,26 @@ ...@@ -9,22 +9,26 @@
class EDA_BoardDesignSettings class EDA_BoardDesignSettings
{ {
protected: protected:
int m_CopperLayerCount; // Number of copper layers for this design int m_CopperLayerCount; // Number of copper layers for this design
public: public:
bool m_MicroViasAllowed; // true to allow micro vias bool m_MicroViasAllowed; // true to allow micro vias
int m_CurrentViaType; // via type (VIA_BLIND_BURIED, VIA_TROUGHT VIA_MICROVIA) int m_CurrentViaType; // via type (VIA_BLIND_BURIED, VIA_TROUGHT VIA_MICROVIA)
bool m_UseConnectedTrackWidth; // if true, when creating a new track starting on an existing track, use this track width bool m_UseConnectedTrackWidth; // if true, when creating a new track starting on an existing track, use this track width
int m_DrawSegmentWidth; // current graphic line width (not EDGE layer) int m_DrawSegmentWidth; // current graphic line width (not EDGE layer)
int m_EdgeSegmentWidth; // current graphic line width (EDGE layer only) int m_EdgeSegmentWidth; // current graphic line width (EDGE layer only)
int m_PcbTextWidth; // current Pcb (not module) Text width int m_PcbTextWidth; // current Pcb (not module) Text width
wxSize m_PcbTextSize; // current Pcb (not module) Text size wxSize m_PcbTextSize; // current Pcb (not module) Text size
int m_TrackMinWidth; // track min value for width ((min copper size value int m_TrackMinWidth; // track min value for width ((min copper size value
int m_ViasMinSize; // vias (not micro vias) min diameter int m_ViasMinSize; // vias (not micro vias) min diameter
int m_ViasMinDrill; // vias (not micro vias) min drill diameter int m_ViasMinDrill; // vias (not micro vias) min drill diameter
int m_MicroViasMinSize; // micro vias (not vias) min diameter int m_MicroViasMinSize; // micro vias (not vias) min diameter
int m_MicroViasMinDrill; // micro vias (not vias) min drill diameter int m_MicroViasMinDrill; // micro vias (not vias) min drill diameter
int m_MaskMargin; // Solder mask margin // Global mask margins:
int m_LayerThickness; // Layer Thickness for 3D viewer int m_SolderMaskMargin; // Solder mask margin
int m_SolderPasteMargin; // Solder paste margin absolute value
double m_SolderPasteMarginRatio; // Solder pask margin ratio value of pad size
// The final margin is the sum of these 2 values
int m_LayerThickness; // Layer Thickness for 3D viewer
protected: protected:
int m_EnabledLayers; // Bit-mask for layer enabling int m_EnabledLayers; // Bit-mask for layer enabling
...@@ -32,14 +36,15 @@ protected: ...@@ -32,14 +36,15 @@ protected:
int m_VisibleElements; // Bit-mask for element category visibility int m_VisibleElements; // Bit-mask for element category visibility
public: public:
// Color options for screen display of the Printed Board: // Color options for screen display of the Printed Board:
int m_LayerColor[32]; // Layer colors (tracks and graphic items) int m_LayerColor[32]; // Layer colors (tracks and graphic items)
int m_ViaColor[4]; // Via color (depending on is type) int m_ViaColor[4]; // Via color (depending on is type)
// Pad color for the pads of both sides is m_PadCUColor OR m_PadCMPColor (in terms of colors) // Pad color for the pads of both sides is m_PadCUColor OR m_PadCMPColor (in terms of colors)
int m_RatsnestColor; // Ratsnest color int m_RatsnestColor; // Ratsnest color
public: public:
...@@ -50,7 +55,7 @@ public: ...@@ -50,7 +55,7 @@ public:
* returns a bit-mask of all the layers that are visible * returns a bit-mask of all the layers that are visible
* @return int - the visible layers in bit-mapped form. * @return int - the visible layers in bit-mapped form.
*/ */
int GetVisibleLayers() const; int GetVisibleLayers() const;
/** /**
* Function SetVisibleLayers * Function SetVisibleLayers
...@@ -69,10 +74,12 @@ public: ...@@ -69,10 +74,12 @@ public:
{ {
if( aLayerIndex < 0 || aLayerIndex >= 32 ) //@@IMB: Altough Pcbnew uses only 29, Gerbview uses all 32 layers if( aLayerIndex < 0 || aLayerIndex >= 32 ) //@@IMB: Altough Pcbnew uses only 29, Gerbview uses all 32 layers
return false; return false;
// If a layer is disabled, it is automatically invisible // If a layer is disabled, it is automatically invisible
return (bool)( m_VisibleLayers & m_EnabledLayers & 1 << aLayerIndex ); return (bool) ( m_VisibleLayers & m_EnabledLayers & 1 << aLayerIndex );
} }
/** /**
* Function SetLayerVisibility * Function SetLayerVisibility
* changes the visibility of a given layer * changes the visibility of a given layer
...@@ -91,6 +98,7 @@ public: ...@@ -91,6 +98,7 @@ public:
return m_VisibleElements; return m_VisibleElements;
} }
/** /**
* Function SetVisibleElements * Function SetVisibleElements
* changes the bit-mask of visible element categories * changes the bit-mask of visible element categories
...@@ -101,6 +109,7 @@ public: ...@@ -101,6 +109,7 @@ public:
m_VisibleElements = aMask; m_VisibleElements = aMask;
} }
/** /**
* Function IsElementVisible * Function IsElementVisible
* tests whether a given element category is visible * tests whether a given element category is visible
...@@ -111,9 +120,10 @@ public: ...@@ -111,9 +120,10 @@ public:
{ {
if( aCategoryIndex < 0 || aCategoryIndex > PAD_CMP_VISIBLE ) if( aCategoryIndex < 0 || aCategoryIndex > PAD_CMP_VISIBLE )
return false; return false;
return (bool)( m_VisibleElements & 1 << aCategoryIndex ); return (bool) ( m_VisibleElements & 1 << aCategoryIndex );
} }
/** /**
* Function SetElementVisibility * Function SetElementVisibility
* changes the visibility of an element category * changes the visibility of an element category
...@@ -132,6 +142,7 @@ public: ...@@ -132,6 +142,7 @@ public:
return m_EnabledLayers; return m_EnabledLayers;
} }
/** /**
* Function SetEnabledLayers * Function SetEnabledLayers
* changes the bit-mask of enabled layers * changes the bit-mask of enabled layers
...@@ -141,10 +152,12 @@ public: ...@@ -141,10 +152,12 @@ public:
{ {
// TODO; ensure consistency with m_CopperLayerCount // TODO; ensure consistency with m_CopperLayerCount
m_EnabledLayers = aMask; m_EnabledLayers = aMask;
// A disabled layer cannot be visible // A disabled layer cannot be visible
m_VisibleLayers &= aMask; m_VisibleLayers &= aMask;
} }
/** /**
* Function IsLayerEnabled * Function IsLayerEnabled
* tests whether a given layer is enabled * tests whether a given layer is enabled
...@@ -153,9 +166,10 @@ public: ...@@ -153,9 +166,10 @@ public:
*/ */
inline bool IsLayerEnabled( int aLayerIndex ) inline bool IsLayerEnabled( int aLayerIndex )
{ {
return (bool)( m_EnabledLayers & 1 << aLayerIndex ); return (bool) ( m_EnabledLayers & 1 << aLayerIndex );
} }
/** /**
* Function GetCopperLayerCount * Function GetCopperLayerCount
* @return int - the number of neabled copper layers * @return int - the number of neabled copper layers
...@@ -165,6 +179,7 @@ public: ...@@ -165,6 +179,7 @@ public:
return m_CopperLayerCount; return m_CopperLayerCount;
} }
/** /**
* Function SetCopperLayerCount * Function SetCopperLayerCount
* do what its name says... * do what its name says...
...@@ -175,4 +190,5 @@ public: ...@@ -175,4 +190,5 @@ public:
#endif #endif
// _BOARD_DESIGN_SETTING_H
// _BOARD_DESIGN_SETTING_H
...@@ -287,9 +287,8 @@ public: ...@@ -287,9 +287,8 @@ public:
GRTraceMode trace_mode ); GRTraceMode trace_mode );
void Genere_DXF( const wxString& FullFileName, int Layer, GRTraceMode trace_mode ); void Genere_DXF( const wxString& FullFileName, int Layer, GRTraceMode trace_mode );
void Plot_Layer( PLOTTER* plotter, int Layer, GRTraceMode trace_mode ); void Plot_Layer( PLOTTER* plotter, int Layer, GRTraceMode trace_mode );
void Plot_Standard_Layer( PLOTTER* plotter, int masque_layer, void Plot_Standard_Layer( PLOTTER* aPlotter, int aLayerMask,
int garde, bool trace_via, bool aPlotVia, GRTraceMode aPlotMode );
GRTraceMode trace_mode );
void Plot_Serigraphie( PLOTTER* plotter, int masque_layer, GRTraceMode trace_mode ); void Plot_Serigraphie( PLOTTER* plotter, int masque_layer, GRTraceMode trace_mode );
/** function PlotDrillMark /** function PlotDrillMark
...@@ -298,7 +297,7 @@ public: ...@@ -298,7 +297,7 @@ public:
* redraw the drill mark on a pad or via, as a negative (i.e. white) shape in FILLED plot mode * redraw the drill mark on a pad or via, as a negative (i.e. white) shape in FILLED plot mode
* @param aPlotter = the PLOTTER * @param aPlotter = the PLOTTER
* @param aTraceMode = the mode of plot (FILLED, SKETCH) * @param aTraceMode = the mode of plot (FILLED, SKETCH)
* @param aSmallDrillShape = true to plot a smalle drill shape, false to plot the actual drill shape * @param aSmallDrillShape = true to plot a small drill shape, false to plot the actual drill shape
*/ */
void PlotDrillMark( PLOTTER* aPlotter, GRTraceMode aTraceMode, bool aSmallDrillShape ); void PlotDrillMark( PLOTTER* aPlotter, GRTraceMode aTraceMode, bool aSmallDrillShape );
......
...@@ -98,8 +98,6 @@ public: ...@@ -98,8 +98,6 @@ public:
void OnCloseWindow( wxCloseEvent& Event ); void OnCloseWindow( wxCloseEvent& Event );
void OnSize( wxSizeEvent& event ); void OnSize( wxSizeEvent& event );
void OnPaint( wxPaintEvent& event );
void ReDraw( wxDC* DC );
void OnSashDrag( wxSashEvent& event ); void OnSashDrag( wxSashEvent& event );
void OnLoadProject( wxCommandEvent& event ); void OnLoadProject( wxCommandEvent& event );
void OnSaveProject( wxCommandEvent& event ); void OnSaveProject( wxCommandEvent& event );
......
...@@ -109,7 +109,7 @@ WinEDA_MainFrame::WinEDA_MainFrame( wxWindow* parent, ...@@ -109,7 +109,7 @@ WinEDA_MainFrame::WinEDA_MainFrame( wxWindow* parent,
RecreateBaseHToolbar(); RecreateBaseHToolbar();
m_auimgr.SetManagedWindow(this); m_auimgr.SetManagedWindow(this);
wxAuiPaneInfo horiz; wxAuiPaneInfo horiz;
horiz.Gripper(false); horiz.Gripper(false);
horiz.DockFixed(true); horiz.DockFixed(true);
...@@ -117,15 +117,15 @@ WinEDA_MainFrame::WinEDA_MainFrame( wxWindow* parent, ...@@ -117,15 +117,15 @@ WinEDA_MainFrame::WinEDA_MainFrame( wxWindow* parent,
horiz.Floatable(false); horiz.Floatable(false);
horiz.CloseButton(false); horiz.CloseButton(false);
horiz.CaptionVisible(false); horiz.CaptionVisible(false);
wxAuiPaneInfo vert(horiz); wxAuiPaneInfo vert(horiz);
vert.TopDockable(false).BottomDockable(false); vert.TopDockable(false).BottomDockable(false);
horiz.LeftDockable(false).RightDockable(false); horiz.LeftDockable(false).RightDockable(false);
m_auimgr.AddPane(m_HToolBar, m_auimgr.AddPane(m_HToolBar,
wxAuiPaneInfo(horiz).Name(wxT("m_HToolBar")).Top()); wxAuiPaneInfo(horiz).Name(wxT("m_HToolBar")).Top());
m_auimgr.AddPane(m_DialogWin, m_auimgr.AddPane(m_DialogWin,
wxAuiPaneInfo(horiz).Name(wxT("m_DialogWin")).Center()); wxAuiPaneInfo(horiz).Name(wxT("m_DialogWin")).Center());
...@@ -281,21 +281,6 @@ void WinEDA_MainFrame::OnCloseWindow( wxCloseEvent& Event ) ...@@ -281,21 +281,6 @@ void WinEDA_MainFrame::OnCloseWindow( wxCloseEvent& Event )
} }
/**********************************************************/
void WinEDA_MainFrame::OnPaint( wxPaintEvent& event )
/**********************************************************/
{
event.Skip();
}
/*******************************************/
void WinEDA_MainFrame::ReDraw( wxDC* DC )
/*******************************************/
{
}
void WinEDA_MainFrame::OnExit( wxCommandEvent& event ) void WinEDA_MainFrame::OnExit( wxCommandEvent& event )
{ {
Close( true ); Close( true );
......
...@@ -35,35 +35,40 @@ EDA_BoardDesignSettings::EDA_BoardDesignSettings() ...@@ -35,35 +35,40 @@ EDA_BoardDesignSettings::EDA_BoardDesignSettings()
LIGHTGRAY LIGHTGRAY
}; };
m_EnabledLayers = ALL_LAYERS; // All layers enabled at first. m_EnabledLayers = ALL_LAYERS; // All layers enabled at first.
// SetCopperLayerCount() will adjust thist. // SetCopperLayerCount() will adjust thist.
m_VisibleLayers = 0xffffffff; // IMB: All layers visible at first. TODO: Use a macro for the initial value. m_VisibleLayers = 0xffffffff; // IMB: All layers visible at first. TODO: Use a macro for the initial value.
m_VisibleElements = 0x00000fff; // IMB: All elements visible at first. TODO: Use a macro for the initial value. m_VisibleElements = 0x00000fff; // IMB: All elements visible at first. TODO: Use a macro for the initial value.
SetCopperLayerCount( 2 ); // Default design is a double sided board SetCopperLayerCount( 2 ); // Default design is a double sided board
m_CurrentViaType = VIA_THROUGH; // via type (VIA_BLIND_BURIED, VIA_THROUGH VIA_MICROVIA) m_CurrentViaType = VIA_THROUGH; // via type (VIA_BLIND_BURIED, VIA_THROUGH VIA_MICROVIA)
m_UseConnectedTrackWidth = false; // if true, when creating a new track starting on an existing track, use this track width m_UseConnectedTrackWidth = false; // if true, when creating a new track starting on an existing track, use this track width
m_MicroViasAllowed = false; // true to allow micro vias m_MicroViasAllowed = false; // true to allow micro vias
m_DrawSegmentWidth = 100; // current graphic line width (not EDGE layer) m_DrawSegmentWidth = 100; // current graphic line width (not EDGE layer)
m_EdgeSegmentWidth = 100; // current graphic line width (EDGE layer only) m_EdgeSegmentWidth = 100; // current graphic line width (EDGE layer only)
m_PcbTextWidth = 100; // current Pcb (not module) Text width m_PcbTextWidth = 100; // current Pcb (not module) Text width
m_PcbTextSize = wxSize( 500, 500 ); // current Pcb (not module) Text size m_PcbTextSize = wxSize( 500, 500 ); // current Pcb (not module) Text size
m_TrackMinWidth = 80; // track min value for width ((min copper size value m_TrackMinWidth = 80; // track min value for width ((min copper size value
m_ViasMinSize = 350; // vias (not micro vias) min diameter m_ViasMinSize = 350; // vias (not micro vias) min diameter
m_ViasMinDrill = 200; // vias (not micro vias) min drill diameter m_ViasMinDrill = 200; // vias (not micro vias) min drill diameter
m_MicroViasMinSize = 200; // micro vias (not vias) min diameter m_MicroViasMinSize = 200; // micro vias (not vias) min diameter
m_MicroViasMinDrill = 50; // micro vias (not vias) min drill diameter m_MicroViasMinDrill = 50; // micro vias (not vias) min drill diameter
m_MaskMargin = 150; // Solder mask margin // Global mask margins:
m_SolderMaskMargin = 150; // Solder mask margin
m_SolderPasteMargin = 0; // Solder paste margin absolute value
m_SolderPasteMarginRatio = 0.0; // Solder pask margin ratio value of pad size
// The final margin is the sum of these 2 values
// Usually < 0 because the mask is smaller than pad
/* Color options for screen display of the Printed Board: */ /* Color options for screen display of the Printed Board: */
for( ii = 0; ii < 32; ii++ ) for( ii = 0; ii < 32; ii++ )
m_LayerColor[ii] = default_layer_color[ii]; m_LayerColor[ii] = default_layer_color[ii];
// Layer colors (tracks and graphic items) // Layer colors (tracks and graphic items)
m_ViaColor[VIA_NOT_DEFINED] = DARKGRAY; m_ViaColor[VIA_NOT_DEFINED] = DARKGRAY;
m_ViaColor[VIA_MICROVIA] = CYAN; m_ViaColor[VIA_MICROVIA] = CYAN;
m_ViaColor[VIA_BLIND_BURIED] = BROWN; m_ViaColor[VIA_BLIND_BURIED] = BROWN;
m_ViaColor[VIA_THROUGH] = WHITE; m_ViaColor[VIA_THROUGH] = WHITE;
m_RatsnestColor = WHITE; // Ratsnest color m_RatsnestColor = WHITE; // Ratsnest color
} }
...@@ -75,22 +80,25 @@ int EDA_BoardDesignSettings::GetVisibleLayers() const ...@@ -75,22 +80,25 @@ int EDA_BoardDesignSettings::GetVisibleLayers() const
return m_VisibleLayers; return m_VisibleLayers;
} }
void EDA_BoardDesignSettings::SetVisibleLayers( int aMask ) void EDA_BoardDesignSettings::SetVisibleLayers( int aMask )
{ {
m_VisibleLayers = aMask & m_EnabledLayers & ALL_LAYERS; m_VisibleLayers = aMask & m_EnabledLayers & ALL_LAYERS;
} }
void EDA_BoardDesignSettings::SetLayerVisibility( int aLayerIndex, bool aNewState ) void EDA_BoardDesignSettings::SetLayerVisibility( int aLayerIndex, bool aNewState )
{ {
// Altough Pcbnew uses only 29, Gerbview uses all 32 layers // Altough Pcbnew uses only 29, Gerbview uses all 32 layers
if( aLayerIndex < 0 || aLayerIndex >= 32 ) if( aLayerIndex < 0 || aLayerIndex >= 32 )
return; return;
if( aNewState && IsLayerEnabled( aLayerIndex )) if( aNewState && IsLayerEnabled( aLayerIndex ) )
m_VisibleLayers |= 1 << aLayerIndex; m_VisibleLayers |= 1 << aLayerIndex;
else else
m_VisibleLayers &= ~( 1 << aLayerIndex ); m_VisibleLayers &= ~( 1 << aLayerIndex );
} }
void EDA_BoardDesignSettings::SetElementVisibility( int aElementCategory, bool aNewState ) void EDA_BoardDesignSettings::SetElementVisibility( int aElementCategory, bool aNewState )
{ {
if( aElementCategory < 0 || aElementCategory > PAD_CMP_VISIBLE ) if( aElementCategory < 0 || aElementCategory > PAD_CMP_VISIBLE )
...@@ -100,6 +108,8 @@ void EDA_BoardDesignSettings::SetElementVisibility( int aElementCategory, bool a ...@@ -100,6 +108,8 @@ void EDA_BoardDesignSettings::SetElementVisibility( int aElementCategory, bool a
else else
m_VisibleElements &= ~( 1 << aElementCategory ); m_VisibleElements &= ~( 1 << aElementCategory );
} }
/** /**
* Function SetCopperLayerCount * Function SetCopperLayerCount
* do what its name says... * do what its name says...
...@@ -108,11 +118,12 @@ void EDA_BoardDesignSettings::SetElementVisibility( int aElementCategory, bool a ...@@ -108,11 +118,12 @@ void EDA_BoardDesignSettings::SetElementVisibility( int aElementCategory, bool a
void EDA_BoardDesignSettings::SetCopperLayerCount( int aNewLayerCount ) void EDA_BoardDesignSettings::SetCopperLayerCount( int aNewLayerCount )
{ {
m_CopperLayerCount = aNewLayerCount; m_CopperLayerCount = aNewLayerCount;
// ensure consistency with the m_EnabledLayers member // ensure consistency with the m_EnabledLayers member
m_EnabledLayers &= ~ALL_CU_LAYERS; m_EnabledLayers &= ~ALL_CU_LAYERS;
m_EnabledLayers |= CUIVRE_LAYER; m_EnabledLayers |= CUIVRE_LAYER;
if ( m_CopperLayerCount > 1 ) if( m_CopperLayerCount > 1 )
m_EnabledLayers |= CMP_LAYER; m_EnabledLayers |= CMP_LAYER;
for( int ii = 1; ii < aNewLayerCount-1; ii++ ) for( int ii = 1; ii < aNewLayerCount - 1; ii++ )
m_EnabledLayers |= 1 << ii; m_EnabledLayers |= 1 << ii;
} }
This diff is collapsed.
...@@ -31,22 +31,22 @@ enum Mod_Attribut /* Attributs used for modules */ ...@@ -31,22 +31,22 @@ enum Mod_Attribut /* Attributs used for modules */
/* flags for autoplace and autoroute (.m_ModuleStatus member) */ /* flags for autoplace and autoroute (.m_ModuleStatus member) */
#define MODULE_is_LOCKED 0x01 /* module LOCKED: no autoplace allowed */ #define MODULE_is_LOCKED 0x01 /* module LOCKED: no autoplace allowed */
#define MODULE_is_PLACED 0x02 /* In autoplace: module automatically placed */ #define MODULE_is_PLACED 0x02 /* In autoplace: module automatically placed */
#define MODULE_to_PLACE 0x04 /* In autoplace: module waiting for autoplace */ #define MODULE_to_PLACE 0x04 /* In autoplace: module waiting for autoplace */
class MODULE : public BOARD_ITEM class MODULE : public BOARD_ITEM
{ {
public: public:
wxPoint m_Pos; // Real coord on board wxPoint m_Pos; // Real coord on board
DLIST<D_PAD> m_Pads; /* Pad list (linked list) */ DLIST<D_PAD> m_Pads; /* Pad list (linked list) */
DLIST<BOARD_ITEM> m_Drawings; /* Graphic items list (linked list) */ DLIST<BOARD_ITEM> m_Drawings; /* Graphic items list (linked list) */
DLIST<S3D_MASTER> m_3D_Drawings; /* First item of the 3D shapes (linked list)*/ DLIST<S3D_MASTER> m_3D_Drawings; /* First item of the 3D shapes (linked list)*/
TEXTE_MODULE* m_Reference; // Component reference (U34, R18..) TEXTE_MODULE* m_Reference; // Component reference (U34, R18..)
TEXTE_MODULE* m_Value; // Component value (74LS00, 22K..) TEXTE_MODULE* m_Value; // Component value (74LS00, 22K..)
wxString m_LibRef; /* Name of the module in library (and the default value when loading amodule from the library) */ wxString m_LibRef; /* Name of the module in library (and the default value when loading amodule from the library) */
wxString m_AlternateReference; /* Used when m_Reference cannot be used to wxString m_AlternateReference; /* Used when m_Reference cannot be used to
* identify the footprint ( after a full reannotation of the schematic */ * identify the footprint ( after a full reannotation of the schematic */
int m_Attributs; /* Flags(ORed bits) ( see Mod_Attribut ) */ int m_Attributs; /* Flags(ORed bits) ( see Mod_Attribut ) */
int m_Orient; /* orientation in 0.1 degrees */ int m_Orient; /* orientation in 0.1 degrees */
...@@ -69,15 +69,24 @@ public: ...@@ -69,15 +69,24 @@ public:
wxString m_Doc; // Module Description (info for users) wxString m_Doc; // Module Description (info for users)
wxString m_KeyWord; // Keywords to select the module in lib wxString m_KeyWord; // Keywords to select the module in lib
// Local clearance. When null, the netclasses values are used. Usually the local clearance is null
int m_LocalClearance;
// Local mask margins: when NULL, the global design values are used
int m_LocalSolderMaskMargin; // Local solder mask margin
int m_LocalSolderPasteMargin; // Local solder paste margin absolute value
double m_LocalSolderPasteMarginRatio; // Local solder pask margin ratio value of pad size
// The final margin is the sum of these 2 values
public: public:
MODULE( BOARD* parent ); MODULE( BOARD* parent );
MODULE( MODULE* module ); MODULE( MODULE* module );
~MODULE(); ~MODULE();
MODULE* Next() const { return (MODULE*) Pnext; } MODULE* Next() const { return (MODULE*) Pnext; }
MODULE* Back() const { return (MODULE*) Pback; } MODULE* Back() const { return (MODULE*) Pback; }
void Copy( MODULE* Module ); // Copy structure void Copy( MODULE* Module ); // Copy structure
/** /**
...@@ -85,7 +94,7 @@ public: ...@@ -85,7 +94,7 @@ public:
* adds the given item to this MODULE and takes ownership of its memory. * adds the given item to this MODULE and takes ownership of its memory.
* @param aBoardItem The item to add to this board. * @param aBoardItem The item to add to this board.
* @param doInsert If true, then insert, else append * @param doInsert If true, then insert, else append
void Add( BOARD_ITEM* aBoardItem, bool doInsert = true ); * void Add( BOARD_ITEM* aBoardItem, bool doInsert = true );
*/ */
...@@ -93,13 +102,13 @@ public: ...@@ -93,13 +102,13 @@ public:
* Function Set_Rectangle_Encadrement() * Function Set_Rectangle_Encadrement()
* calculates the bounding box for orient 0 et origin = module anchor) * calculates the bounding box for orient 0 et origin = module anchor)
*/ */
void Set_Rectangle_Encadrement(); void Set_Rectangle_Encadrement();
/** function SetRectangleExinscrit() /** function SetRectangleExinscrit()
* Calculates the real bounding box accordint to theboard position, and real orientaion * Calculates the real bounding box accordint to theboard position, and real orientaion
* and also calculates the area value (used in automatic placement) * and also calculates the area value (used in automatic placement)
*/ */
void SetRectangleExinscrit(); void SetRectangleExinscrit();
/** /**
* Function GetBoundingBox * Function GetBoundingBox
...@@ -121,14 +130,15 @@ public: ...@@ -121,14 +130,15 @@ public:
// Moves // Moves
void SetPosition( const wxPoint& newpos ); void SetPosition( const wxPoint& newpos );
void SetOrientation( int newangle ); void SetOrientation( int newangle );
/** /**
* Function Move * Function Move
* move this object. * move this object.
* @param const wxPoint& aMoveVector - the move vector for this object. * @param const wxPoint& aMoveVector - the move vector for this object.
*/ */
virtual void Move(const wxPoint& aMoveVector); virtual void Move( const wxPoint& aMoveVector );
/** /**
* Function Rotate * Function Rotate
...@@ -136,14 +146,14 @@ public: ...@@ -136,14 +146,14 @@ public:
* @param const wxPoint& aRotCentre - the rotation point. * @param const wxPoint& aRotCentre - the rotation point.
* @param aAngle - the rotation angle in 0.1 degree. * @param aAngle - the rotation angle in 0.1 degree.
*/ */
virtual void Rotate(const wxPoint& aRotCentre, int aAngle); virtual void Rotate( const wxPoint& aRotCentre, int aAngle );
/** /**
* Function Flip * Function Flip
* Flip this object, i.e. change the board side for this object * Flip this object, i.e. change the board side for this object
* @param const wxPoint& aCentre - the rotation point. * @param const wxPoint& aCentre - the rotation point.
*/ */
virtual void Flip(const wxPoint& aCentre ); virtual void Flip( const wxPoint& aCentre );
/** /**
* Function IsLocked * Function IsLocked
...@@ -178,10 +188,10 @@ public: ...@@ -178,10 +188,10 @@ public:
* @param aFile The FILE to write to. * @param aFile The FILE to write to.
* @return bool - true if success writing else false. * @return bool - true if success writing else false.
*/ */
bool Save( FILE* aFile ) const; bool Save( FILE* aFile ) const;
int Write_3D_Descr( FILE* File ) const; int Write_3D_Descr( FILE* File ) const;
int ReadDescr( FILE* File, int* LineNum = NULL ); int ReadDescr( FILE* File, int* LineNum = NULL );
/** /**
* Function Read_GPCB_Descr * Function Read_GPCB_Descr
...@@ -190,10 +200,11 @@ public: ...@@ -190,10 +200,11 @@ public:
* this is also the footprint name * this is also the footprint name
* @return bool - true if success reading else false. * @return bool - true if success reading else false.
*/ */
bool Read_GPCB_Descr(const wxString & CmpFullFileName); bool Read_GPCB_Descr( const wxString& CmpFullFileName );
int Read_3D_Descr( FILE* File, int* LineNum = NULL ); int Read_3D_Descr( FILE* File, int* LineNum = NULL );
/* drawing functions */ /* drawing functions */
/** Function Draw /** Function Draw
* Draw the text accordint to the footprint pos and orient * Draw the text accordint to the footprint pos and orient
* @param panel = draw panel, Used to know the clip box * @param panel = draw panel, Used to know the clip box
...@@ -201,13 +212,16 @@ public: ...@@ -201,13 +212,16 @@ public:
* @param offset = draw offset (usually wxPoint(0,0) * @param offset = draw offset (usually wxPoint(0,0)
* @param aDrawMode = GR_OR, GR_XOR.. * @param aDrawMode = GR_OR, GR_XOR..
*/ */
void Draw( WinEDA_DrawPanel* panel, wxDC* DC, int aDrawMode, const wxPoint& offset = ZeroOffset ); void Draw( WinEDA_DrawPanel* panel,
wxDC* DC,
int aDrawMode,
const wxPoint& offset = ZeroOffset );
void Draw3D( Pcb3D_GLCanvas* glcanvas ); void Draw3D( Pcb3D_GLCanvas* glcanvas );
void DrawEdgesOnly( WinEDA_DrawPanel* panel, wxDC* DC, void DrawEdgesOnly( WinEDA_DrawPanel* panel, wxDC* DC,
const wxPoint& offset, int draw_mode ); const wxPoint& offset, int draw_mode );
void DrawAncre( WinEDA_DrawPanel* panel, wxDC* DC, void DrawAncre( WinEDA_DrawPanel* panel, wxDC* DC,
const wxPoint& offset, int dim_ancre, int draw_mode ); const wxPoint& offset, int dim_ancre, int draw_mode );
/** /**
* Function DisplayInfo * Function DisplayInfo
...@@ -215,7 +229,7 @@ public: ...@@ -215,7 +229,7 @@ public:
* about this object into the frame's message panel. * about this object into the frame's message panel.
* @param frame A WinEDA_DrawFrame in which to print status information. * @param frame A WinEDA_DrawFrame in which to print status information.
*/ */
void DisplayInfo( WinEDA_DrawFrame* frame ); void DisplayInfo( WinEDA_DrawFrame* frame );
/** /**
...@@ -224,7 +238,7 @@ public: ...@@ -224,7 +238,7 @@ public:
* @param refPos A wxPoint to test * @param refPos A wxPoint to test
* @return bool - true if a hit, else false * @return bool - true if a hit, else false
*/ */
bool HitTest( const wxPoint& refPos ); bool HitTest( const wxPoint& refPos );
/** /**
...@@ -233,7 +247,7 @@ public: ...@@ -233,7 +247,7 @@ public:
* @param refArea : the given EDA_Rect * @param refArea : the given EDA_Rect
* @return bool - true if a hit, else false * @return bool - true if a hit, else false
*/ */
bool HitTest( EDA_Rect& refArea ); bool HitTest( EDA_Rect& refArea );
/** /**
* Function GetReference * Function GetReference
...@@ -244,6 +258,7 @@ public: ...@@ -244,6 +258,7 @@ public:
return m_Reference->m_Text; return m_Reference->m_Text;
} }
/** /**
* Function GetValue * Function GetValue
* @return const wxString& - the value text. * @return const wxString& - the value text.
...@@ -261,7 +276,7 @@ public: ...@@ -261,7 +276,7 @@ public:
* @param * @param
* @return D_PAD* - The first matching name is returned, or NULL if not found. * @return D_PAD* - The first matching name is returned, or NULL if not found.
*/ */
D_PAD* FindPadByName( const wxString& aPadName ) const; D_PAD* FindPadByName( const wxString& aPadName ) const;
/** /**
...@@ -292,7 +307,7 @@ public: ...@@ -292,7 +307,7 @@ public:
} }
#if defined (DEBUG) #if defined(DEBUG)
/** /**
* Function Show * Function Show
......
This diff is collapsed.
...@@ -9,8 +9,10 @@ class Pcb3D_GLCanvas; ...@@ -9,8 +9,10 @@ class Pcb3D_GLCanvas;
/* Default layers used for pads, accordint to the pad type. /* Default layers used for pads, accordint to the pad type.
* this is default values only, they can be changed for a given pad * this is default values only, they can be changed for a given pad
*/ */
// PAD_STANDARD: // PAD_STANDARD:
#define PAD_STANDARD_DEFAULT_LAYERS ALL_CU_LAYERS | SILKSCREEN_LAYER_CMP | SOLDERMASK_LAYER_CU | SOLDERMASK_LAYER_CMP #define PAD_STANDARD_DEFAULT_LAYERS ALL_CU_LAYERS | SILKSCREEN_LAYER_CMP | SOLDERMASK_LAYER_CU | \
SOLDERMASK_LAYER_CMP
// PAD_CONN: // PAD_CONN:
#define PAD_CONN_DEFAULT_LAYERS CMP_LAYER | SOLDERPASTE_LAYER_CMP | SOLDERMASK_LAYER_CMP #define PAD_CONN_DEFAULT_LAYERS CMP_LAYER | SOLDERPASTE_LAYER_CMP | SOLDERMASK_LAYER_CMP
...@@ -19,7 +21,8 @@ class Pcb3D_GLCanvas; ...@@ -19,7 +21,8 @@ class Pcb3D_GLCanvas;
#define PAD_SMD_DEFAULT_LAYERS CMP_LAYER | SOLDERMASK_LAYER_CMP #define PAD_SMD_DEFAULT_LAYERS CMP_LAYER | SOLDERMASK_LAYER_CMP
//PAD_HOLE_NOT_PLATED: //PAD_HOLE_NOT_PLATED:
#define PAD_HOLE_NOT_PLATED_DEFAULT_LAYERS CUIVRE_LAYER | SILKSCREEN_LAYER_CMP | SOLDERMASK_LAYER_CU | SOLDERMASK_LAYER_CMP #define PAD_HOLE_NOT_PLATED_DEFAULT_LAYERS CUIVRE_LAYER | SILKSCREEN_LAYER_CMP | \
SOLDERMASK_LAYER_CU | SOLDERMASK_LAYER_CMP
/* Definition type Structure d'un pad */ /* Definition type Structure d'un pad */
...@@ -74,8 +77,19 @@ public: ...@@ -74,8 +77,19 @@ public:
int m_Attribut; // NORMAL, PAD_SMD, PAD_CONN int m_Attribut; // NORMAL, PAD_SMD, PAD_CONN
int m_Orient; // in 1/10 degrees int m_Orient; // in 1/10 degrees
// Local clearance. When null, the module default value is used.
// when the module default value is null, the netclass value is used
// Usually the local clearance is null
int m_LocalClearance;
// Local mask margins: when NULL, the parent footprint design values are used
int m_LocalSolderMaskMargin; // Local solder mask margin
int m_LocalSolderPasteMargin; // Local solder paste margin absolute value
double m_LocalSolderPasteMarginRatio; // Local solder pask margin ratio value of pad size
// The final margin is the sum of these 2 values
private: private:
int m_SubRatsnest; // variable used in rats nest computations int m_SubRatsnest; // variable used in rats nest computations
// handle subnet (block) number in ratsnet connection // handle subnet (block) number in ratsnet connection
public: public:
...@@ -129,6 +143,29 @@ public: ...@@ -129,6 +143,29 @@ public:
} }
// Mask margins handling:
/** Function GetSolderMaskMargin
* @return the margin for the solder mask layer
* usually > 0 (mask shape bigger than pad
* value is
* 1 - the local value
* 2 - if null, the parent footprint value
* 1 - if null, the global value
*/
int GetSolderMaskMargin();
/** Function GetSolderPasteMargin
* @return the margin for the solder mask layer
* usually < 0 (mask shape smaller than pad
* because the margin can be dependant on the pad size, the margin has a x and a y value
* value is
* 1 - the local value
* 2 - if null, the parent footprint value
* 1 - if null, the global value
*/
wxSize GetSolderPasteMargin();
/* Reading and writing data on files */ /* Reading and writing data on files */
int ReadDescr( FILE* File, int* LineNum = NULL ); int ReadDescr( FILE* File, int* LineNum = NULL );
...@@ -222,11 +259,12 @@ public: ...@@ -222,11 +259,12 @@ public:
* move this object. * move this object.
* @param const wxPoint& aMoveVector - the move vector for this object. * @param const wxPoint& aMoveVector - the move vector for this object.
*/ */
virtual void Move(const wxPoint& aMoveVector) virtual void Move( const wxPoint& aMoveVector )
{ {
m_Pos += aMoveVector; m_Pos += aMoveVector;
} }
#if defined(DEBUG) #if defined(DEBUG)
/** /**
......
...@@ -16,7 +16,7 @@ ...@@ -16,7 +16,7 @@
/*******************************************************************************************/ /*******************************************************************************************/
void D_PAD::Draw( WinEDA_DrawPanel* panel, wxDC* DC, int draw_mode, void D_PAD::Draw( WinEDA_DrawPanel* panel, wxDC* DC, int draw_mode,
const wxPoint& offset ) const wxPoint& offset )
/*******************************************************************************************/ /*******************************************************************************************/
/** Draw a pad: /** Draw a pad:
...@@ -36,7 +36,7 @@ void D_PAD::Draw( WinEDA_DrawPanel* panel, wxDC* DC, int draw_mode, ...@@ -36,7 +36,7 @@ void D_PAD::Draw( WinEDA_DrawPanel* panel, wxDC* DC, int draw_mode,
wxPoint coord[4]; wxPoint coord[4];
int fillpad = 0; int fillpad = 0;
wxPoint shape_pos; wxPoint shape_pos;
int mask_margin = 0; // margin (clearance) used for some non copper layers wxSize mask_margin; // margin (clearance) used for some non copper layers
if( m_Flags & DO_NOT_DRAW ) if( m_Flags & DO_NOT_DRAW )
return; return;
...@@ -166,19 +166,25 @@ void D_PAD::Draw( WinEDA_DrawPanel* panel, wxDC* DC, int draw_mode, ...@@ -166,19 +166,25 @@ void D_PAD::Draw( WinEDA_DrawPanel* panel, wxDC* DC, int draw_mode,
} }
// if Contrast mode is ON and a technical layer active, show pads on this layer // if Contrast mode is ON and a technical layer active, show pads on this layer
// so we can see pads on paste or solder layer // so we can see pads on paste or solder layer and the size of the mask
if( DisplayOpt.ContrastModeDisplay && screen->m_Active_Layer > LAST_COPPER_LAYER ) if( DisplayOpt.ContrastModeDisplay && screen->m_Active_Layer > LAST_COPPER_LAYER )
{ {
if( IsOnLayer( screen->m_Active_Layer ) ) if( IsOnLayer( screen->m_Active_Layer ) )
{ {
color = g_DesignSettings.m_LayerColor[screen->m_Active_Layer]; color = g_DesignSettings.m_LayerColor[screen->m_Active_Layer];
// In hight contrast mode, and if the active layer is the mask layer // In hight contrast mode, and if the active layer is the mask layer
// shows the pad size with the mask clearance // shows the pad size with the mask clearance
switch( screen->m_Active_Layer ) switch( screen->m_Active_Layer )
{ {
case SOLDERMASK_N_CU: case SOLDERMASK_N_CU:
case SOLDERMASK_N_CMP: case SOLDERMASK_N_CMP:
mask_margin = g_DesignSettings.m_MaskMargin; mask_margin.x = mask_margin.y = GetSolderMaskMargin();
break;
case SOLDERPASTE_N_CU:
case SOLDERPASTE_N_CMP:
mask_margin = GetSolderPasteMargin();
break; break;
default: default:
...@@ -232,9 +238,9 @@ void D_PAD::Draw( WinEDA_DrawPanel* panel, wxDC* DC, int draw_mode, ...@@ -232,9 +238,9 @@ void D_PAD::Draw( WinEDA_DrawPanel* panel, wxDC* DC, int draw_mode,
{ {
case PAD_CIRCLE: case PAD_CIRCLE:
if( fillpad ) if( fillpad )
GRFilledCircle( &panel->m_ClipBox, DC, xc, yc, dx + mask_margin, 0, color, color ); GRFilledCircle( &panel->m_ClipBox, DC, xc, yc, dx + mask_margin.x, 0, color, color );
else else
GRCircle( &panel->m_ClipBox, DC, xc, yc, dx + mask_margin, 0, color ); GRCircle( &panel->m_ClipBox, DC, xc, yc, dx + mask_margin.x, 0, color );
if( DisplayIsol ) if( DisplayIsol )
{ {
...@@ -254,13 +260,13 @@ void D_PAD::Draw( WinEDA_DrawPanel* panel, wxDC* DC, int draw_mode, ...@@ -254,13 +260,13 @@ void D_PAD::Draw( WinEDA_DrawPanel* panel, wxDC* DC, int draw_mode,
{ {
delta_cx = dx - dy; delta_cx = dx - dy;
delta_cy = 0; delta_cy = 0;
rotdx = m_Size.y; rotdx = m_Size.y + (mask_margin.y*2);
} }
else /* ellipse verticale */ else /* ellipse verticale */
{ {
delta_cx = 0; delta_cx = 0;
delta_cy = dy - dx; delta_cy = dy - dx;
rotdx = m_Size.x; rotdx = m_Size.x + (mask_margin.x*2);
} }
RotatePoint( &delta_cx, &delta_cy, angle ); RotatePoint( &delta_cx, &delta_cy, angle );
...@@ -269,14 +275,14 @@ void D_PAD::Draw( WinEDA_DrawPanel* panel, wxDC* DC, int draw_mode, ...@@ -269,14 +275,14 @@ void D_PAD::Draw( WinEDA_DrawPanel* panel, wxDC* DC, int draw_mode,
GRFillCSegm( &panel->m_ClipBox, DC, GRFillCSegm( &panel->m_ClipBox, DC,
ux0 + delta_cx, uy0 + delta_cy, ux0 + delta_cx, uy0 + delta_cy,
ux0 - delta_cx, uy0 - delta_cy, ux0 - delta_cx, uy0 - delta_cy,
rotdx + mask_margin, color ); rotdx, color );
} }
else else
{ {
GRCSegm( &panel->m_ClipBox, DC, GRCSegm( &panel->m_ClipBox, DC,
ux0 + delta_cx, uy0 + delta_cy, ux0 + delta_cx, uy0 + delta_cy,
ux0 - delta_cx, uy0 - delta_cy, ux0 - delta_cx, uy0 - delta_cy,
rotdx + mask_margin, color ); rotdx, color );
} }
/* Trace de la marge d'isolement */ /* Trace de la marge d'isolement */
...@@ -297,17 +303,17 @@ void D_PAD::Draw( WinEDA_DrawPanel* panel, wxDC* DC, int draw_mode, ...@@ -297,17 +303,17 @@ void D_PAD::Draw( WinEDA_DrawPanel* panel, wxDC* DC, int draw_mode,
ddx = (m_DeltaSize.x >> 1); ddx = (m_DeltaSize.x >> 1);
ddy = (m_DeltaSize.y >> 1); /* demi dim dx et dy */ ddy = (m_DeltaSize.y >> 1); /* demi dim dx et dy */
coord[0].x = -dx - ddy - mask_margin; coord[0].x = -dx - ddy - mask_margin.x;
coord[0].y = +dy + ddx + mask_margin; coord[0].y = +dy + ddx + mask_margin.y;
coord[1].x = -dx + ddy - mask_margin; coord[1].x = -dx + ddy - mask_margin.x;
coord[1].y = -dy - ddx - mask_margin; coord[1].y = -dy - ddx - mask_margin.y;
coord[2].x = +dx - ddy + mask_margin; coord[2].x = +dx - ddy + mask_margin.x;
coord[2].y = -dy + ddx - mask_margin; coord[2].y = -dy + ddx - mask_margin.y;
coord[3].x = +dx + ddy + mask_margin; coord[3].x = +dx + ddy + mask_margin.x;
coord[3].y = +dy - ddx + mask_margin; coord[3].y = +dy - ddx + mask_margin.y;
for( ii = 0; ii < 4; ii++ ) for( ii = 0; ii < 4; ii++ )
{ {
...@@ -320,8 +326,8 @@ void D_PAD::Draw( WinEDA_DrawPanel* panel, wxDC* DC, int draw_mode, ...@@ -320,8 +326,8 @@ void D_PAD::Draw( WinEDA_DrawPanel* panel, wxDC* DC, int draw_mode,
if( DisplayIsol ) if( DisplayIsol )
{ {
dx += padClearance - mask_margin; dx += padClearance;
dy += padClearance - mask_margin; dy += padClearance;
coord[0].x = -dx - ddy; coord[0].x = -dx - ddy;
coord[0].y = dy + ddx; coord[0].y = dy + ddx;
......
...@@ -98,13 +98,10 @@ DIALOG_MODULE_BOARD_EDITOR_BASE::DIALOG_MODULE_BOARD_EDITOR_BASE( wxWindow* pare ...@@ -98,13 +98,10 @@ DIALOG_MODULE_BOARD_EDITOR_BASE::DIALOG_MODULE_BOARD_EDITOR_BASE( wxWindow* pare
m_buttonModuleEditor = new wxButton( m_PanelProperties, ID_GOTO_MODULE_EDITOR, _("Module Editor"), wxDefaultPosition, wxDefaultSize, 0 ); m_buttonModuleEditor = new wxButton( m_PanelProperties, ID_GOTO_MODULE_EDITOR, _("Module Editor"), wxDefaultPosition, wxDefaultSize, 0 );
m_PropRightSizer->Add( m_buttonModuleEditor, 0, wxALL|wxALIGN_CENTER_HORIZONTAL|wxEXPAND, 5 ); m_PropRightSizer->Add( m_buttonModuleEditor, 0, wxALL|wxALIGN_CENTER_HORIZONTAL|wxEXPAND, 5 );
m_PropRightSizer->Add( 0, 20, 0, 0, 5 );
wxString m_AttributsCtrlChoices[] = { _("Normal"), _("Normal+Insert"), _("Virtual") }; wxString m_AttributsCtrlChoices[] = { _("Normal"), _("Normal+Insert"), _("Virtual") };
int m_AttributsCtrlNChoices = sizeof( m_AttributsCtrlChoices ) / sizeof( wxString ); int m_AttributsCtrlNChoices = sizeof( m_AttributsCtrlChoices ) / sizeof( wxString );
m_AttributsCtrl = new wxRadioBox( m_PanelProperties, wxID_ANY, _("Attributs:"), wxDefaultPosition, wxDefaultSize, m_AttributsCtrlNChoices, m_AttributsCtrlChoices, 1, wxRA_SPECIFY_COLS ); m_AttributsCtrl = new wxRadioBox( m_PanelProperties, wxID_ANY, _("Attributs:"), wxDefaultPosition, wxDefaultSize, m_AttributsCtrlNChoices, m_AttributsCtrlChoices, 1, wxRA_SPECIFY_COLS );
m_AttributsCtrl->SetSelection( 0 ); m_AttributsCtrl->SetSelection( 1 );
m_PropRightSizer->Add( m_AttributsCtrl, 0, wxALL|wxEXPAND, 5 ); m_PropRightSizer->Add( m_AttributsCtrl, 0, wxALL|wxEXPAND, 5 );
wxString m_AutoPlaceCtrlChoices[] = { _("Free"), _("Locked") }; wxString m_AutoPlaceCtrlChoices[] = { _("Free"), _("Locked") };
...@@ -114,24 +111,91 @@ DIALOG_MODULE_BOARD_EDITOR_BASE::DIALOG_MODULE_BOARD_EDITOR_BASE( wxWindow* pare ...@@ -114,24 +111,91 @@ DIALOG_MODULE_BOARD_EDITOR_BASE::DIALOG_MODULE_BOARD_EDITOR_BASE( wxWindow* pare
m_PropRightSizer->Add( m_AutoPlaceCtrl, 0, wxALL|wxEXPAND, 5 ); m_PropRightSizer->Add( m_AutoPlaceCtrl, 0, wxALL|wxEXPAND, 5 );
wxStaticBoxSizer* sbSizerAutoplace; wxStaticBoxSizer* sbSizerAutoplace;
sbSizerAutoplace = new wxStaticBoxSizer( new wxStaticBox( m_PanelProperties, wxID_ANY, _("Auto Move and Place") ), wxVERTICAL ); sbSizerAutoplace = new wxStaticBoxSizer( new wxStaticBox( m_PanelProperties, wxID_ANY, _("Auto Move and Place") ), wxHORIZONTAL );
wxBoxSizer* bSizerRotOpt;
bSizerRotOpt = new wxBoxSizer( wxVERTICAL );
m_staticText11 = new wxStaticText( m_PanelProperties, wxID_ANY, _("Rotation 90 degree"), wxDefaultPosition, wxDefaultSize, 0 ); m_staticText11 = new wxStaticText( m_PanelProperties, wxID_ANY, _("Rotation 90 degree"), wxDefaultPosition, wxDefaultSize, 0 );
m_staticText11->Wrap( -1 ); m_staticText11->Wrap( -1 );
sbSizerAutoplace->Add( m_staticText11, 0, wxTOP|wxRIGHT|wxLEFT, 5 ); bSizerRotOpt->Add( m_staticText11, 0, wxTOP|wxRIGHT|wxLEFT, 5 );
m_CostRot90Ctrl = new wxSlider( m_PanelProperties, wxID_ANY, 0, 0, 10, wxDefaultPosition, wxDefaultSize, wxSL_AUTOTICKS|wxSL_HORIZONTAL|wxSL_LABELS ); m_CostRot90Ctrl = new wxSlider( m_PanelProperties, wxID_ANY, 0, 0, 10, wxDefaultPosition, wxDefaultSize, wxSL_AUTOTICKS|wxSL_HORIZONTAL|wxSL_LABELS );
sbSizerAutoplace->Add( m_CostRot90Ctrl, 0, wxBOTTOM|wxRIGHT|wxLEFT, 5 ); bSizerRotOpt->Add( m_CostRot90Ctrl, 0, wxBOTTOM|wxRIGHT|wxLEFT, 5 );
sbSizerAutoplace->Add( bSizerRotOpt, 1, wxEXPAND, 5 );
wxBoxSizer* bSizerMoveOpt;
bSizerMoveOpt = new wxBoxSizer( wxVERTICAL );
m_staticText12 = new wxStaticText( m_PanelProperties, wxID_ANY, _("Rotation 180 degree"), wxDefaultPosition, wxDefaultSize, 0 ); m_staticText12 = new wxStaticText( m_PanelProperties, wxID_ANY, _("Rotation 180 degree"), wxDefaultPosition, wxDefaultSize, 0 );
m_staticText12->Wrap( -1 ); m_staticText12->Wrap( -1 );
sbSizerAutoplace->Add( m_staticText12, 0, wxTOP|wxRIGHT|wxLEFT, 5 ); bSizerMoveOpt->Add( m_staticText12, 0, wxTOP|wxRIGHT|wxLEFT, 5 );
m_CostRot180Ctrl = new wxSlider( m_PanelProperties, wxID_ANY, 0, 0, 10, wxDefaultPosition, wxDefaultSize, wxSL_AUTOTICKS|wxSL_HORIZONTAL|wxSL_LABELS ); m_CostRot180Ctrl = new wxSlider( m_PanelProperties, wxID_ANY, 0, 0, 10, wxDefaultPosition, wxDefaultSize, wxSL_AUTOTICKS|wxSL_HORIZONTAL|wxSL_LABELS );
sbSizerAutoplace->Add( m_CostRot180Ctrl, 0, wxBOTTOM|wxRIGHT|wxLEFT, 5 ); bSizerMoveOpt->Add( m_CostRot180Ctrl, 0, wxBOTTOM|wxRIGHT|wxLEFT, 5 );
sbSizerAutoplace->Add( bSizerMoveOpt, 1, wxEXPAND, 5 );
m_PropRightSizer->Add( sbSizerAutoplace, 1, wxEXPAND, 5 ); m_PropRightSizer->Add( sbSizerAutoplace, 1, wxEXPAND, 5 );
wxStaticBoxSizer* sbSizerLocalProperties;
sbSizerLocalProperties = new wxStaticBoxSizer( new wxStaticBox( m_PanelProperties, wxID_ANY, _("Masks clearances local values:") ), wxVERTICAL );
m_staticTextInfo = new wxStaticText( m_PanelProperties, wxID_ANY, _("Set these values to 0 to use global values"), wxDefaultPosition, wxDefaultSize, 0 );
m_staticTextInfo->Wrap( -1 );
m_staticTextInfo->SetFont( wxFont( wxNORMAL_FONT->GetPointSize(), 70, 90, 92, false, wxEmptyString ) );
sbSizerLocalProperties->Add( m_staticTextInfo, 0, wxALL|wxALIGN_RIGHT, 5 );
wxFlexGridSizer* fgSizerClearances;
fgSizerClearances = new wxFlexGridSizer( 3, 3, 0, 0 );
fgSizerClearances->SetFlexibleDirection( wxBOTH );
fgSizerClearances->SetNonFlexibleGrowMode( wxFLEX_GROWMODE_SPECIFIED );
m_MaskClearanceTitle = new wxStaticText( m_PanelProperties, wxID_ANY, _("Solder mask clearance:"), wxDefaultPosition, wxDefaultSize, 0 );
m_MaskClearanceTitle->Wrap( -1 );
fgSizerClearances->Add( m_MaskClearanceTitle, 0, wxALL|wxALIGN_RIGHT|wxALIGN_CENTER_VERTICAL, 5 );
m_SolderMaskMarginCtrl = new wxTextCtrl( m_PanelProperties, wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 );
m_SolderMaskMarginCtrl->SetToolTip( _("This is the global clearance between pads and the solder mask\nThis value can be superseded by a pad local value.") );
fgSizerClearances->Add( m_SolderMaskMarginCtrl, 0, wxALL|wxALIGN_CENTER_VERTICAL, 5 );
m_SolderMaskMarginUnits = new wxStaticText( m_PanelProperties, wxID_ANY, _("Inch"), wxDefaultPosition, wxDefaultSize, 0 );
m_SolderMaskMarginUnits->Wrap( -1 );
fgSizerClearances->Add( m_SolderMaskMarginUnits, 0, wxALL|wxALIGN_CENTER_VERTICAL, 5 );
m_staticTextSolderPaste = new wxStaticText( m_PanelProperties, wxID_ANY, _("Solder paste clearance:"), wxDefaultPosition, wxDefaultSize, 0 );
m_staticTextSolderPaste->Wrap( -1 );
fgSizerClearances->Add( m_staticTextSolderPaste, 0, wxALIGN_RIGHT|wxALIGN_CENTER_VERTICAL|wxTOP|wxRIGHT|wxLEFT, 5 );
m_SolderPasteMarginCtrl = new wxTextCtrl( m_PanelProperties, wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 );
m_SolderPasteMarginCtrl->SetToolTip( _("This is the global clearance between pads and the solder paste\nThis value can be superseded by a pad local values.\nThe final clearance value is the sum of this value and the clearance value ratio\nA negative value means a smaller mask size than pad size") );
fgSizerClearances->Add( m_SolderPasteMarginCtrl, 0, wxTOP|wxRIGHT|wxLEFT, 5 );
m_SolderPasteMarginUnits = new wxStaticText( m_PanelProperties, wxID_ANY, _("Inch"), wxDefaultPosition, wxDefaultSize, 0 );
m_SolderPasteMarginUnits->Wrap( -1 );
fgSizerClearances->Add( m_SolderPasteMarginUnits, 0, wxALIGN_CENTER_VERTICAL|wxTOP|wxRIGHT|wxLEFT, 5 );
m_staticTextRatio = new wxStaticText( m_PanelProperties, wxID_ANY, _("Solder mask ratio clearance:"), wxDefaultPosition, wxDefaultSize, 0 );
m_staticTextRatio->Wrap( -1 );
fgSizerClearances->Add( m_staticTextRatio, 0, wxALL|wxALIGN_RIGHT|wxALIGN_CENTER_VERTICAL, 5 );
m_SolderPasteMarginRatioCtrl = new wxTextCtrl( m_PanelProperties, wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 );
m_SolderPasteMarginRatioCtrl->SetToolTip( _("This is the global clearance ratio in per cent between pads and the solder paste\nA value of 10 means the clearance value is 10% of the pad size\nThis value can be superseded by a pad local value.\nThe final clearance value is the sum of this value and the clearance value\nA negative value means a smaller mask size than pad size") );
fgSizerClearances->Add( m_SolderPasteMarginRatioCtrl, 0, wxALIGN_CENTER_VERTICAL|wxALL, 5 );
m_SolderPasteRatioMarginUnits = new wxStaticText( m_PanelProperties, wxID_ANY, _("%"), wxDefaultPosition, wxDefaultSize, 0 );
m_SolderPasteRatioMarginUnits->Wrap( -1 );
fgSizerClearances->Add( m_SolderPasteRatioMarginUnits, 0, wxALL|wxALIGN_CENTER_VERTICAL, 5 );
sbSizerLocalProperties->Add( fgSizerClearances, 1, wxEXPAND, 5 );
m_PropRightSizer->Add( sbSizerLocalProperties, 0, wxEXPAND, 5 );
m_PanelPropertiesBoxSizer->Add( m_PropRightSizer, 0, 0, 5 ); m_PanelPropertiesBoxSizer->Add( m_PropRightSizer, 0, 0, 5 );
m_PanelProperties->SetSizer( m_PanelPropertiesBoxSizer ); m_PanelProperties->SetSizer( m_PanelPropertiesBoxSizer );
......
This source diff could not be displayed because it is too large. You can view the blob instead.
...@@ -66,13 +66,22 @@ class DIALOG_MODULE_BOARD_EDITOR_BASE : public wxDialog ...@@ -66,13 +66,22 @@ class DIALOG_MODULE_BOARD_EDITOR_BASE : public wxDialog
wxTextCtrl* m_ModPositionY; wxTextCtrl* m_ModPositionY;
wxButton* m_buttonExchange; wxButton* m_buttonExchange;
wxButton* m_buttonModuleEditor; wxButton* m_buttonModuleEditor;
wxRadioBox* m_AttributsCtrl; wxRadioBox* m_AttributsCtrl;
wxRadioBox* m_AutoPlaceCtrl; wxRadioBox* m_AutoPlaceCtrl;
wxStaticText* m_staticText11; wxStaticText* m_staticText11;
wxSlider* m_CostRot90Ctrl; wxSlider* m_CostRot90Ctrl;
wxStaticText* m_staticText12; wxStaticText* m_staticText12;
wxSlider* m_CostRot180Ctrl; wxSlider* m_CostRot180Ctrl;
wxStaticText* m_staticTextInfo;
wxStaticText* m_MaskClearanceTitle;
wxTextCtrl* m_SolderMaskMarginCtrl;
wxStaticText* m_SolderMaskMarginUnits;
wxStaticText* m_staticTextSolderPaste;
wxTextCtrl* m_SolderPasteMarginCtrl;
wxStaticText* m_SolderPasteMarginUnits;
wxStaticText* m_staticTextRatio;
wxTextCtrl* m_SolderPasteMarginRatioCtrl;
wxStaticText* m_SolderPasteRatioMarginUnits;
wxPanel* m_Panel3D; wxPanel* m_Panel3D;
wxStaticText* m_staticText3Dname; wxStaticText* m_staticText3Dname;
wxListBox* m_3D_ShapeNameListBox; wxListBox* m_3D_ShapeNameListBox;
...@@ -99,7 +108,7 @@ class DIALOG_MODULE_BOARD_EDITOR_BASE : public wxDialog ...@@ -99,7 +108,7 @@ class DIALOG_MODULE_BOARD_EDITOR_BASE : public wxDialog
public: public:
wxStaticBoxSizer* m_Sizer3DValues; wxStaticBoxSizer* m_Sizer3DValues;
DIALOG_MODULE_BOARD_EDITOR_BASE( wxWindow* parent, wxWindowID id = wxID_ANY, const wxString& title = _("Module properties"), const wxPoint& pos = wxDefaultPosition, const wxSize& size = wxSize( 422,583 ), long style = wxDEFAULT_DIALOG_STYLE|wxRESIZE_BORDER ); DIALOG_MODULE_BOARD_EDITOR_BASE( wxWindow* parent, wxWindowID id = wxID_ANY, const wxString& title = _("Module properties"), const wxPoint& pos = wxDefaultPosition, const wxSize& size = wxSize( 474,583 ), long style = wxDEFAULT_DIALOG_STYLE|wxRESIZE_BORDER );
~DIALOG_MODULE_BOARD_EDITOR_BASE(); ~DIALOG_MODULE_BOARD_EDITOR_BASE();
}; };
......
...@@ -132,6 +132,21 @@ void DIALOG_MODULE_MODULE_EDITOR::InitModeditProperties() ...@@ -132,6 +132,21 @@ void DIALOG_MODULE_MODULE_EDITOR::InitModeditProperties()
BoxSizer = new wxBoxSizer( wxVERTICAL ); BoxSizer = new wxBoxSizer( wxVERTICAL );
m_3D_Rotation = new WinEDA_VertexCtrl( m_Panel3D, _( "Shape Rotation:" ), BoxSizer, 2, 1 ); m_3D_Rotation = new WinEDA_VertexCtrl( m_Panel3D, _( "Shape Rotation:" ), BoxSizer, 2, 1 );
m_Sizer3DValues->Add( BoxSizer, 0, wxGROW | wxALL, 5 ); m_Sizer3DValues->Add( BoxSizer, 0, wxGROW | wxALL, 5 );
// Initialize dialog relative to masks clearances
m_SolderMaskMarginUnits->SetLabel( GetUnitsLabel( g_UnitMetric ) );
m_SolderPasteMarginUnits->SetLabel( GetUnitsLabel( g_UnitMetric ) );
wxString msg;
int Internal_Unit = m_Parent->m_InternalUnits;
PutValueInLocalUnits( *m_SolderMaskMarginCtrl,
m_CurrentModule->m_LocalSolderMaskMargin,
Internal_Unit );
PutValueInLocalUnits( *m_SolderPasteMarginCtrl,
m_CurrentModule->m_LocalSolderPasteMargin,
Internal_Unit );
msg.Printf( wxT( "%.1f" ), m_CurrentModule->m_LocalSolderPasteMarginRatio * 100.0 );
m_SolderPasteMarginRatioCtrl->SetValue( msg );
} }
...@@ -315,6 +330,19 @@ void DIALOG_MODULE_MODULE_EDITOR::OnOkClick( wxCommandEvent& event ) ...@@ -315,6 +330,19 @@ void DIALOG_MODULE_MODULE_EDITOR::OnOkClick( wxCommandEvent& event )
m_CurrentModule->m_Reference->Copy(m_ReferenceCopy ); m_CurrentModule->m_Reference->Copy(m_ReferenceCopy );
m_CurrentModule->m_Value->Copy(m_ValueCopy ); m_CurrentModule->m_Value->Copy(m_ValueCopy );
// Initialize masks clearances
m_CurrentModule->m_LocalSolderMaskMargin =
ReturnValueFromTextCtrl( *m_SolderMaskMarginCtrl, m_Parent->m_InternalUnits );
m_CurrentModule->m_LocalSolderPasteMargin =
ReturnValueFromTextCtrl( *m_SolderPasteMarginCtrl, m_Parent->m_InternalUnits );
double dtmp;
wxString msg = m_SolderPasteMarginRatioCtrl->GetValue();
msg.ToDouble( &dtmp );
// A margin ratio de -50% means no paste on a pad, the ratio must be >= 50 %
if( dtmp < -50 )
dtmp = -50;
m_CurrentModule->m_LocalSolderPasteMarginRatio = dtmp / 100;
/* Update 3D shape list */ /* Update 3D shape list */
int ii = m_3D_ShapeNameListBox->GetSelection(); int ii = m_3D_ShapeNameListBox->GetSelection();
if ( ii >= 0 ) if ( ii >= 0 )
......
...@@ -82,24 +82,91 @@ DIALOG_MODULE_MODULE_EDITOR_BASE::DIALOG_MODULE_MODULE_EDITOR_BASE( wxWindow* pa ...@@ -82,24 +82,91 @@ DIALOG_MODULE_MODULE_EDITOR_BASE::DIALOG_MODULE_MODULE_EDITOR_BASE( wxWindow* pa
m_PropRightSizer->Add( m_AutoPlaceCtrl, 0, wxALL|wxEXPAND, 5 ); m_PropRightSizer->Add( m_AutoPlaceCtrl, 0, wxALL|wxEXPAND, 5 );
wxStaticBoxSizer* sbSizerAutoplace; wxStaticBoxSizer* sbSizerAutoplace;
sbSizerAutoplace = new wxStaticBoxSizer( new wxStaticBox( m_PanelProperties, wxID_ANY, _("Auto Move and Place") ), wxVERTICAL ); sbSizerAutoplace = new wxStaticBoxSizer( new wxStaticBox( m_PanelProperties, wxID_ANY, _("Auto Move and Place") ), wxHORIZONTAL );
wxBoxSizer* bSizerRot90;
bSizerRot90 = new wxBoxSizer( wxVERTICAL );
m_staticText11 = new wxStaticText( m_PanelProperties, wxID_ANY, _("Rotation 90 degree"), wxDefaultPosition, wxDefaultSize, 0 ); m_staticText11 = new wxStaticText( m_PanelProperties, wxID_ANY, _("Rotation 90 degree"), wxDefaultPosition, wxDefaultSize, 0 );
m_staticText11->Wrap( -1 ); m_staticText11->Wrap( -1 );
sbSizerAutoplace->Add( m_staticText11, 0, wxTOP|wxRIGHT|wxLEFT, 5 ); bSizerRot90->Add( m_staticText11, 0, wxTOP|wxRIGHT|wxLEFT, 5 );
m_CostRot90Ctrl = new wxSlider( m_PanelProperties, wxID_ANY, 0, 0, 10, wxDefaultPosition, wxDefaultSize, wxSL_AUTOTICKS|wxSL_HORIZONTAL|wxSL_LABELS ); m_CostRot90Ctrl = new wxSlider( m_PanelProperties, wxID_ANY, 0, 0, 10, wxDefaultPosition, wxDefaultSize, wxSL_AUTOTICKS|wxSL_HORIZONTAL|wxSL_LABELS );
sbSizerAutoplace->Add( m_CostRot90Ctrl, 0, wxBOTTOM|wxRIGHT|wxLEFT, 5 ); bSizerRot90->Add( m_CostRot90Ctrl, 0, wxBOTTOM|wxRIGHT|wxLEFT, 5 );
sbSizerAutoplace->Add( bSizerRot90, 1, wxEXPAND, 5 );
wxBoxSizer* bSizerRot180;
bSizerRot180 = new wxBoxSizer( wxVERTICAL );
m_staticText12 = new wxStaticText( m_PanelProperties, wxID_ANY, _("Rotation 180 degree"), wxDefaultPosition, wxDefaultSize, 0 ); m_staticText12 = new wxStaticText( m_PanelProperties, wxID_ANY, _("Rotation 180 degree"), wxDefaultPosition, wxDefaultSize, 0 );
m_staticText12->Wrap( -1 ); m_staticText12->Wrap( -1 );
sbSizerAutoplace->Add( m_staticText12, 0, wxTOP|wxRIGHT|wxLEFT, 5 ); bSizerRot180->Add( m_staticText12, 0, wxTOP|wxRIGHT|wxLEFT, 5 );
m_CostRot180Ctrl = new wxSlider( m_PanelProperties, wxID_ANY, 0, 0, 10, wxDefaultPosition, wxDefaultSize, wxSL_AUTOTICKS|wxSL_HORIZONTAL|wxSL_LABELS ); m_CostRot180Ctrl = new wxSlider( m_PanelProperties, wxID_ANY, 0, 0, 10, wxDefaultPosition, wxDefaultSize, wxSL_AUTOTICKS|wxSL_HORIZONTAL|wxSL_LABELS );
sbSizerAutoplace->Add( m_CostRot180Ctrl, 0, wxBOTTOM|wxRIGHT|wxLEFT, 5 ); bSizerRot180->Add( m_CostRot180Ctrl, 0, wxBOTTOM|wxRIGHT|wxLEFT, 5 );
sbSizerAutoplace->Add( bSizerRot180, 1, wxEXPAND, 5 );
m_PropRightSizer->Add( sbSizerAutoplace, 1, wxEXPAND, 5 ); m_PropRightSizer->Add( sbSizerAutoplace, 1, wxEXPAND, 5 );
wxStaticBoxSizer* sbSizer8;
sbSizer8 = new wxStaticBoxSizer( new wxStaticBox( m_PanelProperties, wxID_ANY, _("Masks clearances local values:") ), wxVERTICAL );
m_staticTextInfo = new wxStaticText( m_PanelProperties, wxID_ANY, _("Set these values to 0 to use global values"), wxDefaultPosition, wxDefaultSize, 0 );
m_staticTextInfo->Wrap( -1 );
m_staticTextInfo->SetFont( wxFont( wxNORMAL_FONT->GetPointSize(), 70, 90, 92, false, wxEmptyString ) );
sbSizer8->Add( m_staticTextInfo, 0, wxALL|wxALIGN_RIGHT, 5 );
wxFlexGridSizer* fgSizer1;
fgSizer1 = new wxFlexGridSizer( 3, 3, 0, 0 );
fgSizer1->SetFlexibleDirection( wxBOTH );
fgSizer1->SetNonFlexibleGrowMode( wxFLEX_GROWMODE_SPECIFIED );
m_MaskClearanceTitle = new wxStaticText( m_PanelProperties, wxID_ANY, _("Solder mask clearance:"), wxDefaultPosition, wxDefaultSize, 0 );
m_MaskClearanceTitle->Wrap( -1 );
fgSizer1->Add( m_MaskClearanceTitle, 0, wxALL|wxALIGN_CENTER_VERTICAL|wxALIGN_RIGHT, 5 );
m_SolderMaskMarginCtrl = new wxTextCtrl( m_PanelProperties, wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 );
m_SolderMaskMarginCtrl->SetToolTip( _("This is the global clearance between pads and the solder mask\nThis value can be superseded by a pad local value.") );
fgSizer1->Add( m_SolderMaskMarginCtrl, 0, wxALL, 5 );
m_SolderMaskMarginUnits = new wxStaticText( m_PanelProperties, wxID_ANY, _("inch"), wxDefaultPosition, wxDefaultSize, 0 );
m_SolderMaskMarginUnits->Wrap( -1 );
fgSizer1->Add( m_SolderMaskMarginUnits, 0, wxALL|wxALIGN_CENTER_VERTICAL, 5 );
m_staticTextSolderPaste = new wxStaticText( m_PanelProperties, wxID_ANY, _("Solder paste clearance:"), wxDefaultPosition, wxDefaultSize, 0 );
m_staticTextSolderPaste->Wrap( -1 );
fgSizer1->Add( m_staticTextSolderPaste, 0, wxALIGN_RIGHT|wxALIGN_CENTER_VERTICAL|wxTOP|wxRIGHT|wxLEFT, 5 );
m_SolderPasteMarginCtrl = new wxTextCtrl( m_PanelProperties, wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 );
m_SolderPasteMarginCtrl->SetToolTip( _("This is the global clearance between pads and the solder paste\nThis value can be superseded by a pad local values.\nThe final clearance value is the sum of this value and the clearance value ratio\nA negative value means a smaller mask size than pad size") );
fgSizer1->Add( m_SolderPasteMarginCtrl, 0, wxTOP|wxRIGHT|wxLEFT, 5 );
m_SolderPasteMarginUnits = new wxStaticText( m_PanelProperties, wxID_ANY, _("Inch"), wxDefaultPosition, wxDefaultSize, 0 );
m_SolderPasteMarginUnits->Wrap( -1 );
fgSizer1->Add( m_SolderPasteMarginUnits, 0, wxTOP|wxRIGHT|wxLEFT|wxALIGN_CENTER_VERTICAL, 5 );
m_staticTextRatio = new wxStaticText( m_PanelProperties, wxID_ANY, _("Solder mask ratio clearance:"), wxDefaultPosition, wxDefaultSize, 0 );
m_staticTextRatio->Wrap( -1 );
fgSizer1->Add( m_staticTextRatio, 0, wxALL|wxALIGN_RIGHT|wxALIGN_CENTER_VERTICAL, 5 );
m_SolderPasteMarginRatioCtrl = new wxTextCtrl( m_PanelProperties, wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 );
m_SolderPasteMarginRatioCtrl->SetToolTip( _("This is the global clearance ratio in per cent between pads and the solder paste\nA value of 10 means the clearance value is 10% of the pad size\nThis value can be superseded by a pad local value.\nThe final clearance value is the sum of this value and the clearance value\nA negative value means a smaller mask size than pad size") );
fgSizer1->Add( m_SolderPasteMarginRatioCtrl, 0, wxALL, 5 );
m_SolderPasteRatioMarginUnits = new wxStaticText( m_PanelProperties, wxID_ANY, _("%"), wxDefaultPosition, wxDefaultSize, 0 );
m_SolderPasteRatioMarginUnits->Wrap( -1 );
fgSizer1->Add( m_SolderPasteRatioMarginUnits, 0, wxALL|wxALIGN_CENTER_VERTICAL, 5 );
sbSizer8->Add( fgSizer1, 1, wxEXPAND, 5 );
m_PropRightSizer->Add( sbSizer8, 1, wxEXPAND, 5 );
m_PanelPropertiesBoxSizer->Add( m_PropRightSizer, 0, 0, 5 ); m_PanelPropertiesBoxSizer->Add( m_PropRightSizer, 0, 0, 5 );
m_PanelProperties->SetSizer( m_PanelPropertiesBoxSizer ); m_PanelProperties->SetSizer( m_PanelPropertiesBoxSizer );
......
This source diff could not be displayed because it is too large. You can view the blob instead.
...@@ -62,6 +62,16 @@ class DIALOG_MODULE_MODULE_EDITOR_BASE : public wxDialog ...@@ -62,6 +62,16 @@ class DIALOG_MODULE_MODULE_EDITOR_BASE : public wxDialog
wxSlider* m_CostRot90Ctrl; wxSlider* m_CostRot90Ctrl;
wxStaticText* m_staticText12; wxStaticText* m_staticText12;
wxSlider* m_CostRot180Ctrl; wxSlider* m_CostRot180Ctrl;
wxStaticText* m_staticTextInfo;
wxStaticText* m_MaskClearanceTitle;
wxTextCtrl* m_SolderMaskMarginCtrl;
wxStaticText* m_SolderMaskMarginUnits;
wxStaticText* m_staticTextSolderPaste;
wxTextCtrl* m_SolderPasteMarginCtrl;
wxStaticText* m_SolderPasteMarginUnits;
wxStaticText* m_staticTextRatio;
wxTextCtrl* m_SolderPasteMarginRatioCtrl;
wxStaticText* m_SolderPasteRatioMarginUnits;
wxPanel* m_Panel3D; wxPanel* m_Panel3D;
wxStaticText* m_staticText3Dname; wxStaticText* m_staticText3Dname;
wxListBox* m_3D_ShapeNameListBox; wxListBox* m_3D_ShapeNameListBox;
...@@ -85,7 +95,7 @@ class DIALOG_MODULE_MODULE_EDITOR_BASE : public wxDialog ...@@ -85,7 +95,7 @@ class DIALOG_MODULE_MODULE_EDITOR_BASE : public wxDialog
public: public:
wxStaticBoxSizer* m_Sizer3DValues; wxStaticBoxSizer* m_Sizer3DValues;
DIALOG_MODULE_MODULE_EDITOR_BASE( wxWindow* parent, wxWindowID id = wxID_ANY, const wxString& title = _("Module properties"), const wxPoint& pos = wxDefaultPosition, const wxSize& size = wxSize( 422,422 ), long style = wxDEFAULT_DIALOG_STYLE|wxRESIZE_BORDER ); DIALOG_MODULE_MODULE_EDITOR_BASE( wxWindow* parent, wxWindowID id = wxID_ANY, const wxString& title = _("Module properties"), const wxPoint& pos = wxDefaultPosition, const wxSize& size = wxSize( 422,549 ), long style = wxDEFAULT_DIALOG_STYLE|wxRESIZE_BORDER );
~DIALOG_MODULE_MODULE_EDITOR_BASE(); ~DIALOG_MODULE_MODULE_EDITOR_BASE();
}; };
......
///////////////////////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////////////////////////
// Name: dialog_mask_clearance.cpp // Name: dialog_mask_clearance.cpp
// Author: jean-pierre Charras // Author: jean-pierre Charras
// Modified by: // Modified by:
...@@ -34,10 +35,19 @@ void DIALOG_PADS_MASK_CLEARANCE::MyInit() ...@@ -34,10 +35,19 @@ void DIALOG_PADS_MASK_CLEARANCE::MyInit()
{ {
SetFocus(); SetFocus();
AddUnitSymbol( *m_MaskClearanceTitle ); m_SolderMaskMarginUnits->SetLabel( GetUnitsLabel( g_UnitMetric ) );
m_SolderPasteMarginUnits->SetLabel( GetUnitsLabel( g_UnitMetric ) );
int Internal_Unit = m_Parent->m_InternalUnits; int Internal_Unit = m_Parent->m_InternalUnits;
PutValueInLocalUnits( *m_OptMaskMargin, g_DesignSettings.m_MaskMargin, Internal_Unit ); PutValueInLocalUnits( *m_SolderMaskMarginCtrl,
g_DesignSettings.m_SolderMaskMargin,
Internal_Unit );
PutValueInLocalUnits( *m_SolderPasteMarginCtrl,
g_DesignSettings.m_SolderPasteMargin,
Internal_Unit );
wxString msg;
msg.Printf( wxT( "%f" ), g_DesignSettings.m_SolderPasteMarginRatio * 100.0 );
m_SolderPasteMarginRatioCtrl->SetValue( msg );
} }
...@@ -45,8 +55,18 @@ void DIALOG_PADS_MASK_CLEARANCE::MyInit() ...@@ -45,8 +55,18 @@ void DIALOG_PADS_MASK_CLEARANCE::MyInit()
void DIALOG_PADS_MASK_CLEARANCE::OnButtonOkClick( wxCommandEvent& event ) void DIALOG_PADS_MASK_CLEARANCE::OnButtonOkClick( wxCommandEvent& event )
/*******************************************************************/ /*******************************************************************/
{ {
g_DesignSettings.m_MaskMargin = g_DesignSettings.m_SolderMaskMargin =
ReturnValueFromTextCtrl( *m_OptMaskMargin, m_Parent->m_InternalUnits ); ReturnValueFromTextCtrl( *m_SolderMaskMarginCtrl, m_Parent->m_InternalUnits );
g_DesignSettings.m_SolderPasteMargin =
ReturnValueFromTextCtrl( *m_SolderPasteMarginCtrl, m_Parent->m_InternalUnits );
double dtmp;
wxString msg = m_SolderPasteMarginRatioCtrl->GetValue();
msg.ToDouble( &dtmp );
// A margin ratio de -50% means no paste on a pad, the ratio must be >= 50 %
if( dtmp < -50 )
dtmp = -50;
g_DesignSettings.m_SolderPasteMarginRatio = dtmp / 100;
EndModal( 1 ); EndModal( 1 );
} }
...@@ -60,4 +80,3 @@ void DIALOG_PADS_MASK_CLEARANCE::OnButtonCancelClick( wxCommandEvent& event ) ...@@ -60,4 +80,3 @@ void DIALOG_PADS_MASK_CLEARANCE::OnButtonCancelClick( wxCommandEvent& event )
{ {
EndModal( 0 ); EndModal( 0 );
} }
...@@ -27,14 +27,58 @@ DIALOG_PADS_MASK_CLEARANCE_BASE::DIALOG_PADS_MASK_CLEARANCE_BASE( wxWindow* pare ...@@ -27,14 +27,58 @@ DIALOG_PADS_MASK_CLEARANCE_BASE::DIALOG_PADS_MASK_CLEARANCE_BASE( wxWindow* pare
wxStaticBoxSizer* sbMiddleRightSizer; wxStaticBoxSizer* sbMiddleRightSizer;
sbMiddleRightSizer = new wxStaticBoxSizer( new wxStaticBox( this, wxID_ANY, _("Dimensions:") ), wxVERTICAL ); sbMiddleRightSizer = new wxStaticBoxSizer( new wxStaticBox( this, wxID_ANY, _("Dimensions:") ), wxVERTICAL );
m_MaskClearanceTitle = new wxStaticText( this, wxID_ANY, _("Pads Mask Clearance:"), wxDefaultPosition, wxDefaultSize, 0 ); m_staticTextInfo = new wxStaticText( this, wxID_ANY, _("Note:\n- a positive value means a mask bigger than a pad\n- a negative value means a mask smaller than a pad\n"), wxDefaultPosition, wxDefaultSize, 0 );
m_staticTextInfo->Wrap( -1 );
sbMiddleRightSizer->Add( m_staticTextInfo, 0, wxALIGN_CENTER_HORIZONTAL|wxRIGHT|wxLEFT, 5 );
m_staticline1 = new wxStaticLine( this, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxLI_HORIZONTAL );
sbMiddleRightSizer->Add( m_staticline1, 0, wxEXPAND | wxALL, 5 );
wxFlexGridSizer* fgGridSolderMaskSizer;
fgGridSolderMaskSizer = new wxFlexGridSizer( 2, 3, 0, 0 );
fgGridSolderMaskSizer->SetFlexibleDirection( wxBOTH );
fgGridSolderMaskSizer->SetNonFlexibleGrowMode( wxFLEX_GROWMODE_SPECIFIED );
m_MaskClearanceTitle = new wxStaticText( this, wxID_ANY, _("Solder mask clearance:"), wxDefaultPosition, wxDefaultSize, 0 );
m_MaskClearanceTitle->Wrap( -1 ); m_MaskClearanceTitle->Wrap( -1 );
sbMiddleRightSizer->Add( m_MaskClearanceTitle, 0, wxTOP|wxRIGHT|wxLEFT, 5 ); fgGridSolderMaskSizer->Add( m_MaskClearanceTitle, 0, wxALIGN_RIGHT|wxALIGN_CENTER_VERTICAL|wxALL, 5 );
m_SolderMaskMarginCtrl = new wxTextCtrl( this, wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 );
m_SolderMaskMarginCtrl->SetToolTip( _("This is the global clearance between pads and the solder mask\nThis value can be superseded by local values for a footprint or a pad.") );
fgGridSolderMaskSizer->Add( m_SolderMaskMarginCtrl, 0, wxEXPAND|wxALL, 5 );
m_SolderMaskMarginUnits = new wxStaticText( this, wxID_ANY, _("Inch"), wxDefaultPosition, wxDefaultSize, 0 );
m_SolderMaskMarginUnits->Wrap( -1 );
fgGridSolderMaskSizer->Add( m_SolderMaskMarginUnits, 0, wxALL, 5 );
m_staticTextSolderPaste = new wxStaticText( this, wxID_ANY, _("Solder paste clearance:"), wxDefaultPosition, wxDefaultSize, 0 );
m_staticTextSolderPaste->Wrap( -1 );
fgGridSolderMaskSizer->Add( m_staticTextSolderPaste, 0, wxALL|wxALIGN_RIGHT|wxALIGN_CENTER_VERTICAL, 5 );
m_SolderPasteMarginCtrl = new wxTextCtrl( this, wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 );
m_SolderPasteMarginCtrl->SetToolTip( _("This is the global clearance between pads and the solder paste\nThis value can be superseded by local values for a footprint or a pad.\nThe final clearance value is the sum of this value and the clearance value ratio") );
fgGridSolderMaskSizer->Add( m_SolderPasteMarginCtrl, 0, wxALL, 5 );
m_SolderPasteMarginUnits = new wxStaticText( this, wxID_ANY, _("Inch"), wxDefaultPosition, wxDefaultSize, 0 );
m_SolderPasteMarginUnits->Wrap( -1 );
fgGridSolderMaskSizer->Add( m_SolderPasteMarginUnits, 0, wxALL, 5 );
m_staticTextRatio = new wxStaticText( this, wxID_ANY, _("Solder mask ratio clearance:"), wxDefaultPosition, wxDefaultSize, 0 );
m_staticTextRatio->Wrap( -1 );
fgGridSolderMaskSizer->Add( m_staticTextRatio, 0, wxALL|wxALIGN_RIGHT|wxALIGN_CENTER_VERTICAL, 5 );
m_SolderPasteMarginRatioCtrl = new wxTextCtrl( this, wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 );
m_SolderPasteMarginRatioCtrl->SetToolTip( _("This is the global clearance ratio in per cent between pads and the solder paste\nA value of 10 means the clearance value is 10% of the pad size\nThis value can be superseded by local values for a footprint or a pad.\nThe final clearance value is the sum of this value and the clearance value") );
fgGridSolderMaskSizer->Add( m_SolderPasteMarginRatioCtrl, 0, wxALL, 5 );
m_OptMaskMargin = new wxTextCtrl( this, wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 ); m_SolderPasteRatioMarginUnits = new wxStaticText( this, wxID_ANY, _("%"), wxDefaultPosition, wxDefaultSize, 0 );
m_OptMaskMargin->SetToolTip( _("This is the clearance between pads and the mask") ); m_SolderPasteRatioMarginUnits->Wrap( -1 );
fgGridSolderMaskSizer->Add( m_SolderPasteRatioMarginUnits, 0, wxALL, 5 );
sbMiddleRightSizer->Add( m_OptMaskMargin, 0, wxBOTTOM|wxRIGHT|wxLEFT|wxEXPAND, 5 ); sbMiddleRightSizer->Add( fgGridSolderMaskSizer, 1, wxEXPAND, 5 );
bMainUpperSizer->Add( sbMiddleRightSizer, 1, wxEXPAND, 5 ); bMainUpperSizer->Add( sbMiddleRightSizer, 1, wxEXPAND, 5 );
......
This diff is collapsed.
...@@ -16,6 +16,7 @@ ...@@ -16,6 +16,7 @@
#include <wx/font.h> #include <wx/font.h>
#include <wx/colour.h> #include <wx/colour.h>
#include <wx/settings.h> #include <wx/settings.h>
#include <wx/statline.h>
#include <wx/textctrl.h> #include <wx/textctrl.h>
#include <wx/sizer.h> #include <wx/sizer.h>
#include <wx/statbox.h> #include <wx/statbox.h>
...@@ -38,8 +39,17 @@ class DIALOG_PADS_MASK_CLEARANCE_BASE : public wxDialog ...@@ -38,8 +39,17 @@ class DIALOG_PADS_MASK_CLEARANCE_BASE : public wxDialog
protected: protected:
wxStaticText* m_staticTextInfo;
wxStaticLine* m_staticline1;
wxStaticText* m_MaskClearanceTitle; wxStaticText* m_MaskClearanceTitle;
wxTextCtrl* m_OptMaskMargin; wxTextCtrl* m_SolderMaskMarginCtrl;
wxStaticText* m_SolderMaskMarginUnits;
wxStaticText* m_staticTextSolderPaste;
wxTextCtrl* m_SolderPasteMarginCtrl;
wxStaticText* m_SolderPasteMarginUnits;
wxStaticText* m_staticTextRatio;
wxTextCtrl* m_SolderPasteMarginRatioCtrl;
wxStaticText* m_SolderPasteRatioMarginUnits;
wxStdDialogButtonSizer* m_sdbButtonsSizer; wxStdDialogButtonSizer* m_sdbButtonsSizer;
wxButton* m_sdbButtonsSizerOK; wxButton* m_sdbButtonsSizerOK;
wxButton* m_sdbButtonsSizerCancel; wxButton* m_sdbButtonsSizerCancel;
...@@ -50,7 +60,7 @@ class DIALOG_PADS_MASK_CLEARANCE_BASE : public wxDialog ...@@ -50,7 +60,7 @@ class DIALOG_PADS_MASK_CLEARANCE_BASE : public wxDialog
public: public:
DIALOG_PADS_MASK_CLEARANCE_BASE( wxWindow* parent, wxWindowID id = wxID_ANY, const wxString& title = _("Pads Mask Clearance"), const wxPoint& pos = wxDefaultPosition, const wxSize& size = wxSize( 256,117 ), long style = wxDEFAULT_DIALOG_STYLE|wxRESIZE_BORDER ); DIALOG_PADS_MASK_CLEARANCE_BASE( wxWindow* parent, wxWindowID id = wxID_ANY, const wxString& title = _("Pads Mask Clearance"), const wxPoint& pos = wxDefaultPosition, const wxSize& size = wxSize( 358,237 ), long style = wxDEFAULT_DIALOG_STYLE|wxRESIZE_BORDER );
~DIALOG_PADS_MASK_CLEARANCE_BASE(); ~DIALOG_PADS_MASK_CLEARANCE_BASE();
}; };
......
...@@ -556,9 +556,20 @@ int WinEDA_BasePcbFrame::ReadSetup( FILE* File, int* LineNum ) ...@@ -556,9 +556,20 @@ int WinEDA_BasePcbFrame::ReadSetup( FILE* File, int* LineNum )
} }
if( stricmp( Line, "Pad2MaskClearance" ) == 0 ) if( stricmp( Line, "Pad2MaskClearance" ) == 0 )
{ {
g_DesignSettings.m_MaskMargin = atoi( data ); g_DesignSettings.m_SolderMaskMargin = atoi( data );
continue; continue;
} }
if( stricmp( Line, "Pad2PasteClearance" ) == 0 )
{
g_DesignSettings.m_SolderPasteMargin = atoi( data );
continue;
}
if( stricmp( Line, "Pad2PasteClearanceRatio" ) == 0 )
{
g_DesignSettings.m_SolderPasteMarginRatio = atof( data );
continue;
}
#endif #endif
} }
...@@ -658,7 +669,11 @@ static int WriteSetup( FILE* aFile, WinEDA_BasePcbFrame* aFrame, BOARD* aBoard ) ...@@ -658,7 +669,11 @@ static int WriteSetup( FILE* aFile, WinEDA_BasePcbFrame* aFrame, BOARD* aBoard )
fprintf( aFile, "TextModWidth %d\n", ModuleTextWidth ); fprintf( aFile, "TextModWidth %d\n", ModuleTextWidth );
fprintf( aFile, "PadSize %d %d\n", g_Pad_Master.m_Size.x, g_Pad_Master.m_Size.y ); fprintf( aFile, "PadSize %d %d\n", g_Pad_Master.m_Size.x, g_Pad_Master.m_Size.y );
fprintf( aFile, "PadDrill %d\n", g_Pad_Master.m_Drill.x ); fprintf( aFile, "PadDrill %d\n", g_Pad_Master.m_Drill.x );
fprintf( aFile, "Pad2MaskClearance %d\n", g_DesignSettings.m_MaskMargin ); fprintf( aFile, "Pad2MaskClearance %d\n", g_DesignSettings.m_SolderMaskMargin );
if( g_DesignSettings.m_SolderPasteMargin != 0)
fprintf( aFile, "Pad2PasteClearance %d\n", g_DesignSettings.m_SolderPasteMargin );
if( g_DesignSettings.m_SolderPasteMarginRatio != 0 )
fprintf( aFile, "Pad2PasteClearanceRatio %g\n", g_DesignSettings.m_SolderPasteMarginRatio );
fprintf( aFile, "AuxiliaryAxisOrg %d %d\n", fprintf( aFile, "AuxiliaryAxisOrg %d %d\n",
aFrame->m_Auxiliary_Axis_Position.x, aFrame->m_Auxiliary_Axis_Position.y ); aFrame->m_Auxiliary_Axis_Position.x, aFrame->m_Auxiliary_Axis_Position.y );
......
...@@ -88,6 +88,9 @@ MODULE* WinEDA_ModuleEditFrame::Import_Module( wxDC* DC ) ...@@ -88,6 +88,9 @@ MODULE* WinEDA_ModuleEditFrame::Import_Module( wxDC* DC )
Config->Write( EXPORT_IMPORT_LASTPATH_KEY, LastOpenedPathForLoading ); Config->Write( EXPORT_IMPORT_LASTPATH_KEY, LastOpenedPathForLoading );
} }
// Switch the locale to standard C (needed to print floating point numbers like 1.3)
SetLocaleTo_C_standard( );
/* Read header and test file type */ /* Read header and test file type */
GetLine( file, Line, &NbLine ); GetLine( file, Line, &NbLine );
if( strnicmp( Line, ENTETE_LIBRAIRIE, L_ENTETE_LIB ) != 0 ) if( strnicmp( Line, ENTETE_LIBRAIRIE, L_ENTETE_LIB ) != 0 )
...@@ -124,6 +127,7 @@ MODULE* WinEDA_ModuleEditFrame::Import_Module( wxDC* DC ) ...@@ -124,6 +127,7 @@ MODULE* WinEDA_ModuleEditFrame::Import_Module( wxDC* DC )
module->ReadDescr( file, &NbLine ); module->ReadDescr( file, &NbLine );
fclose( file ); fclose( file );
} }
SetLocaleTo_Default( ); // revert to the current locale
/* Insert footprint in list*/ /* Insert footprint in list*/
GetBoard()->Add( module ); GetBoard()->Add( module );
...@@ -197,6 +201,9 @@ void WinEDA_ModuleEditFrame::Export_Module( MODULE* ptmod, bool createlib ) ...@@ -197,6 +201,9 @@ void WinEDA_ModuleEditFrame::Export_Module( MODULE* ptmod, bool createlib )
Config->Write( EXPORT_IMPORT_LASTPATH_KEY, fn.GetPath() ); Config->Write( EXPORT_IMPORT_LASTPATH_KEY, fn.GetPath() );
} }
// Switch the locale to standard C (needed to read floating point numbers like 1.3)
SetLocaleTo_C_standard();
fprintf( file, "%s %s\n", ENTETE_LIBRAIRIE, DateAndTime( Line ) ); fprintf( file, "%s %s\n", ENTETE_LIBRAIRIE, DateAndTime( Line ) );
fputs( "$INDEX\n", file ); fputs( "$INDEX\n", file );
...@@ -207,6 +214,8 @@ void WinEDA_ModuleEditFrame::Export_Module( MODULE* ptmod, bool createlib ) ...@@ -207,6 +214,8 @@ void WinEDA_ModuleEditFrame::Export_Module( MODULE* ptmod, bool createlib )
fputs( "$EndLIBRARY\n", file ); fputs( "$EndLIBRARY\n", file );
fclose( file ); fclose( file );
SetLocaleTo_Default( ); // revert to the current locale
msg.Printf( _( "Module exported in file <%s>" ), GetChars( fn.GetFullPath() ) ); msg.Printf( _( "Module exported in file <%s>" ), GetChars( fn.GetFullPath() ) );
DisplayInfoMessage( this, msg ); DisplayInfoMessage( this, msg );
} }
...@@ -605,6 +614,9 @@ int WinEDA_BasePcbFrame::Save_Module_In_Library( const wxString& aLibName, ...@@ -605,6 +614,9 @@ int WinEDA_BasePcbFrame::Save_Module_In_Library( const wxString& aLibName,
wxBeginBusyCursor(); wxBeginBusyCursor();
// Switch the locale to standard C (needed to print floating point numbers like 1.3)
SetLocaleTo_C_standard( );
/* Create the library header with a new date */ /* Create the library header with a new date */
fprintf( dest, ENTETE_LIBRAIRIE ); fprintf( dest, ENTETE_LIBRAIRIE );
fprintf( dest, " %s\n$INDEX\n", DateAndTime( Line ) ); fprintf( dest, " %s\n$INDEX\n", DateAndTime( Line ) );
...@@ -665,6 +677,7 @@ int WinEDA_BasePcbFrame::Save_Module_In_Library( const wxString& aLibName, ...@@ -665,6 +677,7 @@ int WinEDA_BasePcbFrame::Save_Module_In_Library( const wxString& aLibName,
aModule->m_TimeStamp = tmp; aModule->m_TimeStamp = tmp;
fclose( dest ); fclose( lib_module ); fclose( dest ); fclose( lib_module );
SetLocaleTo_Default( ); // revert to the current locale
wxEndBusyCursor(); wxEndBusyCursor();
......
...@@ -623,10 +623,10 @@ static PARAM_CFG_INT HPGLrecouvrementCfg ...@@ -623,10 +623,10 @@ static PARAM_CFG_INT HPGLrecouvrementCfg
static PARAM_CFG_INT VernisEpargneGardeCfg static PARAM_CFG_INT VernisEpargneGardeCfg
( (
wxT( "VEgarde" ), /* Keyword */ wxT( "VEgarde" ), /* Keyword */
&g_DesignSettings.m_MaskMargin, /* Parameter address */ &g_DesignSettings.m_SolderMaskMargin, /* Parameter address */
100, /* Default value */ 100, /* Default value */
0, 0xFFFF /* Min and max values*/ 0, 10000 /* Min and max values*/
); );
static PARAM_CFG_INT DrawSegmLargeurCfg static PARAM_CFG_INT DrawSegmLargeurCfg
......
This diff is collapsed.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment