VisualComponent.st
author Claus Gittinger <cg@exept.de>
Mon, 18 May 2009 16:03:47 +0200
changeset 2682 578ccaf16564
parent 2669 0d68c8c03911
child 2932 2121f8e38cf5
permissions -rw-r--r--
*** empty log message ***
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
245
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
     1
"
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
     2
 COPYRIGHT (c) 1996 by Claus Gittinger
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
     3
              All Rights Reserved
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
     4
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
     5
 This software is furnished under a license and may be used
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
     6
 only in accordance with the terms of that license and with the
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
     7
 inclusion of the above copyright notice.   This software may not
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
     8
 be provided or otherwise made available to, or used by, any
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
     9
 other person.  No title to or ownership of the software is
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    10
 hereby transferred.
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    11
"
1789
f52f0a0d8448 category
Claus Gittinger <cg@exept.de>
parents: 1270
diff changeset
    12
"{ Package: 'stx:libview2' }"
f52f0a0d8448 category
Claus Gittinger <cg@exept.de>
parents: 1270
diff changeset
    13
2659
0583c55f7000 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2233
diff changeset
    14
DisplayObject subclass:#VisualComponent
0583c55f7000 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2233
diff changeset
    15
	instanceVariableNames:''
245
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    16
	classVariableNames:''
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    17
	poolDictionaries:''
1789
f52f0a0d8448 category
Claus Gittinger <cg@exept.de>
parents: 1270
diff changeset
    18
	category:'Compatibility-ST80-Graphics-Display Objects'
245
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    19
!
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    20
365
47e0d48fd769 commentary
Claus Gittinger <cg@exept.de>
parents: 323
diff changeset
    21
!VisualComponent class methodsFor:'documentation'!
245
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    22
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    23
copyright
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    24
"
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    25
 COPYRIGHT (c) 1996 by Claus Gittinger
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    26
              All Rights Reserved
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    27
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    28
 This software is furnished under a license and may be used
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    29
 only in accordance with the terms of that license and with the
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    30
 inclusion of the above copyright notice.   This software may not
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    31
 be provided or otherwise made available to, or used by, any
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    32
 other person.  No title to or ownership of the software is
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    33
 hereby transferred.
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    34
"
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    35
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    36
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    37
!
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    38
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    39
documentation
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    40
"
246
9f80dbcbcd34 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 245
diff changeset
    41
    abstract superclass for all kinds of visual components.
265
45c83acd7562 comments
Claus Gittinger <cg@exept.de>
parents: 250
diff changeset
    42
    This class and its subclasses (currently) exist mostly for
45c83acd7562 comments
Claus Gittinger <cg@exept.de>
parents: 250
diff changeset
    43
    ST-80 compatibility - to provide a home for ported PD classes,
45c83acd7562 comments
Claus Gittinger <cg@exept.de>
parents: 250
diff changeset
    44
    which depend on the VisualComponent hierarchy.
45c83acd7562 comments
Claus Gittinger <cg@exept.de>
parents: 250
diff changeset
    45
45c83acd7562 comments
Claus Gittinger <cg@exept.de>
parents: 250
diff changeset
    46
    Notice: 
45c83acd7562 comments
Claus Gittinger <cg@exept.de>
parents: 250
diff changeset
    47
        this class was implemented using protocol information
365
47e0d48fd769 commentary
Claus Gittinger <cg@exept.de>
parents: 323
diff changeset
    48
        from alpha testers, from reading PD programs and 
47e0d48fd769 commentary
Claus Gittinger <cg@exept.de>
parents: 323
diff changeset
    49
        from the Hopkins/Horan book.
265
45c83acd7562 comments
Claus Gittinger <cg@exept.de>
parents: 250
diff changeset
    50
        - it may not be complete or compatible to the corresponding ST-80 class. 
45c83acd7562 comments
Claus Gittinger <cg@exept.de>
parents: 250
diff changeset
    51
        If you encounter any incompatibilities, please forward a note 
45c83acd7562 comments
Claus Gittinger <cg@exept.de>
parents: 250
diff changeset
    52
        describing the incompatibility verbal (i.e. no code) to the ST/X team.
45c83acd7562 comments
Claus Gittinger <cg@exept.de>
parents: 250
diff changeset
    53
        This is still being constructed - not yet finished.
245
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    54
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    55
    [author:]
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    56
        Claus Gittinger
265
45c83acd7562 comments
Claus Gittinger <cg@exept.de>
parents: 250
diff changeset
    57
45c83acd7562 comments
Claus Gittinger <cg@exept.de>
parents: 250
diff changeset
    58
    [see also:]
45c83acd7562 comments
Claus Gittinger <cg@exept.de>
parents: 250
diff changeset
    59
        GeometricWrapper
245
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    60
"
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    61
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    62
! !
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    63
365
47e0d48fd769 commentary
Claus Gittinger <cg@exept.de>
parents: 323
diff changeset
    64
!VisualComponent class methodsFor:'instance creation'!
245
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    65
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    66
new
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    67
    ^ self basicNew initialize
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    68
! !
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    69
962
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
    70
!VisualComponent class methodsFor:'queries'!
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
    71
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
    72
defaultFont
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
    73
    ^ SimpleView defaultFont
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
    74
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
    75
    "Created: / 18.6.1998 / 16:14:22 / cg"
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
    76
!
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
    77
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
    78
defaultViewBackgroundColor
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
    79
    ^ SimpleView defaultViewBackgroundColor
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
    80
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
    81
    "Created: / 18.6.1998 / 16:15:17 / cg"
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
    82
! !
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
    83
245
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    84
!VisualComponent methodsFor:'accessing'!
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    85
962
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
    86
backgroundColor
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
    87
    ^ Color white
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
    88
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
    89
    "Created: / 18.6.1998 / 16:01:00 / cg"
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
    90
!
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
    91
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
    92
backgroundColor:aColor
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
    93
    "ignored here"
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
    94
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
    95
    "Created: / 18.6.1998 / 16:15:28 / cg"
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
    96
!
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
    97
274
434f1bc78362 category changes
Claus Gittinger <cg@exept.de>
parents: 266
diff changeset
    98
container:someContainer
434f1bc78362 category changes
Claus Gittinger <cg@exept.de>
parents: 266
diff changeset
    99
    "ignored here"
434f1bc78362 category changes
Claus Gittinger <cg@exept.de>
parents: 266
diff changeset
   100
434f1bc78362 category changes
Claus Gittinger <cg@exept.de>
parents: 266
diff changeset
   101
    "Created: 9.5.1996 / 00:48:54 / cg"
434f1bc78362 category changes
Claus Gittinger <cg@exept.de>
parents: 266
diff changeset
   102
!
434f1bc78362 category changes
Claus Gittinger <cg@exept.de>
parents: 266
diff changeset
   103
962
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
   104
defaultFont
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
   105
    ^ SimpleView defaultFont
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
   106
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
   107
    "Created: / 18.6.1998 / 16:13:56 / cg"
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
   108
!
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
   109
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
   110
font:aFont
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
   111
    "ignored here"
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
   112
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
   113
    "Created: / 18.6.1998 / 16:14:39 / cg"
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
   114
