YAV's RAD Tools
Tips!
This information is taken directly from the "Using YAV's RAD Tools" window of the YAV's RAD Tools installer project.
Click here to send me feedback (Christopher@yav.com).
Back to YAV's Home Page
Back to YAV's Downloadable Software Page
Back to the YRT main menu!
INSTALLATION TIPS:
- Step 1:
-
- With SuperCard 3.0, YAV's RAD Tools no longer needs to be in the SC Pouch but please don't rename it.
- Step 2:
- Read this screen if you haven't done so (and especially if you aren't doing so right now).
- Step 3:
- Read the "Frequently Asked Questions" if you haven't done so.
- Step 4:
- Go to the "Tools" window ("YAVtools 1 2 3")
- Step 5:
- Experiment with the tools using the two experimentation fields and the "Demo" button.
- Step 6:
- Create a "shell" project with a fully functional version of YAV's RAD Tools pre-installed by selecting "Install YAV's RAD Tools..." from the "Special" menu to access the built-in installer.
- Step 7:
- Quit this (the "YAV's RAD Tools") project and relaunch SuperCard by double-clicking on the "shell" project.
REMARKS: The main commands you need to know are:
For the initial loading:
global bsun
open resources
get hasMemory(2048*1024)
put value(word 2 of long name of this project) into myPath
get LoadYAVsRADtools (myPath,"YRT Demo © YAV 1998")
get hasMemory(2048*1024)
Alternatively, registered users would use the following code to load YAV's RAD Tools (note that it is also necessary to install the "UgKp" registration resource in your project):
global bsun
open resources
get hasMemory(2048*1024)
put value(word 2 of long name of this project) into myPath
get LoadYAVsRADtools (myPath,"1234-5678-9101-2131User Name",<options>)
get hasMemory(2048*1024)
Removing YAV's RAD Tools:
Always pass the following when you quit.
GENERAL TIPS:
- To copy any demo script to the clipboard, simply click on the "Demo" button with the option key and the shift key down.
- Selecting items from the "YAVtools" menus with the option key will place the syntax of the selected item onto the clipboard.
- Some other menu items also offer alternate functionality when you select them with the optionkey down. For example, Save (with optionKey) will do a compact and save; Quit (with optionKey) will force a serious quit that will usually get you out of any trouble you might have gotten into.
- Many buttons provide alternate functions when clicked with the option key down (check out their scripts too).
- It is important to learn to use the "yt" command or command-H to bring up YAV's RAD Tools on-line help. This is available from the YAV's RAD Tools project and also from any project in which YAV's RAD Tools is installed (for example a YAV app Shell project).
- Using "yt" or "Help" or command-H will also give you more general SuperCard tips.
- Also, there is a good deal of information to be found in the "Frequently Asked Questions" window as well as the "More Info" window (both of this windows are accessible by way of the "Special" menu.
- As you read the following text YRT stands for "YAV's RAD Tools" and YAS stands for "YAV app Shell"
- It is usually not a good idea to have launched YRT and then open YAS. On the other hand, YRT has been designed to open after YAS has been launched because in that case YRT functions as part of the on-line help system to YAS. This goes for any project you might have installed YAV's RAD Tools into.
CONVENTIONS:
- Functions are listed in all menus and elsewhere with trailing parentheses. For example:
yrtFunction()
- Anything else is a command (meaning that it doesn't return any thing and therefore doesn't need to be proceeded by get, put, if, or to. In other words, commands need to be the first item on a script line (basic to a good deal scriptors... although not all).
- There are a good deal of short-named commands and functions. These adhere to the following naming conventions.
- Several of the short-named terms are "synonyms" for a longer command, for example:
- lpi() is a synonym for LastPathItem()
- gf is a synonym for getFile
- Others were chosen because they are just easy to remember:
- aq() means "add quotes"
- cs means "compact and save"
- ghm means "get hasMemory"
- By far, the vast majority of short-named functions can be decoded as follows:
- t= true
- f= false
- e= empty
- c= character
- w= word
- i= item
- s= set (occasionally "short")
- g= get
- r= replace
- b= but (i.e., "all but")
- f= first
- l= last (occasionally "long" or "line")
- x= exit (to SuperCard)
- i or if = if
- z = zero
- ii = "if in"
- n = "the number of"
- s = short (occasionally "set")
- a = abbreviated
- l = long (occasionally "last" or "line")
- m= my
- -bf = background field
- -bb = background button
- -bg = background graphic
- -cf = card field
- -cb = card button
- -cg = card graphic
As you can see from the chart above, the "3-char wonders" all follow a consistent and logical acronym system: for example, "ncb()" returns the number of card buttons. "iex(arg)" checks the contents of the argument and then if it's empty exits to SuperCard.
Example:
note: This would probably never happen in real life.
YRT:
if iit(gfc(glw("YAV's RAD Tools")),ln()) and izf(ncf()) then put slt((blc(rft((glw(sq(glw(mln())))),"C"))),"!")
OK, OK... I know that SuperCard is supposed to do away with such gobbledygook BUT... the above example would probably only occur in the bizarro world. If you check out the scripts in this project and also the YAV app Shell project, you'll see that the tools aren't really used like this very often.
Straight:
- if (first char of last word of "YAV's RAD Tools" is in long name of this project) = true and (the num of card fields) is not 0 then
- get the long name of the target
- get last word of it
- if first char of it = quote then delete first char of it
- if last char of it = quote then delete last char of it
- get last word of it
- put "C" into first char of it
- delete last char of it
- put "!" after it
- put it
- end if
INFORMATION ABOUT THE YRT WINDOWS:
- There are 11 windows to the YRT project.
- Window 1 is, of course, an anchor window of type Palette set off in cyberspace about a football field away from the text you are reading here.
- Window 2 is the About window and the first time you access that window you will see the Allegiant logo animation. There is a function in the project script that determines whether or not you are opening the About box for the first time.
- Window 3 is called "YAVtools 1 2 3" and provides demos of most of the YRT commands and functions. Also this window serves as the Help window when you access on-line help from any project with YRT installed (that is why it must be in the pouch - because that's where the "yt" command looks for it.
- Window 4 is the "Info" window that comes up after the first About box. This provides a summary of YAV's RAD Tools. You are urged to read the information in that window.
- Window 5 contains both the "Frequently Asked Questions" and also the "Installer" for the YAV app Shell project.
- Window 6 is the Preferences window. You can check to see how this project reads these preference in the openProject script.
- Window 7 is the Text window. This is where imported text is placed. You may find the handler in the growbox at the lower left interesting because it doesn't require any XFCNs. You can do "Save As.." when this window is open to export the text. Further, this window is used to hold bug reports. A working font menu should appear when this window is open. Further, undo should be active in this window. Beta-testers who find a bug can initiate a bug report with the date and time-stamped command or function name placed automatically in this window by selecting items from the YAVtools 1, 2, or 3 menus while holding the commandKey down.
- Window 8 is the Pict window. This is where imported PICTs are placed. The window gets resized to the size of the PICT. This window is also exportable with "Save As..."
- Window 9 is where the words "Window 10 is where the words" appear followed by the word "appear".
- Window 10 is a pseudo-dialog box for Find and Replace.
- Window 11 is a a configuration dialog for configuring YAV App Shell projects.
CREATING A SHELL PROJECT:
Whenever you type "MakeShell" (and return) a new shell project called YAV app Shell is placed in your SC Pouch folder. That's pretty simple. The shell project has ten fully-scripted menus (Apple, File, Edit, Special, Windows, and a Text menu with the submenus: Font, Size, Style, and Align... note that the Text menu appears only when the Text window is visible.) and seven windows.
The Shell project's seven windows are:
- Window 1 is, of course, an anchor window of type Palette set off in cyberspace about a football field away from the text you are reading here.
- Window 2 is the About window and the first time you access that window you will see the Allegiant logo animation. There is a function in the project script that determines whether or not you are opening the About box for the first time.
- Window 3 is called "Main" and you might want to make it your main document window.
- Window 4 is the Preferences window. You can check to see how this project reads these preference in the openProject script. There is a similar handler in the YAV app Shell project script but it is up to you to do something with the preferences.
- Window 5 is the Pict window. This is where imported PICTs are placed. The window gets resized to the size of the PICT. This window is also exportable with "Save As..."
- Window 6 is the Text window. This is where imported text is placed. You may find the handler in the growbox at the lower left interesting because it doesn't require any XFCNs. You can do "Save As.." when this window is open to export the text.
- Window 7 is a pseudo-dialog box used by the Find and Replace option.
Here are some suggestions for using the YAV app Shell:
- Remember to build your own help facility instead of the one you find in the YAV app Shell (which is for YRT).
- Fix up the button names in the Preferences window and the scripts to handle it in the project script (use YAV's RAD Tools as an example). There is already a handler in the project script of YAV app Shell to use.
- While you add objects to your project, don't forget that YAV's RAD Tools has a built-in "nudger" if you press the arrowKeys with the optionkey and the shiftKey down while objects are selected. Also, if you forget the syntax of any command or function simply use the "yt" help function and keep the YAV's RAD Tools help open. When YAV's RAD Tools is being used as Help for YAV app Shell you will notice that six pop-up menus appear. Selecting a command or function from the last three of these menus will place the syntax onto the clipboard.
- Study the docs. Undo, Save, Open, Import, Export, and some of the other features might require adding a command here or there.
- Make liberal use of Command-H
- "Close All" with the optionkey quits YAV app Shell but not other projects that might be open.
- Don't forget to give credit to the makers of SuperCard.
YRT HomePage and Download Area |YRT Command and Function List |YRT Tips |YRT FAQ |YRT Press Release
Return to www.yav.com
Graphics, text, sounds, etc. Copyright © Christopher Yavelow 1994 - 1998