Tk Source Code

Check-in [f4527071]
Login

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:consistant use of mode: objc for OSX, strip spaces from the end of lines
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1: f4527071c7b6317895755fc2070a829c07a57a6a
User & Date: jan.nijtmans 2012-10-23 09:24:21
Context
2012-10-23
13:37
sync nmakehlp.c with Tcl version

purge spaces at end of lines

clean-up unix/Makefile.in after carbon removal

check-in: e67c5c61 user: jan.nijtmans tags: trunk
09:24
consistant use of mode: objc for OSX, strip spaces from the end of lines check-in: f4527071 user: jan.nijtmans tags: trunk
09:01
remove tkMacOSXCarbonEvents.c check-in: 6069d587 user: jan.nijtmans tags: core-8-5-branch
2012-10-18
03:56
merge-mark check-in: b7a8d62e user: jan.nijtmans tags: trunk
Changes
Hide Diffs Unified Diffs Ignore Whitespace Patch

Changes to ChangeLog.

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
2012-09-19  Jan Nijtmans  <[email protected]>

	* win/Makefile.in:    Compile win32 binaries with -DTCL_NO_DEPRECATED
	* win/tkiWinWm.c:     Fix gcc compiler warning.

2012-09-17  Don Porter  <[email protected]>

	*** 8.6b2 TAGGED FOR RELEASE ***
	
	* macosx/tkMacOSXWm.c: [Bug 3567786] Stop segfault in [wm forget].

2012-09-15  Don Porter  <[email protected]>

	* macosx/tkMacOSXFont.c: [Bug 3567778] Make Tk_MeasureChars() honor
	the TK_AT_LEAST_ONE flag properly.









|







1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
2012-09-19  Jan Nijtmans  <[email protected]>

	* win/Makefile.in:    Compile win32 binaries with -DTCL_NO_DEPRECATED
	* win/tkiWinWm.c:     Fix gcc compiler warning.

2012-09-17  Don Porter  <[email protected]>

	*** 8.6b2 TAGGED FOR RELEASE ***

	* macosx/tkMacOSXWm.c: [Bug 3567786] Stop segfault in [wm forget].

2012-09-15  Don Porter  <[email protected]>

	* macosx/tkMacOSXFont.c: [Bug 3567778] Make Tk_MeasureChars() honor
	the TK_AT_LEAST_ONE flag properly.

475
476
477
478
479
480
481
482
483
484
485
486
487
488
489

	* generic/tkText.c: [Bug-3021557]: Moving the cursor in
	* tests/text.test:  elided text freezes Tk

2011-12-22  Don Porter  <[email protected]>

	* win/tkWinMenu.c: [Bug 3235256] Keep menu entry IDs out of system
	values. Thanks Colin McDonald. 

2011-12-13  Donal K. Fellows  <[email protected]>

	* doc/getOpenFile.n: Make example follow best practices. Issue spotted
	by Emiliano Gavilan.

2011-11-29  Donal K. Fellows  <[email protected]>







|







475
476
477
478
479
480
481
482
483
484
485
486
487
488
489

	* generic/tkText.c: [Bug-3021557]: Moving the cursor in
	* tests/text.test:  elided text freezes Tk

2011-12-22  Don Porter  <[email protected]>

	* win/tkWinMenu.c: [Bug 3235256] Keep menu entry IDs out of system
	values. Thanks Colin McDonald.

2011-12-13  Donal K. Fellows  <[email protected]>

	* doc/getOpenFile.n: Make example follow best practices. Issue spotted
	by Emiliano Gavilan.

2011-11-29  Donal K. Fellows  <[email protected]>

Changes to changes.

3249
3250
3251
3252
3253
3254
3255
3256
3257
3258
3259
3260
3261
3262
3263
----------------- Released 4.2b1, 8/30/96 -----------------------

9/5/96 (bug fixes) Fixed several bugs in file dialogs: individual files
could be listed twice, if a long list of files were shown, and the view
scrolled to the right, and then a different file file was shown, the
scrollregion on the canvas wasn't being reset, so the file dialog was
broken from then on, added an update idletasks so that the watch
cursor was shown when the dialog was thinking. For the motif file 
dialog, fixed the weights for resizing.  On the clrpicker, fixed the
finalColor variable which caused problems when the OK button was
"clicked" before the dialog was mapped (in the test suite). Added Ioi's
last changes from before he left. For message boxes, if a single button
message box is shown (currently only 'ok'), it is set to be the default
even if not specified. (KC)








|







3249
3250
3251
3252
3253
3254
3255
3256
3257
3258
3259
3260
3261
3262
3263
----------------- Released 4.2b1, 8/30/96 -----------------------

9/5/96 (bug fixes) Fixed several bugs in file dialogs: individual files
could be listed twice, if a long list of files were shown, and the view
scrolled to the right, and then a different file file was shown, the
scrollregion on the canvas wasn't being reset, so the file dialog was
broken from then on, added an update idletasks so that the watch
cursor was shown when the dialog was thinking. For the motif file
dialog, fixed the weights for resizing.  On the clrpicker, fixed the
finalColor variable which caused problems when the OK button was
"clicked" before the dialog was mapped (in the test suite). Added Ioi's
last changes from before he left. For message boxes, if a single button
message box is shown (currently only 'ok'), it is set to be the default
even if not specified. (KC)

3297
3298
3299
3300
3301
3302
3303
3304
3305
3306
3307
3308
3309
3310
3311
3312
3313
3314
3315
3316
3317
9/26/96 (bug fix) The tests for the common dialogs still used the 'testevent'
function.  I updated these calls in clrpick.test, msgbox.test, filebox.test
to use the new event gereating mechanism.

9/18/96 (bug fix) Long-standing bug in bind where <Button-1><Button-1> was
reported as <Double-Button-1>, but <Double-Key-a> was reported as "aa". (CS)

9/27/96 (bug fix) Bindings didn't work on 64-bit machines due to changes 
made for virtual events. (CS)

9/30/96 (feature change) Binding for new virtual events included both 
lower and upper-case, e.g., <<Copy>> was defined as <Control-c> and 
<Control-C>.  Previously, widgets were directly bound to only lower-case
bindings.  The upper-case binding caused incompatibility with some existing 
Tcl programs, so the upper case bindings for <<Cut>>, <<Copy>>, and <<Paste>>
were removed. (CS)

9/30/96 (bug fix) The postscript code in the canvas widget now uses
channels to get and write .ps files which fixed a bug on the Mac where
an output file would have mixed EOL characters.  In addition, I added
the ability for the prolog to come from the Tk shared library on the







|


|
|

|







3297
3298
3299
3300
3301
3302
3303
3304
3305
3306
3307
3308
3309
3310
3311
3312
3313
3314
3315
3316
3317
9/26/96 (bug fix) The tests for the common dialogs still used the 'testevent'
function.  I updated these calls in clrpick.test, msgbox.test, filebox.test
to use the new event gereating mechanism.

9/18/96 (bug fix) Long-standing bug in bind where <Button-1><Button-1> was
reported as <Double-Button-1>, but <Double-Key-a> was reported as "aa". (CS)

9/27/96 (bug fix) Bindings didn't work on 64-bit machines due to changes
made for virtual events. (CS)

9/30/96 (feature change) Binding for new virtual events included both
lower and upper-case, e.g., <<Copy>> was defined as <Control-c> and
<Control-C>.  Previously, widgets were directly bound to only lower-case
bindings.  The upper-case binding caused incompatibility with some existing
Tcl programs, so the upper case bindings for <<Cut>>, <<Copy>>, and <<Paste>>
were removed. (CS)

9/30/96 (bug fix) The postscript code in the canvas widget now uses
channels to get and write .ps files which fixed a bug on the Mac where
an output file would have mixed EOL characters.  In addition, I added
the ability for the prolog to come from the Tk shared library on the
3329
3330
3331
3332
3333
3334
3335
3336
3337
3338
3339
3340
3341
3342
3343
10/1/96 (feature change)  "grid {column,row}configure <master> <index>"
returns a list of option value pairs for all of the row or column
constraints. It used to return an error. (SAU)

10/1/96 (bug fix)  "The way grid handles '^' short-cuts was re-written
to eliminate core dumps. (SAU)

10/3/96 (feature change) A virtual event binding associated with a 
given physical event is now considered less specific than a binding for
that same physical event, all other things being equal. (CS).

10/3/96 (bug fix) Under Windows text placed on the clipboard did not
undergo CRLF translation when delivered to other applications. (SS)

10/3/96 (bug fix) Copying an image onto itself with a zoom factor that







|







3329
3330
3331
3332
3333
3334
3335
3336
3337
3338
3339
3340
3341
3342
3343
10/1/96 (feature change)  "grid {column,row}configure <master> <index>"
returns a list of option value pairs for all of the row or column
constraints. It used to return an error. (SAU)

10/1/96 (bug fix)  "The way grid handles '^' short-cuts was re-written
to eliminate core dumps. (SAU)

10/3/96 (feature change) A virtual event binding associated with a
given physical event is now considered less specific than a binding for
that same physical event, all other things being equal. (CS).

10/3/96 (bug fix) Under Windows text placed on the clipboard did not
undergo CRLF translation when delivered to other applications. (SS)

10/3/96 (bug fix) Copying an image onto itself with a zoom factor that
3374
3375
3376
3377
3378
3379
3380
3381
3382
3383
3384
3385
3386
3387
3388
3389
3390
3391
3392
3393
3394
error due to a misplaced common in library/menu.tcl. (JO)

10/23/96 (bug fix) Errors in files sourced by the Macintosh
"Source..." menu are now correctly reported via the background
error mechanism. (RJ)

10/23/96 (bug fix) Fixed a bug in the Mac subwindow implementation
that caused refreshes to not occur for canvases with embedded 
windows. (RJ)

10/24/96 (bug fix) Provided workaround for Apple bug that doesn't
handle zooming correctly for floating windows. (RJ)

10/24/96 (bug fix) Macintosh tearoff menus are now correctly 
displayed as Mac floating windows. (RJ)

11/1/96 (bug fix) Restored manual page for procedures like
Tk_CreateWindowFromPath and Tk_DestroyWindow; was accidentally deleted
when Tk_CreateMainWindow procedure was decommissioned. (JO)

11/19/96 (bug fix) Fixed bugs in postscript code that would cause the







|





|







3374
3375
3376
3377
3378
3379
3380
3381
3382
3383
3384
3385
3386
3387
3388
3389
3390
3391
3392
3393
3394
error due to a misplaced common in library/menu.tcl. (JO)

10/23/96 (bug fix) Errors in files sourced by the Macintosh
"Source..." menu are now correctly reported via the background
error mechanism. (RJ)

10/23/96 (bug fix) Fixed a bug in the Mac subwindow implementation
that caused refreshes to not occur for canvases with embedded
windows. (RJ)

10/24/96 (bug fix) Provided workaround for Apple bug that doesn't
handle zooming correctly for floating windows. (RJ)

10/24/96 (bug fix) Macintosh tearoff menus are now correctly
displayed as Mac floating windows. (RJ)

11/1/96 (bug fix) Restored manual page for procedures like
Tk_CreateWindowFromPath and Tk_DestroyWindow; was accidentally deleted
when Tk_CreateMainWindow procedure was decommissioned. (JO)

11/19/96 (bug fix) Fixed bugs in postscript code that would cause the
3482
3483
3484
3485
3486
3487
3488
3489
3490
3491
3492
3493
3494
3495
3496
3497
3498
3499
if their master was destroyed, even if the transient window was not a
child of the master. (SS)

10/18/96 (new features) A -menu option has been added to the toplevel
widget command, which allows a menu to operate as a menubar. On the
Macintosh, the menubar is displayed accross the top of the main monitor,
just like with other applications. Under Windows and Unix, the menu is
attached to the toplevel window. Also, changed some semantics.  
Tearoff menus will now reflect changes to the menu it was 
torn off from, and are deleted when the master menu is
deleted. Tearoffs also reflect more look-and-feel of the 
platforms they are running on. (SRP)

10/31/96 (bug fix) Under Windows, missing system cursors would
generate an error instead of falling through to the Tk cursor of the
same name. (SS)

11/7/96 (feature change) Under Unix, default borderwidth is now 1 to







|
|

|







3482
3483
3484
3485
3486
3487
3488
3489
3490
3491
3492
3493
3494
3495
3496
3497
3498
3499
if their master was destroyed, even if the transient window was not a
child of the master. (SS)

10/18/96 (new features) A -menu option has been added to the toplevel
widget command, which allows a menu to operate as a menubar. On the
Macintosh, the menubar is displayed accross the top of the main monitor,
just like with other applications. Under Windows and Unix, the menu is
attached to the toplevel window. Also, changed some semantics.
Tearoff menus will now reflect changes to the menu it was
torn off from, and are deleted when the master menu is
deleted. Tearoffs also reflect more look-and-feel of the
platforms they are running on. (SRP)

10/31/96 (bug fix) Under Windows, missing system cursors would
generate an error instead of falling through to the Tk cursor of the
same name. (SS)

11/7/96 (feature change) Under Unix, default borderwidth is now 1 to
3571
3572
3573
3574
3575
3576
3577
3578
3579
3580
3581
3582
3583
3584
3585
3586
3587

12/17/96 (bug fix) Under Windows, command line was not being parsed
correctly if it contained the literal characters \" (CS)

12/17/96 (feature change) Native Windows labels do not get a focus-ring
border.  (CS)

12/17/96 (bug fix) Under Windows, colors specified as "#XXYYZZ" where XX, YY, 
or ZZ were not valid hex digits were getting a random color value instead of
being an error. (CS) 

----------------- Released 8.0a1, 12/17/96 -----------------------

12/23/96 (bug fix) Fixed two menu bugs:
    - Menus could get stacked below other windows so that they weren't
      visible when posted (especially under olvwm and fvwm).
    - Under olvwm if you pressed button 1 over an entry in a new-style







|

|







3571
3572
3573
3574
3575
3576
3577
3578
3579
3580
3581
3582
3583
3584
3585
3586
3587

12/17/96 (bug fix) Under Windows, command line was not being parsed
correctly if it contained the literal characters \" (CS)

12/17/96 (feature change) Native Windows labels do not get a focus-ring
border.  (CS)

12/17/96 (bug fix) Under Windows, colors specified as "#XXYYZZ" where XX, YY,
or ZZ were not valid hex digits were getting a random color value instead of
being an error. (CS)

----------------- Released 8.0a1, 12/17/96 -----------------------

12/23/96 (bug fix) Fixed two menu bugs:
    - Menus could get stacked below other windows so that they weren't
      visible when posted (especially under olvwm and fvwm).
    - Under olvwm if you pressed button 1 over an entry in a new-style
3595
3596
3597
3598
3599
3600
3601
3602
3603
3604
3605
3606
3607
3608
3609
3610
3611
3612
3613
3614
3615
3616
3617
3618
3619
3620
3621
3622
3623
3624
3625
1/6/97 (bug fix) Under Windows, the console was appearing even for
non-interactive applications.  This was a side effect of a general
problem with the wm state of windows that were being mapped for the
first time. (SS)

1/6/97 (bug fix) Under Windows, the initialization code was not
looking in the right directory for the Tk libraries when the program
being run was not in the Tcl installation heirarchy. (SS) 

1/8/97 (bug fix) Under Windows, the windows were not being unmapped
properly, which led to strange packer behavior. (SS)

1/8/97 (bug fix) The "winfo containing" command (and the Tk_CoordsToWindow
procedure) didn't work properly on Unix in the presence of embedding or
menubars. (JO)

1/15/97 (bug fix) Invoking "destroy ." as the command from a menu would
cause Tk to crash because TkMainInfo was freed before menu released its
resources.  This bug had already been fixed for scrollbars and buttons. (CS)

1/15/97 (bug fix) Tk is now working under Win32s again, including Win32 
version 1.25.  Fixed separate problems in fonts and dialogs. (CS)

1/15/97 (feature change) Under Windows, font sizes are now specified in 
points, not pixels.  The mapping between pointsize and pixels depends on
Windows having accurate metrics for the monitor (plug&play helps).  Font
metrics are still reported in pixels. (CS)

1/21/97 (bug fix)  Grid no longer reports rows or columns "out of range"
when requesting their constraints. (SAU)








|












|


|







3595
3596
3597
3598
3599
3600
3601
3602
3603
3604
3605
3606
3607
3608
3609
3610
3611
3612
3613
3614
3615
3616
3617
3618
3619
3620
3621
3622
3623
3624
3625
1/6/97 (bug fix) Under Windows, the console was appearing even for
non-interactive applications.  This was a side effect of a general
problem with the wm state of windows that were being mapped for the
first time. (SS)

1/6/97 (bug fix) Under Windows, the initialization code was not
looking in the right directory for the Tk libraries when the program
being run was not in the Tcl installation heirarchy. (SS)

1/8/97 (bug fix) Under Windows, the windows were not being unmapped
properly, which led to strange packer behavior. (SS)

1/8/97 (bug fix) The "winfo containing" command (and the Tk_CoordsToWindow
procedure) didn't work properly on Unix in the presence of embedding or
menubars. (JO)

1/15/97 (bug fix) Invoking "destroy ." as the command from a menu would
cause Tk to crash because TkMainInfo was freed before menu released its
resources.  This bug had already been fixed for scrollbars and buttons. (CS)

1/15/97 (bug fix) Tk is now working under Win32s again, including Win32
version 1.25.  Fixed separate problems in fonts and dialogs. (CS)

1/15/97 (feature change) Under Windows, font sizes are now specified in
points, not pixels.  The mapping between pointsize and pixels depends on
Windows having accurate metrics for the monitor (plug&play helps).  Font
metrics are still reported in pixels. (CS)

1/21/97 (bug fix)  Grid no longer reports rows or columns "out of range"
when requesting their constraints. (SAU)

3756
3757
3758
3759
3760
3761
3762
3763
3764
3765
3766
3767
3768
3769
3770

4/23/97 (feature change) Loosened the rules on parsing font names so that
unix-centric fonts in scripts don't break when run on Windows or Mac.
(1) Previously, an XLFD had to specify font name, weight, slant, and size;
now, a minimal XLFD (such as "*-times-*") will be accepted, and all
unspecified attributes will be given default values.  (2) Previously, in the
{name size style ...} format, only the style was optional; now both the size
and the style are optional; this solves the problem of old scripts that 
contain specifications of the form "-font fixed" or "-font times". (CCS)

