HostGraphicsDevice.st
author Claus Gittinger <cg@exept.de>
Sat, 09 Oct 1999 15:19:39 +0200
changeset 2961 3f5a60b6e06c
parent 2847 8ef5b35346ff
child 3285 b39fff2bf608
permissions -rw-r--r--
checkin from browser
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
1284
d17f4d91174d intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
     1
"
d17f4d91174d intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
     2
COPYRIGHT (c) 1997 by eXept Software AG / Claus Gittinger
2840
c8f5ba536263 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2839
diff changeset
     3
	      All Rights Reserved
1284
d17f4d91174d intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
     4
d17f4d91174d intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
     5
 This software is furnished under a license and may be used
d17f4d91174d intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
     6
 only in accordance with the terms of that license and with the
d17f4d91174d intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
     7
 inclusion of the above copyright notice.   This software may not
d17f4d91174d intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
     8
 be provided or otherwise made available to, or used by, any
d17f4d91174d intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
     9
 other person.  No title to or ownership of the software is
d17f4d91174d intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    10
 hereby transferred.
d17f4d91174d intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    11
"
d17f4d91174d intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    12
d17f4d91174d intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    13
d17f4d91174d intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    14
d17f4d91174d intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    15
GraphicsDevice subclass:#HostGraphicsDevice
2840
c8f5ba536263 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2839
diff changeset
    16
	instanceVariableNames:'deviceColors deviceFonts deviceViews deviceForms deviceCursors'
1284
d17f4d91174d intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    17
	classVariableNames:''
d17f4d91174d intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    18
	poolDictionaries:''
d17f4d91174d intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    19
	category:'Interface-Graphics'
d17f4d91174d intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    20
!
d17f4d91174d intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    21
d17f4d91174d intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    22
!HostGraphicsDevice class methodsFor:'documentation'!
d17f4d91174d intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    23
d17f4d91174d intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    24
copyright
d17f4d91174d intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    25
"
d17f4d91174d intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    26
COPYRIGHT (c) 1997 by eXept Software AG / Claus Gittinger
2840
c8f5ba536263 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2839
diff changeset
    27
	      All Rights Reserved
1284
d17f4d91174d intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    28
d17f4d91174d intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    29
 This software is furnished under a license and may be used
d17f4d91174d intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    30
 only in accordance with the terms of that license and with the
d17f4d91174d intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    31
 inclusion of the above copyright notice.   This software may not
d17f4d91174d intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    32
 be provided or otherwise made available to, or used by, any
d17f4d91174d intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    33
 other person.  No title to or ownership of the software is
d17f4d91174d intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    34
 hereby transferred.
d17f4d91174d intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    35
"
d17f4d91174d intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    36
d17f4d91174d intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    37
d17f4d91174d intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    38
!
d17f4d91174d intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    39
d17f4d91174d intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    40
documentation
d17f4d91174d intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    41
"
d17f4d91174d intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    42
    this abstract class was inserted to provide a home for ST-80 classes
d17f4d91174d intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    43
    (previously, DeviceWorkstation was directly under Object).
2813
913aca399962 preps to keep the view & form lobbies on a per-display basis.
Claus Gittinger <cg@exept.de>
parents: 2809
diff changeset
    44
    We will (over time) move common functionality from there into this class.
1284
d17f4d91174d intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    45
d17f4d91174d intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    46
    In ST/X, this is mostly dummy.
d17f4d91174d intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    47
d17f4d91174d intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    48
    [see also:]
2840
c8f5ba536263 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2839
diff changeset
    49
	DeviceWorkstation XWorkstation
1284
d17f4d91174d intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    50
d17f4d91174d intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    51
    [author:]
2840
c8f5ba536263 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2839
diff changeset
    52
	Claus Gittinger
1284
d17f4d91174d intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    53
"
d17f4d91174d intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    54
d17f4d91174d intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    55
d17f4d91174d intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    56
! !
d17f4d91174d intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    57
2961
3f5a60b6e06c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2847
diff changeset
    58
