// =========================================================================== // Copyright 2018 Autodesk, Inc. All rights reserved. // // Use of this software is subject to the terms of the Autodesk license // agreement provided at the time of installation or download, or which // otherwise accompanies this software in either electronic or hard copy form. // =========================================================================== // // // Creation Date: 18 Oct 1997 // // Procedure Name: // resetGridToDefault // // Description: // Resets the grid to the settings in stored in preferences. // // Return Value: // None. // global proc resetGridToDefault() { if ( `optionVar -exists gridSpacing` ) { // // Set the grid spacing/size in the new unit system // grid -toggle `optionVar -query showGrid` -spacing `optionVar -query gridSpacing` -divisions `optionVar -query gridDivisions` -size `optionVar -query gridSize` ; } if (`optionVar -exists displayGridAxes` ) { // // Reset the new grid display options. These are not included // with the spacing, divisions, and size options above because // these were added for Maya 4.0 (while the others have existed // since 1.0). So it is possible that the pref file contains the // old options vars but it may not have the new ones. // grid -displayAxes `optionVar -query displayGridAxes` -displayGridLines `optionVar -query displayGridLines` -displayDivisionLines `optionVar -query displayDivisionLines` -displayPerspectiveLabels `optionVar -query displayGridPerspLabels` -displayOrthographicLabels `optionVar -query displayGridOrthoLabels` -displayAxesBold `optionVar -query displayGridAxesAccented` ; } if (`optionVar -exists displayGridPerspLabelPosition` ) { // // grid -perspectiveLabelPosition `optionVar -query displayGridPerspLabelPosition` -orthographicLabelPosition `optionVar -query displayGridOrthoLabelPosition` ; } }