Registers the action quick_attr_tolerance() - because of the name of the action, the property editor and attribute edit dialogs will call this action when the user clicks on assisted edit.
When quick_attr_tolerance() is called, it first queries the original tolerance value using propget() and checks if the value is present in the array of known tolerances. If so, it saves the index of the value, because the enum widget communicates in integer indices. The same for loop also builds a flat list of values in a string for initializing the enum.
Next the dialog box is created using the DAD API. The change callback of the enum is made to call our own action qa_tolerance_remember() which is used to remember the last selected value in a script-global variable. After running the dialog box in modal mode (which is required by the quick attr infrastructure), set the new value as symbol attribute using propset(). The return value of the function is as defined by the quick attr infrastructure.
How to test: