Commit Graph

3411 Commits

Author SHA1 Message Date
Jeff Young df924a5e68 Follow standard FBP naming conventions. 2018-03-18 22:17:27 +00:00
Jeff Young 1684fc735a Defensive coding to attempt to prevent wxWidgets crash.
Fixes: lp:1756255
* https://bugs.launchpad.net/kicad/+bug/1756255
2018-03-16 19:02:25 +00:00
Wayne Stambaugh 3f52e87224 Standardize terminology for automatic zoom to "Zoom to Fit".
Fixes lp:1753336

https://bugs.launchpad.net/kicad/+bug/1753336
2018-03-16 08:38:36 -04:00
jean-pierre charras 819056df9d Eeschema: Add footprint field to Cadstar netlist file.
Fixes: lp:1755996
https://bugs.launchpad.net/kicad/+bug/1755996
2018-03-16 13:20:00 +01:00
Jon Evans 2cc5c6fd45 Add ERC check in component editor for conflicting multi-unit pins
Fixes: lp:1680638
* https://bugs.launchpad.net/kicad/+bug/1680638
2018-03-15 11:11:43 -04:00
Jon Evans 0a81782b5d Add ERC check that a pin appears in only one net
Fixes: lp:1680638
* https://bugs.launchpad.net/kicad/+bug/1680638
2018-03-15 11:11:43 -04:00
jean-pierre charras e14a7c928c Fix incorrect pin num string in cadstar and orcadpcb2 format 2018-03-15 09:15:49 +01:00
Jeff Young 3d12a6889b Make sure ERC and DRC item lists respect color themes.
Fixes: lp:1492953
* https://bugs.launchpad.net/kicad/+bug/1492953
2018-03-14 14:15:16 +00:00
Maciej Suminski 83efd6b8a3 Added 'Paste' to eeschema context menus
Fixes: lp:1754891
* https://bugs.launchpad.net/kicad/+bug/1754891
2018-03-13 17:26:33 +01:00
Jon Evans 935a5cada8 Fix typo in conditional check
Fixes: lp:1755265
* https://bugs.launchpad.net/kicad/+bug/1755265
2018-03-12 22:15:27 -04:00
Jeff Young f32f14dc8f Add WX_TEXT_ENTRY_DIALOG which inherits from DIALOG_SHIM.
Fixes: lp:1754977
* https://bugs.launchpad.net/kicad/+bug/1754977
2018-03-12 22:45:51 +00:00
Jeff Young 3d32ee774e Translatable strings must be ASCII7 for translation tools. 2018-03-12 19:54:07 +00:00
Jeff Young 4eedb3a27d The _() macro affords some nullptr safety over a naked immediate.
Fixes: lp:1477448
* https://bugs.launchpad.net/kicad/+bug/1477448
2018-03-12 19:18:05 +00:00
Tomasz Wlostowski b1f613071d eeschema: workaround for 64kByte string length limit in wxString::Format() causing segfaults in netlist update under Windows
Fixes: lp:1754402
* https://bugs.launchpad.net/kicad/+bug/1754402
2018-03-12 18:26:25 +01:00
jean-pierre charras 17f6d09935 Page layout editor: fix incorrect management of block operation in context (popup) menu. 2018-03-11 18:38:27 +01:00
Seth Hillbrand ce8d5787f7 Standardize Hierarchy wording 2018-03-09 09:43:54 -08:00
Seth Hillbrand 649809a38f Standardize Keywords->Key words 2018-03-09 09:43:53 -08:00
hauptmech eeeed88425 Use fixed width on first Symbol Table column
Autosize when the reference field is a list of all components was too long.

Fixes: lp:1753330
* https://bugs.launchpad.net/kicad/+bug/1753330
2018-03-08 20:59:46 -05:00
Jeff Young 4693fd6200 Resolve env vars when looking up documentation files.
Fixes: lp:1729276
* https://bugs.launchpad.net/kicad/+bug/1729276
2018-03-08 23:51:10 +00:00
Seth Hillbrand 33423fe88d Standardize capitalization
Messages should start with capitalized letter
2018-03-08 12:33:32 -08:00
Seth Hillbrand 8ff91cc0da Standardize hotkeys table 2018-03-08 12:33:32 -08:00
Seth Hillbrand de8716bcc2 Standardize open web browser 2018-03-08 12:33:32 -08:00
Seth Hillbrand f76b89cf99 Standardize error message in Eeschema 2018-03-08 12:33:32 -08:00
Seth Hillbrand 3cbf5f4942 Spelling indentifier -> identifier 2018-03-08 12:33:32 -08:00
Maciej Suminski b3601bd540 SCH_LEGACY_PLUGIN_CACHE: Rename conflicting aliases 2018-03-08 09:48:41 +01:00
Maciej Suminski d74bb131e1 SCH_LEGACY_PLUGIN_CACHE: Do not add the root alias for loaded symbols
The root alias is added in the loop iterating through all aliases.
2018-03-08 09:48:41 +01:00
Maciej Suminski a5844c9bb8 Replace illegal characters in LIB_{ALIAS,PART} LIB_IDs
Schematic components have illegal characters replaced during load,
leading to broken component-symbol links. To avoid this, library symbols
should have their names fixed in the same way.

