97 Commits

Author SHA1 Message Date
Andrzej Wolski
c73d555fe2 ADDED: Lasso selection in pcbnew
Adds a lasso or freeform selection tool to KiCad in addition to standard
rectangular selection.  Adds supporting HitTest routines

Fixes: https://gitlab.com/kicad/code/kicad/-/issues/1977
2025-08-06 16:06:40 -07:00
Jeff Young
e230d5164d Honour renderSettings' default font.
This still leaves a few things out in the cold,
such as hit-testing and polygon generation.
But at least it allows us to plot with a default
font.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/19031
2025-07-17 09:35:21 +01:00
Jeff Young
0495828a55 Honour front/back layer types for user layer.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/21284
2025-07-17 09:35:21 +01:00
Jeff Young
bdd8790180 Specialize table cell properties exposure.
(Also removes solder mask properties from textboxes.)

Fixes https://gitlab.com/kicad/code/kicad/-/issues/21224
2025-07-10 17:54:42 +01:00
Seth Hillbrand
b70f2269cb Ensure text ${LAYER} resolves to text not fp layer
We were resolving the footprint variables first for text objects.  This
resulted in always seeing the footprint layer resolution instead of the
text object if the text object was in a footprint.  But this only
happened in the board, not the fp editor.  This harmonizes the display

(cherry picked from commit b2bbee2375a6dfb7cdeacf0726e719c7ea69b194)
2025-06-03 11:52:51 -07:00
Damjan
af11746cc4 pcbnew and eeschema: Table and textbox rotation / text justification fix 2025-04-21 13:32:46 +00:00
Jeff Young
5371312c6f Make auto text thickness active. 2025-04-20 19:59:05 +01:00
Jeff Young
661d002234 CHANGED: moved footprint lock shadows to children.
A full bounding hull wash gets overwhelming on
boards with lots of mechanically-constrained
objects.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/14007
2025-04-03 14:38:14 +01:00
jean-pierre charras
76929808d3 PCB_TEXTBOX:: Rotate: fix size change for rotation by not 90deg
Fixes https://gitlab.com/kicad/code/kicad/-/issues/20529
2025-04-01 19:55:53 +02:00
Jon Evans
dc9fa2e2ac More functional fix for IPC API item modifications
Fixes https://gitlab.com/kicad/code/kicad/-/issues/20206
2025-03-28 20:27:45 -04:00
Jeff Young
413d6747c5 Collapse SCH_TABLE border drawing into shared code.
Also pushes GetCornersInSequence() into EDA_SHAPE
so it can be shared between SCH_TABLE and PCB_TABLE.

Also fixes bug in drawing column rulings over the
right external border.

Also fixes a bug with dialog control enabling.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/20350
2025-03-16 20:21:49 +00:00
Damjan
bded181ad0 pcbnew: table rotation: table jumps if rotation ends at 180° 2025-03-07 20:38:56 +00:00
Jeff Young
675624b926 ADDED: Knockout text boxes. 2025-02-24 11:08:29 +00:00
Damjan
5771467ca3 pcbnew: Table Rotation 2025-02-24 11:00:29 +00:00
Damjan
9c6ebb44b6 pcbnew: Table Cell Text Justification 2025-02-23 21:27:57 +00:00
Jeff Young
5edae8250d Finish eradication of visibility flag on text items.
Import/read previously-hidden symbol/footprint
text items as hidden fields.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/19875
2025-02-19 23:43:52 +00:00
Jeff Young
b64733e76b No hypertext for textboxes. 2025-02-10 16:15:14 +00:00
Jeff Young
6b6729284c Remove default line styles from all items except eeschema wires and buses. 2025-01-20 11:30:46 +00:00
John Beard
520a7cf62c GAL: ViewGetLOD should not be able to change the VIEW
Make the VIEW* parameter const. Since PCB_TEXT does a null-check,
it's not very clear if this can ever be null (and if it is,
why don't the other VIEW_ITEMs check?), so don't make them
all references too at this time.

Also dereference a few pointers a bit earlier to make non-null
promises sooner rather than later.
2025-01-02 22:59:31 +08:00
John Beard
527faddbfd GAL: provide constants for LoD HIDE/SHOW and a scale helper
Saves a mishmash of local HIDE/SHOW defs along with various literals.

Also provide a function that computes the scale at which a given
IU size becomes (notionally) a certain size on screen. While this
is a simple division, it's a bit opaque in terms of meaning.

Also it means the divide by zero case can be more universally
defended-against, which has traditionally been a bug opportunity.
2025-01-02 22:59:31 +08:00
Seth Hillbrand
0b2d4d4879 Revise Copyright statement to align with TLF
Recommendation is to avoid using the year nomenclature as this
information is already encoded in the git repo.  Avoids needing to
repeatly update.