!HostGraphicsDevice methodsFor:'Compatibility - Squeak'!
3f5a60b6e06c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2847
diff changeset
    59
3f5a60b6e06c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2847
diff changeset
    60
deferUpdates: aBoolean
3f5a60b6e06c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2847
diff changeset
    61
    "Set the deferUpdates flag in the virtual machine. 
3f5a60b6e06c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2847
diff changeset
    62
     When this flag is true, BitBlt operations on the Display are not 
3f5a60b6e06c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2847
diff changeset
    63
     automatically propagated to the screen. 
3f5a60b6e06c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2847
diff changeset
    64
     If this underlying platform does not support deferred updates, 
3f5a60b6e06c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2847
diff changeset
    65
     this primitive will fail. 
3f5a60b6e06c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2847
diff changeset
    66
     Answer the receiver if the primitive succeeds, nil if it fails."
3f5a60b6e06c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2847
diff changeset
    67
3f5a60b6e06c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2847
diff changeset
    68
"/    <primitive: 126>
3f5a60b6e06c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2847
diff changeset
    69
    ^ nil  "answer nil if primitive fails"
3f5a60b6e06c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2847
diff changeset
    70
3f5a60b6e06c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2847
diff changeset
    71
!
3f5a60b6e06c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2847
diff changeset
    72
3f5a60b6e06c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2847
diff changeset
    73
forceDisplayUpdate
3f5a60b6e06c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2847
diff changeset
    74
    "On platforms that buffer screen updates, 
3f5a60b6e06c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2847
diff changeset
    75
     force the screen to be updated immediately. 
3f5a60b6e06c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2847
diff changeset
    76
     On other platforms, or if the primitive is not implemented, do nothing."
3f5a60b6e06c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2847
diff changeset
    77
3f5a60b6e06c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2847
diff changeset
    78
"/     <primitive: 231>
3f5a60b6e06c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2847
diff changeset
    79
    "do nothing if primitive fails"
3f5a60b6e06c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2847
diff changeset
    80
! !
3f5a60b6e06c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2847
diff changeset
    81
1365
37a9e7ac4dbc moved color registration from Color class to per-device lobby
Claus Gittinger <cg@exept.de>
parents: 1315
diff changeset
    82
!HostGraphicsDevice methodsFor:'accessing'!
37a9e7ac4dbc moved color registration from Color class to per-device lobby
Claus Gittinger <cg@exept.de>
parents: 1315
diff changeset
    83
37a9e7ac4dbc moved color registration from Color class to per-device lobby
Claus Gittinger <cg@exept.de>
parents: 1315
diff changeset
    84
deviceColors
1371
22f586987cd1 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1367
diff changeset
    85
    "return the registry keeping track of colors which were allocated
2813
913aca399962 preps to keep the view & form lobbies on a per-display basis.
Claus Gittinger <cg@exept.de>
parents: 2809
diff changeset
    86
     on this device."
1365
37a9e7ac4dbc moved color registration from Color class to per-device lobby
Claus Gittinger <cg@exept.de>
parents: 1315
diff changeset
    87
37a9e7ac4dbc moved color registration from Color class to per-device lobby
Claus Gittinger <cg@exept.de>
parents: 1315
diff changeset
    88
    ^ deviceColors
37a9e7ac4dbc moved color registration from Color class to per-device lobby
Claus Gittinger <cg@exept.de>
parents: 1315
diff changeset
    89
37a9e7ac4dbc moved color registration from Color class to per-device lobby
Claus Gittinger <cg@exept.de>
parents: 1315
diff changeset
    90
    "Created: 24.2.1997 / 18:01:41 / cg"
37a9e7ac4dbc moved color registration from Color class to per-device lobby
Claus Gittinger <cg@exept.de>
parents: 1315
diff changeset
    91
!
37a9e7ac4dbc moved color registration from Color class to per-device lobby
Claus Gittinger <cg@exept.de>
parents: 1315
diff changeset
    92
