Commit Graph

320 Commits

Author SHA1 Message Date
Jeff Young a3b9e8ddb4 Round 2 of Worksheet -> Drawing Sheet. 2021-02-23 11:57:44 +00:00
Jeff Young cad5198ab7 Worksheet -> (industry standard) Drawing Sheet. 2021-02-22 17:35:46 +00:00
Jon Evans f1039dfb94 Disable project saving outside explicit save actions
Fixes https://gitlab.com/kicad/code/kicad/-/issues/7589
2021-02-21 21:31:45 -05:00
Jeff Young 2d28ed8eda Move canvas backend selection to Preferences.
Fixes https://gitlab.com/kicad/code/kicad/issues/7630
2021-02-21 20:12:43 +00:00
Jeff Young 5994ce3711 Be more aggressive about updating title to show dirty status.
Fixes https://gitlab.com/kicad/code/kicad/issues/7613
2021-02-19 21:58:49 +00:00
Jeff Young 66b33834b5 Always enable save; move dirty bit to asterisk in title bar.
Also unifies PCB Editor and Schematic Editor names with other
locations in the GUI (which were still Pcbnew and Eeschema).

Fixes https://gitlab.com/kicad/code/kicad/issues/7587

Fixes https://gitlab.com/kicad/code/kicad/issues/7594
2021-02-18 16:05:42 +00:00
Jeff Young b2a4cbedda Add conditions for rotate/group/lock items in toolbar.
Also fixes cut/copy/delete conditions to allow use in immediate mode.
2021-02-18 00:10:41 +00:00
Jeff Young ec20121114 Make sure schematic symbol fields get transferred to symbol editor.
Fixes https://gitlab.com/kicad/code/kicad/issues/7501
2021-02-14 18:30:14 +00:00
Seth Hillbrand 505844f68c Generalize the Ctrl-Q to all frames
Rather than adding our handler to each frame separately, we initialize
the Ctrl-Q quit action at the base frame to be consistent
2021-02-09 11:43:42 -08: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
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
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
Roberto Fernandez Bautista 42cbcf7ef4 Don't allow empty page numbers
Fixes https://gitlab.com/kicad/code/kicad/-/issues/6698
2021-01-22 14:02:34 +00:00
jean-pierre charras d052524707 Eeschema: fix zoom change on undo/redo command.
It was a side effect of commit e10025 fixing another zoom issue.
Fixes #7170
https://gitlab.com/kicad/code/kicad/issues/7170
2021-01-18 16:26:30 +01:00
Dominik Wernberger bb2881a5ab Make RENDER_SETTINGS argument const 2021-01-12 20:51:31 +00:00
Jeff Young 07673d3c11 Don't access tools after they've shut down. 2020-12-29 17:29:24 +00:00
Jeff Young 8a720ef305 Update naming. 2020-12-25 23:37:01 +00:00
Jeff Young 1648dd6f0e Fix various issues with save & editing symbols from schematic.
1) Zero out selection in tree when canvas captures focus so that
save/save as actions will go to canvas, not tree item.
2) Make save do a save to schematic when the canvas symbol is from
the schematic.
3) Copy fields when doing a save to schematic (setting the lib part
doesn't update them on its own).
4) Remove no-longer-necessary calls to update schematic after
saving symbols (the schematic symbols are no longer hot-linked).

Fixes https://gitlab.com/kicad/code/kicad/issues/6763
2020-12-25 11:58:58 +00:00
Seth Hillbrand 61ac9c8d90 Add multiple size icons for programs
In theory, the WM should now choose the closest size icon for its
purpose, making it easier to distinguish in space-constrained settings

Fixes https://gitlab.com/kicad/code/kicad/issues/6798
2020-12-22 15:37:26 -08:00
Jeff Young 47ea51ec34 Allow both aui-manager-based infobars and window overlay infobars. 2020-12-22 21:36:39 +00:00
Jeff Young 7376c25ebe Fix a crash bug trying to update the view before it was ready. 2020-12-20 18:02:16 +00:00
Jeff Young 73b7b104cd Fix some issues with Infobar sizing.
This also commits to the new strategy as it wasn't really compatible
with if-def-ing anymore.
2020-12-11 12:39:40 +00:00
Jeff Young ad281f7538 Remove duplicated TestDanglingEnds routines.
Also adds a changedItemHandler so that the single remaining version
can update the view.

Fixes https://gitlab.com/kicad/code/kicad/issues/6581
2020-12-06 21:24:16 +00:00
Jeff Young e79df4a3ed Formatting. 2020-12-03 15:16:34 +00:00
Roberto Fernandez Bautista 9380d6f533 eeschema page numbers: match ordering in hierarchy navigator to sheet page number ordering
- update hierarchy navigator after any modifications to the SCH_EDIT_FRAME
- do not generate ghost selection events after updating hierarchy tree
- use Human Readable path in SCH_EDIT_TOOL::EditPageNumber
Fixes https://gitlab.com/kicad/code/kicad/-/issues/5760
2020-11-30 16:49:33 +00:00
Jeff Young 3da0ab1a9a Fix a couple of bugs in intersheet references.
1) init reference pages before trying to draw the SCH_FIELDs when
turning intersheet references on

