Commit Graph

8523 Commits

Author SHA1 Message Date
Jeff Young 9fe00bb808 Cleanup. No (intentional) functional changes. 2023-06-06 12:30:35 +01:00
Jeff Young c5e7d800a4 Back out earlier diamond-to-rectangle fix for one that's more targeted.
(And doesn't fail qa_pcbnew.)

Fixes https://gitlab.com/kicad/code/kicad/-/issues/14828
2023-06-05 21:26:37 +01:00
Jeff Young 4dda7d39ab Tranform diamonds back to rects after rotating to a cardinal orientation.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/14828
2023-06-05 18:55:18 +01:00
Mike Williams d48858e298 LibTree: add numpad enter as enter
Written by Andrej Valek
2023-06-05 09:20:22 -04:00
Jeff Young 1528f4700c Treat canvas item as current when tree view contains no selection.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/12702
2023-06-04 20:52:12 +01:00
Jeff Young 9da66ccb58 Hack Mac icon buttons back to size.
It remains unclear to me how this *should* be going forward, but
this at least gets us back to the status quo.
2023-06-03 21:41:56 +01:00
Jeff Young 5875f89531 Centralize text size clamping.
Also introduces alg::clamp to improve readability of
std::max( min, std::max( value, max ) )

Fixes https://gitlab.com/kicad/code/kicad/-/issues/14876
2023-06-03 20:29:51 +01:00
Jon Evans 1aff03eadb Fix bitmap scaling for SPLIT_BUTTON 2023-06-03 12:41:40 -04:00
Jon Evans 8f69336ad1 Support DPI scaling in custom bitmap buttons 2023-06-03 11:32:52 -04:00
Wayne Stambaugh bdee545841 Coverity warning fixes. 2023-06-03 07:28:17 -04:00
Alex df4fefeb20 Fix view shifting when infobar is shown. 2023-06-02 17:46:46 +03:00
Marek Roszko e536fa966c Remove extraneous Pgm() 2023-05-31 23:02:38 -04:00
Marek Roszko 8eb265bf4c Add a central assert handler that generates sentry events 2023-05-31 21:56:59 -04:00
Seth Hillbrand c7758999af Handle LOCKFILE logistics for ro
We need to check if a lockfile is valid to determine if we should
override the lock. Valid() is true if the lockfile couldn't be created
b/c of permissions or if the lockfile could be created and acquired.
2023-05-31 17:04:32 -07:00
Seth Hillbrand 14f6e32c74 ADDED: Change watcher for libraries
When editing or viewing library symbols, the files are watched for
underlying changes.  If any occur, the user is either prompted to reload
(if reloading would overwrite their current edits) or the file is
silently updated to the current version on disk.

This also sets a custom assertion handler to avoid unneeded crashes when
recieving invalid SAMBA packets and turns off assertions entirely when
running in release (non-debug) mode
2023-05-31 13:46:00 -07:00
Seth Hillbrand d94fd5f979 Prevent ro directories from showing lockfile error 2023-05-31 13:45:57 -07:00
Jeff Young 421d6b2ef8 Retire LIB_ID_VALIDATOR as it prevents usage of text variables.
(We perform more complete checks in ERC anyway.)

Fixes https://gitlab.com/kicad/code/kicad/-/issues/14764
2023-05-31 17:26:54 +01:00
jean-pierre charras 90c4b8bc57 Eeschema: try to fix a not working tool (Paste tool on main horiz. toolbar)
Fixes #14827
https://gitlab.com/kicad/code/kicad/-/issues/14827
2023-05-31 17:45:19 +02:00
jean-pierre charras a4b73d74a3 Remove a change committed by mistake in commit 86abfd2ce.
It should be committed in a separate commit.
2023-05-31 17:45:19 +02:00
Jeff Young f9fd37c4ca Correctly handle hidden columns when pasting into grids.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/14844
2023-05-31 12:26:18 +01:00
Jeff Young e82e4af483 Don't double-up FUTURE_FORMAT_ERROR problem strings.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/14780
2023-05-31 11:13:35 +01:00
jean-pierre charras 86abfd2cef Update a golden file in Eagle QA tests 2023-05-31 11:52:50 +02:00
Jeff Young c36b0fcda7 Make sure 3D file browser is treated as modal by quit.
(Otherwise we crash when freeing it during the quit.)
2023-05-30 14:58:46 +01:00
jean-pierre charras 6b845b9054 Fix compil warnings and a wxWidgets alert. 2023-05-30 09:00:46 +02:00
Marek Roszko 6e468c5ce9 Fix more warnings
Needless const and out of order initializer
2023-05-29 23:01:58 -04:00
Jeff Young f5791f5dc6 Left some fixes out of previous commit. 2023-05-29 16:22:24 +01:00
Jeff Young 2612b49698 Fix erroneous wxEXPAND flags. 2023-05-29 14:23:31 +01:00
Roberto Fernandez Bautista 688a61df63 Add options editor to symbol library table + cleanup unused options 2023-05-28 23:56:42 +02:00
Roberto Fernandez Bautista a119bd604d Refactor: Move DIALOG_PLUGIN_OPTIONS to common and use enum for event ID 2023-05-28 23:56:41 +02:00
Jeff Young 570978fa7f Replace larger text bboxes now that we're not using them for knockouts. 2023-05-28 18:17:24 +01:00
Jeff Young c71cf21e2f Use rendered text to generate bounding box for knockout text.
Don't open-code knockout text shape generation in several different
places.

Make sure triangulated knockout text gets clearance added when
specified.

Collapse duplicated footprint text item plot routine (they're no
longer any different from plotting pcb text items).
2023-05-28 17:20:11 +01:00
Jeff Young dacf0b2b96 Account for changes to mimic 6.0 text positioning in bounding boxes.
This is only a partial fix as knockout text is still busted....
2023-05-27 23:41:43 +01:00
Jeff Young 6b0bff2f4f Formatting. 2023-05-27 22:46:02 +01:00
Jeff Young 95a09f686b Revert attempt to use drawing code to generate text bounding boxes. 2023-05-27 22:11:34 +01:00
Jeff Young 3ab9175553 Spread the error-bar move evenly around justified text. 2023-05-27 18:53:04 +01:00
Jeff Young f35a88ce0b Cache LIB_PIN text extents for performance.
Also fixes a bug where we didn't triangulate at all when the char
count didn't warrant the likely overhead of spinning up a
thread_pool.

And fix another bug where EDA_TEXT::GetRenderCache() wasn't using
the given font.

Also reverts using the cache for drawing-sheet text.  The text
items are created from scratch from the data items each time
they're drawn, so there's never an existing cache to make use of.
Instead, we now check that the item is in the view, using a very
approximate bounding box generator (because even generating a
real bounding box shows up large in profiles).

And, lastly, fixes a bug where EndPos was never considered in
DS_DATA_ITEM::IsInsidePage().

Fixes https://gitlab.com/kicad/code/kicad/-/issues/14822
2023-05-27 16:32:11 +01:00
Jeff Young 4ed267394a Outline font performance improvements.
1) Don't fracture font glyphs when generating them; we're going
   to fracture during triangulation anyway.
