--- a/AbstractSettingsApplication.st Mon Oct 28 18:29:18 2013 +0100
+++ b/AbstractSettingsApplication.st Wed Oct 30 09:48:38 2013 +0100
@@ -88,7 +88,8 @@
clipEncodingList ditherListSelection deepIcons monitorSelection
useFixPaletteLabel visualIsPseudoColor ditherSymsNotNil
useFixGrayPalette sizeInfos screen ditherStyles ditherSyms
- screenDepthVisualLabelHolder maxCopyBufferSize'
+ screenDepthVisualLabelHolder maxCopyBufferSize usedWidth
+ usedHeight'
classVariableNames:''
poolDictionaries:''
privateIn:AbstractSettingsApplication
@@ -3097,193 +3098,241 @@
<resource: #canvas>
^
- #(FullSpec
- name: windowSpec
- window:
- (WindowSpec
- label: 'Display Screen Settings'
- name: 'Display Screen Settings'
- min: (Point 10 10)
- bounds: (Rectangle 0 0 600 378)
- )
- component:
- (SpecCollection
- collection: (
- (LabelSpec
- label: 'Actual Visible Screen Area:'
- name: 'ActualVisibleScreenAreaLabel'
- layout: (LayoutFrame 0 0.0 0 0.0 0 1.0 22 0)
- translateLabel: true
- adjust: left
- )
- (LabelSpec
- label: 'Common Sizes:'
- name: 'CommonSizesLabel'
- layout: (LayoutFrame 0 0 39 0 163 0 61 0)
- translateLabel: true
- adjust: right
- )
- (PopUpListSpec
- label: 'monitor size'
- name: 'MonitorSelectionPopUpList'
- layout: (LayoutFrame 170 0 39 0 -5 1 61 0)
- tabable: true
- model: monitorSelection
- menu: monitorList
- useIndex: true
- )
- (LabelSpec
- label: 'Screen Size:'
- name: 'ScreenSizeLabel'
- layout: (LayoutFrame 0 0 72 0 163 0 94 0)
- translateLabel: true
- adjust: right
- )
- (InputFieldSpec
- name: 'SizeXEntryField'
- layout: (LayoutFrame 170 0 72 0 237 0 94 0)
- model: sizeX
- type: number
- immediateAccept: true
- acceptOnReturn: true
- acceptOnTab: true
- acceptOnLostFocus: true
- acceptOnPointerLeave: true
- )
- (LabelSpec
- label: ' x '
- name: 'xLabel'
- layout: (LayoutFrame 238 0 72 0 271 0 94 0)
- translateLabel: true
- )
- (InputFieldSpec
- name: 'SizeYEntryField'
- layout: (LayoutFrame 272 0 72 0 339 0 94 0)
- model: sizeY
- type: number
- immediateAccept: true
- acceptOnReturn: true
- acceptOnTab: true
- acceptOnLostFocus: true
- acceptOnPointerLeave: true
- )
- (LabelSpec
- label: '(mm)'
- name: 'mmLabel'
- layout: (LayoutFrame 351 0 72 0 397 0 94 0)
- translateLabel: true
- adjust: left
- )
- (DividerSpec
- name: 'Separator1'
- layout: (LayoutFrame 0 0.0 105 0 0 1.0 109 0)
- )
- (LabelSpec
- name: 'ScreenDepthVisualLabel'
- layout: (LayoutFrame 0 0.0 113 0.0 0 1.0 135 0)
- translateLabel: true
- labelChannel: screenDepthVisualLabelHolder
- adjust: left
- )
- (DividerSpec
- name: 'Separator2'
- layout: (LayoutFrame 0 0.0 139 0 0 1.0 143 0)
- )
- (CheckBoxSpec
- label: 'Color Monitor'
- name: 'ColorMonitorCheckBox'
- layout: (LayoutFrame 5 0 150 0 250 0 172 0)
- model: isColorMonitor
- translateLabel: true
- )
- (CheckBoxSpec
- label: 'Use Fix Color Palette'
- name: 'FixColorPaletteCheckBox'
- layout: (LayoutFrame 5 0 175 0 301 0 197 0)
- enableChannel: visualIsPseudoColor
- model: useFixPalette
- translateLabel: true
- labelChannel: useFixPaletteLabel
- )
- (CheckBoxSpec
- label: 'Use Fix Gray Color Palette'
- name: 'UseFixGrayPaletteCheckBox'
- layout: (LayoutFrame 5 0 201 0 301 0 223 0)
- enableChannel: visualIsPseudoColor
- model: useFixGrayPalette
- translateLabel: true
- labelChannel: useFixGrayPaletteLabel
- )
- (LabelSpec
- label: 'Image Display:'
- name: 'ImageDisplayLabel'
- layout: (LayoutFrame 0 0 230 0 255 0 252 0)
- translateLabel: true
- adjust: right
- )
- (PopUpListSpec
- label: 'image display'
- name: 'DitherListPopUpList'
- layout: (LayoutFrame 255 0 230 0 -5 1 252 0)
- tabable: true
- model: ditherListSelection
- enableChannel: ditherSymsNotNil
- menu: ditherList
- useIndex: true
- )
- (CheckBoxSpec
- label: 'Allow Colored/Grayscale Icons'
- name: 'AllowColoredGrayscaleIconsCheckBox'
- layout: (LayoutFrame 5 0 262 0 301 0 284 0)
- model: deepIcons
- translateLabel: true
- )
- (DividerSpec
- name: 'Separator3'
- layout: (LayoutFrame 0 0.0 288 0 0 1.0 292 0)
- )
- (LabelSpec
- label: 'ClipBoard Encoding:'
- name: 'ClipBoardEncodingLabel'
- layout: (LayoutFrame 0 0 303 0 255 0 325 0)
- translateLabel: true
- adjust: right
- )
- (PopUpListSpec
- label: 'image display'
- name: 'ClipEncodingListPopUpList'
- layout: (LayoutFrame 255 0 303 0 -5 1 325 0)
- tabable: true
- model: clipEncodingListSelection
- menu: clipEncodingList
- useIndex: true
- )
- (DividerSpec
- name: 'Separator4'
- layout: (LayoutFrame 0 0.0 360 0 0 1.0 364 0)
- )
- (LabelSpec
- label: 'Max. CopyBuffer Size:'
- name: 'MaxCopyBufferSizeLabel'
- layout: (LayoutFrame 0 0 330 0 255 0 352 0)
- translateLabel: true
- adjust: right
- )
- (InputFieldSpec
- name: 'MaxCopyBufferEntryField'
- layout: (LayoutFrame 255 0 330 0 350 0 352 0)
- model: maxCopyBufferSize
- type: fileSize
- immediateAccept: true
- acceptOnReturn: true
- acceptOnTab: true
- acceptOnLostFocus: true
- acceptOnPointerLeave: true
- )
- )
-
- )
- )
+ #(FullSpec
+ name: windowSpec
+ window:
+ (WindowSpec
+ label: 'Display Screen Settings'
+ name: 'Display Screen Settings'
+ min: (Point 10 10)
+ bounds: (Rectangle 0 0 603 459)
+ )
+ component:
+ (SpecCollection
+ collection: (
+ (LabelSpec
+ label: 'Actual Visible Screen Area:'
+ name: 'ActualVisibleScreenAreaLabel'
+ layout: (LayoutFrame 0 0.0 0 0.0 0 1.0 22 0)
+ translateLabel: true
+ adjust: left
+ )
+ (LabelSpec
+ label: 'Common Sizes:'
+ name: 'CommonSizesLabel'
+ layout: (LayoutFrame 0 0 39 0 163 0 61 0)
+ translateLabel: true
+ adjust: right
+ )
+ (PopUpListSpec
+ label: 'monitor size'
+ name: 'MonitorSelectionPopUpList'
+ layout: (LayoutFrame 170 0 39 0 -5 1 61 0)
+ tabable: true
+ model: monitorSelection
+ menu: monitorList
+ useIndex: true
+ )
+ (LabelSpec
+ label: 'Screen Size:'
+ name: 'ScreenSizeLabel'
+ layout: (LayoutFrame 0 0 72 0 163 0 94 0)
+ translateLabel: true
+ adjust: right
+ )
+ (InputFieldSpec
+ name: 'SizeXEntryField'
+ layout: (LayoutFrame 170 0 72 0 237 0 94 0)
+ model: sizeX
+ type: number
+ immediateAccept: true
+ acceptOnReturn: true
+ acceptOnTab: true
+ acceptOnLostFocus: true
+ acceptOnPointerLeave: true
+ )
+ (LabelSpec
+ label: ' x '
+ name: 'xLabel'
+ layout: (LayoutFrame 238 0 72 0 259 0 94 0)
+ translateLabel: true
+ )
+ (InputFieldSpec
+ name: 'SizeYEntryField'
+ layout: (LayoutFrame 260 0 72 0 327 0 94 0)
+ model: sizeY
+ type: number
+ immediateAccept: true
+ acceptOnReturn: true
+ acceptOnTab: true
+ acceptOnLostFocus: true
+ acceptOnPointerLeave: true
+ )
+ (LabelSpec
+ label: '(mm)'
+ name: 'mmLabel'
+ layout: (LayoutFrame 339 0 72 0 385 0 94 0)
+ translateLabel: true
+ adjust: left
+ )
+ (DividerSpec
+ name: 'Separator1'
+ layout: (LayoutFrame 0 0.0 143 0 0 1.0 147 0)
+ )
+ (LabelSpec
+ name: 'ScreenDepthVisualLabel'
+ layout: (LayoutFrame 0 0.0 151 0.0 0 1.0 173 0)
+ translateLabel: true
+ labelChannel: screenDepthVisualLabelHolder
+ adjust: left
+ )
+ (DividerSpec
+ name: 'Separator2'
+ layout: (LayoutFrame 0 0.0 177 0 0 1.0 181 0)
+ )
+ (CheckBoxSpec
+ label: 'Color Monitor'
+ name: 'ColorMonitorCheckBox'
+ layout: (LayoutFrame 5 0 188 0 250 0 210 0)
+ model: isColorMonitor
+ translateLabel: true
+ )
+ (CheckBoxSpec
+ label: 'Use Fix Color Palette'
+ name: 'FixColorPaletteCheckBox'
+ layout: (LayoutFrame 5 0 213 0 301 0 235 0)
+ enableChannel: visualIsPseudoColor
+ model: useFixPalette
+ translateLabel: true
+ labelChannel: useFixPaletteLabel
+ )
+ (CheckBoxSpec
+ label: 'Use Fix Gray Color Palette'
+ name: 'UseFixGrayPaletteCheckBox'
+ layout: (LayoutFrame 5 0 239 0 301 0 261 0)
+ enableChannel: visualIsPseudoColor
+ model: useFixGrayPalette
+ translateLabel: true
+ labelChannel: useFixGrayPaletteLabel
+ )
+ (LabelSpec
+ label: 'Image Display:'
+ name: 'ImageDisplayLabel'
+ layout: (LayoutFrame 0 0 268 0 255 0 290 0)
+ translateLabel: true
+ adjust: right
+ )
+ (PopUpListSpec
+ label: 'image display'
+ name: 'DitherListPopUpList'
+ layout: (LayoutFrame 255 0 268 0 -5 1 290 0)
+ tabable: true
+ model: ditherListSelection
+ enableChannel: ditherSymsNotNil
+ menu: ditherList
+ useIndex: true
+ )
+ (CheckBoxSpec
+ label: 'Allow Colored/Grayscale Icons'
+ name: 'AllowColoredGrayscaleIconsCheckBox'
+ layout: (LayoutFrame 5 0 300 0 301 0 322 0)
+ model: deepIcons
+ translateLabel: true
+ )
+ (DividerSpec
+ name: 'Separator3'
+ layout: (LayoutFrame 0 0.0 326 0 0 1.0 330 0)
+ )
+ (LabelSpec
+ label: 'ClipBoard Encoding:'
+ name: 'ClipBoardEncodingLabel'
+ layout: (LayoutFrame 0 0 341 0 255 0 363 0)
+ translateLabel: true
+ adjust: right
+ )
+ (PopUpListSpec
+ label: 'image display'
+ name: 'ClipEncodingListPopUpList'
+ layout: (LayoutFrame 255 0 341 0 -5 1 363 0)
+ tabable: true
+ model: clipEncodingListSelection
+ menu: clipEncodingList
+ useIndex: true
+ )
+ (DividerSpec
+ name: 'Separator4'
+ layout: (LayoutFrame 0 0.0 398 0 0 1.0 402 0)
+ )
+ (LabelSpec
+ label: 'Max. CopyBuffer Size:'
+ name: 'MaxCopyBufferSizeLabel'
+ layout: (LayoutFrame 0 0 368 0 255 0 390 0)
+ translateLabel: true
+ adjust: right
+ )
+ (InputFieldSpec
+ name: 'MaxCopyBufferEntryField'
+ layout: (LayoutFrame 255 0 368 0 350 0 390 0)
+ model: maxCopyBufferSize
+ type: fileSize
+ immediateAccept: true
+ acceptOnReturn: true
+ acceptOnTab: true
+ acceptOnLostFocus: true
+ acceptOnPointerLeave: true
+ )
+ (LabelSpec
+ label: 'Limit Usable Area To:'
+ name: 'Label1'
+ layout: (LayoutFrame 0 0 105 0 163 0 127 0)
+ translateLabel: true
+ adjust: right
+ )
+ (InputFieldSpec
+ name: 'EntryField1'
+ layout: (LayoutFrame 170 0 105 0 237 0 127 0)
+ model: usedWidth
+ type: number
+ immediateAccept: true
+ acceptOnReturn: true
+ acceptOnTab: true
+ acceptOnLostFocus: true
+ acceptOnPointerLeave: true
+ )
+ (LabelSpec
+ label: ' x '
+ name: 'Label2'
+ layout: (LayoutFrame 238 0 105 0 259 0 127 0)
+ translateLabel: true
+ )
+ (InputFieldSpec
+ name: 'EntryField2'
+ layout: (LayoutFrame 260 0 105 0 327 0 127 0)
+ model: usedHeight
+ type: number
+ immediateAccept: true
+ acceptOnReturn: true
+ acceptOnTab: true
+ acceptOnLostFocus: true
+ acceptOnPointerLeave: true
+ )
+ (LabelSpec
+ label: '(Pixel)'
+ name: 'Label3'
+ layout: (LayoutFrame 339 0 105 0 385 0 127 0)
+ translateLabel: true
+ adjust: left
+ )
+ (ActionButtonSpec
+ label: 'Restore'
+ name: 'Button1'
+ layout: (AlignmentOrigin 402 0 117 0 0 0.5)
+ model: restoreUsableExtent
+ )
+ )
+
+ )
+ )
! !
!AbstractSettingsApplication::DisplaySettingsAppl methodsFor:'actions'!
@@ -3294,7 +3343,10 @@
self isColorMonitor value:screen hasColors.
self sizeX value:screen widthInMillimeter.
self sizeY value:screen heightInMillimeter.
+ self usedWidth value:screen usableWidth.
+ self usedHeight value:screen usableHeight.
self deepIcons value:screen supportsDeepIcons.
+
ditherSyms notNil ifTrue:[
self ditherListSelection
value:(ditherSyms indexOf:(Image ditherAlgorithm) ifAbsent:#threshold)
@@ -3333,6 +3385,9 @@
screen widthInMillimeter:self sizeX value.
screen heightInMillimeter:self sizeY value.
+ screen setUsableWidth:self usedWidth value.
+ screen setUsableHeight:self usedHeight value.
+
screen supportsDeepIcons:self deepIcons value.
ditherSyms notNil ifTrue:[
Image ditherAlgorithm:(ditherSyms at:self ditherListSelection value).
@@ -3343,6 +3398,11 @@
].
screen clipboardEncoding:(self class clipEncodingSyms at:self clipEncodingListSelection value).
+!
+
+restoreUsableExtent
+ self usedWidth value:(screen queryWidth).
+ self usedHeight value:(screen queryHeight).
! !
!AbstractSettingsApplication::DisplaySettingsAppl methodsFor:'aspects'!
@@ -3511,6 +3571,26 @@
^ useFixPaletteLabel.
!
+usedHeight
+ usedHeight isNil ifTrue:[
+ usedHeight := screen usableHeight asValue.
+ usedHeight addDependent:self.
+ usedHeight changed.
+ usedHeight onChangeSend:#updateModifiedChannel to:self.
+ ].
+ ^ usedHeight.
+!
+
+usedWidth
+ usedWidth isNil ifTrue:[
+ usedWidth := screen usableWidth asValue.
+ usedWidth addDependent:self.
+ usedWidth changed.
+ usedWidth onChangeSend:#updateModifiedChannel to:self.
+ ].
+ ^ usedWidth.
+!
+
visualIsPseudoColor
visualIsPseudoColor isNil ifTrue:[
@@ -3553,7 +3633,7 @@
self monitorSelectionChanged.
^ self.
].
- (changedObject == self sizeX or:[self sizeY]) ifTrue:[
+ (changedObject == self sizeX or:[changedObject == self sizeY]) ifTrue:[
self sizeXorYChanged.
^ self.
].
@@ -3610,6 +3690,8 @@
self isColorMonitor value ~= screen hasColors ifTrue:[^ true].
self sizeX value ~= screen widthInMillimeter ifTrue:[^ true].
self sizeY value ~= screen heightInMillimeter ifTrue:[^ true].
+ self usedWidth value ~= screen usableWidth ifTrue:[^ true].
+ self usedHeight value ~= screen usableHeight ifTrue:[^ true].
self deepIcons value ~= screen supportsDeepIcons ifTrue:[^ true].
ditherSyms notNil ifTrue:[
@@ -18301,10 +18383,10 @@
!AbstractSettingsApplication class methodsFor:'documentation'!
version
- ^ '$Header: /cvs/stx/stx/libtool/AbstractSettingsApplication.st,v 1.501 2013-09-24 20:16:09 cg Exp $'
+ ^ '$Header: /cvs/stx/stx/libtool/AbstractSettingsApplication.st,v 1.502 2013-10-30 08:48:38 cg Exp $'
!
version_CVS
- ^ '$Header: /cvs/stx/stx/libtool/AbstractSettingsApplication.st,v 1.501 2013-09-24 20:16:09 cg Exp $'
-! !
-
+ ^ '$Header: /cvs/stx/stx/libtool/AbstractSettingsApplication.st,v 1.502 2013-10-30 08:48:38 cg Exp $'
+! !
+