How to get grid size ?

 

Is there a function to do so ?

 
Grid size is a fixed number of pixels. Just measure it.