3693 Commits

Author SHA1 Message Date
Seth Hillbrand
8acf5c1a25 ADDED: Rounded Rectangles
Fixes https://gitlab.com/kicad/code/kicad/-/issues/4742
2025-08-29 17:37:30 -07:00
Seth Hillbrand
e282dca102 Add configurable hysteresis to PCB snapping
Makes it harder to enter and harder to exit a snap.  ideally this should
help make snapping more intuitive and easier to use.  Once you have a
snap, it is harder to lose it but it avoids being overly snappy in the
begining
2025-08-29 16:21:35 -07:00
Seth Hillbrand
a811f61c39 Make Expand Connection respect the filter
Prevents expansion that would require traversing elements that are
disabled in the selection filter

Fixes https://gitlab.com/kicad/code/kicad/-/issues/21581
2025-08-29 16:11:38 -07:00
Seth Hillbrand
e8cec41355 ADDED: Indication of filter blocking
If the selection filter has blocked all selections under the cursor,
show a subtle flash on which filter(s) did the blocking.  Helpful for
people getting frustrated by not being able to select locked items.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/20487
2025-08-29 07:08:27 -07:00
Jeff Young
83fab7b02c Fix undo for move of group-of-shapes.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/21563
2025-08-28 13:20:14 +01:00
John Beard
0f0527bd03 Pcbnew: fix sensitivity of via placement to large grids
Another case where large grids are overly "grabby" for snaps.

In this case, because the via was moved to the grid-snap first,
and then THAT position was used to look for things like pad-snaps,
the pad snaps would not be found if a coarse grid meant the cursor
was outside the pad.

Instead, use the mouse position when looking for the non-grid snaps
in VIA_PLACER::SnapItem.

Fixes: https://gitlab.com/kicad/code/kicad/-/issues/18626
2025-08-26 23:34:46 +08:00
John Beard
3d8803f579 Pcbnew: use R-tree for pad checks in via place tool
Otherwise this is an O(n-pads-on-board) operation for every new
candidate via position.
2025-08-26 23:34:46 +08:00
Seth Hillbrand
8997b7bcf7 Remove old HasCorner 2025-08-25 22:06:26 -07:00
Seth Hillbrand
5b86f20476 Suppress unneeded move corner context
Doesn't really make sense in terms of a group

Fixes https://gitlab.com/kicad/code/kicad/-/issues/21552
2025-08-25 22:04:32 -07:00
Seth Hillbrand
7841476ed6 Make all 4 corners draggable
When scaling, maybe you want to drag from the bottom left or top right

Fixes https://gitlab.com/kicad/code/kicad/-/issues/21554
2025-08-25 22:02:20 -07:00
Seth Hillbrand
a034c30563 Properly add group size mod to commit
Allows escaping the current state

Fixes https://gitlab.com/kicad/code/kicad/-/issues/21553
2025-08-25 21:59:13 -07:00
Seth Hillbrand
4e7fa189aa Refactor gfx import cleanup
Break up monolithic function into responsibilities.  Adjust cleanup to
correctly modify each graphical pairing.  Fix drc test to properly
report gap distances that are relevant to outlines

Fixes https://gitlab.com/kicad/code/kicad/-/issues/13090
2025-08-25 11:33:26 -07:00
Seth Hillbrand
26f0c03e61 ADDED: support for 45 degree crosshairs
Fixes https://gitlab.com/kicad/code/kicad/-/issues/6047
2025-08-23 06:20:00 -07:00
Seth Hillbrand
206dfa2883 Allow scaling grouped graphics in pcbnew
Adds scaling handles and editpoints to drag shapes larger/smaller while
maintaining proportions.  Future additions might include non
proportional scaling

Fixes https://gitlab.com/kicad/code/kicad/-/issues/13072
2025-08-22 20:04:38 -07:00
Jeff Young
3f85071f91 Don't double mirror groups.
Also removes previous fix, which had side-effects.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/8121

Fixes https://gitlab.com/kicad/code/kicad/-/issues/20465
2025-08-21 12:29:34 +01:00
Jeff Young
42735b775d Remove unreachable PASTE_MODE.
Also, don't depend on enum order.

