Commit Graph

6553 Commits

Author SHA1 Message Date
Michael Kavanagh 97775aa50b Icons: redo missed simulator icon in new style 2021-02-06 22:51:56 +00:00
Jeff Young c2dbd28101 Simplify and harmonize symbol editor and footprint editor menus.
Some differences are due to difference between libraries being files
in symbol editor and directories in footprint editor, but this unifies
most of the rest.

It also dispenses with the save-to-library vs save-to-document distinction
in the GUI because it makes for too much variability in the GUI, was
implemented differently between the two editors, and isn't needed as much
anymore now that we have the highly visible infobar.

There was also an issue that the save-to-board icon occupies the same
location and has the same size/shape/colours as the Board Setup icon in
PCBNew.

Fixes https://gitlab.com/kicad/code/kicad/issues/7215
2021-02-06 14:33:16 +00:00
Wayne Stambaugh f26b4058c2 Symbol editor: enable properties controls for inherited symbols.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/7126
2021-02-06 08:28:06 -05:00
Zoltan Gyarmati 17b0117074 eeschema: fixing intersheet ref mirroring for global labels
Implementing Mirror{X,Y} overrides in SCH_GLOBALLABEL in order
to properly handle Intersheet Ref field mirroring.

Fixes: https://gitlab.com/kicad/code/kicad/issues/7225
2021-02-05 19:55:54 +00:00
Seth Hillbrand 2aa8a3724f Don't continue until the move tool completes
Starting a new action (to add junctions) will break the move tool loop
and cancel placement.  We need to wait until the tool completes before
choosing where to place the junctions

Fixes https://gitlab.com/kicad/code/kicad/issues/7421
2021-02-05 10:18:34 -08:00
Jeff Young 2ad5108e7d Don't depend on wxWidgets dotted and dashed line styles.
Turns out they're buggy on OSX.

Fixes https://gitlab.com/kicad/code/kicad/issues/7144
2021-02-05 16:18:28 +00:00
Marek Roszko e8bcdfed29 Revert 2faf721360
Fix #7323
2021-02-05 07:12:23 -05:00
Marek Roszko 4c1b4b4159 Check normalize path result instead of blindly using it.
Fix #7323 again
2021-02-05 00:52:41 -05:00
Jeff Young b4a9792e23 Add a warning for hidden power pins.
Fixes https://gitlab.com/kicad/code/kicad/issues/6440
2021-02-04 22:47:37 +00:00
jean-pierre charras b48f29161e Eeschema: cross probing pin from a pad clicked in Pcbnew: fix incorrect pos of cursor.
A transform coordinate was applied twice, breaking the position of the graphic cursor.
Fixes #7414
https://gitlab.com/kicad/code/kicad/issues/7414
2021-02-04 17:24:06 +01:00
jean-pierre charras 658a5cf7ed SCH_PIN::GetMsgPanelInfo(): fix missing initialization of Pin Number string
The displayed string was a old value, not related to the Pin Nummber
Fixes #7414
https://gitlab.com/kicad/code/kicad/issues/7414
2021-02-04 11:14:46 +01:00
Jeff Young 62254309b0 Don't rotate fields if their parent is selected.
Fixes https://gitlab.com/kicad/code/kicad/issues/7410
2021-02-04 00:05:13 +00:00
Jeff Young 2faf721360 Edit library table through backing table instead of grid.
While editing the grid works on OSX, it doesn't appear to on MSW or
GTK.  Whether or not editing the backing table is any better or not
remains to be seen....

Fixes https://gitlab.com/kicad/code/kicad/issues/7323
2021-02-03 15:50:37 +00:00
Jeff Young c220913aa1 Handle y-axis inversion in Symbol Editor when drag-selecting text.
Fixes https://gitlab.com/kicad/code/kicad/issues/7406
2021-02-03 15:28:11 +00:00
Jeff Young ff3441143e Fix assert in setupUiConditions. 2021-02-03 14:40:19 +00:00
Seth Hillbrand b07c8110c8 Follow grid snapping when moving 2021-02-02 20:23:12 -08:00
Seth Hillbrand 97194983cd Select cells at a time
Selecting cells allows us to cut/paste from individual cells.  This is
critical to be able to paste from spreadsheets and move columns around
2021-02-02 19:33:18 -08:00
Seth Hillbrand 238aa2b5b0 Snap to eeschema lines
Allows easier snapping to lines when drawing in eeschema.