2843
e13e0c53924a keep registry of cursors here - no longer use a Cursor Lobby
Claus Gittinger <cg@exept.de>
parents: 2840
diff changeset
    93
deviceCursors
e13e0c53924a keep registry of cursors here - no longer use a Cursor Lobby
Claus Gittinger <cg@exept.de>
parents: 2840
diff changeset
    94
    "return the registry keeping track of cursors which were allocated
e13e0c53924a keep registry of cursors here - no longer use a Cursor Lobby
Claus Gittinger <cg@exept.de>
parents: 2840
diff changeset
    95
     on this device."
e13e0c53924a keep registry of cursors here - no longer use a Cursor Lobby
Claus Gittinger <cg@exept.de>
parents: 2840
diff changeset
    96
e13e0c53924a keep registry of cursors here - no longer use a Cursor Lobby
Claus Gittinger <cg@exept.de>
parents: 2840
diff changeset
    97
    ^ deviceCursors
e13e0c53924a keep registry of cursors here - no longer use a Cursor Lobby
Claus Gittinger <cg@exept.de>
parents: 2840
diff changeset
    98
e13e0c53924a keep registry of cursors here - no longer use a Cursor Lobby
Claus Gittinger <cg@exept.de>
parents: 2840
diff changeset
    99
    "Created: 24.2.1997 / 18:01:41 / cg"
e13e0c53924a keep registry of cursors here - no longer use a Cursor Lobby
Claus Gittinger <cg@exept.de>
parents: 2840
diff changeset
   100
!
e13e0c53924a keep registry of cursors here - no longer use a Cursor Lobby
Claus Gittinger <cg@exept.de>
parents: 2840
diff changeset
   101
1371
22f586987cd1 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1367
diff changeset
   102
deviceFonts
22f586987cd1 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1367
diff changeset
   103
    "return the registry keeping track of fonts which were allocated
2813
913aca399962 preps to keep the view & form lobbies on a per-display basis.
Claus Gittinger <cg@exept.de>
parents: 2809
diff changeset
   104
     on this device."
1365
37a9e7ac4dbc moved color registration from Color class to per-device lobby
Claus Gittinger <cg@exept.de>
parents: 1315
diff changeset
   105
1371
22f586987cd1 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1367
diff changeset
   106
    ^ deviceFonts
2813
913aca399962 preps to keep the view & form lobbies on a per-display basis.
Claus Gittinger <cg@exept.de>
parents: 2809
diff changeset
   107
!
913aca399962 preps to keep the view & form lobbies on a per-display basis.
Claus Gittinger <cg@exept.de>
parents: 2809
diff changeset
   108
2839
36f61177428c color release
Claus Gittinger <cg@exept.de>
parents: 2813
diff changeset
   109
deviceForms
36f61177428c color release
Claus Gittinger <cg@exept.de>
parents: 2813
diff changeset
   110
    "return the registry keeping track of forms which were allocated
36f61177428c color release
Claus Gittinger <cg@exept.de>
parents: 2813
diff changeset
   111
     on this device."
36f61177428c color release
Claus Gittinger <cg@exept.de>
parents: 2813
diff changeset
   112
36f61177428c color release
Claus Gittinger <cg@exept.de>
parents: 2813
diff changeset
   113
    ^ deviceForms
36f61177428c color release
Claus Gittinger <cg@exept.de>
parents: 2813
diff changeset
   114
!
36f61177428c color release
Claus Gittinger <cg@exept.de>
parents: 2813
diff changeset
   115
2813
913aca399962 preps to keep the view & form lobbies on a per-display basis.
Claus Gittinger <cg@exept.de>
parents: 2809
diff changeset
   116
deviceViews
913aca399962 preps to keep the view & form lobbies on a per-display basis.
Claus Gittinger <cg@exept.de>
parents: 2809
diff changeset
   117
    "return the registry keeping track of views which were allocated
913aca399962 preps to keep the view & form lobbies on a per-display basis.
Claus Gittinger <cg@exept.de>
parents: 2809
diff changeset
   118
     on this device."