!
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
   115
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
   116
foregroundColor
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
   117
    ^ Color black
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
   118
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
   119
    "Created: / 18.6.1998 / 16:01:07 / cg"
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
   120
!
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
   121
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
   122
foregroundColor:aColor
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
   123
    "ignored here"
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
   124
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
   125
    "Created: / 18.6.1998 / 16:14:53 / cg"
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
   126
!
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
   127
2659
0583c55f7000 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2233
diff changeset
   128
geometryLayout
0583c55f7000 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2233
diff changeset
   129
    "ignored here"
0583c55f7000 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2233
diff changeset
   130
0583c55f7000 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2233
diff changeset
   131
    ^ nil
0583c55f7000 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2233
diff changeset
   132
!
0583c55f7000 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2233
diff changeset
   133
962
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
   134
geometryLayout:aLayout
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
   135
    "ignored here"
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
   136
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
   137
    "Created: / 18.6.1998 / 16:15:39 / cg"
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
   138
!
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
   139
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
   140
hiddenOnRealize:aBoolean
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
   141
    "ignored here"
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
   142
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
   143
    "Created: / 18.6.1998 / 16:13:19 / cg"
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
   144
!
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
   145
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
   146
id
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
   147
    "ignored here"
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
   148
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
   149
    ^ nil
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
   150
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
   151
    "Created: / 18.6.1998 / 16:13:34 / cg"
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
   152
!
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
   153
274
434f1bc78362 category changes
Claus Gittinger <cg@exept.de>
parents: 266
diff changeset
   154
setParentViewIn:aView
434f1bc78362 category changes
Claus Gittinger <cg@exept.de>
parents: 266
diff changeset
   155
    "ignored here - for now"
434f1bc78362 category changes
Claus Gittinger <cg@exept.de>
parents: 266
diff changeset
   156
434f1bc78362 category changes
Claus Gittinger <cg@exept.de>
parents: 266
diff changeset
   157
    "Created: 9.5.1996 / 00:19:39 / cg"
962
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
   158
!
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
   159
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
   160
superView
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
   161
    ^ self container
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
   162
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
   163
    "Created: / 18.6.1998 / 16:16:07 / cg"
274
434f1bc78362 category changes
Claus Gittinger <cg@exept.de>
parents: 266
diff changeset
   164
! !
434f1bc78362 category changes
Claus Gittinger <cg@exept.de>
parents: 266
diff changeset
   165
994
1b606988c010 more ST80/STX compatibility
Claus Gittinger <cg@exept.de>
parents: 962
diff changeset
   166
!VisualComponent methodsFor:'accessing-STX-attributes'!
1b606988c010 more ST80/STX compatibility
Claus Gittinger <cg@exept.de>
parents: 962
diff changeset
   167
1270
774bf14543af more view compatibility
Claus Gittinger <cg@exept.de>
parents: 1220
diff changeset
   168
application
774bf14543af more view compatibility
Claus Gittinger <cg@exept.de>
parents: 1220
diff changeset
   169
    ^ self container application
774bf14543af more view compatibility
Claus Gittinger <cg@exept.de>
parents: 1220
diff changeset
   170
774bf14543af more view compatibility
Claus Gittinger <cg@exept.de>
parents: 1220
diff changeset
   171
    "Created: / 19.11.1999 / 17:44:38 / cg"
774bf14543af more view compatibility
Claus Gittinger <cg@exept.de>
parents: 1220
diff changeset
   172
!
774bf14543af more view compatibility
Claus Gittinger <cg@exept.de>
parents: 1220
diff changeset
   173
994
1b606988c010 more ST80/STX compatibility
Claus Gittinger <cg@exept.de>
parents: 962
diff changeset
   174
borderWidth
1b606988c010 more ST80/STX compatibility
Claus Gittinger <cg@exept.de>
parents: 962
diff changeset
   175
    ^ 0
1b606988c010 more ST80/STX compatibility
Claus Gittinger <cg@exept.de>
parents: 962
diff changeset
   176
1b606988c010 more ST80/STX compatibility
Claus Gittinger <cg@exept.de>
parents: 962
diff changeset
   177
    "Modified: / 6.7.1998 / 13:47:28 / cg"
1b606988c010 more ST80/STX compatibility
Claus Gittinger <cg@exept.de>
parents: 962
diff changeset
   178
!
1b606988c010 more ST80/STX compatibility
Claus Gittinger <cg@exept.de>
parents: 962
diff changeset
   179
1789
f52f0a0d8448 category
Claus Gittinger <cg@exept.de>
parents: 1270
diff changeset
   180
borderWidth:aNumber
f52f0a0d8448 category
Claus Gittinger <cg@exept.de>
parents: 1270
diff changeset
   181
    ^ 0
f52f0a0d8448 category
Claus Gittinger <cg@exept.de>
parents: 1270
diff changeset
   182
f52f0a0d8448 category
Claus Gittinger <cg@exept.de>
parents: 1270
diff changeset
   183
    "Modified: / 6.7.1998 / 13:47:28 / cg"
f52f0a0d8448 category
Claus Gittinger <cg@exept.de>
parents: 1270
diff changeset
   184
!
f52f0a0d8448 category
Claus Gittinger <cg@exept.de>
parents: 1270
diff changeset
   185
f52f0a0d8448 category
Claus Gittinger <cg@exept.de>
parents: 1270
diff changeset
   186
canTab:aBoolean
f52f0a0d8448 category
Claus Gittinger <cg@exept.de>
parents: 1270
diff changeset
   187
f52f0a0d8448 category
Claus Gittinger <cg@exept.de>
parents: 1270
diff changeset
   188
    "Modified: / 6.7.1998 / 13:46:17 / cg"
f52f0a0d8448 category
Claus Gittinger <cg@exept.de>
parents: 1270
diff changeset
   189
    "Created: / 6.7.1998 / 13:48:35 / cg"
f52f0a0d8448 category
Claus Gittinger <cg@exept.de>
parents: 1270
diff changeset
   190
!
f52f0a0d8448 category
Claus Gittinger <cg@exept.de>
parents: 1270
diff changeset
   191
2659
0583c55f7000 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2233
diff changeset
   192
layout
0583c55f7000 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2233
diff changeset
   193
    ^ self geometryLayout
0583c55f7000 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2233
diff changeset
   194
!
994
1b606988c010 more ST80/STX compatibility
Claus Gittinger <cg@exept.de>
parents: 962
diff changeset
   195
2659
0583c55f7000 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2233
diff changeset
   196
layout:newLayout
0583c55f7000 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2233
diff changeset
   197
    self geometryLayout:newLayout
994
1b606988c010 more ST80/STX compatibility
Claus Gittinger <cg@exept.de>
parents: 962
diff changeset
   198
!
1b606988c010 more ST80/STX compatibility
Claus Gittinger <cg@exept.de>
parents: 962
diff changeset
   199
1b606988c010 more ST80/STX compatibility
Claus Gittinger <cg@exept.de>
parents: 962
diff changeset
   200