Fixes https://gitlab.com/kicad/code/kicad/issues/7378
2021-02-02 19:33:18 -08:00
Seth Hillbrand ea08f1b8cb Update action short names for clarity 2021-02-02 19:33:18 -08:00
Roberto Fernandez Bautista 9aedeae5c3 Don't log error messages when using the clipboard
wxClipboard::GetData()and wxClipboard::SetData() both log a "wxLogSysError" error-level message (see for example:  https://github.com/wxWidgets/wxWidgets/blob/v3.1.4/src/msw/clipbrd.cpp#L703 ). This logged message gets displayed as a messagebox to the user.

The logging can be disabled temporarily by creating a wxLogNull object. See https://docs.wxwidgets.org/3.0/classwx_log_null.html

Fixes https://gitlab.com/kicad/code/kicad/-/issues/6956
2021-02-03 01:55:05 +00:00
Jeff Young 1c6c0bf8cf Null-ptr safety.
Fixes https://gitlab.com/kicad/code/kicad/issues/7266
2021-02-02 23:09:35 +00:00
Jeff Young 8464add58c Use GetSchSymbolLibraryName() when looking up symbol in schematic.
Fixes https://gitlab.com/kicad/code/kicad/issues/7301
2021-02-02 22:55:18 +00:00
Jeff Young b8e97bb6b6 Only apply B&W printer fixes when printing.
Fixes https://gitlab.com/kicad/code/kicad/issues/7388
2021-02-02 15:37:30 +00:00
RigoLigoRLC afad1625d7 Fix save-as extension of imported schematics
Fixes https://gitlab.com/kicad/code/kicad/issues/7333
2021-02-01 18:34:59 +00:00
Wayne Stambaugh c11ded24cd Add instrumentation to track down local issues in symbol library file code. 2021-02-01 12:57:16 -05:00
Jeff Young 147c839857 Allow drag-select of fields.
Fixes https://gitlab.com/kicad/code/kicad/issues/6662
2021-02-01 17:14:30 +00:00
Marek Roszko 31fd49d444 Use the new nudge path for the symbol lib table, save global and project mru differently 2021-01-31 19:01:33 -05:00
Seth Hillbrand ae5d2efe07 Snap common single-click tools
Fixes https://gitlab.com/kicad/code/kicad/issues/7362

Fixes https://gitlab.com/kicad/code/kicad/issues/7363
2021-01-31 15:17:24 -08:00
Jeff Young bbb8173b61 Remove and re-add saved-as libraries when Syncing tree.
Also removes the aForce parameter as it was always true anyway.

Fixes https://gitlab.com/kicad/code/kicad/issues/7357
2021-01-31 23:00:17 +00:00
Seth Hillbrand 8567739a7a Remove conditions from common immediate-mode keys
The conditions prevent use in immediate mode for common actions.  While
this makes enable/disable easier in menu items, this fix is a patch
until we refactor the action framework to distinguish between immediate
mode hotkeys that should start without selections and menu items that
need a selection before running.

Fixes https://gitlab.com/kicad/code/kicad/issues/5333
2021-01-31 14:45:24 -08:00
Marek Roszko de9da20bda Fix broken html 2021-01-31 17:37:47 -05:00
Marek Roszko b05bf34b77 Cleanup redundant if statement 2021-01-31 15:31:57 -05:00
Seth Hillbrand 2edcf42115 Symbol Editor IO_ERROR catching
Tests for read-only in table save routines and catches other IO_ERRORS.

Still returns a non-specific error message but prevents crashing when
erroring during save.

Fixes https://gitlab.com/kicad/code/kicad/issues/7352
2021-01-31 11:31:07 -08:00
Jeff Young dfc6070178 Unify schematic file version checking with PCBNew.
This also makes sure that the user gets a warning before saving over
an older s-expr format.  While that won't always be wanted, it's now
in the infobar (like in PCBNew), so it's not too onerous.§

Fixes https://gitlab.com/kicad/code/kicad/issues/7347
2021-01-31 17:28:14 +00:00
Marek Roszko a156acc6b0 Fix broken LIB_ITEM::Compare case 2021-01-31 11:48:05 -05:00
Marek Roszko bfa8723bb6 Add uninitialized call 2021-01-31 11:45:17 -05:00
Zoltan Gyarmati 3380617836 Axis color fixes in symbol editor
- explicitly set axis color at symbol editor start
- force redraw of grid after axis color change

Fixes: https://gitlab.com/kicad/code/kicad/issues/7160
2021-01-31 15:28:37 +00:00
Seth Hillbrand 08a932a969 Add smarts to switch selection on right-click
Now looks at how hard it is to select the item (grids) and switches only
if the mouse is more than a grid square away and there is a new item
under the mouse.

Fixes https://gitlab.com/kicad/code/kicad/issues/4455
2021-01-31 07:00:48 -08:00
Jon Evans abf0a46dce Refactor PICKER_TOOL and push up snapping disable functionality
Fixes https://gitlab.com/kicad/code/kicad/-/issues/7348
2021-01-31 09:50:41 -05:00
jean-pierre charras c155218582 Sim plot: fix a rounding issue that can create a missing point in a plot.
Due to a truncation when converting a value to integer, the first point was
sometimes missing because it looked like out of plot range.
Fix also a cosmetic issue in dialog.
Fixes #7345
https://gitlab.com/kicad/code/kicad/issues/7345
2021-01-31 10:36:26 +01:00
Mikolaj Wielgus 8eca23aabe Mark null project initial screen as zoom-initialized
The variable `m_Initialized` in `BASE_SCREEN` is used by
`SCH_EDIT_FRAME` to mark whether a screen had its zoom level initialized
by the "zoom to fit screen" action. When this variable is `false`, the
function `SCH_EDIT_FRAME::DisplayCurrentSheet()` performs "zoom to fit
screen", modifying the zoom level. This function is indirectly called in
the undo routines, so if `m_Initialized` is not set to `true`, a zoom
change will occur when the user undoes an operation, a behavior that is
undesired.

`m_Initialized` was not initialized to `true` for the null schematic
(the schematic that is loaded if no project is loaded), causing the
aforementioned undesired behavior.

To prevent this, I've changed the `SCH_EDIT_FRAME` constructor to set
`m_Initialized` to `true`, since it zooms to fit screen already. I've
moved `m_Initialized` from `BASE_SCREEN` to `SCH_SCREEN`, as it is used
only in Eeschema, and renamed it to `m_zoomInitialized`, a name I
believe that better describes what this variable does.

I've also introduced the function `SCH_EDIT_FRAME::initScreenZoom()` to
group the "zoom to fit screen" action with setting `m_Initialized` to
`true`, as they often should occur together.

I'd also like to say that I'm not confident whether
`SCH_EDIT_FRAME::DisplayCurrentSheet()` should perform the zoom level
initialization at this point, but I have decided to not change this
behavior for now, as the commit history suggests it's several years old.

Fixes https://gitlab.com/kicad/code/kicad/issues/7343
2021-01-31 00:49:11 +00:00
Wayne Stambaugh 7737489e57 Symbol editor: don't allow new or imported symbols in read only libraries.
Fixes https://gitlab.com/kicad/code/kicad/issues/7334
2021-01-30 13:03:05 -05:00
Jeff Young 41234a8373 Implement more precise annotation-required messages.
Also moves the message to an infobar so it's more noticeable.

Fixes https://gitlab.com/kicad/code/kicad/issues/7332
2021-01-30 16:31:27 +00:00
Jeff Young a235103e48 Redo pad & via painting (again).
New strategy isolates all draw/don't draw decisions to the ViewGetLOD
routines, and all dimmed/not dimmed to PCB_RENDER_SETTINGS::GetColor.
The actual drawing in PCB_PAINTER is more-or-less conditon free.

Also adds new layers for pad and via hole walls so that they can be
controlled for high-contrast mode.

Also changes the drawing paradigm so that the pads are drawn even when
not on the high contrast layer, just in low contrast.  The hole wall
is drawn in high contrast.  This actually makes things clearer to the
user (although to be honest was done to keep from having to re-render
pads when the high contrast layer changes since we have two separate
layers now that we can adjut colours on).

Fixes https://gitlab.com/kicad/code/kicad/issues/7328
2021-01-30 16:31:27 +00:00
Jon Evans 1d12f3fe4a Fix logic in selecting power symbols for net highlighting
Fixes https://gitlab.com/kicad/code/kicad/-/issues/7339
2021-01-30 10:28:26 -05:00
Thomas Pointhuber 619e128536 altium: Fix #6194 by no longer mirroring schematic text. Furthermore improve value parsing. 2021-01-30 15:44:32 +01:00
Mikolaj Wielgus babda304d9 Prevent addition of false plot when current plot panel is not in m_plots
Without this commit, when `currentPlotWindow()` returned a valid
pointer, but one that is not used as a key in `m_plots`, it would get
inserted to the `m_plots` map. Because this pointer was not properly
initialized, a crash would later occur. I think this problem was
triggered by the pointer to welcome page, but I haven't checked.

Fixes https://gitlab.com/kicad/code/kicad/issues/7324
2021-01-30 02:04:57 +01:00
Seth Hillbrand b64611af7a Make highlight net flexible with grid 2021-01-29 14:28:26 -08:00
Seth Hillbrand ea6dc0d730 Make auto-wire use snapping behavior
Forcing grid snap for the kick-start behavior loses snaps to pins that
may be desired.  This also adds force-snapping in select mode to match
the user's auto-start preferences

Fixes https://gitlab.com/kicad/code/kicad/issues/7293
2021-01-29 14:09:33 -08:00
Seth Hillbrand 02954dfaa1 Fix another instance of modifying iterators
We cannot modify the ee_rtree while iterating over it without
invalidating the iterators

Fixes https://gitlab.com/kicad/code/kicad/issues/7331
2021-01-29 08:33:44 -08:00