5/7/97 (new feature) Menus now send a virtual event <<MenuSelect>>
when an item is highlighted in a menu. Applications can use this to
implement context-sensitive help. (SRP)

5/14/97 (bug fix) Fixed a race condition in the focus code where focus







|







3756
3757
3758
3759
3760
3761
3762
3763
3764
3765
3766
3767
3768
3769
3770

4/23/97 (feature change) Loosened the rules on parsing font names so that
unix-centric fonts in scripts don't break when run on Windows or Mac.
(1) Previously, an XLFD had to specify font name, weight, slant, and size;
now, a minimal XLFD (such as "*-times-*") will be accepted, and all
unspecified attributes will be given default values.  (2) Previously, in the
{name size style ...} format, only the style was optional; now both the size
and the style are optional; this solves the problem of old scripts that
contain specifications of the form "-font fixed" or "-font times". (CCS)

5/7/97 (new feature) Menus now send a virtual event <<MenuSelect>>
when an item is highlighted in a menu. Applications can use this to
implement context-sensitive help. (SRP)

5/14/97 (bug fix) Fixed a race condition in the focus code where focus
3791
3792
3793
3794
3795
3796
3797
3798
3799
3800
3801
3802
3803
3804
3805
5/30/97 (bug fix) Made the options to the grid command shortcut-able.
Ie. You can now use -stick, in addition to -sticky. (RJ)

6/2/97 (bug fix) Fixed bug in startup code that caused a problem in
finding the library files when they are installed in a directory
containing a space in the name. (SS)

6/2/97 (bug fix) Virtual events associated with <Enter>/<Leave> in text 
widget tag caused panic. (CCS)

6/6/97 (bug fix) On some systems, struct timeval.tv_sec is unsigned. (SS)

6/6/97 (feature change) Changed -default option on buttons to take
three states: normal, active, disabled.  This allows apps to have a
row of buttons where the default ring moves between buttons without







|







3791
3792
3793
3794
3795
3796
3797
3798
3799
3800
3801
3802
3803
3804
3805
5/30/97 (bug fix) Made the options to the grid command shortcut-able.
Ie. You can now use -stick, in addition to -sticky. (RJ)

6/2/97 (bug fix) Fixed bug in startup code that caused a problem in
finding the library files when they are installed in a directory
containing a space in the name. (SS)

6/2/97 (bug fix) Virtual events associated with <Enter>/<Leave> in text
widget tag caused panic. (CCS)

6/6/97 (bug fix) On some systems, struct timeval.tv_sec is unsigned. (SS)

6/6/97 (feature change) Changed -default option on buttons to take
three states: normal, active, disabled.  This allows apps to have a
row of buttons where the default ring moves between buttons without
3822
3823
3824
3825
3826
3827
3828
3829
3830
3831
3832
3833
3834
3835
3836

6/13/97 (bug fixes) In canvas text item: the insertion cursor wasn't shown
if insertion point was at end of text item, it was impossible to click to
position the insertion point after the last character, and @x,y indices were
computed incorrectly if -scrollregion had been specified and canvas was
scrolled. (CCS)

6/13/97 (bug fix) Hitting up/down arrows in a text widget packed in a 
toplevel window created with the "-screen" option would cause an error dialog
to pop up. (CCS)

6/12/97 (bug fix) Fixed bug in canvas text items where multi-line
selections were not highlighted properly.  This bug existed only in
earlier releases of Tk 8.0.  (JO)








|







3822
3823
3824
3825
3826
3827
3828
3829
3830
3831
3832
3833
3834
3835
3836

6/13/97 (bug fixes) In canvas text item: the insertion cursor wasn't shown
if insertion point was at end of text item, it was impossible to click to
position the insertion point after the last character, and @x,y indices were
computed incorrectly if -scrollregion had been specified and canvas was
scrolled. (CCS)

6/13/97 (bug fix) Hitting up/down arrows in a text widget packed in a
toplevel window created with the "-screen" option would cause an error dialog
to pop up. (CCS)

6/12/97 (bug fix) Fixed bug in canvas text items where multi-line
selections were not highlighted properly.  This bug existed only in
earlier releases of Tk 8.0.  (JO)

3895
3896
3897
3898
3899
3900
3901
3902
3903
3904
3905
3906
3907
3908
3909
7/11/97 (new feature) On the Mac, menus that are too big for the
screen will now scroll. This is part of the interface on the Mac,
impossible under Windows, and is not done for Unix. (SRP)

7/21/97 (bug fix) After fixing the bug that in canvas text item the insertion
cursor wasn't shown if insertion point was at end of text item, introduced a
different bug in where clicking in entry widget with 0 characters would
crash or display garbage. (CCS) 

7/22/97 (bug fix) If there were a whole bunch of returns or tabs in a row in
a canvas text item, then the temporary buffer used when outputting
postscript could overflow and overwrite the stack. (CCS)

7/23/97 (feature change) Reenabled "tkwait" in the Safe Tk base. (JL)








|







3895
3896
3897
3898
3899
3900
3901
3902
3903
3904
3905
3906
3907
3908
3909
7/11/97 (new feature) On the Mac, menus that are too big for the
screen will now scroll. This is part of the interface on the Mac,
impossible under Windows, and is not done for Unix. (SRP)

7/21/97 (bug fix) After fixing the bug that in canvas text item the insertion
cursor wasn't shown if insertion point was at end of text item, introduced a
different bug in where clicking in entry widget with 0 characters would
crash or display garbage. (CCS)

7/22/97 (bug fix) If there were a whole bunch of returns or tabs in a row in
a canvas text item, then the temporary buffer used when outputting
postscript could overflow and overwrite the stack. (CCS)

7/23/97 (feature change) Reenabled "tkwait" in the Safe Tk base. (JL)

3930
3931
3932
3933
3934
3935
3936
3937
3938
3939
3940
3941
3942
3943
3944

8/4/97 (bug fix) Fixed problem under USENIX where raising a toplevel
window could cause an X error if the window had just been withdrawn.  (JO)

8/4/97 (feature change) tkerror and bgerror are not anymore hard links
maintained by the Tcl core. The implementation of bgerror provided by
Tk tries, for backward compatibility only, to to call "tkerror" and
if that fails, falls back to the usual dialog and stack trace option 
posting. You can thus still use either "bgerror" or "tkerror" as your
application error handling proc, but using "bgerror" is strongly
recommended as support for "tkerror" will eventually vanish in upcoming
releases. (DL)
*** POTENTIAL INCOMPATIBILITY with scripts that were using
    the actual hardlink implementation 'features' and with
    scripts (if any) that would be calling the default "tkerror" to







|







3930
3931
3932
3933
3934
3935
3936
3937
3938
3939
3940
3941
3942
3943
3944

8/4/97 (bug fix) Fixed problem under USENIX where raising a toplevel
window could cause an X error if the window had just been withdrawn.  (JO)

8/4/97 (feature change) tkerror and bgerror are not anymore hard links
maintained by the Tcl core. The implementation of bgerror provided by
Tk tries, for backward compatibility only, to to call "tkerror" and
if that fails, falls back to the usual dialog and stack trace option
posting. You can thus still use either "bgerror" or "tkerror" as your
application error handling proc, but using "bgerror" is strongly
recommended as support for "tkerror" will eventually vanish in upcoming
releases. (DL)
*** POTENTIAL INCOMPATIBILITY with scripts that were using
    the actual hardlink implementation 'features' and with
    scripts (if any) that would be calling the default "tkerror" to
3952
3953
3954
3955
3956
3957
3958
3959
3960
3961
3962
3963
3964
3965
3966
8/7/97 (bug fix) Fixed focus to deal with embedding when there is
no window manager. (BW)

8/8/97 (bug fix) Fixed bug in photo image code where photo images from
different interpreters could get confused if they had the same name. (JO)

8/8/97 (new feature) Added new procedure Tk_GetImageMasterData for
mapping image names to master data.  (JO) 

8/8/97 (feature change) Modified Tk_FindPhoto procedure to require
extra "interp" argument (needed for bug fix above).  (JO)
*** POTENTIAL INCOMPATIBILITY ***

8/8/97 (bug fix) Fixed problems under Windows renaming toplevels with
menubars. Fixed problems on all platforms renaming menu widgets and







|







3952
3953
3954
3955
3956
3957
3958
3959
3960
3961
3962
3963
3964
3965
3966
8/7/97 (bug fix) Fixed focus to deal with embedding when there is
no window manager. (BW)

8/8/97 (bug fix) Fixed bug in photo image code where photo images from
different interpreters could get confused if they had the same name. (JO)

8/8/97 (new feature) Added new procedure Tk_GetImageMasterData for
mapping image names to master data.  (JO)

8/8/97 (feature change) Modified Tk_FindPhoto procedure to require
extra "interp" argument (needed for bug fix above).  (JO)
*** POTENTIAL INCOMPATIBILITY ***

8/8/97 (bug fix) Fixed problems under Windows renaming toplevels with
menubars. Fixed problems on all platforms renaming menu widgets and
4014
4015
4016
4017
4018
4019
4020
4021
4022
4023
4024
4025
4026
4027
4028
4029
4030

10/9/97 (bug fix) Image code could cause crashes during "exit" under
some conditions (such as an image named "place").  (JO)

10/9/97 (bug fix) Fixed bug that sometimes prevented listboxes from
scrolling far enough horizontally to see the rightmost character.  (JO)

10/10/97 (bug fix) In canvas text items, if the text ended with a \n, it 
was not counted in the bbox height, as it did in tk4.2.  This caused 
"hello\n" to be the same height as "hello" and you couldn't see the 
cursor positioned on the next line. (CCS)

10/10/97 (bug fix) The grid geometry manager didn't always properly
forget about windows after a "grid forget" or "grid remove" command:
the windows could reappear on the screen later.  (JO)

10/13/97 (bug fix) Selection could not be restored to a text widget







|
|
|







4014
4015
4016
4017
4018
4019
4020
4021
4022
4023
4024
4025
4026
4027
4028
4029
4030

10/9/97 (bug fix) Image code could cause crashes during "exit" under
some conditions (such as an image named "place").  (JO)

10/9/97 (bug fix) Fixed bug that sometimes prevented listboxes from
scrolling far enough horizontally to see the rightmost character.  (JO)

10/10/97 (bug fix) In canvas text items, if the text ended with a \n, it
was not counted in the bbox height, as it did in tk4.2.  This caused
"hello\n" to be the same height as "hello" and you couldn't see the
cursor positioned on the next line. (CCS)

10/10/97 (bug fix) The grid geometry manager didn't always properly
forget about windows after a "grid forget" or "grid remove" command:
the windows could reappear on the screen later.  (JO)

10/13/97 (bug fix) Selection could not be restored to a text widget
4064
4065
4066
4067
4068
4069
4070
4071
4072
4073
4074
4075
4076
4077
4078
4079
4080
4081
4082
4083
4084
4085
4086
4087
4088
4089
4090
4091
4092
4093
4094
4095
4096
4097
4098
4099
4100
4101
4102
4103
4104
4105
4106
4107
4108
4109
4110
4111
4112
4113
4114
4115
4116
4117
4118
different set of added items would crash. On all platforms, a command
menu entry that caused the entry to be deleted, another one created in
its place, and the replacement deleted would cause a panic. On Unix,
<<MenuSelect>> event bindings were firing every time the mouse moved,
instead of everytime the active menu item changed. (SRP)

10/27/97 (bug fix) If a particular race condition occurred under Windows,
Tk would crash complaining about trying to free a color that wasn't 
allocated. (SS)

10/28/97 (bug fix) Under Windows, button grabs did not report motion 
events that occurred outside of Tk windows. (SS)

10/28/97 (bug fix) Fixed incorrect display of transparent images on
the Macintosh. (JI)

10/29/97 (bug fix) Reworked the handling of out-of-range indices in
the widget command for listboxes: there were all sorts of quirks
before (e.g., ".l delete -1" actually deleted the first element
of the listbox). (JO)

10/29/97 (bug fix) Fixed crash on the Macintosh that could occur if a
window is moved before it is mapped where the X window was created but
the Macintosh port was not. (RJ)

10/29/97 (bug fix) Fixed several errors in how wm state was maintained
on the Macintosh.  Tk now also will iconify a toplevel window on the
Mac if the new Appearance Manager is present. (RJ)

10/28/97 (bug fixes) In canvas' postscript command: User name 
information was leaked in safe interpreters on Unix (security fix).
Errors while reading prolog.ps were not propagated and the error 
message was mixed with partial data. Note: postscript output does
not work in safe interpreters on unix and windows. (DL)

10/28/97 (bug fix) Safe Tk interps on unix were leaking env(DISPLAY). (DL)

10/31/97 (bug fix) Fixed problems related to the input focus when one
application had windows open simultaneously on several displays. (JO)

10/31/97 (bug fix) Fixed several problems with traversal of menus via
the keyboard under Unix. (SRP)

11/4/97 (bug fix) Fixed various word-size related problems for 64-bit
architectures. (SS)

11/5/97 (bug fix) Embedding on Windows was using freed data (crashing
in safe.test with TCL_MEM_DEBUG). NB: Embedding is still not fully 
implemented on Windows ! (It works mostly when Tk is embeded into it's
own Tk frame (safe::loadTk case), but not well with respect to resizing
with a toplevel container or with an external process). (DL)

----------------- Released 8.0p1, 11/7/97 -----------------------

11/20/97 (bug fix) Fixed bug on the Mac where the "package require"







|


|


















|

|















|







4064
4065
4066
4067
4068
4069
4070
4071
4072
4073
4074
4075
4076
4077
4078
4079
4080
4081
4082
4083
4084
4085
4086
4087
4088
4089
4090
4091
4092
4093
4094
4095
4096
4097
4098
4099
4100
4101
4102
4103
4104
4105
4106
4107
4108
4109
4110
4111
4112
4113
4114
4115
4116
4117
4118
different set of added items would crash. On all platforms, a command
menu entry that caused the entry to be deleted, another one created in
its place, and the replacement deleted would cause a panic. On Unix,
<<MenuSelect>> event bindings were firing every time the mouse moved,
instead of everytime the active menu item changed. (SRP)

10/27/97 (bug fix) If a particular race condition occurred under Windows,
Tk would crash complaining about trying to free a color that wasn't
allocated. (SS)

10/28/97 (bug fix) Under Windows, button grabs did not report motion
events that occurred outside of Tk windows. (SS)

10/28/97 (bug fix) Fixed incorrect display of transparent images on
the Macintosh. (JI)

10/29/97 (bug fix) Reworked the handling of out-of-range indices in
the widget command for listboxes: there were all sorts of quirks
before (e.g., ".l delete -1" actually deleted the first element
of the listbox). (JO)

10/29/97 (bug fix) Fixed crash on the Macintosh that could occur if a
window is moved before it is mapped where the X window was created but
the Macintosh port was not. (RJ)

10/29/97 (bug fix) Fixed several errors in how wm state was maintained
on the Macintosh.  Tk now also will iconify a toplevel window on the
Mac if the new Appearance Manager is present. (RJ)

10/28/97 (bug fixes) In canvas' postscript command: User name
information was leaked in safe interpreters on Unix (security fix).
Errors while reading prolog.ps were not propagated and the error
message was mixed with partial data. Note: postscript output does
not work in safe interpreters on unix and windows. (DL)

10/28/97 (bug fix) Safe Tk interps on unix were leaking env(DISPLAY). (DL)

10/31/97 (bug fix) Fixed problems related to the input focus when one
application had windows open simultaneously on several displays. (JO)

10/31/97 (bug fix) Fixed several problems with traversal of menus via
the keyboard under Unix. (SRP)

11/4/97 (bug fix) Fixed various word-size related problems for 64-bit
architectures. (SS)

11/5/97 (bug fix) Embedding on Windows was using freed data (crashing
in safe.test with TCL_MEM_DEBUG). NB: Embedding is still not fully
implemented on Windows ! (It works mostly when Tk is embeded into it's
own Tk frame (safe::loadTk case), but not well with respect to resizing
with a toplevel container or with an external process). (DL)

----------------- Released 8.0p1, 11/7/97 -----------------------

11/20/97 (bug fix) Fixed bug on the Mac where the "package require"
4136
4137
4138
4139
4140
4141
4142
4143
4144
4145
4146
4147
4148
4149
4150
4151
4152
4153
4154
4155
4156
4157
4158
4159
4160
4161
4162
4163
4164
4165
4166
4167
4168
4169
4170
4171
12/3/97 (bug fix/optimization) Removed unneeded and potentially dangerous
instances of double evaluations if "if" and "expr" statements from
the library files. It is recommended that unless you need a double
evaluation you always use "expr {...}" instead of "expr ..." and
"if {...} ..." instead of "if ... ...". It will also be faster
thanks to the byte compiler. (DL)

12/3/97 (new feature) Added support for browser/plugin style embedding, 
and made various other fixes to get the plugin working on the Mac. (JI)

12/8/97 (bug fix) on Windows, using "winfo pathname" before "." was mapped
was crashing. (DL)

---- Shipped as part of the plugin2.0b5 as 8.0p2Plugin1, Dec 8th 97 ----

12/97 (bug fix) more Macintosh embeding fixes needed for the plugin. (JI)

Jan/9/98 (improvement) Allow applications to have custom init script
without  having to patch the Tk core: Tk_Init will use an existing
"tkInit" proc if one exists in the interp where one tries to install Tk
instead of defining it's own (tkInit is the transient proc defined in
generic/tkInitScript.h that searches and sources tk.tcl and defines 
the 'correct' tk_library). (DL)

---- Shipped as part of the plugin2.0 as 8.0p2Plugin2, Jan 15th 98 ----

6/3/98 (bug fix) Fixed bugs in the tk_getOpenFile under Unix.
 1) If the -initialdir option was "." the result would be "././foo.tcl"
    instead of an absolute path, like the Windows interface.  
 2) There is a traceVar on the data(selectPath) where the script was
    assumes the window exists. (BS)

6/12/98 (feature change) Focus -force now sets the foreground window
on Windows platforms in addition to moving the focus. (SS)

