Commit Graph

3582 Commits

Author SHA1 Message Date
jean-pierre charras 7848c3acf3 Fix cross-probing issue (not working) when a net name or a pin name contains a space. 2019-01-24 16:59:34 +01:00
jean-pierre charras 752cc43fb8 Fix 2 minor wxWidgets alerts. 2019-01-21 19:53:40 +01:00
joel-bertrand-JKB 35dc387fc6 Fix duplicate directives in Spice netlist inside .control ... .endc
Fixes: lp:1812082
https://bugs.launchpad.net/kicad/+bug/1812082
2019-01-16 19:54:55 +01:00
Wayne Stambaugh 45a3d86d36 Eeschema: fix schematic symbol parsing bug.
Schematic symbol library link names are unquoted strings that can
contain non-ascii characters which breaks the parser.  Converting
the line to uft-8 before breaking the string into tokens resolves
the issue.

(cherry picked from commit b8de4e73bf)
2019-01-08 12:26:21 -05:00
Wayne Stambaugh 9f1b6680a2 Eeschema: fix library symbol pin definition parsing bug.
Pin names are unquoted strings that can contain non-ascii characters
which breaks the parser.  Converting the line to uft-8 before breaking
the string into tokens resolves the issue.

(cherry picked from commit 742961119d)
2019-01-08 12:25:24 -05:00
Wayne Stambaugh 385eb49cb2 Fix schematic append clear annotation bug.
Clear the annotation of only the appended schematic and any sheets in it's
hierarchy.  Do not clear the annotation of the symbols in the target sheet.

Fixes lp:1805695

https://bugs.launchpad.net/kicad/+bug/1805695

(cherry picked from commit 07ebc4df14)
2019-01-08 11:55:05 -05:00
Wayne Stambaugh 61b94c8c2c Eeschema: fix UTF8 character handling bug in legacy parser.
Iterating over unquoted strings as ASCII8 fails when ' ' character is
not the LSB of a UTF8 string with wide characters.  Change parsing method
for unquoted strings to convert the entire line as UTF8 and then use
wxStringTokenizer to break the line into tokens at the ' ' characters.

Fixes lp:1806206

https://bugs.launchpad.net/kicad/+bug/1806206

(cherry picked from commit a61a51f26e)
2019-01-08 11:54:48 -05:00
jean-pierre charras 93caff0ac1 Remove overzealous assert. 2018-12-16 09:30:30 +01:00
jean-pierre charras bc8739f930 Eeschema: fix incorrect parsing of line color (r v b values). Only the R and V were read, the parsing was stopping before reading the B value. 2018-12-09 18:16:50 +01:00
Maciej Suminski 805bb3160f Fix for dark mode on macOS Mojave
Thanks to Scott Rapson and Justace Clutter for the solution.

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

(cherry picked from commit 766156ed87)
2018-12-07 14:29:22 +01:00
Jeff Young 187d7729ff Don't go to '-' numbering till the range reaches 3.
(cherry picked from commit c4ff17d3ec)
2018-12-03 18:49:03 +00:00
Jeff Young 940b08ab85 Sort references before removing duplicates.
std::unique only works within consecutive blocks, so the list must
be sorted first.  (We need it sorted in the end anyway, so no
big deal.)

(cherry picked from commit 90df7a8b22)
2018-12-03 18:48:37 +00:00
Jeff Young e8c8bf8d11 Fix range-based reference formatter.
Fixes: lp:1792483
* https://bugs.launchpad.net/kicad/+bug/1792483

(cherry picked from commit 243b05b2c3)
2018-12-03 18:48:06 +00:00
Jeff Young 03132cabee Make sure original part record always has the write library nickname.
Fixes: lp:1804293
* https://bugs.launchpad.net/kicad/+bug/1804293

(cherry picked from commit 023a445e9f)
2018-11-21 23:24:13 +00:00
Jeff Young daf4985a60 Don't trim entire wires.
Fixes: lp:1804297
* https://bugs.launchpad.net/kicad/+bug/1804297

(cherry picked from commit ae6989f3a1)
2018-11-20 22:03:04 +00:00
Maciej Suminski dd39599903 Link eeschema with ngspice DLL
Adds a link-time dependency for libngspice, so that other tools may
detect ngspice as a KiCad dependency.

The library is still loaded with dlopen() as it gives a way to reload it
in case of problems. The DLL name is recognized during CMake
configuration and used to load the library at runtime.
2018-10-30 08:40:29 +01:00
Stefan Brüns 36bb92f844 Use fixed version for libngspice.so.0
CanonicalizeName only adds the lib prefix and .so suffix, so loading
libngspice.so fails until the development package is installed.
MAC/Windows code paths lookup soversion 0 of ngspice as well, as this
is the only compatible version.
2018-10-27 10:57:08 +02:00
Michael Kavanagh 49753d9dad Update Eeschema BOM dialog html help text
Now links to relevant section in stable eeschema docs.