913aca399962 preps to keep the view & form lobbies on a per-display basis.
Claus Gittinger <cg@exept.de>
parents: 2809
diff changeset
   119
913aca399962 preps to keep the view & form lobbies on a per-display basis.
Claus Gittinger <cg@exept.de>
parents: 2809
diff changeset
   120
    ^ deviceViews
1365
37a9e7ac4dbc moved color registration from Color class to per-device lobby
Claus Gittinger <cg@exept.de>
parents: 1315
diff changeset
   121
! !
37a9e7ac4dbc moved color registration from Color class to per-device lobby
Claus Gittinger <cg@exept.de>
parents: 1315
diff changeset
   122
37a9e7ac4dbc moved color registration from Color class to per-device lobby
Claus Gittinger <cg@exept.de>
parents: 1315
diff changeset
   123
!HostGraphicsDevice methodsFor:'initialize / release'!
37a9e7ac4dbc moved color registration from Color class to per-device lobby
Claus Gittinger <cg@exept.de>
parents: 1315
diff changeset
   124
1367
84941299a4df *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1365
diff changeset
   125
initializeDeviceResourceTables
2813
913aca399962 preps to keep the view & form lobbies on a per-display basis.
Claus Gittinger <cg@exept.de>
parents: 2809
diff changeset
   126
    deviceViews := Registry new.
913aca399962 preps to keep the view & form lobbies on a per-display basis.
Claus Gittinger <cg@exept.de>
parents: 2809
diff changeset
   127
    deviceForms := Registry new.
1365
37a9e7ac4dbc moved color registration from Color class to per-device lobby
Claus Gittinger <cg@exept.de>
parents: 1315
diff changeset
   128
    deviceColors := Registry new.
2843
e13e0c53924a keep registry of cursors here - no longer use a Cursor Lobby
Claus Gittinger <cg@exept.de>
parents: 2840
diff changeset
   129
    deviceCursors := Registry new.
2809
96f6b7b449c7 use a CachingRegistry for fonts.
Claus Gittinger <cg@exept.de>
parents: 1371
diff changeset
   130
    deviceFonts := CachingRegistry new cacheSize:10.
1365
37a9e7ac4dbc moved color registration from Color class to per-device lobby
Claus Gittinger <cg@exept.de>
parents: 1315
diff changeset
   131
37a9e7ac4dbc moved color registration from Color class to per-device lobby
Claus Gittinger <cg@exept.de>
parents: 1315
diff changeset
   132
    "Created: 24.2.1997 / 18:29:53 / cg"
37a9e7ac4dbc moved color registration from Color class to per-device lobby
Claus Gittinger <cg@exept.de>
parents: 1315
diff changeset
   133
!
37a9e7ac4dbc moved color registration from Color class to per-device lobby
Claus Gittinger <cg@exept.de>
parents: 1315
diff changeset
   134
37a9e7ac4dbc moved color registration from Color class to per-device lobby
Claus Gittinger <cg@exept.de>
parents: 1315
diff changeset
   135
releaseDeviceColors
2839
36f61177428c color release
Claus Gittinger <cg@exept.de>
parents: 2813
diff changeset
   136
    deviceColors do:[:aColor |
2845
0794fef6db4a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2843
diff changeset
   137
        aColor releaseFromDevice
2839
36f61177428c color release
Claus Gittinger <cg@exept.de>
parents: 2813
diff changeset
   138
    ].
1365
37a9e7ac4dbc moved color registration from Color class to per-device lobby
Claus Gittinger <cg@exept.de>
parents: 1315
diff changeset
   139
    deviceColors := Registry new.
37a9e7ac4dbc moved color registration from Color class to per-device lobby
Claus Gittinger <cg@exept.de>
parents: 1315
diff changeset
   140
37a9e7ac4dbc moved color registration from Color class to per-device lobby
Claus Gittinger <cg@exept.de>
parents: 1315
diff changeset
   141
    "Created: 24.2.1997 / 18:07:49 / cg"
2839
36f61177428c color release
Claus Gittinger <cg@exept.de>
parents: 2813
diff changeset
   142