Fixes: lp:1752419
* https://bugs.launchpad.net/kicad/+bug/1752419
2018-03-08 09:48:34 +01:00
Seth Hillbrand 9c532dfada Eeschema: Prevent block duplicate from disappearing
Duplicate is handled like move/drag but shouldn't mark the original
items as moving.  This prevents a redraw from drawing the original
items.

Fixes: lp:1750083
* https://bugs.launchpad.net/kicad/+bug/1750083
2018-03-07 16:43:21 -08:00
Michael Kavanagh fabbc48b40 macOS: standardise CFBundleName to application names. 2018-03-05 01:14:00 +00:00
Seth Hillbrand 9c44d67f3b Eeschema: Simplify transformation representation
Fixes: lp:1752745
* https://bugs.launchpad.net/kicad/+bug/1752745
2018-03-05 01:05:21 +00:00
Jeff Young f4eb63f871 Size fields list correctly in symbol edit.
Fixes: lp:1753323
* https://bugs.launchpad.net/kicad/+bug/1753323
2018-03-05 00:07:50 +00:00
Maciej Suminski 2af51ef20f Eagle import: do not call TrimWire() on imported schematics
It turns out that TrimWire() may remove legit Eagle wires and effectively
change the netlist.
2018-03-04 18:04:19 +01:00
Maciej Suminski 1f09990618 Remove not used ListNets() methods 2018-03-04 18:04:19 +01:00
Maciej Suminski 260f680c6c Eagle import: fix memory leak on schematic sheets import 2018-03-04 16:47:26 +01:00
Maciej Suminski 8e8d95dd7f Eagle import: process all sheets when adding junctions; fix footprint LIB_IDs 2018-03-04 16:45:42 +01:00
Maciej Suminski 77346d81ce Eagle import plugin: add junction dots to fix connectivity 2018-03-04 16:45:42 +01:00
Maciej Suminski 1f078f533b Refactor Eagle project import to use Kiway::ExpressMail() 2018-03-04 16:45:42 +01:00
Russell Oliver 9016344bb3 Eagle Schematic Import: Fix netlist mapping for zones and vias. 2018-03-04 16:45:11 +01:00
Russell Oliver 3d9c25494c Revert "Eagle importer: use only global net labels"
This reverts commit b1f456fade.
2018-03-04 16:42:55 +01:00
Wayne Stambaugh 43147a3a7a Do not append "RESCUE" to symbol names when rescuing symbols.
Fixes lp:1741755

https://bugs.launchpad.net/kicad/+bug/1741755
2018-03-03 15:34:26 -05:00
Tomasz Włostowski 919b449595 Added 'show spice netlist' menu option in the simulator
Fixes: lp:1745887
* https://bugs.launchpad.net/kicad/+bug/1745887
2018-03-03 17:38:28 +01:00
Wayne Stambaugh aeae32b1a2 Fix file naming bug when importing Eagle projects with . in file name.
Fixes lp:1747470

https://bugs.launchpad.net/kicad/+bug/1747470
2018-03-03 08:35:53 -05:00
Seth Hillbrand cb052b42a6 LibEdit: Correct Mirroring labels in context menu
Fixes: lp:1752763
* https://bugs.launchpad.net/kicad/+bug/1752763
2018-03-02 10:17:55 -08:00
Maciej Suminski 3f1a3fe65b Derive DIALOG_MULTI_OPTIONS from wxMultiChoiceDialog 2018-03-02 18:09:27 +01:00
Seth Hillbrand 886159347a Eeschema: Verify file content exists
Fixes: lp:1752724
* https://bugs.launchpad.net/kicad/+bug/1752724
2018-03-01 14:32:59 -08:00
Wayne Stambaugh ce1bd4c6b7 Eeschema: fix remapping backup project with schematics in subfolders.
The backup code was designed for a project with all of the schematics
in the project folder which is not always the case.  Fix the schematic
backup to keep the schematic folder structure in tact during backups.

Fixes lp:1751662