level
1b606988c010 more ST80/STX compatibility
Claus Gittinger <cg@exept.de>
parents: 962
diff changeset
   201
    ^ 0
1b606988c010 more ST80/STX compatibility
Claus Gittinger <cg@exept.de>
parents: 962
diff changeset
   202
1b606988c010 more ST80/STX compatibility
Claus Gittinger <cg@exept.de>
parents: 962
diff changeset
   203
    "Modified: / 6.7.1998 / 13:46:17 / cg"
1b606988c010 more ST80/STX compatibility
Claus Gittinger <cg@exept.de>
parents: 962
diff changeset
   204
    "Created: / 6.7.1998 / 13:46:50 / cg"
1b606988c010 more ST80/STX compatibility
Claus Gittinger <cg@exept.de>
parents: 962
diff changeset
   205
!
1b606988c010 more ST80/STX compatibility
Claus Gittinger <cg@exept.de>
parents: 962
diff changeset
   206
1b606988c010 more ST80/STX compatibility
Claus Gittinger <cg@exept.de>
parents: 962
diff changeset
   207
level:newLevel
1b606988c010 more ST80/STX compatibility
Claus Gittinger <cg@exept.de>
parents: 962
diff changeset
   208
1b606988c010 more ST80/STX compatibility
Claus Gittinger <cg@exept.de>
parents: 962
diff changeset
   209
    "Modified: / 6.7.1998 / 13:46:17 / cg"
1b606988c010 more ST80/STX compatibility
Claus Gittinger <cg@exept.de>
parents: 962
diff changeset
   210
    "Created: / 6.7.1998 / 13:47:43 / cg"
2659
0583c55f7000 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2233
diff changeset
   211
!
0583c55f7000 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2233
diff changeset
   212
0583c55f7000 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2233
diff changeset
   213
name
0583c55f7000 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2233
diff changeset
   214
    ^ self printString
0583c55f7000 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2233
diff changeset
   215
!
0583c55f7000 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2233
diff changeset
   216
0583c55f7000 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2233
diff changeset
   217
realized
0583c55f7000 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2233
diff changeset
   218
    ^ true
0583c55f7000 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2233
diff changeset
   219
!
0583c55f7000 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2233
diff changeset
   220
0583c55f7000 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2233
diff changeset
   221
viewBackground
0583c55f7000 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2233
diff changeset
   222
    ^ self backgroundColor
994
1b606988c010 more ST80/STX compatibility
Claus Gittinger <cg@exept.de>
parents: 962
diff changeset
   223
! !
1b606988c010 more ST80/STX compatibility
Claus Gittinger <cg@exept.de>
parents: 962
diff changeset
   224
1b606988c010 more ST80/STX compatibility
Claus Gittinger <cg@exept.de>
parents: 962
diff changeset
   225
!VisualComponent methodsFor:'accessing-dimensions'!
274
434f1bc78362 category changes
Claus Gittinger <cg@exept.de>
parents: 266
diff changeset
   226
434f1bc78362 category changes
Claus Gittinger <cg@exept.de>
parents: 266
diff changeset
   227
bottom
434f1bc78362 category changes
Claus Gittinger <cg@exept.de>
parents: 266
diff changeset
   228
    "return my bottom y coordinate"
434f1bc78362 category changes
Claus Gittinger <cg@exept.de>
parents: 266
diff changeset
   229
434f1bc78362 category changes
Claus Gittinger <cg@exept.de>
parents: 266
diff changeset
   230
    ^ self bounds bottom
434f1bc78362 category changes
Claus Gittinger <cg@exept.de>
parents: 266
diff changeset
   231
434f1bc78362 category changes
Claus Gittinger <cg@exept.de>
parents: 266
diff changeset
   232
    "Modified: 9.5.1996 / 00:13:12 / cg"
434f1bc78362 category changes
Claus Gittinger <cg@exept.de>
parents: 266
diff changeset
   233
    "Created: 26.5.1996 / 12:56:12 / cg"
434f1bc78362 category changes
Claus Gittinger <cg@exept.de>
parents: 266
diff changeset
   234
!
434f1bc78362 category changes
Claus Gittinger <cg@exept.de>
parents: 266
diff changeset
   235
245
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   236
bounds
246
9f80dbcbcd34 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 245
diff changeset
   237
    "return my bounds"
9f80dbcbcd34 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 245
diff changeset
   238
2659
0583c55f7000 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2233
diff changeset
   239
    frame isNil ifTrue:[
0583c55f7000 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2233
diff changeset
   240
        self computeBoundingBox.
0583c55f7000 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2233
diff changeset
   241
    ].
0583c55f7000 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2233
diff changeset
   242
    ^ frame
962
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
   243
!
245
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   244
246
9f80dbcbcd34 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 245
diff changeset
   245
bounds:aRectangle
9f80dbcbcd34 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 245
diff changeset
   246
    "set my bounds"
9f80dbcbcd34 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 245
diff changeset
   247
2664
be1086ed7c1c *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2659
diff changeset
   248
    self assert:aRectangle notNil.
2659
0583c55f7000 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2233
diff changeset
   249
    frame := aRectangle
0583c55f7000 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2233
diff changeset
   250
!
245
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   251
2682
578ccaf16564 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2669
diff changeset
   252
defaultExtent
578ccaf16564 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2669
diff changeset
   253
    ^ 50@50
578ccaf16564 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2669
diff changeset
   254
!
578ccaf16564 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2669
diff changeset
   255
2659
0583c55f7000 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2233
diff changeset
   256
extent:anExtent
0583c55f7000 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2233
diff changeset
   257
    "set my extent"
0583c55f7000 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2233
diff changeset
   258
2669
0d68c8c03911 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2667
diff changeset
   259
    frame := self frame copy extent:anExtent
962
e6ccfc7fb22e added more dummy methods to allow visualComponents to be
Claus Gittinger <cg@exept.de>
parents: 406
diff changeset
   260
!
245
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   261
274
434f1bc78362 category changes
Claus Gittinger <cg@exept.de>
parents: 266
diff changeset
   262
left
434f1bc78362 category changes
Claus Gittinger <cg@exept.de>
parents: 266
diff changeset
   263
    "return my left x coordinate"
250
40acd5bd28ef checkin from browser
Claus Gittinger <cg@exept.de>
parents: 247
diff changeset
   264
274
434f1bc78362 category changes
Claus Gittinger <cg@exept.de>
parents: 266
diff changeset
   265
    ^ self bounds left
434f1bc78362 category changes
Claus Gittinger <cg@exept.de>
parents: 266
diff changeset
   266
434f1bc78362 category changes
Claus Gittinger <cg@exept.de>
parents: 266
diff changeset
   267
    "Created: 8.5.1996 / 23:36:07 / cg"
434f1bc78362 category changes
Claus Gittinger <cg@exept.de>
parents: 266
diff changeset
   268
    "Modified: 26.5.1996 / 12:56:22 / cg"
250
40acd5bd28ef checkin from browser
Claus Gittinger <cg@exept.de>
parents: 247
diff changeset
   269
!
40acd5bd28ef checkin from browser
Claus Gittinger <cg@exept.de>
parents: 247
diff changeset
   270
