Commit Graph

17104 Commits

Author SHA1 Message Date
jean-pierre charras 26ebf3c961 Fix ZONE_CONTAINER ctor issue: incorrect net info setting.
In ZONE_CONTAINER( ZONE_CONTAINER& aOther ), the net info was set before zone type and layer were set.
So the net info was always set to ORPHAN net, instead of set to aOther net info.
Especially, it broke undo/redo function.

Fixes: lp:1840727
https://bugs.launchpad.net/kicad/+bug/1840727
2019-10-15 13:41:49 +02:00
jean-pierre charras 23e09d3de7 some other WXDEBUG replacement 2019-10-14 12:38:52 +02:00
jean-pierre charras d77ba30a95 Replace __WXDEBUG__ (improperly used) by DEBUG in some #define.
__WXDEBUG__ comes from a build option of wxWidgets,
and is not related to a Debug versus Release Kicad build.
2019-10-14 11:17:38 +02:00
Seth Hillbrand e291576c38 plotting: When aggregating areas, heal first
The fracture routine introduces degenerate points that are healed by the
Clipper Polygon simplify command.  This is normally fine but in the case
of hatched areas, there are thousands of degenerate points, which is
very slow in Clipper.  Healing the degenerate points first before
simplifying and fracturing is much faster.

Fixes: lp:1847764
* https://bugs.launchpad.net/kicad/+bug/1847764
2019-10-12 20:14:57 -07:00
jean-pierre charras 337244d423 Gerbview: displays aperture attribute value (TA.attribute) for Regions (polygons) having no dcode 2019-10-12 14:04:41 +02:00
jean-pierre charras a18d3cca6e Pcbnew, zone filler: Ensure hatch pattern thickness bigger than zone minimal width (one micron bigger).
This margin is mandatory to avoid incorrect polygons in Gerber files:
due to the fact Gerber units can be 10 nm (and Gerbview internal unit is also 10nm), valid polygons
can be converted to non valid (self intersecting for instance) by coordinates truncation.
This is a known problem in Gerber files (not specific to Gerber format)

Fixes: lp:1847737
https://bugs.launchpad.net/kicad/+bug/1847737
2019-10-12 11:12:27 +02:00
jean-pierre charras 4b2d801fec Gerber file export: avoid duplicate corner when creating polygons (regions in Gerber dialect)
Fixes: lp:1847714
https://bugs.launchpad.net/kicad/+bug/1847714
2019-10-11 20:59:23 +02:00
Seth Hillbrand 0f8a1c22ad pcbnew: Snap during routing needs active parent
The router items may not yet have a board item parent.  In this case,
the reference to the parent needs to be guarded before dereferencing.

Fixes: lp:1847717
* https://bugs.launchpad.net/kicad/+bug/1847717
2019-10-11 09:16:26 -07:00
jean-pierre charras a43b00b666 Gerber job file Fix incorrect .gbrjob file format when the board stackup is not yet initialized.
Fixes: lp:1847636
https://bugs.launchpad.net/kicad/+bug/1847636
2019-10-10 21:16:45 +02:00
jean-pierre charras 967b9d4a97 Gencad export: fix an issue in hash_eda calculation, that can generate the same hash for 2 different footprints.
Therefore, for some footprints, the right footprint was not associated to the component.
The hash calculation was using a XOR to combine 2 sub hash values.
This is not a strong way to combine these hash values.
They are now added. Looks better to identify similar and different footprints.

Fixes: lp:1847575
https://bugs.launchpad.net/kicad/+bug/1847575
2019-10-10 20:18:48 +02:00
Seth Hillbrand cecfeea947 pcbnew: Remove snapping to hidden items
Items and layers that are hidden in the view should not be used as snap
points.  This happens in multiple locations:
1) Grid Helper for normal tools
2) TOOL_BASE::snapToItem for router

Resolves KiPro Issue #116

Fixes: lp:1833128
* https://bugs.launchpad.net/kicad/+bug/1833128
2019-10-10 09:37:25 -07:00
jean-pierre charras 89e9857f3d Fp editor, DIALOG_FOOTPRINT_FP_EDITOR: fix a very annoying issue: the value field was copuled to the fp name.
Unlike schematic symbols, the value field and the footprint name are 2 different fields.
So coupling these fields in the DIALOG_FOOTPRINT_FP_EDITOR dialog created serious issues.

