Commit Graph

109 Commits

Author SHA1 Message Date
jean-pierre charras 8d1d37beb0 Refinements in pad properties dialog 2017-09-20 16:14:23 +02:00
jean-pierre charras 7c1ac6fbcc Refinements in pad properties dialog 2017-09-20 15:37:37 +02:00
jean-pierre charras a43f3ab1fe replace "BasicShape" by "Primitive" in code, a better name 2017-09-20 12:51:10 +02:00
Maciej Suminski cca63801bf Renamed D_PAD::{Set,Get}PadName() to D_PAD::{Set,Get}Name() 2017-09-19 18:23:50 +02:00
Maciej Suminski 85be485c34 Enable long names for pin numbers and pads
- pad names are stored as wxString instead of a char[4] & integer union
- removed pad name to string conversion functions
- fixed pad & pin properties dialog restrictions regarding the name
length
2017-09-19 18:19:49 +02:00
jean-pierre charras e2d3fcec02 Add support for custom pad shape. Full support in DRC and PnS.
add option to use shape or convex hull as clearance area in zones.
simplify code to handle clearance area
2017-09-19 09:02:53 +02:00
Tomasz Włostowski 32185ddcd3 Multiple improvements concerning colors, configuration handling and legacy features in pcbnew:
- support for background color setting
    - removed several global config settings (such as g_Drc_On)
    - wrapped most of global config settings in PCB_GENERAL_SETTINGS class
    - reorganized PCB general options dialog to clearly mark which options concern only the legacy canvas
    - new GAL feature for legacy users: double-click (or E) to change track width available as an option.

Fixes: lp:1530543
* https://bugs.launchpad.net/kicad/+bug/1530543

Fixes: lp:1707145
* https://bugs.launchpad.net/kicad/+bug/1707145
2017-08-04 16:06:57 +02:00
jean-pierre charras b8183a1aa5 Fix Coverity warnings 2017-05-30 09:07:18 +02:00
Jon Evans 3ec28e2acf Refactor layer enumerations to all live in the same place 2017-03-30 16:01:48 -04:00
Maciej Suminski fe4f02f5b9 Coverity fixes
CIDs:
- 153097
- 157120
- 157119
- 155148
- 155146
- 153103
- 153099
- 153095
- 153087
- 153086
2017-03-11 22:20:08 +01:00
Maciej Suminski 0dc88bb4cf Changed COLOR4D defines to static consts 2017-02-22 17:35:00 +01:00
Jon Evans a52250a91e Change from EDA_COLOR_T to COLOR4D globally; arbitrary color support
eeschema now supports arbitrary colors for all object types, and
pcbnew does in GAL canvas.  When switching from GAL to legacy canvas,
pcbnew will convert colors to the nearest legacy color.
2017-02-22 17:35:00 +01:00
jean-pierre charras 3f1bcf5be8 Pcbnew: Fix "push pad settings" segfault when no pad selected.
Fixes: lp: 1663915
https://bugs.launchpad.net/kicad/+bug/1663915
2017-02-12 08:09:21 +01:00
jean-pierre charras 0dc11936ad Fixes: lp:1662702 (Pad Properties Dialog not responding to OK button when run from ModEdit toolbar)
https://bugs.launchpad.net/kicad/+bug/1662702
2017-02-08 09:27:52 +01:00
Diogo Condeco 75ffcbcef5 MACOS Setfocus and CancelButtonIssue moved into dialog_shim.
Setfocus now works on macos dialogs by setting DLGSHIM_USE_SETFOCUS.
This option is only enabled __WXMAC__ is defined.