Fixes KICAD-YJ8.
2025-08-21 12:29:34 +01:00
Jeff Young
90621947bf Bug fixes for locked tuning patterns.
The router uses locking to know the bounds of the
tuning pattern so it must be temporarily unlocked
while editing with the router.
2025-08-20 23:23:45 +01:00
Seth Hillbrand
c2f503774b Ensure that we use lasso when in the lasso mode
Fixes https://gitlab.com/kicad/code/kicad/-/issues/21499
2025-08-20 12:48:03 -07:00
Mike Williams
0f0c2ea494 pcb: windows build fix 2025-08-20 15:20:13 -04:00
Mike Williams
1e3c95a1d5 append board: use design block info when we have it 2025-08-20 15:20:13 -04:00
Mike Williams
ef50c31584 pcb design blocks: cleanup unused parameter
The position would always be "don't move at all" since we need to ensure
the design block fits in the canvas area, which means we can't move any
objects that we import.
2025-08-20 15:20:13 -04:00
Mike Williams
cdc8435fd8 pcb design blocks: need tool actions from base class, too 2025-08-20 15:20:13 -04:00
Mike Williams
e30b325433 multichannel tool: fixup for rebase 2025-08-20 15:20:13 -04:00
Mike Williams
92ef03cf15 design blocks/multichannel: make apply layout do routing, etc. 2025-08-20 15:20:13 -04:00
Mike Williams
2f88ee9dee multichannel tool: just pass COMPAT_DATA& instead its parts 2025-08-20 15:20:13 -04:00
Mike Williams
3151d97010 multichannel tool: formatting and comments 2025-08-20 15:20:13 -04:00
Mike Williams
4df013cf13 multichannel tool: pass RULE_AREA to functions called findXInRuleArea
Was previously passing just the zone in some of them.
2025-08-20 15:20:13 -04:00
Mike Williams
fbb9b296e3 multichannel tool: rename ZONE* from m_area to m_zone for clarity 2025-08-20 15:20:13 -04:00
Mike Williams
5da6e482ed design blocks / multichannel: don't require user move of temp placement 2025-08-20 15:20:13 -04:00
Mike Williams
97af2af779 design blocks / multichannel: basics of placing DB layout 2025-08-20 15:20:13 -04:00
Mike Williams
986c1a597a multichannel tool: remove redundant m_raFootprints 2025-08-20 15:20:13 -04:00
Mike Williams
c6df815935 multichannel tool: remove some unused variables 2025-08-20 15:20:13 -04:00
John Beard
2a3b758e82 Pcbnew: array tool: improve variable locality, use range-for 2025-08-21 00:18:22 +08:00
John Beard
f31a109ab4 Pcbnew: fix refdes ordering in arrays
The first cell of the array needs to not be reannotated, or it will
skips its own number(s) and take what we expect for the second cell.
The repeats until the last entry, which didn't reannotate anything,
leaving the original numbers. Producing a 'rotation' like 2,3,4,5,1
rather than the expected 1,2,3,4,5.

Fixes: https://gitlab.com/kicad/code/kicad/-/issues/20935
2025-08-21 00:18:22 +08:00
Jeff Young
1ceac1dafd Simplify locking to just be another filter now that we don't have a dialog. 2025-08-20 15:24:36 +01:00
John Beard
105b9fcfe8 Pcbnew: fix occasional failure-to-select for dragging
In the Drag tool client filter function, sometimes,
GuessSelectionCandidates trims the collector's item list.
But we used the old contents of the per-type vectors to make
judgements about what was connected.

If a call came in with 2 tracks (e.g. near a knee) and one
was removed by GuessSelectionCandidates, sometimes the
other one would be the one selected for removal in the
2 tracks/0 via case. This leaves the collector empty.

The other case, where the item removed by GuessSelectionCandidates
was removed from the collector is silent, as removing an item
not in the collector is a no-op.