2) don't double redraw because we accidentally cleared the last
hover item on a non-mouse-moved event.

3) make sure the root sheet gets a name for the hypertext menu.
2020-11-29 16:53:18 +00:00
Jeff Young 9922b7b738 Redraw canvas after preferences. (Needed for grid changes, etc.)
Fixes https://gitlab.com/kicad/code/kicad/issues/6433
2020-11-29 10:57:45 +00:00
Jeff Young 826e47dde3 Hook up excluded ERC marker persistence.
Fixes https://gitlab.com/kicad/code/kicad/issues/6425
2020-11-19 18:22:52 +00:00
Jeff Young c61c7b62aa Start of impl for persisting ERC exclusions. 2020-11-18 23:34:27 +00:00
Jeff Young 8c5c902fa3 Re-write IntersheetRefs on top of SCH_FIELDs and textVars.
1) Generalize SCH_ITEM owners (SCH_COMPONENT, SCH_SHEET, and now
SCH_GLOBALLABEL)
2) Generalize hypertext items
3) Use SCH_FIELD autoplace infrastructure for placing intersheet
references
4) Use textVar infrastructure for buildin intersheet references.

As an important side-effect this also fixes the undo issues with
intersheet refs.
2020-11-17 16:05:49 +00:00
Jeff Young a207bd97bb Naming conventions. 2020-11-17 16:05:49 +00:00
Jeff Young b227d2b910 More component -> symbol. 2020-11-15 20:23:15 +00:00
Wayne Stambaugh 43a4cf7957 Coverity fixes.
CIDs 309391, 310711, 310712, and 313055.
2020-11-12 08:15:49 -05:00
Michael Kavanagh 20bb3b194f Eeschema: Display the root sheet name to the user
Instead of just `/` denoting the root sheet, use the filename
in preparation for non-hierarchical multi-sheet schematics
2020-11-02 17:50:13 +00:00
Marek Roszko fbcbed5543 Add acceleratedGraphics prompt for eeschema 2020-10-31 17:49:50 -04:00
Jeff Young 6cefec64ea Commit pending changes before quitting.
Fixes https://gitlab.com/kicad/code/kicad/issues/6239
2020-10-31 11:50:11 +00:00
Jeff Young bddc97df30 LibEdit -> SymbolEditor 2020-10-31 10:28:21 +00:00
Jon Evans 70c90266a8 Fix crash when loading new schematic with something selected 2020-10-27 22:05:35 -04:00
Wayne Stambaugh f7084afb72 Eeschema: fix annotation bug.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/6154
2020-10-26 13:01:36 -04:00
Marek Roszko e49ac45b84 HTML_MESSAGE_BOX is a dialog 2020-10-25 20:01:12 -04:00
Seth Hillbrand 4085757aeb Remove beginning/ending spaces in translations
Adding space padding makes translations more difficult by increasing
string counts
2020-10-20 12:08:04 -07:00
Wayne Stambaugh 8ff51d8899 Eeschema: add schematic sheet page number.
The groundwork has now been laid for per sheet instance data.  Initially
this only supports sheet page numbers but could be expanded to include
other per sheet instance information.

ADDED: Support for user defined schematic page numbers.
2020-10-19 14:05:45 -04:00
Jon Evans e735d21824 Maximize main editors by default if config is missing
Also set default size for other windows to something slightly
larger than it was before
2020-10-18 14:38:55 -04:00
Jeff Young 81e1bc9df0 Keep track of driver changes so the view can be updated.
Also make renaming of nets a bit more stable.

Fixes https://gitlab.com/kicad/code/kicad/issues/6018
2020-10-17 20:40:05 +01:00
Marek Roszko 5302f7ce73 Remove kicad_string.h from eda_text.h 2020-10-14 19:18:38 -04:00
Marek Roszko 2c86363aa0 Relocate the page_layout includes to a page_layout folder 2020-10-13 20:33:33 -04:00
Jon Evans 1df35145b5 Not all items are drivers
Fixes https://gitlab.com/kicad/code/kicad/-/issues/5946
2020-10-10 09:16:31 -04:00
Jeff Young 4565631728 Finish moving eeschema assigned netclasses to sheet-path-relative.
Also adds code for the case where a new label is created on a net
with an existing netclass assignment.

Fixes https://gitlab.com/kicad/code/kicad/issues/5886
2020-10-07 16:31:55 +01:00
Ian McInerney 43c14face0 Switch to showing metric/imperial units in comboboxes and menus
This will always show 1 unit from each system, with the primary unit
being the current frame unit and the secondary unit being the
most recent unit used from the other system. These are saved in
the settings, so they are saved between runs.
2020-10-05 20:26:33 +01:00
Jon Evans e27786de2d Fix double call of OnPgmExit
Also fix bad filename being passed to pcbnew when starting
from a blank schematic in standalone mode

Fixes https://gitlab.com/kicad/code/kicad/-/issues/5786
2020-10-04 18:39:33 -04:00