summaryrefslogtreecommitdiffstats
path: root/fortran/test/tH5VL.F90
blob: e7a036361563aa287be35887fe6b51a30bc8b185 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
!****h* root/fortran/test/tH5VL.f90
!
! NAME
!  tH5VL.f90
!
! FUNCTION
!  Basic testing of Fortran Variable_length datatypes APIs.
!
! COPYRIGHT
! * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
!   Copyright by The HDF Group.                                               *
!   All rights reserved.                                                      *
!                                                                             *
!   This file is part of HDF5.  The full HDF5 copyright notice, including     *
!   terms governing use, modification, and redistribution, is contained in    *
!   the COPYING file, which can be found at the root of the source code       *
!   distribution tree, or in https://www.hdfgroup.org/licenses.               *
!   If you do not have access to either file, you may request a copy from     *
!   help@hdfgroup.org.                                                        *
! * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
!
! CONTAINS SUBROUTINES
!  vl_test_integer, vl_test_real, vl_test_string
!
!*****

MODULE TH5VL
  USE HDF5 ! This module contains all necessary modules
  USE TH5_MISC
  USE TH5_MISC_GEN

CONTAINS

        SUBROUTINE vl_test_integer(cleanup, total_error)

          IMPLICIT NONE
          LOGICAL, INTENT(IN) :: cleanup
          INTEGER, INTENT(OUT) :: total_error

          CHARACTER(LEN=7), PARAMETER :: filename = "VLtypes" ! File name
          CHARACTER(LEN=80) :: fix_filename
          CHARACTER(LEN=5), PARAMETER :: dsetname = "VLint"     ! Dataset name

          INTEGER(HID_T) :: file_id       ! File identifier
          INTEGER(HID_T) :: dset_id       ! Dataset identifier
          INTEGER(HID_T) :: dspace_id     ! Dataspace identifier
          INTEGER(HID_T) :: vltype_id     ! Datatype identifier


          INTEGER(HSIZE_T), DIMENSION(1) :: dims = (/6/) ! Dataset dimensions
          INTEGER(SIZE_T), DIMENSION(6) :: len           ! Elements lengths
          INTEGER(SIZE_T), DIMENSION(6) :: len_out
          INTEGER     ::   rank = 1                      ! Dataset rank

          INTEGER, DIMENSION(5,6) :: vl_int_data ! Data buffers
          INTEGER, DIMENSION(5,6) :: vl_int_data_out ! Data buffers
          INTEGER     ::   error ! Error flag

          INTEGER     :: i, j    !general purpose integers
          INTEGER(HSIZE_T) :: ih, jh    !general purpose integers
          INTEGER(HSIZE_T), DIMENSION(2) :: data_dims = (/5,6/)
          INTEGER(SIZE_T)  max_len

          !
          ! Initialize the vl_int_data array.
          !
          do i = 1, 6
             do j = 1, 5
                vl_int_data(j,i) = -100
             end do
          end do

          do i = 2, 6
             do j = 1,  i-1
                vl_int_data(j,i) = i-1
             end do
          end do

           do i = 1,6
              len(i) = i-1
           end do


          !
          ! Create a new file using default properties.
          !
          CALL h5_fixname_f(filename, fix_filename, H5P_DEFAULT_F, error)
          if (error .ne. 0) then
              write(*,*) "Cannot modify filename"
              stop
          endif
          CALL h5fcreate_f(fix_filename, H5F_ACC_TRUNC_F, file_id, error)
              CALL check("h5fcreate_f", error, total_error)


          !
          ! Create the dataspace.
          !
          CALL h5screate_simple_f(rank, dims, dspace_id, error)
              CALL check("h5screate_simple_f", error, total_error)


          !
          ! Create the dataset with default properties.
          !
          CALL h5tvlen_create_f(H5T_NATIVE_INTEGER, vltype_id, error)
              CALL check("h5dvlen_create_f", error, total_error)

          CALL h5dcreate_f(file_id, dsetname, vltype_id, dspace_id, &
                           dset_id, error)
              CALL check("h5dcreate_f", error, total_error)

          !
          ! Write the dataset.
          !
          CALL h5dwrite_vl_f(dset_id, vltype_id, vl_int_data, data_dims, len, error)
              CALL check("h5dwrite_int_f", error, total_error)



          !
          ! End access to the dataset and release resources used by it.
          !
          CALL h5dclose_f(dset_id, error)
              CALL check("h5dclose_f", error, total_error)

          !
          ! Close the file.
          !
          CALL h5fclose_f(file_id, error)
              CALL check("h5fclose_f", error, total_error)

          !
          ! Open the existing file.
          !
          CALL h5fopen_f (fix_filename, H5F_ACC_RDWR_F, file_id, error)
              CALL check("h5fopen_f", error, total_error)

          !
          ! Open the existing dataset.
          !
          CALL h5dopen_f(file_id, dsetname, dset_id, error)
              CALL check("h5dopen_f", error, total_error)

          CALL h5dvlen_get_max_len_f(dset_id, vltype_id, dspace_id, max_len, error)
              CALL check("h5dvlen_get_max_len_f", error, total_error)
              if(max_len .ne. data_dims(1)) then
                      total_error = total_error + 1
                      write(*,*) "Wrong number of elements returned by h5dvlen_get_max_len_f"
              endif
          !
          ! Read the dataset.
          !
          CALL h5dread_vl_f(dset_id, vltype_id, vl_int_data_out, data_dims, len_out, &
                            error, mem_space_id = dspace_id, file_space_id = dspace_id)
              CALL check("h5dread_int_f", error, total_error)
              do ih = 1, data_dims(2)
              do jh = 1, len_out(ih)
              if(vl_int_data(jh,ih) .ne. vl_int_data_out(jh,ih))  then
                  total_error = total_error + 1
                  write(*,*) "h5dread_vl_f returned incorrect data"
              endif
              enddo
               if (len(ih) .ne. len_out(ih)) then
                  total_error = total_error + 1
                  write(*,*) "h5dread_vl_f returned incorrect data"
              endif
              enddo

          !
          CALL h5dclose_f(dset_id, error)
              CALL check("h5dclose_f", error, total_error)

          CALL h5tclose_f(vltype_id, error)
              CALL check("h5tclose_f", error, total_error)

          !
          ! Terminate access to the data space.
          !
          CALL h5sclose_f(dspace_id, error)
              CALL check("h5sclose_f", error, total_error)

          !
          ! Close the file.
          !
          CALL h5fclose_f(file_id, error)
              CALL check("h5fclose_f", error, total_error)
          if(cleanup) CALL h5_cleanup_f(filename, H5P_DEFAULT_F, error)
              CALL check("h5_cleanup_f", error, total_error)

          RETURN
        END SUBROUTINE vl_test_integer

        SUBROUTINE vl_test_real(cleanup, total_error)

          IMPLICIT NONE
          LOGICAL, INTENT(IN) :: cleanup
          INTEGER, INTENT(OUT) :: total_error

          CHARACTER(LEN=8), PARAMETER :: filename = "VLtypesR" ! File name
          CHARACTER(LEN=80) :: fix_filename
          CHARACTER(LEN=6), PARAMETER :: dsetname = "VLreal"     ! Dataset name

          INTEGER(HID_T) :: file_id       ! File identifier
          INTEGER(HID_T) :: dset_id       ! Dataset identifier
          INTEGER(HID_T) :: dspace_id     ! Dataspace identifier
          INTEGER(HID_T) :: vltype_id     ! Datatype identifier


          INTEGER(HSIZE_T), DIMENSION(1) :: dims = (/6/) ! Dataset dimensions
          INTEGER(SIZE_T), DIMENSION(6) :: len           ! Elements lengths
          INTEGER(SIZE_T), DIMENSION(6) :: len_out
          INTEGER     ::   rank = 1                      ! Dataset rank

          REAL, DIMENSION(5,6) :: vl_real_data ! Data buffers
          REAL, DIMENSION(5,6) :: vl_real_data_out ! Data buffers
          INTEGER     ::   error ! Error flag

          INTEGER     :: i, j    !general purpose integers
          INTEGER(HSIZE_T)     :: ih, jh    !general purpose integers
          INTEGER(HSIZE_T), DIMENSION(2) :: data_dims = (/5,6/)
          INTEGER(SIZE_T)  max_len
          INTEGER(HID_T) ::  vl_type_id
          LOGICAL        ::  vl_flag

          !
          ! Initialize the vl_int_data array.
          !
          do i = 1, 6
             do j = 1, 5
                vl_real_data(j,i) = -100.
             end do
          end do

          do i = 2, 6
             do j = 1,  i-1
                vl_real_data(j,i) = i-1
             end do
          end do

           do i = 1,6
              len(i) = i-1
           end do


          !
          ! Create a new file using default properties.
          !
          CALL h5_fixname_f(filename, fix_filename, H5P_DEFAULT_F, error)
          if (error .ne. 0) then
              write(*,*) "Cannot modify filename"
              stop
          endif
          CALL h5fcreate_f(fix_filename, H5F_ACC_TRUNC_F, file_id, error)
              CALL check("h5fcreate_f", error, total_error)


          !
          ! Create the dataspace.
          !
          CALL h5screate_simple_f(rank, dims, dspace_id, error)
              CALL check("h5screate_simple_f", error, total_error)


          !
          ! Create the dataset with default properties.
          !
          CALL h5tvlen_create_f(H5T_NATIVE_REAL, vltype_id, error)
              CALL check("h5dvlen_create_f", error, total_error)

          CALL h5dcreate_f(file_id, dsetname, vltype_id, dspace_id, &
                           dset_id, error)
              CALL check("h5dcreate_f", error, total_error)
          CALL h5dget_type_f(dset_id, vl_type_id, error)
              CALL check("h5dget_type_f", error, total_error)
          CALL h5tis_variable_str_f( vl_type_id, vl_flag, error)
              CALL check("h5tis_variable_str_f", error, total_error)
              if( vl_flag ) then
                 write(*,*) "type is wrong"
                 total_error = total_error + 1
              endif


          !
          ! Write the dataset.
          !
          CALL h5dwrite_vl_f(dset_id, vltype_id, vl_real_data, data_dims, len, error)
              CALL check("h5dwrite_vl_real_f", error, total_error)


          !
          ! End access to the dataset and release resources used by it.
          !
          CALL h5dclose_f(dset_id, error)
              CALL check("h5dclose_f", error, total_error)

          !
          ! Close the file.
          !
          CALL h5fclose_f(file_id, error)
              CALL check("h5fclose_f", error, total_error)

          !
          ! Open the existing file.
          !
          CALL h5fopen_f (fix_filename, H5F_ACC_RDWR_F, file_id, error)
              CALL check("h5fopen_f", error, total_error)

          !
          ! Open the existing dataset.
          !
          CALL h5dopen_f(file_id, dsetname, dset_id, error)
              CALL check("h5dopen_f", error, total_error)

          CALL h5dvlen_get_max_len_f(dset_id, vltype_id, dspace_id, max_len, error)
              CALL check("h5dvlen_get_max_len_f", error, total_error)
              if(max_len .ne. data_dims(1)) then
                      total_error = total_error + 1
                      write(*,*) "Wrong number of elements returned by h5dvlen_get_max_len_f"
              endif
          !
          ! Read the dataset.
          !
          CALL h5dread_vl_f(dset_id, vltype_id, vl_real_data_out, data_dims, len_out, &
                            error, mem_space_id = dspace_id, file_space_id = dspace_id)
              CALL check("h5dread_real_f", error, total_error)
              DO ih = 1, data_dims(2)
              DO jh = 1, len_out(ih)
                 CALL VERIFY("h5dread_vl_f returned incorrect data",vl_real_data(jh,ih),vl_real_data_out(jh,ih), total_error)
              ENDDO
              IF (LEN(ih) .NE. len_out(ih)) THEN
                 total_error = total_error + 1
                 WRITE(*,*) "h5dread_vl_f returned incorrect data"
              ENDIF
           ENDDO


          !
          CALL h5dclose_f(dset_id, error)
              CALL check("h5dclose_f", error, total_error)

          CALL h5tclose_f(vltype_id, error)
              CALL check("h5tclose_f", error, total_error)

          !
          ! Terminate access to the data space.
          !
          CALL h5sclose_f(dspace_id, error)
              CALL check("h5sclose_f", error, total_error)

          !
          ! Close the file.
          !
          CALL h5fclose_f(file_id, error)
              CALL check("h5fclose_f", error, total_error)
          if(cleanup) CALL h5_cleanup_f(filename, H5P_DEFAULT_F, error)
              CALL check("h5_cleanup_f", error, total_error)

          RETURN
        END SUBROUTINE vl_test_real

        SUBROUTINE vl_test_string(cleanup, total_error)

          IMPLICIT NONE
          LOGICAL, INTENT(IN) :: cleanup
          INTEGER, INTENT(OUT) :: total_error

          CHARACTER(LEN=8), PARAMETER :: filename = "VLtypesS" ! File name
          CHARACTER(LEN=80) :: fix_filename
          CHARACTER(LEN=9), PARAMETER :: dsetname = "VLstrings"     ! Dataset name

          INTEGER(HID_T) :: file_id       ! File identifier
          INTEGER(HID_T) :: dset_id       ! Dataset identifier
          INTEGER(HID_T) :: dspace_id     ! Dataspace identifier


          INTEGER(HSIZE_T), DIMENSION(1) :: dims = (/4/) ! Dataset dimensions
          INTEGER(SIZE_T), DIMENSION(4) :: str_len           ! Elements lengths
          INTEGER(SIZE_T), DIMENSION(4) :: str_len_out
          INTEGER     ::   rank = 1                      ! Dataset rank

          CHARACTER(LEN=10), DIMENSION(4) :: string_data ! Array of strings
          CHARACTER(LEN=10), DIMENSION(4) :: string_data_out     ! Data buffers
          INTEGER     ::   error ! Error flag

          INTEGER(HSIZE_T) :: ih    !general purpose integers
          INTEGER(HSIZE_T), DIMENSION(2) :: data_dims = (/10,4/)
          INTEGER(HID_T) :: vl_type_id
          LOGICAL        :: vl_flag

          !
          ! Initialize the string_data array.
          !
          string_data(1) = 'This is   '
          str_len(1) = 8
          string_data(2) = 'a fortran '
          str_len(2) = 10
          string_data(3) = 'strings   '
          str_len(3) = 8
          string_data(4) = 'test.     '
          str_len(4) = 5


          !
          ! Create a new file using default properties.
          !
          CALL h5_fixname_f(filename, fix_filename, H5P_DEFAULT_F, error)
          if (error .ne. 0) then
              write(*,*) "Cannot modify filename"
              stop
          endif
          CALL h5fcreate_f(fix_filename, H5F_ACC_TRUNC_F, file_id, error)
              CALL check("h5fcreate_f", error, total_error)


          !
          ! Create the dataspace.
          !
          CALL h5screate_simple_f(rank, dims, dspace_id, error)
              CALL check("h5screate_simple_f", error, total_error)


          !
          ! Create the dataset with default properties.
          !
          CALL h5dcreate_f(file_id, dsetname, H5T_STRING, dspace_id, &
                           dset_id, error)
              CALL check("h5dcreate_f", error, total_error)
          !
          ! Check that dataset has a string datatype
          !
          CALL h5dget_type_f(dset_id, vl_type_id, error)
              CALL check("h5dget_type_f", error, total_error)
          CALL h5tis_variable_str_f( vl_type_id, vl_flag, error)
              CALL check("h5tis_variable_str_f", error, total_error)
              if( .NOT. vl_flag ) then
                 write(*,*) "type is wrong"
                 total_error = total_error + 1
              endif

          !
          ! Write the dataset.
          !
          CALL h5dwrite_vl_f(dset_id, H5T_STRING, string_data, data_dims, str_len, error)
              CALL check("h5dwrite_string_f", error, total_error)


          !
          ! End access to the dataset and release resources used by it.
          !
          CALL h5dclose_f(dset_id, error)
              CALL check("h5dclose_f", error, total_error)

          !
          ! Close the file.
          !
          CALL h5fclose_f(file_id, error)
              CALL check("h5fclose_f", error, total_error)

          !
          ! Open the existing file.
          !
          CALL h5fopen_f (fix_filename, H5F_ACC_RDWR_F, file_id, error)
              CALL check("h5fopen_f", error, total_error)

          !
          ! Open the existing dataset.
          !
          CALL h5dopen_f(file_id, dsetname, dset_id, error)
              CALL check("h5dopen_f", error, total_error)
          !
          !  Read the dataset.
          !
          CALL h5dread_vl_f(dset_id, H5T_STRING, string_data_out, data_dims,  &
                            str_len_out, error)
              CALL check("h5dread_string_f", error, total_error)
          do 100 ih = 1, data_dims(2)
             if(str_len(ih) .ne. str_len_out(ih)) then
                total_error=total_error + 1
                write(*,*) 'Returned string length is incorrect'
                goto 100
             endif
             if(string_data(1)(1:str_len(ih)) .ne. string_data_out(1)(1:str_len(ih))) then
             write(*,*) ' Returned string is wrong'
             total_error = total_error + 1
             endif