https://bugs.launchpad.net/kicad/+bug/1751662
2018-02-28 11:42:05 -05:00
Carsten Schoenert 2b52415cae fix misspelled 'Unkown' -> 'Unknown' 2018-02-25 17:10:10 -05:00
Carsten Schoenert ff305781fb fix misspelled 'neeeded' -> 'needed' 2018-02-25 17:10:10 -05:00
Seth Hillbrand 948396024b Setting Eeschema white foreground for BW printing
Keep any Eeschema color except background a fraction off of true white
to ensure that BW printing shows the lines as black.  Only the
background is allowed to be white in an Eeschema printout.

Fixes: lp:1662859
* https://bugs.launchpad.net/kicad/+bug/1662859
2018-02-23 15:41:41 -05:00
jean-pierre charras 9a462d9414 dialog_bom: modify the way a command line is created (python scripts on windows only) to call python scripts
For some reason, when calling python and giving a full filename script, the last separator in the filename
must be '/', not '\'.
Otherwise the import command inside the script does not find files to import in the same folder as the script.

We cannot replace blindly '\' to '/' in command line because it does not work for file on a server (name starting by \\server_name\).
So the fix is just replacing one '\' in python script full filename.
This is not perfect, but at least it works for newly created plugin commands.
2018-02-23 09:50:15 +01:00
Michael afd4710045 Eeschema: New menubar structure
Update menubar to new structure and use common hotkeys.
2018-02-22 20:43:21 -05:00
Jeff Young 4dda8a39fe Add inc/dec current layer alpha to menus.
Also adds indicators in layers palette for feedback.
Also generates sized images for all indicators instead of using
scaled bitmaps (which didn't look great).
Also fixes a completely unrelated typo in a UI string.
2018-02-22 17:48:14 +01:00
Jeff Young c47821a689 Stop nagging me about annotating.
Adds a checkbox to turn off confirmation dialogs.
2018-02-20 19:12:59 -05:00
Wayne Stambaugh df2819e5bc Eeschema: fix sheet schematic file naming bug.
Fixes lp:1750468

https://bugs.launchpad.net/kicad/+bug/1750468
2018-02-20 16:01:52 -05:00
Jeff Young 4d5e1489fb New menu structure for ModEdit.
Includes some dialog changes to go with the menu update.
Includes promoting the Pcbnew graphics mode back to main menu.
Includes renaming Graphics modes to Toolsets.
2018-02-20 10:49:41 -05:00
Jeff Young 4b01c9e04e Fix undo of pin edit.
Undo stashing must happen before modifications.

Fixes: lp:1750401
* https://bugs.launchpad.net/kicad/+bug/1750401
2018-02-19 15:03:23 -05:00
jean-pierre charras 0e493a3f91 Disallow '/' in labels, Step 2: disallow not allowed chars in all labels (local, global, hierarchical, and sheet pin)
Currently, if a old label already containing a '/' (or a space) is edited, it is accepted,
but no new not allowed char can be added to the label.
(Previously, a sheet pin label was not filtered)
2018-02-19 18:15:53 +01:00
Jeff Young 04d1d503ee Disallow '/' in labels.
Fixes: lp:1749232
* https://bugs.launchpad.net/kicad/+bug/1749232
2018-02-19 18:08:09 +01:00
Jeff Young 447fd1bf02 Add a start number to annotate.
This also makes the dialog modeless so that one switch between
sheets while annotating to choose the base numbers for each
sheet (assuming they don't like the base number we pick because
of the order of the sheets).

Fixes: lp:1154131
* https://bugs.launchpad.net/kicad/+bug/1154131
2018-02-19 09:32:54 -05:00
Jeff Young d67ceea568 Set current sheet number when only annotating a single sheet.
Fixes: lp:1750096
* https://bugs.launchpad.net/kicad/+bug/1750096
2018-02-18 21:12:07 -05:00
jean-pierre charras af1281433b fix minor compil warning 2018-02-18 21:22:16 +01:00
Jeff Young b3884669cf Proper error reporting for Annotate dialog.
Also fixes:
- forcing the annotation scope to "full schematic" when run
  as a prerequisite to Generate Netlist.

- a long-standing bug where displaying extra items in a dialog
  would mess up the height of the HTML_REPORT_PANEL (becasue
  we were setting the html window's height rather than its
  parent flexgrid.

- initializing the annotation radio buttons to safe values
  (full schematic and keep existing)

Fixes: lp:1750062
* https://bugs.launchpad.net/kicad/+bug/1750062
2018-02-18 15:08:24 -05:00
Maciej Suminski 24fcdb00cc Eagle importer: convert special characters in net names
Convert '!' to '~' to reflect overbar toggling and change '~' to '~~'.
Now it matches the net names in schematics import plugin.
2018-02-17 00:03:28 +01:00
Maciej Suminski b1f456fade Eagle importer: use only global net labels
Local net labels are preceded with sheetpath (even for single sheet
schematics it is '/') causing net name conflicts between schematics and
layout. It can be easily avoided by using exclusively global net
labels, at the cost having uglier schematics.
2018-02-17 00:03:28 +01:00
Maciej Suminski 9e80eff90a Eagle importer: two stage netlist update
After Eagle project import, schematic and board netlists are inconsistent:
footprints do not have sheetpaths assigned, schematics are unannotated.

One can update netlist either by references or timestamps, but timestamps
are empty in pcbnew, and updating by reference must by preceded by
annotation which may lead to broken links between board and schematics
(Eagle does not require references to end with a number, so KiCad annotater
will add numbers in such cases).

To fix the problem, there is a two step netlist update:
- update by reference without the annotation step, to assign
correct sheetpaths to footprints
- update by timestamp, after symbols are annotated, in order to
update references in the board

Fixes: lp:1748502
* https://bugs.launchpad.net/kicad/+bug/1748502
2018-02-16 19:37:23 +01:00
Maciej Suminski 43523a6179 Options for board update KiWay request (MAIL_SCH_UPDATE[_REQUEST])
Board update KiWay request may now contain options in the message
payload:
- "no-annotate": do not enforce annotation
- "quiet-annotate": annotate without displaying a dialog
- "by-reference": update netlist by reference, no dialog displayed
- "by-timestamp": update netlist by timestamp, no dialog displayed
2018-02-16 19:37:23 +01:00
Maciej Suminski 67ccf769c7 Symbol Editor: fix a crash when saving/reverting a library not present in sym-lib-table 2018-02-16 12:13:02 +01:00
Maciej Suminski 3c9a5b0966 Library Editor: make 'Save All' the default save action
Fixes: lp:1748555
* https://bugs.launchpad.net/kicad/+bug/1748555
2018-02-16 11:28:37 +01:00
Jeff Young e7d98f89a1 Fix display of datasheet URLs and shorten them if necessary.
Fixes: lp:1676174
* https://bugs.launchpad.net/kicad/+bug/1676174
2018-02-15 22:01:35 +01:00
Maciej Suminski 570f4dd991 Coverity fixes
CIDs:
174166
174170
174171
2018-02-15 10:27:01 +01:00
jean-pierre charras 4012aa70da Fix a few minor Coverity warnings 2018-02-15 10:16:17 +01:00
jean-pierre charras dded3429fd Add missing hotkey to help menu 2018-02-15 09:23:42 +01:00
Wayne Stambaugh b8c00a0d07 Fix hierarchical schematic file sheet path bug.
Sheet file name paths were not being saved and restored properly under
certain conditions when walking the sheet hierarchy causing schematic
load errors.

Changed debugging output to use wxLogTrace left over from last fix.

Fixes lp:1748401

https://bugs.launchpad.net/kicad/+bug/1748401
2018-02-14 13:45:41 -05:00
Seth Hillbrand fd0b364b91 Eeschema: Ensure all items in a block are deleted
Deleting lines can create new ones when old lines are merged as the
result of a delete operation.  This checks that all items inside a
selection block are deleted before finishing.

Fixes: lp:1748907
* https://bugs.launchpad.net/kicad/+bug/1748907
2018-02-14 13:16:42 -05:00
Jeff Young 4bae901dc8 Centralize zoom-to-fit code.
Fixes a bunch of errors:
- libedit and libbrowser would zoom to bounding box but centre on canvas
- libedit, libbrowser and gerbview didn’t take the scroll bars into account
- pcbnew didn’t take scroll bars into account or apply the 10% margin
- appending a board file would re-centre, but not re-zoom

Fixes: lp:1504302
* https://bugs.launchpad.net/kicad/+bug/1504302
2018-02-13 20:06:03 -05:00
Maciej Suminski ac9fc949bd Code formatting for 013f7b4d 2018-02-13 14:56:11 +01:00
Russell Oliver 34b52c91b7 Add empty eeschema page layout for Eagle schematic import.
Fixes: lp:1729722
* https://bugs.launchpad.net/kicad/+bug/1729722
2018-02-13 14:56:11 +01:00
jean-pierre charras a1af13f34d replace '%s' by \"%s\" in a few sentences to be consistent with all other messages 2018-02-13 10:22:05 +01:00
Maciej Suminski c9d9cec6ad LIB_MANAGER: exception handlers display error messages 2018-02-13 08:50:51 +01:00
Jeff Young ac09cfaef4 Wire up <return> for eeschema find dialog.
Fixes: lp:1749026
* https://bugs.launchpad.net/kicad/+bug/1749026
2018-02-12 19:41:34 -05:00
Wayne Stambaugh 01faca2799 Fix release build error caused by previous commit. 2018-02-12 13:36:03 -05:00
Jeff Young 9d26253b2c Don't rely on live pointers in search data.
Try as you might to keep them fresh, there's no gaurantee.
Instead, just treat them as weak references and search the
existing items for a pointer-value match.

This also allows us to remove some code which kept recycling
the search position back to the start ever time a replace
was done.

Fixes: lp:1559258
* https://bugs.launchpad.net/kicad/+bug/1559258
2018-02-12 11:46:39 -05:00
Russell Oliver e340e8a838 Eagle Schematic Import: Label Placement fix.
Extra labels to preserve eagle named nets feature are now placed at the
end of a wire segment instead of the middle of a wire. Prevents a label
being placed on crossing wires that are not connected by a junction
resulting in an incorrent netlist.
2018-02-12 15:35:28 +01:00
Jeff Young 0bbf961881 Clean up Cancel vs Close buttons in dialogs.
Many had already been fixed but weren't working on Mac because
of the DIALOG_SHIM hack (now fixed).  Others hadn't been updated
yet.  Also includes some cleanup for elipses in buttons and
layout.

Fixes: lp:1748506
* https://bugs.launchpad.net/kicad/+bug/1748506
2018-02-10 17:53:12 -05:00
Jeff Young 1afbfad44a Use "..." uniformly in menus.
See the bug report for some wording changes and a couple of
menu restructurings that were also cleaned up.

Fixes: lp:1597827
* https://bugs.launchpad.net/kicad/+bug/1597827
2018-02-10 17:32:28 -05:00
jean-pierre charras dba198e576 Fix code after renaming files
Change class names according to the new name of the main dialog
2018-02-09 17:36:54 +01:00
jean-pierre charras 35a0688bf7 rename dialog_bom_editor* files to dialog_fields_editor_global*
rename also associated files
2018-02-09 17:36:52 +01:00
Kristoffer Ödmark 8f4a954236 Differ the dialog text for when choosing power-symbols and all symbols 2018-02-09 11:00:32 +01:00
Maciej Suminski 2c3a7c9dc4 CMP_TREE_MODEL: Reset SearchTextNormalized flag when a node is updated 2018-02-09 11:00:32 +01:00
jean-pierre charras 07fff6ed35 Eeschema, choose component dialog: remember the relative size of the component tree and the symbol viewer canvas during a session 2018-02-09 08:08:14 +01:00
Michael Geselbracht b04b1dcfb5 Update fields: Add option to omit empty fields
Fixes lp:1747405

https://bugs.launchpad.net/kicad/+bug/1747405
2018-02-08 21:05:10 -05:00
Jeff Young 6c61a46721 Rationalize label orientations for dialog display.
Fixes: lp:593795
* https://bugs.launchpad.net/kicad/+bug/593795
2018-02-08 20:16:26 -05:00
Jeff Young 17ce87a7a5 Add library descriptions to component tree.
Fixes: lp:1747547
* https://bugs.launchpad.net/kicad/+bug/1747547
2018-02-07 08:45:33 +01:00
Chris Pavlina d1a45d1476 Remove icon scaling diagnostic from eeschema 2018-02-05 19:49:07 -07:00
Wayne Stambaugh 00749af914 Eeschema: fix using subpaths in sheets.
Fix double path name issue when using sheet file name paths that differ
from the project path.

This fix also allows for nesting schematics in subfolder in multiple
root paths.

Fixes lp:1745109
https://bugs.launchpad.net/bugs/1745109

Fixes lp:1735982
https://bugs.launchpad.net/bugs/1735982
2018-02-05 17:07:33 -05:00
Maciej Suminski 351a8d72b8 Better test whether a symbol library is saved to its original file
File names can be reliable compared only after normalization. The
problem is the easiest to observe on Windows, where one can use slash or
backslash as path separator, so even though C:/file.txt and C:\file.txt
pointed to the same file - simple string comparison would indicate they
are different files.

Fixes: lp:1744724
* https://bugs.launchpad.net/kicad/+bug/1744724
2018-02-05 17:04:10 +01:00
jean-pierre charras 821668d96c rename class_collector.h to collector.h 2018-02-04 10:49:37 +01:00
Seth Hillbrand fddd5abef1 Merges a line after manually removing its junction.
Fixes: lp:1746998
* https://bugs.launchpad.net/kicad/+bug/1746998
2018-02-03 10:50:10 +01:00
Maciej Suminski 0668cd9d4c Symbol Library Editor: save sym-lib-table only if it had been modified 2018-01-31 10:46:39 +01:00
jean-pierre charras 39b4afecfa fix code after file renaming 2018-01-31 09:24:02 +01:00
Jeff Young 99ad5cf394 More performance optimizations for symbol libraries
1) don't call UI-level LIB_PIN routines when reading library --
not only are they a performance hit, they set the modified flag
too
2) limit progress dialog updating to 15 times a second (this
had crept back up to 31% of the time spent loading libraries)

