Setting grid origin by exact coordinates in KiCad 8

In KiCad 7 the View / Grid Properties… command opened the following window, which had input boxes for the grid origin coordinates:

However, in KiCad 8 that command had disappeared, and the Edit Grids… command in the grid selector popup now opens the Grids page in the Preferences window, which now allows adding multiple custom grid spacing values — but it does not offer a way to set the grid origin by entering the coordinate values manually. Looks like the only way to set the grid origin is to place it by clicking the point, which makes it hard to set the origin to a precise value.

The intended use case that worked in KiCad 7 is:

  • The grid spacing is set to 0.79375 mm (19.05 mm / 24), or 31.25 mil — this value works well for placing the MX switch footprints (actually for many keyboard layouts 19.05 mm / 8 would be enough, but the extra factor of 3 is needed sometimes, and 19.05 mm is actually 3/4 in anyway).
  • 5.08 mm (200 mil) is the offset between the center of the MX switch footprint and the center of the RGB LED footprint for that switch; setting the grid origin to (0, 5.08 mm) allows using the same grid to place the LED footprints. Note that 5.08 mm is not an integer multiple of 0.79375 mm (5.08 / 0.79375 = 6.4), so even setting that value by clicking would require switching the grid spacing (and it’s easy to get the value wrong when using that method).

Is is possible to make special “RGB-LED-for-MX-switch” footprints that have the origin at the point where the center of the MX switch footprint would be (and actually there are such footprints in the used library already); in that case the same grid could be used to place the switch and LED footprints without the need to change the grid origin. However, this workaround breaks if the LED footprint needs to be rotated around its actual center, which is sometimes required to avoid collisions with other components; in that case a simple LED footprint is required, and it needs to be placed on a grid with the 200 mil offset.

Maybe there is some other way to set the grid origin in KiCad 8 which I missed?

It is currently kind of hidden. Right click the “show grid” button in the toolbar at the left side of the screen.

Issue report for this: Specifying grid origin explicitly is no longer discoverable (#17007) · Issues · KiCad / KiCad Source Code / kicad · GitLab

1 Like

If you right click on the grid icon in the upper left corner, you get:

image

Which goes to:
image

2 Likes

Yeah, that’s really undiscoverable. Apparently that’s the only button on that toolbar that responds to the right click, although there are also some buttons on the right toolbar that have a right click menu (and one of them — Draw a line — has an empty menu, which looks like a bug). And the Route tracks button has both a right click menu and a long press popup.

Also the right toolbar has the “Place the grid origin point” button, which does not have a right click menu.

Anyway, thanks for the solution.

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.