1371
22f586987cd1 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1367
diff changeset
   143
!
22f586987cd1 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1367
diff changeset
   144
2843
e13e0c53924a keep registry of cursors here - no longer use a Cursor Lobby
Claus Gittinger <cg@exept.de>
parents: 2840
diff changeset
   145
releaseDeviceCursors
2847
8ef5b35346ff *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2846
diff changeset
   146
    deviceCursors do:[:aCursor |
2845
0794fef6db4a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2843
diff changeset
   147
        aCursor releaseFromDevice
2843
e13e0c53924a keep registry of cursors here - no longer use a Cursor Lobby
Claus Gittinger <cg@exept.de>
parents: 2840
diff changeset
   148
    ].
e13e0c53924a keep registry of cursors here - no longer use a Cursor Lobby
Claus Gittinger <cg@exept.de>
parents: 2840
diff changeset
   149
    deviceCursors := Registry new.
e13e0c53924a keep registry of cursors here - no longer use a Cursor Lobby
Claus Gittinger <cg@exept.de>
parents: 2840
diff changeset
   150
e13e0c53924a keep registry of cursors here - no longer use a Cursor Lobby
Claus Gittinger <cg@exept.de>
parents: 2840
diff changeset
   151
    "Created: 24.2.1997 / 18:07:49 / cg"
e13e0c53924a keep registry of cursors here - no longer use a Cursor Lobby
Claus Gittinger <cg@exept.de>
parents: 2840
diff changeset
   152
e13e0c53924a keep registry of cursors here - no longer use a Cursor Lobby
Claus Gittinger <cg@exept.de>
parents: 2840
diff changeset
   153
!
e13e0c53924a keep registry of cursors here - no longer use a Cursor Lobby
Claus Gittinger <cg@exept.de>
parents: 2840
diff changeset
   154
1371
22f586987cd1 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1367
diff changeset
   155
releaseDeviceFonts
2846
05c5fdd17641 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2845
diff changeset
   156
    deviceFonts do:[:aFont |
05c5fdd17641 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2845
diff changeset
   157
        aFont releaseFromDevice.
05c5fdd17641 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2845
diff changeset
   158
    ].
2809
96f6b7b449c7 use a CachingRegistry for fonts.
Claus Gittinger <cg@exept.de>
parents: 1371
diff changeset
   159
    deviceFonts := CachingRegistry new cacheSize:10.
1365
37a9e7ac4dbc moved color registration from Color class to per-device lobby
Claus Gittinger <cg@exept.de>
parents: 1315
diff changeset
   160
! !
37a9e7ac4dbc moved color registration from Color class to per-device lobby
Claus Gittinger <cg@exept.de>
parents: 1315
diff changeset
   161
2846
05c5fdd17641 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2845
diff changeset
   162
!HostGraphicsDevice methodsFor:'registration'!
05c5fdd17641 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2845
diff changeset
   163
05c5fdd17641 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2845
diff changeset
   164
registerColor:aColor
05c5fdd17641 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2845
diff changeset
   165
    deviceColors register:aColor.
05c5fdd17641 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2845
diff changeset
   166
05c5fdd17641 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2845
diff changeset
   167
    "Created: 24.2.1997 / 18:29:10 / cg"
05c5fdd17641 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2845
diff changeset
   168
!
05c5fdd17641 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2845
diff changeset
   169
05c5fdd17641 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2845
diff changeset
   170
registerCursor:aCursor
05c5fdd17641 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2845
diff changeset
   171
    deviceCursors register:aCursor.
05c5fdd17641 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2845
diff changeset
   172
05c5fdd17641 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2845
diff changeset
   173
    "Created: 24.2.1997 / 18:29:10 / cg"
05c5fdd17641 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2845
diff changeset
   174
!
05c5fdd17641 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2845
diff changeset
   175
05c5fdd17641 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2845
diff changeset
   176
registerFont:aFont
05c5fdd17641 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2845
diff changeset
   177
    deviceFonts register:aFont.
