Commit Graph

7048 Commits

Author SHA1 Message Date
Seth Hillbrand 3cc87b4597 PNS: Ensure we don't miss items
Higher candidate levels could override better matches if the layers did
not overlap.
2018-10-21 14:28:33 -07:00
jean-pierre charras 0f247264f8 Pcbnew: DRC ignores first net of list of nets to test.
Fixes: lp:1798985
https://bugs.launchpad.net/kicad/+bug/1798985
2018-10-21 17:01:58 +02:00
Jeff Young f17c18bcce Remove AdvanceDepth() hacks in favour of proper layers.
Also removes the bounding-box cache since the last big merge
should have sorted out the Update(GEOMETRY) calls.

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

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

Fixes: lp:1797075
* https://bugs.launchpad.net/kicad/+bug/1797075
2018-10-21 15:55:56 +01:00
jean-pierre charras 064b8a8d60 Gerber file generation: remove a optional info in .FileFunction: the layer type.
TF.FileFunction,Copper,L1,Top,Signal is now TF.FileFunction,Copper,L1,Top

This param is not useful, and probably never correctly set by users, because is is not used by Pcbnew.
(It is used only for dsn export)
2018-10-19 15:48:18 +02:00
Thomas Pointhuber e39eeb2f92 Remove debug printf and fix indentation inside of block 2018-10-19 09:59:06 +02:00
Thomas Pointhuber 95e55eb17a Fix coding style issue (space after if) 2018-10-19 09:59:06 +02:00
Thomas Pointhuber e09785db1d Introduce PyStringToWx helper to remove code duplication 2018-10-19 09:59:06 +02:00
Thomas Pointhuber ce471ec898 Fix braces 2018-10-19 09:59:06 +02:00
Thomas Pointhuber 6ac444f587 Fix style issue 2018-10-19 09:59:06 +02:00
Thomas Pointhuber 9eff4e999f Quick fix to avoid nameclash with local qrcode python package 2018-10-19 09:59:06 +02:00
Thomas Pointhuber 8bf1954625 NoneType was incorrectly passed to PyString_AsString
The implementation relied on the fact that PyString_AsString is returning NULL
for invalid inputs (and causing an error condition), which is then fixed by the
call to FROM_UTF8. Now, we will simply return an empty string if Py_None is
returned by a python fuction, which resemebles the old behaviour of those methods
2018-10-19 09:59:06 +02:00
Thomas Pointhuber a27e547290 Fix uss39_barcode.py to work with Python3 as well 2018-10-19 09:59:06 +02:00
Thomas Pointhuber 0812f71bd3 Fix builtins import in Python3 2018-10-19 09:59:06 +02:00
Thomas Pointhuber 22e5e52598 Fix warning: 'HAVE_CLOCK_GETTIME' macro redefined 2018-10-19 09:59:06 +02:00
Thomas Pointhuber 7365cb8e52 Get Exception handling working with Python 3
The old way to get the full stacktrace was incorrect, and does not work
with Python 3:
https://stackoverflow.com/questions/3702675/how-to-print-the-full-traceback-without-halting-the-program#comment84297600_33723119
2018-10-19 09:59:06 +02:00
Thomas Pointhuber 88d04f3bcb Get Action Plugins working with Python 3, fix some unicode string errors 2018-10-19 09:59:06 +02:00
Thomas Pointhuber 8805706ccb Fix incompatibilites between Python 2 and Python 3 2018-10-19 09:59:05 +02:00
Thomas Pointhuber e9da6811a6 Fix initialisation of the pcbnew python module 2018-10-19 09:59:05 +02:00
Thomas Pointhuber 284904b72c Rewrite C extensions to also support Python 3 2018-10-19 09:59:05 +02:00
Seth Hillbrand e1f30a3b38 pcbnew: Fix single-net connectivity
Ensure that changes affecting fewer than 4 nets still get updates in the
ratsnest.
2018-10-18 17:11:58 -07:00
Jeff Young a5c892d9cd Update line width each time a new object is drawn.
Fixes: lp:1797481
* https://bugs.launchpad.net/kicad/+bug/1797481
2018-10-18 15:25:56 +01:00
Tomasz Włostowski bdc64ff0b3 router: DP_GATEWAYS::FilterByOrientation() should have exactly opposite filtering condition!
Fixes: lp:1797914
* https://bugs.launchpad.net/kicad/+bug/1797914
2018-10-18 14:29:19 +02:00
Tomasz Włostowski eea949ce0a router: don't cross DP lines when length tuning, fix swap pair polarity bug
Fixes: lp:1798500
* https://bugs.launchpad.net/kicad/+bug/1798500

