Purpose
Opcode format | Opcode | Operand Format | Comments |
Extended ASCII | (URL | [<ws><IIndex>[<ws>([<ws>]<TAddress>\
[<ws><TName>[<ws>]])]*][<ws>]) |
Establishes URL definition associated with index and assigns (or removes) a URL to or from geometric primitives. |
Index An integer to identify a URL
Address Uniform Resource Locator
Name A user friendly name of a URL that is displayed by a WHIP! data viewing application
A URL is just another WHIP! data attribute. In the same way that color is handled, so are URLs. For example, if WHIP! data has red as its current color, all primitives get drawn in red until the color is changed. The same is true for URLs. A URL is set and all primitives have that URL attached until the URL is changed. To deactivate URLs, i.e., set to no URL, the command (URL) is used. Other than the null form, a URL basically has three parts:
(URL (0 http://www.autodesk.com Autodesk)) The URL will be attached to subsequent geometry. The actual URL is http://www.autodesk.com but the user friendly name "Autodesk" can be displayed by a WHIP! data viewing application.
(L 10,10 35,35) A URL is attached to this line
(URL ) No URL will be attached to subsequent geometry
(L 0,20 20,20) No URL is attached to this line
(URL 0) The shortened URL (substitute for http://www.autodesk.com) will be attached to subsequent geometry
(L 15,15 20,20) A URL is attached to this line
(URL ) No URL will be attached to subsequent geometry
As with other attributes, only one URL link attribute is active at a time. If a URL link attribute is active in WHIP! data and a second URL link attribute is specified, only the later URL link attribute applies to subsequent geometric primitives.
Attaching multiple URLs to geometric primitives is illustrated in the following example:
(L 20, 20 30, 30) Two URLs are attached to this same line
(URL ) No URL will be attached to subsequent geometry
A URL may be attached to geometric primitives that are invisible (see the Set Visibility function). A WHIP! data reading application should allow the user to select such invisible geometry and execute the attached URL. This is useful, for example, when you want a URL executed whenever the user clicks in a general region of an image, but displaying the "hot" region would interfere with the illustration.