Commit Graph

174 Commits

Author SHA1 Message Date
Maciej Suminski d2ebf688f9 Reverted commits that remove boost::polygon dependency (need more testing). 2015-07-14 22:23:13 +02:00
Tomasz Wlostowski 41c753b05d Removed all dependencies on boost::polygon except for bitmap2component. Replaced almost all instances of CPOLYGONS_LIST with SHAPE_POLY_SET. 2015-07-14 13:36:24 +02:00
Chris Pavlina 3af895e285 Replace abs() with std::abs(). 2015-06-26 19:21:09 -04:00
jean-pierre charras fc4352f082 PolyLine.h, Polyline.cpp: a bit of cleaning code: add comments in header, remove duplicate (and not used) method. 2015-06-03 12:35:21 +02:00
jean-pierre charras ba37f33bbb Pcbnew: Use a better (i.e. more suitable to calculate clearance areas) algorithm to inflate/deflate zones outlines. It fixes bug#1459734.
Previously, acute angles (especially small angles)  in zone outlines create incorrect shapes and sometimes strange shapes for clearance areas, when using generic algorithms.
This happens when zones outlines have "spikes", but not usually for smooth outlines.
2015-05-30 14:02:55 +02:00
jean-pierre charras 3c4f76abe4 Fix a not shown dialog under XFCE and Unity. Make display hotkeys window not modal. 2015-03-15 12:41:06 +01:00
jean-pierre charras d6c6b4debb Fix some coverity warnings (mainly not initialized vars). 2015-02-27 15:33:13 +01:00
jean-pierre charras 64925bfc4f Very minor fixes: add missing const return type to some GetBoundingBox() declarations. Change few functions names to better names in some places (like GetName() to GetPinName() ) 2015-01-18 18:28:14 +01:00
jean-pierre charras bb7a74f58f Pcbnew: fix Bug #1404191 (Zone filling fails when a zone inside having the same net and a highter priority exists, which is allowed to manage different fill parameters ) 2014-12-19 20:09:53 +01:00
jean-pierre charras 25a801ed8a Modify usage of Inflate/deflate polygon in zone calculations, in order to be compatible with boost::polygon >= 1.56
Some code cleanup.
2014-11-30 18:07:02 +01:00
jean-pierre charras 8da93abcb8 Polygon tools: update Clipper lib to 6.2.1
Minor doc update.
2014-11-12 18:58:39 +01:00
jean-pierre charras 6a93777a51 Polyline.h: remove useless class CRect. Use the more powerful EDA_RECT instead. Clean and remove duplicate code. 2014-11-08 13:25:29 +01:00
jean-pierre charras 24f516f6ae Fix many doxygen warnings (due to missing info, old comments, typo ...) when building the doxygen doc. 2014-11-02 17:25:04 +01:00
jean-pierre charras 29e6a93d01 Add license information to PolyLine.h and PolyLine.cpp files. 2014-10-29 13:18:02 +01:00
Wayne Stambaugh f86eb756af Source license, coding policy, and documentation fixes.
* Add more missing source code licenses.
* Fix coding policy violations (tabs and trailing white space) in Python
  scripting code.
