1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 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 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 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 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 670 671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 709 710 711 712 713 714 715 716 717 718 719 720 721 722 723 724 725 726 727 728 729 730 731 732 733 734 735 736 737 738 739 740 741 742 743 744 745 746 747 748 749 750 751 752 753 754 755 756 757 758 759 760 761 762 763 764 765 766 767 768 769 770 771 772 773 774 775 776 777 778 779 780 781 782 783 784 785 786 787 788 789 790 791 792 793 794 795 796 797 798 799 800 801 802 803 804 805 806 807 808 809 810 811 812 813 814 815 816 817 818 819 820 821 822 823 824 825 826 827 828 829 830 831 832 833 834 835 836 837 838 839 840 841 842 843 844 845 846 847 848 849 850 851 852 853 854 855 856 857 858 859 860 861 862 863 864 865 866 867 868 869 870 871 872 873 874 875 876 877 878 879 880 881 882 883 884 885 886 887 888 889 890 891 892 893 894 895 896 897 898 899 900 901 902 903 904 905 906 907 908 909 910 911 912 913 914 915 916 917 918 919 920 921 922 923 924 925 926 927 928 929 930 931 932 933 934 935 936 937 938 939 940 941 942 943 944 945 946 947 948 949 950 951 952 953 954 955 956 957 958 959 960 961 962 963 964 965 966 967 968 969 970 971 972 973 974 975 976 977 978 979 980 981 982 983 984 985 986 987 988 989 990 991 992 993 994 995 996 997 998 999 1000 1001 1002 1003 1004 1005 1006 1007 1008
|
--- iwidgets4.0.1/README 2002-09-13 11:39:48.000000000 -0700
+++ iwidgets4.1/README 2012-09-28 07:05:35.000000000 -0700
@@ -1,212 +1,44 @@
-------------------------------------------------------------------------------
- [incr Widgets] - version 4.0.1
-------------------------------------------------------------------------------
-Please send general comments, suggestions, and questions to chad_smith@adc.com
-or itclguy@yahoo.com. Much of this file was written by Mark Ulferts, the
-original [incr Widgets] guy, several years ago when the Iwidgets were first
-released. Chad has assumed responsibilities for updates and maintenance.
-
-==============================================================================
- Copyright (c) 1995 DSC Technologies Corporation
-==============================================================================
- This software is copyrighted by DSC Technologies and private individual
- contributors. The copyright holder is specifically listed in the header
- of each file. The following terms apply to all files associated with the
- software unless explicitly disclaimed in individual files by private
- contributors.
-
- Permission to use, copy, modify, distribute and license this software and
- its documentation for any purpose, and without fee or written agreement
- with DSC, is hereby granted, provided that the above copyright notice
- appears in all copies and that both the copyright notice and warranty
- disclaimer below appear in supporting documentation, and that the names of
- DSC Technologies Corporation or DSC Communications Corporation not be used
- in advertising or publicity pertaining to the software without specific,
- written prior permission.
-
- DSC DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING ALL
- IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, 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. IN NO EVENT SHALL DSC 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 TORTUOUS ACTION, ARISING OUT OF OR IN
- CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
-
- RESTRICTED RIGHTS: Use, duplication or disclosure by the government
- is subject to the restrictions as set forth in subparagraph (c) (1) (ii)
- of the Rights in Technical Data and Computer Software Clause as DFARS
- 252.227-7013 and FAR 52.227-19.
-==============================================================================
-
- OVERVIEW
-------------------------------------------------------------------------------
- - Introduction
- - Distribution
- - Web site
- - Getting started
- - Contributions
- - Acknowledgements
-------------------------------------------------------------------------------
-
-
- Introduction
-------------------------------------------------------------------------------
- [incr Widgets] is an object-oriented mega-widget set which extends
- Tcl/Tk and is based on [incr Tcl] and [incr Tk]. This set of mega-widgets
- delivers many new, general purpose widgets like option menus, comboboxes,
- selection boxes, and various dialogs whose couterparts are found in Motif
- and Windows. Since [incr Widgets] is based on the [incr Tk] extension, the
- Tk framework of configuration options, widget commands, and default bindings
- is maintained. In other words, each [incr Widgets] mega-widget seamlessly
- blends with the standard Tk widgets. They look, act and feel like Tk
- widgets. In addition, all [incr Widgets] mega-widgets are object oriented and
- may themselves be extended, using either inheritance or composition.
-
- [incr Widgets] offers a strong object-oriented foundation which addresses
- the need for a flexible and extensible mega-widget set. Its usage replaces
- common widget combinations with higher level abstractions, simplifying code,
- reducing errors, increasing readability, adding productivity, and promoting
- a singular look-and-feel. The ability to extend [incr Widgets] enables
- developers to create new mega-widgets based on previous work.
-
- In short, [incr Widgets] is a library of reusable mega-widgets that can
- be easily extended using composition or inheritance, allowing quicker
- development of large scale applications. Usage drastically reduces
- development time. New dialogs can be created in hours. Whole applications
- in a few days. Reuse becomes a reality. Many projects are benefitting frm
- the intergration of this mega-widget set into their development strategy.
- [incr Widgets] is an [incr Tcl] and [incr Tk] success story. Good products
- come from good foundations.
-
-
- Distribution
-------------------------------------------------------------------------------
- The [incr Widgets] distribution may be downloaded at SourceForge:
- www.sourceforge.net/projects/incrtcl. The current distribution is
- version 4.0.1.
-
-
- Web site
-------------------------------------------------------------------------------
- For the most current news regarding [incr Widgets] please consult the web
- site - http://incrtcl.sourceforge.net/iwidgets. Many thanks to Brett Schwarz
- who has done an incredible job overhauling this site. Take a look!
-
-
- Getting started
-------------------------------------------------------------------------------
- The "doc" directory contains man pages and a technical paper. The man
- pages are installed under the man directory off your --prefix, and as of
- version 4.0.1 are prepended with the text "iwidgets_" to easily differentiate
- [incr Widgets] man pages from those of other extensions.
-
- doc/iwidgets.ps ... Updated paper presented at Tcl Workshop 95.
-
- doc/*.n ........... Man pages
-
- The "demos" directory contains demo scripts for each mega-widget as
- well as html versions of all the [incr Widgets] man pages. The
- demos are also installed under the lib directory off your --prefix.
-
- demos/catalog ..... Comprehensive demo package which illustrates
- [incr Widgets] usage additionally displaying the
- source.
-
- demos/html ..... HTML version of the [incr Widgets] man pages.
-
- The "tests" directory contains a set of test scripts for [incr Widgets].
- They also make for a great demo of the flexiblity of the mega-widgets.
-
-
- Installation
-------------------------------------------------------------------------------
- NOTE: Having the itcl distribution is a prerequsite to using iwidgets.
- Thus, if you don't have itcl you need to visit Source Forge to download
- and install it first. Once you have downloaded and installed [incr Tcl]
- and [incr Tk], you can proceed with [incr Widgets] installation as follows:
-
- 1) Copy the iwidgets4.0.1.tar.gz file to your toplevel [incr Tcl]
- directory. For example, if you have the itcl3.2.1 distribution in
- a directory named /usr/local/tcl/itcl3.2.1, then you should copy
- the iwidgets file to this directory.
-
- Note, if you don't copy the iwidgets archive to this directory,
- then you will need to specify the --with-itcl flag when you run
- the configure script.
-
- 2) Untar/unzip the archive:
-
- gunzip -c iwidgets4.0.1.tar.gz |tar xvf -
-
- 3) Run the configuration script:
-
- cd iwidgets4.0.0
- ./configure
-
- By default, the configuration script will set things up to be
- installed in "/usr/local". You can change this by specifying a
- different "prefix" in the "configure" command. You'll want to
- use the same value you used for the prefix in the configuration
- of your [incr Tcl/Tk] distribution.
-
- ./configure --prefix=/your/install/path
-
- The "configure" script generates a Makefile from the Makefile.in
- template.
-
- Also, as mentioned eariler, you may need to tell the [incr Widgets]
- where the [incr Tcl] source is located. For example, if your toplevel
- [incr Tcl] directory is located in /opt/tools/tcl/itcl3.2.1 and you
- are building the [incr Widgets] in a directory other than this, then
- you will need to use the following:
-
- ./configure --prefix=/your/install/path \
- --with-itcl=/opt/tools/tcl/itcl3.2.1
-
- 4) Run the test suite:
-
- make test
-
- 7) Install the [incr Widgets] man pages, demos, and script files.
-
- make install
-
-
- Acknowledgements
-------------------------------------------------------------------------------
- Thanks to Brett Schwarz for a ton of work done on the new [incr Widgets]
- web site, http://incrtcl.sourceforge.net/iwidgets.
-
- Thanks to the original develment team, comprised of Mark Ulferts, Sue
- Yockey, Bret Schuhmacher, Alfredo Jahn, John Sigler, and Bill Scott. Also
- thanks to Mark Harrison for his influence, confidence, and ideas.
-
- Thanks also to the new set of contributors which include John Tucker,
- Mitch Gorman, John Reekie, Alfredo Jahn, Ken Copeland, Tako Schotanus,
- Tony Parent and Michael McLennan
-
- Thanks to Michael McLennan, creator of [incr Tcl] and [incr Tk], for the
- beta copies, training, assistance, and his infectious enthusiasm.
-
- Thanks to DSC Communications for picking up the copyright and supporting
- the public release of this software.
-
- Thanks to John P. Davis for creating the [incr Widgets] "Flaming Toaster"
- logo which can be seen at http://www.tcltk.com/iwidgets
-
- Thanks to WebNet Technologies for their assistance is designing the [incr
- Widgets] web site, as well as hosting it.
-
- Special thanks to my wife Karen for supporting this effort and to our two
- girls, Katelyn and Bailey, who occasionally shared the PC with me. Also
- thanks to my Discman and its relentless power supply as well as my rock
- and roll CD collection. No music, no software.
-
---
- ____________________________________________________________________________
- _/_/ _/_/ _/ _/ _/ Mark L. Ulferts
- _/ _/ _/ _/ _/ _/ _/ ulferts@swbell.net
- _/ _/_/ _/ _/ _/ _/ mulferts@austin.dsccc.com
- _/ _/ _/ _/ _/_/_/ _/ _/_/_/_/ _/ DSC Communications Corp, Austin Texas
+iwidgets 4.1 -- iwidgets for itk4
+=================================
+
+Slightly modified iwidgets implementation for itk4.
+For changes see the iwidgets.patch file.
+
+Sources
+-------
+
+The itk repository is hosted at:
+ http://chiselapp.com/user/rene/repository/itk/
+A slightly modified iwidgets (see iwidgets.patch) is hosted at:
+ http://chiselapp.com/user/rene/repository/iwidgets/
+
+Ready to run binaries (*-itk) can be found at:
+ https://sourceforge.net/projects/kbskit/files/itk/
+
+To load itk call:
+ package require itk 4.0
+and to load itk and iwidgets call:
+ package require iwidgets 4.1
+
+Install
+-------
+
+Copy the library directory as iwidgets4.1 in your tcl library path.
+ cp -r library <your-install-path>/iwidgets4.1
+
+Documentation
+-------------
+
+Please refer to the original documantation at
+ http://incrtcl.sourceforge.net/iwidgets/
+
+License & support
+-----------------
+
+This work is under BSD license (see file 'license.terms')
+
+Acknowledgements
+----------------
+
+This work is based on the original "iwidgets" work at
+ http://incrtcl.sourceforge.net/iwidgets/
--- iwidgets4.0.1/license.terms 1998-07-27 11:50:16.000000000 -0700
+++ iwidgets4.1/license.terms 2012-09-28 07:05:34.000000000 -0700
@@ -1,3 +1,7 @@
+This software is copyrighted by Rene Zaumseil (the maintainer).
+The following terms apply to all files associated with the software
+unless explicitly disclaimed in individual files.
+
This software is copyrighted by DSC Technologies and private individual
contributors. The copyright holder is specifically listed in the header
of each file. The following terms apply to all files associated with the
diff -Naur '--exclude=pkgIndex.tcl' iwidgets4.0.1/generic/calendar.itk iwidgets4.1/library/calendar.itk
--- iwidgets4.0.1/generic/calendar.itk 2002-09-05 12:33:06.000000000 -0700
+++ iwidgets4.1/library/calendar.itk 2012-09-28 07:05:35.000000000 -0700
@@ -20,7 +20,7 @@
# mega-widget and the command and option interface was expanded to make
# it even more configurable, but the underlying logic is the same.
#
-# @(#) $Id: calendar.itk,v 1.7 2002/09/05 19:33:06 smithc Exp $
+# @(#) $Id: calendar.itk,v 1.9 2007/05/24 22:41:02 hobbs Exp $
# ----------------------------------------------------------------------
# Copyright (c) 1997 DSC Technologies Corporation
# ======================================================================
@@ -614,11 +614,11 @@
if {$date_ == $now_} {
$canvas_ itemconfigure $item \
-font $itk_option(-currentdatefont) \
- -tags [list all-page date text now]
+ -tags [list all-page date $date_-date text now]
} else {
$canvas_ itemconfigure $item \
-font $itk_option(-datefont) \
- -tags [list all-page date text]
+ -tags [list all-page date $date_-date text]
}
}
@@ -789,6 +789,9 @@
$itk_component(page) bind $date-sensor <ButtonPress-1> \
[itcl::code $this _selectEvent $date]
+
+ $itk_component(page) bind $date-date <ButtonPress-1> \
+ [itcl::code $this _selectEvent $date]
}
#
@@ -859,10 +862,15 @@
set month [clock format $time_ -format "%m"]
set year [clock format $time_ -format "%Y"]
- foreach lastday {31 30 29 28} {
- if {[catch {clock scan "$month/$lastday/$year"}] == 0} {
- break
- }
+ if {[info tclversion] >= 8.5} {
+ set startOfMonth [clock scan "$year-$month-01" -format %Y-%m-%d]
+ set lastday [clock format [clock add $startOfMonth 1 month -1 day] -format %d]
+ } else {
+ foreach lastday {31 30 29 28} {
+ if {[catch {clock scan "$month/$lastday/$year"}] == 0} {
+ break
+ }
+ }
}
set seconds [clock scan "$month/1/$year"]
set firstday [_adjustday [clock format $seconds -format %w]]
diff -Naur '--exclude=pkgIndex.tcl' iwidgets4.0.1/generic/combobox.itk iwidgets4.1/library/combobox.itk
--- iwidgets4.0.1/generic/combobox.itk 2002-09-08 23:43:55.000000000 -0700
+++ iwidgets4.1/library/combobox.itk 2012-09-28 07:05:35.000000000 -0700
@@ -282,7 +282,7 @@
}
}
0 - false - no - off {
- $itk_component(entry) configure -state disabled
+ $itk_component(entry) configure -state readonly
}
default {
error "bad editable option \"$itk_option(-editable)\":\
@@ -355,7 +355,7 @@
$itk_component(entry) configure -state normal
}
0 - false - no - off {
- $itk_component(entry) configure -state disabled
+ $itk_component(entry) configure -state readonly
}
}
}
@@ -521,7 +521,8 @@
} else {
if {$itk_option(-state) == "normal"} {
eval iwidgets::Entryfield::insert $index $args
- [itcl::code $this _lookup ""]
+ #RZ [itcl::code $this _lookup ""]
+ eval [itcl::code $this _lookup ""]
}
}
}
@@ -788,7 +789,7 @@
set rtrn [delete $first $last]
switch -- $itk_option(-editable) {
0 - false - no - off {
- $itk_component(entry) configure -state disabled
+ $itk_component(entry) configure -state readonly
}
}
return $rtrn
@@ -1067,7 +1068,7 @@
$itk_component(entry) insert 0 $item
switch -- $itk_option(-editable) {
0 - false - no - off {
- $itk_component(entry) configure -state disabled
+ $itk_component(entry) configure -state readonly
}
}
}
@@ -1134,7 +1135,7 @@
$itk_component(entry) configure -state normal
}
0 - false - no - off {
- $itk_component(entry) configure -state disabled
+ $itk_component(entry) configure -state readonly
}
}
@@ -1441,3 +1442,5 @@
set _inlookup 0
return
}
+
+
diff -Naur '--exclude=pkgIndex.tcl' iwidgets4.0.1/generic/dateentry.itk iwidgets4.1/library/dateentry.itk
--- iwidgets4.0.1/generic/dateentry.itk 2002-09-05 12:33:58.000000000 -0700
+++ iwidgets4.1/library/dateentry.itk 2012-09-28 07:05:35.000000000 -0700
@@ -8,7 +8,7 @@
# ----------------------------------------------------------------------
# AUTHOR: Mark L. Ulferts E-mail: mulferts@austin.dsccc.com
#
-# @(#) $Id: dateentry.itk,v 1.6 2002/09/05 19:33:58 smithc Exp $
+# @(#) $Id: dateentry.itk,v 1.7 2003/01/30 20:56:05 smithc Exp $
# ----------------------------------------------------------------------
# Copyright (c) 1997 DSC Technologies Corporation
# ======================================================================
@@ -203,6 +203,8 @@
# image displayed in the icon button.
# ------------------------------------------------------------------
itcl::body iwidgets::Dateentry::_getDefaultIcon {} {
+#RZ
+ if {$_defaultIcon ne {}} {return $_defaultIcon}
if {[lsearch [image types] pixmap] != -1} {
set _defaultIcon [image create pixmap -data {
/* XPM */
@@ -260,9 +262,9 @@
# Since this image will only need to be created once, we redefine
# this method to just return the image name for subsequent calls.
#
- itcl::body ::iwidgets::Dateentry::_getDefaultIcon {} {
- return $_defaultIcon
- }
+#RZ itcl::body ::iwidgets::Dateentry::_getDefaultIcon {} {
+#RZ return $_defaultIcon
+#RZ }
return $_defaultIcon
}
@@ -364,9 +366,9 @@
# Perform either a local or global grab based on the -grab option.
#
if {$itk_option(-grab) == "local"} {
- grab $itk_component(popup)
+ ::grab $itk_component(popup)
} else {
- grab -global $itk_component(popup)
+ ::grab -global $itk_component(popup)
}
#
@@ -417,7 +419,7 @@
# to the icon button that engages the popup action.
# ------------------------------------------------------------------
itcl::body iwidgets::Dateentry::_releaseGrab {} {
- grab release $itk_component(popup)
+ ::grab release $itk_component(popup)
$itk_component(iconbutton) configure -relief raised
destroy $itk_component(popup)
bind $itk_component(iconbutton) <Button-1> [itcl::code $this _popup]
diff -Naur '--exclude=pkgIndex.tcl' iwidgets4.0.1/generic/datefield.itk iwidgets4.1/library/datefield.itk
--- iwidgets4.0.1/generic/datefield.itk 2002-02-24 20:45:02.000000000 -0800
+++ iwidgets4.1/library/datefield.itk 2012-09-28 07:05:35.000000000 -0700
@@ -6,7 +6,7 @@
# ----------------------------------------------------------------------
# AUTHOR: Mark L. Ulferts E-mail: mulferts@austin.dsccc.com
#
-# @(#) $Id: datefield.itk,v 1.5 2002/02/25 04:45:02 mgbacke Exp $
+# @(#) $Id: datefield.itk,v 1.6 2007/06/10 19:18:14 hobbs Exp $
# ----------------------------------------------------------------------
# Copyright (c) 1997 DSC Technologies Corporation
# ======================================================================
@@ -457,7 +457,7 @@
# aren't attempting to insert more that 10 characters. If
# so ring the bell and break.
#
- if {[regexp {[0-9]} $char]} {
+ if {[string match {[0-9]} $char]} {
if {[$itk_component(date) index insert] == 10} {
bell
return -code break
@@ -467,7 +467,7 @@
# If we are currently in the month field then we process the
# number entered based on the cursor position. If we are at
# at the first position and our iq is low, then accept any
- # input.
+ # input.
#
if {$_cfield == "month"} {
@@ -475,7 +475,7 @@
if {$itk_option(-iq) == "low"} {
$itk_component(date) delete $month_start_pos
$itk_component(date) insert $month_start_pos $char
- } else {
+ } else {
#
# Otherwise, we're slightly smarter. If the number
# is less than two insert it at position zero. If
@@ -497,7 +497,7 @@
$itk_component(date) delete $month_second_pos
$itk_component(date) insert $month_second_pos 1
$itk_component(date) icursor $month_second_pos
- }
+ }
#
# Finally, if the number is greater than one we'll
@@ -838,8 +838,7 @@
set day_pos 3
set year_pos 8
}
-
-
+
switch $field {
"month" {
$itk_component(date) icursor $month_pos
diff -Naur '--exclude=pkgIndex.tcl' iwidgets4.0.1/generic/disjointlistbox.itk iwidgets4.1/library/disjointlistbox.itk
--- iwidgets4.0.1/generic/disjointlistbox.itk 2002-03-24 23:49:07.000000000 -0800
+++ iwidgets4.1/library/disjointlistbox.itk 2012-09-28 07:05:35.000000000 -0700
@@ -462,7 +462,11 @@
grid configure $itk_component(bbox) \
-in $itk_interior -row 0 -column 1 -columnspan 1 \
-sticky nsew
-
+
+ # Tk8.5: enforce compatibility to previous versions
+ # see Tk-ticket 2062394
+ catch {grid anchor $itk_component(bbox) center}
+
grid configure $itk_component(rhsbutton) \
-in $itk_component(bbox) -row 0 -column 0 -sticky ew
grid configure $itk_component(lhsbutton) \
diff -Naur '--exclude=pkgIndex.tcl' iwidgets4.0.1/generic/entryfield.itk iwidgets4.1/library/entryfield.itk
--- iwidgets4.0.1/generic/entryfield.itk 2001-09-17 12:24:46.000000000 -0700
+++ iwidgets4.1/library/entryfield.itk 2012-09-28 07:05:35.000000000 -0700
@@ -7,7 +7,7 @@
# AUTHOR: Sue Yockey E-mail: yockey@acm.org
# Mark L. Ulferts E-mail: mulferts@austin.dsccc.com
#
-# @(#) $Id: entryfield.itk,v 1.6 2001/09/17 19:24:46 smithc Exp $
+# @(#) $Id: entryfield.itk,v 1.7 2002/09/23 05:10:38 mgbacke Exp $
# ----------------------------------------------------------------------
# Copyright (c) 1995 DSC Technologies Corporation
# ======================================================================
@@ -102,7 +102,7 @@
component hull configure -borderwidth 0
itk_component add entry {
- entry $itk_interior.entry
+ entry $itk_interior.entry
} {
keep -borderwidth -cursor -exportselection \
-foreground -highlightcolor \
@@ -120,7 +120,7 @@
# Create the child site widget.
#
itk_component add -protected efchildsite {
- frame $itk_interior.efchildsite
+ frame $itk_interior.efchildsite
}
set itk_interior $itk_component(efchildsite)
@@ -203,27 +203,27 @@
# to enter into the entryfield.
# ------------------------------------------------------------------
itcl::configbody iwidgets::Entryfield::pasting {
- set oldtags [bindtags $itk_component(entry)]
- if {[lindex $oldtags 0] != "pastetag"} {
- bindtags $itk_component(entry) [linsert $oldtags 0 pastetag]
- }
-
- if ($itk_option(-pasting)) {
- bind pastetag <ButtonRelease-2> [itcl::code $this _checkLength]
- bind pastetag <Control-v> [itcl::code $this _checkLength]
- bind pastetag <Insert> [itcl::code $this _checkLength]
- bind pastetag <KeyPress> {}
- } else {
- bind pastetag <ButtonRelease-2> {break}
- bind pastetag <Control-v> {break}
- bind pastetag <Insert> {break}
- bind pastetag <KeyPress> {
- # Disable function keys > F9.
- if {[regexp {^F[1,2][0-9]+$} "%K"]} {
- break
- }
+ set oldtags [bindtags $itk_component(entry)]
+ if {[lindex $oldtags 0] != "pastetag"} {
+ bindtags $itk_component(entry) [linsert $oldtags 0 pastetag]
+ }
+
+ if {($itk_option(-pasting))} {
+ bind pastetag <ButtonRelease-2> [itcl::code $this _checkLength]
+ bind pastetag <Control-v> [itcl::code $this _checkLength]
+ bind pastetag <Insert> [itcl::code $this _checkLength]
+ bind pastetag <KeyPress> {}
+ } else {
+ bind pastetag <ButtonRelease-2> {break}
+ bind pastetag <Control-v> {break}
+ bind pastetag <Insert> {break}
+ bind pastetag <KeyPress> {
+ # Disable function keys > F9.
+ if {[regexp {^F[1,2][0-9]+$} "%K"]} {
+ break
+ }
+ }
}
- }
}
# ------------------------------------------------------------------
@@ -494,15 +494,22 @@
# A Return key invokes the optionally specified command option.
#
if {$sym == "Return"} {
- uplevel #0 $itk_option(-command)
- return -code break 1
+ if {$itk_option(-command) == ""} {
+ #
+ # Allow <Return> to propagate to parent if the -command option
+ # isn't defined.
+ #
+ return -code continue 1
+ }
+ uplevel #0 $itk_option(-command)
+ return -code break 1
}
#
# Tabs, BackSpace, and Delete are passed on for other bindings.
#
if {($sym == "Tab") || ($sym == "BackSpace") || ($sym == "Delete")} {
- return -code continue 1
+ return -code continue 1
}
#
@@ -523,18 +530,18 @@
set CTRL 4
global tcl_platform
if {$tcl_platform(platform) == "unix"} {
- set ALT 8
+ set ALT 8
} elseif {$tcl_platform(platform) == "windows"} {
- set ALT 16
+ set ALT 16
} else {
- # This is something other than UNIX or WINDOWS. Default to the
- # old behavior (UNIX).
- set ALT 8
+ # This is something other than UNIX or WINDOWS. Default to the
+ # old behavior (UNIX).
+ set ALT 8
}
# Thanks to Rolf Schroedter for the following elegant conditional. This
# masks out all <Ctrl> and <Alt> key combinations.
if {($char == "") || ($state & ($CTRL | $ALT))} {
- return -code continue 1
+ return -code continue 1
}
#
@@ -543,10 +550,10 @@
# invoke the invalid command procedure.
#
if {$itk_option(-fixed) != 0} {
- if {[string length [get]] >= $itk_option(-fixed)} {
- uplevel #0 $itk_option(-invalid)
- return -code break 0
- }
+ if {[string length [get]] >= $itk_option(-fixed)} {
+ uplevel #0 $itk_option(-invalid)
+ return -code break 0
+ }
}
#
@@ -558,20 +565,20 @@
# invalid procedure is called.
#
if {$itk_option(-validate) != {}} {
- set cmd $itk_option(-validate)
+ set cmd $itk_option(-validate)
- regsub -all "%W" "$cmd" $itk_component(hull) cmd
- regsub -all "%P" "$cmd" [list [_peek $char]] cmd
- regsub -all "%S" "$cmd" [list [get]] cmd
- regsub -all "%c" "$cmd" [list $char] cmd
+ regsub -all "%W" "$cmd" $itk_component(hull) cmd
+ regsub -all "%P" "$cmd" [list [_peek $char]] cmd
+ regsub -all "%S" "$cmd" [list [get]] cmd
+ regsub -all "%c" "$cmd" [list $char] cmd
regsub -all {\\} "$cmd" {\\\\} cmd
- set valid [uplevel #0 $cmd]
+ set valid [uplevel #0 $cmd]
- if {($valid == "") || ([regexp 0|false|off|no $valid])} {
- uplevel #0 $itk_option(-invalid)
- return -code break 0
- }
+ if {($valid == "") || ([regexp 0|false|off|no $valid])} {
+ uplevel #0 $itk_option(-invalid)
+ return -code break 0
+ }
}
return -code continue 1
@@ -586,18 +593,18 @@
# specified by the -fixed option.
# ------------------------------------------------------------------
itcl::body iwidgets::Entryfield::_checkLength {} {
- if {$itk_option(-fixed) != 0} {
- if [catch {::selection get -selection CLIPBOARD} pending] {
- # Nothing in the clipboard. Check the primary selection.
- if [catch {::selection get -selection PRIMARY} pending] {
- # Nothing here either. Goodbye.
- return
- }
- }
- set len [expr {[string length $pending] + [string length [get]]}]
- if {$len > $itk_option(-fixed)} {
- uplevel #0 $itk_option(-invalid)
- return -code break 0
+ if {$itk_option(-fixed) != 0} {
+ if {[catch {::selection get -selection CLIPBOARD} pending]} {
+ # Nothing in the clipboard. Check the primary selection.
+ if {[catch {::selection get -selection PRIMARY} pending]} {
+ # Nothing here either. Goodbye.
+ return
+ }
+ }
+ set len [expr {[string length $pending] + [string length [get]]}]
+ if {$len > $itk_option(-fixed)} {
+ uplevel #0 $itk_option(-invalid)
+ return -code break 0
+ }
}
- }
}
diff -Naur '--exclude=pkgIndex.tcl' iwidgets4.0.1/generic/extfileselectionbox.itk iwidgets4.1/library/extfileselectionbox.itk
--- iwidgets4.0.1/generic/extfileselectionbox.itk 2002-03-09 23:34:51.000000000 -0800
+++ iwidgets4.1/library/extfileselectionbox.itk 2012-09-28 07:05:35.000000000 -0700
@@ -11,7 +11,7 @@
# AUTHOR: Mark L. Ulferts EMAIL: mulferts@spd.dsccc.com
# Anthony L. Parent tony.parent@symbios.com
#
-# @(#) $Id: extfileselectionbox.itk,v 1.5 2002/03/10 07:34:51 mgbacke Exp $
+# @(#) $Id: extfileselectionbox.itk,v 1.6 2006/04/11 19:50:38 hobbs Exp $
# ----------------------------------------------------------------------
# Copyright (c) 1997 DSC Technologies Corporation
# ======================================================================
@@ -797,11 +797,11 @@
itcl::body iwidgets::Extfileselectionbox::_setDirList {} {
$itk_component(dirs) clear
+ set currentIndex ""
if {$itk_option(-dirsearchcommand) == {}} {
set cwd "$_pwd"
- set counter 0
- set currentIndex ""
+ set counter 0
foreach i [lsort [glob -nocomplain \
[file join $cwd .*] [file join $cwd *]]] {
if {[file isdirectory $i]} {
diff -Naur '--exclude=pkgIndex.tcl' iwidgets4.0.1/generic/labeledframe.itk iwidgets4.1/library/labeledframe.itk
--- iwidgets4.0.1/generic/labeledframe.itk 2001-08-15 11:32:51.000000000 -0700
+++ iwidgets4.1/library/labeledframe.itk 2012-09-28 07:05:34.000000000 -0700
@@ -155,7 +155,6 @@
set tags [bindtags $itk_hull]
bindtags $itk_hull [linsert $tags 0 itk-delete-$itk_hull]
-
#
# Create the childsite frame window
# _______
@@ -211,7 +210,6 @@
if {$_reposition != ""} {
after cancel $_reposition
}
-
if {[winfo exists $itk_hull]} {
set tags [bindtags $itk_hull]
set i [lsearch $tags itk-delete-$itk_hull]
@@ -289,6 +287,7 @@
# {"-relx" "-rely" <rowconfigure|columnconfigure> <row/column number>}
# -----------------------------------------------------------------------------
itcl::body iwidgets::Labeledframe::_initTable {} {
+ if {![catch {set _LAYOUT_TABLE(nw-relx)}]} return ;#RZ
array set _LAYOUT_TABLE {
nw-relx 0.0 nw-rely 0.0 nw-wrap 0 nw-conf rowconfigure nw-num 0
n-relx 0.5 n-rely 0.0 n-wrap 0 n-conf rowconfigure n-num 0
@@ -313,7 +312,7 @@
#
# NOTE: Be careful to use the "body" command, or the proc will get lost!
#
- itcl::body ::iwidgets::Labeledframe::_initTable {} {}
+ #RZ itcl::body ::iwidgets::Labeledframe::_initTable {} {}
}
# -----------------------------------------------------------------------------
diff -Naur '--exclude=pkgIndex.tcl' iwidgets4.0.1/generic/menubar.itk iwidgets4.1/library/menubar.itk
--- iwidgets4.0.1/generic/menubar.itk 2001-08-15 11:33:13.000000000 -0700
+++ iwidgets4.1/library/menubar.itk 2012-09-28 07:05:34.000000000 -0700
@@ -160,6 +160,7 @@
variable _menuOption ;# The -menu option
variable _helpString ;# The -helpstr optio
+ variable _fixed 0 ;#RZ bug fix
}
}
@@ -198,7 +199,7 @@
set _pathMap(.) $itk_component(menubar)
eval itk_initialize $args
-
+ set _fixed 1 ;#RZ
#
# HACK HACK HACK
# Tk expects some variables to be defined and due to some
@@ -357,7 +358,8 @@
# IF one exists already, delete the old one and create
# a new one
- if { ! [catch {_parsePath .0}] } {
+ #RZ if { ! [catch {_parsePath .0}] }
+ if { $_fixed && ! [catch {_parsePath .0}] } {
delete .0 .last
}
@@ -2071,9 +2073,7 @@
set concatPath ""
foreach seg $segments {
-
set concatPath [_getSymbolicPath $concatPath $seg]
-
if { [catch {set _pathMap($concatPath)} ] } {
error "bad path: \"$path\" does not exist. \"$seg\" not valid"
}
diff -Naur '--exclude=pkgIndex.tcl' iwidgets4.0.1/generic/pushbutton.itk iwidgets4.1/library/pushbutton.itk
--- iwidgets4.0.1/generic/pushbutton.itk 2001-08-17 12:03:44.000000000 -0700
+++ iwidgets4.1/library/pushbutton.itk 2012-09-28 07:05:34.000000000 -0700
@@ -11,7 +11,7 @@
# AUTHOR: Mark L. Ulferts EMAIL: mulferts@austin.dsccc.com
# Bret A. Schuhmacher EMAIL: bas@wn.com
#
-# @(#) $Id: pushbutton.itk,v 1.3 2001/08/17 19:03:44 smithc Exp $
+# @(#) $Id: pushbutton.itk,v 1.4 2007/06/10 19:28:30 hobbs Exp $
# ----------------------------------------------------------------------
# Copyright (c) 1995 DSC Technologies Corporation
# ======================================================================
@@ -100,19 +100,24 @@
itk_option add hull.borderwidth hull.relief
itk_option add hull.highlightcolor
itk_option add hull.highlightbackground
-
- component hull configure \
+
+ if {$::tk_version > 8.3} {
+ # Tk 8.4+ frame -padx -pady options creates inadvertant margin box
+ component hull configure -padx 0 -pady 0 \
-borderwidth [$this cget -borderwidth]
-
+ } else {
+ component hull configure -borderwidth [$this cget -borderwidth]
+ }
+
pack propagate $itk_component(hull) no
itk_component add pushbutton {
button $itk_component(hull).pushbutton \
} {
usual
- keep -underline -wraplength -state -command
+ keep -underline -wraplength -state -command
}
- pack $itk_component(pushbutton) -expand 1 -fill both
+ pack $itk_component(pushbutton) -expand 1 -fill both
#
# Initialize the widget based on the command line options.
diff -Naur '--exclude=pkgIndex.tcl' iwidgets4.0.1/generic/scrolledhtml.itk iwidgets4.1/library/scrolledhtml.itk
--- iwidgets4.0.1/generic/scrolledhtml.itk 2002-02-15 21:11:08.000000000 -0800
+++ iwidgets4.1/library/scrolledhtml.itk 2012-09-28 07:05:34.000000000 -0700
@@ -42,7 +42,7 @@
# ----------------------------------------------------------------------
# AUTHOR: Kris Raney EMAIL: kraney@spd.dsccc.com
#
-# @(#) $Id: scrolledhtml.itk,v 1.7 2002/02/16 05:11:08 mgbacke Exp $
+# @(#) $Id: scrolledhtml.itk,v 1.8 2004/12/02 17:49:18 davygrvy Exp $
# ----------------------------------------------------------------------
# Copyright (c) 1996 DSC Technologies Corporation
# ======================================================================
@@ -139,7 +139,7 @@
itk_option define -alink alink ALink red
itk_option define -linkhighlight alink ALink red
itk_option define -unknownimage unknownimage File {}
- itk_option define -textbackground textBackground Background {}
+ itk_option define -textbackground textBackground Background {#ffffff};#RZ
itk_option define -update update Update 1
itk_option define -debug debug Debug 0
@@ -352,7 +352,8 @@
foreach x $_images {
::image delete $x
}
- if {$_unknownimg != $_defUnknownImg} {
+ #RZ if {$_unknownimg != $_defUnknownImg}
+ if {$_unknownimg != "" && $_unknownimg != $_defUnknownImg} {
::image delete $_unknownimg
}
}
@@ -1418,7 +1419,7 @@
if {![regexp {^[+-].*} $ar(size)]} {
set _pointsndx $ar(size)
} else {
- set _pointsndx [expr {$_basefontsize $ar(size)}]
+ set _pointsndx [expr $_basefontsize $ar(size)]
}
if { $_pointsndx > 6 } {
set _pointsndx 6
diff -Naur '--exclude=pkgIndex.tcl' iwidgets4.0.1/generic/shell.itk iwidgets4.1/library/shell.itk
--- iwidgets4.0.1/generic/shell.itk 2002-02-24 22:43:26.000000000 -0800
+++ iwidgets4.1/library/shell.itk 2012-09-28 07:05:35.000000000 -0700
@@ -8,7 +8,7 @@
# AUTHOR: Mark L. Ulferts EMAIL: mulferts@austin.dsccc.com
# Kris Raney EMAIL: kraney@spd.dsccc.com
#
-# @(#) $Id: shell.itk,v 1.7 2002/02/25 06:43:26 mgbacke Exp $
+# @(#) $Id: shell.itk,v 1.9 2007/06/10 19:35:04 hobbs Exp $
# ----------------------------------------------------------------------
# Copyright (c) 1996 DSC Technologies Corporation
# ======================================================================
@@ -60,7 +60,8 @@
public method deactivate {args}
public method center {{widget {}}}
- private variable _result {} ;# Resultant value for modal activation.
+ protected variable _result {} ;# Resultant value for modal activation.
+
private variable _busied {} ;# List of busied top level widgets.
common grabstack {}
@@ -243,6 +244,17 @@
raise $itk_component(hull)
wm deiconify $itk_component(hull)
tkwait visibility $itk_component(hull)
+ # For some mysterious reason, Tk sometimes returns too late from the
+ # "tkwait visibility", i.e. after the "deactivate" method was invoked,
+ # i.e. after the dialog window already disappeared. This would lead to
+ # an infinite vwait on _wait($this) further on. Trap this case.
+ # See also 2002-03-15 message to the Tcl/Tk newsgroup.
+ # Remark that tests show that if "raise" is given *after* "deiconify"
+ # (see above), "tkwait visibility" always returns duly on time.....
+ if {![winfo ismapped $itk_component(hull)]} {
+ # means "deactivate" went already through the grab-release stuff.
+ return $_result
+ }
# Need to flush the event loop. This line added as a result of
# SF ticket #227885.
diff -Naur '--exclude=pkgIndex.tcl' iwidgets4.0.1/generic/timeentry.itk iwidgets4.1/library/timeentry.itk
--- iwidgets4.0.1/generic/timeentry.itk 2001-08-17 12:05:08.000000000 -0700
+++ iwidgets4.1/library/timeentry.itk 2012-09-28 07:05:34.000000000 -0700
@@ -192,7 +192,8 @@
# image displayed in the icon button.
# ------------------------------------------------------------------
itcl::body iwidgets::Timeentry::_getDefaultIcon {} {
-
+#RZ
+ if {$_defaultIcon ne {}} {return $_defaultIcon}
if {[lsearch [image types] pixmap] != -1} {
set _defaultIcon [image create pixmap -data {
/* XPM */
@@ -249,9 +250,9 @@
# Since this image will only need to be created once, we redefine
# this method to just return the image name for subsequent calls.
#
- itcl::body ::iwidgets::Timeentry::_getDefaultIcon {} {
- return $_defaultIcon
- }
+#RZ itcl::body ::iwidgets::Timeentry::_getDefaultIcon {} {
+#RZ return $_defaultIcon
+#RZ }
return $_defaultIcon
}
diff -Naur '--exclude=pkgIndex.tcl' iwidgets4.0.1/generic/toolbar.itk iwidgets4.1/library/toolbar.itk
--- iwidgets4.0.1/generic/toolbar.itk 2001-08-17 12:05:54.000000000 -0700
+++ iwidgets4.1/library/toolbar.itk 2012-09-28 07:05:35.000000000 -0700
@@ -684,7 +684,8 @@
foreach optionSet [$itk_component($name) configure] {
set option [lindex $optionSet 0]
if { [lsearch $_optionList $option] != -1 } {
- itk_option add $name.$option
+ #RZ itk_option add $name.$option
+ itk_option add $name.[string range $option 1 end]
}
}
diff -Naur iwidgets4.0.1/tests/all.tcl iwidgets4.1/tests/all.tcl
--- iwidgets4.0.1/tests/all.tcl 2000-07-05 23:43:38.000000000 -0700
+++ iwidgets4.1/tests/all.tcl 2012-09-28 07:05:35.000000000 -0700
@@ -80,6 +80,7 @@
# Print results to ::tcltest::outputChannel.
puts $::tcltest::outputChannel $msg
}
+}
# Now concatenate the temporary log file to
# ::tcltest::outputChannel
@@ -105,8 +106,6 @@
} msg]} {
puts $::tcltest::outputChannel $msg
}
-}
-
set numFailures [llength $::tcltest::failFiles]
# cleanup
|