Dec 232017
 
Bullet Menu Macro for WordpPerfect 6.0.
File BULLET60.ZIP from The Programmer’s Corner in
Category Word Perfect
Bullet Menu Macro for WordpPerfect 6.0.
File Name File Size Zip Size Zip Type
BULLETS.DOC 16587 5986 deflated
BULLETS.WPM 21245 5805 deflated

Download File BULLET60.ZIP Here

Contents of the BULLETS.DOC file


WPC
(U.%U.0EWY0llB#
!!PY!p!!!P9!p! +"
)hW

o'XBULLETS.WPM"Bullets&SpecialCharacters"JPage

1

"HHXX'HH">'
!d>(Dj$hdHP LaserJet IIIPBBBBBBBBBBHP3P.PRSRS?,\,\,,H 0H2BULLETS.WPMF10typeoverCtrlOptionStyNoNumberStyNoNumerDLGCREATEDLGENDchartextFORNEXTctrlOPDlgNoOKDlgNoShadowhposvposboxwideboxtall3;vpos*1;boxwide;boxtall*TOUPPERchartext[i"sty;hpos;vpos"ENDFORENDIFNTOCchartext[1A.Small5th chars[result chars[5OnikArianCompuServe

o'XBULLETS.WPM"Bullets&SpecialCharacters"JPage

1

"HHXX'HH">'
!d><6X9`+Courier<6X9`+ CourierLegal)p`CG Times< 9+CourierBold<6X9`+CourierR< 9+(CourierBoldLegalA,_p CG TimesBold<6X9`+"CourierItalicb?xxx,,Xx]q{c?xxx,,/XxTd8RCR,,hXRTf?xxx,,XxgTgs4ddd,,dh?xxx,,Xxi7WCW,,@XWj?xxx,,yXx/@0
\}3|x9"AIP[rE?0404/[email protected]@LL "/6=Dz/)@."u,ae^;C]ddCCCdCCCCddddddddddCCY~~vCN~sk~CCCddCYdYdYCdd88d8ddddJN8ddddYYdYddddddCdddddddddYYYYYY~Y~Y~Y~YC8C8C8C8ddddddddddYdddddsdYYYYYYYd~Y~Y~Y~YddddddddC8C8C8C8oNd~8~8~8<|8dtddddJJJkNlLkNkN~8~8~8dddddddYXYd~8dJkN~8ddddd~YC88d4CCddCC/NdddCYQQddddddFddddFCChhd44ddzzdddvooChdFdhddCCzCddoddCdYds]zUvdYYCCCCz~ozoY~NYdYC8YooYdYzsdzdd~YYzozzzz~NdC88YYYzzYzzzzCCCdddddddzzzzzzzzzzzzzzzzzzzzzzNNNNNNNdddddddddddddddddddddd888888888888YYYYYYYYYYYYYYYYYYYzzzzzzzzzzzzzzzzzzzzzzsdYC"AIP[rE?0404/[email protected]@LL "AIP[rE?0404/[email protected]@LL "/6=Dz/)@."u,ae^;C]ddCCCdCCCCddddddddddCCdxN`xoCCCddCdoYoYFdo8Co8odooYNCodddYdddddddddCddddddddodddddYYYYYN8N8N8N8oddddooooddoddddxodddYYYYoYYYYddddddooN8N8N8N8r`o888N8oooddYYYoNoNoNoNCCCoooooodYYYo8oYoNCddodoYN88d4CCddCC/NdddCdUUddddddFddddFCCssd44ddzzddd~ooCsdFdsddCCzCddoddCdYds`zUvdddCCCCzozoYNYYYN8YooYdYzzdzddYYzozzzzNYN88YYYzzYzzzzCCCdddddddzzzzzzzzzzzzzzzzzzzzzzNNNNNNNYYYYYYYYYYYYYYYYYYYYYY888888888888YYYYYYYYYYYYYYYYYYYzzzzzzzzzzzzzzzzzzzzzzzdYC"AIP[rE?0404/[email protected]@LL <6X9`(CourierX<6X9`+Courier(_2o$
j!hW
j!hWXX8CH:;88CH:;8r^4`
Thisdocumentationfile.x BULLETS.WPM
Themacrofile.w
@ CopythefilestoyourWPmacrodirectory.Then,pressAlt+F10andtype
Bullets.Betteryet,renamethemacrotoanAltkeythatdoesn't conflictwithWordPerfect'spull-downmenus.Alt+Bwouldbeagood
n choice.Thenyouwillbeabletoquicklyinsertabulletatanytime.Allitwouldtakeistwokeystrokes,asopposedtofloggingthroughvariousnesteddialogues.Acoupleofthingstonote:o0Thismacrodoesn'tchecktoseeifyouaresomewhereotherthanthe normaleditingscreen.Thatallowsyoutoinsertbulletsandspecialcharactersintoheaders,footers,etc.
%% o0Themacrodoesforceinsertmodeon,topreventtheaccidental= overwritingoftext.Itwillrestorethetypeoverstatewhenitisfinishedrunning.
%% NOTESFORMACROPROGRAMMERS% Thismacrodemonstratessometricks.Notethatthereisonlyonedialog,andthatitcontainsatotalof35CtrlOption9!9controls.All35areactive,ratherthanthesomewhatlimiting9orlessthatareusuallypresentinWordPerfect'sdialogboxes.Whilethisisanatypicalapproach,itisusefulinthosecircumstanceswhenyoudon'twanttohitmultiplekeystrokestogetthejobdone.Creatingmorethan9activeCtrlOptioncontrolsiseasy.JustuseStyNoNumber!asthecontrolstyletoremovethenumberonanumbered&!% control.Then,incorporateanalphaornumericcharacter,precededbyatilde(~)inthecontrol'stitle.Thus,thefollowing:"' @DLGCONTROL(CtrlOption!;; ~B.Back&Forth;StyNoNumer!;;;;)F$ ) wouldappearas:B.Back&Forth%!+ Then,whenyouhit B,thedialogisexited,andthecontrol'snumberm'6#- ispassedtotheDLGCREATEvariable.Withthisapproach,youcanhaveasmanyas36activecontrolsavailable(AZand09).Thetrickwithnumberedcontrols(suchasCtrlOption!)istokeeptrackofthecontrol'snumber,sothatyoucantesttheDLGCREATEvariablewhenthedialogisexited.Whenwritingamacro,youcancheckwhatacontrol'snumberisbyplacingthefollowingrightafterDLGEND:PROMPT(result)WAIT(20).-})5 Then,thecontrol'snumberisbrieflydisplayedwhenithasbeenselected.D/
+7 Themacroalsomakesuseofarrays,whichareawonderfulfeatureofWordPerfect'snewmacrolanguage.Notethatthismacrohastwotypesofarrays.o0One,calledchars,hastheactualbulletsandspecialcharactersasW itselements.Themacroinsertsoneoftheseelementsintothecurrenttextwhenanoptionischosenfromthedialog.
%% o0Theotherarray,calledchartext,holdsthetextdescriptionsofthosew
@ bulletsandcharacters.Itselementsareusedbythemacrointhedialogboxcontrol'stitles.
%% ApowerfulfeatureofarraysisthateachitemcanbecheckedforandusedinFORNEXTstatements.Ifyouarenewtomacroprogramming,Ihaveaddedasegmentoftextfromthemacrotodemonstrateonewaythatarrayscanbeused.Aportionofthemacroislistedbelow,followedbyanexplanation.//=================BeginexamplectrlOP=CtrlOption!sty=StyNoNumber!DLGCREATE(result; Bullets&Fractions666"6;DlgNoOK!+DlgNoShadow!;;;80;)g0 hpos=6vpos=2boxwide=40boxtall=21DLGCONTROL(CtrlLabel!;; Bullets666"6;;hpos3;vpos1;boxwide;boxtall) x=97FORNEXT(i;1;19;1)y= ~666"6+TOUPPER(NTOC(x))+ .666"6]& DLGCONTROL(CtrlOption!;;y+chartext[i];sty;hpos;vpos)vpos=vpos+1x=x+1ENDFOR..................DLGENDIF(result=1)GO(End)ENDIFTYPE(chars[result])GO(End)//=================EndexampleThecodethat'slistedabovecreatescontrolsforadialogbox(optionsAS),displaysthem,checksforaresultofactiontaken,andinsertsthecorrespondingbulletintothedocument.Hereishowitworks:o0Ratherthaninsertingactualnumbersforpositionandsizeintothe,(4 DLGCONTROLcommands,Iprefertousevariablessuchashposfor-})5 horizontalposition,vposforverticalposition,etc.Thatway,ifyou|.E*6 havetomoveagroupofcontrols,youcanjusteditthevariables,ratherthanhavingtoediteachDLGCONTROLcommand.0+8%% o0x=97storesWordPerfect'snumericequivalentforthe akeytoa7 variablenamedx.NTOC(x)convertsthatnumbertothecharacter a. Then,theTOUPPERcommandcapitalizesitto A.Whenyoutackonthe .666"6characterstring,youget: A..Thisisassignedtoavariablen namedy.t=%% o0TheprecedingisacteduponinaFORNEXTstatement19times,andxis incrementedeachtime,sothatx=97,98....andy= A., B.....%% o0TheDLGCONTROL(CtrlOption!;;y+chartext[i];sty;hpos;vpos)commandthatc, isintheFORNEXTloopthenusestheyvariable19timesaswell,as+
partofitstitle.
%% o0Thechartext[i]isalsopartofthecontrol'stitle.ThevariableiL
belongstoFORNEXT.Initially,i=1,andforeachloopthevalueisK incrementedby1.Now,chartext[i]referstooneoftheitemsthat makeupthechartextarray.Onthefirstloop,itischartext[1], whichisthecharacterstring Smallroundblackcircle4,3.l
Therefore,onthefirstFORNEXTloopDLGCONTROL'Stitleisy+chartext[i],translated: A.Smallroundblackcircle.:%% o0TheTYPE(chars[result])statementattheendofthesamplealso demonstratestheuseofarrays.Theresultvariablebelongstotheb DLGCREATEcommand,andstoresthenumberofthecontrolthatwaspickedtoexitthedialog.Assumethatthe5thchoicewaspicked.Then,result=5,andchars[result]isthesameaschars[5],the5th elementofthecharsarray.Therefore,TYPE(chars[5])meansTYPEthe 5thelementofthearraycalledchars.ThishappenstobetheJ characterfortheMediumroundhollowcircle(4,1).
%% Tosumitup,ifyouhaveonearrayfortextdescriptionsofthebullets(chartext),andanotherarrayfortheactualbulletsthemselves(chars),j andthetextelementscorrespondtothebulletelements,thenitisi2 fairlyeasytousetheminboththecreationofdialogboxes,viatheDLGCONTROLcommand,andinactionitemssuchasTYPE.Hopeyoufindthisbriefexplanationhelpful.Allcomments,suggestions,etc.aremostwelcome.Enjoy!OnikArian,CompuServe#70671,507%

7


 December 23, 2017  Add comments

Leave a Reply