View->Page Grid checkbox unchecked with grid displayed and vice versa

Steps to reproduce:

Until now, I found three ways to get into this state:

  • open Inkscape
  • Activate grid (View->Page grid)
  • Close (Ctrl+W)
  • Click close without saving

or:

  • open Inkscape
  • Activate grid (View->Page grid)
  • Undo

or (This way is also described in https://bugs.launchpad.net/inkscape/+bug/1318318, I closed it there):

  • open Inkscape
  • Activate grid (View->Page grid)
  • Remove grids in Document Properties -> Grids

What happened?

The View-> Page Grid checkbox is still checked, unchecking it creates a new grid.

What should have happened?

The View->Page grid checkbox becomes unchecked.

Screencap for the second case:

grid_undo_wrong_state

The fact that I found three ways to create this state probably shows that something is fundamentally broken in the "View Grid" logic.

Inkscape Version and Operating System:

  • Inkscape Version: 1.0beta2 (3287d1b, 2019-12-24)
  • Operating System: Windows 10
  • Operating System version: 10.0.18362