Jeff Young
09490e1f46
Don't snap a footprint (or group) to its children.
...
Fixes https://gitlab.com/kicad/code/kicad/-/issues/15535
(cherry picked from commit d161602e92
)
2023-08-31 12:37:44 +01:00
jean-pierre charras
c4914a64bb
PCB_GRID_HELPER::BestSnapAnchor() fix overflow due to use of int.
...
GRID_HELPER::GetVisibleGrid() needs double, does not work with int (overflow).
Fixes #15389
https://gitlab.com/kicad/code/kicad/-/issues/15389
2023-08-11 18:04:27 +02:00
Jeff Young
c0ddca12df
Add Property Inspector support for dimension objects.
...
Includes changing the class hierarchy so that dimension objects inherit
from PCB_TEXT rather than containing a PCB_TEXT member variable.
(cherry picked from commit 23accffc6d
)
2023-03-12 21:03:58 +00:00
Seth Hillbrand
1cc9792cdb
Fix snapping dist when disabling grid
...
The disable grid hotkey should allow the snap scale to be completely
determined by the snapSize and world scale. This prevents snapRange
from overriding in the case where grid is disabled.
Additionally, we disallow grid snapping when the grid scale is not
visible. This means that when zoomed out sufficiently to not show the
minor ticks, these minor ticks will not override a snap
Fixes https://gitlab.com/kicad/code/kicad/issues/12303
2022-12-21 17:47:45 -08:00
Jeff Young
9d13e419c2
Reduce compiler warnings.
2022-12-13 00:47:19 +00:00
Alex
8c468dcffc
Use ecoords for distance comparison in PCB grid helper.
...
Fixes a bug where a cursor would jump to a far location while hovering
over some 45-degree tracks.
2022-11-30 08:18:19 +03:00
Alex
dd2f19ca5f
Allow router cursor snapping to points on the arc.
...
Also don't disable grid snapping when holding Shift over arcs.
2022-11-20 16:56:25 +05:00
Alex
110bc6abd1
Fix router cursor glitching on H/V track segments.
...
Also don't disable grid snapping when holding Shift over tracks.
2022-11-20 16:56:25 +05:00
Jeff Young
2cfe78170c
Honour selection filter when picking move anchors.
...
Fixes https://gitlab.com/kicad/code/kicad/issues/12773
2022-11-08 16:27:18 +00:00
Wayne Stambaugh
6a0db3e7e2
Fix Coverity warnings.
2022-10-26 14:39:44 -04:00
Jeff Young
83310659fd
Basic geometry: R != D.
...
Fixes https://gitlab.com/kicad/code/kicad/issues/12601
2022-10-10 19:18:37 +01:00
Jeff Young
8470b178cd
Use actual pad shapes or built outline instead of effective shpaes for anchors.
...
The effective shapes don't work very well in the custom pad or rounded
rectangle cases, and they're somewhat slower in some of the other cases.
Fixes https://gitlab.com/kicad/code/kicad/issues/12601
2022-10-10 18:11:32 +01:00
aris-kimi
f818f3a445
Fix footprint rule and zone area anchors
...
Fixes: https://gitlab.com/kicad/code/kicad/-/issues/12575
2022-10-06 15:29:18 +00:00
Alex
b81a3f0533
GetClampedCoords: Better usability for rounding
2022-08-16 12:08:55 +00:00
Alex
4d7d367b25
Use KiROUND for BBox calculation, change parameter name, block negative padding.
2022-08-16 12:08:55 +00:00
Seth Hillbrand
759e1a64ef
Fix broken const ref in wildcard
2022-08-15 12:09:30 -07:00
Seth Hillbrand
35ac39844f
Clean up some auto usage
...
Don't make new copies of shared_ptr if we can use references. Keep auto
usage down to hard-to-type-out sequences
2022-08-15 11:29:45 -07:00
Jeff Young
f076d07e9e
Fix asserts.
2022-02-24 18:16:45 +00:00
Jeff Young
85805b95ba
Cancel or commit pad edit mode when switching footprints.
...
Fixes https://gitlab.com/kicad/code/kicad/issues/10209
2022-02-19 19:36:19 +00:00
jean-pierre charras
876061369b
Fix some Pcbnew crashes due to null pointers
2022-02-14 13:46:05 +01:00
dsa-t
68655540eb
Clamp cursor to limits of coordinates representation
...
Also improves large distance handling.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/8846
2022-02-11 16:42:52 +00:00
Jeff Young
5739505aa3
TextBoxes for PCBNew.
2022-01-31 20:00:47 +00:00
Jeff Young
c8a50d9b50
Remove unit-less angles from VECTOR2I/D APIs.
2022-01-20 23:58:20 +00:00
aris-kimi
47c0672ff3
Added footprint rule area anchors
...
Fixes https://gitlab.com/kicad/code/kicad/-/issues/10461
2022-01-19 18:25:20 +00:00
Seth Hillbrand
ed35f4bfc5
Fix pad snapping in renumber pads
...
Snap shouldn't be looking for other items in this routine or using the
grid
Fixes https://gitlab.com/kicad/code/kicad/issues/10238
(cherry picked from commit ed9a3deb57
)
2022-01-03 19:39:04 -08:00
Marek Roszko
c4c56de708
Neurotically update position wxPoint usages
2022-01-01 11:55:51 -05:00
Jeff Young
fa908e1f98
Dimensions for footprints.
...
Fixes https://gitlab.com/kicad/code/kicad/issues/8441
2021-12-24 21:10:28 +00:00
Jeff Young
4b6bf3095a
Radial dimensions.
...
ADDED radial type dimensions.
Fixes https://gitlab.com/kicad/code/kicad/issues/2056
2021-12-23 19:34:54 +00:00
Jeff Young
9b9e379aa0
Overhaul arc internal model to not over-specify information.
2021-10-15 12:45:43 +01:00
jean-pierre charras
3316f3998a
Rename BuildPolyPointsList() to DupPolyPointsList() and optimize code
...
to avoid multiple useless copies of the list of polygon corners in code.
2021-09-11 14:21:36 +02:00
Seth Hillbrand
cb917e4c42
Avoid nonsensical intersections
...
When two segments are approximately parallel, we shouldn't look to find
their intersection. It will never be the nearest point and it overflows
the KiROUND call
Fixes https://gitlab.com/kicad/code/kicad/issues/8858
2021-07-26 09:02:54 -07:00
Jeff Young
0fb864d596
Pull some name changes back from 7.0 to ease merging.
2021-07-21 20:58:59 +01:00
Wayne Stambaugh
cf00319c85
More NULL expunging.
2021-07-20 07:27:18 -04:00
Jeff Young
096e342386
Prefix TRACK, ARC and VIA.
2021-06-11 22:07:02 +01:00
Jeff Young
16b0147af8
Prefix DIMENSION types.
2021-06-11 17:59:44 +01:00
Marek Roszko
10e60acf34
Clean up including of board_design_settings.h
2021-06-06 15:03:42 -04:00
Ian McInerney
23f8851409
Remove pcb_group include from board header
2021-06-03 20:03:31 +01:00
Jeff Young
5c9a73aa5e
Correct position for grid even when we're not snapping to a point.
...
Fixes https://gitlab.com/kicad/code/kicad/issues/8125
2021-05-25 21:57:19 +01:00
Marek Roszko
21fde9b629
enum class PCB_SHAPE_TYPE_T
2021-04-30 22:36:12 -04:00
Mikolaj Wielgus
43d8145304
Pcbnew: Snap to the closest point on graphic polygon border
...
Fixes https://gitlab.com/kicad/code/kicad/issues/8164
2021-04-09 22:33:55 +00:00
Mikolaj Wielgus
d64de3808f
Pcbnew: Snap to group items
...
Fixes https://gitlab.com/kicad/code/kicad/issues/7694
2021-04-08 23:22:19 +00:00
Jeff Young
86aaa2e9cb
Rationalize footprint bounding boxes and cache all of them.
...
Fixes https://gitlab.com/kicad/code/kicad/issues/7720
2021-02-26 13:50:27 +00:00
Tomasz Wlostowski
e221b11e3b
GRID_HELPER: fixed arithmetic issue in segment snap distance check disguised as 'excessive optimization' by the dragger in the router
2021-02-25 17:18:23 +01:00
Mikolaj Wielgus
2a9d76f1e3
Pcbnew: Fix snapping segment traces and graphics when initiating move
...
Fixes https://gitlab.com/kicad/code/kicad/issues/4746
2021-02-20 20:29:43 +00:00
Seth Hillbrand
29632e8b6f
Include footprint center as snap point
...
Only when footprint center isn't approximate the footprint origin as
well. This can help when moving/aligning THT footprints
Fixes https://gitlab.com/kicad/code/kicad/issues/7385
2021-02-01 12:03:26 -08:00
Seth Hillbrand
386ead30c5
All circle and arc tools to select all at first
...
Non-layer elements can be logical centers for the circle and arc tools.
We allow the non-layer to snap for the center points and revert to only
on-layer elements after
Fixes https://gitlab.com/kicad/code/kicad/issues/7327
2021-01-29 10:14:44 -08:00
Jeff Young
68efdb2fff
Push shared parts of GRID_HELPERs into common.
2021-01-16 23:18:10 +00:00