The original code was commented on. Unlike blender 2.79, the grid units are now displayed only when RV3D_VIEW_IS_AXIS. The visible subdivisions in the grid are made by the GPU and depending on the pixel. The code used here only mimics this behavior and adds a bit of overhead. Reviewers: fclem, campbellbarton Subscribers: FloridaJo, zlsa, rl.amorato, EitanSomething Differential Revision: https://developer.blender.org/D4325