Posted by Ralph Vince on November 22, 2000 at 09:32:26:
Creating 'Template' Drawings in Technadraw
------------------------------------------
Technadraw was designed to create drawings parametrically, "To-scale." Oftentimes, this may NOT be the intended result.
Such a case may occur, say, if someone is drawing a cylinder where the stroke length is so excessively long, that the drawing resemles a pencil, so to speak, in the view. There are simply times where a template of the drawing, making it appear as though it breaks in the center, is the desired result, yet, the dimensions displayed must be accurate.
To create such a, 'templated,' drawing in Instrux, first, set a variable indicating whether or not this drawing is to be a templated drawing. Allow this variable to default to 0, indicating it is NOT a templated drawing.
Now test for a given condition, usually a ration of one large vertical object and one large horizontal object. In our cylinder example. suppose the height of the front blocks is a catalog variable 'E'.
Thus, if the stroke length divided by E exceeds some value, you want to set a varaible indicating that this is going to be a templated drawing.
As you go to draw the component now, set a new variable for a surrogate stroke length based on whether the drawing is templated or not. If it is NOT templated, make the surrogate stroke length the same as the stroke length. If it IS templated, set the surrogate stroke length to some small value, perhaps 0. Use the surrogate stroke length in lieu of the stroke length throughout the drawing.
In order to get dimensions to display propely, anytime a dimension incorporates teh stroke length, use the SETLASTDIMTEXT command of Instrux immediately after such a DIM statement.
if the drawing is templated, then lastly you want to cut away part of the center. Created a non-existent object, of the appearance you want, and place it into the drawing to cut away part of the drawing.
Sometimes, the users may WANT a to-scale drawing however, so, if you are going to make a drawing templated based on the horizontal/vertical ration, yuo may want to create a MSGBOX dialog while instrux is running to query the user if, in fact, he DOES want the drawing templated, giving him control over this ultimately.