.STAK w`. i "  `$ `$ cb%HJ@@""""""""̪3̪3 @""""@ Ā hC0&0 "U""U"U"UU"Uwwww݀UUUU>"AA"A> (PAX%2d$L@ @ ""@@t"G"q]APP HyperCard Lite Home Stack Version 2.2 Copyright 1987-1991,1993 by Apple Computer, Inc. All Rights Reserved. THE MESSAGE HANDLERS USED IN THIS SCRIPT: startUp,getHomeInfo,resume,help,hyperTalk nav,c,b,s,mw,vw,se,ss,xy,disallowInterruption,allowInterruption setUserLevelFive,restoreUserLevel,searchScript,checkForMissingFonts THE FUNCTION HANDLERS USED IN THIS SCRIPT: lastHCItem,checkHCFont XCMD'S USED BY THIS SCRIPT: FontExists XFCN Form: FontExists(,) It returns true if the font/point size is installed or false if not. ----- Startup/Resume Scripts: --------------------------------------------- on startUp -- Requires handler: getHomeInfo,checkForMissingFonts -- gets and sets the user's preferences checkForMissingFonts getHomeInfo -- audio Palette startup if there is a stack "Audio Help" then -- start using stack "Audio Help" -- send "startSound" to stack "Audio Help" -- end if pass startUp -- so others can use it end startUp on getHomeInfo -- Needs: User preferences card of the home stack -- configures HyperCard to the user specified preferences global Stacks,Applications,Documents,UserName if short name of this stack is not "Home" then -- lock screen set lockRecent to true set lockMessages to true push this card -- remember where we are go home -- will take us to the home stack in case we're not there put false into stackIsHome else put true into stackIsHome put (cd fld "User Name" of cd "User Preferences") into UserName set the userLevel to cd fld "User Level" of cd "User Preferences" -- hidden field set the powerKeys to hilite of cd btn id 3 of cd "User Preferences" -- Power Keys set the textArrows to hilite of cd btn id 2 of cd "User Preferences" -- Arrow keys in text -- load the search path globals put bg fld "Paths" of cd "Stacks" of bg "Paths" into Stacks put bg fld "Paths" of cd "Applications" of bg "Paths" into Applications put bg fld "Paths" of cd "Documents" of bg "Paths" into Documents if not stackIsHome then pop card -- return to where we were set lockRecent to false -- clean up for exit set lockMessages to false unlock screen end if end getHomeInfo on resume -- Requires handler: getHomeInfo -- gets and sets user preferences upon returning getHomeInfo pass resume -- so others can use it end resume ----- Help Scripts -------------------------------------------- on help theTopic -- Note: typing "help " into msg box will locate -- the in "HyperCard Help" put "HyperCard Help" into theStack -- if ":" & theStack & return is in the stacks then if the longWindowTitles then show window line (the number of lines of char 1 to offset(":" & theStack & return, the stacks) of the stacks) of the stacks else show window theStack else go to stack theStack in a new window -- try in a new window if the result = "Cancel" then exit to hyperCard else if the result empty then go to stack theStack end if if the result is empty then findInTitle theTopic -- in the help stack end help on hyperTalk theTopic -- Note: typing "hyperTalk " into msg box will locate -- the in "HyperTalk Reference" put "HyperTalk Reference" into theStack -- if ":" & theStack & return is in the stacks then if the longWindowTitles then show window line (the number of lines of char 1 to offset(":" & theStack & return, the stacks) of the stacks) of the stacks else show window theStack else go to stack theStack in a new window -- try in a new window if the result = "Cancel" then exit to hyperCard else if the result empty then go to stack theStack end if if the result is empty then findInTitle theTopic -- in the help stack end hyperTalk ----- Utility Scripts -------------------------------------------- on nav -- type "nav" into message box -- Requires XCMD: palette "Navigator" palette "Navigator" end nav on c -- type "c" into message box -- Requires handlers: setUserLevelFive,restoreUserLevel put the tool into saveTool choose browse tool setUserLevelFive -- so the menu item will be there doMenu "Card Info..." restoreUserLevel choose saveTool end c on b -- type "b" into message box -- Requires handlers: setUserLevelFive,restoreUserLevel put the tool into saveTool choose browse tool setUserLevelFive -- so the menu item will be there doMenu "Bkgnd Info..." restoreUserLevel choose saveTool end b on s -- type "s" into message box -- Requires handlers: setUserLevelFive,restoreUserLevel put the tool into saveTool choose browse tool setUserLevelFive -- so the menu item will be there doMenu "Stack Info..." restoreUserLevel choose saveTool end s on mw -- type "mw" into message box -- Requires XWindow: Message Watcher show window "Message Watcher" end mw on vw -- type "vw" into message box -- Requires XWindow: Variable Watcher show window "Variable Watcher" end vw on se -- type "se" into message box -- Requires XWindow: Script Editor ask "Set script editor font type to:" with "Monaco" -- default value if the result is "Cancel" or it is empty then exit se set scriptTextFont to it ask "Set script editor font size to:" with "9" -- default value if the result is "Cancel" or it is empty then exit se set scriptTextSize to it end se on ss pattern,stackName -- type "ss" into message box -- Requires handler: searchScript searchScript pattern,stackName end ss on xy -- type "xy" into message box to obtain mouse coordinates set cursor to cross repeat until the mouseClick put the mouseLoc && " horz:" & the mouseH && " vert:" & the mouseV end repeat end xy on disallowInterruption -- so can't stop scripts while running set cantAbort of this stack to true end disallowInterruption on allowInterruption -- so can stop scripts while running set cantAbort of this stack to false end allowInterruption on setUserLevelFive -- some things need this userLevel global SvLvl put the userLevel into SvLvl set the userLevel to 5 end setUserLevelFive on restoreUserLevel -- use after setUserLevelFive global SvLvl if SvLvl is a number then set the userLevel to SvLvl end restoreUserLevel on searchScript pattern,stackName -- Requires handlers: setUserLevelFive,restoreUserLevel -- search ALL scripts of a stack for a 'pattern' of characters global ScriptFindString -- HyperTalk global variable set lockRecent to true setUserLevelFive -- saves current level and sets level 5 push card -- remember where we are if pattern is empty then ask "Search for what string?" with ScriptFindString -- if (it is empty) or (the result is "Cancel") then exit searchScript put it into pattern -- otherwise use it as the search pattern end if -- put in HyperTalk global so just CMD-F in editor for easy find put pattern into ScriptFindString set lockMessages to true -- avoid open messages if stackName is not empty then go to stack stackName -- Note: if stackName is empty then we search the current stack set cursor to busy -- search the stack script of the stack if the script of this stack contains pattern then edit script of this stack -- search the background scripts and objects of the stack repeat with curBkgnd = 1 to the number of bkgnds set cursor to busy go to card 1 of bkgnd curBkgnd if the script of this bkgnd contains pattern then edit script of bkgnd curBkgnd repeat with curBgBtn = 1 to the number of bkgnd buttons set cursor to busy if the script of bkgnd button curBgBtn contains pattern then edit script of bkgnd button curBgBtn end repeat repeat with curBgField = 1 to the number of bkgnd fields set cursor to busy if the script of bkgnd field curBgField contains pattern then edit script of bkgnd field curBgField end repeat end repeat -- search the card scripts and objects of the stack repeat with curCard = 1 to the number of cards set cursor to busy go card curCard if the script of this card contains pattern then edit script of this card repeat with curCdBtn = 1 to the number of card buttons set cursor to busy if the script of card button curCdBtn contains pattern then edit script of card button curCdBtn end repeat repeat with curCdFld = 1 to the number of card fields set cursor to busy if the script of card field curCdFld contains pattern then edit script of card field curCdFld end repeat end repeat set lockMessages to false set lockRecent to false pop card -- return to where we were restoreUserLevel -- set userLevel back to whatever it was answer "Search script done!" -- end searchScript function lastHCItem delim,theText -- returns the portion of that follows the last if delim is in theText then put lastHCItem(delim,char offset(delim,theText) + 1 to length(theText) of theText) into theText end if return theText end lastHCItem ----- Font Adjustment Scripts: ---------------------------------- on checkForMissingFonts -- Requires handler: checkHCFont -- check to see if the fonts needed for the stacks are -- installed in the system. Inform the user if they're not. get checkHCFont("Courier","9,12") & checkHCFont("Geneva","10,14") & checkHCFont("Palatino","10,12,14,18,24") & checkHCFont("Helvetica","18,24") -- these are fonts needed by this stack if it is empty then exit checkForMissingFonts else put it into missingFonts beep -- this dialog informs the user which fonts are missing answer "These font(s) are missing from your system:" & return & return & missingFonts & return & "For text to display correctly in the stacks, make sure you have" && "installed the fonts included with HyperCard." -- end checkForMissingFonts function checkHCFont theFont,pointSizes -- Requires XFCN: FontExists -- returns a list of font sizes needed but not in the system put empty into missing -- steps through each point size passed in repeat with count = 1 to the number of items in pointSizes put item count of pointSizes into theCurrentPtSize if not FontExists(theFont,theCurrentPtSize) -- if can't find it then put theCurrentPtSize & "," after missing end repeat if missing is not empty then put theFont & space before missing delete last char of missing put return after missing end if return missing end checkHCFont after missing end if retuMASTiHĝlrt}βLISTiD`$PAGEi!<v|PP03XZ xBƤqѠEЂjHg,aR@|qE`3 H y` h0 N p left arrowon mouseUp visual effect wipe right go prev card end mouseUph0N p right arrowon mouseUp visual effect wipe left go next card end mouseUp"#6DHomeHome CardsBMAPMVVVx"""" ""ؿ"⿆ 3@,-: : z "D BKGD> N    pathson closeField -- the globals declared here are used by HyperCard for locating -- its stacks, applications, and documents -- puts the contents of this field into the appropriate global variable global Stacks,Applications,Documents if line 1 of me is empty then delete line 1 of me do "put me into" && the short name of this card end closeField on exitField closeField end exitField&%Fuctitlef0s !Applicationson mouseUp go to card (the short name of me) end mouseUp `1s{ ! Stackson mouseUp go to card (the short name of me) end mouseUp d2sZ !Documentson mouseUp go to card (the short name of me) end mouseUp 3@m] G/ About Search Paths...on mouseUp -- Requires handler: toggleAboutInfo toggleAboutInfo true -- show the 'About Info' dialog end mouseUp :0N p right arrowon mouseUp visual effect wipe left if the commandKey is down then go last card else go next card end mouseUpZN1K< Return to First Cardon mouseUp go first card end mouseUp ;0 N p left arrowon mouseUp visual effect wipe right if the commandKey is down then go first card else go prev card end mouseUpIC` About Search Paths...on mouseUp -- Requires handler: toggleAboutInfo toggleAboutInfo true -- show the 'About Info' dialog end mouseUp JBm_  About Search Paths...on mouseUp -- Requires handler: toggleAboutInfo toggleAboutInfo true -- show the 'About Info' dialog end mouseUp "K #D"M#6D5A K  About this cardon mouseUp -- Requires handler: toggleAboutInfo toggleAboutInfo false -- hide the 'About Info' dialog end mouseUp4C W About Search Pathson mouseUp -- Requires handler: toggleAboutInfo toggleAboutInfo false -- hide the 'About Info' dialog end mouseUp>FT  OKon mouseDown set the icon of me to "Clicked Close Box" end mouseDown on mouseUp -- Requires handler: toggleAboutInfo set the icon of me to "Close Box" toggleAboutInfo false -- put away the 'About Info' dialog end mouseUp on mouseStillDown if the mouseLoc is not within the rect of me then set the icon of me to "Close Box" else set the icon of me to "Clicked Close Box" end mouseStillDown 5% When you open a stack, document, or application, HyperCard attempts to locate the file you want by searching the folders listed on the appropriate Search Paths card. Each line in the list indicates the location of a folder, including the disk name (and folder and subfolder names, if any). This information is called a search path. Items in a search path are separated by a colon. If the file is not in any of the folders listed, HyperCard displays a directory dialog box and asks you to locate the file. Once you have done so, HyperCard records the files location on the appropriate Search Paths card. The next time you open the file, HyperCard will be able to find it automatically. You can also type folder names directly on this card. Use this format: my disk:HyperCard folder:my stacks:%eHyperCard uses the information in the field below to find your stacks, documents, and applications. K Search PathsMHomePaths Script of Background: Paths THE MESSAGE HANDLERS USED IN THIS SCRIPT: closeCard,resumeStack,toggleAboutInfo on closeCard -- Requires handler: toggleAboutInfo global Stacks,Applications,Documents if visible of bkgnd fld "About This Card" is true then toggleAboutInfo false -- hide the 'About Info' dialog -- insure that the global variables get loaded properly do "put bg field id 6 into" && the short name of this card pass closeCard -- so others can use it end closeCard on resumeStack global Stacks,Applications,Documents -- insure that the global variables get loaded properly do "put bg field id 6 into" && the short name of this card pass resumeStack -- so others can use it end resumeStack on toggleAboutInfo status -- Requires handlers: disallowInterruption,allowInterruption -- show or hide the "card info" disallowInterruption if status is true then put "zoom open" into theEffect else put "zoom close" into theEffect lock screen -- so everthing will appear at once set visible of bkgnd fld "About This Card" to status set visible of bkgnd btn id 52 to status -- About Search Paths set visible of bkgnd btn id 62 to status -- 'checkbox' button "OK" unlock screen with theEffect allowInterruption end toggleAboutInfoBMAPVVVx"""" ""ؿ"⿆ 3@,-: : z "D @BKGDtH >8 &#L paths"%E &%  title,1kq !Your Name:&4 #C Home&6@ titlej70N p right arrowon mouseUp visual effect wipe left go next card end mouseUp 80 N p left arrowon mouseUp visual effect wipe right if the commandKey is down then go first card else go prev card end mouseUp4HomePreferencesBMAPtmmVVVx"""" ""ؿ  @,' 3@,-: : z "D mmmCARD@ "N Y  rw^ Addresseson mouseUp set cursor to watch go to stack "Addresses" -- end mouseUp"1Lc"0 M' "-M *"  Copyrighttw-nB Audio Helpon mouseUp set cursor to watch go to stack "Audio Help" -- end mouseUpGw{v What is HyperCard?on mouseUp set cursor to watch go to stack "What is HyperCard?" -- end mouseUpxw1 Appointmentson mouseUp set cursor to watch go to stack "Appointments" -- end mouseUp HyperCard is a unique software tool that allows you to do more with your computer. With HyperCard, you use documents called stacks. Stacks can help you do many different thingsfor example, you could use a stack to keep track of your appointments, manage your expenses, learn a new language, or record and play sounds. To learn more, click What is HyperCard, to the right. Welcome to HyperCard /1993 Apple Computer, Inc. All Rights ReservedWelcome to...BMAPV'B'/k8@! P0000% 00%H0`, 0`+H 0`ᢆ* 0`"@`%s_s@))) )3@)Ơ8 @8 (05(j77 70T7FPF F0@F F5@Fj666T66T66 P665@6j6 @6 & U&&T&&5T&j&P5&8"@%P@8 5 CARD H@> Xv*   Documents.   Applications documents applications%HHyperCard uses the information in the field below to find your stacks.5 Each line on this card indicates the location of a folder, including the disk name (and folder name, and subfolder names, if appropriate). These locations are called search paths. Each name in a search path is separated by a colon. When you tell HyperCard to open a stack, document, or application, it looks for the file you want by searching through the folders listed on this card. If HyperCard cant find the file, it displays the directory dialog box. Once youve located the file, HyperCard records the files location on this card. The next time you ask for the file, HyperCard will know where to look for it. You can type folder locations on this card to tell HyperCard where to look for your files, for example: my disk:hypercard folder:my stacks: 11StacksCARD @>56 This field will be a shared field when the time is right. In the meantime, I didn't want to copy the same text into this bkgnd field because I was afraid I might forget to make this a shared field later. See this field on the "stacks" card for the real info. Consider this feature "under construction" 01%OHyperCard uses the information in the field below to find your applications. ApplicationsCARD @>%LHyperCard uses the information in the field below to find your documents. 53 This field will be a shared field when the time is right. In the meantime, I didn't want to copy the same text into this bkgnd field because I was afraid I might forget to make this a shared field later. See this field on the "stacks" card for the real info. Consider this feature "under construction"21DocumentsCARD@PHBmp?@ User Nameon closeField global UserName put me into UserName end closeField on exitField global UserName put me into UserName end exitField*  ;"  Browsing( =  Typing* =  Painting'@  UserLevel 1on mouseUp -- Requires handler: updateDisplay -- last word of btn name is userLevel updateDisplay (last word of short name of me) -- in card script end mouseUp@  UserLevel 2on mouseUp -- Requires handler: updateDisplay -- last word of btn name is userLevel updateDisplay (last word of short name of me) -- in card script end mouseUp  UserLevel 3on mouseUp -- Requires handler: updateDisplay -- last word of btn name is userLevel updateDisplay (last word of short name of me) -- in card script end mouseUp,hy; user leveldC Power Keyson mouseUp set powerKeys to the hilite of me end mouseUp nC֠ Arrow Keys in Texton mouseUp set textArrows to the hilite of me end mouseUp ">  "<  "(=  0, mA Arrowon mouseDown -- Requires handler: updateDisplay -- this handler operates the arrow button like a slider control set cursor to arrow -- put item 1 of the loc of me into slideHorz -- horz remains constant put item 2 of the loc of cd btn id 6 into slideTop -- UserLevel 3 put item 2 of the loc of cd btn id 4 into slideBottom -- UserLevel 1 put top of cd btn id 6 into levelTop -- UserLevel 3 -- repeat while the mouse is down set loc of me to (slideHorz&","&(max(slideTop,min(slideBottom,the mouseV)))) end repeat -- -- calculate userLevel based on loc of slider put ((78 - (item 2 of loc of me - levelTop)) div 20) +1 into curLevel updateDisplay curLevel -- show changes end mouseDown *LEU EnableSEZN1K; Return to First Cardon mouseUp go first card end mouseUp %Click the user level you want: Preferences2GUse the Paint tools to change the appearance of cards and backgrounds.Enter and edit text in fields.$Explore stacks but make no changes.6Other settings:falseUser Preferences Script of Card: User Preferences THE MESSAGE HANDLERS IN THIS SCRIPT: openCard,updateDisplay,magic on openCard if the userLevel card field "User Level" -- hidden on this card then updateDisplay the userLevel -- set display to match userLevel pass openCard -- so others can use the message end openCard on updateDisplay whatLevel -- Requires handlers: disallowInterruption,allowInterruption global UserName lock screen set cursor to watch disallowInterruption set the userLevel to whatLevel put min(whatLevel,3) into whatLevel if UserName is not empty then put UserName into cd field "User Name" put whatLevel into cd field "User Level" -- hidden on this card set top of cd btn "Arrow" to top of cd btn ("UserLevel" && whatLevel) repeat with count = 1 to 3 put "UserLevel" && count into btnName set hilite of cd btn btnName to not (count > whatLevel) end repeat set visible of card btn id 3 to whatLevel 3 -- Power Keys set hilite of card btn id 3 to the powerKeys set visible of card btn id 2 to whatLevel 2 -- Arrow keys in text set hilite of card btn id 2 to the textArrows unlock screen allowInterruption end updateDisplay BMAPVz<{(&      ""  SS  ""  "  "?  "S  S"  ""    ""  "S  SÀC  C    c  c  >"  SS  SS  ""  ""  "    80  "` "`  "S  SS    c  c    ?C  C  ""  " #+STBL `FTBLChicagoPalatinoeGenevamF`PRNT  0 VHel number) end mouseUp|@  UserLevel 5on mouseUp SetUserLevel (last word of short name of me) -- in bkgnd script -- (last word of btn name is desired userlevel number) end mouseUp*  ;"  Browsing( Untitled ReportMT@6LVH@PRFT 0 H``y y   nn*GZW TAILNu r det slut