6/12/98 (bug fix) Fixed bug in Windows font measurement that did not







|













|






|







4136
4137
4138
4139
4140
4141
4142
4143
4144
4145
4146
4147
4148
4149
4150
4151
4152
4153
4154
4155
4156
4157
4158
4159
4160
4161
4162
4163
4164
4165
4166
4167
4168
4169
4170
4171
12/3/97 (bug fix/optimization) Removed unneeded and potentially dangerous
instances of double evaluations if "if" and "expr" statements from
the library files. It is recommended that unless you need a double
evaluation you always use "expr {...}" instead of "expr ..." and
"if {...} ..." instead of "if ... ...". It will also be faster
thanks to the byte compiler. (DL)

12/3/97 (new feature) Added support for browser/plugin style embedding,
and made various other fixes to get the plugin working on the Mac. (JI)

12/8/97 (bug fix) on Windows, using "winfo pathname" before "." was mapped
was crashing. (DL)

---- Shipped as part of the plugin2.0b5 as 8.0p2Plugin1, Dec 8th 97 ----

12/97 (bug fix) more Macintosh embeding fixes needed for the plugin. (JI)

Jan/9/98 (improvement) Allow applications to have custom init script
without  having to patch the Tk core: Tk_Init will use an existing
"tkInit" proc if one exists in the interp where one tries to install Tk
instead of defining it's own (tkInit is the transient proc defined in
generic/tkInitScript.h that searches and sources tk.tcl and defines
the 'correct' tk_library). (DL)

---- Shipped as part of the plugin2.0 as 8.0p2Plugin2, Jan 15th 98 ----

6/3/98 (bug fix) Fixed bugs in the tk_getOpenFile under Unix.
 1) If the -initialdir option was "." the result would be "././foo.tcl"
    instead of an absolute path, like the Windows interface.
 2) There is a traceVar on the data(selectPath) where the script was
    assumes the window exists. (BS)

6/12/98 (feature change) Focus -force now sets the foreground window
on Windows platforms in addition to moving the focus. (SS)

6/12/98 (bug fix) Fixed bug in Windows font measurement that did not
4201
4202
4203
4204
4205
4206
4207
4208
4209
4210
4211
4212
4213
4214
4215
4216
4217
4218
comment at the top of generic/tkInitScript.h for more details. (SS)

7/27/98 (bug fix) The bbox for coords in the canvas were incorrectly
including the center of the coord as part of the bound area.  (RJ)

8/4/98 (bug fix) Fixed memory leak in Windows menu code. (SS)

8/4/98 (bug fix) Fixed bug where bgerror's were not being generated 
from menu callbacks on Windows. (SS)

8/4/98 (bug fix) Alt-key bindings were not being handled properly 
under Windows, resulting in annoying beeps. (SS)

8/4/98 (bug fix) Fixed bug in Windows menubar handling that allowed
a shared menubar to be deleted when any window using it was deleted. (SS)

8/4/98 (feature change) Introduced TkReadBitmapFile to replace
XReadBitmapFile so that all Tk file opens go through the Tcl channel







|


|







4201
4202
4203
4204
4205
4206
4207
4208
4209
4210
4211
4212
4213
4214
4215
4216
4217
4218
comment at the top of generic/tkInitScript.h for more details. (SS)

7/27/98 (bug fix) The bbox for coords in the canvas were incorrectly
including the center of the coord as part of the bound area.  (RJ)

8/4/98 (bug fix) Fixed memory leak in Windows menu code. (SS)

8/4/98 (bug fix) Fixed bug where bgerror's were not being generated
from menu callbacks on Windows. (SS)

8/4/98 (bug fix) Alt-key bindings were not being handled properly
under Windows, resulting in annoying beeps. (SS)

8/4/98 (bug fix) Fixed bug in Windows menubar handling that allowed
a shared menubar to be deleted when any window using it was deleted. (SS)

8/4/98 (feature change) Introduced TkReadBitmapFile to replace
XReadBitmapFile so that all Tk file opens go through the Tcl channel
4349
4350
4351
4352
4353
4354
4355
4356
4357
4358
4359
4360
4361
4362
4363
4364
4365
4366
1/16/98 (new feature) Tk now supports international characters sets:
    - Font display mechanism overhauled to display Unicode strings
      containing full set of international characters.  You do not need
      Unicode fonts on your system in order to use tk or see international
      characters.  For those familiar with the Japanese or Chinese patches,
      there is no "-kanjifont" option.  Characters from any available fonts
      will automatically be used if the widget's originally selected font is
      not capable of displaying a given character.  
    - Textual widgets are international aware.  For instance, cursor
      positioning commands would now move the cursor forwards/back by 1
      international character, not by 1 byte.  
    - Input Method Editors (IMEs) work on Mac and Windows.  Unix is still in
      progress.

7/7/97 (new feature) The send command now works for Microsoft
Windows. It is implemented using Dynamic Data Exchange, and a new
command, dde, allows Tk to send more generic DDE commands to other
applications. (SRP)







|


|







4349
4350
4351
4352
4353
4354
4355
4356
4357
4358
4359
4360
4361
4362
4363
4364
4365
4366
1/16/98 (new feature) Tk now supports international characters sets:
    - Font display mechanism overhauled to display Unicode strings
      containing full set of international characters.  You do not need
      Unicode fonts on your system in order to use tk or see international
      characters.  For those familiar with the Japanese or Chinese patches,
      there is no "-kanjifont" option.  Characters from any available fonts
      will automatically be used if the widget's originally selected font is
      not capable of displaying a given character.
    - Textual widgets are international aware.  For instance, cursor
      positioning commands would now move the cursor forwards/back by 1
      international character, not by 1 byte.
    - Input Method Editors (IMEs) work on Mac and Windows.  Unix is still in
      progress.

7/7/97 (new feature) The send command now works for Microsoft
Windows. It is implemented using Dynamic Data Exchange, and a new
command, dde, allows Tk to send more generic DDE commands to other
applications. (SRP)
4640
4641
4642
4643
4644
4645
4646
4647
4648
4649
4650
4651
4652
4653
4654
4655
4656
4657
4658
4659
4660
4661
4662
4663
4664
4665
4666
4667
7/22/99 (bug fix) Applied patch from Jeff Hobbs to fix
library/menu.tcl. [Bug: 2425] (redman)

7/22/99 (bug fix) Make install-sh have executable permissions before
calling from the Makefile. [Bug: 2413] (redman)

7/22/99 (bug fix) Block out sys/stat.h include with #if to allow
extension writers to use the MetroWerks compiler on Windows. 
[Bug: 2385] (redman)

7/29/99 (bug fix) Allow tcl to opn CON and NUL on Windows, moved check
to Tk Console code instead.  [Bug: 2393 2392 2209 2458] (redman)

7/30/99 (bug fix) corrected the Windows build of threaded Tk from both
sets of makefiles (nmake and gmake). (redman)

7/30/99 (bug fix) Added XFillRectangle to stub table, patch from Jan
Njitmans.  [Bug: 2446] (hobbs)

8/1/99  (bug fix) Wrapped #define of panic() inside #ifndef blocks to
avoid compiler errors on Macintosh.  Patch from Vince Darley.  
[Bug: 2389] (hobbs)

--------------- Released 8.2b2, August 5, 1999 ----------------------

8/13/99 (Mac) Rearranged the projects in the tkMacProjects.sea.hqx so
that the build directory is separate from the sources.  Fixed bug in
Tk_DrawChars(). (Jim Ingham)







|












|







4640
4641
4642
4643
4644
4645
4646
4647
4648
4649
4650
4651
4652
4653
4654
4655
4656
4657
4658
4659
4660
4661
4662
4663
4664
4665
4666
4667
7/22/99 (bug fix) Applied patch from Jeff Hobbs to fix
library/menu.tcl. [Bug: 2425] (redman)

7/22/99 (bug fix) Make install-sh have executable permissions before
calling from the Makefile. [Bug: 2413] (redman)

7/22/99 (bug fix) Block out sys/stat.h include with #if to allow
extension writers to use the MetroWerks compiler on Windows.
[Bug: 2385] (redman)

7/29/99 (bug fix) Allow tcl to opn CON and NUL on Windows, moved check
to Tk Console code instead.  [Bug: 2393 2392 2209 2458] (redman)

7/30/99 (bug fix) corrected the Windows build of threaded Tk from both
sets of makefiles (nmake and gmake). (redman)

7/30/99 (bug fix) Added XFillRectangle to stub table, patch from Jan
Njitmans.  [Bug: 2446] (hobbs)

8/1/99  (bug fix) Wrapped #define of panic() inside #ifndef blocks to
avoid compiler errors on Macintosh.  Patch from Vince Darley.
[Bug: 2389] (hobbs)

--------------- Released 8.2b2, August 5, 1999 ----------------------

8/13/99 (Mac) Rearranged the projects in the tkMacProjects.sea.hqx so
that the build directory is separate from the sources.  Fixed bug in
Tk_DrawChars(). (Jim Ingham)
5117
5118
5119
5120
5121
5122
5123
5124
5125
5126
5127
5128
5129
5130
5131

2001-10-17 (bug fix) updated Mac build support. (steffen)

--- Released 8.3.4, October 19, 2001 --- See ChangeLog for details ---

2001-08-14 (bug fix)[450545] Tk's Tcl_ObjTypes now registered (fellows)

2001-08-20 (performance enhancement) internal use of a "window" Tcl_ObjType 
(fellows)

2001-08-20 (performance enhancement) Obj-ified [grid] and [pack] (spjuth)

2001-09-26 (new feature)[TIP 18] add labels to frames, update geometry
managers (spjuth)








|







5117
5118
5119
5120
5121
5122
5123
5124
5125
5126
5127
5128
5129
5130
5131

2001-10-17 (bug fix) updated Mac build support. (steffen)

--- Released 8.3.4, October 19, 2001 --- See ChangeLog for details ---

2001-08-14 (bug fix)[450545] Tk's Tcl_ObjTypes now registered (fellows)

2001-08-20 (performance enhancement) internal use of a "window" Tcl_ObjType
(fellows)

2001-08-20 (performance enhancement) Obj-ified [grid] and [pack] (spjuth)

2001-09-26 (new feature)[TIP 18] add labels to frames, update geometry
managers (spjuth)

5883
5884
5885
5886
5887
5888
5889
5890
5891
5892
5893
5894
5895
5896
5897
5898
5899
5900
5901
5902
5903
5904
5905
5906
5907
5908
5909
5910
5911
5912
5913
5914
5915
5916
5917
5918
5919
5920
5921
5922
5923
5924
5925
5926
5927
5928
5929
5930
5931
5932
5933
5934
5935
5936
5937
5938
5939
5940
5941
5942
5943
5944
5945
5946

Updated test suite, documentation, and demos.

--- Released 8.5a2, December 7, 2004 --- See ChangeLog for details ---

2004-12-09 (performance)[1081966] BMP, JPG image load speed (fellows)

2004-12-17 (feature change) Modified DisplayFrame to draw a container's 
background when the embedded window is NULL (chengyemao)

2004-12-17 (bug fix)[842945][831627] Fixed a bug in ContainerEventProc  
to handle ConfigureNotify event properly; Changed CleanupContainList to 
TkWinCleanupContainerList to be invoked in TkWinXCleanup; Changed Intialize 
and CreateTopLevelWindow to create the DeleteWindowsExitProc after TkpInit 
so that finalization will be done in a proper sequence (to avoid painics 
and potential crashes in exit). (chengyemao)

2004-12-17 (platform support) Added TkWinClenupContainerList into stublib. 
(chengyemao)

2004-12-18 (buf fix)[222677] Close the embedded window (of a different 
process) when its container is destroyed. (chengyemao)

2004-12-19 (Windows feature implementation of embedded/embedding 
Tk and bug fix) Implemented container identification, focus, raise, set 
title of and move window so that an embedded widget is able to identify 
a container, to get focus and to receive key press input. Fixed bugs include 
[1024364][1096047] and an incorrect wm overrideredirect for an embedded 
window. (chengyemao)

2004-12-20 (Windows feature implementation of embedded/embedding Tk) 
Implemented overrideredirect for an embedded toplevel; correctly updated a 
frame's upper left x and y of an embedded toplevel after its container 
(of another process) moved. (chengyemao) 

2004-12-28 (feature implementatoin of embedded/embedding Tk of Windows) 
Implemented embedded/embedding toplevel menu. A menu may be embedded in 
a container of either the same process or a different process. Working 
fine with Windows 98. But having a problem when invoked with a mouse click 
(Windows XP): if an embedded menu is in a different process, the menu items 
may show as a blank window at the pull-down time and require the mouse 
moves over the menu items to complete display. (chengyemao)

2004-12-29 (platform support)[1092952,1091967] MSVC7, gcc OPT compiles (hobbs)

2005-01-03 (feature implementation of embedded/embedding Tk of Windows) Added
a separated window handler for an embedded menu; solved the problem of 
a blank menu display with a mouse click in XP. (chengyemao)

2005-01-07 (feature implementation of embedded/embedding Tk of Window) Added
TK_STATE message (Windows) to support {wm state} for embedded windows; forced
redraw of container after the embedded window detached; removed unnecessary
panic in using embedded window; embeded toplevel menu of an embedded window
automatically in wrapper updating.  Modified and added functions: WmStateCmd,
UpdateWrapper, TkpWmGetState (added) in tkWinWm.c; TkpUseWindow, 
TkWinEmbeddedEventProc in tkWinEmbed.c; TkWinChildProc in tkWinX.c. 
(chengyemao) 

2005-01-08 (bug fix)[1098625] Wrong toplevel geometry when created with a menu;
[637653] Deleting a popup menu crashes wish (chengyemao)

2005-01-09 (feature implementation of embedded/embedding Tk of Windows)
Changed FrameWidgetObjCmd (tkFrame.c), TkpUseWindow (tkMacOSXEmbed.c,
tkUnixEmbed.c, tkWinEmbed.c) to make implementation ready for a







|


|
|
|
|
|


|


|


|
|
|
|
|


|
|
|
|

|
|
|
|
|
|





|







|
|
|







5883
5884
5885
5886
5887
5888
5889
5890
5891
5892
5893
5894
5895
5896
5897
5898
5899
5900
5901
5902
5903
5904
5905
5906
5907
5908
5909
5910
5911
5912
5913
5914
5915
5916
5917
5918
5919
5920
5921
5922
5923
5924
5925
5926
5927
5928
5929
5930
5931
5932
5933
5934
5935
5936
5937
5938
5939
5940
5941
5942
5943
5944
5945
5946

Updated test suite, documentation, and demos.

--- Released 8.5a2, December 7, 2004 --- See ChangeLog for details ---

2004-12-09 (performance)[1081966] BMP, JPG image load speed (fellows)

2004-12-17 (feature change) Modified DisplayFrame to draw a container's
background when the embedded window is NULL (chengyemao)

2004-12-17 (bug fix)[842945][831627] Fixed a bug in ContainerEventProc
to handle ConfigureNotify event properly; Changed CleanupContainList to
TkWinCleanupContainerList to be invoked in TkWinXCleanup; Changed Intialize
and CreateTopLevelWindow to create the DeleteWindowsExitProc after TkpInit
so that finalization will be done in a proper sequence (to avoid painics
and potential crashes in exit). (chengyemao)

2004-12-17 (platform support) Added TkWinClenupContainerList into stublib.
(chengyemao)

2004-12-18 (buf fix)[222677] Close the embedded window (of a different
process) when its container is destroyed. (chengyemao)

2004-12-19 (Windows feature implementation of embedded/embedding
Tk and bug fix) Implemented container identification, focus, raise, set
title of and move window so that an embedded widget is able to identify
a container, to get focus and to receive key press input. Fixed bugs include
[1024364][1096047] and an incorrect wm overrideredirect for an embedded
window. (chengyemao)

2004-12-20 (Windows feature implementation of embedded/embedding Tk)
Implemented overrideredirect for an embedded toplevel; correctly updated a
frame's upper left x and y of an embedded toplevel after its container
(of another process) moved. (chengyemao)

2004-12-28 (feature implementatoin of embedded/embedding Tk of Windows)
Implemented embedded/embedding toplevel menu. A menu may be embedded in
a container of either the same process or a different process. Working
fine with Windows 98. But having a problem when invoked with a mouse click
(Windows XP): if an embedded menu is in a different process, the menu items
may show as a blank window at the pull-down time and require the mouse
moves over the menu items to complete display. (chengyemao)

2004-12-29 (platform support)[1092952,1091967] MSVC7, gcc OPT compiles (hobbs)

2005-01-03 (feature implementation of embedded/embedding Tk of Windows) Added
a separated window handler for an embedded menu; solved the problem of
a blank menu display with a mouse click in XP. (chengyemao)

2005-01-07 (feature implementation of embedded/embedding Tk of Window) Added
TK_STATE message (Windows) to support {wm state} for embedded windows; forced
redraw of container after the embedded window detached; removed unnecessary
panic in using embedded window; embeded toplevel menu of an embedded window
automatically in wrapper updating.  Modified and added functions: WmStateCmd,
UpdateWrapper, TkpWmGetState (added) in tkWinWm.c; TkpUseWindow,
TkWinEmbeddedEventProc in tkWinEmbed.c; TkWinChildProc in tkWinX.c.
(chengyemao)

2005-01-08 (bug fix)[1098625] Wrong toplevel geometry when created with a menu;
[637653] Deleting a popup menu crashes wish (chengyemao)

2005-01-09 (feature implementation of embedded/embedding Tk of Windows)
Changed FrameWidgetObjCmd (tkFrame.c), TkpUseWindow (tkMacOSXEmbed.c,
tkUnixEmbed.c, tkWinEmbed.c) to make implementation ready for a
6277
6278
6279
6280
6281
6282
6283
6284
6285
6286
6287
6288
6289
6290
6291
".sl") (hobbs)

2007-04-10 (platform support) Correctly handle theming on Vista/Aero (english)

2007-04-23 (enhancement) Allow empty value for -selectforeground opt (steffen)

2007-04-23 (platform support) Aqua: remove Tk-internal double buffering that is
wasteful on Aqua; allows direct-to-window CoreGraphics drawing (e.g. adding 
support for colors with alpha) (steffen)

