309 Commits

Author SHA1 Message Date
Mark Roszko
1e9025a4dc Move to a fixed enum for page sizes as well as well as holding a list of types accessible in a vector.
Drops some hardcoded size names in places among other bits.

Woooo committed pushed at 36000 feet.
2025-09-13 20:12:53 +02:00
Seth Hillbrand
8acf5c1a25 ADDED: Rounded Rectangles
Fixes https://gitlab.com/kicad/code/kicad/-/issues/4742
2025-08-29 17:37:30 -07:00
Jeff Young
c758a2fbaf Don't sequence layers when order doesn't matter. 2025-07-14 19:12:44 +01:00
Jeff Young
b04057498d UNDEFINED_LAYER no longer copacetic for pads (KICAD-QOC). 2025-06-30 23:48:54 -06:00
Jeff Young
19a6669943 Set layerName before plotting drawing sheet.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/20959
2025-06-24 14:04:53 -06:00
Mark Roszko
ce545f4d6c ADDED: Ability to set a PDF background color for PCB plots
Fixes https://gitlab.com/kicad/code/kicad/-/issues/20873
2025-06-19 19:34:31 -04:00
Jeff Young
2844674449 Use courtyards for DNP cross-out sizes.
(And failing that, just pads and edges, no text.)

Fixes https://gitlab.com/kicad/code/kicad/-/issues/21115
2025-06-12 16:29:50 +01:00
jean-pierre charras
f892f39674 Pcbnew, plot zones on Silk and Mask layers: use actual filled areas.
Previously zone outlines were used, but it did not take in account rule areas
that can create holes in filled areas.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/21046
2025-06-02 16:25:31 +02:00
jean-pierre charras
0ddce3b210 PDF plot, auto scale: fix position of board on sheet
When not using a 1:1 scale, the board must be centered on sheet.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/20929
2025-05-15 10:35:59 +02:00
Jeff Young
5e6ef67fce Plot drill marks on mask layers if the pad exists there.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/20859
2025-05-10 19:07:13 +01:00
Jeff Young
34139ae305 Push generalised sketch-mode support down into DXF_PLOTTER. 2025-05-10 17:31:59 +01:00
Jeff Young
c78ce373fd Move pad-outline plotting to plot_brditems_plotter.cpp. 2025-05-10 17:31:59 +01:00
Jeff Young
c452fe9686 REMOVED: HPGL plotting.
Its sketch-mode greatly complicates the plotting
code and it is poorly maintained due to lack of
use.
2025-05-10 17:31:59 +01:00
Salvador E. Tropea
1c07703851 Add "scale" option to "pcb export plotter" CLI and JOB
- Not for gerbers
- DXF, HPGL, PDF, PS and SVG
- Remove the GUI limitation that prevented the use of border & title when
  using a scale != 1
2025-05-06 16:32:53 +00:00
jean-pierre charras
a02f1f2411 PDF plotter: fix a rare pen width issue when plotting many pages in one file.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/20805
2025-05-01 19:57:29 +02:00
Jeff Young
1f07c28999 Fix a bunch of errors involving implied line widths in plotters.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/20818
2025-05-01 16:37:08 +01:00
Jeff Young
5374bffb8e Formatting. 2025-05-01 16:36:33 +01:00
Jeff Young
79924b5dfd Don't gate drill mark plotting on unenabled copper layers.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/20460
2025-03-27 16:57:10 +00:00
jean-pierre charras
99e65afa1f Pcbnew, plot F&B Fab: ensure the DNP mark is plotted only on the right layer.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/20458
2025-03-26 16:26:30 +01:00
Jeff Young
0a4533703c Performance. 2025-03-24 10:28:41 +00:00
Jeff Young
824c7ecfa7 Improve readability.
Also drops a parameter that hasn't been implemented
since early 2022.
2025-03-19 08:55:32 +00:00
Jeff Young
1848401d5b Update layer per page.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/20352
2025-03-17 09:51:53 +00:00
jean-pierre charras
7f1b412203 plot mask layers: do not skip mask on track when solder mask min web is not 0
When solder mask min web is not 0, PlotSolderMaskLayer() uses GenerateLayerPoly(),
that skipped tracks (not updated since tracks can be on a mask layer)
2025-03-14 15:17:04 +01:00
Jeff Young
b569d919ea No more invisible (non-field) text. 2025-03-10 21:58:30 +00:00
Jeff Young
50174ec528 Beware of infinite recursion on colliding hatched shapes.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/20264
2025-03-08 21:23:14 +00:00
Marek Roszko
237953fd55 Move SVG_PLOTTER to {fmt} to punt locale issues 2025-03-05 19:03:25 -05:00
Jeff Young
b44261c2bd Handle clipping silk to mask when there is more than one layer. 2025-02-19 23:43:53 +00:00
Jeff Young
4959b480c3 Cleanup stale comments. 2025-02-19 23:43:53 +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
Seth Hillbrand
7911165294 Prevent overplotting copper layers
68fa45dea0115ae23a8650eb6f6ce05448a2d42e wanted to ensure that drill
marks were visible even when plotting non-copper layers.  However, this
had the effect of changing the plot order depending on whether drill
marks were shown or not.  The current solution is to overplot drill
marks if both copper and non-copper layers are shown.

