Footprint grabbed by the wrong pin during a move.
Description
When I hover over a pad of a footprint and press m to move it, the footprint is often grabbed by the wrong pin. In the attached screen recording I pressed m while hovering over pin 20, but the footprint is grabbed by pin 21.
vokoscreen-2022-01-16_14-22-09.mkv
At other times, a footprint can not be grabbed by a pad at all, but it's grabbed by it's center, even when Pcb Editor / Preferences / Preferences / Pcb Editor / Editing Options / Magnetic Points / Snap to Pads is set to Always
This behavior was also observed by another user on the forum: https://forum.kicad.info/t/grab-a-component-from-the-center-of-a-pad-to-move-it/33292
Steps to reproduce
- Hover over a pad of a footprint.
- Depress m to move the footprint.
- Observe that the cursor jumps and the footprint is grabbed by another pad.
After more experiments, I discovered it is related to the grid. On a coarse grid (for example 5mm) the behavior is atrocious, while at a fine grid (0.1mm) it seems to work as expected. I am guessing here, but could it be that the cursor location is first mapped to a grid point, and then that grid point is used determine the closest a snap location?
KiCad Version
Application: KiCad PCB Editor
Version: 6.0.1-79c1e3a40b~116~ubuntu20.04.1, release build
Libraries:
wxWidgets 3.0.4
Platform: Linux 5.13.0-25-generic x86_64, 64 bit, Little endian, wxGTK, xfce, x11
wxWidgets: 3.0.4 (wchar_t,wx containers,compatible with 2.8) GTK+ 3.24
Boost: 1.71.0
OCC: 7.5.2
Curl: 7.81.0
ngspice: 31
Compiler: GCC 9.3.0 with C++ ABI 1013
Build settings:
KICAD_USE_OCC=ON
KICAD_SPICE=ON