05c5fdd17641 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2845
diff changeset
   178
05c5fdd17641 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2845
diff changeset
   179
    "Created: 24.2.1997 / 18:29:10 / cg"
05c5fdd17641 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2845
diff changeset
   180
!
05c5fdd17641 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2845
diff changeset
   181
05c5fdd17641 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2845
diff changeset
   182
registerForm:aForm
05c5fdd17641 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2845
diff changeset
   183
    deviceForms register:aForm.
05c5fdd17641 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2845
diff changeset
   184
05c5fdd17641 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2845
diff changeset
   185
    "Created: 24.2.1997 / 18:29:10 / cg"
05c5fdd17641 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2845
diff changeset
   186
!
05c5fdd17641 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2845
diff changeset
   187
05c5fdd17641 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2845
diff changeset
   188
registerView:aView
05c5fdd17641 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2845
diff changeset
   189
    deviceViews register:aView.
05c5fdd17641 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2845
diff changeset
   190
05c5fdd17641 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2845
diff changeset
   191
    "Created: 24.2.1997 / 18:29:10 / cg"
05c5fdd17641 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2845
diff changeset
   192
!
05c5fdd17641 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2845
diff changeset
   193
05c5fdd17641 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2845
diff changeset
   194
unregisterColor:aColor
05c5fdd17641 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2845
diff changeset
   195
    deviceColors unregister:aColor.
05c5fdd17641 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2845
diff changeset
   196
05c5fdd17641 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2845
diff changeset
   197
    "Created: 24.2.1997 / 18:29:14 / cg"
05c5fdd17641 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2845
diff changeset
   198
!
05c5fdd17641 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2845
diff changeset
   199
05c5fdd17641 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2845
diff changeset
   200
unregisterCursor:aCursor
05c5fdd17641 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2845
diff changeset
   201
    deviceCursors unregister:aCursor.
05c5fdd17641 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2845
diff changeset
   202
05c5fdd17641 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2845
diff changeset
   203
    "Created: 24.2.1997 / 18:29:14 / cg"
05c5fdd17641 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2845
diff changeset
   204
!
05c5fdd17641 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2845
diff changeset
   205
05c5fdd17641 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2845
diff changeset
   206
unregisterFont:aFont
05c5fdd17641 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2845
diff changeset
   207
    deviceFonts unregister:aFont.
05c5fdd17641 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2845
diff changeset
   208
05c5fdd17641 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2845
diff changeset
   209
    "Created: 24.2.1997 / 18:29:14 / cg"
05c5fdd17641 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2845
diff changeset
   210
!
05c5fdd17641 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2845
diff changeset
   211
05c5fdd17641 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2845
diff changeset
   212
unregisterForm:aForm
05c5fdd17641 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2845
diff changeset
   213
    deviceForms unregister:aForm.
05c5fdd17641 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2845
diff changeset
   214
05c5fdd17641 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2845
diff changeset
   215
    "Created: 24.2.1997 / 18:29:14 / cg"
05c5fdd17641 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2845
diff changeset
   216
!
05c5fdd17641 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2845
diff changeset
   217
05c5fdd17641 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2845
diff changeset
   218
unregisterView:aView
05c5fdd17641 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2845
diff changeset
   219
    deviceViews unregister:aView.
05c5fdd17641 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2845
diff changeset
   220
05c5fdd17641 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2845
diff changeset
   221
    "Created: 24.2.1997 / 18:29:14 / cg"
05c5fdd17641 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2845
diff changeset
   222
! !
05c5fdd17641 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2845
diff changeset
   223
1284
d17f4d91174d intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   224
!HostGraphicsDevice class methodsFor:'documentation'!
d17f4d91174d intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   225
d17f4d91174d intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   226
version
2961
3f5a60b6e06c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2847
diff changeset
   227
    ^ '$Header: /cvs/stx/stx/libview/HostGraphicsDevice.st,v 1.14 1999-10-09 13:19:39 cg Exp $'
1284
d17f4d91174d intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   228
! !