#!/bin/sh
# MetaCard 2.4 stack
# The following is not ASCII text,
# so now would be a good time to q out of more
exec mc $0 "$@"
altPropEditor 2 8 on preOpenStack
if the mode of me is not 4 then
send paletteMe to me in 30 milliseconds
end if
stripAndShip
if the selectedObject is not empty then
altGetProperties the long ID of the selectedObject
else
put the long ID of the topstack into tParam
altGetProperties tParam
end if
end preOpenStack
on altShowMe
--palette this stack
--show stack "AltHtml"
end altShowMe
on altGetInfo
answer information "Version: " & last word of fld "vers"
end altGetInfo
on closeStack
if the short name of the target contains "altProp" then
remove script of btn "altPropsLib" from front
end if
end closeStack
on paletteMe
palette this stack
end paletteMe
on stripAndShip
show img "size.gif"
put "" into fld "fldObject"
put "" into fld "index"
put "" into fld "indexChar"
put "" into fld "fldProps"
set the altToggleSize of stack "altPropEditor" to "Large"
set the width of stack "altPropEditor" to 204
set the height of stack "altPropEditor" to 239
insert script of btn "altPropsLib" into front
put "frontScripts ON" into fld "tStatus"
set the icon of btn "toggleSize" of stack "altPropEditor" to 1027
set the botRight of btn "Resizer" to the botRight of this cd
set the minWidth of stack "altPropEditor" to 204
set the minHeight of stack "altPropEditor" to 239
end stripAndShip
on resizeStack
if the altToggleSize of stack "altPropEditor" is not "Small" then
put the width of this cd into tW
put the height of this cd into tH
set the width of fld "fldObject" to tW-15
set the width of fld "fldProps" to tW-15
set the height of fld "fldProps" to tH -160
#set the tabStops of fld "fldProps" to 120,tW
set the tabStops of fld "fldProps" to round((tW-15)/2)
#set the bottom of fld "vers" to tH + 2
end if
set the right of grp "ttop" to the right of this cd - 2
set the bottomRight of btn "resizer" to the width of this stack, the height of this stack
end resizeStack
on toggleSize pFrom pExpandTall
if pFrom is "Small" then
show img "size.gif"
if pExpandTall is true then
put the screenrect into tRect
if the platform is "MacOS" then
put 38 into item 2 of tRect
else
put 20 into item 2 of tRect
put item 4 of the windowBoundingRect into item 4 of tRect
end if
get the width of stack "altPropEditor"
set the rect of stack "altPropEditor" to \
item 3 of tRect - it, \
item 2 of tRect, item 3 of tRect, item 4 of tRect
set the bottomRight of btn "resizer" to the width of this stack, the height of this stack
#hide img "size.gif"
else
get the rect of stack "altPropEditor"
set the altToggleSize of stack "altPropEditor" to "Large"
set the rect of stack "altPropEditor" to \
item 1 of it, item 2 of it, \
item 1 of it + the altWidth of stack "altPropEditor", \
item 2 of it + the altHeight of stack "altPropEditor"
end if
insert script of btn "altPropsLib" into front
put "frontScripts ON" into fld "tStatus"
set the altToggleSize of stack "altPropEditor" to "Large"
show btn "resizer"
else
set the altWidth of stack "altPropEditor" to the width of stack "altPropEditor"
set the altHeight of stack "altPropEditor" to the Height of stack "altPropEditor"
set the altToggleSize of stack "altPropEditor" to "Small"
get the rect of stack "altPropEditor"
set the rect of stack "altPropEditor" to \
item 1 of it, item 2 of it, item 1 of it + 204, item 2 of it + 50
remove script of btn "altPropsLib" from front
put "frontScripts OFF" into fld "tStatus"
#hide img "size.gif"
hide btn "resizer"
end if
end toggleSize
i altVers 1.0 altWidth 204
altHeight 974
altLargeRect 78,186,282,425
altColors cforegroundColor
backgroundColor
hiliteColor
borderColor
topColor
bottomColor
shadowColor
focusColoraltGlobalProps eaccentColor
activatePalettes
allowInlineInput
allowInterrupts
arcAngle
backdrop
beepDuration
beepLoudness
beepPitch
blinkRate
brush
brushColor
brushPattern
bufferHiddenImages
centered
centuryCutoff
colormap
convertOctals
cursor
defaultCursor
defaultMenubar
defaultStack
dialogData
directory
dontUseNS
dontUseQT
dontUseQTEffects
doubleClickDelta
doubleClickInterval
dragSpeed
effectRate
emacsKeyBindings
eraser
explicitVariables
extendKey
fileType
filled
grid
gridSize
idleRate
hideConsoleWindows
hidePalettes
httpHeaders
httpProxy
jpegQuality
lineSize
linkColor
linkHiliteColor
linkVisitedColor
lockColormap
lockCursor
lockErrorDialogs
lockMoves
lockRecent
lookAndFeel
lowResolutionTimers
moveSpeed
multiple
multiSpace
navigationArrows
numberFormat
paintCompression
pattern
penColor
penPattern
playDestination
playLoudness
polySides
printCardBorders
printColors
printFontTable
printGutters
printMargins
printPaperSize
printRotated
printRowsFirst
printScale
printTextAlign
printTextHeight
printTextSize
printTextStyle
privateColors
proportionalThumbs
randomSeed
raiseMenus
raisePalettes
recordChannels
recordCompression
recordFormat
recording
recordInput
recordRate
recordSampleSize
recursionLimit
relayerGroupedControls
roundEnds
roundRadius
screenGamma
screenNoPixmaps
screenSharedMemory
scriptTextFont
scriptTextSize
secureMode
selectGroupedControls
selectionHandleColor
selectionMode
serialControlString
shellCommand
showInvisibles
slices
socketTimeoutInterval
spray
stackFileType
stacksInUse
startAngle
syncRate
textArrows
toolTipDelay
traceDelay
typingRate
twelveHourTime
underlineLinks
useUnicode
videoClipPlayer
windowBoundingRectaltToggleSize LargealtCurrentObj Zstack "C:/Documents and Settings/chipp.CHIPP-OFFICE/Desktop/aaCurrent/altSplashConfig.rev" altPropEditor
U ms sans serif
@U ms sans serif
@W ms sans serif U ms sans serif
U Tahoma U Tahoma U Tahoma
@U Tahoma
@W Tahoma U Tahoma U Courier New U Courier New U Tahoma U System U Tahoma
U Verdana
@W Verdana
W Tahoma W Tahoma U Lucida Grande cREVGeneral
debugObjects ^field id 1008 of card id 1002 of stack
field id 1008 of card id 1002 of stack "altPropEditor"breakPoints props P
cREVGeneral
fldObject @ 5 , cREVGeneral revUniqueID
1071895146754 [stack "C:/Documents and Settings/chipp.CHIPP-OFFICE/Desktop/aaCurrent/altSplashConfig.rev"
fldProps { 6--> all handlers
on linkClicked p
put the altCurrentObj of stack "altPropEditor" into tObjName
if tObjName = "global props" then
put "" into tObjName
else
put " of " & tObjName into tObjName
end if
put the vScroll of me into tScroll
put item 2 of p into tLineNum
set itemDel to tab
put item 1 of line tLineNum of me into tProp
if ":" is in tProp then
delete char 1 to 3 of tProp
end if
put item 2 of line tLineNum of me into tPropVal
set itemDel to ","
put item 1 of p into tLink
put isValidEdit(tProp,tLink) into tLink
switch tLink
case "CheckTrue"
put "set the " & tProp & tObjName & " to false" into toDo
do toDo
#put "
" into tLinkName
break
case "CheckFalse"
put "set the " & tProp & tObjName & " to true" into toDo
do toDo
#put "
" into tLinkName
break
case "Number"
ask "Enter a Number for the " &tProp& " property" with tPropVal
if the result is "Cancel" then exit to top
if isNumber(it) then
put "set the " & tProp & tObjName & " to " & it into toDo
do toDo
#put ""&it&"" into tLinkName
end if
break
case "Colors"
put line tLineNum of the htmlText of fld "fldProps" of stack "altPropEditor" into tHtm
put offset("bgcolor=",tHtm) into tOff
put char tOff+9 to tOff + 15 of tHtm into tCol
answer Color with tCol
if the result is "Cancel" then
put "set the " & tProp & tObjName & " to " "e"e into toDo
else
put "set the " & tProp & tObjName & " to " & quote & it & quote into toDo
end if
do toDo
break
case "Other"
#breakpoint
ask "Enter a Value for the " &tProp& " property" with tPropVal
if the result is "Cancel" then exit to top
put it into tNew
replace "," with "" in tNew
if isNumber(tNew) then
if first word of tObjName is "card" then
answer warning "Cannot edit this property!"
else
put "set the " & tProp & tObjName & " to " & it into toDo
end if
else
put "set the " & tProp & tObjName & " to " "e&it"e into toDo
end if
do toDo
break
case "Prop"
case "gProp"
altFindProp tProp
exit to top
case "id"
answer warning "Cannot edit this property!"
break
case "colors"
answer warning "Cannot edit this property here. Use the Property Inspector."
break
case "htmlText"
put the htmlText of the selectedObject into fld "props" of stack "longEdit"
put "htmlText property:" into fld "PropLabel" of stack "longEdit"
modal "longEdit"
if the dialogdata is "cancel" then exit to top
set the htmlText of the selectedObject to the dialogData
break
default
#put ""&tPropVal&"" into tLinkName
end switch
if tProp is "name" then
altGetProperties the selectedObject
else
altGetProperties the altCurrentObj of stack "altPropEditor"
end if
set the vScroll of me to tScroll
end linkClicked
function isValidEdit pPropName,pLinkName
if pLinkName is "CheckTrue" or pLinkName is "CheckFalse" then return pLinkName
switch pPropName
case "id"
return "id"
break
case "colors"
return "colors"
break
case "htmltext"
return "htmltext"
break
default
return pLinkName
end switch
end isValidEdit
on altFindProp pWord
revDocsDisplayTranscriptTerm pWord,"property"
end altFindProp
O _
cConsLast prop HandlerScroll 1varChecking falseHandlerName linkClicked message
cREVTable currentvscroll 0formattedview altId 0
backgroundBehavior
borderWidth 2
boundingRect empty
cantDelete
cantSelect
colors
disabled
dontSearch
hilitedButton 0
hScroll 0
hScrollbar
id 1030
label empty
layer 14
lockLoc
margins 4
name group id 1030
opaque
patterns
radioBehavior
rect 8,446,210,518
scrollbarWidth 20
showBorder
showName
tabGroupBehavior
textFont empty
textSize empty
textStyle empty
threeD
toolTip empty
traversalOn
visible
vScroll 0
vScrollbar currenthscroll 0currentxmouseloc 91
viewablerows 35currentymouseloc 76scrollbarwidth 16
cellyspacing 13rightfieldloc 208viewablecolumns 4numbertabstops 1topfieldloc 96
leftfieldloc 6
cellxspacing 120currentview altId 0
backgroundBehavior
borderWidth 2
boundingRect empty
cantDelete
cantSelect
colors
disabled
dontSearch
hilitedButton 0
hScroll 0
hScrollbar
id 1030
label empty
layer 14
lockLoc
margins 4
name group id 1030
opaque
patterns
radioBehavior
rect 8,446,210,518
scrollbarWidth 20
showBorder
showName
tabGroupBehavior
textFont empty
textSize empty
textStyle empty
threeD
toolTip empty
traversalOn
visible
vScroll 0
vScrollbar bottomfieldloc 328 cREVGeneral table falserevUniqueID
1071895165989breakPoints 43 altId 0
Prop,1
Number,1 alwaysBuffer
Prop,2
` CheckTrue,2 1012
cantAbort
Prop,3
`
CheckFalse,3 1013
cantDelete
Prop,4
`
CheckFalse,4 1013
cantModify
Prop,5
`
CheckFalse,5 1013 #C: foregroundColor Effective
Prop,6
" Colors,6
#C: backgroundColor Effective
Prop,7
" Colors,7
C: hiliteColor Effective
Prop,8
" Colors,8
C: borderColor
Prop,9
" Colors,9 C: topColor Effective
Prop,10
"
Colors,10
C: bottomColor Effective
Prop,11
"
Colors,11
C: shadowColor Effective
Prop,12
"
Colors,12
C: focusColor Effective
Prop,13
"
Colors,13
decorations default
Prop,14
Other,14 destroyStack
Prop,15
`
CheckTrue,15 1012
destroyWindow
Prop,16
`
CheckTrue,16 1012 dynamicPaths
Prop,17
` CheckFalse,17 1013
formatForPrinting
Prop,18
` CheckFalse,18 1013 hcAddressing
Prop,19
` CheckFalse,19 1013
icon 0
Prop,20
Number,20 iconic
Prop,21
` CheckFalse,21 1013 id 1063
Prop,22
Number,22 linkColor empty
Prop,23
Other,23
linkHiliteColor empty
Prop,24
Other,24 linkVisitedColor empty
Prop,25
Other,25 liveresizing
Prop,26
` CheckFalse,26 1013
maxHeight 65535
Prop,27
Number,27
maxWidth 65535
Prop,28
Number,28 menubar empty
Prop,29
Other,29 metal
Prop,30
` CheckFalse,30 1013
minHeight 32
Prop,31
Number,31
minWidth 32
Prop,32
Number,32 name altSplashConfig
Prop,33
Other,33 passkey empty
Prop,34
Other,34 password empty
Prop,35
Other,35 patterns
Prop,36
Other,36 rect 120,140,552,586
Prop,37
Other,37 resizable
Prop,38
`
CheckTrue,38 1012
scroll 0
Prop,39
Number,39 shadow
Prop,40
`
CheckTrue,40 1012 startUpIconic
Prop,41
` CheckFalse,41 1013 style toplevel
Prop,42
Other,42 textFont empty
Prop,43
Other,43 textSize empty
Prop,44
Other,44 textStyle empty
Prop,45
Other,45
title empty
Prop,46
Other,46 underlineLinks empty
Prop,47
Other,47
visible
Prop,48
`
CheckTrue,48 1012 windowManagerPlace
Prop,49
` CheckFalse,49 1013 windowShape 0
Prop,50
Number,50 ` @ M checked D LLLLLL 4
1 6 . @ @ @ Q [ _ N D @ 8 ? ? ?0 .0 $p 1 ; ? cREVGeneral revUniqueID
1071897675797
unchecked D LLLLLL , 4
1 6 + @ @ @ @ @ @ @ @ @ 8 ? ? ? ? ? ? ? ? ? cREVGeneral revUniqueID
1071897708586
index fon mouseMove
put the mouseChar into fld "indexChar"
end mouseMove
on mouseDown
--lock screen
put fld "indexChar" into tC
put fld "fldProps" into ttxt
put 1 into tLine
repeat for each line L in ttxt
if char 1 of L is tC then
put word 1 of L into tFound
exit repeat
end if
end repeat
find tFound in fld "fldProps"
put word 2 of the foundLine into tLine
put the textheight of fld "fldProps" into tHt
put (tLine-1) * tHt into tPixels
set the vScroll of fld "fldProps" to tPixels
wait 90 milliseconds
find empty
--unlock screen
end mouseDown
black " x cREVGeneral revUniqueID
1071904661277 ACDFHILMNPRSTUVW
indexChar ( s cREVGeneral revUniqueID
1071905963271
this card Ep --> all handlers
on mouseUp
if the altToggleSize of stack "altPropEditor" is "Small" then
toggleSize "Small"
end if
altGetProperties the long ID of the current card of the topstack
end mouseUp
D :
cConsLast prop HandlerScroll 0varChecking falseHandlerName mouseUp message cREVGeneral revUniqueID
1071908692202breakPoints topStack Ep --> all handlers
on mouseUp
if the altToggleSize of stack "altPropEditor" is "Small" then
toggleSize "Small"
end if
altGetProperties the long ID of the topStack
end mouseUp
<