Commit Graph

479 Commits

Author SHA1 Message Date
Seth Hillbrand 50c7aff3ff Simplify KiROUND using std::llround/clamp
Removes the bespoke rounding in favor of std::llround and std::clamp
routines
2025-08-04 09:26:25 -07:00
Jeff Young e230d5164d Honour renderSettings' default font.
This still leaves a few things out in the cold,
such as hit-testing and polygon generation.
But at least it allows us to plot with a default
font.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/19031
2025-07-17 09:35:21 +01:00
jean-pierre charras b8d2bdb3d2 EEschema: avoid DNP and EXCLUDE from SIM markers blinking when moving an object
They were redrawn multiple times, and not always on the right graphic layer, thus
creating draw artifacts.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/20483
2025-07-07 17:00:29 +02:00
jean-pierre charras 33c9a50afd Fix typo in last commit 2025-06-19 09:03:05 +02:00
jean-pierre charras 92934b2178 Eeschema: fix crash (null pointer) in Preferences->Colors panel.
When drawing items shown in this panel, the <item>->Schematic() is nullptr
so we cannot use it.
2025-06-19 08:53:13 +02:00
Jeff Young 2cd6654e81 Hop-over improvements.
1) Move hop-over enablement to Schematic Setup.
2) Make hop-over size user configurable.
3) Prefer hop-overs to hop-unders.
2025-06-18 22:18:59 +01:00
jean-pierre charras 025317ee10 Eeschema, hop over arc: refinement in draw code (arcs always have the right radius). 2025-06-17 18:53:38 +02:00
jean-pierre charras cd206a62ba Eeschema: hop over arcs: ensure they are drawn not filled. 2025-06-16 08:53:38 +02:00
jean-pierre charras ca9df9986a Make show hop over a configurable option 2025-06-15 16:55:18 +02:00
jean-pierre charras 57bbc96ab2 Make BuildWireWithHopShape() a member of SCH_LINE
BuildWireWithHopShape(): fix incorrect code, and plot Hop Over shapes
2025-06-15 16:54:54 +02:00
Dhineshkumar S f650999004 Eeschema: Add option to show unconnected wire crossings as hop-overs. 2025-06-15 16:53:40 +02:00
Mike Williams fa02c70604 schematic: draw groups 2025-04-15 09:59:38 -04:00
Jeff Young 5e61a5193f Fix misleading cast. 2025-03-21 13:49:07 +00:00
Jeff Young 59e77e977e Don't use net/netclass colors for label graphic shapes.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/19589
2025-03-20 13:52:21 +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 413d6747c5 Collapse SCH_TABLE border drawing into shared code.
Also pushes GetCornersInSequence() into EDA_SHAPE
so it can be shared between SCH_TABLE and PCB_TABLE.

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

Also fixes a bug with dialog control enabling.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/20350
2025-03-16 20:21:49 +00:00
Jeff Young be183c94c0 Make sure color gets set on background layers.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/20241
2025-03-14 15:35:05 +00:00
Jeff Young 93ea523eec De-duplicate table border drawing code.
Also cleans up a misconception about table header borders,
and renames the getter/setter to be clearer.

Also makes sure that table cells are updated when the table
layer changes.

And another bug where we were writing the grey color value
back to the cell for hidden cells.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/20319
2025-03-13 13:15:47 +00:00
Jeff Young 95d8634401 Fix drawing of selected/highlighted local power port labels.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/20262
2025-03-07 20:33:19 +00:00
Seth Hillbrand 49a4699d5a ADDED: Local power symbol option
Local power symbols work like regular power symbols except that they are
scoped only the the sheet in which they are instantiated

Fixes https://gitlab.com/kicad/code/kicad/-/issues/2075
2025-03-04 17:07:46 -08:00
Jeff Young 163a26111a Introduce lambda to improve readability. 2025-03-02 16:05:35 +00:00
Jeff Young 833bcba06c Simplify background colour handling. 2025-03-02 16:05:35 +00:00
Jeff Young 3f15b0d75b ADDED: hatched fills for shapes. 2025-02-24 11:08:29 +00:00
Jeff Young 7eb75720b5 Start to retire "alias" in favour of "symbol" and "derived symbol".
Note: terminology changes only.  No (intentional)
functional changes.
2025-02-24 11:08:29 +00:00
Seth Hillbrand 878cf768d6 Quiet down the Exclude from Sim marks in Schematic
The big grey X and dimming the component made it look like the component
was no longer a part of the circuit, rather than just being excluded for
a single purpose.

