diff options
-rw-r--r-- | ChangeLog | 40 | ||||
-rw-r--r-- | doc/canvas.n | 2 | ||||
-rw-r--r-- | doc/event.n | 48 | ||||
-rw-r--r-- | doc/ttk_notebook.n | 2 | ||||
-rw-r--r-- | generic/tkEvent.c | 6 | ||||
-rw-r--r-- | generic/tkTextTag.c | 5 | ||||
-rw-r--r-- | library/console.tcl | 6 | ||||
-rw-r--r-- | library/demos/entry3.tcl | 4 | ||||
-rw-r--r-- | library/demos/items.tcl | 2 | ||||
-rw-r--r-- | library/entry.tcl | 28 | ||||
-rw-r--r-- | library/iconlist.tcl | 8 | ||||
-rw-r--r-- | library/listbox.tcl | 28 | ||||
-rw-r--r-- | library/menu.tcl | 8 | ||||
-rw-r--r-- | library/scale.tcl | 20 | ||||
-rw-r--r-- | library/scrlbar.tcl | 20 | ||||
-rw-r--r-- | library/spinbox.tcl | 28 | ||||
-rw-r--r-- | library/text.tcl | 76 | ||||
-rw-r--r-- | library/tk.tcl | 127 | ||||
-rw-r--r-- | library/ttk/entry.tcl | 10 | ||||
-rw-r--r-- | library/ttk/notebook.tcl | 4 | ||||
-rw-r--r-- | library/ttk/scale.tcl | 23 | ||||
-rw-r--r-- | unix/tkUnixEvent.c | 2 | ||||
-rw-r--r-- | unix/tkUnixKey.c | 4 | ||||
-rw-r--r-- | unix/tkUnixRFont.c | 2 | ||||
-rwxr-xr-x | win/buildall.vc.bat | 69 | ||||
-rw-r--r-- | win/makefile.vc | 173 | ||||
-rw-r--r-- | win/nmakehlp.c | 10 | ||||
-rw-r--r-- | win/rules.vc | 52 |
28 files changed, 452 insertions, 355 deletions
@@ -1,3 +1,43 @@ +2012-08-22 Jan Nijtmans <nijtmans@users.sf.net> + + * xlib/xcolors.c: [TIP 405]: Web Colors for Tk. New colors aqua, + * xlib/rgb.txt: crimson, fuchsia, indigo, lime, olive, silver + * unix/tkUnixColor.c: and teal. Modified RGB values for gray/grey, + * generic/tkInt.h: green, maroon and purple. + * generic/tkColor.c + +2012-08-17 Jan Nijtmans <nijtmans@users.sf.net> + + * win/nmakehlp.c: Add "-V<num>" option, in order to be able + to detect partial version numbers. + +2012-08-15 Jan Nijtmans <nijtmans@users.sf.net> + + * win/buildall.vc.bat: Only build the threaded builds by default + * win/rules.vc: For msvcrt static builds, allow to link + against libraries where the 'x' is missing (generated by Makefile.in). + * win/makefile.vc: Always compile Tk with -DUSE_TCL_STUBS, formatting. + * library/tk.tcl: [Frq 3555324]: On Windows, re-define Ctrl-A for + Select-All., as most Windows applications do. + +2012-08-11 Jan Nijtmans <nijtmans@users.sf.net> + + * library/*.tcl: [Bug 3555644]: Better use of virtual events. + Pre-define 10 new Virtual events, and correct various + bindings according to the Mac OSX documentation. + * win/rules.vc: Sync with tcl version of rules.vc + +2012-08-11 Francois Vogel <fvogelnew1@free.fr> + + * generic/tkTextTag.c: [Bug 3554273]: Test textDisp-32.2 failed + +2012-08-09 Stuart Cassoff <stwo@users.sourceforge.net> + + * generic/tkEvent.c: Remove useless (void *) casts + * unix/tkUnixEvent.c: introduced in checkin [81e50c85ed]. + * unix/tkUnixKey.c: The warnings were false flags from a + * unix/tkUnixRFont.c: faulty OpenBSD C compiler. + 2012-07-31 Donal K. Fellows <dkf@users.sf.net> * unix/tkUnixKey.c (TkpSetKeycodeAndState, TkpInitKeymapInfo) diff --git a/doc/canvas.n b/doc/canvas.n index e215222..9eb0ec0 100644 --- a/doc/canvas.n +++ b/doc/canvas.n @@ -918,7 +918,7 @@ coordinates. Defaults to the coordinate of the top edge of the window. .RE .TP -\fIpathName \fB \fItagOrId \fR?\fIaboveThis\fR? +\fIpathName \fBraise \fItagOrId \fR?\fIaboveThis\fR? . Move all of the items given by \fItagOrId\fR to a new position in the display list just after the item given by \fIaboveThis\fR. diff --git a/doc/event.n b/doc/event.n index 214e6b7..f45a13f 100644 --- a/doc/event.n +++ b/doc/event.n @@ -373,6 +373,16 @@ selected contents. Move to the next item (i.e., visible character) in the current widget while deselecting any selected contents. .TP +\fB<<NextLine>>\fR +. +Move to the next line in the current widget while deselecting any selected +contents. +.TP +\fB<<NextPara>>\fR +. +Move to the next paragraph in the current widget while deselecting any +selected contents. +.TP \fB<<NextWord>>\fR . Move to the next group of items (i.e., visible word) in the current widget @@ -391,6 +401,16 @@ event has meaningful \fB%x\fR and \fB%y\fR substitutions). Move to the previous item (i.e., visible character) in the current widget while deselecting any selected contents. .TP +\fB<<PrevLine>>\fR +. +Move to the previous line in the current widget while deselecting any selected +contents. +.TP +\fB<<PrevPara>>\fR +. +Move to the previous paragraph in the current widget while deselecting any +selected contents. +.TP \fB<<PrevWindow>>\fR Traverse to the previous window. .TP @@ -402,6 +422,10 @@ while deselecting any selected contents. \fB<<Redo>>\fR Redo one undone action. .TP +\fB<<SelectAll>>\fR +. +Set the range of selected contents to the complete widget. +.TP \fB<<SelectLineEnd>>\fR . Move to the end of the line in the current widget while extending the range @@ -417,16 +441,40 @@ of selected contents. Move to the next item (i.e., visible character) in the current widget while extending the range of selected contents. .TP +\fB<<SelectNextLine>>\fR +. +Move to the next line in the current widget while extending the range of +selected contents. +.TP +\fB<<SelectNextPara>>\fR +. +Move to the next paragraph in the current widget while extending the range +of selected contents. +.TP \fB<<SelectNextWord>>\fR . Move to the next group of items (i.e., visible word) in the current widget while extending the range of selected contents. .TP +\fB<<SelectNone>>\fR +. +Reset the range of selected contents to be empty. +.TP \fB<<SelectPrevChar>>\fR . Move to the previous item (i.e., visible character) in the current widget while extending the range of selected contents. .TP +\fB<<SelectPrevLine>>\fR +. +Move to the previous line in the current widget while extending the range of +selected contents. +.TP +\fB<<SelectPrevPara>>\fR +. +Move to the previous paragraph in the current widget while extending the +range of selected contents. +.TP \fB<<SelectPrevWord>>\fR . Move to the previous group of items (i.e., visible word) in the current widget diff --git a/doc/ttk_notebook.n b/doc/ttk_notebook.n index 6b4b2bc..fe89994 100644 --- a/doc/ttk_notebook.n +++ b/doc/ttk_notebook.n @@ -184,7 +184,7 @@ containing the notebook as follows: .IP \(bu \fBControl-Tab\fR selects the tab following the currently selected one. .IP \(bu -\fBShift-Control-Tab\fR selects the tab preceding the currently selected one. +\fBControl-Shift-Tab\fR selects the tab preceding the currently selected one. .IP \(bu \fBAlt-\fIK\fR, where \fIK\fR is the mnemonic (underlined) character of any tab, will select that tab. diff --git a/generic/tkEvent.c b/generic/tkEvent.c index dfa46ff..1fbf1dd 100644 --- a/generic/tkEvent.c +++ b/generic/tkEvent.c @@ -337,7 +337,7 @@ CreateXIC( preedit_attlist = XVaCreateNestedList(0, XNSpotLocation, &spot, XNFontSet, dispPtr->inputXfs, - (void *) NULL); + NULL); } winPtr->inputContext = XCreateIC(dispPtr->inputMethod, @@ -345,7 +345,7 @@ CreateXIC( XNClientWindow, winPtr->window, XNFocusWindow, winPtr->window, preedit_attname, preedit_attlist, - (void *) NULL); + NULL); if (preedit_attlist) { XFree(preedit_attlist); @@ -360,7 +360,7 @@ CreateXIC( /* * Adjust the window's event mask if the IM requires it. */ - XGetICValues(winPtr->inputContext, XNFilterEvents, &im_event_mask, (void *) NULL); + XGetICValues(winPtr->inputContext, XNFilterEvents, &im_event_mask, NULL); if ((winPtr->atts.event_mask & im_event_mask) != im_event_mask) { winPtr->atts.event_mask |= im_event_mask; XSelectInput(winPtr->display, winPtr->window, winPtr->atts.event_mask); diff --git a/generic/tkTextTag.c b/generic/tkTextTag.c index 9afda0a..6cd018a 100644 --- a/generic/tkTextTag.c +++ b/generic/tkTextTag.c @@ -457,6 +457,11 @@ TkTextTagCmd( &tagPtr->elide) != TCL_OK) { return TCL_ERROR; } + /* Indices are potentially obsolete after changing -elide, + * especially those computed with "display" or "any" + * submodifier, therefore increase the epoch. + */ + textPtr->sharedTextPtr->stateEpoch++; } /* diff --git a/library/console.tcl b/library/console.tcl index e6b7ce9..37832f2 100644 --- a/library/console.tcl +++ b/library/console.tcl @@ -499,18 +499,16 @@ proc ::tk::ConsoleBind {w} { } bind Console <Control-h> [bind Console <BackSpace>] - bind Console <Home> { + bind Console <<LineStart>> { if {[%W compare insert < promptEnd]} { tk::TextSetCursor %W {insert linestart} } else { tk::TextSetCursor %W promptEnd } } - bind Console <Control-a> [bind Console <Home>] - bind Console <End> { + bind Console <<LineEnd>> { tk::TextSetCursor %W {insert lineend} } - bind Console <Control-e> [bind Console <End>] bind Console <Control-d> { if {[%W compare insert < promptEnd]} { break diff --git a/library/demos/entry3.tcl b/library/demos/entry3.tcl index 3d76c2e..d4435c6 100644 --- a/library/demos/entry3.tcl +++ b/library/demos/entry3.tcl @@ -169,8 +169,8 @@ bind $w.l3.e <FocusIn> { after idle {%W selection clear} } } -bind $w.l3.e <Left> {phoneSkipLeft %W} -bind $w.l3.e <Right> {phoneSkipRight %W} +bind $w.l3.e <<PrevChar>> {phoneSkipLeft %W} +bind $w.l3.e <<NextChar>> {phoneSkipRight %W} pack $w.l3.e -fill x -expand 1 -padx 1m -pady 1m labelframe $w.l4 -text "Password Entry" diff --git a/library/demos/items.tcl b/library/demos/items.tcl index 31a1570..177e9a4 100644 --- a/library/demos/items.tcl +++ b/library/demos/items.tcl @@ -173,7 +173,7 @@ bind $c <2> "$c scan mark %x %y" bind $c <B2-Motion> "$c scan dragto %x %y" bind $c <3> "itemMark $c %x %y" bind $c <B3-Motion> "itemStroke $c %x %y" -bind $c <Control-f> "itemsUnderArea $c" +bind $c <<NextChar>> "itemsUnderArea $c" bind $c <1> "itemStartDrag $c %x %y" bind $c <B1-Motion> "itemDrag $c %x %y" diff --git a/library/entry.tcl b/library/entry.tcl index de6c463..f28547e 100644 --- a/library/entry.tcl +++ b/library/entry.tcl @@ -185,10 +185,10 @@ bind Entry <Control-Shift-space> { bind Entry <Shift-Select> { %W selection adjust insert } -bind Entry <Control-slash> { +bind Entry <<SelectAll>> { %W selection range 0 end } -bind Entry <Control-backslash> { +bind Entry <<SelectNone>> { %W selection clear } bind Entry <KeyPress> { @@ -214,8 +214,8 @@ if {[tk windowingsystem] eq "aqua"} { bind Entry <Command-KeyPress> {# nothing} } # Tk-on-Cocoa generates characters for these two keys. [Bug 2971663] -bind Entry <Down> {# nothing} -bind Entry <Up> {# nothing} +bind Entry <<NextLine>> {# nothing} +bind Entry <<PrevLine>> {# nothing} # On Windows, paste is done using Shift-Insert. Shift-Insert already # generates the <<Paste>> event, so we don't need to do anything here. @@ -227,31 +227,11 @@ if {[tk windowingsystem] ne "win32"} { # Additional emacs-like bindings: -bind Entry <Control-a> { - if {!$tk_strictMotif} { - tk::EntrySetCursor %W 0 - } -} -bind Entry <Control-b> { - if {!$tk_strictMotif} { - tk::EntrySetCursor %W [expr {[%W index insert] - 1}] - } -} bind Entry <Control-d> { if {!$tk_strictMotif} { %W delete insert } } -bind Entry <Control-e> { - if {!$tk_strictMotif} { - tk::EntrySetCursor %W end - } -} -bind Entry <Control-f> { - if {!$tk_strictMotif} { - tk::EntrySetCursor %W [expr {[%W index insert] + 1}] - } -} bind Entry <Control-h> { if {!$tk_strictMotif} { tk::EntryBackspace %W diff --git a/library/iconlist.tcl b/library/iconlist.tcl index fc8128d..ce1aae2 100644 --- a/library/iconlist.tcl +++ b/library/iconlist.tcl @@ -444,10 +444,10 @@ package require Tk 8.6 bind $canvas <Control-B1-Motion> {;} bind $canvas <Shift-B1-Motion> [namespace code {my ShiftMotion1 %x %y}] - bind $canvas <Up> [namespace code {my UpDown -1}] - bind $canvas <Down> [namespace code {my UpDown 1}] - bind $canvas <Left> [namespace code {my LeftRight -1}] - bind $canvas <Right> [namespace code {my LeftRight 1}] + bind $canvas <<PrevLine>> [namespace code {my UpDown -1}] + bind $canvas <<NextLine>> [namespace code {my UpDown 1}] + bind $canvas <<PrevChar>> [namespace code {my LeftRight -1}] + bind $canvas <<NextChar>> [namespace code {my LeftRight 1}] bind $canvas <Return> [namespace code {my ReturnKey}] bind $canvas <KeyPress> [namespace code {my KeyPress %A}] bind $canvas <Control-KeyPress> ";" diff --git a/library/listbox.tcl b/library/listbox.tcl index 99047f4..01fb03d 100644 --- a/library/listbox.tcl +++ b/library/listbox.tcl @@ -69,28 +69,28 @@ bind Listbox <B1-Enter> { tk::CancelRepeat } -bind Listbox <Up> { +bind Listbox <<PrevLine>> { tk::ListboxUpDown %W -1 } -bind Listbox <Shift-Up> { +bind Listbox <<SelectPrevLine>> { tk::ListboxExtendUpDown %W -1 } -bind Listbox <Down> { +bind Listbox <<NextLine>> { tk::ListboxUpDown %W 1 } -bind Listbox <Shift-Down> { +bind Listbox <<SelectNextLine>> { tk::ListboxExtendUpDown %W 1 } -bind Listbox <Left> { +bind Listbox <<PrevChar>> { %W xview scroll -1 units } -bind Listbox <Control-Left> { +bind Listbox <<PrevWord>> { %W xview scroll -1 pages } -bind Listbox <Right> { +bind Listbox <<NextChar>> { %W xview scroll 1 units } -bind Listbox <Control-Right> { +bind Listbox <<NextWord>> { %W xview scroll 1 pages } bind Listbox <Prior> { @@ -107,10 +107,10 @@ bind Listbox <Control-Prior> { bind Listbox <Control-Next> { %W xview scroll 1 pages } -bind Listbox <Home> { +bind Listbox <<LineStart>> { %W xview moveto 0 } -bind Listbox <End> { +bind Listbox <<LineEnd>> { %W xview moveto 1 } bind Listbox <Control-Home> { @@ -120,7 +120,7 @@ bind Listbox <Control-Home> { %W selection set 0 event generate %W <<ListboxSelect>> } -bind Listbox <Shift-Control-Home> { +bind Listbox <Control-Shift-Home> { tk::ListboxDataExtend %W 0 } bind Listbox <Control-End> { @@ -130,7 +130,7 @@ bind Listbox <Control-End> { %W selection set end event generate %W <<ListboxSelect>> } -bind Listbox <Shift-Control-End> { +bind Listbox <Control-Shift-End> { tk::ListboxDataExtend %W [%W index end] } bind Listbox <<Copy>> { @@ -154,10 +154,10 @@ bind Listbox <Shift-Select> { bind Listbox <Escape> { tk::ListboxCancel %W } -bind Listbox <Control-slash> { +bind Listbox <<SelectAll>> { tk::ListboxSelectAll %W } -bind Listbox <Control-backslash> { +bind Listbox <<SelectNone>> { if {[%W cget -selectmode] ne "browse"} { %W selection clear 0 end event generate %W <<ListboxSelect>> diff --git a/library/menu.tcl b/library/menu.tcl index cc57532..a51c96f 100644 --- a/library/menu.tcl +++ b/library/menu.tcl @@ -149,16 +149,16 @@ bind Menu <Return> { bind Menu <Escape> { tk::MenuEscape %W } -bind Menu <Left> { +bind Menu <<PrevChar>> { tk::MenuLeftArrow %W } -bind Menu <Right> { +bind Menu <<NextChar>> { tk::MenuRightArrow %W } -bind Menu <Up> { +bind Menu <<PrevLine>> { tk::MenuUpArrow %W } -bind Menu <Down> { +bind Menu <<NextLine>> { tk::MenuDownArrow %W } bind Menu <KeyPress> { diff --git a/library/scale.tcl b/library/scale.tcl index b4da824..d9e7d27 100644 --- a/library/scale.tcl +++ b/library/scale.tcl @@ -71,34 +71,34 @@ if {[tk windowingsystem] eq "win32"} { bind Scale <Control-1> { tk::ScaleControlPress %W %x %y } -bind Scale <Up> { +bind Scale <<PrevLine>> { tk::ScaleIncrement %W up little noRepeat } -bind Scale <Down> { +bind Scale <<NextLine>> { tk::ScaleIncrement %W down little noRepeat } -bind Scale <Left> { +bind Scale <<PrevChar>> { tk::ScaleIncrement %W up little noRepeat } -bind Scale <Right> { +bind Scale <<NextChar>> { tk::ScaleIncrement %W down little noRepeat } -bind Scale <Control-Up> { +bind Scale <<PrevPara>> { tk::ScaleIncrement %W up big noRepeat } -bind Scale <Control-Down> { +bind Scale <<NextPara>> { tk::ScaleIncrement %W down big noRepeat } -bind Scale <Control-Left> { +bind Scale <<PrevWord>> { tk::ScaleIncrement %W up big noRepeat } -bind Scale <Control-Right> { +bind Scale <<NextWord>> { tk::ScaleIncrement %W down big noRepeat } -bind Scale <Home> { +bind Scale <<LineStart>> { %W set [%W cget -from] } -bind Scale <End> { +bind Scale <<LineEnd>> { %W set [%W cget -to] } diff --git a/library/scrlbar.tcl b/library/scrlbar.tcl index 9277160..1f8c7d2 100644 --- a/library/scrlbar.tcl +++ b/library/scrlbar.tcl @@ -91,28 +91,28 @@ bind Scrollbar <Control-2> { tk::ScrollTopBottom %W %x %y } -bind Scrollbar <Up> { +bind Scrollbar <<PrevLine>> { tk::ScrollByUnits %W v -1 } -bind Scrollbar <Down> { +bind Scrollbar <<NextLine>> { tk::ScrollByUnits %W v 1 } -bind Scrollbar <Control-Up> { +bind Scrollbar <<PrevPara>> { tk::ScrollByPages %W v -1 } -bind Scrollbar <Control-Down> { +bind Scrollbar <<NextPara>> { tk::ScrollByPages %W v 1 } -bind Scrollbar <Left> { +bind Scrollbar <<PrevChar>> { tk::ScrollByUnits %W h -1 } -bind Scrollbar <Right> { +bind Scrollbar <<NextChar>> { tk::ScrollByUnits %W h 1 } -bind Scrollbar <Control-Left> { +bind Scrollbar <<PrevWord>> { tk::ScrollByPages %W h -1 } -bind Scrollbar <Control-Right> { +bind Scrollbar <<NextWord>> { tk::ScrollByPages %W h 1 } bind Scrollbar <Prior> { @@ -121,10 +121,10 @@ bind Scrollbar <Prior> { bind Scrollbar <Next> { tk::ScrollByPages %W hv 1 } -bind Scrollbar <Home> { +bind Scrollbar <<LineStart>> { tk::ScrollToPos %W 0 } -bind Scrollbar <End> { +bind Scrollbar <<LineEnd>> { tk::ScrollToPos %W 1 } } diff --git a/library/spinbox.tcl b/library/spinbox.tcl index 20b477a..06c002c 100644 --- a/library/spinbox.tcl +++ b/library/spinbox.tcl @@ -120,10 +120,10 @@ bind Spinbox <Control-1> { %W icursor @%x } -bind Spinbox <Up> { +bind Spinbox <<PrevLine>> { %W invoke buttonup } -bind Spinbox <Down> { +bind Spinbox <<NextLine>> { %W invoke buttondown } @@ -193,10 +193,10 @@ bind Spinbox <Control-Shift-space> { bind Spinbox <Shift-Select> { %W selection adjust insert } -bind Spinbox <Control-slash> { +bind Spinbox <<SelectAll>> { %W selection range 0 end } -bind Spinbox <Control-backslash> { +bind Spinbox <<SelectNone>> { %W selection clear } bind Spinbox <KeyPress> { @@ -231,31 +231,11 @@ if {[tk windowingsystem] ne "win32"} { # Additional emacs-like bindings: -bind Spinbox <Control-a> { - if {!$tk_strictMotif} { - ::tk::EntrySetCursor %W 0 - } -} -bind Spinbox <Control-b> { - if {!$tk_strictMotif} { - ::tk::EntrySetCursor %W [expr {[%W index insert] - 1}] - } -} bind Spinbox <Control-d> { if {!$tk_strictMotif} { %W delete insert } } -bind Spinbox <Control-e> { - if {!$tk_strictMotif} { - ::tk::EntrySetCursor %W end - } -} -bind Spinbox <Control-f> { - if {!$tk_strictMotif} { - ::tk::EntrySetCursor %W [expr {[%W index insert] + 1}] - } -} bind Spinbox <Control-h> { if {!$tk_strictMotif} { ::tk::EntryBackspace %W diff --git a/library/text.tcl b/library/text.tcl index 331d1b4..e59a86e 100644 --- a/library/text.tcl +++ b/library/text.tcl @@ -92,10 +92,10 @@ bind Text <<PrevChar>> { bind Text <<NextChar>> { tk::TextSetCursor %W insert+1displayindices } -bind Text <Up> { +bind Text <<PrevLine>> { tk::TextSetCursor %W [tk::TextUpDownLine %W -1] } -bind Text <Down> { +bind Text <<NextLine>> { tk::TextSetCursor %W [tk::TextUpDownLine %W 1] } bind Text <<SelectPrevChar>> { @@ -104,10 +104,10 @@ bind Text <<SelectPrevChar>> { bind Text <<SelectNextChar>> { tk::TextKeySelect %W [%W index {insert + 1displayindices}] } -bind Text <Shift-Up> { +bind Text <<SelectPrevLine>> { tk::TextKeySelect %W [tk::TextUpDownLine %W -1] } -bind Text <Shift-Down> { +bind Text <<SelectNextLine>> { tk::TextKeySelect %W [tk::TextUpDownLine %W 1] } bind Text <<PrevWord>> { @@ -116,10 +116,10 @@ bind Text <<PrevWord>> { bind Text <<NextWord>> { tk::TextSetCursor %W [tk::TextNextWord %W insert] } -bind Text <Control-Up> { +bind Text <<PrevPara>> { tk::TextSetCursor %W [tk::TextPrevPara %W insert] } -bind Text <Control-Down> { +bind Text <<NextPara>> { tk::TextSetCursor %W [tk::TextNextPara %W insert] } bind Text <<SelectPrevWord>> { @@ -128,10 +128,10 @@ bind Text <<SelectPrevWord>> { bind Text <<SelectNextWord>> { tk::TextKeySelect %W [tk::TextNextWord %W insert] } -bind Text <Shift-Control-Up> { +bind Text <<SelectPrevPara>> { tk::TextKeySelect %W [tk::TextPrevPara %W insert] } -bind Text <Shift-Control-Down> { +bind Text <<SelectNextPara>> { tk::TextKeySelect %W [tk::TextNextPara %W insert] } bind Text <Prior> { @@ -240,10 +240,10 @@ bind Text <Shift-Select> { set tk::Priv(selectMode) char tk::TextKeyExtend %W insert } -bind Text <Control-slash> { +bind Text <<SelectAll>> { %W tag add sel 1.0 end } -bind Text <Control-backslash> { +bind Text <<SelectNone>> { %W tag remove sel 1.0 end } bind Text <<Cut>> { @@ -287,31 +287,11 @@ if {[tk windowingsystem] eq "aqua"} { # Additional emacs-like bindings: -bind Text <Control-a> { - if {!$tk_strictMotif} { - tk::TextSetCursor %W {insert display linestart} - } -} -bind Text <Control-b> { - if {!$tk_strictMotif} { - tk::TextSetCursor %W insert-1displayindices - } -} bind Text <Control-d> { if {!$tk_strictMotif && [%W compare end != insert+1c]} { %W delete insert } } -bind Text <Control-e> { - if {!$tk_strictMotif} { - tk::TextSetCursor %W {insert display lineend} - } -} -bind Text <Control-f> { - if {!$tk_strictMotif} { - tk::TextSetCursor %W insert+1displayindices - } -} bind Text <Control-k> { if {!$tk_strictMotif && [%W compare end != insert+1c]} { if {[%W compare insert == {insert lineend}]} { @@ -321,22 +301,12 @@ bind Text <Control-k> { } } } -bind Text <Control-n> { - if {!$tk_strictMotif} { - tk::TextSetCursor %W [tk::TextUpDownLine %W 1] - } -} bind Text <Control-o> { if {!$tk_strictMotif} { %W insert insert \n %W mark set insert insert-1c } } -bind Text <Control-p> { - if {!$tk_strictMotif} { - tk::TextSetCursor %W [tk::TextUpDownLine %W -1] - } -} bind Text <Control-t> { if {!$tk_strictMotif} { tk::TextTranspose %W @@ -390,31 +360,7 @@ bind Text <Meta-Delete> { # Macintosh only bindings: if {[tk windowingsystem] eq "aqua"} { -bind Text <Option-Left> { - tk::TextSetCursor %W [tk::TextPrevPos %W insert tcl_startOfPreviousWord] -} -bind Text <Option-Right> { - tk::TextSetCursor %W [tk::TextNextWord %W insert] -} -bind Text <Option-Up> { - tk::TextSetCursor %W [tk::TextPrevPara %W insert] -} -bind Text <Option-Down> { - tk::TextSetCursor %W [tk::TextNextPara %W insert] -} -bind Text <Shift-Option-Left> { - tk::TextKeySelect %W [tk::TextPrevPos %W insert tcl_startOfPreviousWord] -} -bind Text <Shift-Option-Right> { - tk::TextKeySelect %W [tk::TextNextWord %W insert] -} -bind Text <Shift-Option-Up> { - tk::TextKeySelect %W [tk::TextPrevPara %W insert] -} -bind Text <Shift-Option-Down> { - tk::TextKeySelect %W [tk::TextNextPara %W insert] -} -bind Text <Control-v> { +bind Text <<Paste>> { tk::TextScrollPages %W 1 } diff --git a/library/tk.tcl b/library/tk.tcl index 928fc2e..0d8853f 100644 --- a/library/tk.tcl +++ b/library/tk.tcl @@ -307,9 +307,9 @@ proc ::tk::EventMotifBindings {n1 dummy dummy} { set op add } - event $op <<Cut>> <Control-Key-w> - event $op <<Copy>> <Meta-Key-w> - event $op <<Paste>> <Control-Key-y> + event $op <<Cut>> <Control-Key-w> <Shift-Key-Delete> + event $op <<Copy>> <Meta-Key-w> <Control-Key-Insert> + event $op <<Paste>> <Control-Key-y> <Shift-Key-Insert> event $op <<Undo>> <Control-underscore> } @@ -358,29 +358,39 @@ if {![llength [info command tk_chooseDirectory]]} { switch -exact -- [tk windowingsystem] { "x11" { - event add <<Cut>> <Control-Key-x> <Key-F20> <Control-Lock-Key-X> - event add <<Copy>> <Control-Key-c> <Key-F16> <Control-Lock-Key-C> - event add <<Paste>> <Control-Key-v> <Key-F18> <Control-Lock-Key-V> - event add <<PasteSelection>> <ButtonRelease-2> - event add <<Undo>> <Control-Key-z> <Control-Lock-Key-Z> - event add <<Redo>> <Control-Key-Z> <Control-Lock-Key-z> - event add <<ContextMenu>> <Button-3> + event add <<Cut>> <Control-Key-x> <Key-F20> <Control-Lock-Key-X> + event add <<Copy>> <Control-Key-c> <Key-F16> <Control-Lock-Key-C> + event add <<Paste>> <Control-Key-v> <Key-F18> <Control-Lock-Key-V> + event add <<PasteSelection>> <ButtonRelease-2> + event add <<Undo>> <Control-Key-z> <Control-Lock-Key-Z> + event add <<Redo>> <Control-Key-Z> <Control-Lock-Key-z> + event add <<ContextMenu>> <Button-3> if {[info exists tcl_platform(os)] && $tcl_platform(os) eq "Darwin"} { - event add <<ContextMenu>> <Button-2> + event add <<ContextMenu>> <Button-2> } - event add <<NextChar>> <Right> - event add <<SelectNextChar>> <Shift-Right> - event add <<PrevChar>> <Left> - event add <<SelectPrevChar>> <Shift-Left> + event add <<SelectAll>> <Control-Key-slash> + event add <<SelectNone>> <Control-Key-backslash> + event add <<NextChar>> <Right> <Control-Key-f> <Control-Lock-Key-F> + event add <<SelectNextChar>> <Shift-Right> <Control-Key-F> <Control-Lock-Key-f> + event add <<PrevChar>> <Left> <Control-Key-b> <Control-Lock-Key-B> + event add <<SelectPrevChar>> <Shift-Left> <Control-Key-B> <Control-Lock-Key-b> event add <<NextWord>> <Control-Right> - event add <<SelectNextWord>> <Shift-Control-Right> + event add <<SelectNextWord>> <Control-Shift-Right> event add <<PrevWord>> <Control-Left> - event add <<SelectPrevWord>> <Shift-Control-Left> - event add <<LineStart>> <Home> - event add <<SelectLineStart>> <Shift-Home> - event add <<LineEnd>> <End> - event add <<SelectLineEnd>> <Shift-End> + event add <<SelectPrevWord>> <Control-Shift-Left> + event add <<LineStart>> <Home> <Control-Key-a> <Control-Lock-Key-A> + event add <<SelectLineStart>> <Shift-Home> <Control-Key-A> <Control-Lock-Key-a> + event add <<LineEnd>> <End> <Control-Key-e> <Control-Lock-Key-E> + event add <<SelectLineEnd>> <Shift-End> <Control-Key-E> <Control-Lock-Key-e> + event add <<PrevLine>> <Up> <Control-Key-p> <Control-Lock-Key-P> + event add <<NextLine>> <Down> <Control-Key-n> <Control-Lock-Key-N> + event add <<SelectPrevLine>> <Shift-Up> <Control-Key-P> <Control-Lock-Key-p> + event add <<SelectNextLine>> <Shift-Down> <Control-Key-N> <Control-Lock-Key-n> + event add <<PrevPara>> <Control-Up> + event add <<NextPara>> <Control-Down> + event add <<SelectPrevPara>> <Control-Shift-Up> + event add <<SelectPrevPara>> <Control-Shift-Down> # Some OS's define a goofy (as in, not <Shift-Tab>) keysym that is # returned when the user presses <Shift-Tab>. In order for tab @@ -399,56 +409,73 @@ switch -exact -- [tk windowingsystem] { set ::tk::AlwaysShowSelection 1 } "win32" { - event add <<Cut>> <Control-Key-x> <Shift-Key-Delete> \ - <Control-Lock-Key-X> - event add <<Copy>> <Control-Key-c> <Control-Key-Insert> \ - <Control-Lock-Key-C> - event add <<Paste>> <Control-Key-v> <Shift-Key-Insert> \ - <Control-Lock-Key-V> - event add <<PasteSelection>> <ButtonRelease-2> - event add <<Undo>> <Control-Key-z> <Control-Lock-Key-Z> - event add <<Redo>> <Control-Key-y> <Control-Lock-Key-Y> - event add <<ContextMenu>> <Button-3> - + event add <<Cut>> <Control-Key-x> <Shift-Key-Delete> <Control-Lock-Key-X> + event add <<Copy>> <Control-Key-c> <Control-Key-Insert> <Control-Lock-Key-C> + event add <<Paste>> <Control-Key-v> <Shift-Key-Insert> <Control-Lock-Key-V> + event add <<PasteSelection>> <ButtonRelease-2> + event add <<Undo>> <Control-Key-z> <Control-Lock-Key-Z> + event add <<Redo>> <Control-Key-y> <Control-Lock-Key-Y> + event add <<ContextMenu>> <Button-3> + + event add <<SelectAll>> <Control-Key-slash> <Control-Key-a> <Control-Lock-Key-A> + event add <<SelectNone>> <Control-Key-backslash> event add <<NextChar>> <Right> event add <<SelectNextChar>> <Shift-Right> event add <<PrevChar>> <Left> event add <<SelectPrevChar>> <Shift-Left> event add <<NextWord>> <Control-Right> - event add <<SelectNextWord>> <Shift-Control-Right> + event add <<SelectNextWord>> <Control-Shift-Right> event add <<PrevWord>> <Control-Left> - event add <<SelectPrevWord>> <Shift-Control-Left> + event add <<SelectPrevWord>> <Control-Shift-Left> event add <<LineStart>> <Home> event add <<SelectLineStart>> <Shift-Home> event add <<LineEnd>> <End> event add <<SelectLineEnd>> <Shift-End> + event add <<PrevLine>> <Up> + event add <<NextLine>> <Down> + event add <<SelectPrevLine>> <Shift-Up> + event add <<SelectNextLine>> <Shift-Down> + event add <<PrevPara>> <Control-Up> + event add <<NextPara>> <Control-Down> + event add <<SelectPrevPara>> <Control-Shift-Up> + event add <<SelectPrevPara>> <Control-Shift-Down> } "aqua" { - event add <<Cut>> <Command-Key-x> <Key-F2> <Control-Lock-Key-X> - event add <<Copy>> <Command-Key-c> <Key-F3> <Control-Lock-Key-C> - event add <<Paste>> <Command-Key-v> <Key-F4> <Control-Lock-Key-V> - event add <<PasteSelection>> <ButtonRelease-2> - event add <<Clear>> <Clear> - event add <<Undo>> <Command-Key-z> <Control-Lock-Key-Z> - event add <<Redo>> <Command-Key-y> <Control-Lock-Key-Y> - event add <<ContextMenu>> <Button-2> + event add <<Cut>> <Command-Key-x> <Key-F2> <Control-Lock-Key-X> + event add <<Copy>> <Command-Key-c> <Key-F3> <Control-Lock-Key-C> + event add <<Paste>> <Command-Key-v> <Key-F4> <Control-Lock-Key-V> + event add <<PasteSelection>> <ButtonRelease-2> + event add <<Clear>> <Clear> + event add <<ContextMenu>> <Button-2> # Official bindings # See http://support.apple.com/kb/HT1343 - event add <<NextChar>> <Right> - event add <<SelectNextChar>> <Shift-Right> - event add <<PrevChar>> <Left> - event add <<SelectPrevChar>> <Shift-Left> + event add <<SelectAll>> <Command-Key-a> + event add <<SelectNone>> <Option-Command-Key-a> + event add <<Undo>> <Command-Key-z> <Control-Lock-Key-Z> + event add <<Redo>> <Command-Key-Z> <Control-Lock-Key-z> + event add <<NextChar>> <Right> <Control-Key-f> <Control-Lock-Key-F> + event add <<SelectNextChar>> <Shift-Right> <Control-Key-F> <Control-Lock-Key-f> + event add <<PrevChar>> <Left> <Control-Key-b> <Control-Lock-Key-B> + event add <<SelectPrevChar>> <Shift-Left> <Control-Key-B> <Control-Lock-Key-b> event add <<NextWord>> <Option-Right> event add <<SelectNextWord>> <Shift-Option-Right> event add <<PrevWord>> <Option-Left> event add <<SelectPrevWord>> <Shift-Option-Left> - event add <<SelectLineStart>> <Shift-Home> <Shift-Command-Left> - event add <<SelectLineEnd>> <Shift-End> <Shift-Command-Right> + event add <<LineStart>> <Home> <Command-Left> <Control-Key-a> <Control-Lock-Key-A> + event add <<SelectLineStart>> <Shift-Home> <Shift-Command-Left> <Control-Key-A> <Control-Lock-Key-a> + event add <<LineEnd>> <End> <Command-Right> <Control-Key-e> <Control-Lock-Key-E> + event add <<SelectLineEnd>> <Shift-End> <Shift-Command-Right> <Control-Key-E> <Control-Lock-Key-e> + event add <<PrevLine>> <Up> <Control-Key-p> <Control-Lock-Key-P> + event add <<SelectPrevLine>> <Shift-Up> <Control-Key-P> <Control-Lock-Key-p> + event add <<NextLine>> <Down> <Control-Key-n> <Control-Lock-Key-N> + event add <<SelectNextLine>> <Shift-Down> <Control-Key-N> <Control-Lock-Key-n> # Not official, but logical extensions of above. Also derived from # bindings present in MS Word on OSX. - event add <<LineStart>> <Home> <Command-Left> - event add <<LineEnd>> <End> <Command-Right> + event add <<PrevPara>> <Option-Up> + event add <<NextPara>> <Option-Down> + event add <<SelectPrevPara>> <Shift-Option-Up> + event add <<SelectPrevPara>> <Shift-Option-Down> } } diff --git a/library/ttk/entry.tcl b/library/ttk/entry.tcl index a27921a..22c4115 100644 --- a/library/ttk/entry.tcl +++ b/library/ttk/entry.tcl @@ -107,8 +107,8 @@ bind TEntry <<SelectNextWord>> { ttk::entry::Extend %W nextword } bind TEntry <<SelectLineStart>> { ttk::entry::Extend %W home } bind TEntry <<SelectLineEnd>> { ttk::entry::Extend %W end } -bind TEntry <Control-Key-slash> { %W selection range 0 end } -bind TEntry <Control-Key-backslash> { %W selection clear } +bind TEntry <<SelectAll>> { %W selection range 0 end } +bind TEntry <<SelectNone>> { %W selection clear } bind TEntry <<TraverseIn>> { %W selection range 0 end; %W icursor end } @@ -136,15 +136,13 @@ if {[tk windowingsystem] eq "aqua"} { bind TEntry <Command-KeyPress> {# nothing} } # Tk-on-Cocoa generates characters for these two keys. [Bug 2971663] -bind TEntry <Down> {# nothing} -bind TEntry <Up> {# nothing} +bind TEntry <<PrevLine>> {# nothing} +bind TEntry <<NextLine>> {# nothing} ## Additional emacs-like bindings: # -bind TEntry <Control-Key-a> { ttk::entry::Move %W home } bind TEntry <Control-Key-b> { ttk::entry::Move %W prevchar } bind TEntry <Control-Key-d> { ttk::entry::Delete %W } -bind TEntry <Control-Key-e> { ttk::entry::Move %W end } bind TEntry <Control-Key-f> { ttk::entry::Move %W nextchar } bind TEntry <Control-Key-h> { ttk::entry::Backspace %W } bind TEntry <Control-Key-k> { %W delete insert end } diff --git a/library/ttk/notebook.tcl b/library/ttk/notebook.tcl index d424b6c..72b85e6 100644 --- a/library/ttk/notebook.tcl +++ b/library/ttk/notebook.tcl @@ -108,7 +108,7 @@ proc ttk::notebook::enableTraversal {nb} { bind $top <Control-Key-Next> {+ttk::notebook::TLCycleTab %W 1} bind $top <Control-Key-Prior> {+ttk::notebook::TLCycleTab %W -1} bind $top <Control-Key-Tab> {+ttk::notebook::TLCycleTab %W 1} - bind $top <Shift-Control-Key-Tab> {+ttk::notebook::TLCycleTab %W -1} + bind $top <Control-Shift-Key-Tab> {+ttk::notebook::TLCycleTab %W -1} catch { bind $top <Control-Key-ISO_Left_Tab> {+ttk::notebook::TLCycleTab %W -1} } @@ -170,7 +170,7 @@ proc ttk::notebook::EnclosingNotebook {w} { } # TLCycleTab -- -# toplevel binding procedure for Control-Tab / Shift-Control-Tab +# toplevel binding procedure for Control-Tab / Control-Shift-Tab # Select the next/previous tab in the nearest ancestor notebook. # proc ttk::notebook::TLCycleTab {w dir} { diff --git a/library/ttk/scale.tcl b/library/ttk/scale.tcl index 23d08ed..69b9dd8 100644 --- a/library/ttk/scale.tcl +++ b/library/ttk/scale.tcl @@ -21,16 +21,19 @@ bind TScale <ButtonPress-3> { ttk::scale::Jump %W %x %y } bind TScale <B3-Motion> { ttk::scale::Drag %W %x %y } bind TScale <ButtonRelease-3> { ttk::scale::Release %W %x %y } -bind TScale <Left> { ttk::scale::Increment %W -1 } -bind TScale <Up> { ttk::scale::Increment %W -1 } -bind TScale <Right> { ttk::scale::Increment %W 1 } -bind TScale <Down> { ttk::scale::Increment %W 1 } -bind TScale <Control-Left> { ttk::scale::Increment %W -10 } -bind TScale <Control-Up> { ttk::scale::Increment %W -10 } -bind TScale <Control-Right> { ttk::scale::Increment %W 10 } -bind TScale <Control-Down> { ttk::scale::Increment %W 10 } -bind TScale <Home> { %W set [%W cget -from] } -bind TScale <End> { %W set [%W cget -to] } +## Keyboard navigation bindings: +# +bind TScale <<LineStart>> { %W set [%W cget -from] } +bind TScale <<LineEnd>> { %W set [%W cget -to] } + +bind TScale <<PrevChar>> { ttk::scale::Increment %W -1 } +bind TScale <<PrevLine>> { ttk::scale::Increment %W -1 } +bind TScale <<NextChar>> { ttk::scale::Increment %W 1 } +bind TScale <<NextLine>> { ttk::scale::Increment %W 1 } +bind TScale <<PrevWord>> { ttk::scale::Increment %W -10 } +bind TScale <<PrevPara>> { ttk::scale::Increment %W -10 } +bind TScale <<NextWord>> { ttk::scale::Increment %W 10 } +bind TScale <<NextPara>> { ttk::scale::Increment %W 10 } proc ttk::scale::Press {w x y} { variable State diff --git a/unix/tkUnixEvent.c b/unix/tkUnixEvent.c index 0987129..4d0ccfa 100644 --- a/unix/tkUnixEvent.c +++ b/unix/tkUnixEvent.c @@ -646,7 +646,7 @@ OpenIM( } if ((XGetIMValues(dispPtr->inputMethod, XNQueryInputStyle, &stylePtr, - (void *) NULL) != NULL) || (stylePtr == NULL)) { + NULL) != NULL) || (stylePtr == NULL)) { goto error; } diff --git a/unix/tkUnixKey.c b/unix/tkUnixKey.c index f13adf7..d07f13a 100644 --- a/unix/tkUnixKey.c +++ b/unix/tkUnixKey.c @@ -64,9 +64,9 @@ Tk_SetCaretPos( spot.x = dispPtr->caret.x; spot.y = dispPtr->caret.y + dispPtr->caret.height; - preedit_attr = XVaCreateNestedList(0, XNSpotLocation, &spot, (void *) NULL); + preedit_attr = XVaCreateNestedList(0, XNSpotLocation, &spot, NULL); XSetICValues(winPtr->inputContext, XNPreeditAttributes, preedit_attr, - (void *) NULL); + NULL); XFree(preedit_attr); } #endif diff --git a/unix/tkUnixRFont.c b/unix/tkUnixRFont.c index 50642ad..ab2ed4a 100644 --- a/unix/tkUnixRFont.c +++ b/unix/tkUnixRFont.c @@ -123,7 +123,7 @@ GetFont( FC_FAMILY, FcTypeString, "sans", FC_SIZE, FcTypeDouble, 12.0, FC_MATRIX, FcTypeMatrix, &mat, - (void *) NULL); + NULL); } if (!ftFont) { /* diff --git a/win/buildall.vc.bat b/win/buildall.vc.bat index 58360b9..1400dbb 100755 --- a/win/buildall.vc.bat +++ b/win/buildall.vc.bat @@ -23,18 +23,27 @@ goto OPTIONS_DONE :: reset errorlevel cd > nul +:: You might have installed your developer studio to add itself to the +:: path or have already run vcvars32.bat. Testing these envars proves +:: cl.exe and friends are in your path. +:: +if defined VCINSTALLDIR (goto :startBuilding) +if defined MSDEVDIR (goto :startBuilding) +if defined MSVCDIR (goto :startBuilding) +if defined MSSDK (goto :startBuilding) +if defined WINDOWSSDKDIR (goto :startBuilding) + :: We need to run the development environment batch script that comes -:: with developer studio (v4,5,6,7,etc...) All have it. These paths -:: might not be correct. You may need to edit these. +:: with developer studio (v4,5,6,7,etc...) All have it. This path +:: might not be correct. You should call it yourself prior to running +:: this batchfile. :: -if not defined MSDevDir ( - call "C:\Program Files\Microsoft Developer Studio\vc98\bin\vcvars32.bat" - ::call "C:\Program Files\Microsoft Developer Studio\vc\bin\vcvars32.bat" - ::call c:\dev\devstudio60\vc98\bin\vcvars32.bat - if errorlevel 1 goto no_vcvars -) +call "C:\Program Files\Microsoft Developer Studio\vc98\bin\vcvars32.bat" +if errorlevel 1 (goto no_vcvars) +:startBuilding +echo. echo Sit back and have a cup of coffee while this grinds through ;) echo You asked for *everything*, remember? echo. @@ -54,6 +63,7 @@ if "%TCLDIR%" == "" set TCLDIR=..\..\tcl :: Build the normal stuff along with the help file. :: +<<<<<<< BEGIN MERGE CONFLICT: local copy shown first <<<<<<<<<<<<<<< set OPTS=none if not %SYMBOLS%.==. set OPTS=symbols nmake -nologo -f makefile.vc release htmlhelp OPTS=%OPTS% %1 @@ -75,26 +85,43 @@ if errorlevel 1 goto error :: Build the core and shell for thread support. :: -set OPTS=threads -if not %SYMBOLS%.==. set OPTS=symbols,threads +======= COMMON ANCESTOR content follows ============================ +set OPTS=none +if not %SYMBOLS%.==. set OPTS=symbols +nmake -nologo -f makefile.vc release winhelp OPTS=%OPTS% %1 +if errorlevel 1 goto error + +:: Build the static core, dlls and shell. +:: +set OPTS=static +if not %SYMBOLS%.==. set OPTS=symbols,static nmake -nologo -f makefile.vc release OPTS=%OPTS% %1 if errorlevel 1 goto error -:: Build a static, thread support core library (no shell). +:: Build the special static libraries that use the dynamic runtime. :: -set OPTS=static,threads -if not %SYMBOLS%.==. set OPTS=symbols,static,threads +set OPTS=static,msvcrt +if not %SYMBOLS%.==. set OPTS=symbols,static,msvcrt nmake -nologo -f makefile.vc core OPTS=%OPTS% %1 if errorlevel 1 goto error -:: Build the special static libraries the use the dynamic runtime, -:: but now with thread support. +:: Build the core and shell for thread support. +:: +======= MERGED IN content follows ================================== +>>>>>>> END MERGE CONFLICT >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> +set OPTS=threads +if not %SYMBOLS%.==. set OPTS=symbols,threads +nmake -nologo -f makefile.vc release OPTS=%OPTS% %1 +if errorlevel 1 goto error + +:: Build the static core and shell. :: set OPTS=static,msvcrt,threads if not %SYMBOLS%.==. set OPTS=symbols,static,msvcrt,threads -nmake -nologo -f makefile.vc core OPTS=%OPTS% %1 +nmake -nologo -f makefile.vc shell OPTS=%OPTS% %1 if errorlevel 1 goto error +set OPTS= set SYMBOLS= goto end @@ -103,16 +130,16 @@ echo *** BOOM! *** goto end :no_vcvars -echo vcvars32.bat not found. You'll need to edit this batch script. +echo vcvars32.bat was not run prior to this batchfile, nor are the MS tools in your path. goto out :help title buildall.vc.bat help message echo usage: -echo %0 : builds Tk for all build types (do this first) -echo %0 install : installs all the release builds (do this second) -echo %0 symbols : builds Tk for all debugging build types. -echo %0 symbols install : install all the debug builds +echo %0 : builds Tk for all build types (do this first) +echo %0 install : installs all the release builds (do this second) +echo %0 symbols : builds Tk for all debugging build types +echo %0 symbols install : install all the debug builds echo. goto out diff --git a/win/makefile.vc b/win/makefile.vc index d69a530..584a11b 100644 --- a/win/makefile.vc +++ b/win/makefile.vc @@ -42,8 +42,8 @@ the build instructions. # turn on the 64-bit compiler, if your SDK has it. # # 3) Targets are: -# release -- Builds the core, the shell and the dlls. (default) -# dlls -- Just builds the windows extensions +# release -- Builds the core, the shell. (default) +# dlls -- Just builds the windows extensions. # shell -- Just builds the shell and the core. # core -- Only builds the core [tkXX.(dll|lib)]. # all -- Builds everything. @@ -51,7 +51,7 @@ the build instructions. # tktest -- Just builds the binaries for the test suite. # install -- Installs the built binaries and libraries to $(INSTALLDIR) # as the root of the install tree. -# cwish -- builds a console version of wish. +# cwish -- Builds a console version of wish. # tidy/clean/hose -- varying levels of cleaning. # genstubs -- Rebuilds the Stubs table and support files (dev only). # depend -- Generates an accurate set of source dependancies for this @@ -62,10 +62,8 @@ the build instructions. # troff manual pages found in $(ROOT)\doc. You need to # have installed the HTML Help Compiler package from Microsoft # to produce the .chm file. -# winhelp -- (deprecated) Builds the windows .hlp file for Tcl from -# the troff man files found in $(ROOT)\doc. This type of -# help file is deprecated by Microsoft in favour of html -# help files (.chm) +# winhelp -- Builds the windows .hlp file for Tcl from the troff man +# files found in $(ROOT)\doc. # # 4) Macros usable on the commandline: # TCLDIR=<path> @@ -78,54 +76,55 @@ the build instructions. # Sets where to install Tcl from the built binaries. # C:\Progra~1\Tcl is assumed when not specified. # -# OPTS=static,msvcrt,staticpkg,nothreads,symbols,profile,loimpact,unchecked,pdbs,none +# OPTS=loimpact,msvcrt,nothreads,noxp,pdbs,profile,square,static,staticpkg,symbols,unchecked,none # Sets special options for the core. The default is for none. # Any combination of the above may be used (comma separated). # 'none' will over-ride everything to nothing. # -# static = Builds a static library of the core instead of a -# dll. The shell will be static (and large), as well. -# msvcrt = Affects the static option only to switch it from +# loimpact = Adds a flag for how NT treats the heap to keep memory +# in use, low. This is said to impact alloc performance. +# msvcrt = Affects the static option only to switch it from # using libcmt(d) as the C runtime [by default] to # msvcrt(d). This is useful for static embedding # support. -# staticpkg = Affects the static option only to switch wishXX.exe +# nothreads= Turns off full multithreading support. +# noxp = If you do not have the uxtheme.h header then you +# cannot include support for XP themeing. +# square = Include the demo square widget. +# static = Builds a static library of the core instead of a +# dll. The shell will be static (and large), as well. +# staticpkg= Affects the static option only to switch wishXX.exe # to have the dde and reg extension linked inside it. -# nothreads = Turns off full multithreading support. +# pdbs = Build detached symbols for release builds. +# profile = Adds profiling hooks. Map file is assumed. # thrdalloc = Use the thread allocator (shared global free pool) # This is the default on threaded builds. +# tclalloc = Use the old non-thread allocator # symbols = Debug build. Links to the debug C runtime, disables # optimizations and creates pdb symbols files. -# pdbs = Build detached symbols for release builds. -# profile = Adds profiling hooks. Map file is assumed. -# loimpact = Adds a flag for how NT treats the heap to keep memory -# in use, low. This is said to impact alloc performance. # unchecked = Allows a symbols build to not use the debug # enabled runtime (msvcrt.dll not msvcrtd.dll # or libcmt.lib not libcmtd.lib). -# noxp = If you do not have the uxtheme.h header then you -# cannot include support for XP themeing. -# square = Include the demo square widget. # -# STATS=memdbg,compdbg,none +# STATS=compdbg,memdbg,none # Sets optional memory and bytecode compiler debugging code added # to the core. The default is for none. Any combination of the # above may be used (comma separated). 'none' will over-ride # everything to nothing. # -# memdbg = Enables the debugging memory allocator. # compdbg = Enables byte compilation logging. +# memdbg = Enables the debugging memory allocator. # -# CHECKS=nodep,fullwarn,64bit,none +# CHECKS=64bit,fullwarn,nodep,none # Sets special macros for checking compatability. # -# nodep = Turns off compatability macros to ensure Tk isn't -# being built with deprecated functions. +# 64bit = Enable 64bit portability warnings (if available) # fullwarn = Builds with full compiler and link warnings enabled. # Very verbose. -# 64bit = Enable 64bit portability warnings (if available) +# nodep = Turns off compatability macros to ensure the core +# isn't being built with deprecated functions. # -# MACHINE=(IX86|IA64|AMD64|ALPHA) +# MACHINE=(ALPHA|AMD64|IA64|IX86) # Set the machine type used for the compiler, linker, and # resource compiler. This hook is needed to tell the tools # when alternate platforms are requested. IX86 is the default @@ -183,7 +182,7 @@ Please `cd` to its location first. !error $(MSG) !endif -PROJECT = tk +PROJECT = tk !include "rules.vc" !if $(TCLINSTALL) @@ -243,7 +242,6 @@ WISHOBJS = \ !if $(TCL_USE_STATIC_PACKAGES) $(TCLDDELIB) \ $(TCLREGLIB) \ - $(TCLSTUBLIB) \ !endif $(TMP_DIR)\wish.res @@ -367,7 +365,7 @@ TKOBJS = \ $(TMP_DIR)\tkVisual.obj \ $(TMP_DIR)\tkStubInit.obj \ $(TMP_DIR)\tkWindow.obj \ - $(TTK_OBJS) \ + $(TTK_OBJS) \ !if !$(STATIC_BUILD) $(TMP_DIR)\tk.res !endif @@ -408,7 +406,8 @@ TTK_OBJS = \ $(TMP_DIR)\ttkStubInit.obj TKSTUBOBJS = \ - $(TMP_DIR)\tkStubLib.obj $(TMP_DIR)\ttkStubLib.obj + $(TMP_DIR)\tkStubLib.obj \ + $(TMP_DIR)\ttkStubLib.obj WINDIR = $(ROOT)\win @@ -448,7 +447,7 @@ cdebug = $(OPTIMIZATIONS) cdebug = !endif !if $(SYMBOLS) -cdebug = $(cdebug) -Zi +cdebug = $(cdebug) -Zi !endif !else if "$(MACHINE)" == "IA64" || "$(MACHINE)" == "AMD64" ### Warnings are too many, can't support warnings into errors. @@ -476,15 +475,10 @@ crt = -MT !endif BASE_CFLAGS = $(cdebug) $(cflags) $(crt) $(TK_INCLUDES) -TK_CFLAGS = $(BASE_CFLAGS) $(TK_DEFINES) +TK_CFLAGS = $(BASE_CFLAGS) $(TK_DEFINES) -DUSE_TCL_STUBS CON_CFLAGS = $(cdebug) $(cflags) $(crt) -DCONSOLE WISH_CFLAGS = $(BASE_CFLAGS) $(TK_DEFINES) -### Stubs files should not be compiled with -GL -STUB_CFLAGS = $(cflags) $(cdebug:-GL=) $(TK_DEFINES) - -!if !$(STATIC_BUILD) -TK_CFLAGS = $(TK_CFLAGS) -DUSE_TCL_STUBS -!endif +STUB_CFLAGS = $(cflags) $(cdebug) $(TK_DEFINES) #--------------------------------------------------------------------- # Link flags @@ -522,10 +516,7 @@ dlllflags = $(lflags) -dll conlflags = $(lflags) -subsystem:console guilflags = $(lflags) -subsystem:windows -tcllibs = $(TCLIMPLIB) -!if !$(STATIC_BUILD) -tcllibs = $(TCLSTUBLIB) $(tcllibs) -!endif +tcllibs = $(TCLSTUBLIB) $(TCLIMPLIB) baselibs = netapi32.lib kernel32.lib user32.lib advapi32.lib ws2_32.lib # Avoid 'unresolved external symbol __security_cookie' errors. @@ -543,7 +534,7 @@ guilibs = $(baselibs) gdi32.lib #--------------------------------------------------------------------- !if "$(TESTPAT)" != "" -TESTFLAGS = $(TESTFLAGS) -file $(TESTPAT) +TESTFLAGS = $(TESTFLAGS) -file $(TESTPAT) !endif @@ -570,11 +561,7 @@ test-classic: setup $(TKTEST) $(TKLIB) $(CAT32) !else @set PATH=$(_TCLDIR)\win\$(BUILDDIRTOP);$(PATH) !endif -!if "$(OS)" == "Windows_NT" || "$(MSVCDIR)" == "IDE" - $(DEBUGGER) $(TKTEST) "$(ROOT)/tests/all.tcl" $(TESTFLAGS) | $(CAT32) -!else - $(DEBUGGER) $(TKTEST) "$(ROOT)/tests/all.tcl" $(TESTFLAGS) | $(CAT32) -!endif + $(DEBUGGER) $(TKTEST) "$(ROOT:\=/)/tests/all.tcl" $(TESTFLAGS) | $(CAT32) test-ttk: setup $(TKTEST) $(TKLIB) $(CAT32) @set TCL_LIBRARY=$(TCL_LIBRARY:\=/) @@ -585,11 +572,7 @@ test-ttk: setup $(TKTEST) $(TKLIB) $(CAT32) !else @set PATH=$(_TCLDIR)\win\$(BUILDDIRTOP);$(PATH) !endif -!if "$(OS)" == "Windows_NT" || "$(MSVCDIR)" == "IDE" - $(DEBUGGER) $(TKTEST) "$(ROOT)/tests/ttk/all.tcl" $(TESTFLAGS) | $(CAT32) -!else - $(DEBUGGER) $(TKTEST) "$(ROOT)/tests/ttk/all.tcl" $(TESTFLAGS) | $(CAT32) -!endif + $(DEBUGGER) $(TKTEST) "$(ROOT:\=/)/tests/ttk/all.tcl" $(TESTFLAGS) | $(CAT32) runtest: setup $(TKTEST) $(TKLIB) $(CAT32) @set TCL_LIBRARY=$(TCL_LIBRARY:\=/) @@ -611,7 +594,7 @@ rundemo: setup $(TKTEST) $(TKLIB) $(CAT32) !else @set PATH=$(_TCLDIR)\win\$(BUILDDIRTOP);$(PATH) !endif - $(TKTEST) $(ROOT)\library\demos\widget + $(TKTEST) $(ROOT:\=/)\library\demos\widget shell: setup $(WISH) @set TCL_LIBRARY=$(TCL_LIBRARY:\=/) @@ -626,6 +609,17 @@ shell: setup $(WISH) console show << +dbgshell: setup $(WISH) + @set TCL_LIBRARY=$(TCL_LIBRARY:\=/) + @set TK_LIBRARY=$(TK_LIBRARY:\=/) + @set TCLLIBPATH= +!if $(TCLINSTALL) + @set PATH=$(_TCLDIR)\bin;$(PATH) +!else + @set PATH=$(_TCLDIR)\win\$(BUILDDIRTOP);$(PATH) +!endif + windbg $(WISH) + setup: @if not exist $(OUT_DIR)\nul mkdir $(OUT_DIR) @if not exist $(TMP_DIR)\nul mkdir $(TMP_DIR) @@ -673,9 +667,8 @@ $(CAT32): $(_TCLDIR)\win\cat.c $(link32) $(conlflags) -out:$@ -stack:16384 $(TMP_DIR)\cat.obj $(baselibs) $(_VC_MANIFEST_EMBED_EXE) - #--------------------------------------------------------------------- -# Regenerate the stubs files. +# Regenerate the stubs files. [Development use only] #--------------------------------------------------------------------- genstubs: @@ -689,9 +682,49 @@ genstubs: #--------------------------------------------------------------------- -# Regenerate the windows help files. +# Build the Windows HTML help file. #--------------------------------------------------------------------- +# NOTE: you can define HHC on the command-line to override this +!ifndef HHC +HHC=""%ProgramFiles%\HTML Help Workshop\hhc.exe"" +!endif +HTMLDIR=$(ROOT)\html +HTMLBASE=TclTk$(VERSION) +HHPFILE=$(HTMLDIR)\$(HTMLBASE).hhp +CHMFILE=$(HTMLDIR)\$(HTMLBASE).chm + +htmlhelp: chmsetup $(CHMFILE) + +$(CHMFILE): $(DOCDIR)\* + @$(TCLSH) $(TOOLSDIR)\tcltk-man2html.tcl + @echo Compiling HTML help project + @$(HHC) <<$(HHPFILE) >NUL +[OPTIONS] +Compatibility=1.1 or later +Compiled file=$(HTMLBASE).chm +Display compile progress=no +Error log file=$(HTMLBASE).log +Language=0x409 English (United States) +Title=Tcl/Tk $(DOT_VERSION) Help +[FILES] +contents.htm +docs.css +Keywords +TclCmd +TclLib +TkCmd +TkLib +UserCmd +<< + +chmsetup: + @if not exist $(HTMLDIR)\nul mkdir $(HTMLDIR) + +#------------------------------------------------------------------------- +# Build the old-style Windows .hlp file +#------------------------------------------------------------------------- + HLPBASE = $(PROJECT)$(TK_VERSION) HELPFILE = $(OUT_DIR)\$(HLPBASE).hlp HELPCNT = $(OUT_DIR)\$(HLPBASE).cnt @@ -740,8 +773,8 @@ CreateButton(3, "Wiki", ExecFile("http://wiki.tcl.tk")) CreateButton(4, "FAQ", ExecFile("http://www.purl.org/NET/Tcl-FAQ/")) << cd $(MAKEDIR) - $(CPY) "$(DOCTMP_DIR)\$(@B).hlp" "$(OUT_DIR)" - $(CPY) "$(DOCTMP_DIR)\$(@B).cnt" "$(OUT_DIR)" + @$(CPY) "$(DOCTMP_DIR)\$(@B).hlp" "$(OUT_DIR)" + @$(CPY) "$(DOCTMP_DIR)\$(@B).cnt" "$(OUT_DIR)" $(MAN2TCL): $(TCLTOOLSDIR)\$$(@B).c $(cc32) $(TK_CFLAGS) -Fo$(@D)\ $(TCLTOOLSDIR)\$(@B).c @@ -818,7 +851,7 @@ $(TMP_DIR)\tkStubLib.obj : $(GENERICDIR)\tkStubLib.c $(TMP_DIR)\wish.exe.manifest: $(WINDIR)\wish.exe.manifest.in @nmakehlp -s << $** >$@ @MACHINE@ $(MACHINE:IX86=X86) -@TK_WIN_VERSION@ $(TK_MAJOR_VERSION).$(TK_MINOR_VERSION).0.0 +@TK_WIN_VERSION@ $(TK_DOTVERSION).0.0 << #--------------------------------------------------------------------- @@ -834,7 +867,7 @@ depend: @echo Build tclsh first! !else set TCL_LIBRARY=$(TCL_LIBRARY) - $(TCLSH) $(TCLTOOLSDIR)\mkdepend.tcl -vc32 -out:"$(OUT_DIR)\depend.mk" \ + $(TCLSH) $(TCLTOOLSDIR:\=/)/mkdepend.tcl -vc32 -out:"$(OUT_DIR)\depend.mk" \ -passthru:"-DBUILD_tk $(TK_INCLUDES)" $(GENERICDIR),$$(GENERICDIR) \ $(WINDIR),$$(WINDIR) $(TTKDIR),$$(TTKDIR) $(XLIBDIR),$$(XLIBDIR) \ $(BITMAPDIR),$$(BITMAPDIR) @<< @@ -861,11 +894,8 @@ $(TMP_DIR)\tk.res: \ ### add a spacer in the output !message - #--------------------------------------------------------------------- -# Implicit rules. A limitation exists with nmake that requires that -# source directory can not contain spaces in the path. This an -# absolute. +# Implicit rules #--------------------------------------------------------------------- {$(XLIBDIR)}.c{$(TMP_DIR)}.obj:: @@ -922,8 +952,13 @@ install-binaries: !if !$(STATIC_BUILD) @echo creating package index @type << > $(OUT_DIR)\pkgIndex.tcl -if {[package vcompare [package provide Tcl] $(TCL_PATCH_LEVEL)] != 0} { return } -package ifneeded Tk $(TK_PATCH_LEVEL) [list load [file join $$dir .. .. bin $(TKLIBNAME)] Tk] +if {[catch {package present Tcl $(TCL_PATCH_LEVEL)}]} { return } +if {($$::tcl_platform(platform) eq "unix") && ([info exists ::env(DISPLAY)] + || ([info exists ::argv] && ("-display" in $$::argv)))} { + package ifneeded Tk $(TK_PATCH_LEVEL) [list load [file join $$dir .. .. bin libtk$(TK_DOTVERSION).dll] Tk] +} else { + package ifneeded Tk $(TK_PATCH_LEVEL) [list load [file join $$dir .. .. bin $(TKLIBNAME)] Tk] +} << @$(CPY) $(OUT_DIR)\pkgIndex.tcl "$(SCRIPT_INSTALL_DIR)\" !endif @@ -949,6 +984,8 @@ install-libraries: @echo installing language files @$(CPY) "$(ROOT)\library\msgs\*" "$(SCRIPT_INSTALL_DIR)\msgs\" +#" + #--------------------------------------------------------------------- # Clean up #--------------------------------------------------------------------- diff --git a/win/nmakehlp.c b/win/nmakehlp.c index 2868857..d0edcf0 100644 --- a/win/nmakehlp.c +++ b/win/nmakehlp.c @@ -47,7 +47,7 @@ static int CheckForLinkerFeature(const char *option); static int IsIn(const char *string, const char *substring); static int SubstituteFile(const char *substs, const char *filename); static int QualifyPath(const char *path); -static const char *GetVersionFromFile(const char *filename, const char *match); +static const char *GetVersionFromFile(const char *filename, const char *match, int numdots); static DWORD WINAPI ReadFromPipe(LPVOID args); /* globals */ @@ -153,7 +153,7 @@ main( &dwWritten, NULL); return 0; } - printf("%s\n", GetVersionFromFile(argv[2], argv[3])); + printf("%s\n", GetVersionFromFile(argv[2], argv[3], *(argv[1]+2) - '0')); return 0; case 'Q': if (argc != 3) { @@ -479,7 +479,8 @@ IsIn( static const char * GetVersionFromFile( const char *filename, - const char *match) + const char *match, + int numdots) { size_t cbBuffer = 100; static char szBuffer[100]; @@ -509,7 +510,8 @@ GetVersionFromFile( */ q = p; - while (*q && (isalnum(*q) || *q == '.')) { + while (*q && (strchr("0123456789.ab", *q)) && ((!strchr(".ab", *q) + && (!strchr("ab", q[-1])) || --numdots))) { ++q; } diff --git a/win/rules.vc b/win/rules.vc index f09e2ea..adc3165 100644 --- a/win/rules.vc +++ b/win/rules.vc @@ -218,7 +218,7 @@ DEBUG = 0 SYMBOLS = 0 PROFILE = 0 PGO = 0 -MSVCRT = 0 +MSVCRT = 1 LOIMPACT = 0 TCL_USE_STATIC_PACKAGES = 0 USE_THREAD_ALLOC = 1 @@ -234,9 +234,13 @@ STATIC_BUILD = 0 !message *** Doing msvcrt MSVCRT = 1 !else +!if !$(STATIC_BUILD) +MSVCRT = 1 +!else MSVCRT = 0 !endif -!if [nmakehlp -f $(OPTS) "staticpkg"] +!endif +!if [nmakehlp -f $(OPTS) "staticpkg"] && $(STATIC_BUILD) !message *** Doing staticpkg TCL_USE_STATIC_PACKAGES = 1 !else @@ -245,6 +249,7 @@ TCL_USE_STATIC_PACKAGES = 0 !if [nmakehlp -f $(OPTS) "nothreads"] !message *** Compile explicitly for non-threaded tcl TCL_THREADS = 0 +USE_THREAD_ALLOC= 0 !else TCL_THREADS = 1 USE_THREAD_ALLOC= 1 @@ -298,15 +303,6 @@ UNCHECKED = 0 !endif !endif - -!if !$(STATIC_BUILD) -# Make sure we don't build overly fat DLLs. -MSVCRT = 1 -# We shouldn't statically put the extensions inside the shell when dynamic. -TCL_USE_STATIC_PACKAGES = 0 -!endif - - #---------------------------------------------------------- # Figure-out how to name our intermediate and output directories. # We wouldn't want different builds to use the same .obj files @@ -348,10 +344,8 @@ TMP_DIRFULL = .\$(BUILDDIRTOP)\$(PROJECT)_ThreadedDynamicStaticX TMP_DIRFULL = $(TMP_DIRFULL:Static=) SUFX = $(SUFX:s=) EXT = dll -!if $(MSVCRT) TMP_DIRFULL = $(TMP_DIRFULL:X=) SUFX = $(SUFX:x=) -!endif !else TMP_DIRFULL = $(TMP_DIRFULL:Dynamic=) EXT = lib @@ -583,19 +577,16 @@ Failed to find tcl.h. The TCLDIR macro does not appear correct. TCL_VERSION = $(TCL_MAJOR_VERSION)$(TCL_MINOR_VERSION) -!if $(TCL_VERSION) < 81 -TCL_DOES_STUBS = 0 -!else -TCL_DOES_STUBS = 1 -!endif - !if $(TCLINSTALL) TCLSH = "$(_TCLDIR)\bin\tclsh$(TCL_VERSION)$(SUFX).exe" -!if !exist($(TCLSH)) && $(TCL_THREADS) -TCLSH = "$(_TCLDIR)\bin\tclsh$(TCL_VERSION)t$(SUFX).exe" +!if !exist($(TCLSH)) +TCLSH = "$(_TCLDIR)\bin\tclsh$(TCL_VERSION)$(SUFX:x=).exe" !endif TCLSTUBLIB = "$(_TCLDIR)\lib\tclstub$(TCL_VERSION).lib" TCLIMPLIB = "$(_TCLDIR)\lib\tcl$(TCL_VERSION)$(SUFX).lib" +!if !exist($(TCLIMPLIB)) +TCLIMPLIB = "$(_TCLDIR)\lib\tcl$(TCL_VERSION)$(SUFX:x=).lib" +!endif TCL_LIBRARY = $(_TCLDIR)\lib TCLREGLIB = "$(_TCLDIR)\lib\tclreg13$(SUFX:t=).lib" TCLDDELIB = "$(_TCLDIR)\lib\tcldde14$(SUFX:t=).lib" @@ -604,11 +595,14 @@ TCLTOOLSDIR = \must\have\tcl\sources\to\build\this\target TCL_INCLUDES = -I"$(_TCLDIR)\include" !else TCLSH = "$(_TCLDIR)\win\$(BUILDDIRTOP)\tclsh$(TCL_VERSION)$(SUFX).exe" -!if !exist($(TCLSH)) && $(TCL_THREADS) -TCLSH = "$(_TCLDIR)\win\$(BUILDDIRTOP)\tclsh$(TCL_VERSION)t$(SUFX).exe" +!if !exist($(TCLSH)) +TCLSH = "$(_TCLDIR)\win\$(BUILDDIRTOP)\tclsh$(TCL_VERSION)$(SUFX:x=).exe" !endif TCLSTUBLIB = "$(_TCLDIR)\win\$(BUILDDIRTOP)\tclstub$(TCL_VERSION).lib" TCLIMPLIB = "$(_TCLDIR)\win\$(BUILDDIRTOP)\tcl$(TCL_VERSION)$(SUFX).lib" +!if !exist($(TCLIMPLIB)) +TCLIMPLIB = "$(_TCLDIR)\win\$(BUILDDIRTOP)\tcl$(TCL_VERSION)$(SUFX:x=).lib" +!endif TCL_LIBRARY = $(_TCLDIR)\library TCLREGLIB = "$(_TCLDIR)\win\$(BUILDDIRTOP)\tclreg13$(SUFX:t=).lib" TCLDDELIB = "$(_TCLDIR)\win\$(BUILDDIRTOP)\tcldde14$(SUFX:t=).lib" @@ -681,13 +675,25 @@ TK_VERSION = $(TK_MAJOR_VERSION)$(TK_MINOR_VERSION) !if "$(PROJECT)" != "tk" !if $(TKINSTALL) WISH = "$(_TKDIR)\bin\wish$(TK_VERSION)$(SUFX).exe" +!if !exist($(WISH)) +WISH = "$(_TKDIR)\bin\wish$(TK_VERSION)$(SUFX:x=).exe" +!endif TKSTUBLIB = "$(_TKDIR)\lib\tkstub$(TK_VERSION).lib" TKIMPLIB = "$(_TKDIR)\lib\tk$(TK_VERSION)$(SUFX).lib" +!if !exist($(TKIMPLIB)) +TKIMPLIB = "$(_TKDIR)\win\$(BUILDDIRTOP)\tk$(TCL_VERSION)$(SUFX:x=).lib" +!endif TK_INCLUDES = -I"$(_TKDIR)\include" !else WISH = "$(_TKDIR)\win\$(BUILDDIRTOP)\wish$(TCL_VERSION)$(SUFX).exe" +!if !exist($(WISH)) +WISH = "$(_TKDIR)\win\$(BUILDDIRTOP)\wish$(TCL_VERSION)$(SUFX:x=).exe" +!endif TKSTUBLIB = "$(_TKDIR)\win\$(BUILDDIRTOP)\tkstub$(TCL_VERSION).lib" TKIMPLIB = "$(_TKDIR)\win\$(BUILDDIRTOP)\tk$(TCL_VERSION)$(SUFX).lib" +!if !exist($(TKIMPLIB)) +TKIMPLIB = "$(_TKDIR)\win\$(BUILDDIRTOP)\tk$(TCL_VERSION)$(SUFX:x=).lib" +!endif TK_INCLUDES = -I"$(_TKDIR)\generic" -I"$(_TKDIR)\win" -I"$(_TKDIR)\xlib" !endif !endif |