Fixes: lp:1734773
* https://bugs.launchpad.net/kicad/+bug/1734773
2018-01-30 10:31:51 -05:00
jean-pierre charras 8022f1cc01 fix code after renamin files 2018-01-30 11:49:51 +01:00
jean-pierre charras 833d6223a0 rename files 2018-01-30 11:08:03 +01:00
jean-pierre charras 2bc9cac234 rename files 2018-01-30 10:51:55 +01:00
jean-pierre charras 1f88b466de move SCH_EDIT_FRAME methods from netlist.cpp to netform.cpp 2018-01-30 10:45:35 +01:00
jean-pierre charras 795a36c9fe Fix code after renaming files, and a bit of code cleanup (remove useless includes and multiple includes of the same files) 2018-01-30 09:57:25 +01:00
jean-pierre charras 87a437c26e rename files in eeschema 2018-01-30 09:57:22 +01:00
jean-pierre charras 5d72aebd22 Fix code after renaming files 2018-01-29 16:40:22 +01:00
jean-pierre charras d0754acf00 Fix code after renaming files 2018-01-29 11:37:29 +01:00
jean-pierre charras d44494beda Update code after file renaming 2018-01-29 09:39:49 +01:00
jean-pierre charras 4c5bd01887 Rename a few files 2018-01-28 22:02:31 +01:00
jean-pierre charras e499d337d8 rename files: update filenames in sources 2018-01-28 19:12:26 +01:00
Jeff Young 899afa1e90 Reinstate OSX cursor shape selection
Mark it as not supported in Legacy graphics.