2007-04-23 (platform support) Aqua: add all OS theme colors/brushes (patterns)
as system colors (steffen)

2007-04-23 (platform support) Aqua: tk_dialog & bgerror use OS theme (steffen)








|







6277
6278
6279
6280
6281
6282
6283
6284
6285
6286
6287
6288
6289
6290
6291
".sl") (hobbs)

2007-04-10 (platform support) Correctly handle theming on Vista/Aero (english)

2007-04-23 (enhancement) Allow empty value for -selectforeground opt (steffen)

2007-04-23 (platform support) Aqua: remove Tk-internal double buffering that is
wasteful on Aqua; allows direct-to-window CoreGraphics drawing (e.g. adding
support for colors with alpha) (steffen)

2007-04-23 (platform support) Aqua: add all OS theme colors/brushes (patterns)
as system colors (steffen)

2007-04-23 (platform support) Aqua: tk_dialog & bgerror use OS theme (steffen)

6438
6439
6440
6441
6442
6443
6444
6445
6446
6447
6448
6449
6450
6451
6452
2007-11-14 (bug fix)[1831803] sv.msg catalog for "sv" locale (fellows)

Many significant improvements to the documentation and demos (fellows, hobbs,
steffen, kupries)

--- Released 8.5b3, Novemeber 19, 2007 --- See ChangeLog for details ---

2007-11-25 (bug fix)[1343984] ttk::notebook bugs (english,boudaillier) 

2007-11-26 (bug fix)[1822391] [photo put] segfault w/ PPM data (kenny)

2007-11-26 (bug fix)[1822076] [tk_saveFile] and path w/spaces (bauer,kenny)

2007-12-04 (new feature)[1844143] Danish message catalog (berg)








|







6438
6439
6440
6441
6442
6443
6444
6445
6446
6447
6448
6449
6450
6451
6452
2007-11-14 (bug fix)[1831803] sv.msg catalog for "sv" locale (fellows)

Many significant improvements to the documentation and demos (fellows, hobbs,
steffen, kupries)

--- Released 8.5b3, Novemeber 19, 2007 --- See ChangeLog for details ---

2007-11-25 (bug fix)[1343984] ttk::notebook bugs (english,boudaillier)

2007-11-26 (bug fix)[1822391] [photo put] segfault w/ PPM data (kenny)

2007-11-26 (bug fix)[1822076] [tk_saveFile] and path w/spaces (bauer,kenny)

2007-12-04 (new feature)[1844143] Danish message catalog (berg)

6731
6732
6733
6734
6735
6736
6737
6738
6739
6740
6741
6742
6743
6744
6745
2009-08-04 (bug fix) [text] word-wrap of non-breaking space (fellows)

2009-08-14 (bug fix) copy from unmapped toplevel crash (alaoui,steffen)

2009-08-19 (bug fix)[2475855] prevent grid & pack on same master (spjuth)

2009-08-24 (bug fix)[2821084] Cocoa: let WM_DELETE_WINDOW handler stop window
deletion (walzer,steffen) 

2009-08-24 (bug fix) tk::MessageBox bindings for ttk::buttons (steiner,fellows)

2009-08-25 (bug fix)[1909931] [send] update for Fedora 8 (fellows)

2009-09-10 (bug fix) font allocation crash (berezhnoy,fellows)








|







6731
6732
6733
6734
6735
6736
6737
6738
6739
6740
6741
6742
6743
6744
6745
2009-08-04 (bug fix) [text] word-wrap of non-breaking space (fellows)

2009-08-14 (bug fix) copy from unmapped toplevel crash (alaoui,steffen)

2009-08-19 (bug fix)[2475855] prevent grid & pack on same master (spjuth)

2009-08-24 (bug fix)[2821084] Cocoa: let WM_DELETE_WINDOW handler stop window
deletion (walzer,steffen)

2009-08-24 (bug fix) tk::MessageBox bindings for ttk::buttons (steiner,fellows)

2009-08-25 (bug fix)[1909931] [send] update for Fedora 8 (fellows)

2009-09-10 (bug fix) font allocation crash (berezhnoy,fellows)

6785
6786
6787
6788
6789
6790
6791
6792
6793
6794
6795
6796
6797
6798
6799

2009-12-08 (bug fix)[2864685] Compiz menu item animation (gavilan,thoyts)

2009-12-11 (bug fix)[2912473] accept :: in DISPLAY name (fellows)

2009-12-15 (bug fix)[2492179] Tcl_ObjType "option" no longer registered (porter)
	*** POTENTIAL INCOMPATIBILITY for Tcl_GetObjType("option") ***
	
2009-12-20 (bug fix)[2917663] [send] accept SI:* on auth list (fellows)

2009-12-22 (bug fix)[2912356] [ttk::sizegrip] accommodate Compiz (english)

2009-12-25 (bug fix)[2977688,2546779] tab selection focus (english)

2009-12-27 (bug fix)[2879927] Win: cascade menu highlight (pawlak,thoyts)







|







6785
6786
6787
6788
6789
6790
6791
6792
6793
6794
6795
6796
6797
6798
6799

2009-12-08 (bug fix)[2864685] Compiz menu item animation (gavilan,thoyts)

2009-12-11 (bug fix)[2912473] accept :: in DISPLAY name (fellows)

2009-12-15 (bug fix)[2492179] Tcl_ObjType "option" no longer registered (porter)
	*** POTENTIAL INCOMPATIBILITY for Tcl_GetObjType("option") ***

2009-12-20 (bug fix)[2917663] [send] accept SI:* on auth list (fellows)

2009-12-22 (bug fix)[2912356] [ttk::sizegrip] accommodate Compiz (english)

2009-12-25 (bug fix)[2977688,2546779] tab selection focus (english)

2009-12-27 (bug fix)[2879927] Win: cascade menu highlight (pawlak,thoyts)

Changes to compat/unistd.h.

19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
#   include <tcl.h>
#endif

#ifndef NULL
#define NULL    0
#endif

/* 
 * Strict POSIX stuff goes here. Extensions go down below, in the ifndef
 * _POSIX_SOURCE section.
 */

extern void		_exit(int status);
extern int		access(const char *path, int mode);
extern int		chdir(const char *path);







|







19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
#   include <tcl.h>
#endif

#ifndef NULL
#define NULL    0
#endif

/*
 * Strict POSIX stuff goes here. Extensions go down below, in the ifndef
 * _POSIX_SOURCE section.
 */

extern void		_exit(int status);
extern int		access(const char *path, int mode);
extern int		chdir(const char *path);

Changes to license.terms.

25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
FITNESS FOR A PARTICULAR PURPOSE, AND NON-INFRINGEMENT.  THIS SOFTWARE
IS PROVIDED ON AN "AS IS" BASIS, AND THE AUTHORS AND DISTRIBUTORS HAVE
NO OBLIGATION TO PROVIDE MAINTENANCE, SUPPORT, UPDATES, ENHANCEMENTS, OR
MODIFICATIONS.

GOVERNMENT USE: If you are acquiring this software on behalf of the
U.S. government, the Government shall have only "Restricted Rights"
in the software and related documentation as defined in the Federal 
Acquisition Regulations (FARs) in Clause 52.227.19 (c) (2).  If you
are acquiring the software on behalf of the Department of Defense, the
software shall be classified as "Commercial Computer Software" and the
Government shall have only "Restricted Rights" as defined in Clause
252.227-7013 (b) (3) of DFARs.  Notwithstanding the foregoing, the
authors grant the U.S. Government and others acting in its behalf
permission to use and distribute the software in accordance with the







|







25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
FITNESS FOR A PARTICULAR PURPOSE, AND NON-INFRINGEMENT.  THIS SOFTWARE
IS PROVIDED ON AN "AS IS" BASIS, AND THE AUTHORS AND DISTRIBUTORS HAVE
NO OBLIGATION TO PROVIDE MAINTENANCE, SUPPORT, UPDATES, ENHANCEMENTS, OR
MODIFICATIONS.

GOVERNMENT USE: If you are acquiring this software on behalf of the
U.S. government, the Government shall have only "Restricted Rights"
in the software and related documentation as defined in the Federal
Acquisition Regulations (FARs) in Clause 52.227.19 (c) (2).  If you
are acquiring the software on behalf of the Department of Defense, the
software shall be classified as "Commercial Computer Software" and the
Government shall have only "Restricted Rights" as defined in Clause
252.227-7013 (b) (3) of DFARs.  Notwithstanding the foregoing, the
authors grant the U.S. Government and others acting in its behalf
permission to use and distribute the software in accordance with the

Changes to macosx/README.

28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
- There are two versions of Tk available on Mac OS X: TkAqua using the native
aqua widgets and look&feel, and TkX11 using the traditional unix X11 wigets.
TkX11 requires an X11 server to be installed, such as Apple's X11 (which is
available as an optional or default install on recent Mac OS X).
TkAqua and TkX11 can be distinguished at runtime via [tk windowingsystem].

- At a minimum, Mac OS X 10.3 is required to run Tcl and TkX11.
TkAqua requires Mac OS X 10.5 or later (starting with Tk 8.6b2).

- Unless weak-linking is used, Tcl/Tk built on Mac OS X 10.x will not run on
10.y with y < x; on the other hand Tcl/Tk built on 10.y will always run on 10.x
with y <= x (but without any of the fixes and optimizations that would be
available in a binary built on 10.x).
Weak-linking is available on OS X 10.2 or later, it additionally allows Tcl/Tk
built on 10.x to run on any 10.y with x > y >= z (for a chosen z >= 2).







|







28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
- There are two versions of Tk available on Mac OS X: TkAqua using the native
aqua widgets and look&feel, and TkX11 using the traditional unix X11 wigets.
TkX11 requires an X11 server to be installed, such as Apple's X11 (which is
available as an optional or default install on recent Mac OS X).
TkAqua and TkX11 can be distinguished at runtime via [tk windowingsystem].

- At a minimum, Mac OS X 10.3 is required to run Tcl and TkX11.
TkAqua requires Mac OS X 10.5 or later (starting with the Cocoa-based Tk 8.5.7).

- Unless weak-linking is used, Tcl/Tk built on Mac OS X 10.x will not run on
10.y with y < x; on the other hand Tcl/Tk built on 10.y will always run on 10.x
with y <= x (but without any of the fixes and optimizations that would be
available in a binary built on 10.x).
Weak-linking is available on OS X 10.2 or later, it additionally allows Tcl/Tk
built on 10.x to run on any 10.y with x > y >= z (for a chosen z >= 2).
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
the default behaviour of respecting the OS settings.

- Scrollbars: There are two scrollbar variants in Aqua, normal & small. The
normal scrollbar has a small dimension of 15, the small variant 11.
Access to the small variant was added in Tk 8.4.2.

- The default metrics of native buttons, radiobuttons, checkboxes and
menubuttons in the Cocoa-based Tk 8.6b2 and later preserve compatibility with
the older Carbon-based implementation, you can turn off the compatibility
metrics to get more native-looking spacing by setting:
	set tk::mac::useCompatibilityMetrics 0

- TkAqua provides access to native OS X images via the Tk native bitmap facility
(including any image file readable by NSImage). A native bitmap name is
interpreted as follows (in order):







|







101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
the default behaviour of respecting the OS settings.

- Scrollbars: There are two scrollbar variants in Aqua, normal & small. The
normal scrollbar has a small dimension of 15, the small variant 11.
Access to the small variant was added in Tk 8.4.2.

- The default metrics of native buttons, radiobuttons, checkboxes and
menubuttons in the Cocoa-based Tk 8.5.7 and later preserve compatibility with
the older Carbon-based implementation, you can turn off the compatibility
metrics to get more native-looking spacing by setting:
	set tk::mac::useCompatibilityMetrics 0

- TkAqua provides access to native OS X images via the Tk native bitmap facility
(including any image file readable by NSImage). A native bitmap name is
interpreted as follows (in order):
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
where -kind is one of
    -file	    icon of file at given path
    -fileType	    icon of given file type
    -osType	    icon of given 4-char OSType file type
    -systemType	    icon for given IconServices 4-char OSType
    -namedImage	    named NSImage for given name
    -imageFile	    image at given path
This support was added with the Cocoa-based Tk 8.6b2.

- TkAqua cursor names are interpred as follows (in order):
    - standard or platform-specific Tk cursor name (c.f. cursors.n)
    - @path to any image file readable by NSImage
    - NSImage named image name
Support for the latter two was added with the Cocoa-based Tk 8.6b2.

- The standard Tk dialog commands [tk_getOpenFile], [tk_chooseDirectory],
[tk_getSaveFile] and [tk_messageBox] all take an additional optional -command
parameter on TkAqua. If it is present, the given command prefix is evaluated at
the global level when the dialog closes, with the dialog command's result
appended (the dialog command itself returning an emtpy result). If the -parent
option is also present, the dialog is configured as a modeless (window-modal)
sheet attached to the parent window and the dialog command returns immediately.
Support for -command was added with the Cocoa-based Tk 8.6b2.

- The TkAqua-specific [tk::mac::standardAboutPanel] command brings the standard
Cocoa about panel to the front, with all its information filled in from your
application bundle files (i.e. standard about panel with no options specified).
See Apple Technote TN2179 and the AppKit documentation for -[NSApplication
orderFrontStandardAboutPanelWithOptions:] for details on the Info.plist keys and
app bundle files used by the about panel.
This support was added with the Cocoa-based Tk 8.6b2.

- TkAqua has three special menu names that give access to the standard
Application, Window and Help menus, see menu.n for details.
By default, the platform-specific standard Help menu item "YourApp Help" peforms
the default Cocoa action of showing the Help Book configured in the
application's Info.plist (or displaying an alert if no Help Book is set). This
action can be customized by defining a procedure named [tk::mac::ShowHelp], if
present, this procedure is invoked instead by the standard Help menu item.
Support for the Window menu and [tk::mac::ShowHelp] was added with the
Cocoa-based Tk 8.6b2.

- The TkAqua-specific command [tk::unsupported::MacWindowStyle style] is used to
get and set Mac OS X-specific toplevel window class and attributes. Note that
the window class and many attributes have to be set before the window is first
mapped for the change to have any effect.
The command has the following syntax:
	tk::unsupported::MacWindowStyle style window ?class? ?attributes?
The 2 argument form returns a list of the current class and attributes for the
given window. The 3 argument form sets the class for the given window using the
default attributes for that class. The 4 argument form sets the class and the
list of attributes for the given window.
Window class names:
    document, modal, floating, utility, toolbar, simple, help, overlay
Window attribute names:
    standardDocument, standardFloating, resizable, fullZoom, horizontalZoom,
    verticalZoom, closeBox, collapseBox, toolbarButton, sideTitlebar,
    noTitleBar, unifiedTitleAndToolbar, metal, hud, noShadow, doesNotCycle,
    noActivates, hideOnSuspend, inWindowMenu, ignoreClicks, doesNotHide,
    canJoinAllSpaces, moveToActiveSpace, nonActivating, black, dark, light,   
    gray, red, green, blue, cyan, yellow, magenta, orange, purple,
    brown, clear, opacity

Note that not all attributes are valid for all window classes.
Support for the 3 argument form was added with the Cocoa-based Tk 8.6b2, at the
same time support for some legacy Carbon-specific classes and attributes was
removed (they are still accepted by the command but no longer have any effect).

The color window attributes (black, dark, red, etc.) and the "opacity" allow  one to set the background and opacity of a textured ("metal") window. This allows a Tk window to implement a window without the dividing line between the titlebar and the rest of the window, or the "unified toolbar" effect, which is increasingly standard in Mac applications. An example:

toplevel .f
tk::unsupported::MacWindowStyle style .f document {metal light opaque closeBox collapseBox resizable standardDocument }