2233
7245ea01ade1 *** empty log message ***
fm
parents: 2210
diff changeset
   271
origin:newOrigin
2669
0d68c8c03911 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2667
diff changeset
   272
    "move my origin"
2233
7245ea01ade1 *** empty log message ***
fm
parents: 2210
diff changeset
   273
2682
578ccaf16564 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2669
diff changeset
   274
    |oldFrame|
578ccaf16564 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2669
diff changeset
   275
578ccaf16564 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2669
diff changeset
   276
    oldFrame := self frame.
578ccaf16564 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2669
diff changeset
   277
    oldFrame isNil ifTrue:[
578ccaf16564 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2669
diff changeset
   278
        oldFrame := 0@0 extent:(self defaultExtent).
578ccaf16564 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2669
diff changeset
   279
    ].
578ccaf16564 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2669
diff changeset
   280
578ccaf16564 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2669
diff changeset
   281
    frame := newOrigin copy extent:(oldFrame extent).
2233
7245ea01ade1 *** empty log message ***
fm
parents: 2210
diff changeset
   282
7245ea01ade1 *** empty log message ***
fm
parents: 2210
diff changeset
   283
    "Created: 8.5.1996 / 23:36:07 / cg"
7245ea01ade1 *** empty log message ***
fm
parents: 2210
diff changeset
   284
    "Modified: 9.5.1996 / 00:13:12 / cg"
7245ea01ade1 *** empty log message ***
fm
parents: 2210
diff changeset
   285
!
7245ea01ade1 *** empty log message ***
fm
parents: 2210
diff changeset
   286
245
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   287
preferredBounds
246
9f80dbcbcd34 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 245
diff changeset
   288
    "return my preferredBounds"
9f80dbcbcd34 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 245
diff changeset
   289
323
ee2f4da361a6 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 321
diff changeset
   290
    ^ 0@0 extent:100@100
245
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   291
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   292
    "Created: 8.5.1996 / 23:36:29 / cg"
323
ee2f4da361a6 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 321
diff changeset
   293
    "Modified: 19.7.1996 / 20:06:28 / cg"
ee2f4da361a6 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 321
diff changeset
   294
!
ee2f4da361a6 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 321
diff changeset
   295
ee2f4da361a6 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 321
diff changeset
   296
preferredExtent
ee2f4da361a6 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 321
diff changeset
   297
    ^ self preferredBounds extent
ee2f4da361a6 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 321
diff changeset
   298
246
9f80dbcbcd34 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 245
diff changeset
   299
    "Modified: 9.5.1996 / 00:13:22 / cg"
323
ee2f4da361a6 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 321
diff changeset
   300
    "Created: 19.7.1996 / 20:06:19 / cg"
247
7b29d5a02e68 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 246
diff changeset
   301
!
7b29d5a02e68 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 246
diff changeset
   302
274
434f1bc78362 category changes
Claus Gittinger <cg@exept.de>
parents: 266
diff changeset
   303
right
434f1bc78362 category changes
Claus Gittinger <cg@exept.de>
parents: 266
diff changeset
   304
    "return my right x coordinate"
434f1bc78362 category changes
Claus Gittinger <cg@exept.de>
parents: 266
diff changeset
   305
434f1bc78362 category changes
Claus Gittinger <cg@exept.de>
parents: 266
diff changeset
   306
    ^ self bounds right
247
7b29d5a02e68 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 246
diff changeset
   307
274
434f1bc78362 category changes
Claus Gittinger <cg@exept.de>
parents: 266
diff changeset
   308
    "Modified: 9.5.1996 / 00:13:12 / cg"
434f1bc78362 category changes
Claus Gittinger <cg@exept.de>
parents: 266
diff changeset
   309
    "Created: 26.5.1996 / 12:56:25 / cg"
434f1bc78362 category changes
Claus Gittinger <cg@exept.de>
parents: 266
diff changeset
   310
!
434f1bc78362 category changes
Claus Gittinger <cg@exept.de>
parents: 266
diff changeset
   311
434f1bc78362 category changes
Claus Gittinger <cg@exept.de>
parents: 266
diff changeset
   312
top
434f1bc78362 category changes
Claus Gittinger <cg@exept.de>
parents: 266
diff changeset
   313
    "return my top y coordinate"
434f1bc78362 category changes
Claus Gittinger <cg@exept.de>
parents: 266
diff changeset
   314
434f1bc78362 category changes
Claus Gittinger <cg@exept.de>
parents: 266
diff changeset
   315
    ^ self bounds top
434f1bc78362 category changes
Claus Gittinger <cg@exept.de>
parents: 266
diff changeset
   316
434f1bc78362 category changes
Claus Gittinger <cg@exept.de>
parents: 266
diff changeset
   317
    "Modified: 9.5.1996 / 00:13:12 / cg"
434f1bc78362 category changes
Claus Gittinger <cg@exept.de>
parents: 266
diff changeset
   318
    "Created: 26.5.1996 / 12:56:15 / cg"
321
6421da8810e2 more view mimicri;
Claus Gittinger <cg@exept.de>
parents: 293
diff changeset
   319
!
6421da8810e2 more view mimicri;
Claus Gittinger <cg@exept.de>
parents: 293
diff changeset
   320
6421da8810e2 more view mimicri;
Claus Gittinger <cg@exept.de>
parents: 293
diff changeset
   321
viewRectangle
6421da8810e2 more view mimicri;
Claus Gittinger <cg@exept.de>
parents: 293
diff changeset
   322
    ^ self bounds
6421da8810e2 more view mimicri;
Claus Gittinger <cg@exept.de>
parents: 293
diff changeset
   323
6421da8810e2 more view mimicri;
Claus Gittinger <cg@exept.de>
parents: 293
diff changeset
   324
    "Created: 19.7.1996 / 17:24:58 / cg"
245
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   325
! !
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   326
293
d10ad10d23fa prepare for view-component integration
Claus Gittinger <cg@exept.de>
parents: 291
diff changeset
   327
!VisualComponent methodsFor:'accessing-mvc'!
d10ad10d23fa prepare for view-component integration
Claus Gittinger <cg@exept.de>
parents: 291
diff changeset
   328
d10ad10d23fa prepare for view-component integration
Claus Gittinger <cg@exept.de>
parents: 291
diff changeset
   329
model
d10ad10d23fa prepare for view-component integration
Claus Gittinger <cg@exept.de>
parents: 291
diff changeset
   330
    "return nil - generic components have no model"
d10ad10d23fa prepare for view-component integration
Claus Gittinger <cg@exept.de>
parents: 291
diff changeset
   331
d10ad10d23fa prepare for view-component integration
Claus Gittinger <cg@exept.de>
parents: 291
diff changeset
   332
    ^ nil
d10ad10d23fa prepare for view-component integration
Claus Gittinger <cg@exept.de>
parents: 291
diff changeset
   333
d10ad10d23fa prepare for view-component integration
Claus Gittinger <cg@exept.de>
parents: 291
diff changeset
   334
    "Created: 5.6.1996 / 14:18:16 / cg"