FixOSXCancelButtonIssue() is now called inside DIALOG_SHIM::SHOW.
All other calls from within the dialogs were removed.
2017-01-29 23:51:35 +01:00
diogocondeco b54e77e466 Macos SetFocus() and SetSelection moved into OnInitDialog
pcbnew/dialog_find and pcbnew/dialog_pad_properties modified so that SetFocus and SetSelection is handled once the dialog is initiated.
2017-01-23 12:30:59 -05:00
jean-pierre charras b8b08dafd6 Code cleaning: remove pcbcommon.* which contains nothing really useful. The very few lines of code are moved to a better place. 2016-12-31 12:56:21 +01:00
Tomasz Włostowski 1c1f4e9a50 Refactoring of VIEW/VIEW_ITEM classes:
- Remove dependency of EDA_ITEM on VIEW
- VIEW_ITEM is now a pure virtual interface
2016-12-12 16:45:52 +01:00
Maciej Suminski c4be379b31 Modified properties dialog to take advantage of BOARD_COMMIT class. 2016-09-12 11:50:06 +02:00
Maciej Suminski 09e0311d4e Replaced Copy() method with operator=. Removed Copy() where default copy ctor was enough. 2016-09-12 11:50:06 +02:00
jean-pierre charras fd42d76e2f refinements in dialogs and OSX Cancel button fix. Dialog_pad_properties, pad viewer in GAL mode: better size of the drawing area. The scrollbars are now usable. 2016-07-19 11:16:16 +02:00
jean-pierre charras 01100a57e5 refinements in dialogs and OSX Cancel button fix 2016-07-18 18:28:02 +02:00
jean-pierre charras e2d4118470 Eechema, Component editor: Fix a bug in Pin properties dialog: a parameter used to draw the pin in preview canvas was incorrect, due to code change in draw pin. 2016-05-19 18:38:36 +02:00
Chris Pavlina 4d77388216 Clean up wxValidator window association
wxValidator::SetWindow was used too many times due to me being a dunderhead who
can't read the docs.
2016-04-10 18:28:06 -04:00
Chris Pavlina 8325d6fdf0 Eliminate 0.1deg units in DIALOG_PAD_PROPERTIES 2016-04-10 18:14:28 -04:00
jean-pierre charras f294834f4d dialog_pad_properties: Some fixes. Dialog_edit_module_text: fix an issue related to displayed texts, which were deleted and replaced by the unit symbol only, and the name of the parameter was therefore lost. 2016-04-10 12:40:31 +02:00
jean-pierre charras 4a838fb8c3 Pcbnew: Add rounded rect pad shape. 2016-04-06 20:15:49 +02:00
jean-pierre charras 7313b28e2a Cvpcb: minor change in menubar: change menu name "files" to "Save" (there is no more files to read or save). Pcbnew, pad properies editor: show Axis (pad origin) in GAL mode (it was already shown in legacy mode). 2016-02-13 16:34:52 +01:00
jean-pierre charras 9d994663f1 Fix Bug #1527446 (Flipping a block in pcbnew doesn't flip inner layers nor their connected microvias).
Also fix a few typos and remove dead code.
2015-12-27 16:51:13 +01:00
jean-pierre charras 70b584c5f5 Dialog Pad Properties: fix 2 issues: Bug #1504749 (pad parameter "delta" checking error for non trapezoid pads which do not use this parameter) and SMD pads allowed on all layers
The existing test was disabled for an unknown reason, which is a non sense and more important breaks the DRC.
2015-10-10 18:56:31 +02:00
jean-pierre charras 4fc230b773 Rework on Enum PAD_SHAPE_T, PAD_DRILL_SHAPE_T and PAD_ATTR_T (see rev 6008) : the new and better names are now used in Kicad code and existing python scripts.
PAD_SHAPE_T  and PAD_ATTR_T still have a double definition (new names and old names) to be sure python scripts are nor broken by the change.
 PAD_DRILL_SHAPE_T does not  have a double definition, because it is unlikely oblong holes are used in python scripts.