pack [label .f.f -bg  #ababab -text "This is a textured window\nwith opacity and a gray background\nsimilar to other Mac applications"] -fill both -expand yes

The color attributes correspond to system-defined NSColor constants (e.g., red is [NSColor redColor]. The "light" and "dark" attributes correspond to lightGrayColor and darkGrayColor, respectively (because of the way the attributes are parsed, using "lightgray" and "darkgray" would cause a conflict with the core "gray" attribute). 

Below are the corresponding hex and/or Tk-defined colors that can be used from Tk widgets to match the NSColor-based attributes:

black	#000000
dark	#545454
light	#ababab
white	#ffffff







|





|








|







|









|


















|




|










|







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
where -kind is one of
    -file	    icon of file at given path
    -fileType	    icon of given file type
    -osType	    icon of given 4-char OSType file type
    -systemType	    icon for given IconServices 4-char OSType
    -namedImage	    named NSImage for given name
    -imageFile	    image at given path
This support was added with the Cocoa-based Tk 8.5.7.

- TkAqua cursor names are interpred as follows (in order):
    - standard or platform-specific Tk cursor name (c.f. cursors.n)
    - @path to any image file readable by NSImage
    - NSImage named image name
Support for the latter two was added with the Cocoa-based Tk 8.5.7.

- The standard Tk dialog commands [tk_getOpenFile], [tk_chooseDirectory],
[tk_getSaveFile] and [tk_messageBox] all take an additional optional -command
parameter on TkAqua. If it is present, the given command prefix is evaluated at
the global level when the dialog closes, with the dialog command's result
appended (the dialog command itself returning an emtpy result). If the -parent
option is also present, the dialog is configured as a modeless (window-modal)
sheet attached to the parent window and the dialog command returns immediately.
Support for -command was added with the Cocoa-based Tk 8.5.7.

- The TkAqua-specific [tk::mac::standardAboutPanel] command brings the standard
Cocoa about panel to the front, with all its information filled in from your
application bundle files (i.e. standard about panel with no options specified).
See Apple Technote TN2179 and the AppKit documentation for -[NSApplication
orderFrontStandardAboutPanelWithOptions:] for details on the Info.plist keys and
app bundle files used by the about panel.
This support was added with the Cocoa-based Tk 8.5.7.

- TkAqua has three special menu names that give access to the standard
Application, Window and Help menus, see menu.n for details.
By default, the platform-specific standard Help menu item "YourApp Help" peforms
the default Cocoa action of showing the Help Book configured in the
application's Info.plist (or displaying an alert if no Help Book is set). This
action can be customized by defining a procedure named [tk::mac::ShowHelp], if
present, this procedure is invoked instead by the standard Help menu item.
Support for the Window menu and [tk::mac::ShowHelp] was added with the
Cocoa-based Tk 8.5.7.

- The TkAqua-specific command [tk::unsupported::MacWindowStyle style] is used to
get and set Mac OS X-specific toplevel window class and attributes. Note that
the window class and many attributes have to be set before the window is first
mapped for the change to have any effect.
The command has the following syntax:
	tk::unsupported::MacWindowStyle style window ?class? ?attributes?
The 2 argument form returns a list of the current class and attributes for the
given window. The 3 argument form sets the class for the given window using the
default attributes for that class. The 4 argument form sets the class and the
list of attributes for the given window.
Window class names:
    document, modal, floating, utility, toolbar, simple, help, overlay
Window attribute names:
    standardDocument, standardFloating, resizable, fullZoom, horizontalZoom,
    verticalZoom, closeBox, collapseBox, toolbarButton, sideTitlebar,
    noTitleBar, unifiedTitleAndToolbar, metal, hud, noShadow, doesNotCycle,
    noActivates, hideOnSuspend, inWindowMenu, ignoreClicks, doesNotHide,
    canJoinAllSpaces, moveToActiveSpace, nonActivating, black, dark, light,
    gray, red, green, blue, cyan, yellow, magenta, orange, purple,
    brown, clear, opacity

Note that not all attributes are valid for all window classes.
Support for the 3 argument form was added with the Cocoa-based Tk 8.5.7, at the
same time support for some legacy Carbon-specific classes and attributes was
removed (they are still accepted by the command but no longer have any effect).

The color window attributes (black, dark, red, etc.) and the "opacity" allow  one to set the background and opacity of a textured ("metal") window. This allows a Tk window to implement a window without the dividing line between the titlebar and the rest of the window, or the "unified toolbar" effect, which is increasingly standard in Mac applications. An example:

toplevel .f
tk::unsupported::MacWindowStyle style .f document {metal light opaque closeBox collapseBox resizable standardDocument }

pack [label .f.f -bg  #ababab -text "This is a textured window\nwith opacity and a gray background\nsimilar to other Mac applications"] -fill both -expand yes

The color attributes correspond to system-defined NSColor constants (e.g., red is [NSColor redColor]. The "light" and "dark" attributes correspond to lightGrayColor and darkGrayColor, respectively (because of the way the attributes are parsed, using "lightgray" and "darkgray" would cause a conflict with the core "gray" attribute).

Below are the corresponding hex and/or Tk-defined colors that can be used from Tk widgets to match the NSColor-based attributes:

black	#000000
dark	#545454
light	#ababab
white	#ffffff

Changes to macosx/Wish.sdef.

1
2
3
4
5
6
7
8
9
10
11
12
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE dictionary SYSTEM "file://localhost/System/Library/DTDs/sdef.dtd">
<!--
	Copyright (c) 1997 Sun Microsystems, Inc.
	Copyright 2009 Kevin Walzer/WordTech Communications LLC. 
	Copyright (c) 2009 Daniel A. Steffen <[email protected]>

	See the file "license.terms" for information on usage and redistribution of
	this file, and for a DISCLAIMER OF ALL WARRANTIES.
-->
<dictionary title="Wish Terminology">
	<suite name="Standard Suite" code="reqd" description="Common commands for all applications.">




|







1
2
3
4
5
6
7
8
9
10
11
12
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE dictionary SYSTEM "file://localhost/System/Library/DTDs/sdef.dtd">
<!--
	Copyright (c) 1997 Sun Microsystems, Inc.
	Copyright 2009 Kevin Walzer/WordTech Communications LLC.
	Copyright (c) 2009 Daniel A. Steffen <[email protected]>

	See the file "license.terms" for information on usage and redistribution of
	this file, and for a DISCLAIMER OF ALL WARRANTIES.
-->
<dictionary title="Wish Terminology">
	<suite name="Standard Suite" code="reqd" description="Common commands for all applications.">

Changes to macosx/configure.ac.

1
2
3
4
5
6
7
8
9
10
11
#! /bin/bash -norc
dnl	This file is an input file used by the GNU "autoconf" program to
dnl	generate the file "configure", which is run during Tk installation
dnl	to configure the system for the local environment.

dnl	Ensure that the config (auto)headers support is used, then just 
dnl	include the configure sources from ../unix:

m4_include(../unix/aclocal.m4)
m4_define(SC_USE_CONFIG_HEADERS)
m4_include(../unix/configure.in)





|





1
2
3
4
5
6
7
8
9
10
11
#! /bin/bash -norc
dnl	This file is an input file used by the GNU "autoconf" program to
dnl	generate the file "configure", which is run during Tk installation
dnl	to configure the system for the local environment.

dnl	Ensure that the config (auto)headers support is used, then just
dnl	include the configure sources from ../unix:

m4_include(../unix/aclocal.m4)
m4_define(SC_USE_CONFIG_HEADERS)
m4_include(../unix/configure.in)

Changes to macosx/tkMacOSXCursor.c.

280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
			bitmap, pix*pix/8, NULL);
		if (provider) {
		    img = CGImageCreate(pix, pix, 1, 1, pix/8, colorspace,
			    kCGBitmapByteOrderDefault, provider, decodeWB, 0,
			    kCGRenderingIntentDefault);
		    CFRelease(provider);
		}
		provider = CGDataProviderCreateWithData(NULL, bitmap + 
			pix*pix/8, pix*pix/8, NULL);
		if (provider) {
		    mask = CGImageMaskCreate(pix, pix, 1, 1, pix/8, provider,
			    decodeWB, 0);
		    CFRelease(provider);
		}
		if (img && mask) {







|







280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
			bitmap, pix*pix/8, NULL);
		if (provider) {
		    img = CGImageCreate(pix, pix, 1, 1, pix/8, colorspace,
			    kCGBitmapByteOrderDefault, provider, decodeWB, 0,
			    kCGRenderingIntentDefault);
		    CFRelease(provider);
		}
		provider = CGDataProviderCreateWithData(NULL, bitmap +
			pix*pix/8, pix*pix/8, NULL);
		if (provider) {
		    mask = CGImageMaskCreate(pix, pix, 1, 1, pix/8, provider,
			    decodeWB, 0);
		    CFRelease(provider);
		}
		if (img && mask) {

Changes to macosx/tkMacOSXDebug.c.

154
155
156
157
158
159
160
161
162
163
164
165
166
#endif /* __LP64__ */
    return addr;
}
#endif /* TK_MAC_DEBUG */

/*
 * Local Variables:
 * mode: c
 * c-basic-offset: 4
 * fill-column: 79
 * coding: utf-8
 * End:
 */







|





154
155
156
157
158
159
160
161
162
163
164
165
166
#endif /* __LP64__ */
    return addr;
}
#endif /* TK_MAC_DEBUG */

/*
 * Local Variables:
 * mode: objc
 * c-basic-offset: 4
 * fill-column: 79
 * coding: utf-8
 * End:
 */

Changes to macosx/tkMacOSXDialog.c.

29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
enum openOptions {
    OPEN_DEFAULT, OPEN_FILETYPES, OPEN_INITDIR, OPEN_INITFILE,
    OPEN_MESSAGE, OPEN_MULTIPLE, OPEN_PARENT, OPEN_TITLE,
    OPEN_TYPEVARIABLE, OPEN_COMMAND,
};
static const char *const saveOptionStrings[] = {
    "-defaultextension", "-filetypes", "-initialdir", "-initialfile",
    "-message", "-parent", "-title", "-typevariable", "-command", 
    "-confirmoverwrite", NULL
};
enum saveOptions {
    SAVE_DEFAULT, SAVE_FILETYPES, SAVE_INITDIR, SAVE_INITFILE,
    SAVE_MESSAGE, SAVE_PARENT, SAVE_TITLE, SAVE_TYPEVARIABLE, SAVE_COMMAND,
    SAVE_CONFIRMOW
};







|







29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
enum openOptions {
    OPEN_DEFAULT, OPEN_FILETYPES, OPEN_INITDIR, OPEN_INITFILE,
    OPEN_MESSAGE, OPEN_MULTIPLE, OPEN_PARENT, OPEN_TITLE,
    OPEN_TYPEVARIABLE, OPEN_COMMAND,
};
static const char *const saveOptionStrings[] = {
    "-defaultextension", "-filetypes", "-initialdir", "-initialfile",
    "-message", "-parent", "-title", "-typevariable", "-command",
    "-confirmoverwrite", NULL
};
enum saveOptions {
    SAVE_DEFAULT, SAVE_FILETYPES, SAVE_INITDIR, SAVE_INITFILE,
    SAVE_MESSAGE, SAVE_PARENT, SAVE_TITLE, SAVE_TYPEVARIABLE, SAVE_COMMAND,
    SAVE_CONFIRMOW
};

Changes to macosx/tkMacOSXEmbed.c.

1173
1174
1175
1176
1177
1178
1179
1180
1181
1182
1183
1184
1185
    Tk_Window tkParent,
    TkBusy busy)
{
}

/*
 * Local Variables:
 * mode: c
 * c-basic-offset: 4
 * fill-column: 79
 * coding: utf-8
 * End:
 */







|





1173
1174
1175
1176
1177
1178
1179
1180
1181
1182
1183
1184
1185
    Tk_Window tkParent,
    TkBusy busy)
{
}

/*
 * Local Variables:
 * mode: objc
 * c-basic-offset: 4
 * fill-column: 79
 * coding: utf-8
 * End:
 */

Changes to macosx/tkMacOSXEntry.c.

255
256
257
258
259
260
261
262
263
264
265
266
267
    ChkErr(HIThemeDrawButton, &bounds, &info, dc.context, HIOrientation, NULL);
    TkMacOSXRestoreDrawingContext(&dc);
    return 1;
}

/*
 * Local Variables:
 * mode: c
 * c-basic-offset: 4
 * fill-column: 79
 * coding: utf-8
 * End:
 */







|





255
256
257
258
259
260
261
262
263
264
265
266
267
    ChkErr(HIThemeDrawButton, &bounds, &info, dc.context, HIOrientation, NULL);
    TkMacOSXRestoreDrawingContext(&dc);
    return 1;
}

/*
 * Local Variables:
 * mode: objc
 * c-basic-offset: 4
 * fill-column: 79
 * coding: utf-8
 * End:
 */

Changes to macosx/tkMacOSXInit.c.

383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
	Tcl_SetVar(interp, "tk_library", tkLibPath, TCL_GLOBAL_ONLY);
    }

    if (scriptPath[0] != '\0') {
	Tcl_SetVar(interp, "auto_path", scriptPath,
		TCL_GLOBAL_ONLY|TCL_LIST_ELEMENT|TCL_APPEND_VALUE);
    }
    
    Tcl_CreateObjCommand(interp, "::tk::mac::standardAboutPanel",
	    TkMacOSXStandardAboutPanelObjCmd, NULL, NULL);
    Tcl_CreateObjCommand(interp, "::tk::mac::iconBitmap",
	    TkMacOSXIconBitmapObjCmd, NULL, NULL);

    return TCL_OK;
}







|







383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
	Tcl_SetVar(interp, "tk_library", tkLibPath, TCL_GLOBAL_ONLY);
    }

    if (scriptPath[0] != '\0') {
	Tcl_SetVar(interp, "auto_path", scriptPath,
		TCL_GLOBAL_ONLY|TCL_LIST_ELEMENT|TCL_APPEND_VALUE);
    }

    Tcl_CreateObjCommand(interp, "::tk::mac::standardAboutPanel",
	    TkMacOSXStandardAboutPanelObjCmd, NULL, NULL);
    Tcl_CreateObjCommand(interp, "::tk::mac::iconBitmap",
	    TkMacOSXIconBitmapObjCmd, NULL, NULL);

    return TCL_OK;
}

Changes to macosx/tkMacOSXRegion.c.

547
548
549
550
551
552
553
554
555
556
557
558
559

    result = HIShapeUnion(inShape1, inShape2, outResult);
    return result;
}

/*
 * Local Variables:
 * mode: c
 * c-basic-offset: 4
 * fill-column: 79
 * coding: utf-8
 * End:
 */







|





547
548
549
550
551
552
553
554
555
556
557
558
559

    result = HIShapeUnion(inShape1, inShape2, outResult);
    return result;
}

/*
 * Local Variables:
 * mode: objc
 * c-basic-offset: 4
 * fill-column: 79
 * coding: utf-8
 * End:
 */

Changes to macosx/tkMacOSXScale.c.

481
482
483
484
485
486
487
488
489
490
491
492
493
    TkMacOSXRunTclEventLoop();
    Tcl_Release((ClientData) scalePtr);
}
#endif

/*
 * Local Variables:
 * mode: c
 * c-basic-offset: 4
 * fill-column: 79
 * coding: utf-8
 * End:
 */







|





481
482
483
484
485
486
487
488
489
490
491
492
493
    TkMacOSXRunTclEventLoop();
    Tcl_Release((ClientData) scalePtr);
}
#endif

/*
 * Local Variables:
 * mode: objc
 * c-basic-offset: 4
 * fill-column: 79
 * coding: utf-8
 * End:
 */

Changes to macosx/tkMacOSXSend.c.

503
504
505
506
507
508
509
510
511
512
513
514
515
				 * interpreter is needed anyway). */
{
    return TCL_OK;
}

/*
 * Local Variables:
 * mode: c
 * c-basic-offset: 4
 * fill-column: 79
 * coding: utf-8
 * End:
 */







|





503
504
505
506
507
508
509
510
511
512
513
514
515
				 * interpreter is needed anyway). */
{
    return TCL_OK;
}

/*
 * Local Variables:
 * mode: objc
 * c-basic-offset: 4
 * fill-column: 79
 * coding: utf-8
 * End:
 */

Changes to macosx/tkMacOSXTest.c.

77
78
79
80
81
82
83
84
85
86
87
88
89
{
    Debugger();
    return TCL_OK;
}

/*
 * Local Variables:
 * mode: c
 * c-basic-offset: 4
 * fill-column: 79
 * coding: utf-8
 * End:
 */







|





77
78
79
80
81
82
83
84
85
86
87
88
89
{
    Debugger();
    return TCL_OK;
}

/*
 * Local Variables:
 * mode: objc
 * c-basic-offset: 4
 * fill-column: 79
 * coding: utf-8
 * End:
 */

Changes to macosx/tkMacOSXWindowEvent.c.

339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
    damageRgn = HIShapeCreateIntersection(updateRgn, boundsRgn);
    if (HIShapeIsEmpty(damageRgn)) {
	CFRelease(damageRgn);
	CFRelease(boundsRgn);
	return 0;
    }
    HIShapeGetBounds(damageRgn, &damageBounds);
   
    CFRelease(damageRgn);
    CFRelease(boundsRgn);

    event.xany.serial = LastKnownRequestProcessed(Tk_Display(winPtr));
    event.xany.send_event = false;
    event.xany.window = Tk_WindowId(winPtr);
    event.xany.display = Tk_Display(winPtr);







|







339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
    damageRgn = HIShapeCreateIntersection(updateRgn, boundsRgn);
    if (HIShapeIsEmpty(damageRgn)) {
	CFRelease(damageRgn);
	CFRelease(boundsRgn);
	return 0;
    }
    HIShapeGetBounds(damageRgn, &damageBounds);

    CFRelease(damageRgn);
    CFRelease(boundsRgn);

    event.xany.serial = LastKnownRequestProcessed(Tk_Display(winPtr));
    event.xany.send_event = false;
    event.xany.window = Tk_WindowId(winPtr);
    event.xany.display = Tk_Display(winPtr);

Changes to macosx/tkMacOSXWm.c.

1653
1654
1655
1656
1657
1658
1659
1660
1661
1662
1663
1664
1665
1666
1667
1668
1669
1670
1671
1672
1673
1674

	Tk_MakeWindowExist(winPtr);
	Tk_MakeWindowExist(winPtr->parentPtr);

	macWin = (MacDrawable *) winPtr->window;

    	TkFocusJoin(winPtr);
    	Tk_UnmapWindow(frameWin); 

	macWin->toplevel = winPtr->parentPtr->privatePtr->toplevel;
	macWin->flags &= ~TK_HOST_EXISTS;

	TkWmDeadWindow(winPtr);
	RemapWindows(winPtr, (MacDrawable *) winPtr->parentPtr->window);
       
	winPtr->flags &= ~(TK_TOP_HIERARCHY|TK_TOP_LEVEL|TK_HAS_WRAPPER|TK_WIN_MANAGED);

	/*
         * Flags (above) must be cleared before calling TkMapTopFrame (below).
         */

	TkMapTopFrame(frameWin);







|






|







1653
1654
1655
1656
1657
1658
1659
1660
1661
1662
1663
1664
1665
1666
1667
1668
1669
1670
1671
1672
1673
1674

	Tk_MakeWindowExist(winPtr);
	Tk_MakeWindowExist(winPtr->parentPtr);

	macWin = (MacDrawable *) winPtr->window;

    	TkFocusJoin(winPtr);
    	Tk_UnmapWindow(frameWin);

	macWin->toplevel = winPtr->parentPtr->privatePtr->toplevel;
	macWin->flags &= ~TK_HOST_EXISTS;

	TkWmDeadWindow(winPtr);
	RemapWindows(winPtr, (MacDrawable *) winPtr->parentPtr->window);

	winPtr->flags &= ~(TK_TOP_HIERARCHY|TK_TOP_LEVEL|TK_HAS_WRAPPER|TK_WIN_MANAGED);

	/*
         * Flags (above) must be cleared before calling TkMapTopFrame (below).
         */

	TkMapTopFrame(frameWin);
5324
5325
5326
5327
5328
5329
5330
5331
5332
5333
5334
5335
5336
5337
5338
	wmPtr->attributes &= (tkAlwaysValidAttributes |
		macClassAttrs[macClass].validAttrs);
	wmPtr->flags |= macClassAttrs[macClass].flags;
	wmPtr->macClass = macClass;

	ApplyWindowAttributeFlagChanges(winPtr, NULL, oldAttributes, oldFlags,
		0, 1);
 
	return TCL_OK;

    badClassAttrs:
	wmPtr->attributes = oldAttributes;
	return TCL_ERROR;
    }








|