d10ad10d23fa prepare for view-component integration
Claus Gittinger <cg@exept.de>
parents: 291
diff changeset
   335
! !
d10ad10d23fa prepare for view-component integration
Claus Gittinger <cg@exept.de>
parents: 291
diff changeset
   336
2127
0d47162b692b *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1789
diff changeset
   337
!VisualComponent methodsFor:'change & update'!
0d47162b692b *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1789
diff changeset
   338
0d47162b692b *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1789
diff changeset
   339
changedPreferredBounds: oldPreferredBoundsOrNil
0d47162b692b *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1789
diff changeset
   340
    "The receiver is notifying any dependents that its preferredBounds has changed."
0d47162b692b *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1789
diff changeset
   341
0d47162b692b *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1789
diff changeset
   342
    self changed: #preferredBounds with: oldPreferredBoundsOrNil
0d47162b692b *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1789
diff changeset
   343
! !
0d47162b692b *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1789
diff changeset
   344
265
45c83acd7562 comments
Claus Gittinger <cg@exept.de>
parents: 250
diff changeset
   345
!VisualComponent methodsFor:'displaying'!
45c83acd7562 comments
Claus Gittinger <cg@exept.de>
parents: 250
diff changeset
   346
2210
d50fff3f6898 *** empty log message ***
fm
parents: 2127
diff changeset
   347
displayOn:aGCOrStream
406
16d990bcde6e removed fg/bgColor
Claus Gittinger <cg@exept.de>
parents: 365
diff changeset
   348
    "display the receiver on some graphicsContext. 
16d990bcde6e removed fg/bgColor
Claus Gittinger <cg@exept.de>
parents: 365
diff changeset
   349
     The sender is repsonsible for restoring the GC's state
16d990bcde6e removed fg/bgColor
Claus Gittinger <cg@exept.de>
parents: 365
diff changeset
   350
     (i.e. it may be left in any undefined state)"
16d990bcde6e removed fg/bgColor
Claus Gittinger <cg@exept.de>
parents: 365
diff changeset
   351
2210
d50fff3f6898 *** empty log message ***
fm
parents: 2127
diff changeset
   352
    "/ what a kludge - Dolphin and Squeak mean: printOn: a stream;
d50fff3f6898 *** empty log message ***
fm
parents: 2127
diff changeset
   353
    "/ ST/X (and some old ST80's) mean: draw-yourself on a GC.
d50fff3f6898 *** empty log message ***
fm
parents: 2127
diff changeset
   354
    (aGCOrStream isStream or:[aGCOrStream == Transcript]) ifTrue:[
d50fff3f6898 *** empty log message ***
fm
parents: 2127
diff changeset
   355
        self printOn:aGCOrStream.
d50fff3f6898 *** empty log message ***
fm
parents: 2127
diff changeset
   356
        ^ self
d50fff3f6898 *** empty log message ***
fm
parents: 2127
diff changeset
   357
    ].
406
16d990bcde6e removed fg/bgColor
Claus Gittinger <cg@exept.de>
parents: 365
diff changeset
   358
    self subclassResponsibility
16d990bcde6e removed fg/bgColor
Claus Gittinger <cg@exept.de>
parents: 365
diff changeset
   359
2210
d50fff3f6898 *** empty log message ***
fm
parents: 2127
diff changeset
   360
    "Modified: / 10-02-1997 / 13:53:03 / cg"
d50fff3f6898 *** empty log message ***
fm
parents: 2127
diff changeset
   361
    "Modified: / 11-09-2006 / 15:01:06 / User"
406
16d990bcde6e removed fg/bgColor
Claus Gittinger <cg@exept.de>
parents: 365
diff changeset
   362
!
16d990bcde6e removed fg/bgColor
Claus Gittinger <cg@exept.de>
parents: 365
diff changeset
   363
16d990bcde6e removed fg/bgColor
Claus Gittinger <cg@exept.de>
parents: 365
diff changeset
   364
displayOn:aGC at:aPoint
16d990bcde6e removed fg/bgColor
Claus Gittinger <cg@exept.de>
parents: 365
diff changeset
   365
    "display the receiver translated by some amount on some graphicsContext"
16d990bcde6e removed fg/bgColor
Claus Gittinger <cg@exept.de>
parents: 365
diff changeset
   366
265
45c83acd7562 comments
Claus Gittinger <cg@exept.de>
parents: 250
diff changeset
   367
    |oldTranslation|
45c83acd7562 comments
Claus Gittinger <cg@exept.de>
parents: 250
diff changeset
   368
45c83acd7562 comments
Claus Gittinger <cg@exept.de>
parents: 250
diff changeset
   369
    oldTranslation := aGC translation.
406
16d990bcde6e removed fg/bgColor
Claus Gittinger <cg@exept.de>
parents: 365
diff changeset
   370
    aGC translateBy:aPoint.
265
45c83acd7562 comments
Claus Gittinger <cg@exept.de>
parents: 250
diff changeset
   371
    self displayOn:aGC.
45c83acd7562 comments
Claus Gittinger <cg@exept.de>
parents: 250
diff changeset
   372
    aGC translation:oldTranslation
45c83acd7562 comments
Claus Gittinger <cg@exept.de>
parents: 250
diff changeset
   373
406
16d990bcde6e removed fg/bgColor
Claus Gittinger <cg@exept.de>
parents: 365
diff changeset
   374
    "Created: 10.2.1997 / 13:47:18 / cg"
16d990bcde6e removed fg/bgColor
Claus Gittinger <cg@exept.de>
parents: 365
diff changeset
   375
    "Modified: 10.2.1997 / 13:52:53 / cg"
16d990bcde6e removed fg/bgColor
Claus Gittinger <cg@exept.de>
parents: 365
diff changeset
   376
!
16d990bcde6e removed fg/bgColor
Claus Gittinger <cg@exept.de>
parents: 365
diff changeset
   377
16d990bcde6e removed fg/bgColor
Claus Gittinger <cg@exept.de>
parents: 365
diff changeset
   378
displayOn:aGC x:x y:y
16d990bcde6e removed fg/bgColor
Claus Gittinger <cg@exept.de>
parents: 365
diff changeset
   379
    "display the receiver translated by some amount on some graphicsContext"
16d990bcde6e removed fg/bgColor
Claus Gittinger <cg@exept.de>
parents: 365
diff changeset
   380
16d990bcde6e removed fg/bgColor
Claus Gittinger <cg@exept.de>
parents: 365
diff changeset
   381
    ^ self displayOn:aGC at:(x @ y).
16d990bcde6e removed fg/bgColor
Claus Gittinger <cg@exept.de>
parents: 365
diff changeset
   382
16d990bcde6e removed fg/bgColor
Claus Gittinger <cg@exept.de>
parents: 365
diff changeset
   383
    "Modified: 10.2.1997 / 13:52:57 / cg"
265
45c83acd7562 comments
Claus Gittinger <cg@exept.de>
parents: 250
diff changeset
   384
! !
45c83acd7562 comments
Claus Gittinger <cg@exept.de>
parents: 250
diff changeset
   385
