txtStatA1 = 14 txtStatA2 = 15 txtStatA3 = 136 txtStatA4 = 72 radButA1 = 140 radButA2 = 18 radButA3 = 234 radButA4 = 32 radButB1 = 140 radButB2 = 38 radButB3 = 234 radButB4 = 50 txtStatB1 = 266 txtStatB2 = 15 txtStatB3 = 368 txtStatB4 = 48 edtBoxA1 = 266 edtBoxA2 = 53 edtBoxA3 = 360 edtBoxA4 = 70 else -- set dialog box values for PC -- diaBeg, pshButA, pshButB values as before -- txtStatA revised, the other values are new txtStatA1 = 3 txtStatA2 = 15 txtStatA3 = 68 txtStatA4 = 40 radButA1 = 70 radButA2 = 8 radButA3 = 117 radButA4 = 24 radButB1 = 70 radButB2 = 25 radButB3 = 117 radButB4 = 40 txtStatB1 = 133 txtStatB2 = 6 txtStatB3 = 184 txtStatB4 = 24 edtBoxA1 = 133 edtBoxA2 = 25 edtBoxA3 = 184 edtBoxA4 = 40 endif

--Dialog box asking user to make more choices dialogbegin diaBeg1, diaBeg2, diaBeg3, diaBeg4, shiftChars Pushbutton pshButA1,pshButA2,pshButA3,pshButA4, "OK" Static txtStatA1,txtStatA2,txtStatA3,txtStatA4, "Choose direction to shift baseline:" -- -- -- --To change direction of default shift, remove ", 1" from next line, add to following line Radiobutton radButA1,radButA2,radButA3,radButA4,"UP", 1 Radiobutton radButB1,radButB2,radButB3,radButB4,"DOWN" Static txtStatB1,txtStatB2,txtStatB3,txtStatB4,"Enter points to shift baseline:" -- -- -- --To change amount of default shift, change value in quotes at end of next line Edit edtBoxA1,edtBoxA2,edtBoxA3,edtBoxA4,"0.5" Pushbutton pshButB1,pshButB2,pshButB3,pshButB4,"Cancel" dialogend >gt;>gt; dialogChoices

--if user clicked "OK," then do something. If user clicked "Cancel" then go to cancel section switch dialogChoices(1) caseof "Cancel" -- user canceled goto cancelLabel default --check user input and store in variables --Down button state shows up in 5th parameter of dialogChoices. --Amount of shift shown in 7th parameter of dialogChoices shiftVal = dialogChoices(7) if dialogChoices(5) = 1 shiftDir = "down" else shiftDir = "up" endif goto workLabel endswitch

label workLabel if shiftChars = "Shift First & Last of Selection" -- user wants to shift only first and last characters gettextcursor >gt;>gt; ...,beginning,end --set cursor at beginning of selected text settextcursor -2,beginning,beginning --select character to right of cursor textSelect +char --shift baseline typeoptions dontcare, dontcare, dontcare, dontcare, ~""(shiftVal), ~""(shiftDir) --set cursor at end of selected text settextcursor -2,end,end --select last character of the selected text textSelect -char --shift baseline typeoptions dontcare, dontcare, dontcare, dontcare, ~""(shiftVal), ~""(shiftDir) --exit script goto cancelLabel else -- user wants to shift entire selection typeoptions dontcare, dontcare, dontcare, dontcare, ~""(shiftVal), ~""(shiftDir) goto cancelLabel endif

--The message to give if there is no text selected. label sorryNoTextLabel message "Sorry, but I can't do that. You must have" message "some text selected for this script to run." RETURN --The cancel routine referred to several places in the script. label cancelLabel RETURN --end of script