Fixes: lp:1745097
* https://bugs.launchpad.net/kicad/+bug/1745097
2018-01-28 10:47:20 -05:00
Martin Sivak d5cdd78062 eeschema: keystroke zoom should obey disabled centering
Keystroke zoom (F1/F2) always centered the screen, because it
was handled as ID_POPUP_ZOOM_IN event. Mousewheel scrolling
was ok, because it is handled using different event based
on the configuration.

This patch introduces special event ids for keystroke
zooming that are then properly translated to either
ID_POPUP_ZOOM_IN or ID_OFFCENTER_ZOOM_IN depending
on the configuration.

The same issue is fixed for legacy canvas pcbnew.

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

Signed-off-by: Martin Sivak <mars@montik.net>
2018-01-27 20:20:32 -05:00
Jeff Young 7a28f3d4cf Implement undo/redo for origins in legacy
PICKED_ITEMS_LIST knows the architecture of the undo commands so
that it can delete those ITEMs which it owns.  This represents poor
encapsulation so instead of adding yet another case, I added a
UR_TRANSIENT item flag which is set by callers whenever they create
new objects to “give to” the undo/redo stack.  This allowed some
cleanup of other code, but cleaning up UR_DELETE and UR_WIRE_IMAGE
will be a bigger task and have to wait for another day.