245
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   386
!VisualComponent methodsFor:'event handling'!
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   387
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   388
buttonPress:button x:x y:y
246
9f80dbcbcd34 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 245
diff changeset
   389
    "button was pressed over me - ignored here"
245
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   390
246
9f80dbcbcd34 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 245
diff changeset
   391
    "Modified: 9.5.1996 / 00:14:08 / cg"
245
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   392
!
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   393
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   394
buttonRelease:button x:x y:y
246
9f80dbcbcd34 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 245
diff changeset
   395
    "button was released over me - ignored here"
245
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   396
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   397
    "Created: 8.5.1996 / 23:38:30 / cg"
246
9f80dbcbcd34 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 245
diff changeset
   398
    "Modified: 9.5.1996 / 00:14:04 / cg"
245
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   399
!
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   400
321
6421da8810e2 more view mimicri;
Claus Gittinger <cg@exept.de>
parents: 293
diff changeset
   401
containerChangedSize
6421da8810e2 more view mimicri;
Claus Gittinger <cg@exept.de>
parents: 293
diff changeset
   402
6421da8810e2 more view mimicri;
Claus Gittinger <cg@exept.de>
parents: 293
diff changeset
   403
    "Created: 19.7.1996 / 17:32:19 / cg"
6421da8810e2 more view mimicri;
Claus Gittinger <cg@exept.de>
parents: 293
diff changeset
   404
!
6421da8810e2 more view mimicri;
Claus Gittinger <cg@exept.de>
parents: 293
diff changeset
   405
6421da8810e2 more view mimicri;
Claus Gittinger <cg@exept.de>
parents: 293
diff changeset
   406
containerMapped
6421da8810e2 more view mimicri;
Claus Gittinger <cg@exept.de>
parents: 293
diff changeset
   407
6421da8810e2 more view mimicri;
Claus Gittinger <cg@exept.de>
parents: 293
diff changeset
   408
    "Created: 19.7.1996 / 17:39:27 / cg"
6421da8810e2 more view mimicri;
Claus Gittinger <cg@exept.de>
parents: 293
diff changeset
   409
!
6421da8810e2 more view mimicri;
Claus Gittinger <cg@exept.de>
parents: 293
diff changeset
   410
6421da8810e2 more view mimicri;
Claus Gittinger <cg@exept.de>
parents: 293
diff changeset
   411
containerUnmapped
6421da8810e2 more view mimicri;
Claus Gittinger <cg@exept.de>
parents: 293
diff changeset
   412
6421da8810e2 more view mimicri;
Claus Gittinger <cg@exept.de>
parents: 293
diff changeset
   413
    "Created: 19.7.1996 / 17:44:52 / cg"
6421da8810e2 more view mimicri;
Claus Gittinger <cg@exept.de>
parents: 293
diff changeset
   414
!
6421da8810e2 more view mimicri;
Claus Gittinger <cg@exept.de>
parents: 293
diff changeset
   415
6421da8810e2 more view mimicri;
Claus Gittinger <cg@exept.de>
parents: 293
diff changeset
   416
destroy
6421da8810e2 more view mimicri;
Claus Gittinger <cg@exept.de>
parents: 293
diff changeset
   417
6421da8810e2 more view mimicri;
Claus Gittinger <cg@exept.de>
parents: 293
diff changeset
   418
    "Created: 19.7.1996 / 17:25:46 / cg"
6421da8810e2 more view mimicri;
Claus Gittinger <cg@exept.de>
parents: 293
diff changeset
   419
!
6421da8810e2 more view mimicri;
Claus Gittinger <cg@exept.de>
parents: 293
diff changeset
   420
2127
0d47162b692b *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1789
diff changeset
   421
hasKeyboardFocus:aBoolean
0d47162b692b *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1789
diff changeset
   422
    "notification from the windowGroup that I got the keyboardFocus."
0d47162b692b *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1789
diff changeset
   423
0d47162b692b *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1789
diff changeset
   424
    ^ self
0d47162b692b *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1789
diff changeset
   425
0d47162b692b *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1789
diff changeset
   426
    "Created: / 6.7.1998 / 13:49:12 / cg"
0d47162b692b *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1789
diff changeset
   427
!
0d47162b692b *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1789
diff changeset
   428
245
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   429
keyPress:key x:x y:y
246
9f80dbcbcd34 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 245
diff changeset
   430
    "key was pressed over me - ignored here"
245
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   431
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   432
    "Created: 8.5.1996 / 23:46:03 / cg"
246
9f80dbcbcd34 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 245
diff changeset
   433
    "Modified: 9.5.1996 / 00:14:14 / cg"
245
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   434
!
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   435
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   436
keyRelease:key x:x y:y
246
9f80dbcbcd34 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 245
diff changeset
   437
    "key was released over me - ignored here"
245
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   438
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   439
    "Created: 8.5.1996 / 23:46:07 / cg"
246
9f80dbcbcd34 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 245
diff changeset
   440
    "Modified: 9.5.1996 / 00:14:19 / cg"
994
1b606988c010 more ST80/STX compatibility
Claus Gittinger <cg@exept.de>
parents: 962
diff changeset
   441
!
1b606988c010 more ST80/STX compatibility
Claus Gittinger <cg@exept.de>
parents: 962
diff changeset
   442
1b606988c010 more ST80/STX compatibility
Claus Gittinger <cg@exept.de>
parents: 962
diff changeset
   443
mapped
1b606988c010 more ST80/STX compatibility
Claus Gittinger <cg@exept.de>
parents: 962
diff changeset
   444
1b606988c010 more ST80/STX compatibility
Claus Gittinger <cg@exept.de>
parents: 962
diff changeset
   445
    "Created: / 6.7.1998 / 13:48:46 / cg"
1b606988c010 more ST80/STX compatibility
Claus Gittinger <cg@exept.de>
parents: 962
diff changeset
   446
!
1b606988c010 more ST80/STX compatibility
Claus Gittinger <cg@exept.de>
parents: 962
diff changeset
   447
1b606988c010 more ST80/STX compatibility
Claus Gittinger <cg@exept.de>
parents: 962
diff changeset
   448
showFocus:explicit
1b606988c010 more ST80/STX compatibility
Claus Gittinger <cg@exept.de>
parents: 962
diff changeset
   449
1b606988c010 more ST80/STX compatibility
Claus Gittinger <cg@exept.de>
parents: 962
diff changeset
   450
    "Created: / 6.7.1998 / 13:49:05 / cg"
1b606988c010 more ST80/STX compatibility
Claus Gittinger <cg@exept.de>
parents: 962
diff changeset
   451
!
1b606988c010 more ST80/STX compatibility
Claus Gittinger <cg@exept.de>
parents: 962
diff changeset
   452
1b606988c010 more ST80/STX compatibility
Claus Gittinger <cg@exept.de>
parents: 962
diff changeset
   453
showNoFocus:explicit
1b606988c010 more ST80/STX compatibility
Claus Gittinger <cg@exept.de>
parents: 962
diff changeset
   454
1b606988c010 more ST80/STX compatibility
Claus Gittinger <cg@exept.de>
parents: 962
diff changeset
   455
    "Created: / 6.7.1998 / 13:49:12 / cg"