5324
5325
5326
5327
5328
5329
5330
5331
5332
5333
5334
5335
5336
5337
5338
	wmPtr->attributes &= (tkAlwaysValidAttributes |
		macClassAttrs[macClass].validAttrs);
	wmPtr->flags |= macClassAttrs[macClass].flags;
	wmPtr->macClass = macClass;

	ApplyWindowAttributeFlagChanges(winPtr, NULL, oldAttributes, oldFlags,
		0, 1);

	return TCL_OK;

    badClassAttrs:
	wmPtr->attributes = oldAttributes;
	return TCL_ERROR;
    }

5488
5489
5490
5491
5492
5493
5494
5495
5496
5497
5498
5499
5500
5501
5502
5503
5504
5505
5506
5507
5508
5509
5510
5511
5512
	    !(styleMask & NSDocModalWindowMask)) {
        /*
	 * Workaround for [Bug 2824538]: Texured windows are draggable
	 *                               from opaque content.
	 */
	[window setMovableByWindowBackground:NO];
    }
   
    
    /* Set background color and opacity of window if those flags are set.  */
    if (colorName != NULL) {
    	[window setBackgroundColor: colorName];
    }

    if (opaqueTag != NULL) {
    	[window setOpaque: opaqueTag];
    }
	   
    [window setDocumentEdited:NO];
    wmPtr->window = window;
    macWin->view = contentView;
    TkMacOSXApplyWindowAttributes(winPtr, window);

    NSRect geometry = InitialWindowBounds(winPtr, window);
    geometry.size.width +=  structureRect.size.width;







|
|








|







5488
5489
5490
5491
5492
5493
5494
5495
5496
5497
5498
5499
5500
5501
5502
5503
5504
5505
5506
5507
5508
5509
5510
5511
5512
	    !(styleMask & NSDocModalWindowMask)) {
        /*
	 * Workaround for [Bug 2824538]: Texured windows are draggable
	 *                               from opaque content.
	 */
	[window setMovableByWindowBackground:NO];
    }


    /* Set background color and opacity of window if those flags are set.  */
    if (colorName != NULL) {
    	[window setBackgroundColor: colorName];
    }

    if (opaqueTag != NULL) {
    	[window setOpaque: opaqueTag];
    }

    [window setDocumentEdited:NO];
    wmPtr->window = window;
    macWin->view = contentView;
    TkMacOSXApplyWindowAttributes(winPtr, window);

    NSRect geometry = InitialWindowBounds(winPtr, window);
    geometry.size.width +=  structureRect.size.width;
6387
6388
6389
6390
6391
6392
6393
6394
6395
6396
6397
6398
6399
6400
6401
	prevMask = [window styleMask];
	prevPres = [NSApp presentationOptions];
	[window setStyleMask: NSBorderlessWindowMask];
	[NSApp setPresentationOptions: NSApplicationPresentationAutoHideDock
	                          | NSApplicationPresentationAutoHideMenuBar];

    } else {
	wmPtr->flags &= ~WM_FULLSCREEN; 

	[NSApp setPresentationOptions: prevPres];
	[window setStyleMask: prevMask];
    }

    if (wasFullscreen && !(wmPtr->flags & WM_FULLSCREEN)) {
	UInt64 oldAttributes = wmPtr->attributes;







|







6387
6388
6389
6390
6391
6392
6393
6394
6395
6396
6397
6398
6399
6400
6401
	prevMask = [window styleMask];
	prevPres = [NSApp presentationOptions];
	[window setStyleMask: NSBorderlessWindowMask];
	[NSApp setPresentationOptions: NSApplicationPresentationAutoHideDock
	                          | NSApplicationPresentationAutoHideMenuBar];

    } else {
	wmPtr->flags &= ~WM_FULLSCREEN;

	[NSApp setPresentationOptions: prevPres];
	[window setStyleMask: prevMask];
    }

    if (wasFullscreen && !(wmPtr->flags & WM_FULLSCREEN)) {
	UInt64 oldAttributes = wmPtr->attributes;

Changes to macosx/ttkMacOSXTheme.c.

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
/*
 * ttkMacOSXTheme.c --
 *
 *	Tk theme engine for Mac OSX, using the Appearance Manager API.
 *
 * Copyright (c) 2004 Joe English
 * Copyright (c) 2005 Neil Madden
 * Copyright (c) 2006-2009 Daniel A. Steffen <[email protected]>
 * Copyright 2008-2009, Apple Inc.
 * Copyright 2009 Kevin Walzer/WordTech Communications LLC. 
 *
 * See the file "license.terms" for information on usage and redistribution
 * of this file, and for a DISCLAIMER OF ALL WARRANTIES.
 *
 * See also:
 *
 * <URL: http://developer.apple.com/documentation/Carbon/Reference/









|







1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
/*
 * ttkMacOSXTheme.c --
 *
 *	Tk theme engine for Mac OSX, using the Appearance Manager API.
 *
 * Copyright (c) 2004 Joe English
 * Copyright (c) 2005 Neil Madden
 * Copyright (c) 2006-2009 Daniel A. Steffen <[email protected]>
 * Copyright 2008-2009, Apple Inc.
 * Copyright 2009 Kevin Walzer/WordTech Communications LLC.
 *
 * See the file "license.terms" for information on usage and redistribution
 * of this file, and for a DISCLAIMER OF ALL WARRANTIES.
 *
 * See also:
 *
 * <URL: http://developer.apple.com/documentation/Carbon/Reference/
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
    HIThemeTabDrawInfo info = {
	.version = 1,
	.style = Ttk_StateTableLookup(TabStyleTable, state),
	.direction = kThemeTabNorth,
	.size = kHIThemeTabSizeNormal,
	.adornment = Ttk_StateTableLookup(TabAdornmentTable, state),
	.kind = kHIThemeTabKindNormal,
	.position = Ttk_StateTableLookup(TabPositionTable, state), 
    };

    bounds.size.height += TAB_OVERLAP;
    BEGIN_DRAWING(d)
    ChkErr(HIThemeDrawTab, &bounds, &info, dc.context, HIOrientation, NULL);
    END_DRAWING
}







|







312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
    HIThemeTabDrawInfo info = {
	.version = 1,
	.style = Ttk_StateTableLookup(TabStyleTable, state),
	.direction = kThemeTabNorth,
	.size = kHIThemeTabSizeNormal,
	.adornment = Ttk_StateTableLookup(TabAdornmentTable, state),
	.kind = kHIThemeTabKindNormal,
	.position = Ttk_StateTableLookup(TabPositionTable, state),
    };

    bounds.size.height += TAB_OVERLAP;
    BEGIN_DRAWING(d)
    ChkErr(HIThemeDrawTab, &bounds, &info, dc.context, HIOrientation, NULL);
    END_DRAWING
}
1190
1191
1192
1193
1194
1195
1196
1197
1198
1199
1200
1201
1202
1203
int Ttk_MacOSXPlatformInit(Tcl_Interp *interp)
{
    return AquaTheme_Init(interp);
}

/*
 * Local Variables:
 * mode: c
 * c-basic-offset: 4
 * fill-column: 79
 * coding: utf-8
 * End:
 */








|






1190
1191
1192
1193
1194
1195
1196
1197
1198
1199
1200
1201
1202
1203
int Ttk_MacOSXPlatformInit(Tcl_Interp *interp)
{
    return AquaTheme_Init(interp);
}

/*
 * Local Variables:
 * mode: objc
 * c-basic-offset: 4
 * fill-column: 79
 * coding: utf-8
 * End:
 */

Changes to unix/tkUnixWm.c.

6414
6415
6416
6417
6418
6419
6420
6421
6422
6423
6424
6425
6426
6427
6428
	    if (hPtr != NULL) {
		childWinPtr = Tcl_GetHashValue(hPtr);
		*window_ptr++ = childWinPtr;
	    }
	}

	/*
	 * ASSERT: window_ptr - windows == table.numEntries 
	 * (#matched toplevel windows == #children) [Bug 1789819]
	 */

	*window_ptr = NULL;
	if (numChildren) {
	    XFree((char *) children);
	}







|







6414
6415
6416
6417
6418
6419
6420
6421
6422
6423
6424
6425
6426
6427
6428
	    if (hPtr != NULL) {
		childWinPtr = Tcl_GetHashValue(hPtr);
		*window_ptr++ = childWinPtr;
	    }
	}

	/*
	 * ASSERT: window_ptr - windows == table.numEntries
	 * (#matched toplevel windows == #children) [Bug 1789819]
	 */

	*window_ptr = NULL;
	if (numChildren) {
	    XFree((char *) children);
	}

Changes to xlib/X11/X.h.

9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29

/***********************************************************
Copyright 1987 by Digital Equipment Corporation, Maynard, Massachusetts,
and the Massachusetts Institute of Technology, Cambridge, Massachusetts.

                        All Rights Reserved

Permission to use, copy, modify, and distribute this software and its 
documentation for any purpose and without fee is hereby granted, 
provided that the above copyright notice appear in all copies and that
both that copyright notice and this permission notice appear in 
supporting documentation, and that the names of Digital or MIT not be
used in advertising or publicity pertaining to distribution of the
software without specific, written prior permission.  

DIGITAL DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING
ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL
DIGITAL BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR
ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,
WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION,
ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS







|
|

|


|







9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29

/***********************************************************
Copyright 1987 by Digital Equipment Corporation, Maynard, Massachusetts,
and the Massachusetts Institute of Technology, Cambridge, Massachusetts.

                        All Rights Reserved

Permission to use, copy, modify, and distribute this software and its
documentation for any purpose and without fee is hereby granted,
provided that the above copyright notice appear in all copies and that
both that copyright notice and this permission notice appear in
supporting documentation, and that the names of Digital or MIT not be
used in advertising or publicity pertaining to distribution of the
software without specific, written prior permission.

DIGITAL DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING
ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL
DIGITAL BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR
ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,
WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION,
ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS
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

#define AllTemporary         0L	/* special Resource ID passed to KillClient */

#define CurrentTime          0L	/* special Time */

#define NoSymbol	     0L	/* special KeySym */

/***************************************************************** 
 * EVENT DEFINITIONS 
 *****************************************************************/

/* Input Event Masks. Used as event-mask window attribute and as arguments
   to Grab requests.  Not to be confused with event names.  */

#define NoEventMask			0L
#define KeyPressMask			(1L<<0)  
#define KeyReleaseMask			(1L<<1)  
#define ButtonPressMask			(1L<<2)  
#define ButtonReleaseMask		(1L<<3)  
#define EnterWindowMask			(1L<<4)  
#define LeaveWindowMask			(1L<<5)  
#define PointerMotionMask		(1L<<6)  
#define PointerMotionHintMask		(1L<<7)  
#define Button1MotionMask		(1L<<8)  
#define Button2MotionMask		(1L<<9)  
#define Button3MotionMask		(1L<<10) 
#define Button4MotionMask		(1L<<11) 
#define Button5MotionMask		(1L<<12) 
#define ButtonMotionMask		(1L<<13) 
#define KeymapStateMask			(1L<<14)
#define ExposureMask			(1L<<15) 
#define VisibilityChangeMask		(1L<<16) 
#define StructureNotifyMask		(1L<<17) 
#define ResizeRedirectMask		(1L<<18) 
#define SubstructureNotifyMask		(1L<<19) 
#define SubstructureRedirectMask	(1L<<20) 
#define FocusChangeMask			(1L<<21) 
#define PropertyChangeMask		(1L<<22) 
#define ColormapChangeMask		(1L<<23) 
#define OwnerGrabButtonMask		(1L<<24) 

/* Event names.  Used in "type" field in XEvent structures.  Not to be
confused with event masks above.  They start from 2 because 0 and 1
are reserved in the protocol for errors and replies. */

#define KeyPress		2
#define KeyRelease		3







|
|






|
|
|
|
|
|
|
|
|
|
|
|
|
|

|
|
|
|
|
|
|
|
|
|







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

#define AllTemporary         0L	/* special Resource ID passed to KillClient */

#define CurrentTime          0L	/* special Time */

#define NoSymbol	     0L	/* special KeySym */

/*****************************************************************
 * EVENT DEFINITIONS
 *****************************************************************/

/* Input Event Masks. Used as event-mask window attribute and as arguments
   to Grab requests.  Not to be confused with event names.  */

#define NoEventMask			0L
#define KeyPressMask			(1L<<0)
#define KeyReleaseMask			(1L<<1)
#define ButtonPressMask			(1L<<2)
#define ButtonReleaseMask		(1L<<3)
#define EnterWindowMask			(1L<<4)
#define LeaveWindowMask			(1L<<5)
#define PointerMotionMask		(1L<<6)
#define PointerMotionHintMask		(1L<<7)
#define Button1MotionMask		(1L<<8)
#define Button2MotionMask		(1L<<9)
#define Button3MotionMask		(1L<<10)
#define Button4MotionMask		(1L<<11)
#define Button5MotionMask		(1L<<12)
#define ButtonMotionMask		(1L<<13)
#define KeymapStateMask			(1L<<14)
#define ExposureMask			(1L<<15)
#define VisibilityChangeMask		(1L<<16)
#define StructureNotifyMask		(1L<<17)
#define ResizeRedirectMask		(1L<<18)
#define SubstructureNotifyMask		(1L<<19)
#define SubstructureRedirectMask	(1L<<20)
#define FocusChangeMask			(1L<<21)
#define PropertyChangeMask		(1L<<22)
#define ColormapChangeMask		(1L<<23)
#define OwnerGrabButtonMask		(1L<<24)

/* Event names.  Used in "type" field in XEvent structures.  Not to be
confused with event masks above.  They start from 2 because 0 and 1
are reserved in the protocol for errors and replies. */

#define KeyPress		2
#define KeyRelease		3
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239

#define NotifyNormal		0
#define NotifyGrab		1
#define NotifyUngrab		2
#define NotifyWhileGrabbed	3

#define NotifyHint		1	/* for MotionNotify events */
		       
/* Notify detail */

#define NotifyAncestor		0
#define NotifyVirtual		1
#define NotifyInferior		2
#define NotifyNonlinear		3
#define NotifyNonlinearVirtual	4







|







225
226
227
228
229
230
231
232
233
234
235
236
237
238
239

#define NotifyNormal		0
#define NotifyGrab		1
#define NotifyUngrab		2
#define NotifyWhileGrabbed	3

#define NotifyHint		1	/* for MotionNotify events */

/* Notify detail */

#define NotifyAncestor		0
#define NotifyVirtual		1
#define NotifyInferior		2
#define NotifyNonlinear		3
#define NotifyNonlinearVirtual	4
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
/* Used in SetInputFocus, GetInputFocus */

#define RevertToNone		(int)None
#define RevertToPointerRoot	(int)PointerRoot
#define RevertToParent		2

/*****************************************************************
 * ERROR CODES 
 *****************************************************************/

#define Success		   0	/* everything's okay */
#define BadRequest	   1	/* bad request code */
#define BadValue	   2	/* int parameter out of range */
#define BadWindow	   3	/* parameter not a Window */
#define BadPixmap	   4	/* parameter not a Pixmap */
#define BadAtom		   5	/* parameter not an Atom */
#define BadCursor	   6	/* parameter not a Cursor */
#define BadFont		   7	/* parameter not a Font */
#define BadMatch	   8	/* parameter mismatch */
#define BadDrawable	   9	/* parameter not a Pixmap or Window */
#define BadAccess	  10	/* depending on context:
				 - key/button already grabbed
				 - attempt to free an illegal 
				   cmap entry 
				- attempt to store into a read-only 
				   color map entry.
 				- attempt to modify the access control
				   list from other than the local host.
				*/
#define BadAlloc	  11	/* insufficient resources */
#define BadColor	  12	/* no such colormap */
#define BadGC		  13	/* parameter not a GC */
#define BadIDChoice	  14	/* choice not in range or already used */
#define BadName		  15	/* font or color name doesn't exist */
#define BadLength	  16	/* Request length incorrect */
#define BadImplementation 17	/* server is defective */

#define FirstExtensionError	128
#define LastExtensionError	255

/*****************************************************************
 * WINDOW DEFINITIONS 
 *****************************************************************/

/* Window classes used by CreateWindow */
/* Note that CopyFromParent is already defined as 0 above */

#define InputOutput		1
#define InputOnly		2







|














|
|
|
















|







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
/* Used in SetInputFocus, GetInputFocus */

#define RevertToNone		(int)None
#define RevertToPointerRoot	(int)PointerRoot
#define RevertToParent		2

/*****************************************************************
 * ERROR CODES
 *****************************************************************/

#define Success		   0	/* everything's okay */
#define BadRequest	   1	/* bad request code */
#define BadValue	   2	/* int parameter out of range */
#define BadWindow	   3	/* parameter not a Window */
#define BadPixmap	   4	/* parameter not a Pixmap */
#define BadAtom		   5	/* parameter not an Atom */
#define BadCursor	   6	/* parameter not a Cursor */
#define BadFont		   7	/* parameter not a Font */
#define BadMatch	   8	/* parameter mismatch */
#define BadDrawable	   9	/* parameter not a Pixmap or Window */
#define BadAccess	  10	/* depending on context:
				 - key/button already grabbed
				 - attempt to free an illegal
				   cmap entry
				- attempt to store into a read-only
				   color map entry.
 				- attempt to modify the access control
				   list from other than the local host.
				*/
#define BadAlloc	  11	/* insufficient resources */
#define BadColor	  12	/* no such colormap */
#define BadGC		  13	/* parameter not a GC */
#define BadIDChoice	  14	/* choice not in range or already used */
#define BadName		  15	/* font or color name doesn't exist */
#define BadLength	  16	/* Request length incorrect */
#define BadImplementation 17	/* server is defective */

#define FirstExtensionError	128
#define LastExtensionError	255

/*****************************************************************
 * WINDOW DEFINITIONS
 *****************************************************************/

/* Window classes used by CreateWindow */
/* Note that CopyFromParent is already defined as 0 above */

