Commit Graph

146 Commits

Author SHA1 Message Date
Jeff Young 4e3109a633 Wide string decls for gerbview. 2022-02-05 22:34:45 +00:00
Jeff Young a6dd1bf09b Implement Reset to Defaults for all preferences panels. 2021-12-24 17:38:39 +00:00
Jeff Young 9ee28ea8f5 Flatten out some more preferences. 2021-12-24 15:43:20 +00:00
Jeff Young d28714167c All the preferences, all the time.
Fixes https://gitlab.com/kicad/code/kicad/issues/7877

Fixes https://gitlab.com/kicad/code/kicad/issues/5153
2021-12-24 13:08:44 +00:00
Jeff Young e26341d424 Cleanup. 2021-12-23 20:36:18 +00:00
Seth Hillbrand 36e07639e0 Trainling -> Trailing 2021-11-08 15:56:51 -08:00
Ian McInerney 69509c9dd1 gerbview: Remove empty strings from PCB layer number combobox 2021-10-13 23:49:52 +01:00
jean-pierre charras 7715d6d396 Gerbview: Minot fix: allows 32 copper layers in Export to Pcbnew.
Fixes #9376
https://gitlab.com/kicad/code/kicad/issues/9376
2021-10-13 18:47:52 +02:00
Jeff Young b84d1456d5 KIFACE_I -> KIFACE_BASE. 2021-09-14 23:45:14 +01:00
Mike Williams 30987cebfe Gerbview: fix cairo negative items and implement real differential mode
Layers with negative objects need to be drawn in a subsurface before
copying so they don't _CLEAR the draw items below them when a negative
object is drawn.

Differential layers are basically the same thing only they use a
different copying operation onto the layers below.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/1863
Fixes https://gitlab.com/kicad/code/kicad/-/issues/4495
2021-08-31 12:43:53 +00:00
jean-pierre charras 210671b10a Gerbview, Excellon reader: add preference to configure default coordinates format. In Excellon drill files, the coordinate format is not specified, and sometimes units and zero option are even not specified, so some drill files cannot be read. In Preferences, default setting options are now added to specify by hand missing info. 2021-08-02 12:55:41 +02:00
Jeff Young f221220fe2 Rename layer ids file.
It hasn't had anything to do with colors or visibility for some time
now.
2021-07-29 16:03:25 +01:00
Wayne Stambaugh 37b200cb3e Pass wxString objects by reference instead of on the stack. 2021-07-27 08:41:27 -04:00
Wayne Stambaugh 1a301d8eea Stop using wxDialog::EndModal() from inside dialogs.
Calling wxDialog::EndModal() directly from inside the dialog is a
potential bug if the dialog is shown in the modeless or window modal
(quasi-modal).  Use the internal button events where possible and
check for the appropriate mode before calling the correct end dialog
function.
2021-07-21 17:38:14 -04:00
Wayne Stambaugh cb72da294a More NULL expunging. 2021-07-16 16:13:41 -04:00
luz paz 0446d35f0d Fix source comment/doc typos (follow-up)
Found via `codespell -q 3 -S *.po,./thirdparty -L aactual,acount,aline,alocation,alog,anormal,anumber,aother,apoints,aparent,aray,dout,einstance,modul,ot,overide,serie,te,,tesselate,tesselator,tht`
2021-07-13 10:48:17 +00:00
Wayne Stambaugh 5395a7fe67 GerbView header housekeeping. 2021-06-03 14:32:24 -04:00
jean-pierre charras 0427bda768 Remove useless wx/wx.h include, that create sometimes compil warnings on msys.
wx/wx.h includes all wxWidgets .h files, and sometimes creates collision
names in #define between kicad and windows headers
Moreover, blindly including a lot of useless files is compil time consuming
2021-05-01 19:32:15 +02: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
Marek Roszko 39fb968820 Fix broken map in findNumX2GerbersLoaded 2021-01-31 11:51:08 -05:00
Jon Evans ff4c01c4a4 Don't say a gerber is an X2 unless the whole attribute is loaded
Fixes https://gitlab.com/kicad/code/kicad/-/issues/7303
2021-01-27 17:17:44 -05:00
Wayne Stambaugh 4619d5e112 Fix more broken Doxygen comment specifiers. 2021-01-26 12:17:52 -05:00
Wayne Stambaugh 08cf9a1e20 Move headers from common folders to appropriate include folders round 1. 2020-12-17 08:12:18 -05:00
Marek Roszko 16e3e59495 Split out arrayDim and MIRROR templates from macros.h
These were not macros
2020-11-17 20:21:04 -05:00
Jeff Young a207bd97bb Naming conventions. 2020-11-17 16:05:49 +00:00
Marek Roszko e928b2d8fd Split EDA_UNITS out from common. 2020-10-25 00:02:52 -04:00
jean-pierre charras 539ac4c214 Remove a few include<wx/wx.h> in many files that do not actually use this include. 2020-10-19 09:00:50 +02:00
Ian McInerney 565bb268bb gerbview: Move more items to actions and tools
* Create a new inspection tool to hold the measure tool and
  the other inspection items
