Updated 2016-04-06 06:23:36 by stevel

Changes in Tcl/Tk 8.5

Please note this page is for reference, not discussions (see Changes in Tcl/Tk)

New Command Line Options  edit

tclsh -encoding encoding
See TIP 137 and 151
wish -encoding encoding

Tcl Changes  edit

New Language Syntax

Changes to Tcl Commands

New Commands

apply
TIP 194
chan
TIPs 208, [1], and 287
dict
TIPs 111, 163, and 212
lassign
TIP 57
lrepeat
TIP 136
lreverse
TIP 272
tcl::mathfunc::abs
TIP 232
tcl::mathfunc::acos
tcl::mathfunc::asin
tcl::mathfunc::atan
tcl::mathfunc::ceil
tcl::mathfunc::cos
tcl::mathfunc::cosh
tcl::mathfunc::double
tcl::mathfunc::exp
tcl::mathfunc::floor
tcl::mathfunc::fmod
tcl::mathfunc::hypot
tcl::mathfunc::int
tcl::mathfunc::log
tcl::mathfunc::log10
tcl::mathfunc::pow
tcl::mathfunc::rand
tcl::mathfunc::round
tcl::mathfunc::sin
tcl::mathfunc::sqrt
tcl::mathfunc::srand
tcl::mathfunc::tan
tcl::mathfunc::tanh
tcl::mathfunc::wide
tcl::mathfunc::bool
TIP 182
tcl::mathfunc::entier
TIP 237
tcl::mathfunc::isqrt
TIP 299
tcl::mathfunc::min
TIP 255
tcl::mathfunc::max
TIP 255
tcl::mathop::!
TIP 174
tcl::mathop::!=
tcl::mathop::%
tcl::mathop::&
tcl::mathop::*
tcl::mathop::+
tcl::mathop::-
tcl::mathop::/
tcl::mathop::<
tcl::mathop::<<
tcl::mathop::<=
tcl::mathop::==
tcl::mathop::>
tcl::mathop::>=
tcl::mathop::>>
tcl::mathop::^
tcl::mathop::eq
tcl::mathop::ne
tcl::mathop::|
tcl::mathop::~
tcl::mathop::**
TIPs 123 and 274
tcl::mathop::in
TIP 201
tcl::mathop::ni
tcl::pkgconfig
TIP 59
tcl::tm::path
TIP 189
tcl::tm::roots
unload
TIP 100

Removed Commands

pkg_compareExtension

New Subcommands

clock add
TIP 173
clock microseconds
TIP 209
clock milliseconds
TIP 209
encoding dirs
TIP 258
info frame
TIP 280
interp bgerror
TIP 221
interp limit
TIP 143
namespace ensemble
TIP 112
namespace path
TIP 229
namespace unknown
TIP 181
namespace upvar
TIP 250
package prefer
TIP 268
string is list
TIP 269
string is wideinteger
TIP 188
string reverse
TIP 272

Expanded Syntax / New Options

binary format tnmrRqQ arg ...
TIP 129
binary scan value tnmrRqQu
TIPs 129 and 275
catch script ?resultVar? ?optionsArray?
TIP90
clock scan string ?-format format? ?-locale name? ?-timezone timeZone?
TIP173
clock format integer ?-locale name? ?-timezone timeZone? ?-format format?
TIP173
New format sequences for format: %Ec %EC %EE %Ex %EX %Ey %EY %J %N %Od %Oe %OH %OI %Ok %Ol %Om %OM %OS %Ou %Ow %Oy %P %Q %z %+
exec ?-ignorestderr? executable ?2>@1?
TIPs 202 and 267
New expr operators **, in, ni
TIPs 123, 274, and 201
New expr functions bool(), entier(), isqrt(), min(), max()
TIPs 182, 237, 299, 255, and 255
file attributes -readonly -creator -type -hidden -rsrclength
TIP 118
format %lld%lli%llo%llx%llX
TIP 237
interp invokehidden interp -namespace namespace
TIP207
lsearch -index -nocase -subindices
TIPs 127 and [2]
lsort -indices -nocase
TIPs 217 and [3]
open filename BINARY
TIP 183
open filename [rwa]b
open {| executable 2>@1}
TIP202
package present package ?requirement ...?
TIP268
package require package ?requirement ...?
TIP268
package vsatisfies requirement ...?
TIP268
return -level level -errorline line
TIP90
scan %lld%lli%llo%llx%llX
TIP237
source -encoding encoding
TIPs 137 and 151
switch -nocase -matchvar varName -indexvar varName
TIPs 75 and 241