Also updates AUTHORS.txt from current repo with contributor names
2025-01-01 14:12:04 -08:00
Seth Hillbrand
e9bc8cfe9d Give Clipper1 a Viking funeral
Clears out the last spot where we were only using Clipper1 (how'd I
miss that?) and remove all calls to the Clipper1 structures
2024-12-23 17:12:09 -08:00
Jeff Young
2926db778c Bug fixes for rotated tables. 2024-12-16 13:26:48 +00:00
Jon Evans
32684decbb API: Move locking to the PCB text objects 2024-11-28 11:48:01 -05:00
Jon Evans
3129e072c4 API: Move graphics and text handling to common
Required moving API_HANDLER_COMMON out of kicommon
2024-11-28 11:28:06 -05:00
Jon Evans
d64b17050d API: Serialize PCB_TEXTBOX 2024-11-24 17:25:56 -05:00
Seth Hillbrand
9dfcb6a362 Cleanup ViewGetLayers()
Old style c-array replaced with vector returns
2024-11-21 13:18:36 -08:00
John Beard
215533f31a Unify flip direction handling
There was a gentle mish-mash of booleans, some with
true being left/right and some up/down, and some functions that
can flip in both axes (which is never actually done, and doesn't
really make geometric sense).

Replace all this with the FLIP_DIRECTION enum class, which makes
the intention completely unambiguous.

This also then allows a small scattering of simplifications,
because everything takes the same type and you don't have to
fiddle booleans to fit.
2024-09-27 17:13:13 +01:00
Maciej Suminski
5ad5be0924 Text variable resolving in footprint text boxes
Mostly a code copy from PCB_TEXT::GetShownText() to
PCB_TEXTBOX::GetShownText().
2024-07-08 23:47:16 +00:00
Jeff Young
9d03a92738 Get rid of C++20 compiler warnings. 2024-07-03 13:32:44 +01:00
Jeff Young
aa5a370b3a ADDED: user layer types.
This allows a user to define user layers to be front
or back (and therefore to flip with the board view).

Fixes https://gitlab.com/kicad/code/kicad/-/issues/8455
2024-07-03 13:32:44 +01:00
Jeff Young
16340e6cf4 Support both short and long item descriptions. 2024-06-28 22:10:22 +01:00
Jeff Young
0040c290ed Don't flip alignment of non-side-specific text.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/18235
2024-06-22 23:54:57 +01:00
Jeff Young
aaf5c454ff Mask new shape properties from textboxes. 2024-06-22 23:54:57 +01:00
Jeff Young
fa0ead98d8 Split out table editing and table cell editing. 2024-02-24 20:05:51 +00:00
Jeff Young
4eefbc7815 ADDED: textbox and tablecell margins.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/10672

Fixes https://gitlab.com/kicad/code/kicad/-/issues/6806
2024-02-24 20:05:51 +00:00
Jeff Young
e445249720 ADDED: PCB tables. 2024-02-24 20:05:51 +00:00
Jeff Young
67cd446e6d Add textbox text to description.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/16573
2024-02-24 20:05:51 +00:00
Marek Roszko
835500bf1c Hide the color prop from pcb editor 2024-02-05 01:13:16 -05:00
Jeff Young
df83e24eb7 Cleanup.
It's been a long time since line style was specific to plotting.
2023-11-25 13:12:45 +00:00
jean-pierre charras
0904231000 Partial revert of commit d8498b62e0d44442b4e0038ed1fb765a796f0113, due to
comments in PCB_TEXTBOX::TransformShapeToPolygon()
2023-11-11 17:01:01 +01:00
jean-pierre charras
d8498b62e0 PCB_TEXTBOX::TransformShapeToPolygon(): fix incorrect transform: when it
is a polygon (rotated rect by a non cardinal angle) the polygon is not
filled, so the shape is just a set of thick segments.
Fixes #16072
https://gitlab.com/kicad/code/kicad/-/issues/16072
2023-11-11 16:44:04 +01:00
Jeff Young
7788c8f21c Fix textbox mirroring and rotation (again).
Fixes https://gitlab.com/kicad/code/kicad/-/issues/15576

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

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

Fixes https://gitlab.com/kicad/code/kicad/-/issues/14178
2023-11-06 14:03:58 +00:00
Seth Hillbrand
d99641be40 ADDED: Git integration support
Adds support for project-based git integration, branch support, commit,
revert and updates

Fixes https://gitlab.com/kicad/code/kicad/issues/10441
2023-10-20 12:51:47 +00:00
Alex Shvartzkop
d7863b09c5 Move CORNER_STRATEGY out of SHAPE_POLY_SET. 2023-10-06 15:42:50 +03:00
Jeff Young
8760bd8c80 Reconcile "apply defaults to new footprints" with DRC lib checks.
Moves apply defaults settings to Board Setup (where they were
duplicated anyway due to an earlier botched merge).

Modifies the apply-to-graphics algorithm to skip copper shapes.

Modifies DRC library check to skip STROKE_PARAMS for non-copper
shapes.
2023-10-02 22:10:13 +01:00
Jeff Young
469a94db8c Fix mirroring of TextBox.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/15576
2023-09-18 14:49:38 +01:00
Marek Roszko
63824487d0 Hide the unsupported Visible prop for textbox text 2023-09-04 09:28:59 -04:00
Marek Roszko
4b31de61b3 Rename txtbox props to border props 2023-09-04 09:28:59 -04:00
Jeff Young
aacb85bdab Make sure enum gets initialized. 2023-09-01 18:48:46 +01:00