Fixes: https://gitlab.com/kicad/code/kicad/-/issues/21517
2025-08-20 20:34:08 +08:00
Jeff Young
b0945ee697 Don't push someone else's commit. 2025-08-20 13:19:37 +01:00
Jeff Young
e9f8b72666 Allow clearing of multiple tuning patterns.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/21508
2025-08-20 13:19:37 +01:00
Jeff Young
6f389fd320 Tighten parent/child undo/redo architecture.
Always look for pre-existing undo/redo record.  Checking for IsNew()
is less robust and should be avoided.  Also moves the checking to a
location where it will be easier to ensure that it's uniform.

Push get-undo-level-item processing down a level so it is uniformly
called.

Make sure tables & labels are uniformly handled.

Remove incorrect usage of Get/SetGroupId() for storing lastPin
(which we don't use anyway).

Lists of deleted and changed items MUST include the screen pointer.
An item could be changed on one screen but not on another.

Also tightens handling of PCB_NETINFO_T items, which are not in the
view.

Also fixes a bug where there is no increment parameter if you assign
the base increment command to a hotkey.
(This was discovered while testing the above changes.)

Also fixes a bug where delete during a move in PCB Editor did an
undo instead of a delete.
(Again, found while testing above.)

An experiment was also run to collapse shared parts of SCH_EDIT_FRAME
and SYMBOL_EDITOR_FRAME into SCH_BASE_EDIT_FRAME.  However, sharing the
undo code actually increased complexity, and there was very little else
of value in SCH_BASE_EDIT_FRAME (other than the Increment() routines).
2025-08-18 19:20:09 +01:00
Seth Hillbrand
1166cacc64 Snap point editor into place
Adds 90° support to the point editor and ensures editing is the same as
creating when it comes to point snapping

Fixes https://gitlab.com/kicad/code/kicad/-/issues/21481
2025-08-15 12:19:06 -07:00
Seth Hillbrand
3ec380d93c Allow generator actions to affect children
Changing the generator will often modify the underlying children's
properties.  We should store these data in the stack.  Also add the
ability to change layers

Fixes https://gitlab.com/kicad/code/kicad/-/issues/21476
2025-08-15 06:50:46 -07:00
Seth Hillbrand
8bf7975440 Make move tool obey snap settings
Fixes https://gitlab.com/kicad/code/kicad/-/issues/21192
2025-08-15 06:35:12 -07:00
Jeff Young
33c73d7db4 Fix crashes when settings manager doesn't exist yet. 2025-08-14 11:33:25 +01:00
Jeff Young
a0e768dd0e Cleanup compiler warnings. 2025-08-13 16:22:51 +01:00
Jeff Young
60b4202766 CHANGED: Rework lock overrides architecture.
We now use a checkbox in the aux toolbar rather
than a query dialog (with "remember setting" checkbox).
2025-08-13 10:30:26 +01:00
Seth Hillbrand
188ffda029 Add a 90°-only mode for polygon creation
Sometimes, you don't want those 45° corners in your nice, clean zones.
This adds an additional mode that can be selected, cycling through
free-angle, 45° angle and 90° angle constraints
2025-08-12 16:48:36 -07:00
John Beard
d1aa7b148a Eeschema/Pcbnew: allow multiple nets to be assigned to a netclass at once
There is only a simplistic multi-net pattern expression
generator here (A|B|...) with a single prefix detected
rather than anything too fancy.

Fixes: https://gitlab.com/kicad/code/kicad/-/issues/21451
2025-08-12 20:00:33 +08:00
John Beard
299a6c6c7b Netinfo: avoid transitive string_utils.h include
Put the string manipuuation utils in the cpp, and
remove string_utils.h from the includes of netinfo.h.

This spams that header into about 350 files, not all of which
need it. Then go round and tidy up the places (most exporters
and dialogs) where CPP files weren't including string_utils.h
when they used it, as well as some other order-sensitive
include issues that turned up.
2025-08-12 20:00:15 +08:00
jean-pierre charras
09e1fca7e4 More about support of press-fit pad fabrication property
Also some fixes in dialogs.
2025-08-11 18:48:35 +02:00
Seth Hillbrand
77b99968ed Fix typo in previous commit 2025-08-10 20:25:35 -07:00