* Move some control functions from the frame to a tool and
  rearrange the code to be cleaner.
2020-10-09 01:55:31 +01:00
Ian McInerney 8b0fb9f4cf Remove units and polar settings from the preferences panels
These options are already available in menus, toolbars and hotkeys,
so having them in the preferences pane is more trouble than it is
worth.
2020-10-04 17:53:55 +01:00
jean-pierre charras 0b23cb7dbb more cleanup about removing useless include 2020-10-03 15:26:03 +02:00
jean-pierre charras 04aa5519d0 Gerbview: code cleanup. Remove many include, now useless. 2020-09-30 12:56:55 +02:00
Jeff Young d1371e513d Make sure Gerber print options have a color settings.
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
2020-08-25 14:08:09 +01:00
Peter Montgomery 5fd7064f76 Add Gerber filename to 'Select Layer:' dialog
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
2020-07-22 02:03:43 +00:00
Peter Montgomery 73168a9405 Gerbview: Keep existing layer selected if user clicks Cancel on 'Select Layer' dialog
Fixes https://gitlab.com/kicad/code/kicad/-/issues/4752
2020-07-11 09:40:46 +00:00
Jeff Young 39d4e422ea Better approximation for pads in Export Gerber to Pcbnew
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.
2020-06-06 16:38:14 +01:00
Jon Evans e59a3d981e Implement a new settings framework across all of KiCad
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.
2020-02-19 23:44:56 -05:00
Mark Roszko 11ff16be4e Switch to scoped enums 2019-12-20 14:11:39 +00:00
Seth Hillbrand 6625d0721e Implement Get/Set display options
The pointer passing for display options is deprecated.  This removes the
excess casting as the EDA_FRAME didn't need the base call with no value.
All requests for display options are now returned const and are updated
with a Set() routine after modification.

In Gerbview, this resolves an issue where the display options were not
stored because it was receiving the NULL from EDA_FRAME.
2019-11-07 08:26:44 -08:00
Jeff Young 8f84c3ec4f Grid rid of GetCanvas/GetGalCanvas distinction now that there's only gal. 2019-06-13 19:58:37 +01:00
Jeff Young 33773bad4d Yet more command conversions to ACTIONs. 2019-06-02 21:10:56 +01:00
Jeff Young c2662b0e11 Retire EDA_DRAW_PANEL and legacy_wx/EDA_DRAW_FRAME. 2019-05-31 21:55:30 +01:00
Jeff Young d2daab808c Remove some legacy cursor handling stuff. 2019-05-31 21:54:22 +01:00
Jeff Young 1a3d0492f5 Push polar coords down into COMMON_TOOLS. 2019-05-18 00:21:49 +01:00
Seth Hillbrand 1e5ba6f1b1 Replace DIM() macro
The standard DIM() macro was not typesafe as it happily deferred errors
to runtime that can be caught at compile time.  Replacing it with a
generic C++11 constexpr allows for typecasting, comparison and compile
time error checking.
2019-01-06 08:43:12 -08:00
jean-pierre charras 9dedbc74a3 Gerbview exporter: fix a wxASSERT. 2018-12-21 13:48:00 +01:00
jean-pierre charras f7cf40f2f4 Fix a few Coverity warnings.
Sometimes a dynamic_cast was used without testing the returned value.
Some are replaced by static_cast, when the dynamic_cast was useless.
2018-11-11 08:28:58 +01:00
Maciej Suminski afda69c9cc Removed default line width setting from the printing dialog 2018-10-31 19:17:30 +01:00
Maciej Suminski 3d15092643 Fixed loading layer visibility setting for printouts 2018-10-31 19:17:30 +01:00
Maciej Suminski d3ea63e133 Removed a redundant parameter from BOARD_PRINTOUT constructor 2018-10-31 19:17:30 +01:00
Maciej Suminski dea778842b Grand printing dialogs refactor
Patch introduces a generic printing settings window that is customized by pcbnew and gerbview.
2018-10-31 19:17:30 +01:00