Added Distance(VECTOR2) function that returns a double. Removed
superfluous EuclideanNorm, GetLineLength, integer constructor for
EDA_ANGLE (this promotes to double in the CTOR), DistanceLinePoint and
HitTestPoints
Also extended the size for arc calculations that get distances to center
points to avoid overflow
Using a boolean argument just leads to a lot of trailing booleans in the
function calls and is not user friendly. Instead, introduce PostAction()
to send an action that runs after the coroutine (equivalent to passing
false or the default argument), and leave RunAction as the immediate
execution function.
We're getting segfaults in places where this isn't checked. Also, add
some asserts so we can catch bad tool push/pop.
Removes all uses of GetCommandStr() and makes it private.
ADDED arc, circle and rectangle shapes for schematic. Shapes support
line styles and fill colors.
CHANGED sheet background color in Edit Text & Graphics Properties to
fill color (and it now affects shapes).
Pushed STROKE_PARAMS down into common and moved all shapes to using it
for stroke descriptions.
This assigns the "Tab" key to a general pcbnew 45° limitation. Limit
can be enabled/disabled using context menu as well.
Removed the user preference for 45° limitation on graphic lines as that
is overlapping with the general limitation, which is not an editing
preference so much as a temporary adjustment to tool action.
Related to https://gitlab.com/kicad/code/kicad/-/issues/8490
They don't define a KiCad string class, so the header file name was
somewhat misleading. But the fact that they didn't match definitely
made coding more difficult.
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.
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