245
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   456
! !
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   457
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   458
!VisualComponent methodsFor:'initialization'!
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   459
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   460
initialize
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   461
406
16d990bcde6e removed fg/bgColor
Claus Gittinger <cg@exept.de>
parents: 365
diff changeset
   462
    "Modified: 10.2.1997 / 19:28:11 / cg"
245
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   463
! !
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   464
265
45c83acd7562 comments
Claus Gittinger <cg@exept.de>
parents: 250
diff changeset
   465
!VisualComponent methodsFor:'queries'!
45c83acd7562 comments
Claus Gittinger <cg@exept.de>
parents: 250
diff changeset
   466
994
1b606988c010 more ST80/STX compatibility
Claus Gittinger <cg@exept.de>
parents: 962
diff changeset
   467
delegate
1b606988c010 more ST80/STX compatibility
Claus Gittinger <cg@exept.de>
parents: 962
diff changeset
   468
    ^ nil
1b606988c010 more ST80/STX compatibility
Claus Gittinger <cg@exept.de>
parents: 962
diff changeset
   469
1b606988c010 more ST80/STX compatibility
Claus Gittinger <cg@exept.de>
parents: 962
diff changeset
   470
    "Created: / 6.7.1998 / 13:50:10 / cg"
1b606988c010 more ST80/STX compatibility
Claus Gittinger <cg@exept.de>
parents: 962
diff changeset
   471
!
1b606988c010 more ST80/STX compatibility
Claus Gittinger <cg@exept.de>
parents: 962
diff changeset
   472
265
45c83acd7562 comments
Claus Gittinger <cg@exept.de>
parents: 250
diff changeset
   473
heightOn:aGC
45c83acd7562 comments
Claus Gittinger <cg@exept.de>
parents: 250
diff changeset
   474
    "return my height, if displayed on aGC;
45c83acd7562 comments
Claus Gittinger <cg@exept.de>
parents: 250
diff changeset
   475
     I assume that my height is independent of the device, and return
45c83acd7562 comments
Claus Gittinger <cg@exept.de>
parents: 250
diff changeset
   476
     the bounds height"
45c83acd7562 comments
Claus Gittinger <cg@exept.de>
parents: 250
diff changeset
   477
45c83acd7562 comments
Claus Gittinger <cg@exept.de>
parents: 250
diff changeset
   478
    ^ self bounds height
45c83acd7562 comments
Claus Gittinger <cg@exept.de>
parents: 250
diff changeset
   479
45c83acd7562 comments
Claus Gittinger <cg@exept.de>
parents: 250
diff changeset
   480
    "Modified: 13.5.1996 / 10:15:13 / cg"
45c83acd7562 comments
Claus Gittinger <cg@exept.de>
parents: 250
diff changeset
   481
!
45c83acd7562 comments
Claus Gittinger <cg@exept.de>
parents: 250
diff changeset
   482
290
d26dc55ac7e4 prepare for components & non-view as superView
Claus Gittinger <cg@exept.de>
parents: 274
diff changeset
   483
isBorderedWrapper
d26dc55ac7e4 prepare for components & non-view as superView
Claus Gittinger <cg@exept.de>
parents: 274
diff changeset
   484
     ^ false
d26dc55ac7e4 prepare for components & non-view as superView
Claus Gittinger <cg@exept.de>
parents: 274
diff changeset
   485
d26dc55ac7e4 prepare for components & non-view as superView
Claus Gittinger <cg@exept.de>
parents: 274
diff changeset
   486
    "Created: 5.6.1996 / 14:11:18 / cg"
d26dc55ac7e4 prepare for components & non-view as superView
Claus Gittinger <cg@exept.de>
parents: 274
diff changeset
   487
!
d26dc55ac7e4 prepare for components & non-view as superView
Claus Gittinger <cg@exept.de>
parents: 274
diff changeset
   488
2127
0d47162b692b *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1789
diff changeset
   489
isCursorKeyConsumer
0d47162b692b *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1789
diff changeset
   490
     ^ false
0d47162b692b *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1789
diff changeset
   491
!
0d47162b692b *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1789
diff changeset
   492
1220
39e5e28042da protocol fixes to make examples work again
Claus Gittinger <cg@exept.de>
parents: 994
diff changeset
   493
isExternalTopView
39e5e28042da protocol fixes to make examples work again
Claus Gittinger <cg@exept.de>
parents: 994
diff changeset
   494
    ^ false
39e5e28042da protocol fixes to make examples work again
Claus Gittinger <cg@exept.de>
parents: 994
diff changeset
   495
39e5e28042da protocol fixes to make examples work again
Claus Gittinger <cg@exept.de>
parents: 994
diff changeset
   496
    "Created: / 6.7.1998 / 13:50:01 / cg"
39e5e28042da protocol fixes to make examples work again
Claus Gittinger <cg@exept.de>
parents: 994
diff changeset
   497
!
39e5e28042da protocol fixes to make examples work again
Claus Gittinger <cg@exept.de>
parents: 994
diff changeset
   498
39e5e28042da protocol fixes to make examples work again
Claus Gittinger <cg@exept.de>
parents: 994
diff changeset
   499
isInputField
39e5e28042da protocol fixes to make examples work again
Claus Gittinger <cg@exept.de>
parents: 994
diff changeset
   500
     ^ false
39e5e28042da protocol fixes to make examples work again
Claus Gittinger <cg@exept.de>
parents: 994
diff changeset
   501
39e5e28042da protocol fixes to make examples work again
Claus Gittinger <cg@exept.de>
parents: 994
diff changeset
   502
    "Created: 19.7.1996 / 17:50:59 / cg"
39e5e28042da protocol fixes to make examples work again
Claus Gittinger <cg@exept.de>
parents: 994
diff changeset
   503
!
39e5e28042da protocol fixes to make examples work again
Claus Gittinger <cg@exept.de>
parents: 994
diff changeset
   504
39e5e28042da protocol fixes to make examples work again
Claus Gittinger <cg@exept.de>
parents: 994
diff changeset
   505
isKeyboardConsumer
39e5e28042da protocol fixes to make examples work again
Claus Gittinger <cg@exept.de>
parents: 994
diff changeset
   506
     ^ false
39e5e28042da protocol fixes to make examples work again
Claus Gittinger <cg@exept.de>
parents: 994
diff changeset
   507
39e5e28042da protocol fixes to make examples work again
Claus Gittinger <cg@exept.de>
parents: 994
diff changeset
   508
    "Created: 19.7.1996 / 17:50:59 / cg"
39e5e28042da protocol fixes to make examples work again
Claus Gittinger <cg@exept.de>
parents: 994
diff changeset
   509
!
39e5e28042da protocol fixes to make examples work again
Claus Gittinger <cg@exept.de>
parents: 994
diff changeset
   510
321
6421da8810e2 more view mimicri;
Claus Gittinger <cg@exept.de>
parents: 293
diff changeset
   511
isLayoutWrapper
6421da8810e2 more view mimicri;
Claus Gittinger <cg@exept.de>
parents: 293
diff changeset
   512
     ^ false