2) Don't check for self-intersection when deciding to fracture.
   It costs nearly as much as the fracture does.
3) Cache drawing sheet text.
4) Use the current font when checking for cache validity.
5) Parallelize glyph triangulation.
6) Don't invalidate bounding box caches when offset by {0,0}
7) Use the glyph cache when generating text effective shape.
8) Short-circuit NormalizeJustification() if its center/center.
9) Don't triangulate for GuessSelectionCandidates()
10) Avoid sqrt whenever possible.
11) Pre-allocate bezier and SHAPE_LINE_CHAIN buffers.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/14303
2023-05-27 01:35:40 +01:00
Jeff Young ff37ebe61a Improve appearance of stroked knockout text. 2023-05-26 19:53:38 +01:00
Jeff Young cb53a18ee3 Bug fixes for handling boolean flags in DRC rules. 2023-05-26 18:44:33 +01:00
Jeff Young 768fbf5af2 Give up on trying to calculate text bounding boxes.
It results in too many hacks strewn through the code.  Just draw the
text and measure it.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/14803
2023-05-26 18:44:33 +01:00
Jeff Young 6e127829f8 Cleanup formating and includes. 2023-05-26 18:44:33 +01:00
Jeff Young 1518ddde74 Push much of text var autocomplete down into SCINTILLA_TRICKS.
Shared code == fewer bugs.  Well, in theory anyway....
2023-05-25 10:24:50 +01:00
Seth Hillbrand 48ecd742eb Maintain file permissions when renaming
Temporary and autosave files do not neccessarily have the correct
permissions set to replace existing project files.  This updates the
permissions to match the existing values where possible

Fixes https://gitlab.com/kicad/code/kicad/-/issues/13574
2023-05-24 17:09:38 -07:00
Seth Hillbrand 122be418bb Upgrade file locking
wxSingleInstanceChecker is meant for running programs, not file locking.
This implements an RAII class for file locking that stores the lock
files next to the file being locked, allowing it to be easily found and
removed.  Also includes the ability to override the lock, with
information about the original owner

Fixes https://gitlab.com/kicad/code/kicad/-/issues/14734
2023-05-24 13:51:54 -07:00
Jeff Young 1057483983 Reset button applies to resolved page, not lazy page holder.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/14786
2023-05-21 18:15:21 +01:00
Jeff Young cbf83c4161 Pin preferences dialog size.
While unfortunate (we generally frown on having fixed sizes in
favour of having everything auto-layout), in this case it's a
cost of lazy-loading the panels.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/14785
2023-05-21 11:17:36 +01:00
Jeff Young d4c9d9d60a Fix issue with colours in the new lazy-loaded preference panels.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/14784

Fixes https://gitlab.com/kicad/code/kicad/-/issues/14782
2023-05-21 10:56:21 +01:00
Jon Evans 902913c7dd Fix infobar height in Windows HiDPI situations 2023-05-20 21:57:08 -04:00
Wayne Stambaugh 24b04795fd Add net navigator panel to schematic editor.
[ADDED]: A panel to the schematic editor  that allows quick access to all
         of the items connected to the currently highlighted net.

This is an initial swag at implementing a full net navigator feature.  For
now it only shows the currently highlighted net nodes.  The incremental
net list advanced setting must be enabled in order to use this feature due
to performance reasons.  There are still some issues with saving the panel
position which will be addressed in the future.

Initial code for serializing wxAuiPaneInfo settings to and from JSON have
be implemented.
2023-05-20 13:48:03 -04:00
Jeff Young 4c59365867 Blind attempt to fix pns-debug-tool linking issue. 2023-05-19 19:26:03 +01:00