MacFlatButtonBorder.st
author mawalch
Thu, 07 Jul 2016 20:21:22 +0200
changeset 7403 9a4c5d6da62c
parent 7040 9de35e2b291f
child 7835 019761925559
child 8595 7f9b84978a2e
permissions -rw-r--r--
#OTHER by mawalch Spelling fixes.
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
6943
80ae41ea8a5b initial checkin
Claus Gittinger <cg@exept.de>
parents: 6942
diff changeset
     1
"{ Encoding: utf8 }"
80ae41ea8a5b initial checkin
Claus Gittinger <cg@exept.de>
parents: 6942
diff changeset
     2
6942
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
     3
"{ Package: 'stx:libview' }"
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
     4
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
     5
"{ NameSpace: Smalltalk }"
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
     6
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
     7
SimpleBorder subclass:#MacFlatButtonBorder
6965
066bfdfbb5b3 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6943
diff changeset
     8
	instanceVariableNames:'backgroundColor1 backgroundColor2 imgTopLeft imgTopRight
066bfdfbb5b3 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6943
diff changeset
     9
		imgBottomLeft imgBottomRight'
6942
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    10
	classVariableNames:''
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    11
	poolDictionaries:''
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    12
	category:'Graphics-Support'
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    13
!
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    14
6943
80ae41ea8a5b initial checkin
Claus Gittinger <cg@exept.de>
parents: 6942
diff changeset
    15
!MacFlatButtonBorder class methodsFor:'documentation'!
80ae41ea8a5b initial checkin
Claus Gittinger <cg@exept.de>
parents: 6942
diff changeset
    16
80ae41ea8a5b initial checkin
Claus Gittinger <cg@exept.de>
parents: 6942
diff changeset
    17
documentation
80ae41ea8a5b initial checkin
Claus Gittinger <cg@exept.de>
parents: 6942
diff changeset
    18
"
80ae41ea8a5b initial checkin
Claus Gittinger <cg@exept.de>
parents: 6942
diff changeset
    19
    an as yet unused and unfinished attempt to provide a mac-osx like
80ae41ea8a5b initial checkin
Claus Gittinger <cg@exept.de>
parents: 6942
diff changeset
    20
    button border. These will look like mac buttons in yosemite (i.e. ugly old 70s retro flat style).
80ae41ea8a5b initial checkin
Claus Gittinger <cg@exept.de>
parents: 6942
diff changeset
    21
    To be continued.
80ae41ea8a5b initial checkin
Claus Gittinger <cg@exept.de>
parents: 6942
diff changeset
    22
"
80ae41ea8a5b initial checkin
Claus Gittinger <cg@exept.de>
parents: 6942
diff changeset
    23
! !
6942
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    24
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    25
!MacFlatButtonBorder class methodsFor:'instance creation'!
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    26
6965
066bfdfbb5b3 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6943
diff changeset
    27
color:color1 backgroundColor:color2
066bfdfbb5b3 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6943
diff changeset
    28
    "create a new instance of the receiver with a border of the given color."
066bfdfbb5b3 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6943
diff changeset
    29
066bfdfbb5b3 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6943
diff changeset
    30
    ^ self new color:color1; backgroundColor:color2
066bfdfbb5b3 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6943
diff changeset
    31
!
066bfdfbb5b3 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6943
diff changeset
    32