100       continue

          !
          CALL h5dclose_f(dset_id, error)
              CALL check("h5dclose_f", error, total_error)

          !
          ! Terminate access to the data space.
          !
          CALL h5sclose_f(dspace_id, error)
              CALL check("h5sclose_f", error, total_error)

          !
          ! Close the file.
          !
          CALL h5fclose_f(file_id, error)
              CALL check("h5fclose_f", error, total_error)
          if(cleanup) CALL h5_cleanup_f(filename, H5P_DEFAULT_F, error)
              CALL check("h5_cleanup_f", error, total_error)

          RETURN
        END SUBROUTINE vl_test_string
END MODULE TH5VL
pan class="hl opt">((TkWindow * winPtr)); /* 4 */ EXTERN void TkpSetCapture _ANSI_ARGS_((TkWindow * winPtr)); /* 5 */ EXTERN void TkpSetCursor _ANSI_ARGS_((TkpCursor cursor)); /* 6 */ EXTERN void TkpWmSetState _ANSI_ARGS_((TkWindow * winPtr, int state)); /* 7 */ EXTERN void TkAboutDlg _ANSI_ARGS_((void)); /* 8 */ EXTERN unsigned int TkMacOSXButtonKeyState _ANSI_ARGS_((void)); /* 9 */ EXTERN void TkMacOSXClearMenubarActive _ANSI_ARGS_((void)); /* 10 */ EXTERN int TkMacOSXDispatchMenuEvent _ANSI_ARGS_((int menuID, int index)); /* 11 */ EXTERN void TkMacOSXInstallCursor _ANSI_ARGS_(( int resizeOverride)); /* 12 */ EXTERN void TkMacOSXHandleTearoffMenu _ANSI_ARGS_((void)); /* Slot 13 is reserved */ /* 14 */ EXTERN int TkMacOSXDoHLEvent _ANSI_ARGS_(( EventRecord * theEvent)); /* Slot 15 is reserved */ /* 16 */ EXTERN Window TkMacOSXGetXWindow _ANSI_ARGS_((WindowRef macWinPtr)); /* 17 */ EXTERN int TkMacOSXGrowToplevel _ANSI_ARGS_(( WindowRef whichWindow, Point start)); /* 18 */ EXTERN void TkMacOSXHandleMenuSelect _ANSI_ARGS_((long mResult, int optionKeyPressed)); /* Slot 19 is reserved */ /* Slot 20 is reserved */ /* 21 */ EXTERN void TkMacOSXInvalidateWindow _ANSI_ARGS_(( MacDrawable * macWin, int flag)); /* 22 */ EXTERN int TkMacOSXIsCharacterMissing _ANSI_ARGS_(( Tk_Font tkfont, unsigned int searchChar)); /* 23 */ EXTERN void TkMacOSXMakeRealWindowExist _ANSI_ARGS_(( TkWindow * winPtr)); /* 24 */ EXTERN BitMapPtr TkMacOSXMakeStippleMap _ANSI_ARGS_((Drawable d1, Drawable d2)); /* 25 */ EXTERN void TkMacOSXMenuClick _ANSI_ARGS_((void)); /* 26 */ EXTERN void TkMacOSXRegisterOffScreenWindow _ANSI_ARGS_(( Window window, GWorldPtr portPtr)); /* 27 */ EXTERN int TkMacOSXResizable _ANSI_ARGS_((TkWindow * winPtr)); /* 28 */ EXTERN void TkMacOSXSetHelpMenuItemCount _ANSI_ARGS_((void)); /* 29 */ EXTERN void TkMacOSXSetScrollbarGrow _ANSI_ARGS_(( TkWindow * winPtr, int flag)); /* 30 */ EXTERN void TkMacOSXSetUpClippingRgn _ANSI_ARGS_(( Drawable drawable)); /* 31 */ EXTERN void TkMacOSXSetUpGraphicsPort _ANSI_ARGS_((GC gc, GWorldPtr destPort)); /* 32 */ EXTERN void TkMacOSXUpdateClipRgn _ANSI_ARGS_((TkWindow * winPtr)); /* 33 */ EXTERN void TkMacOSXUnregisterMacWindow _ANSI_ARGS_(( WindowRef portPtr)); /* 34 */ EXTERN int TkMacOSXUseMenuID _ANSI_ARGS_((short macID)); /* 35 */ EXTERN RgnHandle TkMacOSXVisableClipRgn _ANSI_ARGS_(( TkWindow * winPtr)); /* 36 */ EXTERN void TkMacOSXWinBounds _ANSI_ARGS_((TkWindow * winPtr, Rect * geometry)); /* 37 */ EXTERN void TkMacOSXWindowOffset _ANSI_ARGS_((WindowRef wRef, int * xOffset, int * yOffset)); /* 38 */ EXTERN int TkSetMacColor _ANSI_ARGS_((unsigned long pixel, RGBColor * macColor)); /* 39 */ EXTERN void TkSetWMName _ANSI_ARGS_((TkWindow * winPtr, Tk_Uid titleUid)); /* 40 */ EXTERN void TkSuspendClipboard _ANSI_ARGS_((void)); /* 41 */ EXTERN int TkMacOSXZoomToplevel _ANSI_ARGS_(( WindowPtr whichWindow, Point where, short zoomPart)); /* 42 */ EXTERN Tk_Window Tk_TopCoordsToWindow _ANSI_ARGS_((Tk_Window tkwin, int rootX, int rootY, int * newX, int * newY)); /* 43 */ EXTERN MacDrawable * TkMacOSXContainerId _ANSI_ARGS_((TkWindow * winPtr)); /* 44 */ EXTERN MacDrawable * TkMacOSXGetHostToplevel _ANSI_ARGS_(( TkWindow * winPtr)); /* 45 */ EXTERN void TkMacOSXPreprocessMenu _ANSI_ARGS_((void)); /* 46 */ EXTERN int TkpIsWindowFloating _ANSI_ARGS_((WindowRef window)); /* 47 */ EXTERN Tk_Window TkMacOSXGetCapture _ANSI_ARGS_((void)); /* Slot 48 is reserved */ /* 49 */ EXTERN Window TkGetTransientMaster _ANSI_ARGS_((TkWindow * winPtr)); /* 50 */ EXTERN int TkGenerateButtonEvent _ANSI_ARGS_((int x, int y, Window window, unsigned int state)); /* 51 */ EXTERN void TkGenWMDestroyEvent _ANSI_ARGS_((Tk_Window tkwin)); /* Slot 52 is reserved */ /* 53 */ EXTERN unsigned long TkpGetMS _ANSI_ARGS_((void)); #endif /* MAC_OSX_TK */ #if !(defined(__WIN32__) || defined(MAC_TCL) || defined(MAC_OSX_TK)) /* X11 */ /* 0 */ EXTERN void TkCreateXEventSource _ANSI_ARGS_((void)); /* 1 */ EXTERN void TkFreeWindowId _ANSI_ARGS_((TkDisplay * dispPtr, Window w)); /* 2 */ EXTERN void TkInitXId _ANSI_ARGS_((TkDisplay * dispPtr)); /* 3 */ EXTERN int TkpCmapStressed _ANSI_ARGS_((Tk_Window tkwin, Colormap colormap)); /* 4 */ EXTERN void TkpSync _ANSI_ARGS_((Display * display)); /* 5 */ EXTERN Window TkUnixContainerId _ANSI_ARGS_((TkWindow * winPtr)); /* 6 */ EXTERN int TkUnixDoOneXEvent _ANSI_ARGS_((Tcl_Time * timePtr)); /* 7 */ EXTERN void TkUnixSetMenubar _ANSI_ARGS_((Tk_Window tkwin, Tk_Window menubar)); /* 8 */ EXTERN int TkpScanWindowId _ANSI_ARGS_((Tcl_Interp * interp, CONST char * string, Window * idPtr)); /* 9 */ EXTERN void TkWmCleanup _ANSI_ARGS_((TkDisplay * dispPtr)); /* 10 */ EXTERN void TkSendCleanup _ANSI_ARGS_((TkDisplay * dispPtr)); /* 11 */ EXTERN void TkFreeXId _ANSI_ARGS_((TkDisplay * dispPtr)); /* 12 */ EXTERN int TkpWmSetState _ANSI_ARGS_((TkWindow * winPtr, int state)); #endif /* X11 */ typedef struct TkIntPlatStubs { int magic; struct TkIntPlatStubHooks *hooks; #ifdef __WIN32__ char * (*tkAlignImageData) _ANSI_ARGS_((XImage * image, int alignment, int bitOrder)); /* 0 */ void *reserved1; void (*tkGenerateActivateEvents) _ANSI_ARGS_((TkWindow * winPtr, int active)); /* 2 */ unsigned long (*tkpGetMS) _ANSI_ARGS_((void)); /* 3 */ void (*tkPointerDeadWindow) _ANSI_ARGS_((TkWindow * winPtr)); /* 4 */ void (*tkpPrintWindowId) _ANSI_ARGS_((char * buf, Window window)); /* 5 */ int (*tkpScanWindowId) _ANSI_ARGS_((Tcl_Interp * interp, CONST char * string, Window * idPtr)); /* 6 */ void (*tkpSetCapture) _ANSI_ARGS_((TkWindow * winPtr)); /* 7 */ void (*tkpSetCursor) _ANSI_ARGS_((TkpCursor cursor)); /* 8 */ void (*tkpWmSetState) _ANSI_ARGS_((TkWindow * winPtr, int state)); /* 9 */ void (*tkSetPixmapColormap) _ANSI_ARGS_((Pixmap pixmap, Colormap colormap)); /* 10 */ void (*tkWinCancelMouseTimer) _ANSI_ARGS_((void)); /* 11 */ void (*tkWinClipboardRender) _ANSI_ARGS_((TkDisplay * dispPtr, UINT format)); /* 12 */ LRESULT (*tkWinEmbeddedEventProc) _ANSI_ARGS_((HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam)); /* 13 */ void (*tkWinFillRect) _ANSI_ARGS_((HDC dc, int x, int y, int width, int height, int pixel)); /* 14 */ COLORREF (*tkWinGetBorderPixels) _ANSI_ARGS_((Tk_Window tkwin, Tk_3DBorder border, int which)); /* 15 */ HDC (*tkWinGetDrawableDC) _ANSI_ARGS_((Display * display, Drawable d, TkWinDCState* state)); /* 16 */ int (*tkWinGetModifierState) _ANSI_ARGS_((void)); /* 17 */ HPALETTE (*tkWinGetSystemPalette) _ANSI_ARGS_((void)); /* 18 */ HWND (*tkWinGetWrapperWindow) _ANSI_ARGS_((Tk_Window tkwin)); /* 19 */ int (*tkWinHandleMenuEvent) _ANSI_ARGS_((HWND * phwnd, UINT * pMessage, WPARAM * pwParam, LPARAM * plParam, LRESULT * plResult)); /* 20 */ int (*tkWinIndexOfColor) _ANSI_ARGS_((XColor * colorPtr)); /* 21 */ void (*tkWinReleaseDrawableDC) _ANSI_ARGS_((Drawable d, HDC hdc, TkWinDCState* state)); /* 22 */ LRESULT (*tkWinResendEvent) _ANSI_ARGS_((WNDPROC wndproc, HWND hwnd, XEvent * eventPtr)); /* 23 */ HPALETTE (*tkWinSelectPalette) _ANSI_ARGS_((HDC dc, Colormap colormap)); /* 24 */ void (*tkWinSetMenu) _ANSI_ARGS_((Tk_Window tkwin, HMENU hMenu)); /* 25 */ void (*tkWinSetWindowPos) _ANSI_ARGS_((HWND hwnd, HWND siblingHwnd, int pos)); /* 26 */ void (*tkWinWmCleanup) _ANSI_ARGS_((HINSTANCE hInstance)); /* 27 */ void (*tkWinXCleanup) _ANSI_ARGS_((ClientData clientData)); /* 28 */ void (*tkWinXInit) _ANSI_ARGS_((HINSTANCE hInstance)); /* 29 */ void (*tkWinSetForegroundWindow) _ANSI_ARGS_((TkWindow * winPtr)); /* 30 */ void (*tkWinDialogDebug) _ANSI_ARGS_((int debug)); /* 31 */ Tcl_Obj * (*tkWinGetMenuSystemDefault) _ANSI_ARGS_((Tk_Window tkwin, CONST char * dbName, CONST char * className)); /* 32 */ int (*tkWinGetPlatformId) _ANSI_ARGS_((void)); /* 33 */ void (*tkWinSetHINSTANCE) _ANSI_ARGS_((HINSTANCE hInstance)); /* 34 */ int (*tkWinGetPlatformTheme) _ANSI_ARGS_((void)); /* 35 */ #endif /* __WIN32__ */ #ifdef MAC_TCL void (*tkGenerateActivateEvents) _ANSI_ARGS_((TkWindow * winPtr, int active)); /* 0 */ void *reserved1; void *reserved2; unsigned long (*tkpGetMS) _ANSI_ARGS_((void)); /* 3 */ void *reserved4; void (*tkPointerDeadWindow) _ANSI_ARGS_((TkWindow * winPtr)); /* 5 */ void (*tkpSetCapture) _ANSI_ARGS_((TkWindow * winPtr)); /* 6 */ void (*tkpSetCursor) _ANSI_ARGS_((TkpCursor cursor)); /* 7 */ void (*tkpWmSetState) _ANSI_ARGS_((TkWindow * winPtr, int state)); /* 8 */ void *reserved9; void (*tkAboutDlg) _ANSI_ARGS_((void)); /* 10 */ void *reserved11; void *reserved12; Window (*tkGetTransientMaster) _ANSI_ARGS_((TkWindow * winPtr)); /* 13 */ int (*tkGenerateButtonEvent) _ANSI_ARGS_((int x, int y, Window window, unsigned int state)); /* 14 */ void *reserved15; void (*tkGenWMDestroyEvent) _ANSI_ARGS_((Tk_Window tkwin)); /* 16 */ void *reserved17; unsigned int (*tkMacButtonKeyState) _ANSI_ARGS_((void)); /* 18 */ void (*tkMacClearMenubarActive) _ANSI_ARGS_((void)); /* 19 */ void *reserved20; int (*tkMacDispatchMenuEvent) _ANSI_ARGS_((int menuID, int index)); /* 21 */ void (*tkMacInstallCursor) _ANSI_ARGS_((int resizeOverride)); /* 22 */ void *reserved23; void (*tkMacHandleTearoffMenu) _ANSI_ARGS_((void)); /* 24 */ void *reserved25; void *reserved26; void (*tkMacDoHLEvent) _ANSI_ARGS_((EventRecord * theEvent)); /* 27 */ void *reserved28; Time (*tkMacGenerateTime) _ANSI_ARGS_((void)); /* 29 */ void *reserved30; TkWindow * (*tkMacGetScrollbarGrowWindow) _ANSI_ARGS_((TkWindow * winPtr)); /* 31 */ Window (*tkMacGetXWindow) _ANSI_ARGS_((WindowRef macWinPtr)); /* 32 */ int (*tkMacGrowToplevel) _ANSI_ARGS_((WindowRef whichWindow, Point start)); /* 33 */ void (*tkMacHandleMenuSelect) _ANSI_ARGS_((long mResult, int optionKeyPressed)); /* 34 */ void *reserved35; void *reserved36; void *reserved37; void (*tkMacInvalidateWindow) _ANSI_ARGS_((MacDrawable * macWin, int flag)); /* 38 */ int (*tkMacIsCharacterMissing) _ANSI_ARGS_((Tk_Font tkfont, unsigned int searchChar)); /* 39 */ void (*tkMacMakeRealWindowExist) _ANSI_ARGS_((TkWindow * winPtr)); /* 40 */ BitMapPtr (*tkMacMakeStippleMap) _ANSI_ARGS_((Drawable d1, Drawable d2)); /* 41 */ void (*tkMacMenuClick) _ANSI_ARGS_((void)); /* 42 */ void (*tkMacRegisterOffScreenWindow) _ANSI_ARGS_((Window window, GWorldPtr portPtr)); /* 43 */ int (*tkMacResizable) _ANSI_ARGS_((TkWindow * winPtr)); /* 44 */ void *reserved45; void (*tkMacSetHelpMenuItemCount) _ANSI_ARGS_((void)); /* 46 */ void (*tkMacSetScrollbarGrow) _ANSI_ARGS_((TkWindow * winPtr, int flag)); /* 47 */ void (*tkMacSetUpClippingRgn) _ANSI_ARGS_((Drawable drawable)); /* 48 */ void (*tkMacSetUpGraphicsPort) _ANSI_ARGS_((GC gc)); /* 49 */ void (*tkMacUpdateClipRgn) _ANSI_ARGS_((TkWindow * winPtr)); /* 50 */ void (*tkMacUnregisterMacWindow) _ANSI_ARGS_((GWorldPtr portPtr)); /* 51 */ int (*tkMacUseMenuID) _ANSI_ARGS_((short macID)); /* 52 */ RgnHandle (*tkMacVisableClipRgn) _ANSI_ARGS_((TkWindow * winPtr)); /* 53 */ void (*tkMacWinBounds) _ANSI_ARGS_((TkWindow * winPtr, Rect * geometry)); /* 54 */ void (*tkMacWindowOffset) _ANSI_ARGS_((WindowRef wRef, int * xOffset, int * yOffset)); /* 55 */ void *reserved56; int (*tkSetMacColor) _ANSI_ARGS_((unsigned long pixel, RGBColor * macColor)); /* 57 */ void (*tkSetWMName) _ANSI_ARGS_((TkWindow * winPtr, Tk_Uid titleUid)); /* 58 */ void (*tkSuspendClipboard) _ANSI_ARGS_((void)); /* 59 */ void *reserved60; int (*tkMacZoomToplevel) _ANSI_ARGS_((WindowPtr whichWindow, Point where, short zoomPart)); /* 61 */ Tk_Window (*tk_TopCoordsToWindow) _ANSI_ARGS_((Tk_Window tkwin, int rootX, int rootY, int * newX, int * newY)); /* 62 */ MacDrawable * (*tkMacContainerId) _ANSI_ARGS_((TkWindow * winPtr)); /* 63 */ MacDrawable * (*tkMacGetHostToplevel) _ANSI_ARGS_((TkWindow * winPtr)); /* 64 */ void (*tkMacPreprocessMenu) _ANSI_ARGS_((void)); /* 65 */ int (*tkpIsWindowFloating) _ANSI_ARGS_((WindowRef window)); /* 66 */ #endif /* MAC_TCL */ #ifdef MAC_OSX_TK void (*tkGenerateActivateEvents) _ANSI_ARGS_((TkWindow * winPtr, int active)); /* 0 */ void *reserved1; void *reserved2; void (*tkPointerDeadWindow) _ANSI_ARGS_((TkWindow * winPtr)); /* 3 */ void (*tkpSetCapture) _ANSI_ARGS_((TkWindow * winPtr)); /* 4 */ void (*tkpSetCursor) _ANSI_ARGS_((TkpCursor cursor)); /* 5 */ void (*tkpWmSetState) _ANSI_ARGS_((TkWindow * winPtr, int state)); /* 6 */ void (*tkAboutDlg) _ANSI_ARGS_((void)); /* 7 */ unsigned int (*tkMacOSXButtonKeyState) _ANSI_ARGS_((void)); /* 8 */ void (*tkMacOSXClearMenubarActive) _ANSI_ARGS_((void)); /* 9 */ int (*tkMacOSXDispatchMenuEvent) _ANSI_ARGS_((int menuID, int index)); /* 10 */ void (*tkMacOSXInstallCursor) _ANSI_ARGS_((int resizeOverride)); /* 11 */ void (*tkMacOSXHandleTearoffMenu) _ANSI_ARGS_((void)); /* 12 */ void *reserved13; int (*tkMacOSXDoHLEvent) _ANSI_ARGS_((EventRecord * theEvent)); /* 14 */ void *reserved15; Window (*tkMacOSXGetXWindow) _ANSI_ARGS_((WindowRef macWinPtr)); /* 16 */ int (*tkMacOSXGrowToplevel) _ANSI_ARGS_((WindowRef whichWindow, Point start)); /* 17 */ void (*tkMacOSXHandleMenuSelect) _ANSI_ARGS_((long mResult, int optionKeyPressed)); /* 18 */ void *reserved19; void *reserved20; void (*tkMacOSXInvalidateWindow) _ANSI_ARGS_((MacDrawable * macWin, int flag)); /* 21 */ int (*tkMacOSXIsCharacterMissing) _ANSI_ARGS_((Tk_Font tkfont, unsigned int searchChar)); /* 22 */ void (*tkMacOSXMakeRealWindowExist) _ANSI_ARGS_((TkWindow * winPtr)); /* 23 */ BitMapPtr (*tkMacOSXMakeStippleMap) _ANSI_ARGS_((Drawable d1, Drawable d2)); /* 24 */ void (*tkMacOSXMenuClick) _ANSI_ARGS_((void)); /* 25 */ void (*tkMacOSXRegisterOffScreenWindow) _ANSI_ARGS_((Window window, GWorldPtr portPtr)); /* 26 */ int (*tkMacOSXResizable) _ANSI_ARGS_((TkWindow * winPtr)); /* 27 */ void (*tkMacOSXSetHelpMenuItemCount) _ANSI_ARGS_((void)); /* 28 */ void (*tkMacOSXSetScrollbarGrow) _ANSI_ARGS_((TkWindow * winPtr, int flag)); /* 29 */ void (*tkMacOSXSetUpClippingRgn) _ANSI_ARGS_((Drawable drawable)); /* 30 */ void (*tkMacOSXSetUpGraphicsPort) _ANSI_ARGS_((GC gc, GWorldPtr destPort)); /* 31 */ void (*tkMacOSXUpdateClipRgn) _ANSI_ARGS_((TkWindow * winPtr)); /* 32 */ void (*tkMacOSXUnregisterMacWindow) _ANSI_ARGS_((WindowRef portPtr)); /* 33 */ int (*tkMacOSXUseMenuID) _ANSI_ARGS_((short macID)); /* 34 */ RgnHandle (*tkMacOSXVisableClipRgn) _ANSI_ARGS_((TkWindow * winPtr)); /* 35 */ void (*tkMacOSXWinBounds) _ANSI_ARGS_((TkWindow * winPtr, Rect * geometry)); /* 36 */ void (*tkMacOSXWindowOffset) _ANSI_ARGS_((WindowRef wRef, int * xOffset, int * yOffset)); /* 37 */ int (*tkSetMacColor) _ANSI_ARGS_((unsigned long pixel, RGBColor * macColor)); /* 38 */ void (*tkSetWMName) _ANSI_ARGS_((TkWindow * winPtr, Tk_Uid titleUid)); /* 39 */ void (*tkSuspendClipboard) _ANSI_ARGS_((void)); /* 40 */ int (*tkMacOSXZoomToplevel) _ANSI_ARGS_((WindowPtr whichWindow, Point where, short zoomPart)); /* 41 */ Tk_Window (*tk_TopCoordsToWindow) _ANSI_ARGS_((Tk_Window tkwin, int rootX, int rootY, int * newX, int * newY)); /* 42 */ MacDrawable * (*tkMacOSXContainerId) _ANSI_ARGS_((TkWindow * winPtr)); /* 43 */ MacDrawable * (*tkMacOSXGetHostToplevel) _ANSI_ARGS_((TkWindow * winPtr)); /* 44 */ void (*tkMacOSXPreprocessMenu) _ANSI_ARGS_((void)); /* 45 */ int (*tkpIsWindowFloating) _ANSI_ARGS_((WindowRef window)); /* 46 */ Tk_Window (*tkMacOSXGetCapture) _ANSI_ARGS_((void)); /* 47 */ void *reserved48; Window (*tkGetTransientMaster) _ANSI_ARGS_((TkWindow * winPtr)); /* 49 */ int (*tkGenerateButtonEvent) _ANSI_ARGS_((int x, int y, Window window, unsigned int state)); /* 50 */ void (*tkGenWMDestroyEvent) _ANSI_ARGS_((Tk_Window tkwin)); /* 51 */ void *reserved52; unsigned long (*tkpGetMS) _ANSI_ARGS_((void)); /* 53 */ #endif /* MAC_OSX_TK */ #if !(defined(__WIN32__) || defined(MAC_TCL) || defined(MAC_OSX_TK)) /* X11 */ void (*tkCreateXEventSource) _ANSI_ARGS_((void)); /* 0 */ void (*tkFreeWindowId) _ANSI_ARGS_((TkDisplay * dispPtr, Window w)); /* 1 */ void (*tkInitXId) _ANSI_ARGS_((TkDisplay * dispPtr)); /* 2 */ int (*tkpCmapStressed) _ANSI_ARGS_((Tk_Window tkwin, Colormap colormap)); /* 3 */ void (*tkpSync) _ANSI_ARGS_((Display * display)); /* 4 */ Window (*tkUnixContainerId) _ANSI_ARGS_((TkWindow * winPtr)); /* 5 */ int (*tkUnixDoOneXEvent) _ANSI_ARGS_((Tcl_Time * timePtr)); /* 6 */ void (*tkUnixSetMenubar) _ANSI_ARGS_((Tk_Window tkwin, Tk_Window menubar)); /* 7 */ int (*tkpScanWindowId) _ANSI_ARGS_((Tcl_Interp * interp, CONST char * string, Window * idPtr)); /* 8 */ void (*tkWmCleanup) _ANSI_ARGS_((TkDisplay * dispPtr)); /* 9 */ void (*tkSendCleanup) _ANSI_ARGS_((TkDisplay * dispPtr)); /* 10 */ void (*tkFreeXId) _ANSI_ARGS_((TkDisplay * dispPtr)); /* 11 */ int (*tkpWmSetState) _ANSI_ARGS_((TkWindow * winPtr, int state)); /* 12 */ #endif /* X11 */ } TkIntPlatStubs; #ifdef __cplusplus extern "C" { #endif extern TkIntPlatStubs *tkIntPlatStubsPtr; #ifdef __cplusplus } #endif #if defined(USE_TK_STUBS) && !defined(USE_TK_STUB_PROCS) /* * Inline function declarations: */ #ifdef __WIN32__ #ifndef TkAlignImageData #define TkAlignImageData \ (tkIntPlatStubsPtr->tkAlignImageData) /* 0 */ #endif /* Slot 1 is reserved */ #ifndef TkGenerateActivateEvents #define TkGenerateActivateEvents \ (tkIntPlatStubsPtr->tkGenerateActivateEvents) /* 2 */ #endif #ifndef TkpGetMS #define TkpGetMS \ (tkIntPlatStubsPtr->tkpGetMS) /* 3 */ #endif #ifndef TkPointerDeadWindow #define TkPointerDeadWindow \ (tkIntPlatStubsPtr->tkPointerDeadWindow) /* 4 */ #endif #ifndef TkpPrintWindowId #define TkpPrintWindowId \ (tkIntPlatStubsPtr->tkpPrintWindowId) /* 5 */ #endif #ifndef TkpScanWindowId #define TkpScanWindowId \ (tkIntPlatStubsPtr->tkpScanWindowId) /* 6 */ #endif #ifndef TkpSetCapture #define TkpSetCapture \ (tkIntPlatStubsPtr->tkpSetCapture) /* 7 */ #endif #ifndef TkpSetCursor #define TkpSetCursor \ (tkIntPlatStubsPtr->tkpSetCursor) /* 8 */ #endif #ifndef TkpWmSetState #define TkpWmSetState \ (tkIntPlatStubsPtr->tkpWmSetState) /* 9 */ #endif #ifndef TkSetPixmapColormap #define TkSetPixmapColormap \ (tkIntPlatStubsPtr->tkSetPixmapColormap) /* 10 */ #endif #ifndef TkWinCancelMouseTimer #define TkWinCancelMouseTimer \ (tkIntPlatStubsPtr->tkWinCancelMouseTimer) /* 11 */ #endif #ifndef TkWinClipboardRender #define TkWinClipboardRender \ (tkIntPlatStubsPtr->tkWinClipboardRender) /* 12 */ #endif #ifndef TkWinEmbeddedEventProc #define TkWinEmbeddedEventProc \ (tkIntPlatStubsPtr->tkWinEmbeddedEventProc) /* 13 */ #endif #ifndef TkWinFillRect #define TkWinFillRect \ (tkIntPlatStubsPtr->tkWinFillRect) /* 14 */ #endif #ifndef TkWinGetBorderPixels #define TkWinGetBorderPixels \ (tkIntPlatStubsPtr->tkWinGetBorderPixels) /* 15 */ #endif #ifndef TkWinGetDrawableDC #define TkWinGetDrawableDC \ (tkIntPlatStubsPtr->tkWinGetDrawableDC) /* 16 */ #endif #ifndef TkWinGetModifierState #define TkWinGetModifierState \ (tkIntPlatStubsPtr->tkWinGetModifierState) /* 17 */ #endif #ifndef TkWinGetSystemPalette #define TkWinGetSystemPalette \ (tkIntPlatStubsPtr->tkWinGetSystemPalette) /* 18 */ #endif #ifndef TkWinGetWrapperWindow #define TkWinGetWrapperWindow \ (tkIntPlatStubsPtr->tkWinGetWrapperWindow) /* 19 */ #endif #ifndef TkWinHandleMenuEvent #define TkWinHandleMenuEvent \ (tkIntPlatStubsPtr->tkWinHandleMenuEvent) /* 20 */ #endif #ifndef TkWinIndexOfColor #define TkWinIndexOfColor \ (tkIntPlatStubsPtr->tkWinIndexOfColor) /* 21 */ #endif #ifndef TkWinReleaseDrawableDC #define TkWinReleaseDrawableDC \ (tkIntPlatStubsPtr->tkWinReleaseDrawableDC) /* 22 */ #endif #ifndef TkWinResendEvent #define TkWinResendEvent \ (tkIntPlatStubsPtr->tkWinResendEvent) /* 23 */ #endif #ifndef TkWinSelectPalette #define TkWinSelectPalette \ (tkIntPlatStubsPtr->tkWinSelectPalette) /* 24 */ #endif #ifndef TkWinSetMenu #define TkWinSetMenu \ (tkIntPlatStubsPtr->tkWinSetMenu) /* 25 */ #endif #ifndef TkWinSetWindowPos #define TkWinSetWindowPos \ (tkIntPlatStubsPtr->tkWinSetWindowPos) /* 26 */ #endif #ifndef TkWinWmCleanup #define TkWinWmCleanup \ (tkIntPlatStubsPtr->tkWinWmCleanup) /* 27 */ #endif #ifndef TkWinXCleanup #define TkWinXCleanup \ (tkIntPlatStubsPtr->tkWinXCleanup) /* 28 */ #endif #ifndef TkWinXInit #define TkWinXInit \ (tkIntPlatStubsPtr->tkWinXInit) /* 29 */ #endif #ifndef TkWinSetForegroundWindow #define TkWinSetForegroundWindow \ (tkIntPlatStubsPtr->tkWinSetForegroundWindow) /* 30 */ #endif #ifndef TkWinDialogDebug #define TkWinDialogDebug \ (tkIntPlatStubsPtr->tkWinDialogDebug) /* 31 */ #endif #ifndef TkWinGetMenuSystemDefault #define TkWinGetMenuSystemDefault \ (tkIntPlatStubsPtr->tkWinGetMenuSystemDefault) /* 32 */ #endif #ifndef TkWinGetPlatformId #define TkWinGetPlatformId \ (tkIntPlatStubsPtr->tkWinGetPlatformId) /* 33 */ #endif #ifndef TkWinSetHINSTANCE #define TkWinSetHINSTANCE \ (tkIntPlatStubsPtr->tkWinSetHINSTANCE) /* 34 */ #endif #ifndef TkWinGetPlatformTheme #define TkWinGetPlatformTheme \ (tkIntPlatStubsPtr->tkWinGetPlatformTheme) /* 35 */ #endif #endif /* __WIN32__ */ #ifdef MAC_TCL #ifndef TkGenerateActivateEvents #define TkGenerateActivateEvents \ (tkIntPlatStubsPtr->tkGenerateActivateEvents) /* 0 */ #endif /* Slot 1 is reserved */ /* Slot 2 is reserved */ #ifndef TkpGetMS #define TkpGetMS \ (tkIntPlatStubsPtr->tkpGetMS) /* 3 */ #endif /* Slot 4 is reserved */ #ifndef TkPointerDeadWindow #define TkPointerDeadWindow \ (tkIntPlatStubsPtr->tkPointerDeadWindow) /* 5 */ #endif #ifndef TkpSetCapture #define TkpSetCapture \ (tkIntPlatStubsPtr->tkpSetCapture) /* 6 */ #endif #ifndef TkpSetCursor #define TkpSetCursor \ (tkIntPlatStubsPtr->tkpSetCursor) /* 7 */ #endif #ifndef TkpWmSetState #define TkpWmSetState \ (tkIntPlatStubsPtr->tkpWmSetState) /* 8 */ #endif /* Slot 9 is reserved */ #ifndef TkAboutDlg #define TkAboutDlg \ (tkIntPlatStubsPtr->tkAboutDlg) /* 10 */ #endif /* Slot 11 is reserved */ /* Slot 12 is reserved */ #ifndef TkGetTransientMaster #define TkGetTransientMaster \ (tkIntPlatStubsPtr->tkGetTransientMaster) /* 13 */ #endif #ifndef TkGenerateButtonEvent #define TkGenerateButtonEvent \ (tkIntPlatStubsPtr->tkGenerateButtonEvent) /* 14 */ #endif /* Slot 15 is reserved */ #ifndef TkGenWMDestroyEvent #define TkGenWMDestroyEvent \ (tkIntPlatStubsPtr->tkGenWMDestroyEvent) /* 16 */ #endif /* Slot 17 is reserved */ #ifndef TkMacButtonKeyState #define TkMacButtonKeyState \ (tkIntPlatStubsPtr->tkMacButtonKeyState) /* 18 */ #endif #ifndef TkMacClearMenubarActive #define TkMacClearMenubarActive \ (tkIntPlatStubsPtr->tkMacClearMenubarActive) /* 19 */ #endif /* Slot 20 is reserved */ #ifndef TkMacDispatchMenuEvent #define TkMacDispatchMenuEvent \ (tkIntPlatStubsPtr->tkMacDispatchMenuEvent) /* 21 */ #endif #ifndef TkMacInstallCursor #define TkMacInstallCursor \ (tkIntPlatStubsPtr->tkMacInstallCursor) /* 22 */ #endif /* Slot 23 is reserved */ #ifndef TkMacHandleTearoffMenu #define TkMacHandleTearoffMenu \ (tkIntPlatStubsPtr->tkMacHandleTearoffMenu) /* 24 */ #endif /* Slot 25 is reserved */ /* Slot 26 is reserved */ #ifndef TkMacDoHLEvent #define TkMacDoHLEvent \ (tkIntPlatStubsPtr->tkMacDoHLEvent) /* 27 */ #endif /* Slot 28 is reserved */ #ifndef TkMacGenerateTime #define TkMacGenerateTime \ (tkIntPlatStubsPtr->tkMacGenerateTime) /* 29 */ #endif /* Slot 30 is reserved */ #ifndef TkMacGetScrollbarGrowWindow #define TkMacGetScrollbarGrowWindow \ (tkIntPlatStubsPtr->tkMacGetScrollbarGrowWindow) /* 31 */ #endif #ifndef TkMacGetXWindow #define TkMacGetXWindow \ (tkIntPlatStubsPtr->tkMacGetXWindow) /* 32 */ #endif #ifndef TkMacGrowToplevel #define TkMacGrowToplevel \ (tkIntPlatStubsPtr->tkMacGrowToplevel) /* 33 */ #endif #ifndef TkMacHandleMenuSelect #define TkMacHandleMenuSelect \ (tkIntPlatStubsPtr->tkMacHandleMenuSelect) /* 34 */ #endif /* Slot 35 is reserved */ /* Slot 36 is reserved */ /* Slot 37 is reserved */ #ifndef TkMacInvalidateWindow #define TkMacInvalidateWindow \ (tkIntPlatStubsPtr->tkMacInvalidateWindow) /* 38 */ #endif #ifndef TkMacIsCharacterMissing #define TkMacIsCharacterMissing \ (tkIntPlatStubsPtr->tkMacIsCharacterMissing) /* 39 */ #endif #ifndef TkMacMakeRealWindowExist #define TkMacMakeRealWindowExist \ (tkIntPlatStubsPtr->tkMacMakeRealWindowExist) /* 40 */ #endif #ifndef TkMacMakeStippleMap #define TkMacMakeStippleMap \ (tkIntPlatStubsPtr->tkMacMakeStippleMap) /* 41 */ #endif #ifndef TkMacMenuClick #define TkMacMenuClick \ (tkIntPlatStubsPtr->tkMacMenuClick) /* 42 */ #endif #ifndef TkMacRegisterOffScreenWindow #define TkMacRegisterOffScreenWindow \ (tkIntPlatStubsPtr->tkMacRegisterOffScreenWindow) /* 43 */ #endif #ifndef TkMacResizable #define TkMacResizable \ (tkIntPlatStubsPtr->tkMacResizable) /* 44 */ #endif /* Slot 45 is reserved */ #ifndef TkMacSetHelpMenuItemCount #define TkMacSetHelpMenuItemCount \ (tkIntPlatStubsPtr->tkMacSetHelpMenuItemCount) /* 46 */ #endif #ifndef TkMacSetScrollbarGrow #define TkMacSetScrollbarGrow \ (tkIntPlatStubsPtr->tkMacSetScrollbarGrow) /* 47 */ #endif #ifndef TkMacSetUpClippingRgn #define TkMacSetUpClippingRgn \ (tkIntPlatStubsPtr->tkMacSetUpClippingRgn) /* 48 */ #endif #ifndef TkMacSetUpGraphicsPort #define TkMacSetUpGraphicsPort \ (tkIntPlatStubsPtr->tkMacSetUpGraphicsPort) /* 49 */ #endif #ifndef TkMacUpdateClipRgn #define TkMacUpdateClipRgn \ (tkIntPlatStubsPtr->tkMacUpdateClipRgn) /* 50 */ #endif #ifndef TkMacUnregisterMacWindow #define TkMacUnregisterMacWindow \ (tkIntPlatStubsPtr->tkMacUnregisterMacWindow) /* 51 */ #endif #ifndef TkMacUseMenuID #define TkMacUseMenuID \ (tkIntPlatStubsPtr->tkMacUseMenuID) /* 52 */ #endif #ifndef TkMacVisableClipRgn #define TkMacVisableClipRgn \ (tkIntPlatStubsPtr->tkMacVisableClipRgn) /* 53 */ #endif #ifndef TkMacWinBounds #define TkMacWinBounds \ (tkIntPlatStubsPtr->tkMacWinBounds) /* 54 */ #endif #ifndef TkMacWindowOffset #define TkMacWindowOffset \ (tkIntPlatStubsPtr->tkMacWindowOffset) /* 55 */ #endif /* Slot 56 is reserved */ #ifndef TkSetMacColor #define TkSetMacColor \ (tkIntPlatStubsPtr->tkSetMacColor) /* 57 */ #endif #ifndef TkSetWMName #define TkSetWMName \ (tkIntPlatStubsPtr->tkSetWMName) /* 58 */ #endif #ifndef TkSuspendClipboard #define TkSuspendClipboard \ (tkIntPlatStubsPtr->tkSuspendClipboard) /* 59 */ #endif /* Slot 60 is reserved */ #ifndef TkMacZoomToplevel #define TkMacZoomToplevel \ (tkIntPlatStubsPtr->tkMacZoomToplevel) /* 61 */ #endif #ifndef Tk_TopCoordsToWindow #define Tk_TopCoordsToWindow \ (tkIntPlatStubsPtr->tk_TopCoordsToWindow) /* 62 */ #endif #ifndef TkMacContainerId #define TkMacContainerId \ (tkIntPlatStubsPtr->tkMacContainerId) /* 63 */ #endif #ifndef TkMacGetHostToplevel #define TkMacGetHostToplevel \ (tkIntPlatStubsPtr->tkMacGetHostToplevel) /* 64 */ #endif #ifndef TkMacPreprocessMenu #define TkMacPreprocessMenu \ (tkIntPlatStubsPtr->tkMacPreprocessMenu) /* 65 */ #endif #ifndef TkpIsWindowFloating #define TkpIsWindowFloating \ (tkIntPlatStubsPtr->tkpIsWindowFloating) /* 66 */ #endif #endif /* MAC_TCL */ #ifdef MAC_OSX_TK #ifndef TkGenerateActivateEvents #define TkGenerateActivateEvents \ (tkIntPlatStubsPtr->tkGenerateActivateEvents) /* 0 */ #endif /* Slot 1 is reserved */ /* Slot 2 is reserved */ #ifndef TkPointerDeadWindow #define TkPointerDeadWindow \ (tkIntPlatStubsPtr->tkPointerDeadWindow) /* 3 */ #endif #ifndef TkpSetCapture #define TkpSetCapture \ (tkIntPlatStubsPtr->tkpSetCapture) /* 4 */ #endif #ifndef TkpSetCursor #define TkpSetCursor \ (tkIntPlatStubsPtr->tkpSetCursor) /* 5 */ #endif #ifndef TkpWmSetState #define TkpWmSetState \ (tkIntPlatStubsPtr->tkpWmSetState) /* 6 */ #endif #ifndef TkAboutDlg #define TkAboutDlg \ (tkIntPlatStubsPtr->tkAboutDlg) /* 7 */ #endif #ifndef TkMacOSXButtonKeyState #define TkMacOSXButtonKeyState \ (tkIntPlatStubsPtr->tkMacOSXButtonKeyState) /* 8 */ #endif #ifndef TkMacOSXClearMenubarActive #define TkMacOSXClearMenubarActive \ (tkIntPlatStubsPtr->tkMacOSXClearMenubarActive) /* 9 */ #endif #ifndef TkMacOSXDispatchMenuEvent #define TkMacOSXDispatchMenuEvent \ (tkIntPlatStubsPtr->tkMacOSXDispatchMenuEvent) /* 10 */ #endif #ifndef TkMacOSXInstallCursor #define TkMacOSXInstallCursor \ (tkIntPlatStubsPtr->tkMacOSXInstallCursor) /* 11 */ #endif #ifndef TkMacOSXHandleTearoffMenu #define TkMacOSXHandleTearoffMenu \ (tkIntPlatStubsPtr->tkMacOSXHandleTearoffMenu) /* 12 */ #endif /* Slot 13 is reserved */ #ifndef TkMacOSXDoHLEvent #define TkMacOSXDoHLEvent \ (tkIntPlatStubsPtr->tkMacOSXDoHLEvent) /* 14 */ #endif /* Slot 15 is reserved */ #ifndef TkMacOSXGetXWindow #define TkMacOSXGetXWindow \ (tkIntPlatStubsPtr->tkMacOSXGetXWindow) /* 16 */ #endif #ifndef TkMacOSXGrowToplevel #define TkMacOSXGrowToplevel \ (tkIntPlatStubsPtr->tkMacOSXGrowToplevel) /* 17 */ #endif #ifndef TkMacOSXHandleMenuSelect #define TkMacOSXHandleMenuSelect \ (tkIntPlatStubsPtr->tkMacOSXHandleMenuSelect) /* 18 */ #endif /* Slot 19 is reserved */ /* Slot 20 is reserved */ #ifndef TkMacOSXInvalidateWindow #define TkMacOSXInvalidateWindow \ (tkIntPlatStubsPtr->tkMacOSXInvalidateWindow) /* 21 */ #endif #ifndef TkMacOSXIsCharacterMissing #define TkMacOSXIsCharacterMissing \ (tkIntPlatStubsPtr->tkMacOSXIsCharacterMissing) /* 22 */ #endif #ifndef TkMacOSXMakeRealWindowExist #define TkMacOSXMakeRealWindowExist \ (tkIntPlatStubsPtr->tkMacOSXMakeRealWindowExist) /* 23 */ #endif #ifndef TkMacOSXMakeStippleMap #define TkMacOSXMakeStippleMap \ (tkIntPlatStubsPtr->tkMacOSXMakeStippleMap) /* 24 */ #endif #ifndef TkMacOSXMenuClick #define TkMacOSXMenuClick \ (tkIntPlatStubsPtr->tkMacOSXMenuClick) /* 25 */ #endif #ifndef TkMacOSXRegisterOffScreenWindow #define TkMacOSXRegisterOffScreenWindow \ (tkIntPlatStubsPtr->tkMacOSXRegisterOffScreenWindow) /* 26 */ #endif #ifndef TkMacOSXResizable #define TkMacOSXResizable \ (tkIntPlatStubsPtr->tkMacOSXResizable) /* 27 */ #endif #ifndef TkMacOSXSetHelpMenuItemCount #define TkMacOSXSetHelpMenuItemCount \ (tkIntPlatStubsPtr->tkMacOSXSetHelpMenuItemCount) /* 28 */ #endif #ifndef TkMacOSXSetScrollbarGrow #define TkMacOSXSetScrollbarGrow \ (tkIntPlatStubsPtr->tkMacOSXSetScrollbarGrow) /* 29 */ #endif #ifndef TkMacOSXSetUpClippingRgn #define TkMacOSXSetUpClippingRgn \ (tkIntPlatStubsPtr->tkMacOSXSetUpClippingRgn) /* 30 */ #endif #ifndef TkMacOSXSetUpGraphicsPort #define TkMacOSXSetUpGraphicsPort \ (tkIntPlatStubsPtr->tkMacOSXSetUpGraphicsPort) /* 31 */ #endif #ifndef TkMacOSXUpdateClipRgn #define TkMacOSXUpdateClipRgn \ (tkIntPlatStubsPtr->tkMacOSXUpdateClipRgn) /* 32 */ #endif #ifndef TkMacOSXUnregisterMacWindow #define TkMacOSXUnregisterMacWindow \ (tkIntPlatStubsPtr->tkMacOSXUnregisterMacWindow) /* 33 */ #endif #ifndef TkMacOSXUseMenuID #define TkMacOSXUseMenuID \ (tkIntPlatStubsPtr->tkMacOSXUseMenuID) /* 34 */ #endif #ifndef TkMacOSXVisableClipRgn #define TkMacOSXVisableClipRgn \ (tkIntPlatStubsPtr->tkMacOSXVisableClipRgn) /* 35 */ #endif #ifndef TkMacOSXWinBounds #define TkMacOSXWinBounds \ (tkIntPlatStubsPtr->tkMacOSXWinBounds) /* 36 */ #endif #ifndef TkMacOSXWindowOffset #define TkMacOSXWindowOffset \ (tkIntPlatStubsPtr->tkMacOSXWindowOffset) /* 37 */ #endif #ifndef TkSetMacColor #define TkSetMacColor \ (tkIntPlatStubsPtr->tkSetMacColor) /* 38 */ #endif #ifndef TkSetWMName #define TkSetWMName \ (tkIntPlatStubsPtr->tkSetWMName) /* 39 */ #endif #ifndef TkSuspendClipboard #define TkSuspendClipboard \ (tkIntPlatStubsPtr->tkSuspendClipboard) /* 40 */ #endif #ifndef TkMacOSXZoomToplevel #define TkMacOSXZoomToplevel \ (tkIntPlatStubsPtr->tkMacOSXZoomToplevel) /* 41 */ #endif #ifndef Tk_TopCoordsToWindow #define Tk_TopCoordsToWindow \ (tkIntPlatStubsPtr->tk_TopCoordsToWindow) /* 42 */ #endif #ifndef TkMacOSXContainerId #define TkMacOSXContainerId \ (tkIntPlatStubsPtr->tkMacOSXContainerId) /* 43 */ #endif #ifndef TkMacOSXGetHostToplevel #define TkMacOSXGetHostToplevel \ (tkIntPlatStubsPtr->tkMacOSXGetHostToplevel) /* 44 */ #endif #ifndef TkMacOSXPreprocessMenu #define TkMacOSXPreprocessMenu \ (tkIntPlatStubsPtr->tkMacOSXPreprocessMenu) /* 45 */ #endif #ifndef TkpIsWindowFloating #define TkpIsWindowFloating \ (tkIntPlatStubsPtr->tkpIsWindowFloating) /* 46 */ #endif #ifndef TkMacOSXGetCapture #define TkMacOSXGetCapture \ (tkIntPlatStubsPtr->tkMacOSXGetCapture) /* 47 */ #endif /* Slot 48 is reserved */ #ifndef TkGetTransientMaster #define TkGetTransientMaster \ (tkIntPlatStubsPtr->tkGetTransientMaster) /* 49 */ #endif #ifndef TkGenerateButtonEvent #define TkGenerateButtonEvent \ (tkIntPlatStubsPtr->tkGenerateButtonEvent) /* 50 */ #endif #ifndef TkGenWMDestroyEvent #define TkGenWMDestroyEvent \ (tkIntPlatStubsPtr->tkGenWMDestroyEvent) /* 51 */ #endif /* Slot 52 is reserved */ #ifndef TkpGetMS #define TkpGetMS \ (tkIntPlatStubsPtr->tkpGetMS) /* 53 */ #endif #endif /* MAC_OSX_TK */ #if !(defined(__WIN32__) || defined(MAC_TCL) || defined(MAC_OSX_TK)) /* X11 */ #ifndef TkCreateXEventSource #define TkCreateXEventSource \ (tkIntPlatStubsPtr->tkCreateXEventSource) /* 0 */ #endif #ifndef TkFreeWindowId #define TkFreeWindowId \ (tkIntPlatStubsPtr->tkFreeWindowId) /* 1 */ #endif #ifndef TkInitXId #define TkInitXId \ (tkIntPlatStubsPtr->tkInitXId) /* 2 */ #endif #ifndef TkpCmapStressed #define TkpCmapStressed \ (tkIntPlatStubsPtr->tkpCmapStressed) /* 3 */ #endif #ifndef TkpSync #define TkpSync \ (tkIntPlatStubsPtr->tkpSync) /* 4 */ #endif