Fixes: lp:1798248
https://bugs.launchpad.net/kicad/+bug/1798248
2018-10-22 13:21:38 -04:00
Maciej Suminski 3d9e6867cf Spice netlist exporter: handle multiline directives
Fixes: lp:1797937
* https://bugs.launchpad.net/kicad/+bug/1797937

(cherry-picked from 9757107b)
2018-10-19 17:34:14 +02:00
jean-pierre charras bd1b15ded7 Eeschema, spice netlist exporter: fix an issue that converted spice string commands to lowercase.
Therefore, it can breaks some commands, especially filenames.

Partial fix of bug 1797937.

(cherry-picked from 8f9b0f02)
2018-10-19 17:00:11 +02:00
Seth Hillbrand 234b01905d eeschema: fix mistaken wire removal bug
The wire between two points should not be trimmed if it starts or ends
on one of the component's connection points.

(cherry picked from commit d2906f7975)
2018-10-08 11:35:12 -07:00
Wayne Stambaugh 876232aa7a Fix LIB_ID illegal character tests.
The '/' and ':' are reserved and cannot be used in symbol or footprint
names.  They will cause the LIB_ID parser and formatter to fail.  While
it seems like they should be legal in symbol alias names, they will
trigger a symbol rescue the next time the schematic is loaded.

Use ID_SCH as in the Eagle schematic plugin rather than ID_ALIAS to
ensure symbol names do not need rescued the next time the schematic is
opened.

Remove ID_ALIAS since the rules for alias names are the same as the
rules for symbol names.  Otherwise, allowing '/' and ':' in alias names
will force a symbol rescue on the next schematic load.

Fixes lp:1795600

https://bugs.launchpad.net/kicad/+bug/1795600
2018-10-07 15:35:16 -04:00
Jeff Young f56ea6bf3c Don't assume GetFlags() != 0 means it's being edited.
It could just mean it's selected, highlighted or brightened.

Fixes: lp:1794624
* https://bugs.launchpad.net/kicad/+bug/1794624
2018-09-27 22:17:32 +01:00
Jeff Young 1e223b9027 Don't use nullprt for a dialog's parent.
Fixes: lp:1791561
* https://bugs.launchpad.net/kicad/+bug/1791561

(cherry picked from commit 3f23e9ac46)
2018-09-25 04:41:42 -07:00
Seth Hillbrand 9831a14ef3 eeschema: Re-add auto-wire removal
Somewhere during v5 rc cycle, the trimming of wires laid over simple
components was removed.  The wires were still removed as soon as the
user moved the component again.  This corrects the first behavior to
intended action for simple components.

Fixes: lp:1794019
* https://bugs.launchpad.net/kicad/+bug/1794019
2018-09-24 06:38:52 -07:00
Wayne Stambaugh 3f58dce1de Eeschema: fix yet another lock file issues.
Reset lock file when saving a schematic sheet to a different file name.
This prevents a file is already open error from being displayed when
opening the original file.

Fixes lp:1788507

https://bugs.launchpad.net/kicad/+bug/1788507
2018-09-24 09:00:11 -04:00
Maciej Suminski 4fcd80eda1 Spice simulator: change gain units to dBV
(cherry-picked from commit 85ef0584)
2018-09-22 20:08:13 +02:00
Wayne Stambaugh c722ea7a0c Eeschema: fix minor bug in block handler.
Under certain conditions, it was possible for the block handler to be
entered with no mouse capture callback which would raise a rather
cryptic error message to the user.  This should have always been an
assertion so users will not see this issue in release builds.

Fixes lp:1791839

https://bugs.launchpad.net/kicad/+bug/1791839
2018-09-19 15:34:34 -04:00
Wayne Stambaugh 079d6b2009 Eeschema, fix broken instances of symbols in rescue dialog.
The symbol library table rescue candidate was only using the item name
of the library ID object which was being compared to the fully formatted
library ID causing a comparison failure so no instances of any rescued
symbols was shown in the dialog.

Fixes lp:1791805

https://bugs.launchpad.net/kicad/+bug/1791805
2018-09-14 17:43:22 -04:00
Maciej Suminski a149960faa Eagle SCH importer: fix slash characters when fixing symbol names
Even though slash is a valid character in symbol names, it is a revision
separator, but is not the case with Eagle symbol names.

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

(cherry-picked from commit 2c217499)
2018-09-12 10:54:58 +02:00
Maciej Suminski e9b1552b16 Spice netlist exporter: make directives case insensitive, extra comments
(cherry-picked from commit 4a57541b)
2018-09-10 14:21:27 +02:00
Joël Bertrand 27b88be61f Spice netlist exporter: handle .control .. .endc blocks
Spice may include a list of directives that are wrapped with
.control and .endc. Such directives do not have a dot prefix, so
they need to be handled in a special way.

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

(cherry-picked from commit 36f2eb11)
2018-09-10 14:21:27 +02:00
jean-pierre charras 7e8c5b9574 Eeschema: fix incorrect/incomplete annotation clearing in duplicate and paste block (happens in complex hierarchy) 2018-09-09 09:19:22 +02:00
jean-pierre charras 500abd0ac4 Eeschema: fix incorrect references clearing for shared sheet paths.
Previously, when creating a new instance of a sheet, the full set of references
was cleared.
Moreover, if this sheet has sub-sheets, the annotation was incorrectly handled