This remains a sub-optimal solution as buried vias will be overplotted
along with through holes.  It may be a better long-term solution to gate
the plotting of covering pad layers' drill marks to the plot options
that include copper layers on the same page
2025-02-11 11:01:20 -08:00
Jon Evans
3364bd0a8b Plotter: Don't restrict via width query to copper layers
Fixes https://gitlab.com/kicad/code/kicad/-/issues/19458
2025-01-01 18:11:27 -05: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
Marek Roszko
17a1706257 ADDED: "Single document" PDF plot option for PCB plots 2024-12-30 23:51:42 -05:00
JamesJCode
dfe0d6345b Another go at supressing FOOTPRINT field on FOOTPRINT objects 2024-12-28 21:57:35 +00:00
jean-pierre charras
e848373307 Pcbnew: Fix vias not plotted by some plotters.
It was due to the fact via colors are no longer managed.
2024-12-24 12:40:38 +01: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
Jon Evans
9b1b318736 REMOVED: Footprint field from footprints
This field was redundant (was generally set to the footprint's LIB_ID)
but also buggy (not guaranteed to contain the footprint's LIB_ID)
and confusing (not a way to change the footprint's LIB_ID).
2024-12-01 15:50:40 -05:00
Jon Evans
7e1638ed11 Support via stacks in plotter 2024-11-04 22:27:50 -05:00
Seth Hillbrand
3f36d7f1dd Avoid negative pad sizes in plot
Clearance can be negative but setting the pad size to negative leads to
invalid output in plotting

Fixes https://gitlab.com/kicad/code/kicad/-/issues/18996
2024-10-29 15:32:18 -07:00
Wayne Stambaugh
43c3cd57eb Substitute variables in PDF plotter URI links and add file:// URI handler.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/14250
2024-10-24 08:06:28 -04:00
Andrzej Wolski
537d3ac81a ADDED: Soldermask layer option for tracks
Allows adding a soldermask opening for individual tracks.
Soldermask expansion can also be specified.

Fixes: https://gitlab.com/kicad/code/kicad/-/issues/2125
2024-10-08 02:48:33 +00:00
Jon Evans
2a605e4a4e Infrastructure and file format for via stacks 2024-10-06 18:45:25 -04:00
Jon Evans
752371833b Support custom padstacks in plotter 2024-10-02 18:07:09 -04:00
Jon Evans
56e0811516 Phase 2 of padstack support
CHANGED: PCB file format now supports saving/loading complex padstacks

CHANGED: PTH pads are now rendered per copper layer in the copper color;
         the PTH pad color is no longer used.

ADDED: support for importing complex pad stacks from Altium PCBs

Enforce padstack-aware access to pad properties across KiCad

Fixes https://gitlab.com/kicad/code/kicad/-/issues/8182
2024-10-01 19:55:03 -04:00
Mike Williams
867cb58175 feature removal: remove Show Hidden Text
Does not work properly since 8.0 introduction of footprint fields.

Fixes: https://gitlab.com/kicad/code/kicad/-/issues/18656
2024-09-19 15:41:44 -04:00
Seth Hillbrand
5e0abadb23 Reorganize layer numbering
F_Cu = 0
B_Cu = 2
Remaining internal copper layers are even and incrementing

Non-copper layers are odd and incrementing.

This means that we can no longer do things like:
for( PCB_LAYER_ID layer = F_Cu; layer <= B_Cu; ++layer)
Instead, we have the class LAYER_RANGE:
for( PCB_LAYER_ID layer : LAYER_RANGE( F_Cu, B_Cu) )

Similarly, gt/lt tests should not refer to the integer value of the
layer.  We have functions such as IsCopperLayer to test whether a layer
is copper or not.

When using the connectivity RTree, the third dimension is layer, so we
provide B_Cu with the special INT_MAX value, ensuring that elements
between F_Cu and B_Cu will be identified.  There is a new, special
function GetBoardLayer() for interfacing with CN_ITEMS

Similarly, PNS layers remain unchanged and sequential.  A set of
interface functions is provided to map PNS layers to Board layers and
back.  This allows the PNS_LAYER_RANGE to function as expected
2024-09-06 23:07:58 +00:00
Jeff Young
01332a2cb5 ADDED: plotting options for DNP footprints
Also removes the plot-fp-refs, plot-fp-values and
plot fp-text overrides from the GUI, but leaves
them as job arguments.

(Note that the job arguments also separate out
sketching DNP graphics and plotting the 'X', which
the GUI does not.)

Fixes https://gitlab.com/kicad/code/kicad/-/issues/18056
2024-08-18 10:02:14 -06:00
Jeff Young
b8819b4636 Another reduction in asserts. 2024-07-19 22:11:56 +01:00
Seth Hillbrand
e0453d9bcc Further cleanup of LSET
Remove duplicative functions.  Standardize on C++ stdlib formatting
2024-07-08 22:00:53 -07:00
Seth Hillbrand
cc850d0da0 Split out LSEQ/LSET from LAYER_ID
Separate the layer grouping classes for easier modification
2024-07-08 20:59:46 -07:00