#define InputOutput		1
#define InputOnly		2
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
#define GCForeground            (1L<<2)
#define GCBackground            (1L<<3)
#define GCLineWidth             (1L<<4)
#define GCLineStyle             (1L<<5)
#define GCCapStyle              (1L<<6)
#define GCJoinStyle		(1L<<7)
#define GCFillStyle		(1L<<8)
#define GCFillRule		(1L<<9) 
#define GCTile			(1L<<10)
#define GCStipple		(1L<<11)
#define GCTileStipXOrigin	(1L<<12)
#define GCTileStipYOrigin	(1L<<13)
#define GCFont 			(1L<<14)
#define GCSubwindowMode		(1L<<15)
#define GCGraphicsExposures     (1L<<16)
#define GCClipXOrigin		(1L<<17)
#define GCClipYOrigin		(1L<<18)
#define GCClipMask		(1L<<19)
#define GCDashOffset		(1L<<20)
#define GCDashList		(1L<<21)
#define GCArcMode		(1L<<22)

#define GCLastBit		22
/*****************************************************************
 * FONTS 
 *****************************************************************/

/* used in QueryFont -- draw direction */

#define FontLeftToRight		0
#define FontRightToLeft		1

#define FontChange		255

/*****************************************************************
 *  IMAGING 
 *****************************************************************/

/* ImageFormat -- PutImage, GetImage */

#define XYBitmap		0	/* depth 1, XYFormat */
#define XYPixmap		1	/* depth == drawable depth */
#define ZPixmap			2	/* depth == drawable depth */

/*****************************************************************
 *  COLOR MAP STUFF 
 *****************************************************************/

/* For CreateColormap */

#define AllocNone		0	/* create map with no entries */
#define AllocAll		1	/* allocate entire map writeable */








|
















|










|









|







521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
#define GCForeground            (1L<<2)
#define GCBackground            (1L<<3)
#define GCLineWidth             (1L<<4)
#define GCLineStyle             (1L<<5)
#define GCCapStyle              (1L<<6)
#define GCJoinStyle		(1L<<7)
#define GCFillStyle		(1L<<8)
#define GCFillRule		(1L<<9)
#define GCTile			(1L<<10)
#define GCStipple		(1L<<11)
#define GCTileStipXOrigin	(1L<<12)
#define GCTileStipYOrigin	(1L<<13)
#define GCFont 			(1L<<14)
#define GCSubwindowMode		(1L<<15)
#define GCGraphicsExposures     (1L<<16)
#define GCClipXOrigin		(1L<<17)
#define GCClipYOrigin		(1L<<18)
#define GCClipMask		(1L<<19)
#define GCDashOffset		(1L<<20)
#define GCDashList		(1L<<21)
#define GCArcMode		(1L<<22)

#define GCLastBit		22
/*****************************************************************
 * FONTS
 *****************************************************************/

/* used in QueryFont -- draw direction */

#define FontLeftToRight		0
#define FontRightToLeft		1

#define FontChange		255

/*****************************************************************
 *  IMAGING
 *****************************************************************/

/* ImageFormat -- PutImage, GetImage */

#define XYBitmap		0	/* depth 1, XYFormat */
#define XYPixmap		1	/* depth == drawable depth */
#define ZPixmap			2	/* depth == drawable depth */

/*****************************************************************
 *  COLOR MAP STUFF
 *****************************************************************/

/* For CreateColormap */

#define AllocNone		0	/* create map with no entries */
#define AllocAll		1	/* allocate entire map writeable */

584
585
586
587
588
589
590
591
592
593
594
595
596
597
598

/* QueryBestSize Class */

#define CursorShape		0	/* largest size that can be displayed */
#define TileShape		1	/* size tiled fastest */
#define StippleShape		2	/* size stippled fastest */

/***************************************************************** 
 * KEYBOARD/POINTER STUFF
 *****************************************************************/

#define AutoRepeatModeOff	0
#define AutoRepeatModeOn	1
#define AutoRepeatModeDefault	2








|







584
585
586
587
588
589
590
591
592
593
594
595
596
597
598

/* QueryBestSize Class */

#define CursorShape		0	/* largest size that can be displayed */
#define TileShape		1	/* size tiled fastest */
#define StippleShape		2	/* size stippled fastest */

/*****************************************************************
 * KEYBOARD/POINTER STUFF
 *****************************************************************/

#define AutoRepeatModeOff	0
#define AutoRepeatModeOn	1
#define AutoRepeatModeDefault	2

615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
#define MappingFailed		2

#define MappingModifier		0
#define MappingKeyboard		1
#define MappingPointer		2

/*****************************************************************
 * SCREEN SAVER STUFF 
 *****************************************************************/

#define DontPreferBlanking	0
#define PreferBlanking		1
#define DefaultBlanking		2

#define DisableScreenSaver	0







|







615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
#define MappingFailed		2

#define MappingModifier		0
#define MappingKeyboard		1
#define MappingPointer		2

/*****************************************************************
 * SCREEN SAVER STUFF
 *****************************************************************/

#define DontPreferBlanking	0
#define PreferBlanking		1
#define DefaultBlanking		2

#define DisableScreenSaver	0
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
/* for ChangeHosts */

#define HostInsert		0
#define HostDelete		1

/* for ChangeAccessControl */

#define EnableAccess		1      
#define DisableAccess		0

/* Display classes  used in opening the connection 
 * Note that the statically allocated ones are even numbered and the
 * dynamically changeable ones are odd numbered */

#define StaticGray		0
#define GrayScale		1
#define StaticColor		2
#define PseudoColor		3







|


|







645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
/* for ChangeHosts */

#define HostInsert		0
#define HostDelete		1

/* for ChangeAccessControl */

#define EnableAccess		1
#define DisableAccess		0

/* Display classes  used in opening the connection
 * Note that the statically allocated ones are even numbered and the
 * dynamically changeable ones are odd numbered */

#define StaticGray		0
#define GrayScale		1
#define StaticColor		2
#define PseudoColor		3

Changes to xlib/X11/Xfuncproto.h.

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
/* $XConsortium: Xfuncproto.h,v 1.7 91/05/13 20:49:21 rws Exp $ */
/* 
 * Copyright 1989, 1991 by the Massachusetts Institute of Technology
 *
 * Permission to use, copy, modify, and distribute this software and its
 * documentation for any purpose and without fee is hereby granted, provided 
 * that the above copyright notice appear in all copies and that both that 
 * copyright notice and this permission notice appear in supporting 
 * documentation, and that the name of M.I.T. not be used in advertising
 * or publicity pertaining to distribution of the software without specific, 
 * written prior permission. M.I.T. makes no representations about the 
 * suitability of this software for any purpose.  It is provided "as is"
 * without express or implied warranty.
 *
 */

/* Definitions to make function prototypes manageable */


|



|
|
|

|
|







1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
/* $XConsortium: Xfuncproto.h,v 1.7 91/05/13 20:49:21 rws Exp $ */
/*
 * Copyright 1989, 1991 by the Massachusetts Institute of Technology
 *
 * Permission to use, copy, modify, and distribute this software and its
 * documentation for any purpose and without fee is hereby granted, provided
 * that the above copyright notice appear in all copies and that both that
 * copyright notice and this permission notice appear in supporting
 * documentation, and that the name of M.I.T. not be used in advertising
 * or publicity pertaining to distribution of the software without specific,
 * written prior permission. M.I.T. makes no representations about the
 * suitability of this software for any purpose.  It is provided "as is"
 * without express or implied warranty.
 *
 */

/* Definitions to make function prototypes manageable */

Changes to xlib/X11/Xlib.h.

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
/* $XConsortium: Xlib.h,v 11.221 93/07/02 14:13:28 gildea Exp $ */
/* 
 * Copyright 1985, 1986, 1987, 1991 by the Massachusetts Institute of Technology
 *
 * Permission to use, copy, modify, and distribute this software and its
 * documentation for any purpose and without fee is hereby granted, provided 
 * that the above copyright notice appear in all copies and that both that 
 * copyright notice and this permission notice appear in supporting 
 * documentation, and that the name of M.I.T. not be used in advertising
 * or publicity pertaining to distribution of the software without specific, 
 * written prior permission. M.I.T. makes no representations about the 
 * suitability of this software for any purpose.  It is provided "as is"
 * without express or implied warranty.
 *
 * X Window System is a Trademark of MIT.
 *
 */


|



|
|
|

|
|







1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
/* $XConsortium: Xlib.h,v 11.221 93/07/02 14:13:28 gildea Exp $ */
/*
 * Copyright 1985, 1986, 1987, 1991 by the Massachusetts Institute of Technology
 *
 * Permission to use, copy, modify, and distribute this software and its
 * documentation for any purpose and without fee is hereby granted, provided
 * that the above copyright notice appear in all copies and that both that
 * copyright notice and this permission notice appear in supporting
 * documentation, and that the name of M.I.T. not be used in advertising
 * or publicity pertaining to distribution of the software without specific,
 * written prior permission. M.I.T. makes no representations about the
 * suitability of this software for any purpose.  It is provided "as is"
 * without express or implied warranty.
 *
 * X Window System is a Trademark of MIT.
 *
 */

159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
typedef struct {
	int function;		/* logical operation */
	unsigned long plane_mask;/* plane mask */
	unsigned long foreground;/* foreground pixel */
	unsigned long background;/* background pixel */
	int line_width;		/* line width */
	int line_style;	 	/* LineSolid, LineOnOffDash, LineDoubleDash */
	int cap_style;	  	/* CapNotLast, CapButt, 
				   CapRound, CapProjecting */
	int join_style;	 	/* JoinMiter, JoinRound, JoinBevel */
	int fill_style;	 	/* FillSolid, FillTiled, 
				   FillStippled, FillOpaeueStippled */
	int fill_rule;	  	/* EvenOddRule, WindingRule */
	int arc_mode;		/* ArcChord, ArcPieSlice */
	Pixmap tile;		/* tile pixmap for tiling operations */
	Pixmap stipple;		/* stipple 1 plane pixmap for stipping */
	int ts_x_origin;	/* offset for tile or stipple operations */
	int ts_y_origin;







|


|







159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
typedef struct {
	int function;		/* logical operation */
	unsigned long plane_mask;/* plane mask */
	unsigned long foreground;/* foreground pixel */
	unsigned long background;/* background pixel */
	int line_width;		/* line width */
	int line_style;	 	/* LineSolid, LineOnOffDash, LineDoubleDash */
	int cap_style;	  	/* CapNotLast, CapButt,
				   CapRound, CapProjecting */
	int join_style;	 	/* JoinMiter, JoinRound, JoinBevel */
	int fill_style;	 	/* FillSolid, FillTiled,
				   FillStippled, FillOpaeueStippled */
	int fill_rule;	  	/* EvenOddRule, WindingRule */
	int arc_mode;		/* ArcChord, ArcPieSlice */
	Pixmap tile;		/* tile pixmap for tiling operations */
	Pixmap stipple;		/* stipple 1 plane pixmap for stipping */
	int ts_x_origin;	/* offset for tile or stipple operations */
	int ts_y_origin;
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
	unsigned long red_mask, green_mask, blue_mask;	/* mask values */
	int bits_per_rgb;	/* log base 2 of distinct color values */
	int map_entries;	/* color map entries */
} Visual;

/*
 * Depth structure; contains information for each possible depth.
 */	
typedef struct {
	int depth;		/* this depth (Z) of the depth */
	int nvisuals;		/* number of Visual types at this depth */
	Visual *visuals;	/* list of visuals possible at this depth */
} Depth;

/*







|







205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
	unsigned long red_mask, green_mask, blue_mask;	/* mask values */
	int bits_per_rgb;	/* log base 2 of distinct color values */
	int map_entries;	/* color map entries */
} Visual;

/*
 * Depth structure; contains information for each possible depth.
 */
typedef struct {
	int depth;		/* this depth (Z) of the depth */
	int nvisuals;		/* number of Visual types at this depth */
	Visual *visuals;	/* list of visuals possible at this depth */
} Depth;

/*
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
	Visual *root_visual;	/* root visual */
	GC default_gc;		/* GC for the root root visual */
	Colormap cmap;		/* default color map */
	unsigned long white_pixel;
	unsigned long black_pixel;	/* White and Black pixel values */
	int max_maps, min_maps;	/* max and min color maps */
	int backing_store;	/* Never, WhenMapped, Always */
	Bool save_unders;	
	long root_input_mask;	/* initial root input mask */
} Screen;

/*
 * Format structure; describes ZFormat data the screen will understand.
 */
typedef struct {







|







233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
	Visual *root_visual;	/* root visual */
	GC default_gc;		/* GC for the root root visual */
	Colormap cmap;		/* default color map */
	unsigned long white_pixel;
	unsigned long black_pixel;	/* White and Black pixel values */
	int max_maps, min_maps;	/* max and min color maps */
	int backing_store;	/* Never, WhenMapped, Always */
	Bool save_unders;
	long root_input_mask;	/* initial root input mask */
} Screen;

/*
 * Format structure; describes ZFormat data the screen will understand.
 */
typedef struct {
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
	int (*put_pixel)();
	struct _XImage *(*sub_image)();
	int (*add_pixel)();
#endif
	} f;
} XImage;

/* 
 * Data structure for XReconfigureWindow
 */
typedef struct {
    int x, y;
    int width, height;
    int border_width;
    Window sibling;
    int stack_mode;
} XWindowChanges;

/*
 * Data structure used by color operations
 */
typedef struct {
	unsigned long pixel;
	unsigned short red, green, blue;
	char flags;  /* do_red, do_green, do_blue */
	char pad;
} XColor;

/* 
 * Data structures for graphics operations.  On most machines, these are
 * congruent with the wire protocol structures, so reformatting the data
 * can be avoided on these architectures.
 */
typedef struct {
    short x1, y1, x2, y2;
} XSegment;

typedef struct {
    short x, y;
} XPoint;
    
typedef struct {
    short x, y;
    unsigned short width, height;
} XRectangle;
    
typedef struct {
    short x, y;
    unsigned short width, height;
    short angle1, angle2;
} XArc;









|




















|











|




|







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
	int (*put_pixel)();
	struct _XImage *(*sub_image)();
	int (*add_pixel)();
#endif
	} f;
} XImage;

/*
 * Data structure for XReconfigureWindow
 */
typedef struct {
    int x, y;
    int width, height;
    int border_width;
    Window sibling;
    int stack_mode;
} XWindowChanges;

/*
 * Data structure used by color operations
 */
typedef struct {
	unsigned long pixel;
	unsigned short red, green, blue;
	char flags;  /* do_red, do_green, do_blue */
	char pad;
} XColor;

/*
 * Data structures for graphics operations.  On most machines, these are
 * congruent with the wire protocol structures, so reformatting the data
 * can be avoided on these architectures.
 */
typedef struct {
    short x1, y1, x2, y2;
} XSegment;

typedef struct {
    short x, y;
} XPoint;

typedef struct {
    short x, y;
    unsigned short width, height;
} XRectangle;

typedef struct {
    short x, y;
    unsigned short width, height;
    short angle1, angle2;
} XArc;


483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
	char *xdefaults;	/* contents of defaults from server */
	char *scratch_buffer;	/* place to hang scratch buffer */
	unsigned long scratch_length;	/* length of scratch buffer */
	int ext_number;		/* extension number on this display */
	struct _XExten *ext_procs; /* extensions initialized on this display */
	/*
	 * the following can be fixed size, as the protocol defines how
	 * much address space is available. 
	 * While this could be done using the extension vector, there
	 * may be MANY events processed, so a search through the extension
	 * list to find the right procedure for each event might be
	 * expensive if many extensions are being used.
	 */
	Bool (*event_vec[128])();  /* vector for wire to event */
	Status (*wire_vec[128])(); /* vector for event to wire */







|







483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
	char *xdefaults;	/* contents of defaults from server */
	char *scratch_buffer;	/* place to hang scratch buffer */
	unsigned long scratch_length;	/* length of scratch buffer */
	int ext_number;		/* extension number on this display */
	struct _XExten *ext_procs; /* extensions initialized on this display */
	/*
	 * the following can be fixed size, as the protocol defines how
	 * much address space is available.
	 * While this could be done using the extension vector, there
	 * may be MANY events processed, so a search through the extension
	 * list to find the right procedure for each event might be
	 * expensive if many extensions are being used.
	 */
	Bool (*event_vec[128])();  /* vector for wire to event */
	Status (*wire_vec[128])(); /* vector for event to wire */
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
	Window subwindow;	/* child window */
	Time time;		/* milliseconds */
	int x, y;		/* pointer x, y coordinates in event window */
	int x_root, y_root;	/* coordinates relative to root */
	int mode;		/* NotifyNormal, NotifyGrab, NotifyUngrab */
	int detail;
	/*
	 * NotifyAncestor, NotifyVirtual, NotifyInferior, 
	 * NotifyNonlinear,NotifyNonlinearVirtual
	 */
	Bool same_screen;	/* same screen flag */
	Bool focus;		/* boolean focus */
	unsigned int state;	/* key or button mask */
} XCrossingEvent;
typedef XCrossingEvent XEnterWindowEvent;
typedef XCrossingEvent XLeaveWindowEvent;

typedef struct {
	int type;		/* FocusIn or FocusOut */
	unsigned long serial;	/* # of last request processed by server */
	Bool send_event;	/* true if this came from a SendEvent request */
	Display *display;	/* Display the event was read from */
	Window window;		/* window of event */
	int mode;		/* NotifyNormal, NotifyGrab, NotifyUngrab */
	int detail;
	/*
	 * NotifyAncestor, NotifyVirtual, NotifyInferior, 
	 * NotifyNonlinear,NotifyNonlinearVirtual, NotifyPointer,
	 * NotifyPointerRoot, NotifyDetailNone 
	 */
} XFocusChangeEvent;
typedef XFocusChangeEvent XFocusInEvent;
typedef XFocusChangeEvent XFocusOutEvent;

/* generated on EnterWindow and FocusIn  when KeyMapState selected */
typedef struct {
	int type;
	unsigned long serial;	/* # of last request processed by server */
	Bool send_event;	/* true if this came from a SendEvent request */
	Display *display;	/* Display the event was read from */
	Window window;
	char key_vector[32];
} XKeymapEvent;	

