Jeff Young
8165fc6c44
Give up trying to infer what kind of polygon the user wants.
In many instances there are 3 valid answers: mimic linewidths, use
centerlines, and build a bounding hull.
Fixes https://gitlab.com/kicad/code/kicad/issues/12950
3 years ago
Jeff Young
ec9c6a8053
Separate creation of polygons for open and closed shapes.
This allows us to create a bounding hull from an open shape-line-chain,
which is useful for defining milled slots.
3 years ago
Jeff Young
3fc727bb91
Clear selection before deleting objects during conversion.
Fixes https://gitlab.com/kicad/code/kicad/issues/12879
3 years ago
Seth Hillbrand
c7c4439027
Allow bezier->line/poly conversion
Fixes https://gitlab.com/kicad/code/kicad/issues/12778
3 years ago
Jeff Young
d16b23d16e
Name shortening and line-break reduction.
3 years ago
jean-pierre charras
6b3d36b6c3
CONVERT_TOOL: also show the "Create From Selection" menu if a array can be created
The "Create Array" sub-menu was recently moved to this menu, so it must me
shown as soon as an array can be created.
3 years ago
Jeff Young
c30a557810
ADDED netclass assignment from PCB canvas.
Fixes https://gitlab.com/kicad/code/kicad/issues/5975
3 years ago
Seth Hillbrand
f1261e71d4
Replace boost::optional with std::optional
3 years ago
Jeff Young
1871812f2b
Consolidate on a more widely used sub-type architecture.
3 years ago
Jeff Young
aa2ad3b44c
Move KICAD_T[] to std::initializer_list<KICAD_T>.
3 years ago
Jeff Young
927bc8141b
Init member variables.
3 years ago
Jeff Young
6f49b57f9b
Cleanup & performance enhancements.
3 years ago
Jeff Young
f0b9e67212
Add ignore-line-widths mode to CONVERT_TOOL.
Fixes https://gitlab.com/kicad/code/kicad/issues/5911
3 years ago
Jeff Young
fc1afa6298
Improvements to convert tool.
1) Handle filled shapes
2) If a chained outline can't be found, build hulls of the individual
segments
3) Combine intersecting shapes
4) Simplify code
Fixes https://gitlab.com/kicad/code/kicad/issues/git
Fixes https://gitlab.com/kicad/code/kicad/issues/5911
3 years ago
Seth Hillbrand
737d65fd36
Skip zero-size elements when converting
Also fixes an assertion when converting to polygon from the board editor
Fixes https://gitlab.com/kicad/code/kicad/issues/11313
(cherry picked from commit 6706a5c462 )
4 years ago
Seth Hillbrand
2fafa55647
Maintain width of converted tracks
4 years ago
Seth Hillbrand
7e836ae27a
Select the copper layer before processing
If we are converting to tracks, the copper layer needs to be selected
before any other elements are processed, otherwise, we end up with the
default undefined layer
Fixes https://gitlab.com/kicad/code/kicad/issues/11025
(cherry picked from commit 9396735733 )
4 years ago
Jeff Young
34a9a165c9
More wide-string declarations.
4 years ago
Jon Evans
bf38cb56b7
Handle footprint shapes in polygon creation
Fixes https://gitlab.com/kicad/code/kicad/-/issues/10259
(cherry picked from commit f9d8ec6137 )
4 years ago
Jon Evans
4be56825bb
Fix creating polygons from footprint rule areas
Fixes https://gitlab.com/kicad/code/kicad/-/issues/10257
(cherry picked from commit e9b91b6fab )
4 years ago
Marek Roszko
c4c56de708
Neurotically update position wxPoint usages
4 years ago
Jeff Young
2bc86fa0a8
Shapes for schematic.
ADDED arc, circle and rectangle shapes for schematic. Shapes support
line styles and fill colors.
CHANGED sheet background color in Edit Text & Graphics Properties to
fill color (and it now affects shapes).
Pushed STROKE_PARAMS down into common and moved all shapes to using it
for stroke descriptions.
4 years ago
Jon Evans
62e6f542ed
Init zone type when creating in convert tool
Fixes https://gitlab.com/kicad/code/kicad/-/issues/9918
4 years ago
Jon Evans
a9168860e0
Reduce excessive epsilon in polygon search algo
Fixes https://gitlab.com/kicad/code/kicad/-/issues/9903
4 years ago
Jeff Young
f9861b4a6c
Finish arc rework and push out to file formats.
4 years ago
Jeff Young
9b9e379aa0
Overhaul arc internal model to not over-specify information.
4 years ago
Jeff Young
8b08c9e53f
Shorter names before things get out of hand.
Also, remove comments indicating CURVE is a Bezier. Just call it a
BEZIER.
4 years ago
Jeff Young
a41944020d
Push most of PCB_SHAPE impl down in to EDA_SHAPE.
4 years ago
Ian McInerney
4d89061d4c
Support footprint arcs in convert to polygon
Fixes https://gitlab.com/kicad/code/kicad/issues/9352
4 years ago
jean-pierre charras
da79a3dd69
Option graphics limited to 45deg in creation: separate options for brd and fp editors.
Add these options in PANEL_EDIT_OPTIONS.
This option was previously living only in some context menus, not really visible.
4 years ago
Jon Evans
07e01e6297
Allow converting graphic arc to track arc
4 years ago
Jon Evans
5bfafa5e4c
Add rounding epsilon to convert tool polygon search
Fixes https://gitlab.com/kicad/code/kicad/-/issues/8927
4 years ago
Jon Evans
a90656900a
Allow creating polygon types from polygons
Fixes https://gitlab.com/kicad/code/kicad/-/issues/7302
4 years ago
Jon Evans
3beeb52c43
Convert tool: create lines on active layer, not source layer
4 years ago
Jeff Young
0fb864d596
Pull some name changes back from 7.0 to ease merging.
4 years ago
Wayne Stambaugh
cf00319c85
More NULL expunging.
4 years ago
Jon Evans
75190370dd
Convert -> Create from Selection
Fixes https://gitlab.com/kicad/code/kicad/-/issues/8818
4 years ago
Jeff Young
e02bb80bf3
Handle cancel when selecting copper layer.
Also changes the algorithm to ask only once, rather than one per
non-copper-layer object.
Fixes https://gitlab.com/kicad/code/kicad/issues/8767
4 years ago
Jon Evans
67762a11f6
Don't double-process arcs if we get one first
4 years ago
Jon Evans
b291f36dae
ADDED: Convert tool can create polygons with arcs from contiguous line and arc segments
Fixes https://gitlab.com/kicad/code/kicad/-/issues/5409
4 years ago
Jon Evans
de4eb1fcef
Convert to zone: take dest layer from editor active layer
Show non-copper zone properties if active layer is non-copper
Fixes https://gitlab.com/kicad/code/kicad/-/issues/8646
4 years ago
Jeff Young
096e342386
Prefix TRACK, ARC and VIA.
4 years ago
Marek Roszko
10e60acf34
Clean up including of board_design_settings.h
4 years ago
Marek Roszko
21fde9b629
enum class PCB_SHAPE_TYPE_T
5 years ago
Jeff Young
18470693fe
Copy linewidths when coverting to polygons.
Fixes https://gitlab.com/kicad/code/kicad/issues/7893
5 years ago
Jon Evans
18037e2f65
Rework bitmap system to load from archived PNGs
Bitmaps are now identified by an enum class instead of by pointers.
Bitmap loading and caching is now handled by a class in common, and
we no longer compile most bitmaps into the binary, so there is no
longer a bitmaps static library.
Instead, bitmaps are archived to a .tar.gz file which is installed
in ${KICAD_DATA}/resources/images.tar.gz
The source PNGs are checked in to Git as the original CPP files were,
so that people can build without the required dependencies to convert
SVGs to PNGs.
Initial support is also added for dark theme icons, although this
is not yet exposed in the GUI.
Stubs are present for multi-resolution image resources, but this is
not fully-baked yet and could use some refinement.
5 years ago
Jeff Young
ea9c269914
Don't fill polygons converted from lines.
The lines couldn't have been filled, so the polygon shouldn't start
out filled either. The user can set it to filled if they want.
Fixes https://gitlab.com/kicad/code/kicad/issues/7867
5 years ago
jean-pierre charras
5d2dc0b50e
Fix a few (minor) issues:
- Make DIALOG_SHIM::SetPosition working)
- rename PCB_BASE_FRAME::SelectLayer() to PCB_BASE_FRAME::SelectOneLayer()
- PCB_BASE_FRAME::SelectOneLayer(): make dismiss dialog by escape key working.
Fixes #7578
https://gitlab.com/kicad/code/kicad/issues/7578
5 years ago
Seth Hillbrand
1c9d8a9f4c
Don't warn on locked conversion
5 years ago
Jeff Young
2a088e5c7b
Add conversion of circles to zones and enable in footprint editor.
Also rule areas, of course.
Fixes https://gitlab.com/kicad/code/kicad/issues/6966
5 years ago