The changes the display to make a more subtle grey outline with an icon
in the corner to indicate that this refers to simulation.
2025-02-21 12:38:23 -08:00
Jeff Young 072d8d55fe ADDED: support naked hyperlinks in tablecells and textboxes.
Also fix flickering due to IS_ROLLOVER flag getting
nuked.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/18832
2025-02-19 23:43:53 +00:00
Wayne Stambaugh f45915ba93 Eeschema folder housekeeping. 2025-02-06 09:47:00 -05:00
Jeff Young 6b6729284c Remove default line styles from all items except eeschema wires and buses. 2025-01-20 11:30:46 +00:00
John Beard a8582e9054 Eeschema: when shadows are in fill-shapes mode, also draw the strokes
Otherwise, stright lines have no shadow at all. The alternative is
to special case stright lines, which means that some graphics
get stroke shadows and some don't and it looks inconsistent.

Fixes: https://gitlab.com/kicad/code/kicad/-/issues/19662
2025-01-18 00:52:02 +08:00
Wayne Stambaugh 5c8f4697ca Common folder housekeeping part 1. 2025-01-12 12:06:45 -05:00
Jeff Young 40871a6a08 Naming clarity. 2025-01-10 15:12:03 +00:00
Jeff Young 2922d508de Don't ever draw hierarchical label shape in bus colour.
(We do still draw the text in bus colour if it's
connected to a bus.  This makes it consistent
with what we do for global labels.)

Fixes https://gitlab.com/kicad/code/kicad/-/issues/19564
2025-01-10 15:12:03 +00:00
JamesJCode 35172fe402 Guard against null m_part in erc TextVar checks
Also removes duplication of LIB_SYMBOL dummy() construction methods

Fixes https://gitlab.com/kicad/code/kicad/-/issues/19575
2025-01-10 00:13:53 +00:00
Ian McInerney e845db1977 Implement dnagling wire to bus entry ERC
Also, rename the dangling flag/getter to match the flag in SCH_LINE for
consistency.
2025-01-03 14:58:57 +00: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
JamesJCode 96082a63a8 Add a new GAL layer for shape backgrounds
Fixes https://gitlab.com/kicad/code/kicad/-/issues/12393
2025-01-01 19:46:33 +00:00
JamesJCode 870b2ec0c5 Revert "Don't allow netclass highlighting to override net highlighting"
This commit had different issues with selected but netclass-highlighted
wires.

This reverts commit a216369d72.
2024-12-30 00:36:26 +00:00
JamesJCode a216369d72 Don't allow netclass highlighting to override net highlighting 2024-12-29 23:31:52 +00:00
Seth Hillbrand e9bc8cfe9d Give Clipper1 a Viking funeral
Clears out the last spot where we were only using Clipper1 (how'd I
miss that?) and remove all calls to the Clipper1 structures
2024-12-23 17:12:09 -08:00
Jeff Young 2926db778c Bug fixes for rotated tables. 2024-12-16 13:26:48 +00:00
Jeff Young 1d4945dad5 Implement private flag for SCH_FIELD.
I don't think this was the original intent, but the
GUI for setting the flag leaked out via the
properties inspector so it kind of needs to work.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/18760
2024-12-09 20:33:40 +00:00
Seth Hillbrand 9dfcb6a362 Cleanup ViewGetLayers()
Old style c-array replaced with vector returns
2024-11-21 13:18:36 -08:00
John Beard 1a86982a2a Avoid enum name conflict on MacOS. 2024-11-05 08:20:37 +08:00
John Beard dbf68a80b8 GAL: also scope layer depth push/pops
This means that an early return or an exception between
a manual Push/Pop (or an omission of the Pop) cannot
corrupt the layer stack.

It also means the GAL doesn't have to maintain its own
stack (with the in-scope GAL_SCOPED_ATTRS taking that role).

Reomve the Push/PopDepth functions, as they're only ever
used in pairs, and doing it manually needs more care.
2024-11-04 20:41:44 +08:00
John Beard 01133d6150 Eeschema: move all pin text layout to PIN_LAYOUT_CACHE 2024-10-26 15:31:12 +08:00
John Beard f29d1fafe4 Include dangling indicator in SCH_PIN bbox
Delegate computation of the size and location of the pin dangling
indicator to the PIN_LAYOUT_CACHE.

Relates-To: https://gitlab.com/kicad/code/kicad/-/issues/18894
2024-10-26 15:04:51 +08:00
JamesJCode 5ac8797475 Fix clang / mac build warnings 2024-10-18 22:07:17 +01:00
Seth Hillbrand 33328fb864 Minor formatting fixes 2024-10-18 13:35:25 -07:00
jean-pierre charras e8d89b1327 Fix compil warnings 2024-10-13 17:28:44 +02:00
John Beard eae84fd5f3 Sym edit: add alt mode icon toggle
Moves the logic into the SCH_RENDER_SETTINGS, rather than
repeating it in EESCHEMA/SYMBOL_EDITOR_SETTINGS (they still
maintain their state there, but the painter looks at the
SCH_RENDER_SETTINGS).

Also turn them off for preview purposes.
2024-10-09 21:27:58 -06:00