Fixes: lp:1846533
https://bugs.launchpad.net/kicad/+bug/1846533
2019-10-09 18:57:40 +02:00
jean-pierre charras c7d636d560 Gerber file generation: fix incorrect aperFunction attribute for graphic items on edge cut layer.
Was NonConductor. Must be Profile.
2019-10-09 15:46:35 +02:00
jean-pierre charras 187cd5aa09 Add missing info in compil_options_symbols.txt 2019-10-08 08:07:29 +02:00
Ian McInerney 58d4a8bb4a pcbnew: Don't reinitialize the router tool in an action
Calling Init() in an action routine will reset the router
settings to the state they were in when first starting pcbnew.
The Init() function is automatically called when the tool is created.

Fixes: lp:1843810
* https://bugs.launchpad.net/kicad/+bug/1843810
2019-10-07 16:07:05 -04:00
Jeff Young 890e1c9ea0 Be more careful about EOF processing when reading netlist.
Fixes: lp:1845848
* https://bugs.launchpad.net/kicad/+bug/1845848
2019-10-07 12:53:32 +01:00
jean-pierre charras 34b26a0ac7 Add KICAD_USE_FONT_REDUCED_SET (default OFF) to build options.
It allow using the previous font set without CJK.
The new font (with CJK) is very large (10x), and can create (on Opengl) out of memory issues
with some graphic cards.
2019-10-07 09:50:24 +02:00
Ian McInerney bdf7fb9e95 Update building documentation with new debugging options 2019-10-07 08:54:55 +02:00
Ian McInerney a1d3f3486e cvpcb: Fix some issues
* ESC no longer closed the window since it didn't properly generate
  the close event
* Copy/Cut from a context menu did not work due to a focus-loss issue
* Add better error handling for the copy/cut/paste actions to prevent
  text that isn't an FPID from being inserted
2019-10-06 17:53:35 +01:00
jean-pierre charras 1a3f4fb38b Gerbview: enhancement: show attributes for polygons (Regions in Gerber dialect) 2019-10-06 17:34:35 +02:00
Ian McInerney 027658d3da Fix invalid cursor position access in tool manager
Fixes: lp:1846923
* https://bugs.launchpad.net/kicad/+bug/1846923
2019-10-06 13:26:07 +02:00
jean-pierre charras 36e986629a Eeschema: fix issues with pin shapes related to clock input pin shapes.
* Fix not drawn shapes for clock low, inverted clock and broken shape for falling edge clock
* Especially, shape for falling edge clock was a not existing shape, therefore useless.
* now falling edge clock and clock low shape are similar.

Fixes: lp:1846901
https://bugs.launchpad.net/kicad/+bug/1846901
2019-10-06 13:24:56 +02:00
Seth Hillbrand 8c2ee6c025 Rescale and flip Chinese characters
Characters now scale similar to capital latin letters and are correctly
oriented.

Fixes: lp:1846846
* https://bugs.launchpad.net/kicad/+bug/1846846
2019-10-05 07:42:15 -07:00
jean-pierre charras d0f498dd10 Fix missing function in qa_utils 2019-10-05 14:03:02 +02:00
Jakub Kozdon 4646bc0eef Pcb Calculator: Convert tracks width versus current formula to markdown. 2019-10-05 11:12:15 +02:00
jean-pierre charras 0a829c328e Python scripting: fix a crash with some pythons scripts calling BOARD::ComputeBoundingBox()
This function calls Pgm(), but when running from a script (not from kicad) Pgm() uses a nullptr reference.
The nullptr reference is now tested in ComputeBoundingBox()
2019-10-05 10:39:33 +02:00
Ian McInerney b33c3a5ad8 pcbnew: Clean up extension handling in graphics plugins
* Fix wildcard display in the file selector dialog (on GTK
  it would show the regex to the user)