New unsupported commands

tcl::unsupported::disassemble

Changes to Tcl variables

New global variables

tcl_platform(pointerSize)
TIP291

Removed global variables

auto_oldpath
tcl_libPath
TIP258

Changed Tcl behavior

clock clicks
returns microseconds since the epoch. TIP 124
expr
script level definition of functions TIP232
expr, incr, [string is double]
Unlimited range of integer values supported; integer calculations no longer overflow. TIP237
incr
auto-initializes unset variable [4]
global varName ( elemName ) raises error
TIP184
lindex,linsert,lrange,lreplace,lset,string index: indices support integer[+-]integer and end[+-]integer syntax
TIP176
list properly quotes the # character
TIP148
namespace import returns imported commands
TIP261
package unknown callback takes {packageName args} arguments where args is list of requirements
TIP268
upvar level varName ( elemName ) varName ( elemName ) raises error
TIP184
Default value of tcl_precision is 0, meaning as many digits as needed for no loss of precision
TIP132
Default package unknown supports Tcl Modules
TIP189
The following commands are script-modifiable ensembles
chan, clock, dict, info, string

Tk Changes edit

Changes to Tk Commands

New Commands

tk::pkgconfig
TIP205
tk::button
TIP248
tk::canvas
tk::checkbutton
tk::entry
tk::frame
tk::label
tk::labelframe
tk::listbox
tk::menubutton
tk::message
tk::panedwindow
tk::radiobutton
tk::scale
tk::scrollbar
tk::spinbox
tk::text
tk::toplevel
ttk::button
ttk::checkbutton
ttk::combobox
ttk::entry
ttk::frame
ttk::labelframe
ttk::label
ttk::menubutton
ttk::notebook
ttk::panedwindow
ttk::progressbar
ttk::radiobutton
ttk::scrollbar
ttk::separator
ttk::sizegrip
ttk::style
ttk::treeview

New Subcommands

grid anchor
TIP 146
menu xposition index
TIP 286
text count
TIP 155
text peer
TIP 169
text replace
TIP 155
text window -blockcursor boolean -tabstyle style
TIP 155, 256
tk inactive
TIP 245
wm iconphoto
TIP 159
wm manage and wm forget
TIP 125

Expanded Syntax / New Options

canvas create line -smooth raw
TIP 168
canvas create line -smooth true
canvas create polygon -smooth raw
canvas create polygon -smooth true
canvas create text -underline index
TIP 260
checkbutton -tristatevalue value -tristateimage image
TIP 110
event generate window event -data string
TIP 165
font actual font char
TIP 300
panedwindow paneconfigure window -hide boolean -stretch value
TIP 177 [5]
radiobutton -tristatevalue value -tristateimage image
TIP 110
text search -all -nolinestop
TIP 113
tk_messageBox -detail detail
TIP 152
wm attributes -alpha fraction -fullscreen -topmost -zoomed, and -notify (on MacOS X)
TIPs 222, 223, 231
-typevariable added to tk_getOpenFile and tk_getSaveFile
TIP 242
grid
adds the grid anchor command and the default anchor is nw (while 8.4 behavior was center)

Changed Tk behavior

checkbutton, radiobutton
new look. TIP 109
grid columnconfigure, grid rowconfigure accept widget names and all
TIP 147
text does smooth scrolling
TIP 155
winfo toplevel supports extension-created windows
TIP 153
Photo out of memory give error, not panic
TIP 116
Enhanced Tk Font Handling (named fonts, etc.)
TIP 145

New Events

<TraverseIn>
TIP 204
<TraverseOut>
TIP 204
<KP_Enter>
on Windows TIP 158

Changes to Bundled Packages edit

New packages

ttk::theme::alt
8.5 TIP 248
ttk::theme::classic
8.5 TIP 248
ttk::theme::default
8.5 TIP 248
ttk::theme::clam
8.5 TIP 248
tile 0.8.0
TIP 248
Ttk 8.5.0
TIP 248
platform 1.0.3
TIP 291
platform::shell 1.1.3
TIP 291
tcl::tommath 8.5.0

Updated packages

dde 1.3.2
TIP 120, 130, and 135
msgcat 1.4.2
TIP 156
opt 0.4.5
registry 1.2.1
tcltest 2.3.0

What other kinds of changes will a developer have to make when moving from Tcl 8.4 to 8.5?
[Migration to 8.5: Big integers]
[Migration to 8.5: Tile]
Tcl/Tk 8.5: New public C routines