# HG changeset patch # User Claus Gittinger # Date 968949552 -7200 # Node ID 176ae89e0b31650f18a2bf7fdfad06075fcb0a86 # Parent c3cf368bccf1d198ceb7afc8b3713dffc254d073 *** empty log message *** diff -r c3cf368bccf1 -r 176ae89e0b31 UILayoutTool.st --- a/UILayoutTool.st Sun Sep 03 18:43:57 2000 +0200 +++ b/UILayoutTool.st Thu Sep 14 18:39:12 2000 +0200 @@ -13,6 +13,8 @@ +"{ Package: 'stx:libtool2' }" + ApplicationModel subclass:#UILayoutTool instanceVariableNames:'modifiedHolder aspects selection currentTool layoutView tabList layoutSpec toolsDictionary' @@ -28,21 +30,14 @@ privateIn:UILayoutTool ! -UILayoutTool::AnyLayout subclass:#AlignmentOrigin +UILayoutTool::AnyLayout subclass:#LayoutFrame instanceVariableNames:'' classVariableNames:'' poolDictionaries:'' privateIn:UILayoutTool ! -UILayoutTool::AnyLayout subclass:#LayoutOrigin - instanceVariableNames:'' - classVariableNames:'' - poolDictionaries:'' - privateIn:UILayoutTool -! - -UILayoutTool::AnyLayout subclass:#LayoutFrame +UILayoutTool::AnyLayout subclass:#AlignmentOrigin instanceVariableNames:'' classVariableNames:'' poolDictionaries:'' @@ -56,6 +51,13 @@ privateIn:UILayoutTool ! +UILayoutTool::AnyLayout subclass:#Extent + instanceVariableNames:'' + classVariableNames:'' + poolDictionaries:'' + privateIn:UILayoutTool +! + UILayoutTool::AnyLayout subclass:#Rectangle instanceVariableNames:'' classVariableNames:'' @@ -63,7 +65,7 @@ privateIn:UILayoutTool ! -UILayoutTool::AnyLayout subclass:#Extent +UILayoutTool::AnyLayout subclass:#LayoutOrigin instanceVariableNames:'' classVariableNames:'' poolDictionaries:'' @@ -1036,6 +1038,865 @@ constantNamed:#'UILayoutTool::AnyLayout imageFractY' ifAbsentPut:[(Depth1Image new) width: 16; height: 16; photometric:(#palette); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'??>@@X@A?''@@X@A??@?0A>@C0@O@A>@O + + ^super helpSpec addPairsFrom:#( + +#bottomAbsolute +'Offset of the bottom edge; positive is to the bottom, negative to the top.' + +#bottomFixPartLayout +'Set the layout for a fixed area at the bottom of the widgets containers space' + +#bottomHalfLayout +'Set the layout for the bottom half of the widgets containers space' + +#bottomLeftQuarterLayout +'Set the layout for the bottom-left quarter of the widgets containers space' + +#bottomRelative +'Relative corner y of the selected widget.' + +#bottomRightQuarterLayout +'Set the layout for the bottom-right quarter of the widgets containers space' + +#horizontalFixPartLayout +'Set the layout for a fixed-height horizontal area' + +#leftFixPartLayout +'Set the layout for a fixed area at the left of the widgets containers space' + +#leftHalfLayout +'Set the layout for the left half of the widgets containers space' + +#makeBottomAbsolute +'Compute pure-absolute y.' + +#makeBottomRelative +'Computes pure-fractional y.' + +#makeBottomRelativeFromBottom +'Compute fraction+offset for y relative to containers bottom.' + +#makeRightAbsolute +'Compute pure-absolute x.' + +#makeRightRelative +'Compute pure-fraction x.' + +#makeRightRelativeFromRight +'Compute fraction+offset for x relative to containers right.' + +#rightAbsolute +'Offset of the right edge; positive is to the right, negative to the left.' + +#rightFixPartLayout +'Set the layout for a fixed area at the right of the widgets containers space' + +#rightHalfLayout +'Set the layout for the right half of the widgets containers space' + +#rightRelative +'Relative corner x of the selected widget.' + +#topFixPartLayout +'Set the layout for a fixed area at the top of the widgets containers space' + +#topHalfLayout +'Set the layout for the top half of the widgets containers space' + +#topLeftQuarterLayout +'Set the layout for the top-left quarter of the widgets containers space' + +#topRightQuarterLayout +'Set the layout for the top-right quarter of the widgets containers space' + +#verticalFixPartLayout +'Set the layout for a fixed-height vertical area' + +) +! ! + +!UILayoutTool::LayoutFrame class methodsFor:'image specs'! + +setBottomFixPartIcon + "This resource specification was automatically generated + by the ImageEditor of ST/X." + + "Do not manually edit this!! If it is corrupted, + the ImageEditor may not be able to read the specification." + + " + self setBottomFixPartIcon inspect + ImageEditor openOnClass:self andSelector:#setBottomFixPartIcon + " + + + + ^Icon + constantNamed:#'UILayoutTool::LayoutFrame setBottomFixPartIcon' + ifAbsentPut:[(Depth4Image new) width: 16; height: 16; photometric:(#palette); bitsPerSample:(#(4 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@H"H"@BH"H @!!DQD@DQDR@BDQDP@QDQH@H"H"@BH"H @@@@@@@@@@@b') ; colorMapFromArray:#[0 0 0 255 0 0 255 255 255]; mask:((Depth1Image new) width: 16; height: 16; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'??>@@X@A @F@@X@A @F@@X@A @G??????????????? + + ^Icon + constantNamed:#'UILayoutTool::LayoutFrame setBottomHalfIcon' + ifAbsentPut:[(Depth4Image new) width: 16; height: 16; photometric:(#palette); bitsPerSample:(#(4 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@"H"H"H"H"@BDQDQDQDQH@HQDQDQDQD @!!DQDQDQDR@BDQDQDQDQH@H"H"H"H"H @@@@@@@@@@@b') ; colorMapFromArray:#[0 0 0 255 0 0 255 255 255]; mask:((Depth1Image new) width: 16; height: 16; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'??>@@X@A @F@@X@A @F@@_???????????????????? + + ^Icon + constantNamed:#'UILayoutTool::LayoutFrame setBottomLeftQuarterIcon' + ifAbsentPut:[(Depth4Image new) width: 16; height: 16; photometric:(#palette); bitsPerSample:(#(4 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@H"H"@@@@@@@!!DQH@@@@@@BDQD @@@@@@HQDR@@@@@@@!!DQH@@@@@@BDQD @@@@@@H"H"@@@@@@@@@@@@@@@@@b') ; colorMapFromArray:#[0 0 0 255 0 0 255 255 255]; mask:((Depth1Image new) width: 16; height: 16; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'??>@@X@A @F@@X@A @G?@_ + + ^Icon + constantNamed:#'UILayoutTool::LayoutFrame setBottomRightQuarterIcon' + ifAbsentPut:[(Depth4Image new) width: 16; height: 16; photometric:(#palette); bitsPerSample:(#(4 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@BH"H"@@@@@@HQDQH@@@@@@!!DQD @@@@@BDQDR@@@@@@HQDQH@@@@@@"H"H @@@@@@@@@@@b') ; colorMapFromArray:#[0 0 0 255 0 0 255 255 255]; mask:((Depth1Image new) width: 16; height: 16; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'??>@@X@A @F@@X@A @F@@XG? _>A?8G? _>A?8G??? + + ^Icon + constantNamed:#'UILayoutTool::LayoutFrame setHorizontalFixPartIcon' + ifAbsentPut:[(Depth4Image new) width: 16; height: 16; photometric:(#palette); bitsPerSample:(#(4 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:' +@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@"H"H@H"H"@BDQDP@QDQH@HQDQ@ADQD @"H"H@H"H"@@@@@@@@@@@@@@ +@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@b') ; colorMapFromArray:#[0 0 0 255 0 0 255 255 255]; mask:((Depth1Image new) width: 16; height: 16; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'??>@@X@A @F@@_???????????????8@A @F@@X@A?? + + ^Icon + constantNamed:#'UILayoutTool::LayoutFrame setLeftFixPartIcon' + ifAbsentPut:[(Depth4Image new) width: 16; height: 16; photometric:(#palette); bitsPerSample:(#(4 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:' +@@@@@@@@@@@BH"@@@@@@@@HQH@@@@@@@@!!D @@@@@@@BDR@@@@@@@@HQH@@@@@@@@!!D @@@@@@@@@@@@@@@@@@@@@@@@@@@@@!!D @@@@@@@BDR@@@@@@@@HQ +H@@@@@@@@!!D @@@@@@@BDR@@@@@@@@H"H@@@@@@@@@@@@@@@@@@b') ; colorMapFromArray:#[0 0 0 255 0 0 255 255 255]; mask:((Depth1Image new) width: 16; height: 16; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'???<@_0A?@G<@_0A?@G<@_0A?@G<@_0A?@G<@_0A?? + + ^Icon + constantNamed:#'UILayoutTool::LayoutFrame setLeftHalfIcon' + ifAbsentPut:[(Depth4Image new) width: 16; height: 16; photometric:(#palette); bitsPerSample:(#(4 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@@@@@@@@BH"H @@@@@@HQDR@@@@@@@!!DQH@@@@@@BDQD @@@@@@HQDR@@@@@@@!!DQH@@@@@@BDQD @@@@@@HQDR@@@@@@@!!DQH@@@@@@BDQD @@@@@@HQDR@@@@@@@!!DQH@@@@@@BDQD @@@@@@H"H"@@@@@@@@@@@@@@@@@b') ; colorMapFromArray:#[0 0 0 255 0 0 255 255 255]; mask:((Depth1Image new) width: 16; height: 16; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'????@_ + + ^Icon + constantNamed:#'UILayoutTool::LayoutFrame setRightFixPartIcon' + ifAbsentPut:[(Depth4Image new) width: 16; height: 16; photometric:(#palette); bitsPerSample:(#(4 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:' +@@@@@@@@@@@@@@@@@@H"H@@@@@@@@!!D @@@@@@@BDR@@@@@@@@HQH@@@@@@@@!!D @@@@@@@BDR@@@@@@@@@@@@@@@@@@@@@@@@@@@@@BDR@@@@@@@@HQH@@@ +@@@@@!!D @@@@@@@BDR@@@@@@@@HQH@@@@@@@@"H @@@@@@@@@@@b') ; colorMapFromArray:#[0 0 0 255 0 0 255 255 255]; mask:((Depth1Image new) width: 16; height: 16; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'??>@O8@? C>@O8@? C>@O8@? C>@O8@? C>@O8@??? + + ^Icon + constantNamed:#'UILayoutTool::LayoutFrame setRightHalfIcon' + ifAbsentPut:[(Depth4Image new) width: 16; height: 16; photometric:(#palette); bitsPerSample:(#(4 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@@@@@@@@@@@@@@"H"H@@@@@@BDQD @@@@@@HQDR@@@@@@@!!DQH@@@@@@BDQD @@@@@@HQDR@@@@@@@!!DQH@@@@@@BDQD @@@@@@HQDR@@@@@@@!!DQH@@@@@@BDQD @@@@@@HQDR@@@@@@@!!DQH@@@@@@BH"H @@@@@@@@@@@b') ; colorMapFromArray:#[0 0 0 255 0 0 255 255 255]; mask:((Depth1Image new) width: 16; height: 16; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'??>@?8C? O>@?8C? O>@?8C? O>@?8C? O>@?8C??? + + ^Icon + constantNamed:#'UILayoutTool::LayoutFrame setToRightQuarterIcon' + ifAbsentPut:[(Depth4Image new) width: 16; height: 16; photometric:(#palette); bitsPerSample:(#(4 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@@@@@@@@@@@@@@"H"H@@@@@@BDQD @@@@@@HQDR@@@@@@@!!DQH@@@@@@BDQD @@@@@@HQDR@@@@@@@"H"H@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@b') ; colorMapFromArray:#[0 0 0 255 0 0 255 255 255]; mask:((Depth1Image new) width: 16; height: 16; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'??>@?8C? O>@?8C? O>@?8C? @F@@X@A @F@@X@A?? + + ^Icon + constantNamed:#'UILayoutTool::LayoutFrame setTopFixPartIcon' + ifAbsentPut:[(Depth4Image new) width: 16; height: 16; photometric:(#palette); bitsPerSample:(#(4 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@@@@@@@@BH"H @"H"H@HQDQ@ADQD @!!DQD@DQDR@BH"H @"H"H@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@b') ; colorMapFromArray:#[0 0 0 255 0 0 255 255 255]; mask:((Depth1Image new) width: 16; height: 16; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'???????????????? @F@@X@A @F@@X@A @F@@X@A?? + + ^Icon + constantNamed:#'UILayoutTool::LayoutFrame setTopHalfIcon' + ifAbsentPut:[(Depth4Image new) width: 16; height: 16; photometric:(#palette); bitsPerSample:(#(4 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@@@@@@@@BH"H"H"H"H@HQDQDQDQD @!!DQDQDQDR@BDQDQDQDQH@HQDQDQDQD @"H"H"H"H"@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@b') ; colorMapFromArray:#[0 0 0 255 0 0 255 255 255]; mask:((Depth1Image new) width: 16; height: 16; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'?????????????????????8@A @F@@X@A @F@@X@A?? + + ^Icon + constantNamed:#'UILayoutTool::LayoutFrame setTopLeftQuarterIcon' + ifAbsentPut:[(Depth4Image new) width: 16; height: 16; photometric:(#palette); bitsPerSample:(#(4 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@@@@@@@@BH"H"@@@@@@HQDQH@@@@@@!!DQD @@@@@BDQDR@@@@@@HQDQH@@@@@@"H"H @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@b') ; colorMapFromArray:#[0 0 0 255 0 0 255 255 255]; mask:((Depth1Image new) width: 16; height: 16; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'???? _>A?8G? _>A?8G? X@A @F@@X@A @F@@X@A?? + + ^Icon + constantNamed:#'UILayoutTool::LayoutFrame setVerticalFixPartIcon' + ifAbsentPut:[(Depth4Image new) width: 16; height: 16; photometric:(#palette); bitsPerSample:(#(4 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:' +@@@@@@@@@@@@@@@"H @@@@@@@BDR@@@@@@@@HQH@@@@@@@@!!D @@@@@@@BDR@@@@@@@@HQH@@@@@@@@@@@@@@@@@@@@@@@@@@@@@HQH@@@@@@@@!!D @@@@@@ +@BDR@@@@@@@@HQH@@@@@@@@!!D @@@@@@@BH"@@@@@@@@@@@@@@@b') ; colorMapFromArray:#[0 0 0 255 0 0 255 255 255]; mask:((Depth1Image new) width: 16; height: 16; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'??>G8X_!!!!>FG8X_!!!!>FG8X_!!!!>FG8X_!!!!>FG8X_!!?? + + ^ + #(#FullSpec + #name: #windowSpec + #window: + #(#WindowSpec + #label: 'UILayoutTool-LayoutFrame' + #name: 'UILayoutTool-LayoutFrame' + #min: #(#Point 10 10) + #max: #(#Point 1152 900) + #bounds: #(#Rectangle 12 22 411 325) + #forceRecursiveBackground: false + ) + #component: + #(#SpecCollection + #collection: #( + #(#UISubSpecification + #name: 'layoutOriginSpec' + #layout: #(#LayoutFrame 1 0.0 6 0 0 1.0 110 0) + #majorKey: #UILayoutTool + #minorKey: #layoutOriginSpec + ) + #(#FramedBoxSpec + #label: 'Corner' + #name: 'FramedBox' + #layout: #(#LayoutFrame 1 0.0 113 0 0 1.0 214 0) + #labelPosition: #topLeft + #component: + #(#SpecCollection + #collection: #( + #(#LabelSpec + #label: 'Right:' + #name: 'labelRight' + #layout: #(#AlignmentOrigin 68 0 25 0 1 0.5) + ) + #(#ActionButtonSpec + #label: 'imageFractX' + #name: 'actionRelativeRight' + #layout: #(#LayoutFrame 78 0 14 0 100 0 36 0) + #activeHelpKey: #makeRightRelative + #hasCharacterOrientedLabel: false + #tabable: true + #model: #relativeRight + ) + #(#InputFieldSpec + #name: 'fieldRightFraction' + #layout: #(#LayoutFrame 103 0 14 0 153 0 36 0) + #activeHelpKey: #rightRelative + #tabable: true + #model: #rightFraction + #group: #inputGroup + #type: #numberOrNil + #acceptOnLostFocus: true + #acceptChannel: #acceptChannel + #modifiedChannel: #modifiedChannel + #acceptOnPointerLeave: false + ) + #(#ActionButtonSpec + #label: 'imageAbsXFromRight' + #name: 'actionRightRelativeRight' + #layout: #(#LayoutFrame 257 0 14 0 279 0 36 0) + #activeHelpKey: #makeRightRelativeFromRight + #hasCharacterOrientedLabel: false + #tabable: true + #model: #rightRelativeRight + ) + #(#InputFieldSpec + #name: 'fieldRightOffset' + #layout: #(#LayoutFrame 203 0 14 0 253 0 36 0) + #activeHelpKey: #rightAbsolute + #tabable: true + #model: #rightOffset + #group: #inputGroup + #type: #numberOrNil + #acceptOnLostFocus: true + #acceptChannel: #acceptChannel + #modifiedChannel: #modifiedChannel + #acceptOnPointerLeave: false + ) + #(#ActionButtonSpec + #label: 'imageAbsX' + #name: 'actionAbsoluteRight' + #layout: #(#LayoutFrame 178 0 14 0 200 0 36 0) + #activeHelpKey: #makeRightAbsolute + #hasCharacterOrientedLabel: false + #tabable: true + #model: #absoluteRight + ) + #(#LabelSpec + #label: 'Bottom:' + #name: 'labelBottom' + #layout: #(#AlignmentOrigin 68 0 53 0 1 0.5) + ) + #(#ActionButtonSpec + #label: 'imageFractY' + #name: 'actionRelativeBottom' + #layout: #(#LayoutFrame 78 0 42 0 100 0 64 0) + #activeHelpKey: #makeBottomRelative + #hasCharacterOrientedLabel: false + #tabable: true + #model: #relativeBottom + ) + #(#InputFieldSpec + #name: 'fieldBottomFraction' + #layout: #(#LayoutFrame 103 0 42 0 153 0 64 0) + #activeHelpKey: #bottomRelative + #tabable: true + #model: #bottomFraction + #group: #inputGroup + #type: #numberOrNil + #acceptOnLostFocus: true + #acceptChannel: #acceptChannel + #modifiedChannel: #modifiedChannel + #acceptOnPointerLeave: false + ) + #(#ActionButtonSpec + #label: 'imageAbsYFromBottom' + #name: 'actionBottomRelativeBottom' + #layout: #(#LayoutFrame 257 0 42 0 279 0 64 0) + #activeHelpKey: #makeBottomRelativeFromBottom + #hasCharacterOrientedLabel: false + #tabable: true + #model: #bottomRelativeBottom + ) + #(#InputFieldSpec + #name: 'fieldBottomOffset' + #layout: #(#LayoutFrame 203 0 42 0 253 0 64 0) + #activeHelpKey: #bottomAbsolute + #tabable: true + #model: #bottomOffset + #group: #inputGroup + #type: #numberOrNil + #acceptOnLostFocus: true + #acceptChannel: #acceptChannel + #modifiedChannel: #modifiedChannel + #acceptOnPointerLeave: false + ) + #(#ActionButtonSpec + #label: 'imageAbsY' + #name: 'actionAbsoluteBottom' + #layout: #(#LayoutFrame 178 0 42 0 200 0 64 0) + #activeHelpKey: #makeBottomAbsolute + #hasCharacterOrientedLabel: false + #tabable: true + #model: #absoluteBottom + ) + ) + + ) + ) + #(#MenuPanelSpec + #name: 'commonLayoutToolBar' + #layout: #(#LayoutFrame 6 0.0 231 0 -4 1.0 263 0) + #level: 0 + #tabable: true + #menu: #commonFrameLayoutsMenu + #textDefault: true + ) + ) + + ) + ) +! ! + +!UILayoutTool::LayoutFrame class methodsFor:'menu specs'! + +commonFrameLayoutsMenu + "This resource specification was automatically generated + by the MenuEditor of ST/X." + + "Do not manually edit this!! If it is corrupted, + the MenuEditor may not be able to read the specification." + + " + MenuEditor new openOnClass:UILayoutTool::LayoutFrame andSelector:#commonFrameLayoutsMenu + (Menu new fromLiteralArrayEncoding:(UILayoutTool::LayoutFrame commonFrameLayoutsMenu)) startUp + " + + + + ^ + + #(#Menu + + #( + #(#MenuItem + #label: 'setTopHalfFrame' + #translateLabel: true + #isButton: true + #nameKey: #setTopHalfFrame + #value: #setTopHalfFrame + #activeHelpKey: #topHalfLayout + #labelImage: #(#ResourceRetriever #'UILayoutTool::LayoutFrame' #setTopHalfIcon) + ) + #(#MenuItem + #label: 'setBottomHalfFrame' + #translateLabel: true + #isButton: true + #nameKey: #setBottomHalfFrame + #value: #setBottomHalfFrame + #activeHelpKey: #bottomHalfLayout + #labelImage: #(#ResourceRetriever nil #setBottomHalfIcon) + ) + #(#MenuItem + #label: 'setLeftHalfFrame' + #translateLabel: true + #isButton: true + #nameKey: #setLeftHalfFrame + #value: #setLeftHalfFrame + #activeHelpKey: #leftHalfLayout + #labelImage: #(#ResourceRetriever nil #setLeftHalfIcon) + ) + #(#MenuItem + #label: 'setRightHalfFrame' + #translateLabel: true + #isButton: true + #nameKey: #setRightHalfFrame + #value: #setRightHalfFrame + #activeHelpKey: #rightHalfLayout + #labelImage: #(#ResourceRetriever nil #setRightHalfIcon) + ) + #(#MenuItem + #label: '' + ) + #(#MenuItem + #label: 'setTopLeftQuarterFrame' + #translateLabel: true + #isButton: true + #activeHelpKey: #topLeftQuarterLayout + #nameKey: #setTopLeftQuarterFrame + #value: #setTopLeftQuarterFrame + #labelImage: #(#ResourceRetriever nil #setTopLeftQuarterIcon) + ) + #(#MenuItem + #label: 'setTopRightQuarterFrame' + #translateLabel: true + #isButton: true + #activeHelpKey: #topRightQuarterLayout + #nameKey: #setTopRightQuarterFrame + #value: #setTopRightQuarterFrame + #labelImage: #(#ResourceRetriever nil #setToRightQuarterIcon) + ) + #(#MenuItem + #label: 'setBottomRightQuarterFrame' + #translateLabel: true + #isButton: true + #activeHelpKey: #bottomRightQuarterLayout + #nameKey: #setBottomRightQuarterFrame + #value: #setBottomRightQuarterFrame + #labelImage: #(#ResourceRetriever nil #setBottomRightQuarterIcon) + ) + #(#MenuItem + #label: 'setBottomLeftQuarterFrame' + #translateLabel: true + #activeHelpKey: #bottomLeftQuarterLayout + #isButton: true + #nameKey: #setBottomLeftQuarterFrame + #value: #setBottomLeftQuarterFrame + #labelImage: #(#ResourceRetriever nil #setBottomLeftQuarterIcon) + ) + #(#MenuItem + #label: '' + ) + #(#MenuItem + #label: 'setTopFixPartFrame' + #translateLabel: true + #isButton: true + #nameKey: #setTopFixPartFrame + #value: #setTopFixPartFrame + #activeHelpKey: #topFixPartLayout + #labelImage: #(#ResourceRetriever nil #setTopFixPartIcon) + ) + #(#MenuItem + #label: 'setHorizontalFixPartFrame' + #translateLabel: true + #isButton: true + #nameKey: #setHorizontalFixPartFrame + #value: #setHorizontalFixPartFrame + #activeHelpKey: #horizontalFixPartLayout + #labelImage: #(#ResourceRetriever nil #setHorizontalFixPartIcon) + ) + #(#MenuItem + #label: 'setBottomFixPartFrame' + #translateLabel: true + #isButton: true + #nameKey: #setBottomFixPartFrame + #value: #setBottomFixPartFrame + #activeHelpKey: #bottomFixPartLayout + #labelImage: #(#ResourceRetriever nil #setBottomFixPartIcon) + ) + #(#MenuItem + #label: '' + ) + #(#MenuItem + #label: 'setLeftFixPartFrame' + #translateLabel: true + #isButton: true + #nameKey: #setLeftFixPartFrame + #value: #setLeftFixPartFrame + #activeHelpKey: #leftFixPartLayout + #labelImage: #(#ResourceRetriever nil #setLeftFixPartIcon) + ) + #(#MenuItem + #label: 'setVerticalFixPartFrame' + #translateLabel: true + #isButton: true + #nameKey: #setVerticalFixPartFrame + #value: #setVerticalFixPartFrame + #activeHelpKey: #verticalFixPartLayout + #labelImage: #(#ResourceRetriever nil #setVerticalFixPartIcon) + ) + #(#MenuItem + #label: 'setRightFixPartFrame' + #translateLabel: true + #isButton: true + #nameKey: #setRightFixPartFrame + #value: #setRightFixPartFrame + #activeHelpKey: #rightFixPartLayout + #labelImage: #(#ResourceRetriever nil #setRightFixPartIcon) + ) + ) nil + nil + ) +! ! + +!UILayoutTool::LayoutFrame methodsFor:'accessing'! + +fetch:aView spec:aSpec + |layout| + + layout := UIPainterView asLayoutFrameFromView:aView. + + (self aspectFor:#leftOffset) value:(layout leftOffset). + (self aspectFor:#leftFraction) value:(layout leftFraction). + (self aspectFor:#topOffset) value:(layout topOffset). + (self aspectFor:#topFraction) value:(layout topFraction). + (self aspectFor:#rightOffset) value:(layout rightOffset). + (self aspectFor:#bottomOffset) value:(layout bottomOffset). + (self aspectFor:#rightFraction) value:(layout rightFraction). + (self aspectFor:#bottomFraction) value:(layout bottomFraction). + +! + +layout + "returns current layout as layoutFrame + " + |layout| + + layout := Smalltalk::LayoutFrame new. + + layout leftOffset:((self aspectFor:#leftOffset) value) ? 0. + layout rightOffset:((self aspectFor:#rightOffset) value) ? 0. + layout topOffset:((self aspectFor:#topOffset) value) ? 0. + layout bottomOffset:((self aspectFor:#bottomOffset) value) ? 0. + layout leftFraction:((self aspectFor:#leftFraction) value) ? 0. + layout rightFraction:((self aspectFor:#rightFraction) value) ? 0. + layout topFraction:((self aspectFor:#topFraction) value) ? 0. + layout bottomFraction:((self aspectFor:#bottomFraction) value) ? 0. + + ^ layout + +! ! + +!UILayoutTool::LayoutFrame methodsFor:'common frames'! + +setBottomFixPartFrame + self + setFrameLeft:0 offset:0 + right:1 offset:0 + top:1 offset:-30 + bottom:1 offset:0 +! + +setBottomHalfFrame + self + setFrameLeft:0 offset:0 + right:1 offset:0 + top:0.5 offset:0 + bottom:1 offset:0 +! + +setBottomLeftQuarterFrame + self + setFrameLeft:0 offset:0 + right:0.5 offset:0 + top:0.5 offset:0 + bottom:1 offset:0 +! + +setBottomRightQuarterFrame + self + setFrameLeft:0.5 offset:0 + right:1 offset:0 + top:0.5 offset:0 + bottom:1 offset:0 +! + +setFrameLeft:lF offset:lO right:rF offset:rO top:tF offset:tO bottom:bF offset:bO + (self aspectFor:#leftOffset) value:lO. + (self aspectFor:#rightOffset) value:rO. + (self aspectFor:#topOffset) value:tO. + (self aspectFor:#bottomOffset) value:bO. + + (self aspectFor:#leftFraction) value:lF. + (self aspectFor:#rightFraction) value:rF. + (self aspectFor:#topFraction) value:tF. + (self aspectFor:#bottomFraction) value:bF. +! + +setHorizontalFixPartFrame + self + setFrameLeft:0 offset:0 + right:1 offset:0 + top:0.5 offset:-15 + bottom:0.5 offset:15 +! + +setLeftFixPartFrame + self + setFrameLeft:0 offset:0 + right:0 offset:30 + top:0 offset:0 + bottom:1 offset:0 +! + +setLeftHalfFrame + self + setFrameLeft:0 offset:0 + right:0.5 offset:0 + top:0 offset:0 + bottom:1 offset:0 +! + +setRightFixPartFrame + self + setFrameLeft:1 offset:0 + right:1 offset:-30 + top:0 offset:0 + bottom:1 offset:0 +! + +setRightHalfFrame + self + setFrameLeft:0.5 offset:0 + right:1 offset:0 + top:0 offset:0 + bottom:1 offset:0 +! + +setTopFixPartFrame + self + setFrameLeft:0 offset:0 + right:1 offset:0 + top:0 offset:0 + bottom:0 offset:30 +! + +setTopHalfFrame + self + setFrameLeft:0 offset:0 + right:1 offset:0 + top:0 offset:0 + bottom:0.5 offset:0 +! + +setTopLeftQuarterFrame + self + setFrameLeft:0 offset:0 + right:0.5 offset:0 + top:0 offset:0 + bottom:0.5 offset:0 +! + +setTopRightQuarterFrame + self + setFrameLeft:0.5 offset:0 + right:1 offset:0 + top:0 offset:0 + bottom:0.5 offset:0 +! + +setVerticalFixPartFrame + self + setFrameLeft:0.5 offset:-15 + right:0.5 offset:15 + top:0 offset:0 + bottom:1 offset:0 +! ! + !UILayoutTool::AlignmentOrigin class methodsFor:'help specs'! helpSpec @@ -1452,780 +2313,6 @@ ! ! -!UILayoutTool::LayoutOrigin class methodsFor:'interface specs'! - -windowSpec - "This resource specification was automatically generated - by the UIPainter of ST/X." - - "Do not manually edit this!! If it is corrupted, - the UIPainter may not be able to read the specification." - - " - UIPainter new openOnClass:UILayoutTool::LayoutOrigin andSelector:#windowSpec - UILayoutTool::LayoutOrigin new openInterface:#windowSpec - UILayoutTool::LayoutOrigin open - " - - - - ^ - - #(#FullSpec - #window: - #(#WindowSpec - #name: 'UILayoutTool-LayoutOrigin' - #layout: #(#LayoutFrame 290 0 420 0 647 0 565 0) - #label: 'UILayoutTool-LayoutOrigin' - #min: #(#Point 10 10) - #max: #(#Point 1152 900) - #bounds: #(#Rectangle 290 420 648 566) - #usePreferredExtent: false - ) - #component: - #(#SpecCollection - #collection: - #( - #(#UISubSpecification - #name: 'layoutOriginSpec' - #layout: #(#LayoutFrame 1 0.0 6 0 0 1.0 110 0) - #majorKey: #UILayoutTool - #minorKey: #layoutOriginSpec - ) - ) - ) - ) -! ! - -!UILayoutTool::LayoutOrigin methodsFor:'accessing'! - -fetch:aView spec:aSpec - "fetch layoutOrigin - " - |layout| - - layout := UIPainterView asLayoutFrameFromView:aView. - - (self aspectFor:#leftOffset) value:(layout leftOffset). - (self aspectFor:#leftFraction) value:(layout leftFraction). - (self aspectFor:#topOffset) value:(layout topOffset). - (self aspectFor:#topFraction) value:(layout topFraction). - - -! - -layout - "returns current layout as layoutOrigin - " - |layout| - - layout := Smalltalk::LayoutOrigin new. - - layout leftOffset:((self aspectFor:#leftOffset) value) ? 0. - layout topOffset:((self aspectFor:#topOffset) value) ? 0. - layout leftFraction:((self aspectFor:#leftFraction) value) ? 0. - layout topFraction:((self aspectFor:#topFraction) value) ? 0. - - ^ layout - -! ! - -!UILayoutTool::LayoutFrame class methodsFor:'help specs'! - -helpSpec - "This resource specification was automatically generated - by the UIHelpTool of ST/X." - - "Do not manually edit this!! If it is corrupted, - the UIHelpTool may not be able to read the specification." - - " - UIHelpTool openOnClass:UILayoutTool::LayoutFrame - " - - - - ^super helpSpec addPairsFrom:#( - -#bottomAbsolute -'Offset of the bottom edge; positive is to the bottom, negative to the top.' - -#bottomFixPartLayout -'Set the layout for a fixed area at the bottom of the widgets containers space' - -#bottomHalfLayout -'Set the layout for the bottom half of the widgets containers space' - -#bottomLeftQuarterLayout -'Set the layout for the bottom-left quarter of the widgets containers space' - -#bottomRelative -'Relative corner y of the selected widget.' - -#bottomRightQuarterLayout -'Set the layout for the bottom-right quarter of the widgets containers space' - -#leftHalfLayout -'Set the layout for the left half of the widgets containers space' - -#makeBottomAbsolute -'Compute pure-absolute y.' - -#makeBottomRelative -'Computes pure-fractional y.' - -#makeBottomRelativeFromBottom -'Compute fraction+offset for y relative to containers bottom.' - -#makeRightAbsolute -'Compute pure-absolute x.' - -#makeRightRelative -'Compute pure-fraction x.' - -#makeRightRelativeFromRight -'Compute fraction+offset for x relative to containers right.' - -#rightAbsolute -'Offset of the right edge; positive is to the right, negative to the left.' - -#rightHalfLayout -'Set the layout for the right half of the widgets containers space' - -#rightRelative -'Relative corner x of the selected widget.' - -#topFixPartLayout -'Set the layout for a fixed area at the top of the widgets containers space' - -#topHalfLayout -'Set the layout for the top half of the widgets containers space' - -#topLeftQuarterLayout -'Set the layout for the top-left quarter of the widgets containers space' - -#topRightQuarterLayout -'Set the layout for the top-right quarter of the widgets containers space' - -) -! ! - -!UILayoutTool::LayoutFrame class methodsFor:'image specs'! - -setBottomFixPartIcon - "This resource specification was automatically generated - by the ImageEditor of ST/X." - - "Do not manually edit this!! If it is corrupted, - the ImageEditor may not be able to read the specification." - - " - self setBottomFixPartIcon inspect - ImageEditor openOnClass:self andSelector:#setBottomFixPartIcon - " - - - - ^Icon - constantNamed:#'UILayoutTool::LayoutFrame setBottomFixPartIcon' - ifAbsentPut:[(Depth4Image new) width: 16; height: 16; photometric:(#palette); bitsPerSample:(#(4 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@H"H"@BH"H @!!DQD@DQDR@BDQDP@QDQH@H"H"@BH"H @@@@@@@@@@@b') ; colorMapFromArray:#[0 0 0 255 0 0 255 255 255]; mask:((Depth1Image new) width: 16; height: 16; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'??>@@X@A @F@@X@A @F@@X@A @G??????????????? - - ^Icon - constantNamed:#'UILayoutTool::LayoutFrame setBottomHalfIcon' - ifAbsentPut:[(Depth4Image new) width: 16; height: 16; photometric:(#palette); bitsPerSample:(#(4 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@"H"H"H"H"@BDQDQDQDQH@HQDQDQDQD @!!DQDQDQDR@BDQDQDQDQH@H"H"H"H"H @@@@@@@@@@@b') ; colorMapFromArray:#[0 0 0 255 0 0 255 255 255]; mask:((Depth1Image new) width: 16; height: 16; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'??>@@X@A @F@@X@A @F@@_???????????????????? - - ^Icon - constantNamed:#'UILayoutTool::LayoutFrame setBottomLeftQuarterIcon' - ifAbsentPut:[(Depth4Image new) width: 16; height: 16; photometric:(#palette); bitsPerSample:(#(4 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@H"H"@@@@@@@!!DQH@@@@@@BDQD @@@@@@HQDR@@@@@@@!!DQH@@@@@@BDQD @@@@@@H"H"@@@@@@@@@@@@@@@@@b') ; colorMapFromArray:#[0 0 0 255 0 0 255 255 255]; mask:((Depth1Image new) width: 16; height: 16; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'??>@@X@A @F@@X@A @G?@_ - - ^Icon - constantNamed:#'UILayoutTool::LayoutFrame setBottomRightQuarterIcon' - ifAbsentPut:[(Depth4Image new) width: 16; height: 16; photometric:(#palette); bitsPerSample:(#(4 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@BH"H"@@@@@@HQDQH@@@@@@!!DQD @@@@@BDQDR@@@@@@HQDQH@@@@@@"H"H @@@@@@@@@@@b') ; colorMapFromArray:#[0 0 0 255 0 0 255 255 255]; mask:((Depth1Image new) width: 16; height: 16; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'??>@@X@A @F@@X@A @F@@XG? _>A?8G? _>A?8G??? - - ^Icon - constantNamed:#'UILayoutTool::LayoutFrame setLeftHalfIcon' - ifAbsentPut:[(Depth4Image new) width: 16; height: 16; photometric:(#palette); bitsPerSample:(#(4 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@@@@@@@@BH"H @@@@@@HQDR@@@@@@@!!DQH@@@@@@BDQD @@@@@@HQDR@@@@@@@!!DQH@@@@@@BDQD @@@@@@HQDR@@@@@@@!!DQH@@@@@@BDQD @@@@@@HQDR@@@@@@@!!DQH@@@@@@BDQD @@@@@@H"H"@@@@@@@@@@@@@@@@@b') ; colorMapFromArray:#[0 0 0 255 0 0 255 255 255]; mask:((Depth1Image new) width: 16; height: 16; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'????@_ - - ^Icon - constantNamed:#'UILayoutTool::LayoutFrame setRightHalfIcon' - ifAbsentPut:[(Depth4Image new) width: 16; height: 16; photometric:(#palette); bitsPerSample:(#(4 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@@@@@@@@@@@@@@"H"H@@@@@@BDQD @@@@@@HQDR@@@@@@@!!DQH@@@@@@BDQD @@@@@@HQDR@@@@@@@!!DQH@@@@@@BDQD @@@@@@HQDR@@@@@@@!!DQH@@@@@@BDQD @@@@@@HQDR@@@@@@@!!DQH@@@@@@BH"H @@@@@@@@@@@b') ; colorMapFromArray:#[0 0 0 255 0 0 255 255 255]; mask:((Depth1Image new) width: 16; height: 16; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'??>@?8C? O>@?8C? O>@?8C? O>@?8C? O>@?8C??? - - ^Icon - constantNamed:#'UILayoutTool::LayoutFrame setToRightQuarterIcon' - ifAbsentPut:[(Depth4Image new) width: 16; height: 16; photometric:(#palette); bitsPerSample:(#(4 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@@@@@@@@@@@@@@"H"H@@@@@@BDQD @@@@@@HQDR@@@@@@@!!DQH@@@@@@BDQD @@@@@@HQDR@@@@@@@"H"H@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@b') ; colorMapFromArray:#[0 0 0 255 0 0 255 255 255]; mask:((Depth1Image new) width: 16; height: 16; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'??>@?8C? O>@?8C? O>@?8C? @F@@X@A @F@@X@A?? - - ^Icon - constantNamed:#'UILayoutTool::LayoutFrame setTopFixPartIcon' - ifAbsentPut:[(Depth4Image new) width: 16; height: 16; photometric:(#palette); bitsPerSample:(#(4 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@@@@@@@@BH"H @"H"H@HQDQ@ADQD @!!DQD@DQDR@BH"H @"H"H@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@b') ; colorMapFromArray:#[0 0 0 255 0 0 255 255 255]; mask:((Depth1Image new) width: 16; height: 16; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'???????????????? @F@@X@A @F@@X@A @F@@X@A?? - - ^Icon - constantNamed:#'UILayoutTool::LayoutFrame setTopHalfIcon' - ifAbsentPut:[(Depth4Image new) width: 16; height: 16; photometric:(#palette); bitsPerSample:(#(4 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@@@@@@@@BH"H"H"H"H@HQDQDQDQD @!!DQDQDQDR@BDQDQDQDQH@HQDQDQDQD @"H"H"H"H"@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@b') ; colorMapFromArray:#[0 0 0 255 0 0 255 255 255]; mask:((Depth1Image new) width: 16; height: 16; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'?????????????????????8@A @F@@X@A @F@@X@A?? - - ^Icon - constantNamed:#'UILayoutTool::LayoutFrame setTopLeftQuarterIcon' - ifAbsentPut:[(Depth4Image new) width: 16; height: 16; photometric:(#palette); bitsPerSample:(#(4 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@@@@@@@@BH"H"@@@@@@HQDQH@@@@@@!!DQD @@@@@BDQDR@@@@@@HQDQH@@@@@@"H"H @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@b') ; colorMapFromArray:#[0 0 0 255 0 0 255 255 255]; mask:((Depth1Image new) width: 16; height: 16; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'???? _>A?8G? _>A?8G? X@A @F@@X@A @F@@X@A?? - - ^ - #(#FullSpec - #name: #windowSpec - #window: - #(#WindowSpec - #label: 'UILayoutTool-LayoutFrame' - #name: 'UILayoutTool-LayoutFrame' - #min: #(#Point 10 10) - #max: #(#Point 1152 900) - #bounds: #(#Rectangle 12 22 411 325) - #forceRecursiveBackground: false - ) - #component: - #(#SpecCollection - #collection: #( - #(#UISubSpecification - #name: 'layoutOriginSpec' - #layout: #(#LayoutFrame 1 0.0 6 0 0 1.0 110 0) - #majorKey: #UILayoutTool - #minorKey: #layoutOriginSpec - ) - #(#FramedBoxSpec - #label: 'Corner' - #name: 'FramedBox' - #layout: #(#LayoutFrame 1 0.0 113 0 0 1.0 214 0) - #labelPosition: #topLeft - #component: - #(#SpecCollection - #collection: #( - #(#LabelSpec - #label: 'Right:' - #name: 'labelRight' - #layout: #(#AlignmentOrigin 68 0 25 0 1 0.5) - ) - #(#ActionButtonSpec - #label: 'imageFractX' - #name: 'actionRelativeRight' - #layout: #(#LayoutFrame 78 0 14 0 100 0 36 0) - #activeHelpKey: #makeRightRelative - #hasCharacterOrientedLabel: false - #tabable: true - #model: #relativeRight - ) - #(#InputFieldSpec - #name: 'fieldRightFraction' - #layout: #(#LayoutFrame 103 0 14 0 153 0 36 0) - #activeHelpKey: #rightRelative - #tabable: true - #model: #rightFraction - #group: #inputGroup - #type: #numberOrNil - #acceptOnLostFocus: true - #acceptChannel: #acceptChannel - #modifiedChannel: #modifiedChannel - #acceptOnPointerLeave: false - ) - #(#ActionButtonSpec - #label: 'imageAbsXFromRight' - #name: 'actionRightRelativeRight' - #layout: #(#LayoutFrame 257 0 14 0 279 0 36 0) - #activeHelpKey: #makeRightRelativeFromRight - #hasCharacterOrientedLabel: false - #tabable: true - #model: #rightRelativeRight - ) - #(#InputFieldSpec - #name: 'fieldRightOffset' - #layout: #(#LayoutFrame 203 0 14 0 253 0 36 0) - #activeHelpKey: #rightAbsolute - #tabable: true - #model: #rightOffset - #group: #inputGroup - #type: #numberOrNil - #acceptOnLostFocus: true - #acceptChannel: #acceptChannel - #modifiedChannel: #modifiedChannel - #acceptOnPointerLeave: false - ) - #(#ActionButtonSpec - #label: 'imageAbsX' - #name: 'actionAbsoluteRight' - #layout: #(#LayoutFrame 178 0 14 0 200 0 36 0) - #activeHelpKey: #makeRightAbsolute - #hasCharacterOrientedLabel: false - #tabable: true - #model: #absoluteRight - ) - #(#LabelSpec - #label: 'Bottom:' - #name: 'labelBottom' - #layout: #(#AlignmentOrigin 68 0 53 0 1 0.5) - ) - #(#ActionButtonSpec - #label: 'imageFractY' - #name: 'actionRelativeBottom' - #layout: #(#LayoutFrame 78 0 42 0 100 0 64 0) - #activeHelpKey: #makeBottomRelative - #hasCharacterOrientedLabel: false - #tabable: true - #model: #relativeBottom - ) - #(#InputFieldSpec - #name: 'fieldBottomFraction' - #layout: #(#LayoutFrame 103 0 42 0 153 0 64 0) - #activeHelpKey: #bottomRelative - #tabable: true - #model: #bottomFraction - #group: #inputGroup - #type: #numberOrNil - #acceptOnLostFocus: true - #acceptChannel: #acceptChannel - #modifiedChannel: #modifiedChannel - #acceptOnPointerLeave: false - ) - #(#ActionButtonSpec - #label: 'imageAbsYFromBottom' - #name: 'actionBottomRelativeBottom' - #layout: #(#LayoutFrame 257 0 42 0 279 0 64 0) - #activeHelpKey: #makeBottomRelativeFromBottom - #hasCharacterOrientedLabel: false - #tabable: true - #model: #bottomRelativeBottom - ) - #(#InputFieldSpec - #name: 'fieldBottomOffset' - #layout: #(#LayoutFrame 203 0 42 0 253 0 64 0) - #activeHelpKey: #bottomAbsolute - #tabable: true - #model: #bottomOffset - #group: #inputGroup - #type: #numberOrNil - #acceptOnLostFocus: true - #acceptChannel: #acceptChannel - #modifiedChannel: #modifiedChannel - #acceptOnPointerLeave: false - ) - #(#ActionButtonSpec - #label: 'imageAbsY' - #name: 'actionAbsoluteBottom' - #layout: #(#LayoutFrame 178 0 42 0 200 0 64 0) - #activeHelpKey: #makeBottomAbsolute - #hasCharacterOrientedLabel: false - #tabable: true - #model: #absoluteBottom - ) - ) - - ) - ) - #(#MenuPanelSpec - #name: 'commonLayoutToolBar' - #layout: #(#LayoutFrame 6 0.0 231 0 -4 1.0 263 0) - #level: 0 - #tabable: true - #menu: #commonFrameLayoutsMenu - #textDefault: true - ) - ) - - ) - ) -! ! - -!UILayoutTool::LayoutFrame class methodsFor:'menu specs'! - -commonFrameLayoutsMenu - "This resource specification was automatically generated - by the MenuEditor of ST/X." - - "Do not manually edit this!! If it is corrupted, - the MenuEditor may not be able to read the specification." - - " - MenuEditor new openOnClass:UILayoutTool::LayoutFrame andSelector:#commonFrameLayoutsMenu - (Menu new fromLiteralArrayEncoding:(UILayoutTool::LayoutFrame commonFrameLayoutsMenu)) startUp - " - - - - ^ - - #(#Menu - - #( - #(#MenuItem - #label: 'setTopHalfFrame' - #translateLabel: true - #isButton: true - #nameKey: #setTopHalfFrame - #value: #setTopHalfFrame - #activeHelpKey: #topHalfLayout - #labelImage: #(#ResourceRetriever #'UILayoutTool::LayoutFrame' #setTopHalfIcon) - ) - #(#MenuItem - #label: 'setBottomHalfFrame' - #translateLabel: true - #isButton: true - #nameKey: #setBottomHalfFrame - #value: #setBottomHalfFrame - #activeHelpKey: #bottomHalfLayout - #labelImage: #(#ResourceRetriever nil #setBottomHalfIcon) - ) - #(#MenuItem - #label: 'setLeftHalfFrame' - #translateLabel: true - #isButton: true - #nameKey: #setLeftHalfFrame - #value: #setLeftHalfFrame - #activeHelpKey: #leftHalfLayout - #labelImage: #(#ResourceRetriever nil #setLeftHalfIcon) - ) - #(#MenuItem - #label: 'setRightHalfFrame' - #translateLabel: true - #isButton: true - #nameKey: #setRightHalfFrame - #value: #setRightHalfFrame - #activeHelpKey: #rightHalfLayout - #labelImage: #(#ResourceRetriever nil #setRightHalfIcon) - ) - #(#MenuItem - #label: '' - ) - #(#MenuItem - #label: 'setTopLeftQuarterFrame' - #translateLabel: true - #isButton: true - #activeHelpKey: #topLeftQuarterLayout - #nameKey: #setTopLeftQuarterFrame - #value: #setTopLeftQuarterFrame - #labelImage: #(#ResourceRetriever nil #setTopLeftQuarterIcon) - ) - #(#MenuItem - #label: 'setTopRightQuarterFrame' - #translateLabel: true - #isButton: true - #activeHelpKey: #topRightQuarterLayout - #nameKey: #setTopRightQuarterFrame - #value: #setTopRightQuarterFrame - #labelImage: #(#ResourceRetriever nil #setToRightQuarterIcon) - ) - #(#MenuItem - #label: 'setBottomRightQuarterFrame' - #translateLabel: true - #isButton: true - #activeHelpKey: #bottomRightQuarterLayout - #nameKey: #setBottomRightQuarterFrame - #value: #setBottomRightQuarterFrame - #labelImage: #(#ResourceRetriever nil #setBottomRightQuarterIcon) - ) - #(#MenuItem - #label: 'setBottomLeftQuarterFrame' - #translateLabel: true - #activeHelpKey: #bottomLeftQuarterLayout - #isButton: true - #nameKey: #setBottomLeftQuarterFrame - #value: #setBottomLeftQuarterFrame - #labelImage: #(#ResourceRetriever nil #setBottomLeftQuarterIcon) - ) - #(#MenuItem - #label: '' - ) - #(#MenuItem - #label: 'setTopFixPartFrame' - #translateLabel: true - #isButton: true - #nameKey: #setTopFixPartFrame - #value: #setTopFixPartFrame - #activeHelpKey: #topFixPartLayout - #labelImage: #(#ResourceRetriever nil #setTopFixPartIcon) - ) - #(#MenuItem - #label: 'setBottomFixPartFrame' - #translateLabel: true - #isButton: true - #nameKey: #setBottomFixPartFrame - #value: #setBottomFixPartFrame - #activeHelpKey: #bottomFixPartLayout - #labelImage: #(#ResourceRetriever nil #setBottomFixPartIcon) - ) - ) nil - nil - ) -! ! - -!UILayoutTool::LayoutFrame methodsFor:'accessing'! - -fetch:aView spec:aSpec - |layout| - - layout := UIPainterView asLayoutFrameFromView:aView. - - (self aspectFor:#leftOffset) value:(layout leftOffset). - (self aspectFor:#leftFraction) value:(layout leftFraction). - (self aspectFor:#topOffset) value:(layout topOffset). - (self aspectFor:#topFraction) value:(layout topFraction). - (self aspectFor:#rightOffset) value:(layout rightOffset). - (self aspectFor:#bottomOffset) value:(layout bottomOffset). - (self aspectFor:#rightFraction) value:(layout rightFraction). - (self aspectFor:#bottomFraction) value:(layout bottomFraction). - -! - -layout - "returns current layout as layoutFrame - " - |layout| - - layout := Smalltalk::LayoutFrame new. - - layout leftOffset:((self aspectFor:#leftOffset) value) ? 0. - layout rightOffset:((self aspectFor:#rightOffset) value) ? 0. - layout topOffset:((self aspectFor:#topOffset) value) ? 0. - layout bottomOffset:((self aspectFor:#bottomOffset) value) ? 0. - layout leftFraction:((self aspectFor:#leftFraction) value) ? 0. - layout rightFraction:((self aspectFor:#rightFraction) value) ? 0. - layout topFraction:((self aspectFor:#topFraction) value) ? 0. - layout bottomFraction:((self aspectFor:#bottomFraction) value) ? 0. - - ^ layout - -! ! - -!UILayoutTool::LayoutFrame methodsFor:'common frames'! - -setBottomFixPartFrame - self - setFrameLeft:0 offset:0 - right:1 offset:0 - top:1 offset:-30 - bottom:1 offset:0 -! - -setBottomHalfFrame - self - setFrameLeft:0 offset:0 - right:1 offset:0 - top:0.5 offset:0 - bottom:1 offset:0 -! - -setBottomLeftQuarterFrame - self - setFrameLeft:0 offset:0 - right:0.5 offset:0 - top:0.5 offset:0 - bottom:1 offset:0 -! - -setBottomRightQuarterFrame - self - setFrameLeft:0.5 offset:0 - right:1 offset:0 - top:0.5 offset:0 - bottom:1 offset:0 -! - -setFrameLeft:lF offset:lO right:rF offset:rO top:tF offset:tO bottom:bF offset:bO - (self aspectFor:#leftOffset) value:lO. - (self aspectFor:#rightOffset) value:rO. - (self aspectFor:#topOffset) value:tO. - (self aspectFor:#bottomOffset) value:bO. - - (self aspectFor:#leftFraction) value:lF. - (self aspectFor:#rightFraction) value:rF. - (self aspectFor:#topFraction) value:tF. - (self aspectFor:#bottomFraction) value:bF. -! - -setLeftHalfFrame - self - setFrameLeft:0 offset:0 - right:0.5 offset:0 - top:0 offset:0 - bottom:1 offset:0 -! - -setRightHalfFrame - self - setFrameLeft:0.5 offset:0 - right:1 offset:0 - top:0 offset:0 - bottom:1 offset:0 -! - -setTopFixPartFrame - self - setFrameLeft:0 offset:0 - right:1 offset:0 - top:0 offset:0 - bottom:0 offset:30 -! - -setTopHalfFrame - self - setFrameLeft:0 offset:0 - right:1 offset:0 - top:0 offset:0 - bottom:0.5 offset:0 -! - -setTopLeftQuarterFrame - self - setFrameLeft:0 offset:0 - right:0.5 offset:0 - top:0 offset:0 - bottom:0.5 offset:0 -! - -setTopRightQuarterFrame - self - setFrameLeft:0.5 offset:0 - right:1 offset:0 - top:0 offset:0 - bottom:0.5 offset:0 -! ! - !UILayoutTool::Point class methodsFor:'interface specs'! windowSpec @@ -2294,130 +2381,6 @@ ! ! -!UILayoutTool::Rectangle class methodsFor:'interface specs'! - -windowSpec - "This resource specification was automatically generated - by the UIPainter of ST/X." - - "Do not manually edit this!! If it is corrupted, - the UIPainter may not be able to read the specification." - - " - UIPainter new openOnClass:UILayoutTool::Rectangle andSelector:#windowSpec - UILayoutTool::Rectangle new openInterface:#windowSpec - UILayoutTool::Rectangle open - " - - - - ^ - - #(#FullSpec - #window: - #(#WindowSpec - #name: 'UILayoutTool-Rectangle' - #layout: #(#LayoutFrame 291 0 130 0 632 0 328 0) - #label: 'UILayoutTool-Rectangle' - #min: #(#Point 10 10) - #max: #(#Point 1152 900) - #bounds: #(#Rectangle 291 130 633 329) - #usePreferredExtent: false - ) - #component: - #(#SpecCollection - #collection: - #( - #(#UISubSpecification - #name: 'subSpecification' - #layout: #(#LayoutFrame 1 0.0 6 0 0 1.0 96 0) - #majorKey: #UILayoutTool - #minorKey: #layoutPointSpec - ) - #(#FramedBoxSpec - #name: 'FramedBox' - #layout: #(#LayoutFrame 1 0.0 99 0 0 1.0 194 0) - #component: - #(#SpecCollection - #collection: - #( - #(#LabelSpec - #name: 'labelCornerY' - #layout: #(#AlignmentOrigin 83 0 16 0 1 0) - #label: 'Right:' - #adjust: #left - ) - #(#InputFieldSpec - #name: 'fieldCornerX' - #layout: #(#LayoutFrame 85 0 13 0 135 0 35 0) - #activeHelpKey: #cornerX - #tabable: true - #model: #rightOffset - #group: #inputGroup - #type: #numberOrNil - #acceptOnLostFocus: true - #acceptChannel: #acceptChannel - #modifiedChannel: #modifiedChannel - ) - #(#LabelSpec - #name: 'labelCornerX' - #layout: #(#AlignmentOrigin 83 0 41 0 1 0) - #label: 'Bottom:' - #adjust: #left - ) - #(#InputFieldSpec - #name: 'fieldCornerY' - #layout: #(#LayoutFrame 85 0 38 0 135 0 60 0) - #activeHelpKey: #cornerY - #tabable: true - #model: #bottomOffset - #group: #inputGroup - #type: #numberOrNil - #acceptOnLostFocus: true - #acceptChannel: #acceptChannel - #modifiedChannel: #modifiedChannel - ) - ) - ) - #label: 'Corner' - #labelPosition: #topLeft - ) - ) - ) - ) - - "Modified: / 13.8.1998 / 19:59:16 / cg" -! ! - -!UILayoutTool::Rectangle methodsFor:'accessing'! - -fetch:aView spec:aSpec - "fetch rectangle - " - |origin corner| - - origin := aView computeOrigin. - corner := aView computeCorner. - - (self aspectFor:#leftOffset) value:(origin x). - (self aspectFor:#rightOffset) value:(corner x). - (self aspectFor:#topOffset) value:(origin y). - (self aspectFor:#bottomOffset) value:(corner y). - - -! - -layout - "returns current layout as rectangle - " - ^ Smalltalk::Rectangle left:(((self aspectFor:#leftOffset) value) ? 0) - top:(((self aspectFor:#topOffset) value) ? 0) - right:(((self aspectFor:#rightOffset) value) ? 0) - bottom:(((self aspectFor:#bottomOffset) value) ? 0) - - -! ! - !UILayoutTool::Extent class methodsFor:'help specs'! helpSpec @@ -2577,6 +2540,208 @@ ! ! +!UILayoutTool::Rectangle class methodsFor:'interface specs'! + +windowSpec + "This resource specification was automatically generated + by the UIPainter of ST/X." + + "Do not manually edit this!! If it is corrupted, + the UIPainter may not be able to read the specification." + + " + UIPainter new openOnClass:UILayoutTool::Rectangle andSelector:#windowSpec + UILayoutTool::Rectangle new openInterface:#windowSpec + UILayoutTool::Rectangle open + " + + + + ^ + + #(#FullSpec + #window: + #(#WindowSpec + #name: 'UILayoutTool-Rectangle' + #layout: #(#LayoutFrame 291 0 130 0 632 0 328 0) + #label: 'UILayoutTool-Rectangle' + #min: #(#Point 10 10) + #max: #(#Point 1152 900) + #bounds: #(#Rectangle 291 130 633 329) + #usePreferredExtent: false + ) + #component: + #(#SpecCollection + #collection: + #( + #(#UISubSpecification + #name: 'subSpecification' + #layout: #(#LayoutFrame 1 0.0 6 0 0 1.0 96 0) + #majorKey: #UILayoutTool + #minorKey: #layoutPointSpec + ) + #(#FramedBoxSpec + #name: 'FramedBox' + #layout: #(#LayoutFrame 1 0.0 99 0 0 1.0 194 0) + #component: + #(#SpecCollection + #collection: + #( + #(#LabelSpec + #name: 'labelCornerY' + #layout: #(#AlignmentOrigin 83 0 16 0 1 0) + #label: 'Right:' + #adjust: #left + ) + #(#InputFieldSpec + #name: 'fieldCornerX' + #layout: #(#LayoutFrame 85 0 13 0 135 0 35 0) + #activeHelpKey: #cornerX + #tabable: true + #model: #rightOffset + #group: #inputGroup + #type: #numberOrNil + #acceptOnLostFocus: true + #acceptChannel: #acceptChannel + #modifiedChannel: #modifiedChannel + ) + #(#LabelSpec + #name: 'labelCornerX' + #layout: #(#AlignmentOrigin 83 0 41 0 1 0) + #label: 'Bottom:' + #adjust: #left + ) + #(#InputFieldSpec + #name: 'fieldCornerY' + #layout: #(#LayoutFrame 85 0 38 0 135 0 60 0) + #activeHelpKey: #cornerY + #tabable: true + #model: #bottomOffset + #group: #inputGroup + #type: #numberOrNil + #acceptOnLostFocus: true + #acceptChannel: #acceptChannel + #modifiedChannel: #modifiedChannel + ) + ) + ) + #label: 'Corner' + #labelPosition: #topLeft + ) + ) + ) + ) + + "Modified: / 13.8.1998 / 19:59:16 / cg" +! ! + +!UILayoutTool::Rectangle methodsFor:'accessing'! + +fetch:aView spec:aSpec + "fetch rectangle + " + |origin corner| + + origin := aView computeOrigin. + corner := aView computeCorner. + + (self aspectFor:#leftOffset) value:(origin x). + (self aspectFor:#rightOffset) value:(corner x). + (self aspectFor:#topOffset) value:(origin y). + (self aspectFor:#bottomOffset) value:(corner y). + + +! + +layout + "returns current layout as rectangle + " + ^ Smalltalk::Rectangle left:(((self aspectFor:#leftOffset) value) ? 0) + top:(((self aspectFor:#topOffset) value) ? 0) + right:(((self aspectFor:#rightOffset) value) ? 0) + bottom:(((self aspectFor:#bottomOffset) value) ? 0) + + +! ! + +!UILayoutTool::LayoutOrigin class methodsFor:'interface specs'! + +windowSpec + "This resource specification was automatically generated + by the UIPainter of ST/X." + + "Do not manually edit this!! If it is corrupted, + the UIPainter may not be able to read the specification." + + " + UIPainter new openOnClass:UILayoutTool::LayoutOrigin andSelector:#windowSpec + UILayoutTool::LayoutOrigin new openInterface:#windowSpec + UILayoutTool::LayoutOrigin open + " + + + + ^ + + #(#FullSpec + #window: + #(#WindowSpec + #name: 'UILayoutTool-LayoutOrigin' + #layout: #(#LayoutFrame 290 0 420 0 647 0 565 0) + #label: 'UILayoutTool-LayoutOrigin' + #min: #(#Point 10 10) + #max: #(#Point 1152 900) + #bounds: #(#Rectangle 290 420 648 566) + #usePreferredExtent: false + ) + #component: + #(#SpecCollection + #collection: + #( + #(#UISubSpecification + #name: 'layoutOriginSpec' + #layout: #(#LayoutFrame 1 0.0 6 0 0 1.0 110 0) + #majorKey: #UILayoutTool + #minorKey: #layoutOriginSpec + ) + ) + ) + ) +! ! + +!UILayoutTool::LayoutOrigin methodsFor:'accessing'! + +fetch:aView spec:aSpec + "fetch layoutOrigin + " + |layout| + + layout := UIPainterView asLayoutFrameFromView:aView. + + (self aspectFor:#leftOffset) value:(layout leftOffset). + (self aspectFor:#leftFraction) value:(layout leftFraction). + (self aspectFor:#topOffset) value:(layout topOffset). + (self aspectFor:#topFraction) value:(layout topFraction). + + +! + +layout + "returns current layout as layoutOrigin + " + |layout| + + layout := Smalltalk::LayoutOrigin new. + + layout leftOffset:((self aspectFor:#leftOffset) value) ? 0. + layout topOffset:((self aspectFor:#topOffset) value) ? 0. + layout leftFraction:((self aspectFor:#leftFraction) value) ? 0. + layout topFraction:((self aspectFor:#topFraction) value) ? 0. + + ^ layout + +! ! + !UILayoutTool class methodsFor:'documentation'! version