Double definitions will be removed in the (next) future.
2015-08-23 21:40:33 +02:00
unknown cc7549a2a5 * Python scripting: brings pad.GetZoneConnection() and in example pad.SetZoneConnection(pcbnew.PAD_ZONE_CONN_FULL) to full workable.
* Cleanup namespace  in enum ZoneConnection in pcbnew/zones.h to self-explained names unification:  PAD_ZONE_CONN_INHERITED, PAD_ZONE_CONN_NONE,PAD_ZONE_CONN_THERMAL,PAD_ZONE_CONN_FULL, PAD_ZONE_CONN_THT_THERMAL
2015-08-18 16:19:17 +02:00
unknown 71b3125d8e Cleanup: remove unnecessary macros EXCHG and NEGATE. add MIRROR macro. 2015-06-26 15:41:56 +02:00
Maciej Suminski b6c5b291a2 Coverity fixes. 2015-03-11 14:17:43 +01:00
Blair Bonnett 149a04f331 Fix crash in footprint editor when SMD pad diameter is zero. (fixes lp:1378917) 2014-11-19 13:39:02 -05:00
Lorenzo Marcantonio 424aac6cf2 TEXTE_MODULE cleanup in preparation for text on different layers
- Removed the friends MODULE and FOOTPRINT_EDIT_FRAME from TEXTE_MODULE
  (as in the @todo comment)

- Refactored the Rotate/Flip/Mirror for text in modules into the
  TEXTE_MODULE class itself (members RotateWithModule, FlipWithModule,
  MirrorWithModule)

- New behaviour in coloring text on screen: reference and value still
  take the color from the MOD_TEXT_FR_VISIBLE and MOD_TEXT_BK_VISIBLE
  visibles; other text takes the color of the layer containing it
  (except when hidden, obviously) but still get its visibility
  controlled by those visibles (probably the most intuitive and useful
  behaviour)

- Still need to decide: should text on a layer be hidden when the layer
  is? Probably yes (still to be implemented);

- Some comment fixed and many cast converted to static_cast
2014-09-10 17:18:42 +02:00
Dick Hollenbeck 3e861db371 Lock file improvements. 2014-09-07 15:01:26 -04:00
Maciej Suminski 6ba1410054 Fixed vanishing pads issue in the pad properties dialog (GAL). 2014-07-28 14:01:29 +02:00
Maciej Suminski 2c5b79456e Fixed crash in pad properties dialog with wxWidgets 2.8. 2014-07-15 16:02:08 +02:00
Maciej Suminski 5134781a38 GAL view in pad properties dialog - initial version. 2014-07-09 11:22:43 +02:00
jean-pierre charras eb396a5e88 Fix footprint wizard issues. Fix export vrml incorrect Z position of items. 2014-07-02 15:08:28 +02:00
jean-pierre charras c6af2a7974 Fix a double minor bug about layers occupied by SMD pads and CONN pad:
The default layer stack between these 2 types was swaped in pad definition, and also in the dialog pad properties.
This double swap creates no bug, but creates bugs in the footprint wizards (SMD or CONN pads do not have the right layer stack)
FYI, the CONN pad type should be removed soon.
2014-06-30 20:14:06 +02:00
Dick Hollenbeck 4578ea8b9e 1) Add 32 Cu Layers.
2) Change from legacy Cu stack to counting down from top=(F_Cu or 0).
   The old Cu stack required knowing the count of Cu layers to make
   sense of the layer number when converting to many exported file types.
   The new Cu stack is more commonly used, although ours still gives
   B_Cu a fixed number.
3) Introduce class LSET and enum LAYER_ID.
4) Change *.kicad_pcb file format version to 4 from 3.
5) Change fixed names Inner1_Cu-Inner14_Cu to In1_Cu-In30_Cu and their
   meanings are typically flipped.
6) Moved the #define LAYER_N_* stuff into legacy_plugin.cpp where they
   can die a quiet death, and switch to enum LAYER_ID symbols throughout.
7) Removed the LEGACY_PLUGIN::Save() and FootprintSave() functions.
   You will need to convert to the format immediately, *.kicad_pcb and
   *.kicad_mod (=pretty) since legacy format was never going to know
   about 32 Cu layers and additional technical layers and the reversed Cu
   stack.