6942
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    33
color:color1 insideColor:color2
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    34
    "create a new instance of the receiver with a border of the given color."
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    35
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    36
    ^ self new color:color1; insideColor:color2
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    37
! !
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    38
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    39
!MacFlatButtonBorder class methodsFor:'image specs'!
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    40
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    41
topLeftImageFilled
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    42
    "This resource specification was automatically generated
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    43
     by the ImageEditor of ST/X."
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    44
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    45
    "Do not manually edit this!! If it is corrupted,
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    46
     the ImageEditor may not be able to read the specification."
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    47
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    48
    "
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    49
     self topLeftImageFilled inspect
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    50
     ImageEditor openOnClass:self andSelector:#topLeftImageFilled
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    51
     Icon flushCachedIcons
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    52
    "
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    53
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    54
    <resource: #image>
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    55
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    56
    ^Icon
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    57
        constantNamed:'MacOSXRoundButtonBorder topLeftImageFilled'
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    58
        ifAbsentPut:[(Depth8Image width:4 height:4) bits:(ByteArray fromPackedString:'@@LB@PLA@P@B@P@@@P@@@@@a') colorMapFromArray:#[44 132 251 49 107 245 95 142 236 175 196 234] mask:((ImageMask width:4 height:4) bits:(ByteArray fromPackedString:'\OC0<@@a'); yourself); yourself]
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    59
!
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    60
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    61
topLeftImageUnfilled
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    62
    "This resource specification was automatically generated
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    63
     by the ImageEditor of ST/X."
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    64
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    65
    "Do not manually edit this!! If it is corrupted,
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    66
     the ImageEditor may not be able to read the specification."
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    67
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    68
    "
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    69
     self topLeftImageUnfilled inspect
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    70
     ImageEditor openOnClass:self andSelector:#topLeftImageUnfilled
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    71
     Icon flushCachedIcons
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    72
    "
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    73
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    74
    <resource: #image>
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    75
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    76
    ^Icon
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    77
        constantNamed:'MacOSXRoundButtonBorder topLeftImageUnfilled'
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    78
        ifAbsentPut:[(Depth2Image width:4 height:4) bits:(ByteArray fromPackedString:'9HMOO0@a') colorMapFromArray:#[183 183 183 201 201 201 224 224 224 255 255 255] mask:((ImageMask width:4 height:4) bits:(ByteArray fromPackedString:'\OC0<@@a'); yourself); yourself]
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    79
!
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    80
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    81
topLeftImageUnfilledMasked
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    82
    "This resource specification was automatically generated
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    83
     by the ImageEditor of ST/X."
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    84
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    85
    "Do not manually edit this!! If it is corrupted,
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    86
     the ImageEditor may not be able to read the specification."
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    87
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    88
    "
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    89
     self topLeftImageUnfilledMasked inspect
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    90
     ImageEditor openOnClass:self andSelector:#topLeftImageUnfilledMasked
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    91
     Icon flushCachedIcons
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    92
    "
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    93
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    94
    <resource: #image>
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    95
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    96
    ^Icon
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    97
        constantNamed:'MacOSXRoundButtonBorder topLeftImageUnfilledMasked'
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    98
        ifAbsentPut:[(Depth2Image width:4 height:4) bits:(ByteArray fromPackedString:'IHA@@@@a') colorMapFromArray:#[183 183 183 201 201 201 224 224 224 255 255 255] mask:((ImageMask width:4 height:4) bits:(ByteArray fromPackedString:'\NC@ @@a'); yourself); yourself]
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    99
!
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   100
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   101
topLeftImageUnfilledMasked2
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   102
    "This resource specification was automatically generated
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   103
     by the ImageEditor of ST/X."
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   104
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   105
    "Do not manually edit this!! If it is corrupted,
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   106
     the ImageEditor may not be able to read the specification."
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   107
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   108
    "
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   109
     self topLeftImageUnfilledMasked2 inspect
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   110
     ImageEditor openOnClass:self andSelector:#topLeftImageUnfilledMasked2
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   111
     Icon flushCachedIcons
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   112
    "
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   113
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   114
    <resource: #image>
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   115
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   116
    ^Icon
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   117
        constantNamed:'MacOSXRoundButtonBorder topLeftImageUnfilledMasked2'
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   118
        ifAbsentPut:[(Depth2Image width:4 height:4) bits:(ByteArray fromPackedString:'IH!! @@@a') colorMapFromArray:#[183 183 183 201 201 201 224 224 224 255 255 255] mask:((ImageMask width:4 height:4) bits:(ByteArray fromPackedString:'\NC@ @@a'); yourself); yourself]
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   119
!
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   120
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   121
topLeftImageUnfilledMasked3
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   122
    "This resource specification was automatically generated
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   123
     by the ImageEditor of ST/X."
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   124
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   125
    "Do not manually edit this!! If it is corrupted,
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   126
     the ImageEditor may not be able to read the specification."
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   127
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   128
    "
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   129
     self topLeftImageUnfilledMasked3 inspect
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   130
     ImageEditor openOnClass:self andSelector:#topLeftImageUnfilledMasked3
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   131
     Icon flushCachedIcons
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   132
    "
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   133
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   134
    <resource: #image>
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   135
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   136
    ^Icon
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   137
        constantNamed:'MacOSXRoundButtonBorder topLeftImageUnfilledMasked3'
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   138
        ifAbsentPut:[(Depth2Image width:4 height:4) bits:(ByteArray fromPackedString:'HH  @@@a') colorMapFromArray:#[183 183 183 201 201 201 224 224 224 255 255 255] mask:((ImageMask width:4 height:4) bits:(ByteArray fromPackedString:'\NC@ @@a'); yourself); yourself]
6965
066bfdfbb5b3 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6943
diff changeset
   139
!
066bfdfbb5b3 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6943
diff changeset
   140
066bfdfbb5b3 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6943
diff changeset
   141
topLeftImageUnfilledMasked4
066bfdfbb5b3 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6943
diff changeset
   142
    "This resource specification was automatically generated
066bfdfbb5b3 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6943
diff changeset
   143
     by the ImageEditor of ST/X."
066bfdfbb5b3 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6943
diff changeset
   144
066bfdfbb5b3 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6943
diff changeset
   145
    "Do not manually edit this!! If it is corrupted,
066bfdfbb5b3 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6943
diff changeset
   146
     the ImageEditor may not be able to read the specification."
066bfdfbb5b3 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6943
diff changeset
   147
066bfdfbb5b3 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6943
diff changeset
   148
    "
066bfdfbb5b3 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6943
diff changeset
   149
     self topLeftImageUnfilledMasked4 inspect
066bfdfbb5b3 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6943
diff changeset
   150
     ImageEditor openOnClass:self andSelector:#topLeftImageUnfilledMasked4
066bfdfbb5b3 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6943
diff changeset
   151
     Icon flushCachedIcons
066bfdfbb5b3 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6943
diff changeset
   152
    "
066bfdfbb5b3 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6943
diff changeset
   153
066bfdfbb5b3 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6943
diff changeset
   154
    <resource: #image>
066bfdfbb5b3 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6943
diff changeset
   155
066bfdfbb5b3 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6943
diff changeset
   156
    ^Icon
066bfdfbb5b3 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6943
diff changeset
   157
        constantNamed:'MacFlatButtonBorder topLeftImageUnfilledMasked4'
6973
12bfcaedde29 #FEATURE
Claus Gittinger <cg@exept.de>
parents: 6965
diff changeset
   158
        ifAbsentPut:[(Depth2Image width:4 height:4) bits:(ByteArray fromPackedString:'HH,/O0@a') colorMapFromArray:#[183 183 183 201 201 201 224 224 224 255 255 255] mask:((ImageMask width:4 height:4) bits:(ByteArray fromPackedString:'\OC0<@@a'); yourself); yourself]
6982
6056c7d05b97 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6976
diff changeset
   159
!
6056c7d05b97 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6976
diff changeset
   160
6056c7d05b97 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6976
diff changeset
   161
topLeftImageUnfilledMasked5
6056c7d05b97 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6976
diff changeset
   162
    "This resource specification was automatically generated
6056c7d05b97 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6976
diff changeset
   163
     by the ImageEditor of ST/X."
6056c7d05b97 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6976
diff changeset
   164
6056c7d05b97 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6976
diff changeset
   165
    "Do not manually edit this!! If it is corrupted,
6056c7d05b97 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6976
diff changeset
   166
     the ImageEditor may not be able to read the specification."
6056c7d05b97 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6976
diff changeset
   167
6056c7d05b97 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6976
diff changeset
   168
    "
6056c7d05b97 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6976
diff changeset
   169
     self topLeftImageUnfilledMasked5 inspect
6056c7d05b97 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6976
diff changeset
   170
     ImageEditor openOnClass:self andSelector:#topLeftImageUnfilledMasked5
6056c7d05b97 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6976
diff changeset
   171
     Icon flushCachedIcons
6056c7d05b97 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6976
diff changeset
   172
    "
6056c7d05b97 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6976
diff changeset
   173
6056c7d05b97 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6976
diff changeset
   174
    <resource: #image>
6056c7d05b97 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6976
diff changeset
   175
6056c7d05b97 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6976
diff changeset
   176
    ^Icon
6056c7d05b97 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6976
diff changeset
   177
        constantNamed:'MacFlatButtonBorder topLeftImageUnfilledMasked5'
6056c7d05b97 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6976
diff changeset
   178
        ifAbsentPut:[(Depth2Image width:4 height:4) bits:(ByteArray fromPackedString:'HH<?O0@a') colorMapFromArray:#[183 183 183 201 201 201 224 224 224 255 255 255] mask:((ImageMask width:4 height:4) bits:(ByteArray fromPackedString:'\OC0<@@a'); yourself); yourself]
6985
d5f5ff0cae1a viewbackground from container
Claus Gittinger <cg@exept.de>
parents: 6982
diff changeset
   179
!
d5f5ff0cae1a viewbackground from container
Claus Gittinger <cg@exept.de>
parents: 6982
diff changeset
   180
d5f5ff0cae1a viewbackground from container
Claus Gittinger <cg@exept.de>
parents: 6982
diff changeset
   181
topLeftImageUnfilledMasked6
d5f5ff0cae1a viewbackground from container
Claus Gittinger <cg@exept.de>
parents: 6982
diff changeset
   182
    "This resource specification was automatically generated
d5f5ff0cae1a viewbackground from container
Claus Gittinger <cg@exept.de>
parents: 6982
diff changeset
   183
     by the ImageEditor of ST/X."
d5f5ff0cae1a viewbackground from container
Claus Gittinger <cg@exept.de>
parents: 6982
diff changeset
   184
d5f5ff0cae1a viewbackground from container
Claus Gittinger <cg@exept.de>
parents: 6982
diff changeset
   185
    "Do not manually edit this!! If it is corrupted,
d5f5ff0cae1a viewbackground from container
Claus Gittinger <cg@exept.de>
parents: 6982
diff changeset
   186
     the ImageEditor may not be able to read the specification."
d5f5ff0cae1a viewbackground from container
Claus Gittinger <cg@exept.de>
parents: 6982
diff changeset
   187
d5f5ff0cae1a viewbackground from container
Claus Gittinger <cg@exept.de>
parents: 6982
diff changeset
   188
    "
d5f5ff0cae1a viewbackground from container
Claus Gittinger <cg@exept.de>
parents: 6982
diff changeset
   189
     self topLeftImageUnfilledMasked6 inspect
d5f5ff0cae1a viewbackground from container
Claus Gittinger <cg@exept.de>
parents: 6982
diff changeset
   190
     ImageEditor openOnClass:self andSelector:#topLeftImageUnfilledMasked6
d5f5ff0cae1a viewbackground from container
Claus Gittinger <cg@exept.de>
parents: 6982
diff changeset
   191
     Icon flushCachedIcons
d5f5ff0cae1a viewbackground from container
Claus Gittinger <cg@exept.de>
parents: 6982
diff changeset
   192
    "
d5f5ff0cae1a viewbackground from container
Claus Gittinger <cg@exept.de>
parents: 6982
diff changeset
   193
d5f5ff0cae1a viewbackground from container
Claus Gittinger <cg@exept.de>
parents: 6982
diff changeset
   194
    <resource: #image>
d5f5ff0cae1a viewbackground from container
Claus Gittinger <cg@exept.de>
parents: 6982
diff changeset
   195
d5f5ff0cae1a viewbackground from container
Claus Gittinger <cg@exept.de>
parents: 6982
diff changeset
   196
    ^Icon
d5f5ff0cae1a viewbackground from container
Claus Gittinger <cg@exept.de>
parents: 6982
diff changeset
   197
        constantNamed:'MacFlatButtonBorder topLeftImageUnfilledMasked6'
d5f5ff0cae1a viewbackground from container
Claus Gittinger <cg@exept.de>
parents: 6982
diff changeset
   198
        ifAbsentPut:[(Depth2Image width:4 height:4) bits:(ByteArray fromPackedString:'@@<?O0@a') colorMapFromArray:#[183 183 183 201 201 201 224 224 224 255 255 255] mask:((ImageMask width:4 height:4) bits:(ByteArray fromPackedString:'LGC0<@@a'); yourself); yourself]
6942
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   199
! !
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   200
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   201
!MacFlatButtonBorder methodsFor:'accessing'!
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   202
6965
066bfdfbb5b3 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6943
diff changeset
   203
backgroundColor1
066bfdfbb5b3 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6943
diff changeset
   204
    "the first gradient color"
066bfdfbb5b3 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6943
diff changeset
   205
066bfdfbb5b3 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6943
diff changeset
   206
    ^ backgroundColor1
066bfdfbb5b3 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6943
diff changeset
   207
!
066bfdfbb5b3 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6943
diff changeset
   208
6976
38ae15a18db3 #FEATURE
Claus Gittinger <cg@exept.de>
parents: 6973
diff changeset
   209
backgroundColor1:newColor
6965
066bfdfbb5b3 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6943
diff changeset
   210
    "the first gradient color"
066bfdfbb5b3 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6943
diff changeset
   211
6976
38ae15a18db3 #FEATURE
Claus Gittinger <cg@exept.de>
parents: 6973
diff changeset
   212
    backgroundColor1 ~= newColor ifTrue:[        
38ae15a18db3 #FEATURE
Claus Gittinger <cg@exept.de>
parents: 6973
diff changeset
   213
        backgroundColor1 := newColor.
38ae15a18db3 #FEATURE
Claus Gittinger <cg@exept.de>
parents: 6973
diff changeset
   214
        imgTopLeft := imgTopRight := imgBottomLeft := imgBottomRight := nil.
38ae15a18db3 #FEATURE
Claus Gittinger <cg@exept.de>
parents: 6973
diff changeset
   215
    ]
6965
066bfdfbb5b3 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6943
diff changeset
   216
!
066bfdfbb5b3 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6943
diff changeset
   217
066bfdfbb5b3 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6943
diff changeset
   218
backgroundColor2
066bfdfbb5b3 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6943
diff changeset
   219
    "the second gradient color"
066bfdfbb5b3 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6943
diff changeset
   220
066bfdfbb5b3 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6943
diff changeset
   221
    ^ backgroundColor2
066bfdfbb5b3 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6943
diff changeset
   222
!
066bfdfbb5b3 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6943
diff changeset
   223
6976
38ae15a18db3 #FEATURE
Claus Gittinger <cg@exept.de>
parents: 6973
diff changeset
   224
backgroundColor2:newColor
6965
066bfdfbb5b3 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6943
diff changeset
   225
    "the second gradient color"
066bfdfbb5b3 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6943
diff changeset
   226
6976
38ae15a18db3 #FEATURE
Claus Gittinger <cg@exept.de>
parents: 6973
diff changeset
   227
    backgroundColor2 ~= newColor ifTrue:[        
38ae15a18db3 #FEATURE
Claus Gittinger <cg@exept.de>
parents: 6973
diff changeset
   228
        backgroundColor2 := newColor.
38ae15a18db3 #FEATURE
Claus Gittinger <cg@exept.de>
parents: 6973
diff changeset
   229
        imgTopLeft := imgTopRight := imgBottomLeft := imgBottomRight := nil.
38ae15a18db3 #FEATURE
Claus Gittinger <cg@exept.de>
parents: 6973
diff changeset
   230
    ]
6965
066bfdfbb5b3 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6943
diff changeset
   231
!
066bfdfbb5b3 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6943
diff changeset
   232
6942
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   233
color:newColor
6965
066bfdfbb5b3 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6943
diff changeset
   234
    "the color of the border"
066bfdfbb5b3 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6943
diff changeset
   235
    
6942
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   236
    color ~= newColor ifTrue:[        
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   237
        color := newColor.
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   238
        imgTopLeft := imgTopRight := imgBottomLeft := imgBottomRight := nil.
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   239
    ].
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   240
! !
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   241
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   242
!MacFlatButtonBorder methodsFor:'displaying'!
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   243
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   244
displayOn:aGC forDisplayBox:aRectangle
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   245
    |oldPaint boxLeft boxRight boxTop boxBottom boxWidth boxHeight|
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   246
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   247
    color isNil ifTrue:[ ^ self].
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   248
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   249
    oldPaint := aGC paint.
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   250
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   251
    boxLeft := aRectangle left.
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   252
    boxTop := aRectangle top.
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   253
    boxWidth := aRectangle width.
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   254
    boxHeight := aRectangle height.
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   255
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   256
    boxRight := boxLeft + boxWidth.
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   257
    boxBottom := boxTop + boxHeight.
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   258
    
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   259
    imgTopLeft isNil ifTrue:[
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   260
        self makeImages.
6965
066bfdfbb5b3 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6943
diff changeset
   261
        imgTopLeft isNil ifTrue:[
066bfdfbb5b3 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6943
diff changeset
   262
            ^ self
066bfdfbb5b3 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6943
diff changeset
   263
        ].    
6942
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   264
    ].    
7040
Claus Gittinger <cg@exept.de>
parents: 6985
diff changeset
   265
    aGC container isNil ifTrue:[
Claus Gittinger <cg@exept.de>
parents: 6985
diff changeset
   266
        aGC paint:(aGC viewBackground).
Claus Gittinger <cg@exept.de>
parents: 6985
diff changeset
   267
    ] ifFalse:[
Claus Gittinger <cg@exept.de>
parents: 6985
diff changeset
   268
        aGC paint:(aGC container viewBackground).
Claus Gittinger <cg@exept.de>
parents: 6985
diff changeset
   269
    ].
6973
12bfcaedde29 #FEATURE
Claus Gittinger <cg@exept.de>
parents: 6965
diff changeset
   270
    aGC fillRectangleX:boxLeft y:boxTop width:2 height:2.
12bfcaedde29 #FEATURE
Claus Gittinger <cg@exept.de>
parents: 6965
diff changeset
   271
    aGC fillRectangleX:boxRight-2 y:boxTop width:2 height:2.
12bfcaedde29 #FEATURE
Claus Gittinger <cg@exept.de>
parents: 6965
diff changeset
   272
    aGC fillRectangleX:boxRight-2 y:boxBottom-2 width:2 height:2.
12bfcaedde29 #FEATURE
Claus Gittinger <cg@exept.de>
parents: 6965
diff changeset
   273
    aGC fillRectangleX:boxLeft y:boxBottom-2 width:2 height:2.
6965
066bfdfbb5b3 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6943
diff changeset
   274
6942
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   275
    aGC displayImage:imgTopLeft x:boxLeft y:boxTop.
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   276
    aGC displayImage:imgTopRight x:boxRight-4 y:boxTop.
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   277
    aGC displayImage:imgBottomRight x:boxRight-4 y:boxBottom-4.
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   278
    aGC displayImage:imgBottomLeft x:boxLeft y:boxBottom-4.
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   279
6965
066bfdfbb5b3 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6943
diff changeset
   280
    aGC paint:color.
6942
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   281
    aGC displayLineFromX:boxLeft+4 y:boxTop toX:boxRight-4 y:boxTop.
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   282
    aGC displayLineFromX:boxLeft+4 y:boxBottom-1 toX:boxRight-4 y:boxBottom-1.
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   283
    aGC displayLineFromX:boxLeft y:boxTop+4 toX:boxLeft y:boxBottom-4.
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   284
    aGC displayLineFromX:boxRight-1 y:boxTop+4 toX:boxRight-1 y:boxBottom-4.
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   285
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   286
    aGC paint:oldPaint.
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   287
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   288
    "
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   289
     |v1 v2|
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   290
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   291
     v1 := TopView new.
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   292
     v2 := View origin:10@10 corner:100@30 in:v1.
6965
066bfdfbb5b3 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6943
diff changeset
   293
     v2 border:(MacFlatButtonBorder color:Color red).
6942
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   294
     v1 open.
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   295
    "
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   296
    "
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   297
     |v1 v2|
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   298
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   299
     v1 := TopView new.
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   300
     v2 := View origin:10@10 corner:100@30 in:v1.
6965
066bfdfbb5b3 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6943
diff changeset
   301
     v2 border:((MacFlatButtonBorder color:Color red) backgroundColor1:Color blue; backgroundColor2:Color green).
6942
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   302
     v1 open.
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   303
    "
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   304
! !
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   305
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   306
!MacFlatButtonBorder methodsFor:'private'!
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   307
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   308
makeImages
6965
066bfdfbb5b3 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6943
diff changeset
   309
    |protoImage img hue light sat|
6942
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   310
    
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   311
    hue := color hue.
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   312
    light := color light.
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   313
    sat := color saturation.
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   314
6985
d5f5ff0cae1a viewbackground from container
Claus Gittinger <cg@exept.de>
parents: 6982
diff changeset
   315
    protoImage := self class topLeftImageUnfilledMasked6.
6942
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   316
    img := protoImage copy.
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   317
6965
066bfdfbb5b3 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6943
diff changeset
   318
    img colorMap at:1 put:color.
066bfdfbb5b3 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6943
diff changeset
   319
    hue notNil ifTrue:[
6942
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   320
        img colorMap at:2 put:(Color hue:hue light:light+15 saturation:sat-12).
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   321
        img colorMap at:3 put:(Color hue:hue light:light+30 saturation:sat-40).
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   322
    ].    
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   323
    imgTopLeft := img.
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   324
    imgTopRight := img rotated:90.
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   325
    imgBottomLeft := img rotated:-90.
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   326
    imgBottomRight := img rotated:180.
6965
066bfdfbb5b3 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6943
diff changeset
   327
066bfdfbb5b3 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6943
diff changeset
   328
    backgroundColor1 notNil ifTrue:[ 
066bfdfbb5b3 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6943
diff changeset
   329
        imgTopLeft colorMap at:4 put:backgroundColor1. 
066bfdfbb5b3 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6943
diff changeset
   330
        imgTopRight colorMap at:4 put:backgroundColor1. 
066bfdfbb5b3 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6943
diff changeset
   331
    ].
066bfdfbb5b3 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6943
diff changeset
   332
    backgroundColor2 notNil ifTrue:[ 
066bfdfbb5b3 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6943
diff changeset
   333
        imgBottomLeft colorMap at:4 put:backgroundColor2. 
066bfdfbb5b3 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6943
diff changeset
   334
        imgBottomRight colorMap at:4 put:backgroundColor2. 
066bfdfbb5b3 #UI_ENHANCEMENT
Claus Gittinger <cg@exept.de>
parents: 6943
diff changeset
   335
    ].
6976
38ae15a18db3 #FEATURE
Claus Gittinger <cg@exept.de>
parents: 6973
diff changeset
   336
    
38ae15a18db3 #FEATURE
Claus Gittinger <cg@exept.de>
parents: 6973
diff changeset
   337
"/    imgBottomRight colorMap at:1 put:color darkened. 
38ae15a18db3 #FEATURE
Claus Gittinger <cg@exept.de>
parents: 6973
diff changeset
   338
"/    imgBottomRight colorMap at:2 put:color slightlyDarkened. 
38ae15a18db3 #FEATURE
Claus Gittinger <cg@exept.de>
parents: 6973
diff changeset
   339
"/    imgBottomRight colorMap at:3 put:color slightlyDarkened. 
6942
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   340
! !
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   341
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   342
!MacFlatButtonBorder class methodsFor:'documentation'!
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   343
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   344
version
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   345
    ^ '$Header$'
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   346
!
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   347
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   348
version_CVS
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   349
    ^ '$Header$'
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   350
! !
b804dc9f04de initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   351