Using CopyFile() that can collide with a windows header create hard to
understand errors, including link errors.
Renaming this function avoids these strange errors.
CHANGED: GetDocumentExtents() in 'eda_draw_frame.h' now has a bool
parameter "aIncludeAllVisible" with a default value "true" which makes
it behave as it did before adding parameter. If "aIncludeAllVisible"
is false, the returned bbox ignores some items depending on which
program it is running in.
CHANGED: Made "Zoom to Objects" use only PCB edge in Pcbnew. This
allows text, notes, etc outside the PCB edge to be excluded in the
zoom calculation.
CHANGED: Added "Zoom to Objects" to Pcbnew main menu, and to RMB context
menus for Eeschema and Pcbnew.
Fixes https://gitlab.com/kicad/code/kicad/issues/5787
ADDED: Make middle mouse button double click do a 'Zoom to Fit'
in Eeschema, Pcbnew, and Gerbview. Ctrl-MMB does a 'Zoom to Objects'
in Eeschema.
Fixes https://gitlab.com/kicad/code/kicad/issues/1988
ViewGetLOD() returns the minimal value of a zoom to show an item.
However a zoom is a double, and using int as minimal value does not
allows setting a correct value in some cases.
You can now enable and disable snap to grid when drawing/editing across
all apps. You can also tie snap to grid to the visibility of the grid
to allow rapid enable/disable via grid display.
There was a regression in v6 where the zoom to selection toolbar
item wasn't canceling the tool when pressed and the tool was active
(it was in v5). This implements a more generic framework for canceling
tools on button presses.
Fixes https://gitlab.com/kicad/code/kicad/issues/5103
We probably don't need it, but some code attempts to dereference
it so safer to have one then to start checking everywhere for
dereferences.
Fixes https://gitlab.com/kicad/code/kicad/issues/5353
The use of printf, wxLogDebug, and std::err/std::out causes excessive
debugging output which makes finding specific debugging messages more
difficult than it needs to be.
There is still some debugging output in test code that really needs to
be moved into a unit test.
Add debugging output section to the coding policy regarding debugging
output.
* Frames moved: cvpcb, cvpcb footprints frame, gerbview, pagelayout editor
This also introduces new EDITOR_CONDITIONS that are used to set the
conditions of very common editor settings.
Also, some IDs were converted to tools in the pagelayout editor.
EDA_ITEM is a child of VIEW_ITEM, so a static_cast is not appropriate,
since in some cases it could be called with a non-EDA_ITEM argument.
This was triggering an ASAN heap-buffer-overflow in GerbView.
This Merge Request creates a function called 'findKnownGerbersLoaded()'. That function in turn
calls the existing 'findNumAltiumGerbersLoaded()' and two new functions:
findNumX2GerbersLoaded()
findNumKiCadGerbersLoaded()
This approach allows a single call to detect Altium/Protel Gerbers, X2 Gerbers, and Gerbers using
KiCad naming conventions.
If it's desired to add detection of Gerbers from other EDA programs, new functions can be written
and then called from 'findKnownGerbersLoaded()'.
Fixes issue https://gitlab.com/kicad/code/kicad/-/issues/4872
Adds the ability to flip (mirror) the display, just like "Flip
Board View" does in Pcbnew.
Also added this to vertical toolbar since it's handy to not
have to go into the menu system to flip the display back and
forth.
Fixes issue https://gitlab.com/kicad/code/kicad/-/issues/2501
This API doesn't transfer ownership, so no smart pointers are required --
this just needlessly tightens requirements on the user of the interface.
(Fixes five instances of MSVC C26410 warning)
The 'Select Layer:' dialog pops up directly over the dialog with the loaded
Gerbers and hides all Gerber file names. This is just an aid so users remember
exactly which Gerber layer they're working on without having to move the dialog.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/4893
This moves the program-specific code (e.g. BIU files) into
the program tests.
Also, create title_block.cpp to break a dependency that pulled
in eda_text.cpp when using the TITLE_BLOCK object.
The issue for the grid color was due to the fact there are 2 places to
store the color: the color settings and the m_gridColor GERBVIEW_FRAME member.
The worksheet color (color set to RED after a color change in layer render)
is a bit strange: looks like LAYER_GERBVIEW_WORKSHEET and LAYER_WORKSHEET
are both used to draw the worksheet.
ADDED new rectangle graphics tool for PCBNew and Footprint Editor.
Also adds rectangle tool to both Footprint Editor and PCBNew Place
menus.
The Aux Origin tool can come back once we have multi-select toobar
buttons.
Also collapses an unnecessary level out of the auxOrigin and gridOrigin
settings.
Fixes https://gitlab.com/kicad/code/kicad/issues/2246
The m_auxiliaryToolBar manage controls, not tools, and controls need specific
management after a wxToolbar->Clear() call.
wxToolbar->Clear() does not delete controls, but stop their management.
We can't get all the way there because we can't create pads outside
of modules and the Gerbers don't store any grouping/footprint info.
This change moves us from outputing a via for every flashed item
(some of which don't even have holes) to synthesizing pads from
flashed items using a via (when they have holes) and a copper polygon.
This is much better for SMD pads, perhaps better for regular pads,
and no worse for vias.
You can now choose the behavior of dragging with the
middle and right mouse buttons.
You can also choose which modifier keys to use for
panning and zooming with the scroll wheel or trackpad.
You can also customize the zoom speed, which makes
it possible to have a good zoom experience on a wider
range of input devices.
You can also now zoom by dragging with the right or
middle button if desired.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/3885
Fixes https://gitlab.com/kicad/code/kicad/-/issues/4348
Now only reposition a window if it is completely on a
disconnected display or if only one corner is on screen
and it is within a region close to the screen border.
CHANGED: Window position on startup should be preserved more
Move the camera out to its own so that everything else is board-
related, and then rename BOARD_ADAPTER.
At some point the flags should probably be moved out too, and they
can have the EDA_3D_SETTINGS name.
Replace SEVERITY_ERROR by RPT_SEVERITY_ERROR to avoid collision with a system definition.
Replace other SEVERITY_XXX by RPT_SEVERITY_XX for consistency.
Fix compil warnings and some other compil issues.
Keeping a pointer to the actual file history inside a special
file history menu led to many cases of use after free crashes,
so instead rework the actual file history to add the menu
items.
Fixes https://gitlab.com/kicad/code/kicad/issues/3741
The Gerber attribute deletion command (%TD,xxx) always cleared all attributes,
instead of clearing xxx attribute.
Therefore some attributes were not always displayed.
CHANGED: Settings are now stored in versioned sub-directories
ADDED: First-run dialog for migrating settings from a previous version
CHANGED: Settings are now stored as JSON files instead of wxConfig-style INI files
CHANGED: Color settings are now all stored in a separate settings file
CHANGED: The symbol editor and footprint editor now have their own settings files
CHANGED: Color settings are no longer exposed through BOARD object
CHANGED: Page layout editor now uses Eeschema's color scheme
Settings are now managed through a central SETTINGS_MANAGER held by PGM_BASE.
Existing settings will be migrated from the wxConfig format on first run of each application.
Per-application settings are now stored in one class for each application.