* Move the file extension comparison into a common function
2019-10-04 15:43:29 -04:00
Jeff Young 429c7055e9 Some performance enhancements contributed by Oleg Endo.
Fixes: lp:1846438
* https://bugs.launchpad.net/kicad/+bug/1846438
2019-10-04 19:41:40 +01:00
Adam Wolf c7c49cee5a Add additional ngspice codemodel path for launching from standalone eeschema on macOS. 2019-10-04 13:41:50 -04:00
Seth Hillbrand 4302bc2562 Fix segfault when getting mouse position 2019-10-04 08:58:32 -07:00
Jeff Young 0ad9ddb3a6 Use cached bounding boxes for performance.
Fixes: lp:1846438
* https://bugs.launchpad.net/kicad/+bug/1846438
2019-10-04 11:45:08 +01:00
Jeff Young d22ea0e201 Safety for frames which don't have an m_viewControls. 2019-10-03 22:23:35 +01:00
Ian McInerney 3a2dbf7786 Update pleditor path for run from build directory 2019-10-03 15:00:01 -04:00
Wayne Stambaugh d837a212aa Bump Boost version to 1.59. 2019-10-03 14:53:27 -04:00
Ian McInerney 0aa5424511 pcbnew: Switch over some drawing tools to use PrimeTool
Before, if the tools were activated from the context menu,
they would start drawing where the menu item was selected
instead of where the menu was opened.
2019-10-03 19:04:36 +01:00
Ian McInerney 5862b1559f Cleanup position handling for TOOL_EVENTs
* Make the events generated by the selection of context menu items
  have the position where the menu was opened
* Ensure that TC_COMMAND type events have their position set to
  be the cursor position where the event originated
2019-10-03 19:04:33 +01:00
jean-pierre charras 9d617502d5 Gerbview: fix missing grid initialization at starting. 2019-10-03 18:33:16 +02:00
jean-pierre charras c3175b45af Gerbview: fix incorrect canvas type saving after closing Gerbview.
Was due to the fact the canvas type was now saved into m_canvasType when opening Gerbview.
2019-10-02 18:19:44 +02:00
jean-pierre charras ac2373ae16 Gerber plotter: add support of standard aperture regular polygon as flashed shape.
Standard apertures are circle, rect, oblong and polygon (regular polygonal shapes with 3 to 12 vertices)
The support of the standard aperture type polygon was missing in Gerber plotter.
2019-10-02 17:33:06 +02:00
Jeff Young 6179dfde37 Default keep upright to false in design settings.
The board file only writes out a token if it's true, so the value
must default to false.

Fixes: lp:1845883
* https://bugs.launchpad.net/kicad/+bug/1845883
2019-10-02 10:56:13 +01:00
jean-pierre charras d17cef95fd Add an other markdown to html converter (sundown), better to convert markdown.
The previous converter (maddy) is still available, during some time.
We therefore have the time to choose between them.
sundown is better to convert a md text, but is written to C
maddy has a few issues to convert a md text, but is written to C++
Both have no dependency.
2019-10-01 18:53:23 +02:00
Jeff Young 2679e80469 Fix bug saving last netlist filepath.
Fixes: lp:1845883
* https://bugs.launchpad.net/kicad/+bug/1845883
2019-10-01 17:43:26 +01:00
jean-pierre charras 49dbc37277 Fix a few issues related to help files in html or markdown.
Fix *.cmake scripts that dropped the semicolon in strings during conversion.
Move markdown2html in a separate library.
2019-10-01 17:11:39 +02:00
Jeff Young d9336e9f97 Reset autoplace flag when a field is moved with respect to its component.
Fixes: lp:1843929
* https://bugs.launchpad.net/kicad/+bug/1843929
2019-10-01 15:31:52 +01:00
Jeff Young 58b9d5f69e Map orientation when converting text types.
Also fixes up dangling state when converting.

Fixes: lp:1844716
* https://bugs.launchpad.net/kicad/+bug/1844716
2019-10-01 15:16:43 +01:00
Jeff Young 9a349065db Better error messages for router. 2019-10-01 15:02:41 +01:00
Jeff Young b58df5e777 Flip Start0 etc. when in ModEdit.
ModEdit and PCBNew use Start0/End0/etc. differently so care must
be taken when flipping.

Fixes: lp:1845402
* https://bugs.launchpad.net/kicad/+bug/1845402
2019-10-01 11:02:52 +01:00
jean-pierre charras 9339afcc26 minor fixes about translatable help files in markdown 2019-10-01 09:56:35 +02:00
Seth Hillbrand aad28a3d3c Adding standard library CJK strokes
This also cleans a few strokes that were not up to par in the previous
iteration.
2019-09-30 17:27:03 -07:00
Seth Hillbrand 7dd9304d24 Fix null-dereference in libedit
Clearing the CurPart sets to null.  Need to keep datasheet checks behind
guards
2019-09-30 16:53:51 -07:00