typedef struct {
	int type;
	unsigned long serial;	/* # of last request processed by server */
	Bool send_event;	/* true if this came from a SendEvent request */
	Display *display;	/* Display the event was read from */
	Window window;







|


















|

|













|







598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
	Window subwindow;	/* child window */
	Time time;		/* milliseconds */
	int x, y;		/* pointer x, y coordinates in event window */
	int x_root, y_root;	/* coordinates relative to root */
	int mode;		/* NotifyNormal, NotifyGrab, NotifyUngrab */
	int detail;
	/*
	 * NotifyAncestor, NotifyVirtual, NotifyInferior,
	 * NotifyNonlinear,NotifyNonlinearVirtual
	 */
	Bool same_screen;	/* same screen flag */
	Bool focus;		/* boolean focus */
	unsigned int state;	/* key or button mask */
} XCrossingEvent;
typedef XCrossingEvent XEnterWindowEvent;
typedef XCrossingEvent XLeaveWindowEvent;

typedef struct {
	int type;		/* FocusIn or FocusOut */
	unsigned long serial;	/* # of last request processed by server */
	Bool send_event;	/* true if this came from a SendEvent request */
	Display *display;	/* Display the event was read from */
	Window window;		/* window of event */
	int mode;		/* NotifyNormal, NotifyGrab, NotifyUngrab */
	int detail;
	/*
	 * NotifyAncestor, NotifyVirtual, NotifyInferior,
	 * NotifyNonlinear,NotifyNonlinearVirtual, NotifyPointer,
	 * NotifyPointerRoot, NotifyDetailNone
	 */
} XFocusChangeEvent;
typedef XFocusChangeEvent XFocusInEvent;
typedef XFocusChangeEvent XFocusOutEvent;

/* generated on EnterWindow and FocusIn  when KeyMapState selected */
typedef struct {
	int type;
	unsigned long serial;	/* # of last request processed by server */
	Bool send_event;	/* true if this came from a SendEvent request */
	Display *display;	/* Display the event was read from */
	Window window;
	char key_vector[32];
} XKeymapEvent;

typedef struct {
	int type;
	unsigned long serial;	/* # of last request processed by server */
	Bool send_event;	/* true if this came from a SendEvent request */
	Display *display;	/* Display the event was read from */
	Window window;
1120
1121
1122
1123
1124
1125
1126
1127
1128
1129
1130
1131
1132
1133
1134
1135
1136
1137
1138
1139
1140
1141
1142
1143
1144
1145
1146
1147
1148
1149
1150
1151
1152
1153
1154
1155
1156
1157
1158
1159
1160
1161
1162
1163
1164
1165
1166
1167
1168
1169
1170
1171
1172
1173
1174
1175
1176
1177
1178
1179
1180
1181
1182
1183
    XPointer client_data;
    XIMProc callback;
} XIMCallback;

typedef unsigned long XIMFeedback;

#define XIMReverse	1
#define XIMUnderline	(1<<1) 
#define XIMHighlight	(1<<2)
#define XIMPrimary 	(1<<5)
#define XIMSecondary	(1<<6)
#define XIMTertiary 	(1<<7)

typedef struct _XIMText {
    unsigned short length;
    XIMFeedback *feedback;
    Bool encoding_is_wchar; 
    union {
	char *multi_byte;
	wchar_t *wide_char;
    } string; 
} XIMText;

typedef struct _XIMPreeditDrawCallbackStruct {
    int caret;		/* Cursor offset within pre-edit string */
    int chg_first;	/* Starting change position */
    int chg_length;	/* Length of the change in character count */
    XIMText *text;
} XIMPreeditDrawCallbackStruct;

typedef enum {
    XIMForwardChar, XIMBackwardChar,
    XIMForwardWord, XIMBackwardWord,
    XIMCaretUp, XIMCaretDown,
    XIMNextLine, XIMPreviousLine,
    XIMLineStart, XIMLineEnd, 
    XIMAbsolutePosition,
    XIMDontChange
} XIMCaretDirection;

typedef enum {
    XIMIsInvisible,	/* Disable caret feedback */ 
    XIMIsPrimary,	/* UI defined caret feedback */
    XIMIsSecondary	/* UI defined caret feedback */
} XIMCaretStyle;

typedef struct _XIMPreeditCaretCallbackStruct {
    int position;		 /* Caret offset within pre-edit string */
    XIMCaretDirection direction; /* Caret moves direction */
    XIMCaretStyle style;	 /* Feedback of the caret */
} XIMPreeditCaretCallbackStruct;

typedef enum {
    XIMTextType,
    XIMBitmapType
} XIMStatusDataType;
	
typedef struct _XIMStatusDrawCallbackStruct {
    XIMStatusDataType type;
    union {
	XIMText *text;
	Pixmap  bitmap;
    } data;
} XIMStatusDrawCallbackStruct;







|








|



|














|





|














|







1120
1121
1122
1123
1124
1125
1126
1127
1128
1129
1130
1131
1132
1133
1134
1135
1136
1137
1138
1139
1140
1141
1142
1143
1144
1145
1146
1147
1148
1149
1150
1151
1152
1153
1154
1155
1156
1157
1158
1159
1160
1161
1162
1163
1164
1165
1166
1167
1168
1169
1170
1171
1172
1173
1174
1175
1176
1177
1178
1179
1180
1181
1182
1183
    XPointer client_data;
    XIMProc callback;
} XIMCallback;

typedef unsigned long XIMFeedback;

#define XIMReverse	1
#define XIMUnderline	(1<<1)
#define XIMHighlight	(1<<2)
#define XIMPrimary 	(1<<5)
#define XIMSecondary	(1<<6)
#define XIMTertiary 	(1<<7)

typedef struct _XIMText {
    unsigned short length;
    XIMFeedback *feedback;
    Bool encoding_is_wchar;
    union {
	char *multi_byte;
	wchar_t *wide_char;
    } string;
} XIMText;

typedef struct _XIMPreeditDrawCallbackStruct {
    int caret;		/* Cursor offset within pre-edit string */
    int chg_first;	/* Starting change position */
    int chg_length;	/* Length of the change in character count */
    XIMText *text;
} XIMPreeditDrawCallbackStruct;

typedef enum {
    XIMForwardChar, XIMBackwardChar,
    XIMForwardWord, XIMBackwardWord,
    XIMCaretUp, XIMCaretDown,
    XIMNextLine, XIMPreviousLine,
    XIMLineStart, XIMLineEnd,
    XIMAbsolutePosition,
    XIMDontChange
} XIMCaretDirection;

typedef enum {
    XIMIsInvisible,	/* Disable caret feedback */
    XIMIsPrimary,	/* UI defined caret feedback */
    XIMIsSecondary	/* UI defined caret feedback */
} XIMCaretStyle;

typedef struct _XIMPreeditCaretCallbackStruct {
    int position;		 /* Caret offset within pre-edit string */
    XIMCaretDirection direction; /* Caret moves direction */
    XIMCaretStyle style;	 /* Feedback of the caret */
} XIMPreeditCaretCallbackStruct;

typedef enum {
    XIMTextType,
    XIMBitmapType
} XIMStatusDataType;

typedef struct _XIMStatusDrawCallbackStruct {
    XIMStatusDataType type;
    union {
	XIMText *text;
	Pixmap  bitmap;
    } data;
} XIMStatusDrawCallbackStruct;

Changes to xlib/X11/Xutil.h.

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
/* $XConsortium: Xutil.h,v 11.73 91/07/30 16:21:37 rws Exp $ */

/***********************************************************
Copyright 1987 by Digital Equipment Corporation, Maynard, Massachusetts,
and the Massachusetts Institute of Technology, Cambridge, Massachusetts.

                        All Rights Reserved

Permission to use, copy, modify, and distribute this software and its 
documentation for any purpose and without fee is hereby granted, 
provided that the above copyright notice appear in all copies and that
both that copyright notice and this permission notice appear in 
supporting documentation, and that the names of Digital or MIT not be
used in advertising or publicity pertaining to distribution of the
software without specific, written prior permission.  

DIGITAL DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING
ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL
DIGITAL BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR
ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,
WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION,
ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS
SOFTWARE.

******************************************************************/

#ifndef _XUTIL_H_
#define _XUTIL_H_

/* You must include <X11/Xlib.h> before including this file */

#if defined(MAC_OSX_TK)
#   define Region XRegion
#endif

/* 
 * Bitmask returned by XParseGeometry().  Each bit tells if the corresponding
 * value (x, y, width, height) was found in the parsed string.
 */
#define NoValue		0x0000
#define XValue  	0x0001
#define YValue		0x0002
#define WidthValue  	0x0004








|
|

|


|




















|







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
/* $XConsortium: Xutil.h,v 11.73 91/07/30 16:21:37 rws Exp $ */

/***********************************************************
Copyright 1987 by Digital Equipment Corporation, Maynard, Massachusetts,
and the Massachusetts Institute of Technology, Cambridge, Massachusetts.

                        All Rights Reserved

Permission to use, copy, modify, and distribute this software and its
documentation for any purpose and without fee is hereby granted,
provided that the above copyright notice appear in all copies and that
both that copyright notice and this permission notice appear in
supporting documentation, and that the names of Digital or MIT not be
used in advertising or publicity pertaining to distribution of the
software without specific, written prior permission.

DIGITAL DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING
ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL
DIGITAL BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR
ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,
WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION,
ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS
SOFTWARE.

******************************************************************/

#ifndef _XUTIL_H_
#define _XUTIL_H_

/* You must include <X11/Xlib.h> before including this file */

#if defined(MAC_OSX_TK)
#   define Region XRegion
#endif

/*
 * Bitmask returned by XParseGeometry().  Each bit tells if the corresponding
 * value (x, y, width, height) was found in the parsed string.
 */
#define NoValue		0x0000
#define XValue  	0x0001
#define YValue		0x0002
#define WidthValue  	0x0004
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
#define DontCareState 0	/* don't know or care */
#define ZoomState 2	/* application wants to start zoomed */
#define InactiveState 4	/* application believes it is seldom used; */
			/* some wm's may put it on inactive menu */


/*
 * new structure for manipulating TEXT properties; used with WM_NAME, 
 * WM_ICON_NAME, WM_CLIENT_MACHINE, and WM_COMMAND.
 */
typedef struct {
    unsigned char *value;		/* same as Property routines */
    Atom encoding;			/* prop type */
    int format;				/* prop data format: 8, 16, or 32 */
    unsigned long nitems;		/* number of data items in value */







|







124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
#define DontCareState 0	/* don't know or care */
#define ZoomState 2	/* application wants to start zoomed */
#define InactiveState 4	/* application believes it is seldom used; */
			/* some wm's may put it on inactive menu */


/*
 * new structure for manipulating TEXT properties; used with WM_NAME,
 * WM_ICON_NAME, WM_CLIENT_MACHINE, and WM_COMMAND.
 */
typedef struct {
    unsigned char *value;		/* same as Property routines */
    Atom encoding;			/* prop type */
    int format;				/* prop data format: 8, 16, or 32 */
    unsigned long nitems;		/* number of data items in value */
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
  (((unsigned)(keysym) >= XK_Select)   && ((unsigned)(keysym) <= XK_Break))

#define IsModifierKey(keysym) \
  ((((unsigned)(keysym) >= XK_Shift_L) && ((unsigned)(keysym) <= XK_Hyper_R)) \
   || ((unsigned)(keysym) == XK_Mode_switch) \
   || ((unsigned)(keysym) == XK_Num_Lock))
/*
 * opaque reference to Region data type 
 */
typedef struct _XRegion *Region; 

/* Return values from XRectInRegion() */
 
#define RectangleOut 0
#define RectangleIn  1
#define RectanglePart 2
 

/*
 * Information used by the visual utility routines to find desired visual
 * type from the many visuals a display may support.
 */

typedef struct {







|

|


|



|







202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
  (((unsigned)(keysym) >= XK_Select)   && ((unsigned)(keysym) <= XK_Break))

#define IsModifierKey(keysym) \
  ((((unsigned)(keysym) >= XK_Shift_L) && ((unsigned)(keysym) <= XK_Hyper_R)) \
   || ((unsigned)(keysym) == XK_Mode_switch) \
   || ((unsigned)(keysym) == XK_Num_Lock))
/*
 * opaque reference to Region data type
 */
typedef struct _XRegion *Region;

/* Return values from XRectInRegion() */

#define RectangleOut 0
#define RectangleIn  1
#define RectanglePart 2


/*
 * Information used by the visual utility routines to find desired visual
 * type from the many visuals a display may support.
 */

typedef struct {
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
);

extern Status XGetStandardColormap(
#if NeedFunctionPrototypes
    Display*		/* display */,
    Window		/* w */,
    XStandardColormap*	/* colormap_return */,
    Atom		/* property */			    
#endif
);

extern Status XGetTextProperty(
#if NeedFunctionPrototypes
    Display*		/* display */,
    Window		/* window */,







|







431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
);

extern Status XGetStandardColormap(
#if NeedFunctionPrototypes
    Display*		/* display */,
    Window		/* w */,
    XStandardColormap*	/* colormap_return */,
    Atom		/* property */
#endif
);

extern Status XGetTextProperty(
#if NeedFunctionPrototypes
    Display*		/* display */,
    Window		/* window */,
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
    XTextProperty*	/* text_prop_return */
#endif
);

extern XWMHints *XGetWMHints(
#if NeedFunctionPrototypes
    Display*		/* display */,
    Window		/* w */		      
#endif
);

extern Status XGetWMIconName(
#if NeedFunctionPrototypes
    Display*		/* display */,
    Window		/* w */,







|







456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
    XTextProperty*	/* text_prop_return */
#endif
);

extern XWMHints *XGetWMHints(
#if NeedFunctionPrototypes
    Display*		/* display */,
    Window		/* w */
#endif
);

extern Status XGetWMIconName(
#if NeedFunctionPrototypes
    Display*		/* display */,
    Window		/* w */,
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
);

extern Status XGetWMNormalHints(
#if NeedFunctionPrototypes
    Display*		/* display */,
    Window		/* w */,
    XSizeHints*		/* hints_return */,
    long*		/* supplied_return */ 
#endif
);

extern Status XGetWMSizeHints(
#if NeedFunctionPrototypes
    Display*		/* display */,
    Window		/* w */,







|







481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
);

extern Status XGetWMNormalHints(
#if NeedFunctionPrototypes
    Display*		/* display */,
    Window		/* w */,
    XSizeHints*		/* hints_return */,
    long*		/* supplied_return */
#endif
);

extern Status XGetWMSizeHints(
#if NeedFunctionPrototypes
    Display*		/* display */,
    Window		/* w */,
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
);

extern void XSetIconSizes(
#if NeedFunctionPrototypes
    Display*		/* display */,
    Window		/* w */,
    XIconSize*		/* size_list */,
    int			/* count */    
#endif
);

extern void XSetNormalHints(
#if NeedFunctionPrototypes
    Display*		/* display */,
    Window		/* w */,







|







587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
);

extern void XSetIconSizes(
#if NeedFunctionPrototypes
    Display*		/* display */,
    Window		/* w */,
    XIconSize*		/* size_list */,
    int			/* count */
#endif
);

extern void XSetNormalHints(
#if NeedFunctionPrototypes
    Display*		/* display */,
    Window		/* w */,

Changes to xlib/X11/keysym.h.

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
/* $XConsortium: keysym.h,v 1.13 91/03/13 20:09:49 rws Exp $ */

/***********************************************************
Copyright 1987 by Digital Equipment Corporation, Maynard, Massachusetts,
and the Massachusetts Institute of Technology, Cambridge, Massachusetts.

                        All Rights Reserved

Permission to use, copy, modify, and distribute this software and its 
documentation for any purpose and without fee is hereby granted, 
provided that the above copyright notice appear in all copies and that
both that copyright notice and this permission notice appear in 
supporting documentation, and that the names of Digital or MIT not be
used in advertising or publicity pertaining to distribution of the
software without specific, written prior permission.  

DIGITAL DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING
ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL
DIGITAL BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR
ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,
WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION,
ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS








|
|

|


|







1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
/* $XConsortium: keysym.h,v 1.13 91/03/13 20:09:49 rws Exp $ */

/***********************************************************
Copyright 1987 by Digital Equipment Corporation, Maynard, Massachusetts,
and the Massachusetts Institute of Technology, Cambridge, Massachusetts.

                        All Rights Reserved

Permission to use, copy, modify, and distribute this software and its
documentation for any purpose and without fee is hereby granted,
provided that the above copyright notice appear in all copies and that
both that copyright notice and this permission notice appear in
supporting documentation, and that the names of Digital or MIT not be
used in advertising or publicity pertaining to distribution of the
software without specific, written prior permission.

DIGITAL DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING
ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL
DIGITAL BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR
ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,
WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION,
ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS

Changes to xlib/xgc.c.

129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
    }

#define InitField(name,maskbit,default) \
	(gp->name = (mask & (maskbit)) ? values->name : (default))

    InitField(function,		  GCFunction,		GXcopy);
    InitField(plane_mask,	  GCPlaneMask,		(unsigned long)(~0));
    InitField(foreground,	  GCForeground,		
	    BlackPixelOfScreen(DefaultScreenOfDisplay(display)));
    InitField(background,	  GCBackground,		
	    WhitePixelOfScreen(DefaultScreenOfDisplay(display)));
    InitField(line_width,	  GCLineWidth,		1);
    InitField(line_style,	  GCLineStyle,		LineSolid);
    InitField(cap_style,	  GCCapStyle,		0);
    InitField(join_style,	  GCJoinStyle,		0);
    InitField(fill_style,	  GCFillStyle,		FillSolid);
    InitField(fill_rule,	  GCFillRule,		WindingRule);







|

|







129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
    }

#define InitField(name,maskbit,default) \
	(gp->name = (mask & (maskbit)) ? values->name : (default))

    InitField(function,		  GCFunction,		GXcopy);
    InitField(plane_mask,	  GCPlaneMask,		(unsigned long)(~0));
    InitField(foreground,	  GCForeground,
	    BlackPixelOfScreen(DefaultScreenOfDisplay(display)));
    InitField(background,	  GCBackground,
	    WhitePixelOfScreen(DefaultScreenOfDisplay(display)));
    InitField(line_width,	  GCLineWidth,		1);
    InitField(line_style,	  GCLineStyle,		LineSolid);
    InitField(cap_style,	  GCCapStyle,		0);
    InitField(join_style,	  GCJoinStyle,		0);
    InitField(fill_style,	  GCFillStyle,		FillSolid);
    InitField(fill_rule,	  GCFillRule,		WindingRule);