2014-06-24 11:17:18 -05:00
jean-pierre charras 9c1f6b7307 Pcbnew: fix Bug #1304418 . Fix also a related issue which crashes Pcbnew in some corner cases.
(for instance, when a footprint from the currently edited board is loaded in the footprint editor, and when the board is cleared or reloaded)
In footprint editor, the net names are no more shown od modifiable (becuase the footprint editor does not know anything about net names.
This change should allow the changes planned in pcbnew.
2014-04-24 20:54:49 +02:00
Dick Hollenbeck 6bfff89fe5 merge tip in, resolve. 2014-03-20 01:24:33 -05:00
Dick Hollenbeck 2c67c3ff80 * KIWAY Milestone A): Make major modules into DLL/DSOs.
!   The initial testing of this commit should be done using a Debug build so that
    all the wxASSERT()s are enabled.  Also, be sure and keep enabled the
    USE_KIWAY_DLLs option.  The tree won't likely build without it.  Turning it
    off is senseless anyways.  If you want stable code, go back to a prior version,
    the one tagged with "stable".

*   Relocate all functionality out of the wxApp derivative into more finely
    targeted purposes:
    a) DLL/DSO specific
    b) PROJECT specific
    c) EXE or process specific
    d) configuration file specific data
    e) configuration file manipulations functions.

    All of this functionality was blended into an extremely large wxApp derivative
    and that was incompatible with the desire to support multiple concurrently
    loaded DLL/DSO's ("KIFACE")s and multiple concurrently open projects.
    An amazing amount of organization come from simply sorting each bit of
    functionality into the proper box.

*   Switch to wxConfigBase from wxConfig everywhere except instantiation.
*   Add classes KIWAY, KIFACE, KIFACE_I, SEARCH_STACK, PGM_BASE, PGM_KICAD,
    PGM_SINGLE_TOP,
*   Remove "Return" prefix on many function names.
*   Remove obvious comments from CMakeLists.txt files, and from else() and endif()s.
*   Fix building boost for use in a DSO on linux.
*   Remove some of the assumptions in the CMakeLists.txt files that windows had
    to be the host platform when building windows binaries.
*   Reduce the number of wxStrings being constructed at program load time via
    static construction.
*   Pass wxConfigBase* to all SaveSettings() and LoadSettings() functions so that
    these functions are useful even when the wxConfigBase comes from another
    source, as is the case in the KICAD_MANAGER_FRAME.
*   Move the setting of the KIPRJMOD environment variable into class PROJECT,
    so that it can be moved into a project variable soon, and out of FP_LIB_TABLE.
*   Add the KIWAY_PLAYER which is associated with a particular PROJECT, and all
    its child wxFrames and wxDialogs now have a Kiway() member function which
    returns a KIWAY& that that window tree branch is in support of.  This is like
    wxWindows DNA in that child windows get this member with proper value at time
    of construction.
*   Anticipate some of the needs for milestones B) and C) and make code
    adjustments now in an effort to reduce work in those milestones.
*   No testing has been done for python scripting, since milestone C) has that
    being largely reworked and re-thought-out.
2014-03-19 19:42:08 -05:00
jean-pierre charras 0f09c15f11 Pad editor dialog: Better tests and error messages about issues in pad settings. Fis also an other hard to translate error messge. 2014-03-19 21:06:09 +01:00
jean-pierre charras ab27f56cc7 Doc update 2014-03-14 08:37:04 +01:00
jean-pierre charras d00fae588a Footprint Editor: fix a crash when the dialog to set pad properties is called from the main toolbar (i.e. to define the default setting for new pads, and not to edit an existing pad) 2014-03-13 08:15:19 +01:00
Maciej Suminski 5ed0980dd5 Merged upstream. 2014-03-06 09:42:16 +01:00