Fixes: lp:1542018
* https://bugs.launchpad.net/kicad/+bug/1542018
2018-01-27 19:51:44 -05:00
Jeff Young f88c4ccb02 Add an Edit button to the Symbol Properties aliases list
Fixes: lp:1248451
* https://bugs.launchpad.net/kicad/+bug/1248451
2018-01-27 18:57:33 -05:00
Jeff Young 829c236437 Symbol library load performance enhancements.
1) Edit Symbol gets similar fix as Place Symbol
2) progress dialog updating reduced to once every 50ms
3) SearchText gets lazy normalization
4) TypeNames get lazy translation
5) default fieldNames get translated a single time per language change

These fixes reduce first-load-time of both Edit Symbol and Place Symbol
by about 2/3, and second-load-time of Edit Symbol to near-instantaneous.
2018-01-27 08:29:43 -05:00
jean-pierre charras 54ebd45749 DIALOG_EDIT_COMPONENT_IN_SCHEMATIC: ensure mandatory field names are always correctly translated after changing the locale. 2018-01-26 20:21:12 +01:00
Tomasz Włostowski 7a6e3bf3ed eeschema: remember last browsed directory in the Symbol Lib Table dialog 2018-01-26 18:39:09 +01:00
jean-pierre charras d54418c14a Fix minor compil warnings 2018-01-26 09:35:22 +01:00
ludovic léau-mercier 0d532b43de Support .title directive in spice netlist exporter
Spice netlist exporter processes all texts on the exported schematic
sheet to find spice directives and include them in the output file.
By default it also added ".title KiCad schematic" in the first line, so
if there was another .title directive in the exported schematic sheet,
the generated file would contain two .title directives.

