7
mirror of https://gitlab.com/kicad/code/kicad.git synced 2025-04-18 00:29:10 +00:00
Commit Graph

7023 Commits

Author SHA1 Message Date
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
JamesJCode
d64a112971 Implement Component Classes
- Adds Component Class field to SCH_DIRECTIVE_LABEL
- Adds SCH_SYMBOLs to SCH_RULE_AREA item lists
- SCH_SYMBOLs resolve Component Class directives
- Netlist exporter / importer handles Component Class names
- Adds DRC expressions and functions
- Adds QA check for component class netlist export
2024-10-01 22:36:18 +01:00
Seth Hillbrand
ea6c53ba5d Re-enable low-translation testing languages
Languages lower on the translation level need to be enabled in the
master branch for testing
2024-10-01 10:59:47 -07:00
John Beard
e65221a479 Snapping: extension snaps on by default 2024-10-01 18:06:27 +01:00
John Beard
e23b83505e Snapping: delayed activation of snap points.
This makes it easier to control what snap points you are aiming for
without accidentally activating objects just by mousing near them
on the way to somewhere else.
2024-10-01 18:06:27 +01:00
Marek Roszko
d74caace0a Initial jobset creation and running within the CLI and GUI.
Incomplete, just pushing this before feature freeze, much fixing left
2024-09-30 20:04:53 -04:00
John Beard
460e575457 Use REFERENCE_IMAGE for SCH_BITMAP
Also wire in the transform origin handling to the point editor
and the properties panel in eeschema.
2024-09-30 10:20:20 +01:00
John Beard
3f131e2011 Abstract REFERENCE_IMAGE to a separate class
Break the non-PCB-specfic parts of PCB_REFERENCE_IMAGE out
to a common REFERENCE_IMAGE class, which is then composed into
the PCB_REFERENCE_IMAGE. This will make it easier to bring the
transform origin logic to eeschema without repetition.
2024-09-30 10:20:20 +01:00
jean-pierre charras
4a0f111fd6 Eeschema: add bitmap to tool Increment Annotations From... 2024-09-30 11:00:43 +02:00
jean-pierre charras
9979b4849e Pcbnew: Fix issue when flipping a graphic segment (SHAPE_T::SEGMENT).
PCB_SHAPE::Normalize() normalized a graphic segment by (sometimes) swapping
start and end points. But it creates an issue when flipping a segment: the
reference point can be changed.
This normalization was made for DRC purpose when comparing 2 footprints.
Now, PCB_SHAPE::Normalize() does not change end points of a segment, and a
specific PCB_SHAPE::NormalizeForCompare() normalize fct is used for DRC compare.
2024-09-28 17:40:08 +02: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
Astropeak
3066ad2088 Pcbnew: make 'Flip board items' option more clear
CHANGED: The 'Filp board items' checkbox in the 'PCB Editing Options'
was changed to a radio box.

Fixes: https://gitlab.com/kicad/code/kicad/-/issues/16652
2024-09-27 17:13:13 +01:00
jean-pierre charras
e2282a4af8 Minor cosmetic enhancement: add icon to Revert and Generate Legacy BOM tools 2024-09-27 13:34:20 +02:00
jean-pierre charras
51d615d30d Minor cosmetic enhancement: add icon to "Create Outsets from Selection" tool 2024-09-26 20:13:43 +02:00
John Beard
b3248095e8 Pcbnew: add bezier editing tool
Adds the initial implementation of bezier overlay
(assistant) and geometry manager. This is only
implemented in Pcbnew - the code is common, but
eeschema doesn't currently use it for any shape.

Relates-To: https://gitlab.com/kicad/code/kicad/-/issues/8828
2024-09-25 21:41:32 +01:00
John Beard
30e51f7d1a Pcbnew: Show some helper lines in point editor
Some shapes, like arcs and beziers have "lines" that
can be useful to see when editing, but aren't directly
editable and may not overlap the object's own lines.

So make it possible to, indepedently:

 - Turn off the centre-point drag handle affordance
 - Show the actual line segment on screen.
2024-09-26 10:17:23 +01:00
Mike Williams
53022ab347 mouse settings: add reverse zoom option
Fixes: https://gitlab.com/kicad/code/kicad/-/issues/18583
2024-09-23 17:09:44 +00:00
John Beard
95beedb612 Dogbones: add slots for acute angles
It's actually not as hard as I thought, though
surely has wierd edge cases which users might need to
handle manually.
2024-09-22 13:45:19 +01: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
John Beard
46e7228945 UNIT_BINDER: Handle binding of combo-box option lists
This is useful if you want to give some preset options
to a user (e.g. recently used value) but stil have them
controlled and presented using the UNIT_BINDER logic.
2024-09-19 06:35:43 +01:00
John Beard
653d85f9fc Abstract LIB_TABLE IO to allow non-file-based tables
Mostly intended right now for allowing testing of library tables
to help with testing chained loading, but it also decouples the
idea of a library table from on-disk files in general.

All current (real) lib table implementations continue to use the
file-based IO.

This could be made more general (not just for tables) if really
needed.
2024-09-19 06:35:43 +01:00
Alex Shvartzkop
05b4aace38 Fix an issue causing "zbot < ztop" assert in 3D viewer on multilayer boards. 2024-09-19 10:07:32 +05:00
Jon Evans
4e7fcb3b67 Temporary patches around LSET and negative layers
Probably this should be replaced with a less error-prone
approach.  Right now the LSET -> BASE_SET system is risky
because it is converting a signed enum (PCB_LAYER_ID) to
a size_t in all the underlying operations.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/18738
2024-09-18 18:36:17 -04:00
jean-pierre charras
b2e4e9be9c Update outdated comments. No code change 2024-09-18 17:25:30 +02:00
Mike Williams
87a66d4df1 grids: make settings panel correctly implement cancel
Before we edited the grid settings directly so cancel would keep your
changes.

Also includes numerous QoL improvements borrowed from Ian's patch,
and a few other small fixes.
2024-09-18 10:49:12 -04:00
John Beard
99e1869987 Fix build: use same signature for alg::lexicographical_compare_three_way as std::
This makes it clearer that it is a polyfill-type affair
and make it easier to swap for the std:: one when the
compiler support is guaranteed.

Also avoid double underscores in parameter names,
as well as underscore-capital latter as they are reserved.
2024-09-18 06:56:03 +01:00
Seth Hillbrand
f978fd4436 Fix build for MacOS
Accidentally removed our patch to allow three-way compare on MacOS
2024-09-17 22:25:44 -05:00
Eric
1506beecbc Implement ODB++ export
ADDED: Add support in Pcbnew for exporting ODB++ files under Fabrication
       Outputs, base on ODB++Design Format Specification (Release v8.1
       Update 3 February 2021).

Note: There is still a lot of work to do if we will make the feature as
      complete as the ODB++ spec.  However, the current functionality's
      completeness is already sufficient to cover general production
      scenarios. I have compared the output results with Gerber files by
      DFM tool and the accuracy at the graphic level should be able to
      cover most usage scenarios.  Additionally, I am very grateful to
      the great open-source project Horizon EDA for giving me a lot of
      inspiration in terms of ideas.

The feature can be enabled by adding "EnableODB=1" to the kicad_advanced
configuration file.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/2019
2024-09-14 15:34:51 +00:00
jean-pierre charras
d2cb868829 Pcb editor and 3d viewer: fix some issues:
- Fix incorrect values of displayed layers of blind/buried vias
- Fix possible incorrect layer order in PCB_VIA::SanitizeLayers()
- fix some display issues in 3D viewer.
- fix issue in LAYER_RANGE::Contains(): sometimes the test was incorrect.
2024-09-14 15:57:56 +02:00
Mike Williams
337211adea grids: allow editing existing grids
Fixes: https://gitlab.com/kicad/code/kicad/-/issues/16870
2024-09-12 15:19:34 -04:00
John Beard
ebef24b6b0 Debug: graphical snap anchor debug mode
When working near snap anchors, which come and go
rapidly, it's often useful to see what snaps have been
calculated. Add an advanced config to show these
(EnableSnapAnchorsDebug) on an overlay layer.

With more polish this could be a hotkey or something.
2024-09-11 22:35:35 +01:00
John Beard
6bad4bb1a2 Put extension snaps behind an advanced config
This can be backed out when the snapping bevaviour is
considered good enough to be on by default.
2024-09-11 22:35:35 +01:00
John Beard
b2be0d39bd Snapping: Add construction geometry snapping
This is a pretty major rework of the snapping system.
The GRID_HELPERs now have a separate CONSTRUCTION_MANAGER
which handles some of the state involving "construction
geometry".

This is fed with 'extended' geometry (e.g. "infinite" lines from
segments) for use in generating things like intersection points.
It also handles adding this geoemtry to a GAL view item
(CONSTRUCTION_GEOM) for display to the user.

The process is:

