question: public double snap ( double value ) { if ( gridEnabled ) { value = Math . round ( value / gridSize ) * gridSize ; } return value ; }
target:  Snaps the given numeric value to the grid if <gridEnabled> is true.