This patch looks for .title directive and when one is found - it uses
the specified title in the first line.
2018-01-26 08:57:35 +01:00
Maciej Suminski 8e18aea11d New ERC rule verifying if all units of a component use the same footprint 2018-01-25 12:19:41 +01:00
Maciej Suminski 0ef785981b Add pin numbering exception to sync pin edit mode description 2018-01-25 12:08:29 +01:00
Maciej Suminski 6c32b6f955 Pin edit coupling: renamed and changed the description
This commit aims at making the pin edit coupling easier to understand.
It renames the mode to 'synchronized pin edit', shortens the description
and inverts the logic to avoid double negation.

To make the code clearer, two items have their name changed to fit the
new description:
- m_editPinsSeparately       -> m_syncPinEdit
- ID_LIBEDIT_EDIT_PIN_BY_PIN -> ID_LIBEDIT_SYNC_PIN_EDIT
2018-01-25 11:45:34 +01:00
Seth Hillbrand 7a2d9dff62 Sets additional conditions for when a wire is trimmed
This adds a set of conditions that will prevent a wire from being
automatically trimmed.  Wires that are currently being moved or are
newly created or are explicitly avoided will not be removed.  This also
adds a function to set a flag on items in a block.

Fixes: lp:1744632
* https://bugs.launchpad.net/kicad/+bug/1744632
2018-01-24 19:47:14 -05:00
Wayne Stambaugh 2b460bc1ff Eeschema: improve alias load performance.
Don't use wxFileName == operator when comparing cache file name.  There
is a lot of overhead the wxFileName == operator that is not necessary
so just do a comparison with the original string used to create the
cache.
2018-01-24 19:37:07 -05:00
Jeff Young eb7ecf1dfd Load each symbol library atomically for better performance. 2018-01-24 19:21:56 -05:00
Maciej Suminski a99d0c44e1 Code comments 2018-01-24 15:18:19 +01:00
jean-pierre charras 270a63daac DRAWSEGMENT, S_POLYGON shape: remove useless copies or conversion to std::vector<wxPoint> of SHPE_POLY_SET polygon shape.
Rename GetPolyPoint() to BuildPolyPointsList(), because GetPolyPoint() looks like an accessor, but it is not an accessor.
(Using it as accessor can creates a *very long calculation time* for very basic access to polygon vertices)

Fixes: lp:1745050
https://bugs.launchpad.net/kicad/+bug/1745050
2018-01-24 14:22:43 +01:00
Jeff Young c6d0075076 Keep value, footprint and datasheet in sync in multi-unit parts
Fixes: lp:1731743
* https://bugs.launchpad.net/kicad/+bug/1731743
2018-01-23 11:46:27 -05:00
Jeff Young 76885169c4 Fix delete issues in symbol aliases list in libedit.
The alias list now displays the user model (multiple aliases *of*
a root part, rather than a collection of names *including* the
root part).  This simplified the error detection logic, fixing
the first bug in the bug report.

Updating the part in the library is now done uniformly on OK
(which was the second bug in the bug report).

Fixes: lp:1744656
* https://bugs.launchpad.net/kicad/+bug/1744656
2018-01-23 14:49:20 +01:00
Maciej Suminski cbf433fe04 Symbol Library Editor: save anchor position when modified
OnModify() stores the edited symbol in its edit buffer, therefore it has
to be called after a modification.

Fixes: lp:1744540
* https://bugs.launchpad.net/kicad/+bug/1744540
2018-01-23 14:04:31 +01:00
Maciej Suminski 2d3ef0fa6e Symbol Editor: Remove a redundant separator from symbol context menu 2018-01-23 12:19:19 +01:00
Maciej Suminski 6b9a286a85 Fix crash when a renamed part is saved
The crash happened when during rename operation, when the original part
buffer has been marked as deleted, but its memory was not yet freed. The
renamed part was still using the original SCH_SCREEN object, which was
freed together with the original part buffer.
2018-01-22 17:46:30 +01:00
jean-pierre charras 6322c90c50 Symbol editor: Fix incorrect pin edition coupling for non interchangeable multi-units symbols.
Fixes: lp:1744680
https://bugs.launchpad.net/kicad/+bug/1744680
2018-01-22 13:33:24 +01:00
Jeff Young 2201482e47 Add '*' to modified files in libedit cmptree, and change highlighting.
The highlight colour on some platforms (OSX, for instance)
renders nearly invisible against a white background.  However,
wxWidgets doesn't handle background colours on OSX and GTK+.
A separate commit to the new kicad/wxWidgets fork fixes OSX,
and we continue to use the old highlighting on GTK+