6421da8810e2 more view mimicri;
Claus Gittinger <cg@exept.de>
parents: 293
diff changeset
   513
6421da8810e2 more view mimicri;
Claus Gittinger <cg@exept.de>
parents: 293
diff changeset
   514
    "Created: 19.7.1996 / 17:50:59 / cg"
6421da8810e2 more view mimicri;
Claus Gittinger <cg@exept.de>
parents: 293
diff changeset
   515
!
6421da8810e2 more view mimicri;
Claus Gittinger <cg@exept.de>
parents: 293
diff changeset
   516
994
1b606988c010 more ST80/STX compatibility
Claus Gittinger <cg@exept.de>
parents: 962
diff changeset
   517
isRootView
1b606988c010 more ST80/STX compatibility
Claus Gittinger <cg@exept.de>
parents: 962
diff changeset
   518
    ^ false
1b606988c010 more ST80/STX compatibility
Claus Gittinger <cg@exept.de>
parents: 962
diff changeset
   519
1b606988c010 more ST80/STX compatibility
Claus Gittinger <cg@exept.de>
parents: 962
diff changeset
   520
    "Created: / 6.7.1998 / 13:50:01 / cg"
1b606988c010 more ST80/STX compatibility
Claus Gittinger <cg@exept.de>
parents: 962
diff changeset
   521
!
1b606988c010 more ST80/STX compatibility
Claus Gittinger <cg@exept.de>
parents: 962
diff changeset
   522
2667
523afff34647 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2664
diff changeset
   523
isTransparentBox
523afff34647 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2664
diff changeset
   524
     ^ false
523afff34647 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2664
diff changeset
   525
523afff34647 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2664
diff changeset
   526
    "Created: 19.7.1996 / 17:50:59 / cg"
523afff34647 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2664
diff changeset
   527
!
523afff34647 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2664
diff changeset
   528
290
d26dc55ac7e4 prepare for components & non-view as superView
Claus Gittinger <cg@exept.de>
parents: 274
diff changeset
   529
isWrapper
d26dc55ac7e4 prepare for components & non-view as superView
Claus Gittinger <cg@exept.de>
parents: 274
diff changeset
   530
     ^ false
d26dc55ac7e4 prepare for components & non-view as superView
Claus Gittinger <cg@exept.de>
parents: 274
diff changeset
   531
d26dc55ac7e4 prepare for components & non-view as superView
Claus Gittinger <cg@exept.de>
parents: 274
diff changeset
   532
    "Created: 5.6.1996 / 01:04:40 / cg"
d26dc55ac7e4 prepare for components & non-view as superView
Claus Gittinger <cg@exept.de>
parents: 274
diff changeset
   533
!
d26dc55ac7e4 prepare for components & non-view as superView
Claus Gittinger <cg@exept.de>
parents: 274
diff changeset
   534
265
45c83acd7562 comments
Claus Gittinger <cg@exept.de>
parents: 250
diff changeset
   535
widthOn:aGC
45c83acd7562 comments
Claus Gittinger <cg@exept.de>
parents: 250
diff changeset
   536
    "return my width, if displayed on aGC;
45c83acd7562 comments
Claus Gittinger <cg@exept.de>
parents: 250
diff changeset
   537
     I assume that my width is independent of the device, and return
45c83acd7562 comments
Claus Gittinger <cg@exept.de>
parents: 250
diff changeset
   538
     the bounds width"
45c83acd7562 comments
Claus Gittinger <cg@exept.de>
parents: 250
diff changeset
   539
45c83acd7562 comments
Claus Gittinger <cg@exept.de>
parents: 250
diff changeset
   540
    ^ self bounds width
45c83acd7562 comments
Claus Gittinger <cg@exept.de>
parents: 250
diff changeset
   541
45c83acd7562 comments
Claus Gittinger <cg@exept.de>
parents: 250
diff changeset
   542
    "Created: 13.5.1996 / 10:14:44 / cg"
45c83acd7562 comments
Claus Gittinger <cg@exept.de>
parents: 250
diff changeset
   543
    "Modified: 13.5.1996 / 10:15:17 / cg"
45c83acd7562 comments
Claus Gittinger <cg@exept.de>
parents: 250
diff changeset
   544
! !
45c83acd7562 comments
Claus Gittinger <cg@exept.de>
parents: 250
diff changeset
   545
247
7b29d5a02e68 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 246
diff changeset
   546
!VisualComponent methodsFor:'testing'!
7b29d5a02e68 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 246
diff changeset
   547
7b29d5a02e68 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 246
diff changeset
   548
containsPoint:aPoint
7b29d5a02e68 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 246
diff changeset
   549
    "return true, if the receiver contains aPoint"
7b29d5a02e68 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 246
diff changeset
   550
7b29d5a02e68 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 246
diff changeset
   551
    ^ self bounds containsPoint:aPoint
7b29d5a02e68 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 246
diff changeset
   552
7b29d5a02e68 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 246
diff changeset
   553
    "Created: 9.5.1996 / 00:21:44 / cg"
7b29d5a02e68 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 246
diff changeset
   554
    "Modified: 9.5.1996 / 00:22:00 / cg"
7b29d5a02e68 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 246
diff changeset
   555
!
7b29d5a02e68 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 246
diff changeset
   556
7b29d5a02e68 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 246
diff changeset
   557
hasBorder
7b29d5a02e68 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 246
diff changeset
   558
    "return true, if the receiver shows a border"
7b29d5a02e68 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 246
diff changeset
   559
7b29d5a02e68 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 246
diff changeset
   560
    ^ false
7b29d5a02e68 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 246
diff changeset
   561
7b29d5a02e68 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 246
diff changeset
   562
    "Modified: 9.5.1996 / 00:21:29 / cg"
7b29d5a02e68 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 246
diff changeset
   563
!
7b29d5a02e68 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 246
diff changeset
   564
7b29d5a02e68 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 246
diff changeset
   565
intersects:aRectangle
7b29d5a02e68 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 246
diff changeset
   566
    "return true, if the receivers bounds intersects aRectangle"
7b29d5a02e68 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 246
diff changeset
   567
7b29d5a02e68 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 246
diff changeset
   568
    ^ self bounds intersects:aRectangle
7b29d5a02e68 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 246
diff changeset
   569
7b29d5a02e68 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 246
diff changeset
   570
    "Created: 9.5.1996 / 00:21:18 / cg"
7b29d5a02e68 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 246
diff changeset
   571
    "Modified: 9.5.1996 / 00:22:04 / cg"
7b29d5a02e68 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 246
diff changeset
   572
! !
7b29d5a02e68 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 246
diff changeset
   573
365
47e0d48fd769 commentary
Claus Gittinger <cg@exept.de>
parents: 323
diff changeset
   574
!VisualComponent class methodsFor:'documentation'!
245
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   575
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   576
version
2682
578ccaf16564 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2669
diff changeset
   577
    ^ '$Header: /cvs/stx/stx/libview2/VisualComponent.st,v 1.27 2009-05-18 14:03:47 cg Exp $'
245
8d7f9a8d2c78 intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   578
! !