Fixes: lp:1798221
* https://bugs.launchpad.net/kicad/+bug/1798221
2018-10-18 13:48:43 +02:00
Jeff Young ff992f4a64 Keep track of which nets are currently in use.
Fixes: lp:1798006
* https://bugs.launchpad.net/kicad/+bug/1798006
2018-10-18 12:14:23 +01:00
Seth Hillbrand 38c5b025c8 Ratsnest: iterate only over dirty nets
Rather than forcing each thread to iterate over the full nets list to
find the dirty items, we collect the dirty items first before asking the
threads to address them.  This prevents thread spinning.  We also
amortize the cost of calculating on an 8-net per thread basis rather
than 2.
2018-10-17 17:07:29 -07:00
Jeff Young e9a80a5d7f Some minor dialog layout fixups. 2018-10-17 11:23:02 +01:00
jean-pierre charras 9795a3572d dialog_pns_length_tuning_settings: fix incorrect dialog size.
This was due to the fact sizers recalculate the sizes before initialization of a bitmap.
2018-10-17 11:48:15 +02:00
Jeff Young 6e3f226e45 Update texts with %V and %R when values or references is chosen.
(This in addition to updating them when other fields is chosen.)
2018-10-16 17:46:01 +01:00
Jeff Young 51deb9d562 Fix issue with updating Footprint graphic items.
dyn_cast doesn't handle inheritance.
2018-10-16 17:07:59 +01:00
Jeff Young ecd893c4b1 Refresh screen after filling zones.
Previous code didn't refresh until you moved the mouse.
2018-10-16 17:07:59 +01:00
Jeff Young d62145fba9 Fix compile error when not on OSX. 2018-10-15 20:54:29 +01:00
jean-pierre charras aabff98fb6 Try to fix the Jenkins link error 2018-10-15 21:43:50 +02:00
Jeff Young 59b7762981 Back out workaround f1e2f142a6.
A proper fix is in bf164f7c4b.
2018-10-15 20:33:43 +01:00
Jeff Young 3dcd52021a Simplify exchange footprints dialog and support wildcards. 2018-10-15 19:59:47 +01:00
Jeff Young 0585382986 Allow editing of library footprint from board reference. 2018-10-15 19:59:47 +01:00
jean-pierre charras 9c398dbf90 Pcbnew, CMakeLists.txt: remove duplicate lines.
For some reason, a few files were included 3 times in the same dependency. One time is enough.
2018-10-15 20:14:27 +02:00
Seth Hillbrand a7672716f8 Revert "pcbnew: Fix memory leak in Eagle importer"
This reverts commit 45d438cd13.
2018-10-15 08:26:04 -07:00
Jeff Young 0bd0558833 Auto-select reference numbers in PcbNew like we do in Eeschema. 2018-10-14 00:06:41 +01:00
Jeff Young f1e2f142a6 Work-around for preference crash with multiple GAL docs open. 2018-10-13 19:41:45 +01:00
Jeff Young 3158273c1a Revert window-locking change which didn't fix preferences crash. 2018-10-13 15:53:54 +01:00
Jeff Young 6a5744adb1 Show compile errors and go back to GLSL V120. 2018-10-13 12:39:53 +01:00
Seth Hillbrand 4a730e6c54 pcbnew: refactor connectivity locking
Locks protect the std::set in each item.  Devolving the mutex to the
CN_ITEM allows multiple threads to make simultaneous connections to
different items where they do not conflict.
2018-10-12 17:07:31 -07:00
Seth Hillbrand 59adb109a6 Organizing connectivity
Moved large routines out of headers in into cpp.  Moved trivial routines
into headers.
2018-10-12 16:31:09 -07:00
Seth Hillbrand cfaf7c1f23 pcbnew: re-organizing connectivity
The connectivity files were unwieldy.  This separates them logically
into data, algo and items where the items classes are those that hold,
surprise, surprise, the items, lists and clusters.
2018-10-12 16:31:09 -07:00
Seth Hillbrand 4460313104 pcbnew: Separating connectivity to subdir 2018-10-12 16:31:09 -07:00
Seth Hillbrand 9e4cad666e pcbnew: Code Cleanup removing unused fns
IsDirty() is generic, so we keep the clearer m_items.isDirty() sub
function and clear out old defs.
2018-10-12 16:31:09 -07:00
Seth Hillbrand cc776f71a9 pcbnew: Code cleanup
Moving functions to std:: algorithms where feasible to reduce the code
burden.
2018-10-12 16:31:09 -07:00
Seth Hillbrand 915d2ed374 pcbnew: Zone tool follows active layer
Refactor the polygon event loop into its parent function to allow access
to the params structure.  Active layer now updates the drawing layer for
add/cutout zones.

Fixes: lp:1797483
* https://bugs.launchpad.net/kicad/+bug/1797483
2018-10-11 21:16:05 -07:00
Seth Hillbrand 4f672f0d39 Fixing a number of dynamic_casts
Dynamic casts should only be used when we explicitly check for the
resulting pointer to be NULL.  Where we know the class is castable we
can use static_cast, save on overhead and ensure our resulting pointer
is non-null.
2018-10-11 15:24:12 -07:00
Jeff Young 732e0b0bf8 Remove extra rebuild of toolbar.
It's called from CommmonSettingsChanged() anyway.
2018-10-11 18:53:00 +01:00