Fixes: lp:1741719
* https://bugs.launchpad.net/kicad/+bug/1741719
2018-01-22 10:37:06 +01:00
Jeff Young 6b9866de8b Sort pins in pin-table.
Fixes: lp:1744509
* https://bugs.launchpad.net/kicad/+bug/1744509
2018-01-21 08:47:26 +01:00
Jeff Young cba430deab Fix undo/redo and revert for libedit name changes and aliases
Three interrelated issues:
1) Implement an undo/redo type for renames so that we know to delete
the old lib entry and add a new lib entry
2) When doing so (for the undo/redo OR the original edit), we must
make a copy of the 'original' LIB_PART which is used for revert, and
hand it to the new lib entry
3) When comparing a modified component tree item with the current item
we must also check for aliases.

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

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

Fixes: lp:1744373
* https://bugs.launchpad.net/kicad/+bug/1744373
2018-01-20 11:20:22 +01:00
jean-pierre charras 448dbf476c Dialog symbol lib table editor: fix incorrect tool tips
Fixes: lp:1744416
https://bugs.launchpad.net/kicad/+bug/1744416
2018-01-20 10:47:19 +01:00
jean-pierre charras d4dbdcd638 Symbol editor, Pin table editor: always display a icon in Pin Type column
At least on Linux, if a null icon is used as icon in Pin Type column, other icons are not
displayed. So the workaround is to use a neutral icon when a specific icon cannot be used
(i.e. when pins are grouped)

Fixes: lp:1559542
https://bugs.launchpad.net/kicad/+bug/1559542
2018-01-20 09:59:15 +01:00
jean-pierre charras afeaf909fa Better error message 2018-01-19 11:51:01 +01:00
Jon Evans 10b635ffe2 Clear autoplaced flag when modifiying field orientation/justification
Fixes: lp:1743893
* https://bugs.launchpad.net/kicad/+bug/1743893
2018-01-19 10:09:00 +01:00
Jeff Young 959767c09f Don't warp mouse when context menu was cancelled.
Fixes: lp:1674199
* https://bugs.launchpad.net/kicad/+bug/1674199
2018-01-18 13:43:24 -05:00
Maciej Suminski 8721f7ed70 Changed remaining occurences of 'part' to 'symbol' in the symbol editor 2018-01-18 11:24:02 +01:00
Jeff Young 17e6720bc9 Implement undo for eeschema's "Import existing drawings"
Fixes: lp:1522189
* https://bugs.launchpad.net/kicad/+bug/1522189
2018-01-17 15:30:36 -05:00
Seth Hillbrand 2fa5c723d8 Don't cleanup schematic when symbols are rescued.
Schematic cleanup only makes sense after the libraries are fully updated
and loaded.  Before pin caching, this was a minor difference but once we
needed to update pin caches, schematic cleanup can remove junctions from
pin-wire connections incorrectly.

Instead, we use the global OpenProjectFiles() schematic cleanup call to
be sufficient and not call a second time, prior to all libraries being
rescued and loaded.

Fixes: lp:1743148
* https://bugs.launchpad.net/kicad/+bug/1743148
2018-01-17 12:53:38 -05:00
Maciej Suminski 60963fe2fc Fixes for 590cac9d
The original patch did properly recognize the case when all transient
source definition fields are empty, which is perfectly valid.
2018-01-17 10:37:57 +01:00
Dan Weatherill 590cac9d55 Fix transient SPICE source field check logic
Fixes: lp:1743486
https://bugs.launchpad.net/kicad/+bug/1743486
2018-01-17 10:36:35 +01:00
Maciej Suminski ac1771a9f0 Handle block selection removal of libraries in SYMBOL_LIB_TABLE dialog
Fixes: lp:1741543
* https://bugs.launchpad.net/kicad/+bug/1741543
2018-01-17 09:59:48 +01:00
jean-pierre charras 2e79b93b99 Eeschema: fix issue (2 tools not working in left vertical toolbar) created by commit 7e6a6540c8 2018-01-16 19:39:31 +01:00