Now only (and all) new sheet path(s) created have a reference cleared, as expected.
(new sheet paths can be more than one, if the new instance of the sheet has sub-sheets)

Fixes: lp:1789048
https://bugs.launchpad.net/kicad/+bug/1789048
2018-09-09 09:19:22 +02:00
Seth Hillbrand 5e9b4dd6a5 eeschema: Set images to draw first in eeschema
Bitmaps in eeschema are mainly used for referencing and data.  Having
them between functional items obscures the elements.  This places the
images in the background for eeschema as a partial fix for lp:1787404

This commit should not be picked into 5.1 as the canvas changes.
2018-09-06 14:10:11 -07:00
Seth Hillbrand 1f60d8fdbf eeschema: Only allow dragging of draggable items
When expanding the drag item to allow corners, we accidentally picked up
other items in the list.  This limits the items that can be dragged to
only those that are explicitly in the draggable list.

A side effect of this commit is that when converting from move to drag
(with tab), items not in the draggable list will be left in place.

Fixes: lp:1787966
* https://bugs.launchpad.net/kicad/+bug/1787966
2018-09-06 13:42:01 -07:00
jean-pierre charras b7b125d83c Eeschema: Fix incorrect parsing of old schematic files (version 2) for HLabels and GLabels 2018-09-03 19:52:22 +02:00
Seth Hillbrand 6754aa8a74 eeschema: Close ERC before placing components
We have a dialog shim that raises the ERC dialog in front of the
schematic frame, which is useful for keeping the ERC dialog visible
during debugging.  But mouse move events do not pass through to the
schematic, resulting in a captured mouse pointer but no drawing updates.

As a work-around we close the ERC dialog while placing new components.
Previous ERC data still exist when the window is launched again.

Fixes: lp:1779851
* https://bugs.launchpad.net/kicad/+bug/1779851
2018-08-28 16:03:02 -07:00
Jeff Young e424f29bbb Don't inadvertantly strip hotkey off Save All Libraries.
Fixes: lp:1786066
* https://bugs.launchpad.net/kicad/+bug/1786066
2018-08-26 00:32:38 +01:00
jean-pierre charras 0f78fe5a5a Fix a minor wxWidget alert. 2018-08-25 10:38:13 +02:00
jean-pierre charras 333ba4b9a2 Eeschema: fix an assert ( "meOwner" failed in DeleteAll() ) when appending a sheet from an other project to the schematic.
It was only a overzealous (in this case) assert, with no issue.
The fix avoid calling DeleteAll() when there is nothing to delete.

Fixes: lp:1787810
https://bugs.launchpad.net/kicad/+bug/1787810
2018-08-25 10:38:13 +02:00
Jeff Young 7e2e39ce30 Handle separate parsing rules for ID_SCH and ID_PCB.
This removes the existing constructors so that all parsing must
be explicit and callers are made aware that they need to think
about illegal characters, malformed ids, etc.

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

Fixes: lp:1786819
* https://bugs.launchpad.net/kicad/+bug/1786819
2018-08-24 23:57:19 +01:00
Ronnie Gaensli 182b8a32df eeschema: fix dangling pin marker after adding NoConnect
Fixes: lp:1787858
* https://bugs.launchpad.net/kicad/+bug/1787858
2018-08-19 19:47:21 -07:00
Maciej Suminski ca1f50a023 Spice simulator: search each line of a text field for a Spice directive
Fixes: lp:1786119
* https://bugs.launchpad.net/kicad/+bug/1786119

(cherry-picked from commit d5ee3296)
2018-08-14 10:27:07 +02:00
Maciej Suminski 626f5ac45a Spice simulator: prevent double quoting library file names
Fixes: lp:1786559
* https://bugs.launchpad.net/kicad/+bug/1786559

(cherry-picked from commit f82b839d)
2018-08-14 09:47:24 +02:00
Seth Hillbrand 0e946dad1a Eagle: Fix NULL-dereference on malformed Eagle files
Eagle files that are edited may be missing required data.  While we do
not need to handle these files, we do need to prevent segfaults in KiCad
when reading them.
2018-08-09 14:57:50 -07:00
Jeff Young 26cbdbf103 Add Edit context menu item for EEschema graphic lines.
Fixes: lp:1779554
* https://bugs.launchpad.net/kicad/+bug/1779554

(cherry picked from commit 02b29ba)

(cherry picked from commit 7dcc8e346f)
2018-08-06 13:56:56 +01:00
Jeff Young f163d9ff2a Fix bug with duplicate columns in Edit Symbol Fields.
(cherry picked from commit 01c5bdf)
2018-08-06 13:55:59 +01:00
jean-pierre charras 57c3e98f8c Fix a wxWidgets minor alert 2018-08-03 09:28:30 +02:00
jean-pierre charras d2aa976017 Fix many wxWidgets alerts, to avoid useless bug reports when kicad is compiled in Debug mode 2018-07-31 11:41:47 +02:00