* Add stable release policy to full documentation build.
2014-10-28 15:43:12 -04:00
jean-pierre charras d4731da097 Minor fixes: remove compil warning. Remove one of 3 messages when saving a part lib in libedit.
Update clipper version to 6.1.3a.
2014-09-29 12:51:04 +02:00
unknown c8d69f19c8 Pcbnew: add drc test for texts on copper layer (only in full drc test, not in on line drc), from a patch sent by Simon Schumann
Add EDA_TEXT::TransformTextShapeToSegmentList function to export a list of segments used to draw/plot the text.
2014-08-13 17:47:02 +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 afc5d13172 Apply a workaround in 3D_draw.cpp to avoid crash in boost::polygon (try to fix Bug #1322804)
This workaround was already used (bzr 4301, in file plot_board_layers.cpp) also to avoid similar crashes (uses 18 segments instead of 16 to approximate a circle by segments).
Minor code cleanup in dialog_plot.
2014-05-26 08:54:04 +02:00
Lorenzo Marcantonio 342016b692 Constification of HitTest and GetParent
In particular HitTest for zones *do not* select the nearest vertex/edge as a side effect
2014-05-04 19:08:36 +02:00
Marco Serantoni 932c92af55 [MacOSX] New reorg for building system, typos and path refines 2014-02-19 22:39:21 +01:00
jean-pierre charras fe919cd456 Update demos. Fix pspice netlist issues when using ( and ) in net names ( parenthesis are replaced by underscore) . 2014-01-07 20:42:34 +01:00
Dick Hollenbeck 84cf722541 This is why we cannot have nice things. This is why we test our changes before committing.
Pray for angus johnson who is support too many languages, and needs to find a text editor that removes trailing whitespace.
2014-01-03 18:46:06 -06:00
Dick Hollenbeck dbb72d161e fix some compiler warnings 2014-01-03 18:07:20 -06:00
Dick Hollenbeck e659d53590 fix compiler warnings 2014-01-03 17:16:40 -06:00
jean-pierre charras eb22bf426c Pcbnew: very minor fixes and update: update clipper version. uncrustify polytri/* and fix some warning compil. 2014-01-03 18:39:28 +01:00
jean-pierre charras 46e82e4e18 Move HitTestForCorner and HitTestForEdge code from class_zone to polygon/PolyLine.cpp, to avoid redundant code.
Fix bug 1264248.
Fix a very minor issue in RemoveTrailingZeros, for countries where the separator in floating numbers is a comma.
2013-12-29 11:15:06 +01:00
Povilas Kanapickas 7f12513c7e Remove some uses of using namespace std. 2013-12-13 10:27:30 -06:00
maciej. 72e567f503 Bug fix: pcbnew hangs up on polygon movement 2013-12-06 15:34:39 +01:00
Maciej Suminski e13f862145 Merged upstream. 2013-10-28 21:34:06 +01:00
jean-pierre charras e9713bb291 Pcbnew: Block selection enhancement, from Bug #593997 (whishlist)
1. block created from-left-to-right selects only 100%inside selection objects (as it now does)
2.block created from-right-to-left selects all overlapping objects inside selection
From the patch sent by mathieulj (mathieulj), and some fixes and code cleaning.
2013-09-21 20:09:41 +02:00
Maciej Suminski c00533a150 Merged kicad-gal 2013-09-20 15:48:27 +02:00
Maciej Suminski dcb5d8f25c Merged Tom's branch 2013-09-18 16:59:08 +02:00
tomasz.wlostowski@cern.ch 228a9451f7 polygon: added poly2tri library.
Requied for constrained Delaunay triangulation (P&S/ratsnest) and zone tesselation (GAL).
2013-09-13 15:28:20 +02:00
Wayne Stambaugh 2afe1eab7a Fix MinGW build issue for missing isinf() in PolyLine.cpp. 2013-08-16 10:25:34 -04:00
Marco Mattila 7e1aef2200 Pcbnew: fix filleting of zones with parallel adjacent edges 2013-08-16 14:51:35 +03:00
jean-pierre charras 50743cf3ba Initial release of pl_editor, the page layout and title block editor. 2013-07-19 20:27:22 +02:00
Dick Hollenbeck 8ccf0320b4 1) Add "rules" to base of tree for copying into BZR_HOME/rules.
File "rules" has instructional text as comments near top.

2) Convert all text files in repo to LF line ending form.
   Any checkout done with "rules" in play will convert the working
   tree to native line ending, while keeping repo as LF line ending.
2013-05-25 23:36:44 -05:00
jean-pierre charras ac1386a5a2 Pcbnew: fix bug 1179877, due a bad default copy constructor, after my changes about CPOLYGONS_LIST class.
More about CPOLYGONS_LIST work.
2013-05-14 20:47:01 +02:00
jean-pierre charras 2554575656 More work on CPOLYGONS_LIST class.
Pcbnew: fix minor bug about  plot line width.
2013-05-09 21:08:12 +02:00
jean-pierre charras 2e6969fe96 More work on CPOLYGONS_LIST class. 2013-05-08 20:20:58 +02:00
Lorenzo Marcantonio cb49ca5ae2 More int casts to rounding conversions 2013-05-04 13:57:09 +02:00
jean-pierre charras b2a76062c7 All: use CPOLYGONS_LIST, a typedef of std::vector<CPolyPt> to handle a Corners Polygons List.
This is a starting point of some code enhancements relative to polygons in Pcbew and 3D viewer.
2013-05-03 19:51:10 +02:00
Lorenzo Marcantonio 0e903dba5b Angle and distances cleanup (preparing for angles in doubles)
- Removed spurious int casts (these are truncated anyway and will break
  doubles)

- Applied the Distance, GetLineLength, EuclideanNorm, DEG2RAD, RAD2DEG
  ArcTangente and NORMALIZE* functions where possible

- ArcTangente now returns double and handles the 0,0 case like atan2, so
  it's no longer necessary to check for it before calling

- Small functions in trigo moved as inline
2013-05-01 19:32:36 +02:00
Lorenzo Marcantonio f50f31e5a3 Added include guard to math_for_graphics.h 2013-04-30 15:27:08 +02:00
Lorenzo Marcantonio 74a57d4ea8 Cleanup of the eeschema 'layers' i.e. entitity colours. This also fixes
the spurious warning about stuff that couldn't be seen when changing
colours.
NOTE that the 'net name' layer is present and configurable but non used 
anywhere!
2013-04-06 07:01:48 +02:00
Lorenzo Marcantonio 00f0e27851 Factored layer utility functions: classification, layer flip and mask flip 2013-04-05 21:04:58 +02:00
jean-pierre charras 92e0eb628c Minor changes in dialogs to ensure a better likeness between dialogs on Linux and Windows (mainly, remove some wxStaticBoxSizer in dialogs) 2013-04-01 12:50:01 +02:00
Lorenzo Marcantonio 9fd79dfa91 Implemented the LAYER_NUM typedef (LAYER was already taken as a class name...) to represent a layer number. 2013-03-31 15:27:46 +02:00
Lorenzo Marcantonio e0303a4558 - New typedef LAYER_MSK to encapsulate a layer bitmap
- Renamed ReturnMaskLayer to GetLayerMask (since it's a plain getter)
2013-03-30 18:24:04 +01:00