* A TOOL creates a GRID_HELPER
* Optionally, it pre-loads a "persistent" batch of construction
  geometry (e.g. for an item's original position)
* The grid helper finds useful snap 'anchors' as before, including
  those involving the construction items.
* Other items on the board can be 'activated' by snapping to one
  of their main points. Then, if it has construction geometry,
  it will be added to the display. At most 2 items of this kind of
  geometry are shown, plus the original item, to reduce avoid
  too much clutter.

The dashed snap lines state machine is also handled in the
CONSTRUCTION_MANAGER and displayed in the CONSTRUCTION_GEOM item.
2024-09-11 22:35:35 +01:00
John Beard
a3a3f7648e Break ERROR_LOC out to its own header
Having this in geometry_utils.h means that touching
that header affects nearly every file, as this type is used
in EDA_SHAPE, BOARD_ITEM and SHAPE.
2024-09-11 22:08:36 +01:00
Mike Williams
2eec2489ea design blocks: move globals behind accessor functions
Prepare for lazy loading
2024-09-10 15:50:03 -04:00
Marek Roszko
aceca713d8 Fix kicommon exports 2024-09-08 08:00:47 -04:00
Marek Roszko
00f2e56e51 IO_BASE must be dllexport/dllimport specified as a base class 2024-09-07 22:37:05 -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
Seth Hillbrand
be2a52dd2b Avoid GL ctx deadlock
Allow non-drawing routines to access error messages without dealocking
the load
2024-09-06 16:00:49 -07:00
Seth Hillbrand
5ba50c26a9 Update embedded files hash to use Murmur3
SHA256 is fine for one-offs but for large libraries where we might be
running the hash on hundreds of files, the speed difference is
appreciable.  We don't require crytographic hashing, just a check that
the original file hasn't been corrupted so Murmur3 satisfies our basic
requirement.
2024-09-06 09:57:23 -07:00
Jeff Young
ca5fb08f62 Ensure thread safety with EDA_PATTERN_MATCH_RELATIONAL. 2024-09-05 17:37:49 +01:00
Mike Williams
2c99bc6c6d new feature: Schematic Design Blocks
Added to advanced config, default to off.
EnableDesignBlocks=1 in kicad_advanced to test

Fixes: https://gitlab.com/kicad/code/kicad/-/issues/2263
2024-09-05 08:35:49 -04:00
Alex Shvartzkop
c1e255c4fe Fix unreachable code warnings on non-OSX. 2024-09-05 06:17:16 +03:00
Alex Shvartzkop
36019314e9 Make simulation reporter warnings non-fatal.
Adds REPORTER::HasMessageOfSeverity for WX_STRING_REPORTER,
which allows us to show simulation warnings and fail only if there's errors.

Also fixes a crash when SPICE_GENERATOR_KIBIS throws an IO_ERROR.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/18143
2024-09-05 05:59:35 +03:00
Jeff Young
94f995c49e Reduce dependency on dynamic_cast.
(Especially where it is no-worky on MacOS.)

Fixes https://gitlab.com/kicad/code/kicad/-/issues/17245
2024-09-04 17:24:49 +01:00
Marek Roszko
89a3b7baa5 Move some things starting from reporter to kicommon 2024-09-02 21:15:14 -04:00
Alex Shvartzkop
88272a59b7 Fix MSVC build. 2024-08-29 04:57:13 +03:00
Jeff Young
3441861988 Make arrow keys respect grid overrides. 2024-08-28 19:54:23 +01:00
Seth Hillbrand
86c0aec468 Move zone connection filler out of AC
New algorithm to prevent zone fills that are smaller than the minimum
copper width.
2024-08-28 09:04:51 -07:00
John Beard
b043f334de Update font when needed on italic/bold change
When the italic or bold nature is changed, text using outline fonts may
need to change its font. Add this to the SetItalic/SetBold functions.

Also add a counterpart SetItalicFlag function (following SetBoldFlag)
when you only need to set the flag (e.g. when importing or changing
everything in the text properties dialog).

Fixes: https://gitlab.com/kicad/code/kicad/-/issues/18592
2024-08-28 13:49:36 +01:00
John Beard
0818ee1770 Pcbnew/FPedit: Add snap anchor type indicators
This allows to see what the current snap point is, which is useful when
zoomed in, or the point is like the corner of a rounded pad where it's
"in free space" and might not be immediately obvious.
2024-08-28 13:49:36 +01:00
Mark Roszko
c19aa8170b Revert "Move some things starting from reporter to kicommon"
This reverts commit 3d893254e9
2024-08-28 01:21:40 +00:00
Marek Roszko
3d893254e9 Move some things starting from reporter to kicommon 2024-08-27 20:33:08 -04:00
Jeff Young
b549c4feec Drawing sheet can't share glyph cache entries with editors.
(They use different internal units.)

Also fixes a fialure of CAIRO_GAL to reset the fill
and stroke after drawing outline glyphs.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/18579
2024-08-22 12:23:21 -06:00
Seth Hillbrand
7214ef1f14 Remove basic masking class map_string_utf8
This is just std::map<std::string, UTF8>, using the class just masks
what it is and adds unclear functions.
2024-08-19 11:51:13 -07:00
Marek Roszko
9eae3330ca Use std::array for rstring and elems 2024-08-18 22:04:00 -04:00
Marek Roszko
b101c1a0c3 Enum class ELEM. 2024-08-18 21:09:37 -04:00
Marek Roszko
58e3c5bb6b Rename Type() to ProjectElementType() for _ELEM children 2024-08-18 20:30:45 -04:00
Seth Hillbrand
b6c1a3ba63 Move SetLayerSet to const reference
Avoids potential performance inefficiencies
2024-08-17 07:56:30 -07:00
Mark Roszko
869a3ee21f Unbind events in KISTATUSBAR destructor 2024-08-16 02:21:37 +00:00
Jeff Young
79ec93da4c Ensure that EDA_PATTERN_MATCH_RELATIONAL is thread-safe.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/18548
2024-08-14 15:46:25 -06:00
Seth Hillbrand
a724b3d8b1 Handle DXF files with out of bounds values
First, ensure that we calculate the bbox of the imported elements.

If the total BBOX is outside our allowed value, refused to import.  This
needs to be scaled or addressed in an external editor

If the bbox fits, then make sure that we clamp it such that the largest
element is still within our bounds

Fixes https://gitlab.com/kicad/code/kicad/-/issues/18523
2024-08-14 13:06:18 -07:00
Kacper Słomiński
e6bcc6d0a6 Fix build issue with experimental GCC version 15.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/18539
2024-08-14 07:34:18 -04:00
Tomasz Wlostowski
54e5632a42 multichannel: put MC tool behind an ADVANCED_CFG flag 2024-08-13 22:50:26 +02:00
Tomasz Wlostowski
9963b9dd9f TOOL_INTERACTIVE: only create the context menu when we are running in GUI mode
TOOL_MENU::m_menu was unconditionally created by the TOOL_INTERACTIVE constructor, resulting in crashes if
we wanted to run the TOOLs in headless  mode, e.g. in unit tests. This commits makes
the creation of the menu object dependent on Pgm::IsGui().
2024-08-13 22:50:26 +02:00
John Beard
f2d2e953f7 Fix clang warning (need virtual dtor) 2024-08-13 08:36:10 +01:00
JamesJCode
19d5d21f23 Move netclass highlighting style to application-level setting
Also includes bugfix whereby wires, junctions, and bus entries
were not subject to override of local colors.
2024-08-12 23:52:01 +01:00
JamesJCode
ea482e8d15 Revert NET_SETTING schema increment 2024-08-12 22:40:12 +01:00
JamesJCode
6371b15aa4 Implement highlighting style for netclass colors 2024-08-12 21:39:07 +01:00
Jon Evans
4332618e68 Fix uninitialized member 2024-08-12 08:27:24 -04:00
Jeff Young
f89ba38b66 ADDED: importing text vars from Schematic Setup.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/18465
2024-08-11 19:33:15 -06:00
Jon Evans
bd946313dc ADDED: Position items relative to arbitrary reference point
Fixes https://gitlab.com/kicad/code/kicad/-/issues/4756
2024-08-11 18:59:26 -04:00
Jeff Young
5ad8f0e387 Better OnModify() handling for Symbol Fields Table. 2024-08-11 12:45:36 -06:00
Seth Hillbrand
094d265313 Re-enable grid snap line
This was accidentally disabled by 4039b7da6b
2024-08-08 14:29:27 -07:00
John Beard
d933ed964e Move LAYER_PRESENTATION to widgets/
Since this is code used by widgets for UI presentation purposes.

Also saves some unnexessary includes in headers.
2024-08-07 06:49:53 +08:00
John Beard
0c3ac40bb6 LAYER_PAIR doesn't need a comparison
This upsets the Windows build and isn't needed as there's no
container used that needs the operator.
2024-08-07 06:13:24 +08:00
John Beard
c989a7ba83 Don't use layer pair in common code 2024-08-07 05:42:18 +08:00
Wayne Stambaugh
d75c3d5791 Fix a build error on Linux.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/18503
2024-08-06 16:20:40 -04:00
John Beard
edf13bdfd0 Add a layer pair preset list
This will later be used for a quick switcher UI. This commit
adds the data structures, set-up UI and project file persistance.

Relates-To: https://gitlab.com/kicad/code/kicad/-/issues/15227
2024-08-06 23:45:55 +08:00
John Beard
db457f52fa Move layer presentation logic to a separate class
The separates it from the LAYER_SELECTOR class - deciding
what color a layer is (say) is separate to managing the
actual selection of the layer. For example, sel_layer.cpp
only needs the presentation logic. This also makes it eaiser
to compose rather than inherit.

Additonally, break out the layer pair swatch function
to this class.

This will also be needed by the layer pair manager UI.

Relates-To: https://gitlab.com/kicad/code/kicad/-/issues/15227
2024-08-06 23:45:55 +08:00
John Beard
15924958d9 Add wxGrid autosizer helper
This moves a fiddly little bit of logic used by a few UI
classes into a central location.

Also means that the paths dialog learns to expand the
first cell when it needs to (like the text variable
panel).
2024-08-06 23:45:55 +08:00
Alex Shvartzkop
377b9aa859 Fix warning: 'const' qualifier on return type has no effect. 2024-07-28 03:34:17 +03:00
James J
7ce00e511b Multi-netclass support 2024-07-26 20:49:29 +00:00
Seth Hillbrand
433677fc21 Replace std::lexicographical_compare_three_way
On platforms that don't yet support the std:: version, we implement our
own, possibly slower, version of the 3-way compare
2024-07-24 18:03:29 +02:00
Jeff Young
431087fc7c Don't deadlock when adding rows. 2024-07-23 17:49:34 +01:00
Jeff Young
0f099ac65e Use lock when clearing and loading libTables.
Also make sure it's re-indexed after loading.
2024-07-23 09:53:01 +00:00
Alex Shvartzkop
e2bd76bdce Fix OOB access in LSET when opening a PCB file or updating from schematic.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/18422
2024-07-23 01:41:01 +03:00
Jon Evans
5120a3bd82 Fix incorrect lambda capture 2024-07-21 17:29:24 -04:00
Seth Hillbrand
a13df1ec28 Fix broken rebase 2024-07-17 15:20:29 -07:00
Seth Hillbrand
6182069c0c Fix shadowing 2024-07-17 15:19:32 -07:00
Jon Evans
c66f862a39 Quiet a warning 2024-07-17 18:17:17 -04:00
Alex Shvartzkop
17f44c0dc1 Fix some warnings and improve memory layout. 2024-07-17 23:20:32 +03:00
Seth Hillbrand
d0292c39fc Fixes for MSVC 2024-07-17 11:41:13 -07:00
Seth Hillbrand
7ecde84a94 Move LSET to new BASE_SET class
Next step in large layer refactoring.  Added multiple unit tests as well
to check behavior
2024-07-17 10:32:09 -07:00
Mark Roszko
5f63e1dec5 Fix build error on windows 2024-07-17 11:50:41 +00:00
Seth Hillbrand
535ed165a6 Add BASE_SET class 2024-07-16 17:52:32 -07:00
Seth Hillbrand
c093fe1355 Simplify LSEQ
Remove unneeded operators and index
2024-07-16 14:48:33 -07:00
Marek Roszko
c16d078b8c Fix conflict with windows header define thats leaking in
GetTempFileName is a windows header define unforunately and the big boi header is leaking in somehow
2024-07-15 20:22:33 -04:00
Seth Hillbrand
77797103f7 Add ability to embed files in various elements
Schematics, symbols, boards and footprints all get the ability to store
files inside their file structures.  File lookups now have a
kicad-embed:// URI to allow various parts of KiCad to refer to files
stored in this manner.

kicad-embed://datasheet.pdf references the file named "datasheet.pdf"
embedded in the document.  Embeds are allowed in schematics, boards,
symbols and footprints.  Currently supported embeddings are Datasheets,
3D Models and drawingsheets

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

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

Fixes https://gitlab.com/kicad/code/kicad/-/issues/17827
2024-07-15 16:06:55 -07:00
Alex Shvartzkop
77eb197a21 Fix build on GCC 14.1.1. 2024-07-15 13:38:34 +03:00
jean-pierre charras
3bacfacf95 Ensure non handled text properties are never written in .kicad_pcb files
ctl_flags.h: fix two duplicate flag values.
2024-07-14 20:45:40 +02:00
jean-pierre charras
a075a80b3c Move all CTL_OMIT_xxx flags definitions into a new file ctl_flags.h
Previously, they were defined in different files, and sometimes redefined.
This change should not create an actual code change.
However, this move shows there are the same value used for different flags,
so another fix should be made later.
2024-07-14 18:10:37 +02:00
Seth Hillbrand
ffe496abf3 Cleanup for Project Backup
Do conservative check for time offset before making the expensive
backup.  Don't clear and re-check the file list for a single file change
2024-07-11 10:48:13 -07:00
Harry Best
cc5fb60d93 CHANGED: Backup project only when different
Makes a test backup file and compares to the existing zip file backup to
see if the files have changed since it was made.  If so, the new file is
kept.  If not, we discard the new file and continue

Fixes https://gitlab.com/kicad/code/kicad/-/issues/12453
2024-07-11 10:48:13 -07:00
Seth Hillbrand
845130ba9e ADDED: pcbnew fill avoids kissing fills
Previously, fills could end up just barely touching, leading to DRC
errors even if there was enough room to fill the remaining space.  This
was due to how we shrink/expand the zones to remove small features.  By
adding a zero-width line between points that should be connected, we
expand back to the correct width.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/14130
2024-07-10 18:34:41 -07:00
Seth Hillbrand
e8f3545423 Update max recursiondepth default per @jeffyoung 2024-07-10 08:29:15 -07:00
aris-kimi
6969b9d64f Open library file preselected in the file explorer for both symbol and footprint editors. 2024-07-10 06:14:04 +00: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
Seth Hillbrand
293075426b Clean up some LSEQ functions
We are derived from std::vector now.  We don't need our own prima donna
increment and dereference overload as these just create bloat and
non-standard coding practices
2024-07-08 20:59:46 -07:00
Jeff Young
02a08bf9b1 ADDED: RMB > Copy item for HTML_WINDOW.
(Used at least in Footprint and Symbol Chooser details
panes.)

Fixes https://gitlab.com/kicad/code/kicad/-/issues/17904
2024-07-08 20:55:08 +01:00
Seth Hillbrand
c0bf866c58 Speed up shutdown
When shutting down, we shouldn't need to do a lot of things like
resyncing the PNS world multiple times that can really slow down the
process
2024-07-05 11:16:20 -07:00
Alex Shvartzkop
0a53fc41a7 Shut down curl operations before global cleanup.
Fixes KICAD-7DP
Fixes https://gitlab.com/kicad/code/kicad/-/issues/17103
2024-07-04 22:33:59 +03: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
Seth Hillbrand
b4760b9b2c Add ADVANCED_CFG variable for recursion depth of variables
At 10, a strict recursion shows a noticable lag in schematics with
larger numbers of fields.  2 may be a sweet spot unless we find a
schematic where this does not work
2024-07-02 11:37:21 -07:00
Jeff Young
16340e6cf4 Support both short and long item descriptions. 2024-06-28 22:10:22 +01:00
Seth Hillbrand
9e82d7c93c Decrease font error allowance
This is activated when changing bezier into segments and sets the
minimum allowance in 1/16 of the font's internal units.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/18300
2024-06-28 12:11:49 -07:00
Jon Evans
c70ef36739 ADDED: Opacity control for filled graphic shapes
Fixes https://gitlab.com/kicad/code/kicad/-/issues/18253
2024-06-26 22:29:58 -04:00
Jeff Young
080cbbe0dd Error reporting for drawing sheet loading. 2024-06-24 20:22:29 +01:00
Seth Hillbrand
11c6164934 Silence font replace warnings for libs
When loading schematics/pcbs, notification of font replacements might be
warranted but in libraries, this warning is not helpful and intrusive
2024-06-24 09:55:10 -07:00
Jeff Young
968ef0082d Handle undo of a Repeat Draw Item.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/18261
2024-06-24 13:59:05 +01:00
Alex Shvartzkop
ece46223c9 Fix shadowed/conflicting enum values. 2024-06-21 16:16:29 +03:00
Alex Shvartzkop
1bb507e3c4 Reduce VERTEX_ITEM size by removing vfptr.
24 -> 16 bytes.
2024-06-20 19:08:07 +03:00
Alex Shvartzkop
386651153b Improve EDA_ITEM memory layout slightly. 2024-06-20 15:33:56 +03:00
Alex Shvartzkop
b143ffb797 Reduce KIID size from 20 to 16 bytes.
Removes separate legacy timestamp value.
2024-06-20 13:59:15 +03:00
Jeff Young
8e349eedf0 Bug fixes for PCB_TABLES.
In particular, rotated tables and tables in rotated
footprints.
2024-06-19 12:39:22 +01:00
Seth Hillbrand
bcf6b620a8 Large rework of BEZIER_POLY
Add direct handling of quadratic beziers to save compute time and number
of points.  Update cubic interpolation to reduce number of points
generated for a given smoothness

Cache data on open and used cached data to avoid multiple re-calcs

Remove minimum line length and number of segments and replace with
standard max error level.  Allows us to specify the tolerance of bezier
interpolation
2024-06-18 17:55:41 -07:00
Jeff Young
90cd3286fa Remove cover types. 2024-06-16 10:47:48 +01:00
Jeff Young
5a9b681009 Clear timestamp when clearing cache.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/17913
2024-06-16 10:46:36 +01:00
Jeff Young
7fef6e8d83 Use view's RTree for redrawing netnames. 2024-06-14 00:20:37 +01:00
Jeff Young
0ca7a81181 Deferred redraw for netnames. 2024-06-12 17:20:20 +01:00
Jeff Young
b7161181e8 Hidden footprint libraries are not yet supported.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/18183
2024-06-12 16:59:20 +01:00
Jeff Young
694a7db457 Performance improvements.
Don't construct a wxString or a LSEQ when you don't
have to.  They're both more expensive than you might
think.
2024-06-12 11:06:10 +01:00
Jon Evans
5fc0f1f51e ADDED: Independent control of front/back via tenting 2024-06-11 21:50:25 -04:00
Jon Evans
4aab9f59aa ADDED: Support tenting control of individual vias
REMOVED: Tenting option from plot dialog (tenting is now
         controlled from Board Setup and via properties)

See https://gitlab.com/kicad/code/kicad/-/issues/2402
2024-06-11 21:25:02 -04:00
Wayne Stambaugh
889931505b Eagle schematic importer improvements.
Change Eagle file importer to use a two pass import.  The first pass
parses the entire Eagle file into an associated E* object.  The second
pass converts the parsed E* objects into the appropriate KiCad objects.

Improve handling of Eagle versioned libraries.

Add helpers to IO_BASE to ease handling of PROGRESS_REPORTER and REPORTER
objects.

ADDED: Support for importing Eagle schematic modules.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/1813
2024-06-10 11:28:20 -04:00
jean-pierre charras
b20a32f2fd bitmap_info.xxx: add comments to try to avoid issues like 8b1e971f
No actual code change
2024-06-08 20:18:11 +02:00
Alex Shvartzkop
4b96bb5d8f Support touchscreen gestures (zoom/pan/rotate) in 3D viewer.
Though rotate doesn't work yet on MSW due to a wxWidgets bug.
2024-06-08 21:13:16 +03:00
Jeff Young
ed0869aa0c Share more library tree code. 2024-06-08 19:06:10 +01:00
Alex Shvartzkop
8f8a68229c Handle touchscreen gesture events for zoom/pan. 2024-06-08 16:00:34 +03:00
Alex Shvartzkop
8e90063258 Support hidpi in Cairo GAL canvas; performance improvements.
We now draw onto wxBitmap directly, reducing the amount of copying.
Also moves the bitmap blit into paint event handler.
Modifies ClearScreen to work universally between Cairo/OpenGL backends.
2024-06-08 12:51:27 +03:00
Seth Hillbrand
9f2c9636f0 Update conn minor check to use Advanced Config 2024-06-03 11:56:37 -07:00
Jeff Young
ec0fdfffff ADDED: markers for excluded-from-sim items.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/15382
2024-06-03 17:12:15 +01:00
Jeff Young
4a01f322ff Special-case hit-testing of filled schematic rule areas.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/17879
2024-06-01 22:48:02 +01:00
Alex Shvartzkop
6d6f6f384e Fix MSVC warning C4355: 'this': used in base member initializer list. 2024-06-01 06:49:30 +03:00
Alex Shvartzkop
cf7ad330e9 Fix some platform ifdef checks. 2024-06-01 06:49:11 +03:00
Jeff Young
931de12072 Use wxWidgets to track DPI.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/17981
2024-05-31 17:08:43 +01:00
Jeff Young
1eb26b439a REMOVED new footprint dialog.
We now just create an "Untitled" footprint.

Also fixes a bug where the preview of new footprints
would zoom in too far.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/17573
2024-05-31 10:36:51 +01:00
Jeff Young
b88d3b13ac ADDED: sketch-pads-on-fab-layers to CLI PDF & SVG export.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/18091
2024-05-27 20:59:11 +01:00
xx
5ff61ae561 Add rectangle height and width to properties
Fixes https://gitlab.com/kicad/code/kicad/-/issues/17181
2024-05-27 17:28:32 +00:00
Jeff Young
bc14a841cb Check for drilled hole errors in Footprint Checker.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/18093
2024-05-27 13:51:21 +01:00
Alex Shvartzkop
b6aa01a572 Accept bitmap bundles for menu items (but don't use it yet). 2024-05-27 01:02:12 +03:00
Alex Shvartzkop
2a5903cd9b More universal way of scaling indicator icon bitmaps. 2024-05-26 22:14:52 +03:00
Seth Hillbrand
ab0426d620 Detect if HiDPI cursors are needed
HiDPI cursors are twice as large as regular cursors, allowing them to be
more easily seen on a HiDPI system

Fixes https://gitlab.com/kicad/code/kicad/-/issues/16231
2024-05-26 07:51:15 -07:00
Jeff Young
30b5adde17 Fix spacing/scaling of indicators on MacOS.
Also pushes indicator scaling improvements to GerbView.
2024-05-26 14:37:05 +01:00
Alex Shvartzkop
b64a30f44b Fix color swatches and color picker dialog on GTK with window scaling. 2024-05-26 13:02:37 +03:00
Alex Shvartzkop
0b4ff7b859 Improve indicator icons in hidpi monitors. 2024-05-26 01:16:47 +03:00
Alex Shvartzkop
894bf45480 Make color picker dialog usable on hidpi monitors.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/17860
2024-05-25 04:13:13 +03:00
Jeff Young
ecb7cd6b84 Fix color-swatch sizing on MacOS.
Also fixes BITMAP_BUTTON sizing.
2024-05-24 18:27:15 +01:00
Jeff Young
397ae3bafd Support wildcards and regEx's in Net Inspector.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/18071
2024-05-24 12:24:05 +01:00
Alex Shvartzkop
884051fae1 Update status bar widths on DPI change. 2024-05-23 20:22:13 +03:00
Wayne Stambaugh
795a9eea60 Coding policy fixes.
This is primarily to change all instances of wxLogDebug with wxLogTrace
so developers do not have to sift through debugging output that is always
dumped.  The only exception is for code blocks built in debug builds and
called on demand for dumping object states.
2024-05-23 07:59:45 -04:00
Jeff Young
edae328ca6 Push multi-sweep traces down into MathPlot.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/17215
2024-05-23 12:24:56 +01:00
Alex Shvartzkop
492ce600a4 Improve message panel alignment on hidpi monitors. 2024-05-23 00:40:47 +03:00
Alex Shvartzkop
77b285c8ce Improve BITMAP_BUTTON behaviour when changing DPI. 2024-05-23 00:40:47 +03:00
Jeff Young
e332320108 Handle font when reading render cache.
(Also fixes a bug where the cache's triangulation wasn't
cached.)

Fixes https://gitlab.com/kicad/code/kicad/-/issues/17666
2024-05-21 11:31:35 +01:00
Alex Shvartzkop
4e306a7d76 Remove useless method (ResyncBitmapOnly) 2024-05-21 03:46:09 +03:00
Jon Evans
2836025402 Clear field listener when quitting
Fixes https://gitlab.com/kicad/code/kicad/-/issues/18016
2024-05-16 20:49:27 -04:00
Jeff Young
f7bef5e09b Generalize EnhanceAttr() function.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/17735
2024-05-16 16:28:13 +01:00
Jon Evans
c800fb790d Start unifying padstack properties 2024-05-14 20:57:56 -04:00
Jeff Young
d9ff3c4485 Maintain selection when sorting.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/17983
2024-05-11 16:20:34 +01:00
Seth Hillbrand
42ebf0eca5 Limit FSWatcher
Library watches only need a single directory or immediate children.  The
project watcher should have a sensible limit to the total number of
files it tries to track.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/15717
2024-05-09 15:42:25 -07:00
Marek Roszko
f87bd91d61 Move libeval to kicommon 2024-05-07 20:44:19 -04:00
Seth Hillbrand
c8375c151c Launch default URI handler if exists
Otherwise, handle as a normal file

Fixes https://gitlab.com/kicad/code/kicad/-/issues/17902
2024-05-06 12:22:40 -07:00
Alex Shvartzkop
5475359d00 More build time optimizations. 2024-05-06 04:39:28 +03:00
Seth Hillbrand
a835ba0715 Add "Mechanical" pad property
Prevents mechanical support pads from being used to check pad types.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/16747
2024-05-05 21:57:10 +00:00
Jeff Young
1290228fbf Don't modify radius when editing center.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/17192
2024-05-05 19:58:01 +01:00
Alex Shvartzkop
5e14ae9698 Add OpenGL info to About. 2024-05-05 21:30:25 +03:00
JamesJCode
658eb1d338 Assert if NESTED_SETTINGS migration is missing for an intermediate version
- Fixes early load during NESTED_SETTINGS construction within
  SCHEMATIC_SETTINGS, now failing due to missing migrations at that
  object construction point
- Adds missing (NOOP) migration for NET_SETTINGS schema versions 1 -> 2
2024-05-05 19:12:01 +01:00
John Beard
fa7e842c8c Rework item distribution
This splits the tool into two separate tools: by center and
by even gaps. Previously, this was automatically decided, based on
if the items could have any gaps between them. This was unintuitive
as it would appear to arrange by centre point sometimes but not others.
When items aren't all the same width, the results can then be very
different, based only on the starting positions.

The new behaviour is to have a dedicated tool for each, which echos
how graphical programs like Inkscape manage this.

The by-gaps method is then extended to work for overlapping items
(when items overlap, the overlaps are made equal). The logic is
centralised in kimath/geometry, and some QA is added. This should
make it easier to extend to eeschema, for example.

This also (attempts to) address some rounding issues which could
cause minor, but compounding, errors to build up along the list
of items.

Also, fix bugs in the collection filtering - previously items
like markers were filtered out only after the selection size
was used to compute the gaps between items.
2024-05-05 03:35:09 +08:00
Jon Evans
6b145b2830 Add optional reporting of non-KiCad design issues
Also add HTML reporter to PCB side to match schematic


(cherry picked from commit b8fa10ab2b)

Co-authored-by: Jon Evans <jon@craftyjon.com>
2024-05-04 15:27:52 +00:00
Jon Evans
3351da9906 DbLib: Fill entire table if cache is empty when loading one part
The "already placed parts" feature causes a situation where many
single-part queries are placed before the cache is even filled.

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


(cherry picked from commit 3c99a3797e)

Co-authored-by: Jon Evans <jon@craftyjon.com>
2024-05-03 21:04:13 +00:00
Seth Hillbrand
416033e8e5 Ignore hidden text fields when cross-probing
Zoom-to-selection should only show the elements that we can see, so
avoiding hidden fields in footprints keeps the zoom window appropriately
sized

Fixes https://gitlab.com/kicad/code/kicad/-/issues/15245
2024-05-02 10:57:25 -07:00
John Beard
129c61a742 SELECTION::GetItemsSortedByTypeAndXY - minor tweaks
Simplify a little by keeping the positions of A and B in
variables.

Also remove const when returning by value - all that does is
inhibit a (possible, NRVO) move if you assign the result to
a non-const vector.
2024-05-01 23:33:25 +08:00
Rosy
17891f7a1d HTTP Libraries: Add support for descriptions of sublibraries 2024-04-30 11:57:00 +00:00
Jeff Young
43e6006306 Separate Compare Footprints from DRC.
(We want to ignore some of the flags for DRC.)

Fixes https://gitlab.com/kicad/code/kicad/-/issues/17819
2024-04-28 23:05:54 +01:00
Jeff Young
c45c80f083 Fix clang includes. 2024-04-28 16:00:54 +01:00
Jeff Young
67737ea0b2 Restore view_controls include for clang. 2024-04-28 14:03:45 +01:00
Jeff Young
a24eada8b1 Cleanup. 2024-04-28 13:52:41 +01:00
Alex Shvartzkop
6fdeca7c56 Fix build on Linux. 2024-04-28 02:06:12 +03:00
Alex Shvartzkop
16e3692e71 Build time optimizations. 2024-04-27 23:49:13 +03:00
Jeff Young
c59ed0bbb7 Flip symbol editor's Y axis to match other editors. 2024-04-27 13:47:56 +01:00
Alex Shvartzkop
1ae9e9b676 ADDED: XAO export for SALOME / Gmsh workflows.
Pad surfaces are assigned as face groups.
2024-04-26 01:53:43 +03:00
Seth Hillbrand
ef62b01dd1 Make import/export flags explicit
IO plugins can import/export or both.  This sets an explicit boolean for
controlling which options are available.
2024-04-25 09:21:15 -07:00
James J
be8744176c Add SCH_RULE_AREA shapes to eeschema
Includes:
 - Fix GAL to draw closed polygons in eeschema
 - Add functionality to eeschema to draw arbitary polygons
 - Update polygon item previews to have customisable edge colour
 - Add new SCH_RULE_AREA class, derived from a poly SCH_SHAPE
 - Add SCH_RULE_AREA to paint and plot methods
 - Add new rule area color preference to themes
2024-04-25 14:24:46 +00:00
Jeff Young
cd64630661 Remember shown columns in netclass setup.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/17852
2024-04-25 08:34:36 +01:00
RosyDev
058b337b00 HTTP library users will now see the generic fields in the components' properties in the correct order as submitted by the API.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/17584
2024-04-25 00:23:51 +00:00
Seth Hillbrand
315ad0e071 Replace stale pin references with UNDO copy
When we replace a symbol with one that has fewer pins, the old pins
are released, which leaves points to them in the connection graph
dangling.  This updates the pointer to use the cloned copy in the undo
stack until the connection graph is rebuilt with the new data

Fixes https://gitlab.com/kicad/code/kicad/-/issues/17851
2024-04-24 12:55:02 -07:00
Alex Shvartzkop
2babd574be Refactor autosave prefix into FILEEXT. 2024-04-22 04:06:04 +03:00
Jeff Young
95136494b3 RIP LIB_PIN. 2024-04-20 12:10:31 +01:00
Seth Hillbrand
d8b6e28890 Excise the remaining unused ifdef EESCHEMA
Common units are now shared between programs, so we need a different way
other than compile definitions to choose how many digits to display.
2024-04-18 18:21:13 -07:00
Wayne Stambaugh
d79619edd1 Minor net navigator improvements.
Ignore bus member connection subgraphs.  They do not have a valid net
name nor do they contain schematic items.  This prevents empty nodes
from being added to the tree.  They can be reintroduced in the future
if someone wants to pursue it.

Freeze the wxTreeCtrl while populating it and thaw when done to prevent
any unnecessary repainting.

Add profiling to test how long it takes to rebuild the net navigator.
The recently added populate the navigator with all nets when no net
is highlighted has exposed some potential performances issues with some
versions of wxWidgets on certain platforms.  Namely wxWidgets 3.2.4 on
Linux GTK.

Fix an issue where a sheet name change would not update the highlighted
net navigator resulting in a stale human readable sheet path.

Prevent the highlighted net navigator from being rebuilt twice when
loading a schematic.  SCH_EDIT_FRAME::RefreshNetNavigator() was being
called from both SCH_EDIT_FRAME::UpdateHierarchyNavigator() and
SCH_EDIT_FRAME::RecalculateConnectivity().

Add a new trace helper "KICAD_UI_PROFILE" to show trace output when
profiling user interface performance.  It's used in the net navigator
profiling mentioned above.

Reuse PROF_TIMER::Show() to generate string for PROF_TIMER::to_string().
2024-04-17 14:31:50 -04:00
Alex Shvartzkop
d98d7f9017 ADDED: Support 3D shape export in BREP format.
BREP doesn't support colors or label names,
but is much faster to write/read compared to STEP.
2024-04-17 17:31:10 +03:00
Jeff Young
d761b4f22f RIP LIB_TEXTBOX and LIB_SHAPE. 2024-04-16 16:31:16 +01:00
Jeff Young
3efe504dcc Collapse LIB_TEXT into SCH_TEXT. 2024-04-16 16:31:16 +01:00
Mike Williams
ea904c9fb1 Symbol Fields Table: configurable excluded from BOM filtering
Fixes: https://gitlab.com/kicad/code/kicad/-/issues/17747
2024-04-15 13:08:04 -04:00
jean-pierre charras
c6f4157689 msys2: fix a link issue in Eeschema after changes from 89dd8e1. 2024-04-14 09:18:32 +02:00
Alex Shvartzkop
affcfed677 Fix some warnings. 2024-04-14 01:19:39 +03:00
Alex Shvartzkop
c1dc4e1d47 Fix build error on Linux/clang. 2024-04-14 00:37:44 +03:00
Alex Shvartzkop
76b7cdd128 Improve grid cell editors appearance. 2024-04-13 23:26:01 +03:00
Jeff Young
d77eae3e7e Collapse LIB_FIELD into SCH_FIELD. 2024-04-13 15:42:13 +01:00
Marek Roszko
aa8f449d48 Remove extraneous struct keyword 2024-04-13 09:56:25 -04:00
Marek Roszko
89dd8e1166 Move the PARAM_LIST<> specializations for BOM to bom_settings 2024-04-13 07:59:25 -04:00
Marek Roszko
eb38932d26 Fix capture lambda
Fixes https://gitlab.com/kicad/code/kicad/-/issues/17757
2024-04-13 07:47:02 -04:00
Marek Roszko
c05ae0b32e Fix another lambda capture 2024-04-12 23:37:38 -04:00
Marek Roszko
262d94964f Lets try C++20 2024-04-12 23:32:18 -04:00
Marek Roszko
5e3396561d Fix some layer id enum colliding warnings
C++20 under MSVC does not like seeing enum values between two enums getting operated on.
static cast to int fixes it for what we are trying to do anyway
2024-04-12 21:55:19 -04:00
Marek Roszko
41fc1411eb Use explicit this capture in COLLECTOR m_inspector lambda 2024-04-12 20:03:07 -04:00
Alex Shvartzkop
cae631d7b7 Fix build error in API handler.
(cherry picked from commit 46e1839203)
2024-04-10 19:09:12 +00:00
Jeff Young
5abc7145da Fold LIB_ITEM into SCH_ITEM. 2024-04-08 10:24:50 +01:00
Jeff Young
494001ed4c Harmonize more APIs. 2024-04-08 10:10:24 +01:00
Jon Evans
aff2d5c0d3 Factor out SHAPE_LINE_CHAIN utilities 2024-04-04 18:55:58 -04:00
Jeff Young
92910d5d0f Factor common parts of SCH_ & LIB_SYMBOL into SYMBOL. 2024-04-04 13:18:55 +01:00
Jeff Young
bf2b3b0b0f Deconflict some LIB_TREE_ITEM APIs so they can remain non-const.
(The non-const is required by FOOTPRINT_INFO, which must load
footrpints to get some of the data.)
2024-04-04 13:18:55 +01:00
Jon Evans
9c113b25a4 Allow turning the API server on/off at runtime 2024-04-03 22:04:11 -04:00
Jon Evans
1dbe78c68b Add QA tests and expand serialization for API 2024-04-02 19:51:18 -04:00
Jon Evans
6bd02cae6d Refactor; add user control over API server 2024-04-02 19:51:18 -04:00
Jon Evans
a3b6ab48a4 Add a new plugin system for the new API 2024-04-02 19:51:16 -04:00
Jon Evans
f613cd1cb4 ADDED: A new IPC API based on protobuf and nng
Details, documentation, and language bindings are works in
progress and will be evolving over the course of KiCad 9
development.
2024-04-02 19:34:36 -04:00
Jon Evans
77eaa75db1 Show all library children if library name matches search
(cherry picked from commit a042d1aab4)
2024-04-02 22:51:41 +00:00
Alex Shvartzkop
b905b4eac8 Improve moving, rendering and plotting of very small angle arcs.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/17110
2024-04-03 00:40:18 +03:00
Seth Hillbrand
d82e8ee41a Map nets in pasted data
Add missing nets to the existing board and use any existing nets of the
same name.

Adds option to clear all nets in Paste Special

Fixes https://gitlab.com/kicad/code/kicad/-/issues/17626
2024-04-01 16:56:44 -07:00
Ian McInerney
9e597ea754 Add the option to use alternating row colors in tables/grids
ADDED: Option to use alternating row colors in tables/grids

Fixes https://gitlab.com/kicad/code/kicad/-/issues/16739
2024-04-01 21:59:37 +01:00
Céleste Wouters
e98c9f283f Improve SHAPE_POLY_SET fracture performance
Refactors `SHAPE_POLY_SET::fractureSingle()` to be more efficient, while
not changing the actual algorithm:

* increase cache locality by using contiguous arrays instead of what was
effectively a linked list
* reduce latency and jitter by replacing per-edge allocator calls with
ahead-of-time std::vector reserves
* increase cache efficiency by making the vertex struct smaller
* replace O(n^2) leftmost edge search with O(n log n) std::sort
* sort the polygons instead of the edges
* cut iteration count in half in the remaining O(polygons * edges) part
2024-03-27 21:19:02 +00:00
Jon Evans
5aa8af1abf Add a cache for looking up board items by ID 2024-03-26 18:36:23 -04:00
Jeff Young
fc572bfbc6 Make sure users don't run into min text size.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/17543
2024-03-23 15:50:45 +00:00
Jeff Young
7218d501d4 Better locality-of-reference for footprint chooser filters. 2024-03-23 12:48:52 +00:00
Jeff Young
a3f3da5a7d Implement STROKE_PARAMS::Stroke() for SH_RECT.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/17516
2024-03-22 12:22:30 +00:00
Marek Roszko
f0912b6128 Fix msys2 build 2024-03-21 19:52:18 -04:00
Seth Hillbrand
7e7fec69f6 Add logging and area check to tesselation
Logging is useful when we find an area that cannot be triangulated.
This will be used to generated test cases.

Skipping minor untesselated areas means that the polygon will still be
considered fully tesselated (and not sent back again and again) even if
the tesselation misses an area less than the configured limit.
Currently, this is 31^2nm.
2024-03-21 13:57:57 -07:00
Seth Hillbrand
4f03bb2fb6 Update triangulation 2024-03-21 13:57:57 -07:00
Marek Roszko
83ef5fd7d6 Move PGM_BASE to kicommon 2024-03-20 23:29:42 -04:00
Marek Roszko
e32b26ebeb Move JSON_SETTINGS and PARAMS to kicommon 2024-03-20 23:29:42 -04:00
Jon Evans
f00f47df13 wxWidgets 3.3 compatibility: explicit wxString conversion 2024-03-20 22:02:41 -04:00
Jon Evans
e7b6573717 wxWidgets 3.3 compatibility: properties API 2024-03-20 22:02:40 -04:00
Jeff Young
7bdf1c7e0f Clear flags before depending on them.
(While at first it may look like any item with the flag set
is going to get deleted anyway, if an undo happens then we
end up with table cells with the STRUCT_DELETED flag already
set.)

Fixes https://gitlab.com/kicad/code/kicad/-/issues/17487
2024-03-20 17:55:58 +00:00
jean-pierre charras
f3966371be Simulation: add export current plot to clipboard and current schematic
These exports are in file menu.
2024-03-19 17:05:55 +01:00
JamesJ
a763d613e5 Move Net Inspector dialog to a widget panel in pcbnew
Introduces some updates to the inspector, and a number of bug fixes:

- Correctly handles changes in board stackup
- Correctly handles unit change events
- Correctly handles language change events
- All layout / panel settings are stored to the project settings
- Retains ability to create net report
- Simple filter searches on net name and net class name (stored in settings)
- Allows hide / show of columns (stored in settings)
- Grouping by netclass (stored in settings)
- Optional filtering by net name (stored in settings)
- Optional filtering by net class (stored in settings)
- Custom grouping by net name match
2024-03-19 01:02:01 +00:00
Jeff Young
05cdd44404 Don't assume all glyphs are outline with an outline font.
Underline and overbar may be stroke glyphs.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/17478
2024-03-18 22:21:01 +00:00
Mark Roszko
72d83cd5de Revert "Move JSON_SETTINGS and PARAMS to kicommon"
This reverts commit 81855aaaa6
2024-03-18 00:08:46 +00:00
Marek Roszko
81855aaaa6 Move JSON_SETTINGS and PARAMS to kicommon 2024-03-17 18:11:49 -04:00
Jeff Young
e30b6398b7 ADDED: optional PDF metadata from AUTHOR and SUBJECT variables.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/17289
2024-03-14 17:40:04 +00:00
Alex Shvartzkop
463b609993 Disable infinite panning when using XWayland.
Cursor warping doesn't work properly in this scenario.

https://gitlab.com/kicad/code/kicad/-/issues/14109
2024-03-12 10:31:23 +03:00
Jeff Young
85d0126187 Auto-start text entry for Scintilla grid cells. 2024-03-11 17:46:09 +00:00
Jeff Young
fbc433deaa Make sure to initialize cell start location.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/17379
2024-03-10 21:49:54 +00:00
Jeff Young
1152b0462c Grid properties for GerbView.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/17372
2024-03-10 18:21:50 +00:00
ecorm
4dcd1fb8e2 Fix formatting from simulator X/Y zoom changes 2024-03-10 12:43:18 +00:00
ecorm
16de0a666c Horizontal/vertical zoom for Simulator plots
ADDED: Horizontal/vertical zoom for simulator plots, via mouse wheel,
toolbar buttons, menu commands, and hotkeys.

ADDED: Simulator preferences panel, populated with mouse wheel
and trackpad settings that control pan and zoom of simulator plots.

ADDED: Zoom In/Out Horizontally/Vertically commands that can be bound
to hotkeys.

CHANGED: Simulator plot scroll wheel gestures are no longer hard-coded
and can now be configured via the new Simulator preferences panel.

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

Other unreported bugs that were fixed:

- Fixed wierd, jumpy simulator plot view limiting behavior.

- Fixed Zoom In Center and Zoom Out Center commands not preserving
  the simulator plot center point.

- Fixed simulator plot nudging when exported as PNGs.

- Fixed rectangular selection zoom being able to exceed simulator plot
  view limits.

Notes:

- Provided new SIM_PREFERENCES struct to be used for future
  simulator preferences set via the simulator preferences dialog.

- Bundled pre-existing EESCHEMA_SETTINGS::SIMULATOR settings into
  EESCHEMA_SETTINGS::SIMULATOR::VIEW.

- Replaced mpWindow::EnableMouseWheelPan with more general
  SetMouseWheelActions.

- Refactored and tidied up wxMathPlot's mpWindow code involved with
  fitting, zooming, and panning.

- Consolidated long lists of duplicated member variable initializers to
  a new mpWindow private delegated constructor.

- Provided provisional Zoom In/Out Horizontally/Vertically toolbar
  icons that need improvement by a graphics designer.

- Provided gitignore entries for the Qt Creator IDE
2024-03-10 12:43:18 +00:00
Jeff Young
a12d79cd13 Performance improvements for multi-page dialogs. 2024-03-10 12:18:50 +00:00
jean-pierre charras
821063e5b1 Pcbnew, pdf plotter: fixes and enhancements.
* To select a footprint info, Use the bbox with not text as selectable area
* Fix also incorrect position of footprint bbox when plotting with offset

Fixes https://gitlab.com/kicad/code/kicad/-/issues/17355
2024-03-10 13:04:39 +01:00
Jeff Young
72ba31ba27 Pass symbol's netlist to footprint preview widget.
This allows us to show the pin functions on the corresponding
pads.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/17349
2024-03-09 15:01:59 +00:00
Marek Roszko
cb01bca1f4 Add PADS netlist format export 2024-03-09 10:00:46 -05:00
Alex Shvartzkop
4d66a8ebdb Fix rendering/plotting of arcs with tiny angle and huge radius.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/17343
2024-03-09 02:07:24 +03:00
Alex Shvartzkop
f6f0b9a661 ADDED: PCB 3D image raytracing rendering from CLI.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/3691
2024-03-08 14:38:18 +00:00
Marek Roszko
0c8e08ed58 Move some language changes to a event on the frame 2024-03-03 11:02:26 -05:00
Marek Roszko
585cf841e5 Create a singular point for events like EDA_EVT_UNITS_CHANGED to be exported out of kicommon 2024-03-02 16:29:08 -05:00
Jan Wichmann
1297ddc88d pcbnew: Added default master pad properties
CHANGED: Automatically selects the right pad type for the footprint type. Resets the pad properties if the master pad properties do not match the pad type.

https://gitlab.com/kicad/code/kicad/-/issues/16563
2024-03-02 00:13:39 +00:00
Yon Uriarte
464f185387 Performance
Cache VIEW_ITEM's bbox in VIEW_TREE for faster removals.

Fixes https://gitlab.com/kicad/code/kicad/issues/16841
2024-03-02 00:03:46 +00:00
Jeff Young
8dddd9cc2c Separate "use board stackup colors" into separate checkbox.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/17085
2024-03-01 23:45:06 +00:00
arturo182
41147dc3b3 kicad_advanced: Make OCE tesselation deflection configurable
Fixes https://gitlab.com/kicad/code/kicad/-/issues/17168
2024-02-29 19:04:39 +00:00
aris-kimi
24529e5242 ADDED: library tree context menu option to open sym/fp library files from the defined text editor.
Short description:

Works for Symbol and Footprint Editor behind an advanced config option.
For Symbol Editor it is shown for a single item selection (library or symbol).
For Footprint Editor it is shown for a footprint selection.
(fp editor allows a single tree item selection only).
Option stays hidden if current frame has been modified.

Also small fix(?) for similar action to the project manager.
(Call for the Execution has moved inside the file loop.)

Fixes: https://gitlab.com/kicad/code/kicad/-/issues/15736
2024-02-29 19:01:59 +00:00
Jeff Young
c23550dc0b Unflip when going to viewport which isn't flipped.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/13773
2024-02-29 17:37:48 +00:00
Alex Shvartzkop
80457d5871 Support transparent background in 3D viewer PNG/clipboard export.
Only really works with realtime renderer currently.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/12060
2024-02-29 17:11:53 +03:00
Alex Shvartzkop
e71cbea7f8 Use a version string without the extra packaging info in drawing sheets.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/17176


(cherry picked from commit c59fac4089)
2024-02-29 01:24:39 +00:00
JamesJ
5f4c7a52e4 Add netclass color management / import functionality to PCB setup dialog
Fixes https://gitlab.com/kicad/code/kicad/-/issues/16908

ADDED Netclass color column in board setup dialog
ADDED Import netlist colors from schematic button in board setup dialog
2024-02-28 23:13:21 +00:00
JamesJ
b8748c4ef8 Add import netclass color menu items to PCB appearance widget
Fixes https://gitlab.com/kicad/code/kicad/-/issues/16908

ADDED: Context menu item in PCB appearances widget to import netclass
color from schematic.
ADDED: Context menu item to reset PCB netclass color (replicating
same menu item from Nets inspector)
2024-02-28 23:13:15 +00:00
Seth Hillbrand
6a8d2a7eb3 Store group id rather than group
We only need the group storage id for lookup.  Storing the KIID instead
of a copy of the group avoids unneeded overhead

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

(cherry picked from commit 7d1adff071)
2024-02-28 13:27:38 -08:00
Alex Shvartzkop
3582edb185 Cairo GAL: reduce buffer allocation sizes.
cairo_format_stride_for_width() result is in bytes.
Also removes unneeded extra width.


(cherry picked from commit d359fb8ab9)
2024-02-28 00:53:56 +00:00
jean-pierre charras
ed4a4ec8ec Add option to Footprint Chooser to switch between the selected fp or its 3D view
Fixes 
https://gitlab.com/kicad/code/kicad/-/issues/16173
2024-02-27 10:17:00 +01:00
Jon Evans
e9456201a7 Don't rely on dynamic_cast across DLLs
See https://gitlab.com/kicad/code/kicad/-/issues/16998
2024-02-26 22:10:28 -05:00
Jon Evans
2f6c9d1f3a ADDED: Selection filter for schematic editor
Fixes https://gitlab.com/kicad/code/kicad/-/issues/14988
2024-02-25 17:44:10 -05:00
Jeff Young
aef87b9796 Push thickness handling down into EDA_TEXT::SetBold().
Fixes https://gitlab.com/kicad/code/kicad/-/issues/17077

Fixes https://gitlab.com/kicad/code/kicad/-/issues/14875
2024-02-25 17:28:52 +00:00
Jeff Young
fa0ead98d8 Split out table editing and table cell editing. 2024-02-24 20:05:51 +00:00
Jeff Young
782af3a918 Clear text before replacing in ImportSettingsFrom. 2024-02-24 20:05:51 +00:00
Jeff Young
d7e4a8cebd ADDED: ERC/DRC exclusion comments.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/16020
2024-02-24 20:05:51 +00:00
Jeff Young
833ec402a0 Generalize DRCItem inspections.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/10539
2024-02-24 20:05:51 +00:00
Jeff Young
6856e59374 ADDED: ExpandAll/CollapseAll for lib trees.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/8243
2024-02-24 20:05:51 +00:00
Jeff Young
e445249720 ADDED: PCB tables. 2024-02-24 20:05:51 +00:00
Jeff Young
91df43c97a ADDED: schematic tables.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/6806
2024-02-24 20:05:50 +00:00
Jeff Young
4a9df1e18e ADDED: actions for left-, center-, and right-justifying text items.
(For both PCBNew and EESchema.)

Fixes https://gitlab.com/kicad/code/kicad/-/issues/12375
2024-02-24 20:05:50 +00:00
Alex Shvartzkop
8f428c04b0 Fix floating point rounding issues with scaled parameteres in settings.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/17070

(cherry picked from commit fdf38256e8)
2024-02-23 20:29:18 +03:00
Alex Shvartzkop
cb25c8620e Performance optimizations for database libraries.
(cherry picked from commit e68df8e1d1)
2024-02-23 20:29:18 +03:00
Jeff Young
ca3cd706e5 Show friendly name in toolbar button tooltips.
(Don't require the same text to be put into the tooltip.
It's error-prone and also disallows us from having a separate
tooltip for toolbar buttons.)

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

(cherry picked from commit f4a085575a)
2024-02-23 16:53:33 +01:00
Jeff Young
ef23d6776d Formatting.
(cherry picked from commit baaed8ed84)
2024-02-23 16:53:32 +01:00
Jeff Young
73b6b19a4e Keep Mac debugger from crashing with breakpoints in .h files.
(cherry picked from commit 7446fba70a)
2024-02-23 16:53:32 +01:00
Jeff Young
ffa6adec96 Add a cache for TrueType contours and triangulation data.
Also returns minimumSegmentLength to its former value as
it doesn't appear to be required to fix
https://gitlab.com/kicad/code/kicad/-/issues/11463.

Fixes: https://gitlab.com/kicad/code/kicad/-/issues/16568
(cherry picked from commit 162e8962f7)
2024-02-23 16:53:29 +01:00
Alex Shvartzkop
1a65c0091f Tweak default meander settings. 2024-02-20 03:20:08 +00:00
Jon Evans
7b0bb59b37 Remove hard-coded versioned env vars in most places 2024-02-15 15:31:08 +00:00
Seth Hillbrand
0775d1364a Add bezier icon
Fixes https://gitlab.com/kicad/code/kicad/issues/16830
2024-02-14 02:01:01 +01:00
Marek Roszko
f73d45b0cf Add $schema prop to drc/erc 2024-02-13 19:08:55 -05:00
Marek Roszko
6db6e85161 Set an excluded property in json reports for erc/drc 2024-02-13 18:38:26 -05:00
Seth Hillbrand
f303996f9c Add new icons for tools
Align elements to grid
Cleanup graphics
Cleanup tracks/vias
Drag

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

Fixes https://gitlab.com/kicad/code/kicad/-/issues/16205
2024-02-09 15:55:57 -08:00
Seth Hillbrand
cabbab9a5f Move pcbnew drag to move specific icon 2024-02-09 15:55:57 -08:00
Jeff Young
aef6b2a66e nullptr safety and a bit of wxT'ing. 2024-02-09 13:56:01 +00:00
Jeff Young
e62b4f8ff4 Add nullable int and double to property system. 2024-02-08 18:14:31 +00:00
Jeff Young
f8b8bc78bd Make m_originalColWidths impervious to init-order issues. 2024-02-08 15:09:07 +00:00
Jeff Young
8efd90e6e8 Allow reading of 0 text sizes.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/16902
2024-02-07 16:46:42 +00:00
Jeff Young
98bc03919d Nullptr safety. KICAD-7DM 2024-02-07 14:21:44 +00:00
Jon Evans
874be359e0 Use a more specific path for instance checker 2024-02-06 21:33:44 -05:00
Jeff Young
de634c6f3e Generate tofu if we fail to decompose outline font glyph. 2024-02-05 15:49:57 +00:00
Jeff Young
a28f092b67 Don't cover STL types. 2024-02-05 15:49:57 +00:00
Jeff Young
7b3485fcb8 Remove atrophied terminology (logical -> nickname) 2024-02-05 15:49:57 +00:00
Andre Iwers
a0c39715df HTTP LIB - Fine tuning 2024-02-05 12:11:01 +00:00
Jeff Young
77c19fa99a Fill in missing zone properties.
Also fixes some bugs with hatch properties being available
on rule areas.
2024-02-04 23:01:31 +00:00
Marek Roszko
b08f1ee6bf Fix SPLIT_BUTTON at hidpi 2024-02-04 16:04:45 -05:00
Wayne Stambaugh
92c2ddf77a Do not parent dialogs to non top level windows in panels or widgets. 2024-02-03 10:40:28 -05:00
Jeff Young
0890ac57dd Improve clarity of default zone settings. 2024-02-03 13:22:16 +00:00
Jeff Young
7cc663ad77 Schematic parity checking for CLI DRC. 2024-02-02 23:05:37 +00:00
Ian McInerney
85a2d6178a Add coroutine stack size to trace output 2024-02-02 11:00:08 +00:00
Jeff Young
5d4b4f39ec Allow PARAM_WXSTRING_MAP to behave as an array.
In particular, overwrite file contents with current
contents of map rather than merging.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/16801
2024-01-31 14:58:48 +00:00
Jeff Young
445ed380b8 Formatting. 2024-01-31 14:58:48 +00:00
Marek Roszko
4b12534dbd Fix property editor for graphic circles 2024-01-30 22:00:09 -05:00
Jeff Young
5b5c6f0474 Init tuning pattern settings from BOARD_DESIGN_SETTINGS.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/16819
2024-01-30 13:19:04 +00:00
Marek Roszko
18692ea8e7 This is totally a debug aid for the search pane listview and not a feature 2024-01-29 20:39:48 -05:00
Jeff Young
ee5e2e56c0 Naming conventions; no functional changes. 2024-01-29 16:00:06 +00:00
Jeff Young
053a0aade7 Formatting & commenting. 2024-01-26 14:05:04 +00:00
Alex Shvartzkop
6a69396070 Allow column auto-sizing in RC trees.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/16727
2024-01-25 20:51:54 +03:00
afkiwers
c871bcf6db removed unnecessary variables 2024-01-23 22:32:05 +00:00
afkiwers
c7475a16c8 implemented better caching for categories and parts overview to reduce processing time 2024-01-23 22:32:05 +00:00
Jeff Young
8410a5e685 Coding conventions and cleanup. 2024-01-23 16:03:25 +00:00
Jeff Young
d47a000564 Make sure group items get added to commit.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/16705
2024-01-22 23:34:34 +00:00
Seth Hillbrand
92ed389ad2 Add cir file icon to treeview
Fixes https://gitlab.com/kicad/code/kicad/-/issues/15777
2024-01-22 15:24:00 -08:00
Jeff Young
85f0dd279c Push fileFilter callback function down a level.
(The GRID_CELL_PATH_EDITOR is shared by the whole column.)

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

Fixes https://gitlab.com/kicad/code/kicad/-/issues/13959
2024-01-22 18:27:31 +00:00
Andre Iwers
4d1a016429 HTTP Libraries: Improved cache performance 2024-01-18 02:33:16 +00:00
Jeff Young
97cb15dd47 Make sub menus conditional on them having child items.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/16631
2024-01-18 00:21:15 +00:00
Jeff Young
455fae45d8 Support point editing of inverted rectangles.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/16595
2024-01-17 15:27:48 +00:00
Marek Roszko
fc62d36441 Add share/locale to catalog paths on windows 2024-01-15 22:08:17 -05:00
Alex Shvartzkop
57bc443f0b Fix HPGL color mode being set. 2024-01-15 22:35:35 +03:00
Seth Hillbrand
42e02552ac Make outline font min segment length configurable
This was hard coded at 10IU, which was way too small for pcbnew and
still too small for schematic editor.  Instead, we set a default of 50
and allow the user to adjust (smaller for less powerful machines)

Fixes https://gitlab.com/kicad/code/kicad/-/issues/16568
2024-01-11 18:30:00 -08:00
Marek Roszko
8eb6123985 Move PAGE_INFO to kicommon 2024-01-09 07:26:04 -05:00
Marek Roszko
f53c3f895d pcb_group.h should live in pcbnew 2024-01-08 22:32:18 -05:00
Andre Iwers
047cb41a1d Implemented Timeout for HTTP LIB
Fixes https://gitlab.com/kicad/code/kicad/-/issues/15756
2024-01-08 23:20:23 +00:00
jean-pierre charras
3f70387a17 KISTATUSBAR: code refinement and add comments 2024-01-07 09:47:40 +01:00
jean-pierre charras
1649b7dd56 Kicad manager: fix some issues about the wxStatusBar:
- fix broken code KICAD_MANAGER_FRAME::PrintPrjInfo()
- fix issues created by using KISTATUSBAR instead of wxStatusBar
(the user field count differs because there are 4 other fields added)
- do do use a fixed size in KISTATUSBAR for FIELD_OFFSET_BGJOB_TEXT field:
fixed field size does not work fine if the text to display is not known
Fixes 
https://gitlab.com/kicad/code/kicad/-/issues/16535
2024-01-06 20:23:37 +01:00
Wayne Stambaugh
a310c0a05a Do not expand the entire schematic hierarchy navigator tree by default.
The new behavior is to only expand to the first child of the root sheet
level.  On very complex hierarchies, this makes the navigator far more
useful.

Do not update schematic hierarchy navigator on every edit.  Now only
sheet changes will trigger a rebuild of the tree.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/16371
2024-01-06 07:56:16 -05:00
Jeff Young
169ece3b71 Try reusing the TOOL_DISPATCHER menu hack for libtree previews.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/16493
2024-01-05 14:20:33 +00:00
Marek Roszko
f8744b7797 dsnlexer can live in kicommon 2024-01-03 23:18:31 -05:00
Mark Roszko
d4f6425523 boost::noncopyable is redundant since we declare a copy ctor 2024-01-02 16:10:24 +00:00
Jon Evans
b8aef58561 Add proper comparison operators for BOARD_DESIGN_SETTINGS and children
BOARD::operator== was just comparing pointers
2024-01-01 13:37:31 -05:00
Ian McInerney
b6fffb3923 Add more tool stack tracing 2023-12-29 00:37:38 +00:00
Ian McInerney
f2702b223c Introduce base IO_MGR class and unify RELEASER objects
The IO_RELEASER is a thin-wrapper around a std::unique_ptr, but done
this way to allow easier addition of a custom deleter in the future if
something needs to call back into the IO_MGR.
2023-12-29 00:37:38 +00:00
Marek Roszko
7252ae551c Move EDA_PATTERN_MATCH to kicommon 2023-12-27 22:08:11 -05:00
Marek Roszko
8ef77ce8ef Fix build error due to duplicate var declaration 2023-12-27 21:52:30 -05:00
Marek Roszko
9a890cdba9 Kick the wildcards and file exts into a static class, export it from kicommon 2023-12-27 21:10:01 -05:00
Marek Roszko
5e7a68fcd9 netclass can be in kicommon 2023-12-27 17:57:02 -05:00
Marek Roszko
a36eb2af72 Netclass shouldnt have odd pcb forward decls 2023-12-27 17:12:35 -05:00
Marek Roszko
5bfc601e09 STD_BITMAP_BUTTON can be in kicommon 2023-12-27 17:08:05 -05:00
Ian McInerney
f8688a922d Unify IO library descriptors 2023-12-27 16:34:59 +00:00
Ian McInerney
743e9d669a Push library management into IO_BASE 2023-12-27 01:21:53 +00:00
Ian McInerney
cad91312aa Introduce main base class for all IO loaders 2023-12-26 23:27:11 +00:00
Marek Roszko
5c20c5732d We don't need pgm_base to expose pybind to everything 2023-12-25 23:28:33 -05:00
Marek Roszko
c7fa3adcb8 kicommon PROGRESS_REPORTER 2023-12-25 23:22:39 -05:00
Ian McInerney
e6632bb983 Rename PCB IO classes/files 2023-12-24 01:22:21 +00:00
Ian McInerney
d8b47d18d3 Initial rename of file plugin infrastructure components to IO 2023-12-24 01:22:21 +00:00
Seth Hillbrand
5f234211f9 Remove __WXWINDOWS__ defines
__WXWINDOWS__ is for all of our builds.  __WXMSW__ is for windows only
2023-12-21 08:57:28 -08:00
Mike Williams
1700cad83b Symbol/Footprint Chooser: remember open libraries
Fixes: https://gitlab.com/kicad/code/kicad/-/issues/16383
2023-12-21 09:57:54 -05:00
Wayne Stambaugh
922aee1532 Coding policy fixes. 2023-12-20 07:17:23 -05:00
Jon Evans
1c895fe18c Improve rendering of tuning status popup
Fixes https://gitlab.com/kicad/code/kicad/-/issues/16304

Add dedicated UI rendering layers

Switch to screen-space rendering to avoid blurriness

Fix a bug in OpenGL GAL that causes layer
ordering to be broken when using Scale

Fix some issues with VIEW_GROUP layer ordering
2023-12-19 22:38:21 -05:00
Wayne Stambaugh
a4b38fbb80 Coverity warning fixes. 2023-12-18 16:09:13 -05:00
Jeff Young
8251fca66a performance efficiencies 2023-12-18 17:39:29 +00:00
Jeff Young
68cbb820a7 performance efficiencies 2023-12-18 17:20:34 +00:00
Jeff Young
11805d6696 performance efficiencies 2023-12-18 17:01:55 +00:00
Wayne Stambaugh
25c03da5a5 Coding policy and Doxygen comment fixes. 2023-12-18 08:32:41 -05:00
Wayne Stambaugh
eb3fd10af8 Fix obscured object selection issue in board and footprint editors.
This selection improvement feature is hidden behind the advanced
configuration key "PcbSelectionVisibilityRatio".  It is turned off (1.0)
by default.  Value values are from 0.0 to less that 1.0.  From testing,
using a value between 0.1 and 0.3 produces the best results.

This fix uses normal alpha blending described in the link below.  The
current design only uses the alpha of the object's color.  It could be
improved by doing a full color alpha blending but using the color alpha
alone seems to result in satisfactory results.

https://en.wikipedia.org/wiki/Alpha_compositing

Fixes https://gitlab.com/kicad/code/kicad/-/issues/16126
2023-12-17 16:43:56 -05:00
Jeff Young
b29a56530c Remove undo-of-ungroup hack.
The hack assumed that the parent group would be the first
deleted item of type group in the undo list.  While this
will be true when undoing a user ungroup command, it will
not be when undoing an ungroup side-effect, such as when a
member of a group is deleted during UpdateFromPCB.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/16384
2023-12-17 15:35:35 +00:00
Jeff Young
9fb06f95a0 Fix msys2 build. 2023-12-16 16:17:24 +00:00
Jeff Young
ea3c87f243 Move group/ungroup to COMMIT infrastructure. 2023-12-16 14:17:25 +00:00
Jeff Young
1df84f4d92 Move some PCB_GENERATOR special-cases to propMgr listeners. 2023-12-15 21:04:33 +00:00
Jeff Young
0ab474e596 Comments. 2023-12-15 18:02:52 +00:00
Jeff Young
4844cffc00 Make sure PCB_GENERATOR's lock status follows their members.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/16372
2023-12-15 17:37:36 +00:00
Marek Roszko
c8f646efb1 ADDED: KiCad update check
Fixes https://gitlab.com/kicad/code/kicad/-/issues/15026
2023-12-13 20:47:40 -05:00
Wayne Stambaugh
5fa274ead0 Add board layer view stack up sequence from front layer to back layer.
The old bottom to top layer stack up sequence from back to front layer was
only used for plotting so it was renamed appropriately.  This will be used
for future board object select disambiguation improvements.
2023-12-11 15:07:58 -05:00
Wayne Stambaugh
484491aaea Fix crash on save after pasting symbols in schematic editor.
This was caused by pasting zero length instance paths which are not valid.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/16300
2023-12-11 08:29:10 -05:00
Ian McInerney
be9c3b08b5 Fix library table file filters
The schematic librayr table was missing the Kicad Sexpr filter, and also
the filter inside the grid editor was never updated when the library
plugin type was changed in the grid, so a library of the new type could
not be selected.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/16278
2023-12-07 11:16:02 +00:00
jean-pierre charras
921291c28b Pcbnew, default values for sizes and thickness: add missing tests for validation.
Especially for texts, the min and max values that are used are the same as
for other dialogs.
2023-12-06 16:45:18 +01:00
Mike Williams
2795fa9ca3 EE/PCB_Actions: convert to generic Finish
Fixes: https://gitlab.com/kicad/code/kicad/-/issues/16079
2023-12-06 10:33:17 -05:00
Seth Hillbrand
0e37ea0c66 2581 enabled by default 2023-12-04 12:03:15 -08:00
Wayne Stambaugh
ef2f72697b Make paste special dialog a bit more user friendly.
Set a default control so that the escape key closes the dialog.

Select the OK button after the user selects an annotation option.  This
allows for keyboard navigation of the dialog and saves an extra mouse
move and click to when choosing an annotation setting.
2023-12-03 13:44:38 -05:00
Jon Evans
16dea1d7e7 Remove unused advanced config variable 2023-12-02 21:25:18 -05:00
Jon Evans
9c1a160fcd Add system for property change notifications
Use this to sync symbol field edits that are
synced by the dialog

Fixes https://gitlab.com/kicad/code/kicad/-/issues/15697
2023-12-02 19:22:59 -05:00
Jeff Young
b13590f4c0 Use preview items instead of highlightNets & status popup
The router preview item can be specific to the part that is being
tuned, rather than the whole net.  It's also less visually noisy as
it doesn't dim/undim the rest of the board.

Using kigfx preview items for the status keeps us from having a bunch
of focus issues with the status popup window.
2023-12-02 16:15:43 +00:00
Jon Evans
4ff127b452 Parse generator_version and improve error output on mismatch
Also bump symbol format version for generator_version
2023-11-29 16:17:41 +00:00
Jon Evans
0face5a891 Add prettification to pl_editor; bump version 2023-11-29 16:17:41 +00:00
Jon Evans
f1f8981395 Automatic whitespace and indentation prettification for sexpr formats 2023-11-29 16:17:41 +00:00
Jon Evans
55ba667bcb Retire tstamp keyword in favor of uuid 2023-11-29 16:17:41 +00:00
Jon Evans
55bca5e7ac Normalize formatting of booleans in the PCB file format 2023-11-29 16:17:41 +00:00
Seth Hillbrand
f64349b292 Coverity fixes 2023-11-27 11:57:31 -08:00
Seth Hillbrand
75c6b0ab28 Added IPC2581 support
IPC2581 is a modern production file exchange system.  It provides
single-file data output for an entire board including BOM and netlist
information.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/1954
2023-11-26 15:30:58 -08:00
Ian McInerney
b64631d7bc Add um support to the unit binder 2023-11-26 00:03:09 +00:00