# ticket

tkt_uuid: 220110ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 99. Other
priority: 1 Zero
foundin: obsolete: 8.0p2
resolution: Invalid
title: many tests fail on IRIX 6.5 in Tk 8.0p2
comment:
  OriginalBugID: 659 Bug
  Version: 8.0p2
  SubmitDate: '1998-05-25'
  LastModified: '2000-04-03'
  Severity: MED
  Status: Closed
  Submitter: hershey
  ChangedBy: ericm
  RelatedBugIDs: 1770
  OS: IRIX
  OSVersion: 6.5
  Machine: NA
  FixedInVersion: NA
  ClosedDate: '2000-04-03'


  When testing Tk8.0p2, some of the tests fail (see attached file).
  I am unable to figure out why.
  Are these known failures (to be fixed), something new
  nobody has seen before or have I done simply something
  wrong?
  For the record: IRIX 6.5, CFLAGS="-n32 -mips3", SGI Octane

  Zdenek Sekera          email: zs@cray.com
  ----
          LD_LIBRARY_PATH=`pwd`:/usr/people/zs/src/tcl8.0/unix:;  export LD_LIBRARY_PATH;  TCL_LIBRARY=/usr/people/zs/src/tcl8.0/library; export TCL_LIBRARY;  TK_LIBRARY=./../library; export TK_LIBRARY;  ( echo cd ./../tests\; source all\; exit )  | ./tktest -geometry +0+0
  bell.test
  (will skip non-portable tests)
  Bell should ring now ...
  bgerror.test
  bind.test
  button.test
  canvImg.test
  canvPs.test
  canvRect.test
  canvText.test

  ==== canvText-6.1 ComputeTextBbox procedure
  ==== Contents of test case:

      .c itemconfig test -font $font -text 0
      .c coords test 0 0
      set x {}
      lappend x [.c itemconfig test -anchor n; .c bbox test]
      lappend x [.c itemconfig test -anchor nw; .c bbox test]
      lappend x [.c itemconfig test -anchor w; .c bbox test]
      lappend x [.c itemconfig test -anchor sw; .c bbox test]
      lappend x [.c itemconfig test -anchor s; .c bbox test]
      lappend x [.c itemconfig test -anchor se; .c bbox test]
      lappend x [.c itemconfig test -anchor e; .c bbox test]
      lappend x [.c itemconfig test -anchor ne; .c bbox test]
      lappend x [.c itemconfig test -anchor center; .c bbox test]

  ==== Result was:
  {-8 0 8 31} {-1 0 15 31} {-1 -15 15 16} {-1 -31 15 0} {-8 -31 8 0} {-15 -31 1 0} {-15 -15 1 16} {-15 0 1 31} {-8 -15 8 16}
  ---- Result should have been:
  {-8 0 8 31} {-1 0 15 31} {-1 -16 15 15} {-1 -31 15 0} {-8 -31 8 0} {-15 -31 1 0} {-15 -16 1 15} {-15 0 1 31} {-8 -16 8 15}
  ---- canvText-6.1 FAILED
  canvWind.test
  canvas.test
  clipboard.test
  clrpick.test
  cmds.test
  color.test
  entry.test
  event.test
  filebox.test
  focus.test

  ==== focus-5.1 ChangeXFocus procedure, don't take focus unless have it
  ==== Contents of test case:

      focusSetup
      focus -force .t
      update
      set result [focus]
      send [dobg {tk appname}] {focus -force .; update}
      lappend result [focus]
      focus .t.b2
      update
      lappend result [focus]

  ==== Test generated error:
  X server insecure (must use xauth-style authorization); command ignored
  focusTcl.test
  font.test
  frame.test
  geometry.test
  grid.test
  id.test
  image.test
  imgBmap.test
  imgPPM.test
  imgPhoto.test
  listbox.test
  macEmbed.test
  macFont.test
  macMenu.test
  macWinMenu.test
  macscrollbar.test
  main.test
  menu.test
  menuDraw.test
  menubut.test
  msgbox.test
  oldpack.test
  option.test
  pack.test
  place.test
  raise.test
  safe.test
  scale.test

  ==== scale-7.1 ComputeScaleGeometry procedure
  ==== Contents of test case:

      catch {destroy .s}
      scale .s -from 0 -to 10 -label "Short" -orient vertical -length 5i
      pack .s
      update
      list [winfo reqwidth .s] [winfo reqheight .s]

  ==== Result was:
  88 472
  ---- Result should have been:
  88 458
  ---- scale-7.1 FAILED

  ==== scale-7.5 ComputeScaleGeometry procedure
  ==== Contents of test case:

      catch {destroy .s}
      scale .s -from 0 -to 10 -label "Short" -orient horizontal -length 5i
      pack .s
      update
      list [winfo reqwidth .s] [winfo reqheight .s]

  ==== Result was:
  472 61
  ---- Result should have been:
  458 61
  ---- scale-7.5 FAILED
  scrollbar.test
  select.test

  ==== select-10.4 ConvertSelection procedure
  ==== Contents of test case:

      setup
      setupbg
      set selValue $longValue
      set selInfo ""
      selection handle .f1 {errIncrHandler STRING}
      set result ""
      set pass 0
      lappend result [dobg {selection get}]
      cleanupbg
      lappend result $selInfo

  ==== Result was:
  {selection owner didn't respond} {STRING 0 4000 STRING 4000 4000 STRING 8000 4000 STRING 12000 4000 STRING 16000 4000 STRING 0 4000}
  ---- Result should have been:
  {selection owner didn't respond} {STRING 0 4000 STRING 4000 4000 STRING 8000 4000 STRING 12000 4000 STRING 16000 4000 STRING 0 4000 STRING 4000 4000}
  ---- select-10.4 FAILED
  send.test
  Your X server is insecure, so "send" can't be used; skipping "send" tests.
  text.test
  textBTree.test
  textDisp.test
  textImage.test
  textIndex.test

  ==== textIndex-5.1 TkTextGetIndex, "@"
  ==== Contents of test case:

      .t index @12,9

  ==== Result was:
  1.0
  ---- Result should have been:
  1.1
  ---- textIndex-5.1 FAILED
  textMark.test
  textTag.test
  textWind.test
  tk.test
  unixButton.test
  unixEmbed.test

  ==== unixEmbed-3.1 ContainerEventProc procedure, detect creation
  ==== Contents of test case:

      foreach w [winfo child .] {
          catch {destroy $w}
      }
      frame .f1 -container 1 -width 200 -height 50
      pack .f1
      dobg "set w1 [winfo id .f1]"
      set x [testembed]
      dobg {
          eval destroy [winfo child .]
          toplevel .t1 -use $w1
          wm withdraw .t1
      }
      list $x [testembed]

  ==== Result was:
  {{XXX .f1 {} {}}} {{XXX .f1 {} {}}}
  ---- Result should have been:
  {{XXX .f1 {} {}}} {{XXX .f1 XXX {}}}
  ---- unixEmbed-3.1 FAILED
  unixFont.test

  ==== unixfont-1.2 TkpGetNativeFont procedure: native
  ==== Contents of test case:

      font measure fixed 0

  ==== Result was:
  12
  ---- Result should have been:
  6
  ---- unixfont-1.2 FAILED

  ==== unixfont-5.9 Tk_MeasureChars procedure: TK_PARTIAL_OK
  ==== Contents of test case:

      .b.c dchars $t 0 end
      .b.c insert $t 0 "0000"
      .b.c index $t @[expr int($ax*2.5)],1

  ==== Result was:
  4
  ---- Result should have been:
  2
  ---- unixfont-5.9 FAILED

  ==== unixfont-8.3 AllocFont procedure: can't parse info from name
  ==== Contents of test case:

      if [catch {set a [font actual a12biluc]}]==0 {
          string compare $a "-family a12biluc -size 0 -weight normal -slant roman -underline 0 -overstrike 0"
      } else {
          set a 0
      }

  ==== Result was:
  1
  ---- Result should have been:
  0
  ---- unixfont-8.3 FAILED

  ==== unixfont-9.1 GetControlCharSubst procedure: 2 chars subst
  ==== Contents of test case:

      .b.c dchars $t 0 end
      .b.c insert $t 0 "0\a0"
      set x {}
      lappend x [.b.c index $t @[expr $ax*0],0]
      lappend x [.b.c index $t @[expr $ax*1],0]
      lappend x [.b.c index $t @[expr $ax*2],0]
      lappend x [.b.c index $t @[expr $ax*3],0]

  ==== Result was:
  0 1 3 3
  ---- Result should have been:
  0 1 1 2
  ---- unixfont-9.1 FAILED

  ==== unixfont-9.2 GetControlCharSubst procedure: 4 chars subst
  ==== Contents of test case:

      .b.c dchars $t 0 end
      .b.c insert $t 0 "0\1770"
      set x {}
      lappend x [.b.c index $t @[expr $ax*0],0]
      lappend x [.b.c index $t @[expr $ax*1],0]
      lappend x [.b.c index $t @[expr $ax*2],0]
      lappend x [.b.c index $t @[expr $ax*3],0]
      lappend x [.b.c index $t @[expr $ax*4],0]
      lappend x [.b.c index $t @[expr $ax*5],0]

  ==== Result was:
  0 1 1 3 3 3
  ---- Result should have been:
  0 1 1 1 1 2
  ---- unixfont-9.2 FAILED
  unixMenu.test
  unixWm.test

  ==== unixWm-41.2 ConfigureEvent procedure, menubars
  ==== Contents of test case:

      catch {destroy .t}
      toplevel .t -width 300 -height 200 -bd 2 -relief raised
      wm geom .t +0+0
      update
      set x [winfo rootx .t]
      set y [winfo rooty .t]
      frame .t.m -bd 2 -relief raised -height 20
      testmenubar window .t .t.m
      update
      set result {}
      bind .t <Configure> {
          if {"%W" == ".t"} {
              lappend result "%W: %wx%h"
          }
      }
      bind .t.m <Configure> {lappend result "%W: %wx%h"}
      wm geometry .t 200x300
      update
      lappend result [expr [winfo rootx .t.m] - $x]  [expr [winfo rooty .t.m] - $y]  [winfo width .t.m] [winfo height .t.m]  [expr [winfo rootx .t] - $x] [expr [winfo rooty .t] - $y]  [winfo width .t] [winfo height .t]

  ==== Result was:
  {.t.m: 200x20} {.t: 200x300} -8 -32 200 20 -8 -12 200 300
  ---- Result should have been:
  {.t.m: 200x20} {.t: 200x300} 0 0 200 20 0 20 200 300
  ---- unixWm-41.2 FAILED

  ==== unixWm-47.1 WaitRestrictProc procedure
  ==== Contents of test case:

      catch {destroy .t}
      toplevel .t -width 300 -height 200
      frame .t.f -bd 2 -relief raised
      place .t.f -x 20 -y 30 -width 100 -height 20
      wm geometry .t +0+0
      tkwait visibility .t
      set result {}
      bind .t.f <Configure> {lappend result {configure on .t.f}}
      bind .t <Map> {lappend result {map on .t}}
      bind .t <Unmap> {lappend result {unmap on .t}; bind .t <Unmap> {}}
      bind .t <Button> {lappend result {button %b on .t}}
      event generate .t.f <Configure> -when tail
      event generate .t <Configure> -when tail
      event generate .t <Button> -button 3 -when tail
      event generate .t <Map> -when tail
      lappend result iconify
      wm iconify .t
      lappend result done
      update
      set result

  ==== Result was:
  iconify {unmap on .t} done {button 3 on .t} {map on .t}
  ---- Result should have been:
  iconify {unmap on .t} done {configure on .t.f} {button 3 on .t} {map on .t}
  ---- unixWm-47.1 FAILED

  ==== unixWm-50.1 Tk_CoordsToWindow procedure, finding a toplevel, x-coords
  ==== Contents of test case:

      eval destroy [winfo children .]
      toplevel .t -width 300 -height 400 -bg green
      wm geom .t +40+0
      tkwait visibility .t
      toplevel .t2 -width 100 -height 80 -bg red
      wm geom .t2 +140+200
      tkwait visibility .t2
      raise .t2
      set x [winfo rootx .t]
      set y [winfo rooty .t]
      list [winfo containing [expr $x - 30] [expr $y + 250]]  [winfo containing [expr $x - 1] [expr $y + 250]]  [winfo containing $x [expr $y + 250]]  [winfo containing [expr $x + 99] [expr $y + 250]]  [winfo containing [expr $x + 100] [expr $y + 250]]  [winfo containing [expr $x + 199] [expr $y + 250]]  [winfo containing [expr $x + 200] [expr $y + 250]]  [winfo containing [expr $x + 220] [expr $y + 250]]

  ==== Result was:
  {} {} .t {} {} {} {} .t
  ---- Result should have been:
  {} {} .t {} .t2 .t2 {} .t
  ---- unixWm-50.1 FAILED
  util.test
  visual.test
  winButton.test
  winClipboard.test
  winFont.test
  winMenu.test
  winWm.test
  window.test
  winfo.test



  canvTest-6.1 is marked nonPortable in Tk8.1

  focus-5.1 gets skipped if X server is insecure in Tk8.1

  scale-* may be fixed in Tk8.1.  This may depend on the window manager.  It was reported that the previous (fixed in Tk8.1) behavior of some pack tests cause some window managers to later fail in scale tests.

  testIndex-5.1, unixEmbed-3.1, and unixWm-4* are marked nonPortable in Tk8.1

  select-10.4 and unixWm-50.1:  I can't reproduce these failure, and I'm reluctant to mark it nonPortable.  Let's see about this one in Tk8.1+ if it's still a problem.

  --

  These appear to perform much better in recent builds.  When this bug was submitted many of the tests that failed were not marked as non portable, even though they were (depending on such iffy bits as the number of pixels corresponding to one inch on the physical display).

  If you continue to see failures with the new version of Tcl/Tk, please send us an update.

  - eric

  -- 04/03/2000 ericm


tkt_uuid: 220923ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 84. Unix Build
priority: 5 Medium
foundin: obsolete: 8.4a1
resolution: Invalid
title: tk's ./configure --with-tcl opt behavior changed
comment:
  OriginalBugID: 5846 Bug
  Version: 8.4a1
  SubmitDate: '2000-06-07'
  LastModified: 
  Severity: LOW
  Status: UnAssn
  Submitter: techsupp
  OS: Other
  OSVersion: QNX 4.25
  Machine: PII 300


  Name:
  Bruce Edge

  ReproducibleScript:
  With tcl/tk 8.3, I used the same ./configure options for both tcl and tk.
  With 8.4a1 I tried to use:
  ./configure --prefix=/usr/local/tcl8.4a1  --disable-threads --disable-load --disable-shard --enable-gcc --with-tcl=/usr/local/tcl8.4a1  --with-tk=/usr/local/tcl8.4a1

  Tcl built OK, but when running ./configure for tk I got the following error:
   ./configure --prefix=/usr/local/tcl8.4a1  --disable-threads --disable-lo
  od --disable-shard --enable-gcc --with-tcl=/usr/local/tcl8.4a1  --with-tk=/usr/local/tcl8.4a1
  creating cache ./config.cache
  checking for ranlib... ranlib
  checking for gcc... gcc
  checking whether the C compiler (gcc  ) works... yes
  checking whether the C compiler (gcc  ) is a cross-compiler... no
  checking whether we are using GNU C... yes
  checking whether gcc accepts -g... yes
  checking for gcc... (cached) gcc
  checking whether the C compiler (gcc -g -O2 ) works... yes
  checking whether the C compiler (gcc -g -O2 ) is a cross-compiler... no
  checking whether we are using GNU C... (cached) yes
  checking whether gcc accepts -g... (cached) yes
  checking how to run the C preprocessor... gcc -E
  checking for unistd.h... yes
  checking for limits.h... yes
  checking for building with threads... no (default)
  checking if the compiler understands -pipe... yes
  checking for Tcl configuration... configure: error: /usr/local/tcl8.4a1 directory doesn't contain tclConfig.sh

  I had to use
  ./configure --prefix=/usr/local/tcl8.4a1  --disable-threads --disable-load --disable-shard --enable-gcc --with-tcl=/usr/local/tcl8.4a1/lib  --with-tk=/usr/local/tcl8.4a1

  note the addition of /lib on the end of the --with-tcl opt.

  ObservedBehavior:
  I felt that I should not have to specify the ./lib dir under the tcl install path.
  I did not have to do so in prev versions.


tkt_uuid: 1912679fffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 84. Unix Build
priority: 5 Medium
foundin: obsolete: 8.5.1
resolution: Fixed
title: chmod error during tk cvs head install
comment:
  I downloaded the cvs head tar files from activestate's ftp site.

  I built and installed tcl on my sparc solaris 9 system, using sun's c compiler.

  I build tk next. When I did the gmake install, I get

  Installing libtkstub8.5.a to /projects/sprs_lwv/tcl85/lib/
  Making directory 
  usage:  chmod [-fR] <absolute-mode> file ...
          chmod [-fR] <symbolic-mode-list> file ...
  where   <symbolic-mode-list> is a comma-separated list of
          [ugoa]{+|-|=}[rwxXlstugo]

  To try and figure out what is going wrong here, I removed the @ before the if statement. Here's what I see when I run it again:
  Installing libtkstub8.5.a to /projects/sprs_lwv/tcl85/lib/
  if test "" != ""; then \
              XLIB_INCLUDE_INSTALL_DIR="/projects/sprs_lwv/tcl85/include"/X11; fi; \
          for i in "/projects/sprs_lwv/tcl85/include" "${XLIB_INCLUDE_INSTALL_DIR}" \
                  "/projects/sprs_lwv/tcl85/lib/tk8.5" "/projects/sprs_lwv/tcl85/lib/tk8.5"/images \
                  "/projects/sprs_lwv/tcl85/lib/tk8.5"/msgs "/projects/sprs_lwv/tcl85/lib/tk8.5"/ttk; \
              do \
              if [ ! -d "$i" ] ; then \
                  echo "Making directory $i"; \
                  mkdir -p "$i"; \
                  chmod 755 "$i"; \
                  else true; \
                  fi; \
              done;
  Making directory 
  usage:  chmod [-fR] <absolute-mode> file ...
          chmod [-fR] <symbolic-mode-list> file ...
  where   <symbolic-mode-list> is a comma-separated list of
          [ugoa]{+|-|=}[rwxXlstugo]

  I am uncertain why, but the only thing I can figure is that the XLIB_INCLUDE_INSTALL_DIR is ending up null, despite being set...


tkt_uuid: 220314ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 39. Image Basics
priority: 1 Zero
foundin: obsolete: 8.3.1
resolution: Invalid
title: tkimage copy -subsample ... does not work
comment:
  OriginalBugID: 5979 Bug
  Version: 8.3.1
  SubmitDate: '2000-07-06'
  LastModified: '2000-08-21'
  Severity: MED
  Status: Closed
  Submitter: techsupp
  ChangedBy: ericm
  OS: Windows 98
  Machine: P II 500
  ClosedDate: '2000-08-21'


  Name:
  Michael Lukaschek

  ReproducibleScript:
  mZI copy DstImg -subsample $samplex $samplex -to  [expr ([image width mZI]-[image width DstImg]/$samplex)/2]  [expr ([image height mZI]-[image height DstImg]/$samplex)/2]

  ObservedBehavior:
  the result is an image having mixed channels

  maybe this is a conflict with the old 3 band image handling and the new 4-band one

  DesiredBehavior:
  Another command does work on the new tkimage format:
  DstImg copy ZI -zoom $ZIF -from $ZIXS $ZIYS $ZIXE $ZIYE

  Maybe the subsample option is not maintained any longer?



  I am unable to reproduce this problem.  If possible, please send us a copy of the image you are using and the exact values you are using with the -subsample option (that is, the value of the samplex variable in your sample script).  Thanks,

     Eric Melski                            The Other Tcl Guy
     ericm at ajubasolutions.com            Ajuba Solutions

  -- 08/21/2000 ericm


tkt_uuid: 826614ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 85. Win Build
priority: 7 High
foundin: obsolete: 8.4.4
resolution: Fixed
title: tkConfig.sh doesn't set TK_STUB_LIB_SPEC
comment:
  (This is for the ActiveState ActiveTcl 8.4.4.0 release-- 
  don't know if it's a problem with other Windows builds.)

  Anyway, the "tkConfig.sh" file in ActiveTcl 8.4.4.0 sets

  TK_STUB_LIB_SPEC=''
  TK_LIB_SPEC=''

  So TEA-based Tk extensions fail to compile properly 
  unless this file is patched.


tkt_uuid: 1246936fffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 18. [text]
priority: 5 Medium
foundin: obsolete: 8.5a4
resolution: Fixed
title: textDisp-19.15 fails
comment:
  Some change in the style
  cleanup of tkTextDisp.c
  has resulted in a change
  in the whitespace in a
  $::errorInfo value, which
  makes test textDisp-19.15 fail.

  The test does do a useful
  task of checking the
  stack trace format, so this
  ought to be fixed, rather
  than making the test more
  forgiving.


tkt_uuid: 219895ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 05. Canvas Items
priority: 1 Zero
foundin: obsolete: 8.1a2
resolution: Duplicate
title: stipple in Mac vers. 8.0 and 8.1a2
comment:
  OriginalBugID: 610 Bug
  Version: 8.1a2
  SubmitDate: '1998-05-21'
  LastModified: '1999-08-14'
  Severity: LOW
  Status: Closed
  Submitter: hershey
  ChangedBy: hobbs
  RelatedBugIDs: 555 1274
  OS: Macintosh
  OSVersion: NA
  Machine: NA
  FixedDate: '2000-10-31'
  FixedInVersion: NA
  ClosedDate: '1999-08-14'


  Dear Tk Team,

  I don't know if this is a know bug, but I cannot get canvas objects to be
  stippled on Mac OS. Using System 8.1, and Wish8.0p2 or Wish8.1a2:

  canvas .c
  pack .c
  .c create rectangle 100 100 200 200 -fill red -stipple gray50

  The above produces a solid red rectangle. Will this be fixed soon? Thanks
  for the great product!

  David Smith
  Programmer
  Perseus Project
  David Smith <dasmith@perseus.tufts.edu>


tkt_uuid: 1485750fffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 14. [message]
priority: 8
foundin: obsolete: 8.5a5
resolution: Fixed
title: Missing Tcl_Release in MessageWidgetObjCmd() ?
comment:
  I spotted a couple of possible problems in
  Tcl_Preserve()..Tcl_Release() blocks while
  looking thro' the Tk source.

  I'm not 100% sure if they're real problems
  due to my limited understanding of the code,
  so apoglogies if i'm barking up the wrong tree!

  1.
  In tkMessage.c's MessageWidgetObjCmd(),
  it's possible to bypass the Tcl_Release(msgPtr) done
  at the end:

   Tcl_Preserve((ClientData) msgPtr);

   switch ((enum options) index) {
    case MESSAGE_CGET: {
     if (objc != 3) {
      Tcl_WrongNumArgs(interp, 2, objv, "option");
      return TCL_ERROR; // skip's Tcl_Release

  It's not clear why this case should omit
  the Tcl_Release, so possibly an oversight?

  2.
  In tkEvent.c, the

  ~1362: Tcl_Preserve((ClientData) interp);

  is conditional on:

  ~1351: (winPtr->mainPtr != NULL).

  However the corresponding Release is conditional on:

  ~1446: (interp != (Tcl_Interp *) NULL)

  It's not clear to me if these conditions are
  equivalent. ie. if winPtr->mainPtr is NULL,
  and interp is !NULL, then it would Release
  something it hadn't Preserve'd (unless that gets
  done elsewhere?).


tkt_uuid: 220495ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 85. Win Build
priority: 2
foundin: obsolete: 8.1b3
resolution: Fixed
title: NT / tkIntXlibDecls.h not installed correctly
comment:
  OriginalBugID: 1799 Bug
  Version: 8.1b3
  SubmitDate: '1999-04-14'
  LastModified: '1999-04-16'
  Severity: CRIT
  Status: Released
  Submitter: pat
  ChangedBy: surles
  OS: Windows NT
  Machine: X86
  FixedDate: '1999-04-16'
  FixedInVersion: 8.1b3


  Name:
  Petteri Kettunen

  Extensions:
  N/A

  CustomShell:
  N/A

  Comments:
  N/A

  ReproducibleScript:
  Dowload tk81b3.zip, cd tk8.1b3\win, nmake, nmake install. Then try to
      compile something that includes tk.h from install directory.
      
      C:\tmp>cat dummy.c
      #include <stdio.h>
      #include <tcl.h>
      #include <tk.h>
      
      void dummy() { }

  ObservedBehavior:
  C:\tmp>cl -c -Ie:\pr\tcl\include dummy.c
      Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 12.00.8168 for
      80x86
      Copyright (C) Microsoft Corp 1984-1998. All rights reserved.
      
      dummy.c
      e:\pr\tcl\include\X11/Xlib.h(1220) : fatal error C1083: Cannot open
      include file
      : 'tkIntXlibDecls.h': No such file or directory

  DesiredBehavior:
  Clean compilation without errors.

  Patch:
  N/A

  PatchFiles:
  N/A



  04/16/1999 17:19 - surles - Updated the Tcl and Tk makefile.vc files so that the correct decl header files are installed."


tkt_uuid: 220357ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 68. Win Window Operations
priority: 2
foundin: obsolete: 8.0p2
resolution: Fixed
title: On Windows, don't use a maximize box if the Windows is not resizable
comment:
  OriginalBugID: 595 Bug
  Version: 8.0p2
  SubmitDate: '1998-05-21'
  LastModified: '1999-03-17'
  Severity: LOW
  Status: Released
  Submitter: hershey
  ChangedBy: stanton
  OS: All
  OSVersion: NA
  Machine: NA
  FixedDate: '1999-03-17'
  FixedInVersion: 8.1b2


  On Windows, if a window is not resizable (because of a call to wm

  resizable), there is really no reason to have a maximize box or a

  sizing frame.  In fact, it's better to omit them, because they suggest

  to Windows users that the window can be resized, even though it can't.



  The appended patch makes this change in Tk8.0p2.  It should also apply

  to Tk8.1a2.



  Ian Taylor

  ian@cygnus.com



  *** /5g/ian/tk8.0p2/win/tkWinWm.c       Fri Oct 31 12:57:07 1997

  --- tkWinWm.c   Wed Apr 15 15:52:20 1998

  *************** UpdateWrapper(winPtr)

  *** 668,673 ****

  --- 668,678 ----

              wmPtr->exStyle = EX_TOPLEVEL_STYLE;

          }

    

  +       if ((wmPtr->flags & WM_WIDTH_NOT_RESIZABLE)

  +           && (wmPtr->flags & WM_HEIGHT_NOT_RESIZABLE)) {

  +           wmPtr->style &= ~ (WS_MAXIMIZEBOX | WS_SIZEBOX);

  +       }

  + 

          /*

           * Compute the geometry of the parent and child windows.

           */





  03/17/1999 15:05 - stanton - applied patch


tkt_uuid: 487442ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 76. Widget Tour
priority: 5 Medium
foundin: obsolete: 8.3.4
resolution: Fixed
title: changing font size in tk widget demo
comment:
  I work on windows-Me with a 1024x768 screen.

  The basic "widget demonstration" has a big
  font and, in my opinion, may give to newcomers the
  feeling that tk is a bit "kludge".

  Changing the line 26 of widget.tcl 
  from "set font {Helvetica 14}"
  to "set font {Helvetica 10}"   (or 11)

  makes me feel much better, each time I install
  a new distribution. 

  I suggest to integrate this modification in the core
  distribution.


  V. Wartelle.


tkt_uuid: 705787ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 66. Aqua Window Operations
priority: 5 Medium
foundin: obsolete: 8.4.2
resolution: Fixed
title: "winfo server ." crashes Mac Acqua Tcl
comment:
  I am running Tcl/Tk 8.4.2 built from the standard
  source distribution, following the README instructions
  in Tk's macosx directory.

  Typing "winfo server ." causes a segmentation violation
  with wish (running under Acqua).


tkt_uuid: 1692755fffffffffffffffffffffffffffffffff
type: Bug
status: Open
subsystem: 01. Bindings
priority: 5 Medium
foundin: obsolete: 8.4.14
resolution: None
title: Focused button widgets invoked on Alt-Space
comment:
  On Windows, when an Alt-Space event occurs to show the "Windows system menu", the buttons and checkbuttons (provided they have focus) will see the space and/or Alt key events and are invoked. 

  This trivial script shows the misbehaviour. Alt-Space should never cause the checkbutton to be toggled or the button to be invoked.

  checkbutton .but1 -text "Do something but not on Alt-Space" 
  button .but2 -text "Do something but not on Alt-Space" -command exit 

  pack .but1 .but2 


tkt_uuid: 220109ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: None
priority: 1 Zero
foundin: obsolete: 8.0
resolution: Invalid
title: loadable shared libraries
comment:
  OriginalBugID: 645 Bug
  Version: 8.0
  SubmitDate: '1998-05-25'
  LastModified: '1999-08-06'
  Severity: LOW
  Status: Closed
  Submitter: hershey
  ChangedBy: hobbs
  OS: IRIX
  OSVersion: 6.2
  Machine: NA
  FixedInVersion: NA
  ClosedDate: '1999-08-06'


  Brent,

  I am trying to get the load random.so example on page 523 to 525
  of the second edition of your book to work. The make file
  makes a random.so file using code from example 41-1, 41-2,
  and 41-3.  The interaction with the machine looks like this,

  bangkok{lreder}349: make random
          CC -g -I/home/lreder/src/tcltk/tcl8.0/include -c random.c
          CC -g -I/home/lreder/src/tcltk/tcl8.0/include -c RandomCmd.c
          CC -g -I/home/lreder/src/tcltk/tcl8.0/include -c RandomObjCmd.c
          CC -o random.so -shared random.o RandomCmd.o RandomObjCmd.o
  -L/home/lreder/src/tcltk/tcl8.0/lib -ltcl8.0 -lm
  bangkok{lreder}350: wish8.0
  % pwd
  /home/lreder/src/animplayer/tktest
  % pkg_mkIndex /home/lreder/src/animplayer/tktest *.so
  error while loading or sourcing random.so: couldn't find procedure
  Random_Init

  I am running on Irix 6.2 and using tcl/tk 8.0.

  Also if I do,

  % load /home/lreder/src/animplayer/tktest/random.so
  couldn't find procedure Random_Init

  I know the Random_Init routine is in the random.so library.

  Can you tell me how to make this work?  I have a current
  application which is compiled into a wish shell.  What I
  want to do is make it a shared library so that I can just
  use the load command to include it into my tcl/tk scripts.
  This feature does not seem to work.

  A quick reply would be very much appreciated.

  Len

  P.S. Also in example 41-9 the variable object is not defined.
       Also in example 41-6 the Tcl_DecrRefCount call is not needed.
       The routine works without it but not with it. 


  This appears to be a random programming error (not extern'ed
  func or something). 
  -- 08/06/1999 hobbs


tkt_uuid: 220140ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 01. Bindings
priority: 1 Zero
foundin: obsolete: 8.0p2
resolution: Invalid
title: Control-v under Unix
comment:
  OriginalBugID: 1455 RFE
  Version: 8.0p2
  SubmitDate: '1999-03-04'
  LastModified: '1999-08-06'
  Severity: LOW
  Status: Closed
  Submitter: pat
  ChangedBy: hobbs
  OS: Linux-SuSE
  Machine: Other
  ClosedDate: '1999-08-06'


  Name:
  Joe Acosta

  DesiredBehavior:
  Some way of unbinding default bindings, using only the script and no C code.
  Currently there are default bindings, in particular "Control-v" whcih does a page down under unix. I am creating a cross platform editor and want to use Control-v as my Paste to please my Windows95/98/NT users. Is there/will there be a way to unbind this binding without me changing the text.tcl code? I think that possible makeing another value for tk_strictMotif may work, instead of it being a boolean of 0 or 1. Say a value of 2 would turn off all bindings? Then I could defing my own. Or maybe making the behavior such that the binding in the parent script override the default bindings of tcl/tk? I'd rather not use Meta keys either.



  All the bindings are controllable at the Tcl level through the
  'bind' command.  They can be overwritten, extended, removed, etc.
  You can refer to the text.tcl for just examples of what you might
  want to provide. 
  -- 08/06/1999 hobbs


tkt_uuid: 220876ffffffffffffffffffffffffffffffffff
type: Bug
status: Open
subsystem: 10. Generic Menus
priority: 5 Medium
foundin: obsolete: 8.2.1
resolution: None
title: Error with torn off menus
comment:
  OriginalBugID: 3408 Bug
  Version: 8.2.1
  SubmitDate: '1999-11-05'
  LastModified: '1999-11-12'
  Severity: LOW
  Status: UnAssn
  Submitter: techsupp
  ChangedBy: hobbs
  OS: Windows NT


  Name:
  Peter Spjuth

  ReproducibleScript:
  catch {console show}
      
      menubutton .mb -text Menu -menu .mb.m
      menu .mb.m
      .mb.m add command -label Apa
      .mb.m add cascade -label Bepa -menu .mb.m.m
      menu .mb.m.m
      .mb.m.m add command -label Cepa
      
      pack .mb
      
      proc apa {name1 name2 op} {
          set caller [lindex [info level -1] 0]
          puts "tkPriv(menuBar) is now \"$::tkPriv(menuBar)\" set in $caller"
      }
      trace variable tkPriv(menuBar) w apa
      
      ----------------
      Press the menu button and tear off the menu.
      In the torn off menu, click Bepa to open the cascade
      Click Cepa.
      The trace output should now show that tkPriv(menuBar) is ".tearoff1"
      Close the window with the torn off menu.
      Click the menu button.
      This gives an error since tkPriv(menuBar) references a window that does
      not exist.
      
      I have also seen another effect with torn off menus which might be
      related.
      Tear of the menu.
      Click Bepa to open the cascade.
      Click Cepa. The cascade disappears (as it should).
      Click Bepa. Nothing happens!
      Click Apa.
      Click Bepa. Now it works ok.


tkt_uuid: 220619ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 68. Win Window Operations
priority: 2
foundin: obsolete: 8.2.1
resolution: Fixed
title: "static" keywork missing from function definitions
comment:
  OriginalBugID: 3520 Bug
  Version: 8.2.1
  SubmitDate: '1999-11-08'
  LastModified: '1999-12-22'
  Severity: LOW
  Status: Released
  Submitter: techsupp
  ChangedBy: hobbs
  OS: All
  FixedDate: '1999-12-22'
  FixedInVersion: 8.3


  Name:
  D. Richard Hipp

  ReproducibleScript:
  In the file win/tkWinImage.c, the functions DestroyImage() and ImageGetPixel() should
  (I think) have only file scope.  In other words, their definition should begin with the
  keyword "static".  This is not the case.



  Fixed in 8.3b2. 
  -- 12/22/1999 hobbs


tkt_uuid: 595257ffffffffffffffffffffffffffffffffff
type: Patch
status: Closed
subsystem: 81. Portability
priority: 5 Medium
foundin: None
resolution: Duplicate
title: Borland: Additional info for a TK build
comment:
  Hello David,
  another attempt to get along with SF.
  Just found out that my original patch for building TK
  wasn't  really sufficient: I had been using C++
  Builder, not the command line compiler.
  So, there is another (small) patch necessary: tkWinX.c
  #includes <zmouse.h> - which (being part of MFC) is not
  available in the free compiler. All this file does,
  however, is to contribute the definition of 
  "WM_MOUSEWHEEL".
  No big deal: just include <winuser.h> instead and all
  is fine. I add a diff, comparing my patched version of
  tkWinX.c with the original version.
  Just an idea: *winuser.h" seems like a fairly generic
  header file. If this file contains "WM_MOUSEWHEEL" on
  *all* Windows compilers, we could change the #include
  mentioned above for all of them to "#include
  <winuser.h>", thus avoiding another test for the
  current compiler.
  Just a thought - with the conditional I added it works
  well with the Borland compiler.

  Best regards
  Helmut Giese


tkt_uuid: 220816ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 18. [text]
priority: 5 Medium
foundin: obsolete: 8.5a0
resolution: Fixed
title: Horizontal scrollbar doesn't scroll to the end of the widget
comment:
  OriginalBugID: 1940 Bug
  Version: 8.0.4
  SubmitDate: '1999-04-27'
  LastModified: '2000-02-10'
  Severity: MED
  Status: Assigned
  Submitter: pat
  ChangedBy: hobbs
  OS: Windows NT
  Machine: X86


  Name:
  Todor Slavov

  Comments:
  Reproducing described undesirable behavior depends also on the window
      geometry.

  ReproducibleScript:
  # OS: Windows NT4SP4, Display settings: 1024x768,Large Fonts
      package require Tk
      wm geometry . 121x141+200+200
      text .t -wrap none -height 5 -width 5 -font {Arial 10}
      .t insert end "WWWWWWWWWWWWi"
      scrollbar .h -orient horizontal -command {.t xview}
      .t config -xscrollcommand {.h set}
      grid .t -row 0 -column 0 -sticky nsew
      grid .h -row 1 -column 0 -sticky ew
      grid columnconfigure . 0 -weight 1
      grid rowconfigure . 0 -weight 1
      grid rowconfigure . 1 -weight 0

  ObservedBehavior:
  With proportionally-spaced font sometimes is impossible to view
      rightmost character 'i' in the text widget .t by moving the slider.
      Additional click on arrow2 is needed.

  DesiredBehavior:
  Moving the slider should scroll entire widgets, not just part of it.



  verified on NT in 8.3b2.  Problem does not occur with entry. 
  -- 02/10/2000 hobbs


tkt_uuid: 220878ffffffffffffffffffffffffffffffffff
type: RFE
status: Closed
subsystem: -- New Widgets
priority: 5 Medium
foundin: None
resolution: Wont Fix
title: Access to Windows NT Messaging/Printing dialogs
comment:
  OriginalBugID: 3450 RFE
  Version: 8.0p2
  SubmitDate: '1999-11-05'
  LastModified: '1999-12-14'
  Severity: LOW
  Status: UnAssn
  Submitter: techsupp
  ChangedBy: hobbs
  OS: Windows NT
  OSVersion: We also use SGI Irix


  Name:
  Mark Garvey

  Comments:
  Just a note on Megawidget support... Not very relevant but anyway!
      
      We also rely heavily on the TIX Megawidget set.
      
      Failure by Scriptics to support this extension or introduce a better
      megawidget set, will ultimately force us to move elsewhere for our GUI
      development. It has already resulted in a lack of enthusiasm for the
      later (8.1+) TK releases. User Interface look and feel is very important
      to our customers. 
      
      We are more interested in good megawidget support than in closing TCL
      support contracts with Scriptics.  While I cannot guarantee that my
      company would purchase a Scriptics Megawidget set, we would much more
      likely do so than a TCL support agreement, as TCL support expertize is
      already available in house.
      
      Please look on this as constructive critisism. I wish TCL & Scriptics
      every success for the future. It is the easiest language I know for fast
      development. Please let its public face shine!

  DesiredBehavior:
  As far as I am aware it is not possible from even the newer versions of
      TCL/TK to access the built in NT User Interfaces for printing and
      mailing.


tkt_uuid: 2863003fffffffffffffffffffffffffffffffff
type: Patch
status: Open
subsystem: 48. Geometry Management
priority: 6
foundin: None
resolution: None
title: Add a virtual event when GM leaves parent without slaves
comment:
  When trying to build a custom scrolledframe one generally resorts to the <Configure> event to catch the resizing of the scrolled frame [usually a frame inside a canvas] to keep scrollbars in sync. The problem with this approach is that, when the last slave is removed from inside the frame, the geometry managers leave the frame size as-is, and the scrolled frame ends scrolling an empty region.
  This can be noted in this BWidget example:
  ==================================================
  package require BWidget

  set sw [ScrolledWindow .sw]
  set sf [ScrollableFrame .sf]
  $sw setwidget $sf
  set f [$sf getframe]

  pack $sw -expand 1 -fill both -padx 10 -pady 10

  for {set i 0} {$i <= 20} {incr i} {
  grid \
  [label $f.la$i -text "Label a order $i"] \
  [label $f.lb$i -text "Label b order $i"] \
  [label $f.lc$i -text "Label c order $i"]
  }

  after 5000 {destroy {*}[winfo children $sf]}
  =================================================

  A way to note when the GM removes the last slave is to deliver a virtual event to the master.
  This patch adds the virtual event, and is intended as a sketch of the final code (the name of the
  virtual event, and whether to send additional details or not can be changed)


tkt_uuid: 1788019fffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: None
priority: 7 High
foundin: obsolete: 8.5a7
resolution: Fixed
title: tkTest.c compiler warning
comment:
  /home/dgp/release/tk8.5b1/unix/../generic/tkTest.c: In function ‘TestpropCmd’:
  /home/dgp/release/tk8.5b1/unix/../generic/tkTest.c:1989: warning: dereferencing type-punned pointer will break strict-aliasing rules


tkt_uuid: 570902ffffffffffffffffffffffffffffffffff
type: Patch
status: Closed
subsystem: 65. Generic Window Operations
priority: 8
foundin: None
resolution: Accepted
title: Patch to fix crashes in XCloseIM
comment:
  After many hours of searching and patching, I think
  I have finally fixed all the X input context issues
  that were causing crashes in XCloseIM or XCloseDisplay.
  These crashes were a result of a bug in X, so
  our only hope is to work around them. I sent a
  patch for the problem into the XFree86 project.
  but that will not cover existing systems. The basic
  problem is that you need to call XDestroyIC for
  every input context created by XCreateIC. We were
  missing some for the "special" windows created
  by the send command and the clipboard. This lead
  to invalid memory accesses in XCloseIM and things
  could get random after that.

  My original approach was to just hack some
  XDestroyIC call in, but that was not the best
  approach. The real fix was to make it possible
  to invoke Tk_DestroyWindow on the special
  windows created by the send and clipboard
  methods. That required a little rework of
  the shutdown sequence since this was not
  handled before. I have tested this quite
  a bit, this patch should solve the
  strange crashing I have been seeing
  without introducing any others.


tkt_uuid: 220830ffffffffffffffffffffffffffffffffff
type: RFE
status: Open
subsystem: 69. Events
priority: 5 Medium
foundin: None
resolution: None
title: add ability to define an event &quot;filter&quot;
comment:
  OriginalBugID: 1304 RFE
  Version: 8.1b1
  SubmitDate: '1999-02-25'
  LastModified: '1999-12-14'
  Severity: LOW
  Status: UnAssn
  Submitter: pat
  ChangedBy: hobbs
  OS: Windows NT
  OSVersion: 4
  Machine: X86


  Name:
  Bryan Oakley

  DesiredBehavior:
  it would be nice to define an event filter -- a script that all events
  for a particular bindtag go through before going through the normal
  event handling process.

  This could be used, for example, to implement an event record and
  playback tool. Once could set an event filter on ".", then use the "%e"
  substitution I recommended in another feature request to store the event
  information for later retrieval.

  If it were a true filter where aspects of the event could be changed, it
  could be useful to provide input validation or masking, or possibly even
  to redirect an event to a particular window (by modifying the %W value).
  It could also be used to implement a "busy" state, where all events are
  rejected until the busy state is clear. This can be done now, but not
  without a lot of work.  

  Finally, it could be used to drive additional copies of an application.
  For example, one could fire up N instances of a program, all controlled
  by a master program. Any events that pass through the filter could be
  sent to the other applications using a combination of send and event
  generate. This could be useful for remote debugging, for example. Or in
  teaching situations where the teacher can demonstrate a program and have
  his/her actions duplicated on the student's machines.


tkt_uuid: 749014ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 15. [scale]
priority: 5 Medium
foundin: obsolete: 8.5a0
resolution: Invalid
title: scale.test fails
comment:
   This test fails on Tru64Unix 5.1A with tcl8.4.3/tk-cvs
   but NOT tcl8.4.3/tk8.4.3(maybe it's expected when
   messing up versions):


  ==== scale-15.5 ScaleVarProc procedure, variable
  deleted FAILED
  ==== Contents of test case:

      catch {destroy .s}
      set y 6
      scale .s -from 10 -to 0 -variable y -orient
  horizontal -length 150  -command "set x"
      pack .s
      update
      set x untouched
      unset y
      update
      list [catch {set y} msg] $msg [.s get] $x

  ---- Result was:
  0 6 6 6
  ---- Result should have been (exact matching):
  0 6 6 untouched
  ==== scale-15.5 FAILED


  ==== scale-15.6 ScaleVarProc procedure, don't call
  -command FAILED
  ==== Contents of test case:

      catch {destroy .s}
      set y 6
      scale .s -from 0 -to 100 -variable y -orient
  horizontal -length 150  -command "set x"
      pack .s
      update
      set x untouched
      set y 60
      update
      list $x [.s get]

  ---- Result was:
  60 60
  ---- Result should have been (exact matching):
  untouched 60
  ==== scale-15.6 FAILED


tkt_uuid: 2080587fffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 41. Photo Images
priority: 5 Medium
foundin: obsolete: 8.6a3
resolution: Fixed
title: failing imgPhoto tests
comment:
  ==== imgPhoto-4.67 ImgPhotoCmd procedure: transparency set option FAILED
  ==== Contents of test case:

      photo1 put white -to 0 0 3 3
      checkImgTransLoopSetReset photo1 3 3

  ---- Test generated error; Return code was: 1
  ---- Return code should have been one of: 0 2
  ---- errorInfo: image "img" doesn't exist
      while executing
  "image width $img"
      (procedure "foreachPixel" line 3)
      invoked from within
  "foreachPixel img x y {
              $img put white -to 0 0 3 3
              $img transparency set $x $y 1
              lappend result {*}[checkImgTrans $img]
              append resu..."
      (procedure "checkImgTransLoopSetReset" line 3)
      invoked from within
  "checkImgTransLoopSetReset photo1 3 3"
      ("uplevel" body line 3)
      invoked from within
  "uplevel 1 $script"
  ---- errorCode: NONE
  ==== imgPhoto-4.67 FAILED



  ==== imgPhoto-4.71 ImgPhotoCmd procedure: copy with -compositingrule FAILED
  ==== Contents of test case:

      # Tests default compositing rule
      photo1 blank
      photo2 blank
      photo1 put white -to 0 0 2 2
      photo2 put white -to 0 0 2 2
      photo2 transparency set 0 0 true
      photo1 copy photo2 -to 1 1
      checkImgTrans photo1

  ---- Result was:
  0,2 2,0
  ---- Result should have been (exact matching):
  0 2 2 0
  ==== imgPhoto-4.71 FAILED



  ==== imgPhoto-4.72 ImgPhotoCmd procedure: copy with -compositingrule FAILED
  ==== Contents of test case:

      photo1 blank
      photo2 blank
      photo1 put white -to 0 0 2 2
      photo2 put white -to 0 0 2 2
      photo2 transparency set 0 0 true
      photo1 copy photo2 -to 1 1 -compositingrule overlay
      checkImgTrans photo1

  ---- Result was:
  0,2 2,0
  ---- Result should have been (exact matching):
  0 2 2 0
  ==== imgPhoto-4.72 FAILED



  ==== imgPhoto-4.73 ImgPhotoCmd procedure: copy with -compositingrule FAILED
  ==== Contents of test case:

      photo1 blank
      photo2 blank
      photo1 put white -to 0 0 2 2
      photo2 put white -to 0 0 2 2
      photo2 transparency set 0 0 true
      photo1 copy photo2 -to 1 1 -compositingrule set
      checkImgTrans photo1

  ---- Result was:
  0,2 1,1 2,0
  ---- Result should have been (exact matching):
  0 2 1 1 2 0
  ==== imgPhoto-4.73 FAILED


tkt_uuid: 3555324fffffffffffffffffffffffffffffffff
type: RFE
status: Closed
subsystem: 01. Bindings
priority: 5 Medium
severity: Minor
foundin: None
resolution: Fixed
title: Ctrl+A for select-all
comment:
  Tk binds Ctrl+A to start-of-line instead
  of select-all, which many other applications
  do. See:
  <http://www.computerhope.com/shortcut.htm>

  Suggestion: Introduce a virtual event
  <<SelectAll>>


tkt_uuid: 627462ffffffffffffffffffffffffffffffffff
type: RFE
status: Closed
subsystem: 78. Other Demos
priority: 5 Medium
foundin: None
resolution: Accepted
title: New widget demo - keysym display
comment:
  A regularly posted script is tk code displaying the
  names of keys as used by bind.  A 'best practices'
  version of such code , included in the widget tour, m
  ight make a useful utility as well.


tkt_uuid: 2789782fffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 03. [*button] and [label]
priority: 5 Medium
foundin: obsolete: 8.5.7
resolution: Duplicate
title: button not centering image
comment:
  This is identical to ID: 2433781. For any reason comments have been closed for #2433781, therefore I add a new bug report:

  Try the following code:

  image create photo img -data {
  R0lGODdhCgAKAIABAMEsLP///ywAAAAACgAKAAACCISPqcvtD2MrADs= }
  button .b -borderwidth 1 -image img -relief solid
  pack .b

  As you can see, the image will not be centered. This makes it impossible to
  use button as a toolbar button.

  Your response to ID 2433781 is:

  > In what way is the image not centered? On Windows I see a read square
  > perfectly surrounded by 1px all around, then the solid outline. When
  > selecting, it shifts down, as is the designed behavior of button images on
  > selection.

  I believe you, but on Linux the image is not centered. I see two 2 px left and above, but 0 px right and below the solid outline. It seems, that the result is different on Linux and Windows.


tkt_uuid: 1669632fffffffffffffffffffffffffffffffff
type: Bug
status: Open
subsystem: 01. Bindings
priority: 5 Medium
foundin: obsolete: 8.5a5
resolution: None
title: text widget: autoseparator placement, <Control-1> cleanup
comment:
  LIST OF BUGS/FEATURES FIXED BY THE PATCH

  A patch to lib/tk8.5/text.tcl is supplied, and each fix in the patch file is commented.  The bugs/features are labeled here by the binding, followed by a short description of how to demonstrate the bug/feature.

  (i), (iv) and (vii) are bugfixes to autoseparator placement
  (ii), (iii) fix apparent bugs where the real problem is a shaky hand; since they don't break any intended behavior they could be considered improvements
  (v), (vi) make <<Clear>> and <<Cut>> atomic operations on the Undo stack.

  (i) <Control-1>
  Insert text at position 'A'; use <Control-1> to click at 'B'; insert text at 'B'; <<Undo>>
  The insertions at both 'A' and 'B' are removed together.
  The patch inserts an autoseparator.

  General rule (obeyed elsewhere in text.tcl): an operation that moves the insert mark without making it one end of the selection must insert an autoseparator.

  (ii) <Double-Control-1>
  The patch prevents <Control-1> from becoming <Double-Button-1> if the user accidentally double clicks.

  (iii) <Control-B1-Motion>
  The patch prevents <Control-1> from becoming <B1-Motion> if the user accidentally makes a slight movement of the mouse.

  (iv) <Control-backslash>
  Insert text at position 'A'; use <Shift-Right> to create a selection to position 'B'; use <Control-backslash> to clear the selection, leaving the insert mark at 'B'; insert text at 'B'; <<Undo>>
  The insertions at both 'A' and 'B' are removed together.
  The patch inserts an autoseparator.

  General rule (obeyed elsewhere in text.tcl): an operation that clears the selection must insert an autoseparator, because the selection operation may have moved the insert mark.

  (v) <<Clear>>
  <Delete> a character at position 'A'; use <Shift-Right> to create a selection to position 'B'; use <<Clear>> to delete the selection; <Delete> another character; <<Undo>>
  All three deletions are undone.
  It might be preferable to make <<Clear>> atomic.  The patch does this.

  (For testing on non-Mac systems, use
      event add <<Clear>> <Key-F6>
  to map this binding to the F6 key)

  (vi) <<Cut>> (proc ::tk_textCut)
  Similar to <<Clear>> above: the patch makes <<Cut>> atomic.

  (vii) <<Undo>>
  (a) create a widget with -undo 1, and enter some text
  (b) click somewhere in the text.  Delete a character; type a few characters, without deleting anything or navigating away (i.e. only insert text).
  (c) click somewhere else in the text. Insert another character there.

  At this point the top operation in the Undo stack is the single inserted character, the operation before that is the group of inserted characters.

  (d) <<Undo>> - correctly undoes the last operation, but also removes the separator from the top of the Undo stack
  (e) type a character
  (f) <<Undo>> - undoes the character (e) _and_ the previous item on the Undo stack.


tkt_uuid: 574335ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 46. Unix Fonts
priority: 5 Medium
foundin: obsolete: 8.4a5
resolution: Fixed
title: compiler warnings
comment:
  cc -c -O  -KPIC -I/local/src/tk/unix
  -I/local/src/tk/unix/../generic
  -I/local/src/tk/unix/../bitmaps
  -I/local/src/tcl/generic -I/usr/openwin/include
  -DHAVE_UNISTD_H=1 -DHAVE_LIMITS_H=1
  -DTCL_WIDE_INT_TYPE=long\ long -DHAVE_STRUCT_DIRENT64=1
  -DHAVE_STRUCT_STAT64=1 -DHAVE_TYPE_OFF64_T=1
  -D_REENTRANT=1 -D_POSIX_PTHREAD_SEMANTICS=1
  -DSTDC_HEADERS=1 -DHAVE_SYS_TIME_H=1
  -DTIME_WITH_SYS_TIME=1 -DHAVE_PW_GECOS=1     
  -DTCL_NO_DEPRECATED -DUSE_TCL_STUBS 
  /local/src/tk/unix/tkUnixFont.c
  "/local/src/tk/unix/tkUnixFont.c", line 1174: warning:
  argument #6 is incompatible with prototype:
          prototype: pointer to unsigned int :
  "/usr/openwin/include/X11/Xlib.h", line 2995
          argument : pointer to int
  "/local/src/tk/unix/tkUnixFont.c", line 1174: warning:
  argument #7 is incompatible with prototype:
          prototype: pointer to unsigned int :
  "/usr/openwin/include/X11/Xlib.h", line 2995
          argument : pointer to int
  "/local/src/tk/unix/tkUnixFont.c", line 1174: warning:
  argument #8 is incompatible with prototype:
          prototype: pointer to unsigned int :
  "/usr/openwin/include/X11/Xlib.h", line 2995
          argument : pointer to int
  "/local/src/tk/unix/tkUnixFont.c", line 1174: warning:
  argument #9 is incompatible with prototype:
          prototype: pointer to unsigned int :
  "/usr/openwin/include/X11/Xlib.h", line 2995
          argument : pointer to int


tkt_uuid: 1591489fffffffffffffffffffffffffffffffff
type: Bug
status: Open
subsystem: 18. [text]
priority: 5 Medium
foundin: obsolete: 8.5a5
resolution: None
title: test suite text-1.10 failure , cvs head
comment:
  tk 8.5 cvs head, built on solaris 2.9 using sun c
  compiler, then test suite run output via exceed
  10.0.0.12 on win xp system.

  text.test

  ==== text-1.10 text options FAILED
  ==== Contents of test case:

          set result {}
          lappend result [catch {.t2 configure [lindex
  $test 0] [lindex $test 3]}]
          .t2 configure [lindex $test 0] [lindex $test 1]
          lappend result [.t2 cget [lindex $test 0]]
      
  ---- Result was:
  0 fixed
  ---- Result should have been (exact matching):
  1 fixed
  ==== text-1.10 FAILED


tkt_uuid: 220385ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 65. Generic Window Operations
priority: 2
foundin: obsolete: 8.0.4
resolution: Fixed
title: Tk8.0.3 'wm iconname' memory leak
comment:
  OriginalBugID: 728 Bug
  Version: 8.0.4
  SubmitDate: '1998-10-13'
  LastModified: '1998-10-13'
  Severity: MED
  Status: Released
  Submitter: admin
  ChangedBy: rjohnson
  OS: All
  OSVersion: NA
  Machine: NA
  FixedDate: '1998-10-13'
  FixedInVersion: NA


  This was fixed by a patch someone else submitted. (RJ)


  There is a memory leak in 'wm iconname', so that the following
  self-reposting code continuously increases the heap size of the
  process:

  #! /bin/sh
  # exec wish $0

  wm geometry . 0x0+0+0
  wm iconify .
  proc daemon {} {
  wm iconname . gag
  after 10 daemon ;# so that heap grows faster !!!
  }
  daemon


tkt_uuid: 1660674fffffffffffffffffffffffffffffffff
type: Bug
status: Open
subsystem: 05. Canvas Items
priority: 6
foundin: obsolete: 8.4.13
resolution: None
title: arrow reconfig triggers infinite Enter/Leave event sequence
comment:
  Submitted by John Brzustowski 
  jbrzusto@fastmail.fm

  VERSIONS/PLATFORMS
    Tk 8.4.13 on linux 2.6.13
    Tk 8.4.13 and 8.4.1 on cygwin 1.5.23, Windows XP

  SUMMARY
  If a canvas line item has its Enter/Leave events bound to handlers that configure arrows on and off, then triggering the handlers from some screen locations leads to an infinite sequence of mutually triggering Enter/Leave events.  See "PATCH" below for
  where in the Tk code the problem lies.

  EXAMPLE
  canvas .c
  .c create line 10 10 100 100 -fill black -tags myline
  pack .c
  .c bind myline <Leave> {.c itemconfigure myline -arrow none; puts Leaving}
  .c bind myline <Enter> {.c itemconfigure myline -arrow both; puts Entering}

  If you mouse around one of the line endpoints enough,
  you'll lock up event processing and the print output   
  will show an infinite sequence of 
  mutually triggering Enter and Leave events.
  (On Windows, the print output does not appear during the lockup.)

  I can understand how *adding* arrows could trigger an Enter event, since the line item is being enlarged, possibly to include the previously excluded pointer position.
  However, I can't see why adding arrows should trigger a Leave event, nor why removing them should trigger an Enter event (at least on the line item itself).

  PATCH
  The following patch removes the problem.  However, I don't understand the rationale for the code as originally written, therefore I'm not recommending this as a fix - it needs more thought.

  diff generic/tkCanvLine.c generic/mytkCanvLine.c
  2175,2176c2175,2176
  < linePtr->coordPtr[0] = poly[0] - backup*cosTheta;
  < linePtr->coordPtr[1] = poly[1] - backup*sinTheta;
  ---
  > linePtr->coordPtr[0] = poly[0];
  > linePtr->coordPtr[1] = poly[1];
  2214,2215c2214,2215
  < coordPtr[2] = poly[0] - backup*cosTheta;
  < coordPtr[3] = poly[1] - backup*sinTheta;
  ---
  > coordPtr[2] = poly[0];
  > coordPtr[3] = poly[1];


tkt_uuid: 220646ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 04. Canvas Basics
priority: 2
foundin: obsolete: 8.3b1
resolution: Fixed
title: Memory leak in advanced tag search feature
comment:
  OriginalBugID: 3977 Bug
  Version: 8.3b1
  SubmitDate: '2000-01-05'
  LastModified: '2000-01-07'
  Severity: SER
  Status: Released
  Submitter: techsupp
  ChangedBy: hobbs
  OS: All
  FixedDate: '2000-01-07'
  FixedInVersion: 8.3b2


  Name:

  Jan Nijtmans


  Comments:

  Many thanks to Kirk Hilliard for reporting and tracking down this bug (he also provided the above example script), and to John Ellson for fixing it so quickly.

  And last but not least to David Engel for all his support.


  ReproducibleScript:

  proc poly {} {

      global id a b

      if {$id != 0} { .c delete $id }

      set id [.c create oval $a $a $b $b -fill #ff0000]

      incr a

      incr b -1

      if {$b == 10} {

          set a 10

          set b 90

      }

      after 10 poly

  }


  set id 0

  set a 10

  set b 90

  canvas .c -width 100 -height 100 -bg black

  pack append . .c expand

  poly


  ObservedBehavior:

  This script about 48 kByte each second.


  Patch:

  *** generic/tkCanvas.c.origWed Dec 22 04:13:44 1999

  --- generic/tkCanvas.cTue Jan  4 22:07:07 2000

  ***************

  *** 311,318 ****

    static intRelinkItems _ANSI_ARGS_((TkCanvas *canvasPtr,

        Tcl_Obj *tag, Tk_Item *prevPtr,

        TagSearch **searchPtrPtr));

  ! static void TagSearchExprInit _ANSI_ARGS_ ((TagSearchExpr **exprPtrPtr,

  !     Tk_Uid uid));

    static voidTagSearchExprDestroy _ANSI_ARGS_((TagSearchExpr *expr));

    static voidTagSearchDestroy _ANSI_ARGS_((TagSearch *searchPtr));

    static intTagSearchScan _ANSI_ARGS_((TkCanvas *canvasPtr,

  --- 311,317 ----

    static intRelinkItems _ANSI_ARGS_((TkCanvas *canvasPtr,

        Tcl_Obj *tag, Tk_Item *prevPtr,

        TagSearch **searchPtrPtr));

  ! static void TagSearchExprInit _ANSI_ARGS_ ((TagSearchExpr **exprPtrPtr));

    static voidTagSearchExprDestroy _ANSI_ARGS_((TagSearchExpr *expr));

    static voidTagSearchDestroy _ANSI_ARGS_((TagSearch *searchPtr));

    static intTagSearchScan _ANSI_ARGS_((TkCanvas *canvasPtr,

  ***************

  *** 3010,3018 ****

     */


    static void

  ! TagSearchExprInit(exprPtrPtr, uid)

    TagSearchExpr **exprPtrPtr;

  - Tk_Uid uid;

    {

        TagSearchExpr* expr = *exprPtrPtr;


  --- 3009,3016 ----

     */


    static void

  ! TagSearchExprInit(exprPtrPtr)

    TagSearchExpr **exprPtrPtr;

    {

        TagSearchExpr* expr = *exprPtrPtr;


  ***************

  *** 3022,3028 ****

    expr->uids = NULL;

    expr->next = NULL;

        }

  !     expr->uid = uid;

        expr->index = 0;

        expr->length = 0;

        *exprPtrPtr = expr;

  --- 3020,3026 ----

    expr->uids = NULL;

    expr->next = NULL;

        }

  !     expr->uid = NULL;

        expr->index = 0;

        expr->length = 0;

        *exprPtrPtr = expr;

  ***************

  *** 3068,3074 ****

     *      was successfully scanned (syntax).

     *      The information at *searchPtr is initialized

     *      such that a call to TagSearchFirst, followed by

  !  *      successive calls to NextItem will return items

     *      that match tag.

     *

     * Side effects:

  --- 3066,3072 ----

     *      was successfully scanned (syntax).

     *      The information at *searchPtr is initialized

     *      such that a call to TagSearchFirst, followed by

  !  *      successive calls to TagSearchNext will return items

     *      that match tag.

     *

     * Side effects:

  ***************

  *** 3107,3123 ****

            searchPtr->rewritebuffer =

                ckalloc(searchPtr->rewritebufferAllocated);

        }

  !     TagSearchExprInit(&(searchPtr->expr),Tk_GetUid(tag));


  !     /* short circuit impossible searches for null tags */

  !     if ((searchPtr->stringLength = strlen(tag)) == 0) {

  !         return TCL_OK;

  ! }


        /* Make sure there is enough buffer to hold rewritten tags */

        if ((unsigned int)searchPtr->stringLength >=

        searchPtr->rewritebufferAllocated) {

  !         searchPtr->rewritebufferAllocated += 100;

            searchPtr->rewritebuffer =

                ckrealloc(searchPtr->rewritebuffer,

        searchPtr->rewritebufferAllocated);

  --- 3105,3119 ----

            searchPtr->rewritebuffer =

                ckalloc(searchPtr->rewritebufferAllocated);

        }

  !     TagSearchExprInit(&(searchPtr->expr));


  !     /* How long is the tagOrId ? */

  !     searchPtr->stringLength = strlen(tag);


        /* Make sure there is enough buffer to hold rewritten tags */

        if ((unsigned int)searchPtr->stringLength >=

        searchPtr->rewritebufferAllocated) {

  !         searchPtr->rewritebufferAllocated = searchPtr->stringLength + 100;

            searchPtr->rewritebuffer =

                ckrealloc(searchPtr->rewritebuffer,

        searchPtr->rewritebufferAllocated);

  ***************

  *** 3135,3141 ****

         * hot item, in which case the search can be skipped.

         */


  !     if (isdigit(UCHAR(*tag))) {

            char *end;


            searchPtr->id = strtoul(tag, &end, 0);

  --- 3131,3137 ----

         * hot item, in which case the search can be skipped.

         */


  !     if (searchPtr->stringLength && isdigit(UCHAR(*tag))) {

            char *end;


            searchPtr->id = strtoul(tag, &end, 0);

  ***************

  *** 3143,3148 ****

  --- 3139,3156 ----

                searchPtr->type = 1;

                return TCL_OK;

    }

  +     }

  + 

  +     /*

  +      * For all other tags and tag expressions convert to a UID.

  +      * This UID is kept forever, but this should be thought of

  +      * as a cache rather than as a memory leak.

  +      */

  +     searchPtr->expr->uid = Tk_GetUid(tag);

  + 

  +     /* short circuit impossible searches for null tags */

  +     if (searchPtr->stringLength == 0) {

  + return TCL_OK;

        }


        /*


  PatchFiles:

  tkCanvas.c




  fixed in 8.3b2 
  -- 01/07/2000 hobbs


tkt_uuid: 219962ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 99. Other
priority: 1 Zero
foundin: obsolete: 8.1b2
resolution: Duplicate
title: make test generates many errors
comment:
  OriginalBugID: 1658 Bug
  Version: 8.1b2
  SubmitDate: '1999-03-29'
  LastModified: '1999-08-31'
  Severity: SER
  Status: Closed
  Submitter: pat
  ChangedBy: hobbs
  RelatedBugIDs: 2181
  OS: Solaris
  OSVersion: 2.6
  Machine: Other
  ClosedDate: '1999-08-31'


  Name: Larry W. Virden
  Extensions: Tk
  CustomShell: none

  ReproducibleScript:
      I did a make distclean to remove the previous configuration
      (which was core dumping).  I then did a
      /vol/tclsrcsol/tcl81/tk8.1b2/unix/configure --prefix=/usr/tcl81
      --exec_prefix=/usr/tcl81/sun4 --enable-shared
      make all
      make test

  ObservedBehavior:
      the make test reported 47 failures - ranging from
      canvText.test clipboard.test config.test focus.test grid.test main.test
      safe.test send.test textDisp.test unixEmbed.test unixFont.test
      unixSend.test util.test winfo.test
      
      Here are the specifics of the failures.
      
      canvText.test
      
      ==== canvText-6.1 ComputeTextBbox procedure FAILED
      ==== Contents of test case:
      
          .c itemconfig test -font $font -text 0
          .c coords test 0 0
          set x {}
          lappend x [.c itemconfig test -anchor n; .c bbox test]
          lappend x [.c itemconfig test -anchor nw; .c bbox test]
          lappend x [.c itemconfig test -anchor w; .c bbox test]
          lappend x [.c itemconfig test -anchor sw; .c bbox test]
          lappend x [.c itemconfig test -anchor s; .c bbox test]
          lappend x [.c itemconfig test -anchor se; .c bbox test]
          lappend x [.c itemconfig test -anchor e; .c bbox test]
          lappend x [.c itemconfig test -anchor ne; .c bbox test]
          lappend x [.c itemconfig test -anchor center; .c bbox test]
      
      ---- Result was:
      {-6 0 6 25} {-1 0 11 25} {-1 -12 11 13} {-1 -25 11 0} {-6 -25 6 0} {-11
      -25 1 0} {-11 -12 1 13} {-11 0 1 25} {-6 -12 6 13}
      ---- Result should have been:
      {-6 0 6 25} {-1 0 11 25} {-1 -13 11 12} {-1 -25 11 0} {-6 -25 6 0} {-11
      -25 1 0} {-11 -13 1 12} {-11 0 1 25} {-6 -13 6 12}
      ==== canvText-6.1 FAILED
      
      clipboard.test
      
      ==== clipboard-6.2 Tk_ClipboardAppend procedure FAILED
      ==== Contents of test case:
      
          setupbg
          clipboard clear
          clipboard append -f INTEGER -t TEST "16"
          set result [dobg {selection get -s CLIPBOARD TEST}]
          cleanupbg
          set result
      
      ---- Result was:
      CLIPBOARD selection doesn't exist or form "TEST" not defined
      ---- Result should have been:
      0x10
      ==== clipboard-6.2 FAILED
      
      clrpick.test
      Skipped tests clrpick2.1, clrpick2.2 and clrpick2.3 because
      you ran out of colors in your color palette, and this would
      have caused the tests to generate errors.
      
      config.test
      
      ==== config-8.9 Tk_RestoreSavedOptions - font internal form FAILED
      ==== Contents of test case:
      
          eval destroy [winfo children .]
          testobjconfig internal .a
          list [catch {.a csave -font {Times 12} -color bogus}] [.a cget
      -font]
      
      ---- Result was:
      1 {-*-lucida sans typewriter-medium-r-*-*-16-*-*-*-*-*-*-*}
      ---- Result should have been:
      1 {Helvetica 12}
      ==== config-8.9 FAILED
      
      focus.test
      
      ==== focus-6.1 miscellaneous - embedded application in same process
      FAILED
      ==== Contents of test case:
      
          eval interp delete [interp slaves]
          catch {destroy .t}
          toplevel .t
          wm geometry .t +0+0
          frame .t.f1 -container 1
          frame .t.f2
          pack .t.f1 .t.f2
          entry .t.f2.e1 -bg red
          pack .t.f2.e1
          bind all <FocusIn> {lappend x "focus in %W %d"}
          bind all <FocusOut> {lappend x "focus out %W %d"}
          interp create child
          child eval "set argv {-use [winfo id .t.f1]}"
          load {} tk child
          child eval {
              entry .e1 -bg lightBlue
              pack .e1
              bind all <FocusIn> {lappend x "focus in %W %d"}
              bind all <FocusOut> {lappend x "focus out %W %d"}
              set x {}
          }
      
          # Claim the focus and wait long enough for it to really arrive.
      
          focus -force .t.f2.e1
          after 300 {set timer 1}
          vwait timer
          set x {}
          lappend x [focus] [child eval focus]
      
          # See if a "focus" command will move the focus to the embedded
          # application.
      
          child eval {focus .e1}
          after 300 {set timer 1}
          vwait timer
          lappend x |
          child eval {lappend x |}
      
          # Bring the focus back to the main application.
      
          focus .t.f2.e1
          after 300 {set timer 1}
          vwait timer
          set result [list $x [child eval {set x}]]
          interp delete child
          set result
      
      ---- Result was:
      {.t.f2.e1 {} | {focus out .t.f2.e1 NotifyNonlinear} {focus out .t.f2
      NotifyNonlinearVirtual} {focus in .t.f1 NotifyNonlinear}} {| {focus in .
      NotifyVirtual} {focus in .e1 NotifyAncestor}}
      ---- Result should have been:
      {.t.f2.e1 {} {focus out .t.f2.e1 NotifyNonlinear} {focus out .t.f2
      NotifyNonlinearVirtual} {focus in .t.f1 NotifyNonlinear} | {focus out
      .t.f1 NotifyNonlinear} {focus in .t.f2 NotifyNonlinearVirtual} {focus in
      .t.f2.e1 NotifyNonlinear}} {{focus in . NotifyVirtual} {focus in .e1
      NotifyAncestor} | {focus out .e1 NotifyAncestor} {focus out .
      NotifyVirtual}}
      ==== focus-6.1 FAILED
      
      grid.test
      
      ==== grid-6.9 location: check updates pending FAILED
      ==== Contents of test case:
      
              set a ""
              foreach i {0 1 2} {
                  frame .$i -width 120 -height 75 -bg red
                  lappend a [grid location . 150 90]
                  grid .$i -row $i -column $i
              }
              set a
      
      ---- Result was:
      {0 0} {0 1} {1 1}
      ---- Result should have been:
      {0 0} {1 1} {1 1}
      ==== grid-6.9 FAILED
      
      main.test
      
      ==== main-1.1 StdinProc FAILED
      ==== Contents of test case:
      
          catch {removeFile script}
          set fd [open script w]
          puts $fd {
              close stdin; exit
          }
          close $fd
          if {[catch {exec $tktest <script} msg]} {
              set error 1
          } else {
              set error 0
          }
          file delete -force script
          list $error $msg
      
      ---- Result was:
      1 {can't read "tktest": no such variable}
      ---- Result should have been:
      0 {}
      ==== main-1.1 FAILED
      
      safe.test
      
      ==== safe-5.1 loading Tk in safe interps without master's clearance
      FAILED
      ==== Contents of test case:
      
          set i [safe::interpCreate]
          catch {interp eval $i {load {} Tk}} msg
          safe::interpDelete $i
          set msg
      
      ---- Result was:
      couldn't create child of window "0xa0008f7"
      ---- Result should have been:
      not allowed to start Tk by master's safe::TkInit
      ==== safe-5.1 FAILED
      
      send.test
      
      ==== send-8.1 Tk_SendCmd procedure, options FAILED
      ==== Contents of test case:
      
          setupbg
          set app [dobg {tk appname}]
          set a 66
          send -async $app [list send [tk appname] set a 77]
          set result $a
          after 200 set x 40
          tkwait variable x
          cleanupbg
          lappend result $a
      
      ---- Result was:
      66 66
      ---- Result should have been:
      66 77
      ==== send-8.1 FAILED
      
      ==== send-10.19 SendEventProc procedure, send exits FAILED
      ==== Contents of test case:
      
              setupbg
              dobg {tk appname t_s_3}
              set x [list [catch {send t_s_3 exit} msg] $msg]
              close $fd
              set x
      
      ==== Test generated error:
      can not find channel named "file7"
      ---- Result should have been:
      1 {target application died}
      ==== send-10.19 FAILED
      
      ==== send-12.2 TimeoutProc procedure FAILED
      ==== Contents of test case:
      
          winfo interps
          tk appname tktest
          update
          setupbg
          puts $fd {after 10 {after 5000; exit}; puts [tk appname]; puts
      **DONE**; flush stdout}
          set ::test::bgDone 0
          set ::test::bgData {}
          flush $fd
          tkwait variable ::test::bgDone
          set app $::test::bgData
          after 200
          set result [list [catch {send $app foo} msg] $msg]
          close $fd
          set result
      
      ==== Test generated error:
      can not find channel named "file7"
      ---- Result should have been:
      1 {target application died}
      ==== send-12.2 FAILED
      
      textDisp.test
      
      ==== textDisp-2.22 LayoutDLine, spacing options FAILED
      ==== Contents of test case:
      
          .t configure -wrap word
          .t delete 1.0 end
          .t tag delete x y
          .t insert end "Short line\nLine 2 is long enough "
          .t insert end "to wrap around a couple of times"
          .t insert end "\nLine 3\nLine 4"
          set i [.t dlineinfo 1.0]
          set b1 [expr [lindex $i 1] + [lindex $i 4]]
          set i [.t dlineinfo 2.0]
          set b2 [expr [lindex $i 1] + [lindex $i 4]]
          set i [.t dlineinfo 2.end]
          set b3 [expr [lindex $i 1] + [lindex $i 4]]
          set i [.t dlineinfo 3.0]
          set b4 [expr [lindex $i 1] + [lindex $i 4]]
          .t configure -spacing1 2 -spacing2 1 -spacing3 3
          set i [.t dlineinfo 1.0]
          set b1 [expr [lindex $i 1] + [lindex $i 4] - $b1]
          set i [.t dlineinfo 2.0]
          set b2 [expr [lindex $i 1] + [lindex $i 4] - $b2]
          set i [.t dlineinfo 2.end]
          set b3 [expr [lindex $i 1] + [lindex $i 4] - $b3]
          set i [.t dlineinfo 3.0]
          set b4 [expr [lindex $i 1] + [lindex $i 4] - $b4]
          list $b1 $b2 $b3 $b4
      
      ---- Result was:
      2.0 7.0 10.0 15.0
      ---- Result should have been:
      2 7 10 15
      ==== textDisp-2.22 FAILED
      
      ==== textDisp-2.23 LayoutDLine, spacing options FAILED
      ==== Contents of test case:
      
          .t configure -wrap word
          .t delete 1.0 end
          .t tag delete x y
          .t insert end "Short line\nLine 2 is long enough "
          .t insert end "to wrap around a couple of times"
          .t insert end "\nLine 3\nLine 4"
          set i [.t dlineinfo 1.0]
          set b1 [expr [lindex $i 1] + [lindex $i 4]]
          set i [.t dlineinfo 2.0]
          set b2 [expr [lindex $i 1] + [lindex $i 4]]
          set i [.t dlineinfo 2.end]
          set b3 [expr [lindex $i 1] + [lindex $i 4]]
          set i [.t dlineinfo 3.0]
          set b4 [expr [lindex $i 1] + [lindex $i 4]]
          .t configure -spacing1 4 -spacing2 4 -spacing3 4
          .t tag configure x -spacing1 1 -spacing2 2 -spacing3 3
          .t tag add x 1.0 end
          .t tag configure y -spacing1 0 -spacing2 3
          .t tag add y 2.19 end
          .t tag raise y
          set i [.t dlineinfo 1.0]
          set b1 [expr [lindex $i 1] + [lindex $i 4] - $b1]
          set i [.t dlineinfo 2.0]
          set b2 [expr [lindex $i 1] + [lindex $i 4] - $b2]
          set i [.t dlineinfo 2.end]
          set b3 [expr [lindex $i 1] + [lindex $i 4] - $b3]
          set i [.t dlineinfo 3.0]
          set b4 [expr [lindex $i 1] + [lindex $i 4] - $b4]
          list $b1 $b2 $b3 $b4
      
      ---- Result was:
      1.0 5.0 13.0 16.0
      ---- Result should have been:
      1 5 13 16
      ==== textDisp-2.23 FAILED
      
      ==== textDisp-24.9 TkTextCharLayoutProc, line ends with space FAILED
      ==== Contents of test case:
      
          .t configure -wrap char
          .t delete 1.0 end
          .t insert 1.0 "a b c d e f g h i j k l m n o p"
          wm geom . [expr $width-6]x$height
          update
          list [.t bbox 1.19] [.t bbox 1.20]
      
      ==== Test generated error:
      bad geometry specifier "244.0x140"
      ---- Result should have been:
      {136 3 5 13} {3 16 7 13}
      ==== textDisp-24.9 FAILED
      
      unixEmbed.test
      
      ==== unixEmbed-1.3 TkpUseWindow procedure, inheriting colormap FAILED
      ==== Contents of test case:
      
          catch {destroy .t}
          catch {destroy .x}
          toplevel .t -colormap new
          wm geometry .t +0+0
          eatColors .t.t
          frame .t.f -container 1
          toplevel .x -use [winfo id .t.f]
          set result [colorsFree .x]
          destroy .t
          set result
      
      ==== Test generated error:
      expected integer but got "0.0"
      ---- Result should have been:
      0
      ==== unixEmbed-1.3 FAILED
      
      ==== unixEmbed-1.4 TkpUseWindow procedure, inheriting colormap FAILED
      ==== Contents of test case:
      
          catch {destroy .t}
          catch {destroy .t2}
          catch {destroy .x}
          toplevel .t -container 1 -colormap new
          wm geometry .t +0+0
          eatColors .t2
          toplevel .x -use [winfo id .t]
          set result [colorsFree .x]
          destroy .t
          set result
      
      ==== Test generated error:
      expected integer but got "0.0"
      ---- Result should have been:
      1
      ==== unixEmbed-1.4 FAILED
      
      ==== unixEmbed-5.1 EmbedFocusProc procedure, FocusIn events FAILED
      ==== Contents of test case:
      
          foreach w [winfo child .] {
              catch {destroy $w}
          }
          frame .f1 -container 1 -width 200 -height 50
          pack .f1
          dobg "set w1 [winfo id .f1]"
          dobg {
              eval destroy [winfo child .]
              toplevel .t1 -use $w1
              bind .t1 <FocusIn> {lappend x "focus in %W"}
              bind .t1 <FocusOut> {lappend x "focus out %W"}
              set x {}
          }
          focus -force .f1
          update
          dobg {set x}
      
      ==== Test generated error:
      error flushing "file10": broken pipe
      ---- Result should have been:
      {focus in .t1}
      ==== unixEmbed-5.1 FAILED
      
      ==== unixEmbed-5.2 EmbedFocusProc procedure, focusing on dead window
      FAILED
      ==== Contents of test case:
      
          foreach w [winfo child .] {
              catch {destroy $w}
          }
          frame .f1 -container 1 -width 200 -height 50
          pack .f1
          dobg "set w1 [winfo id .f1]"
          dobg {
              eval destroy [winfo child .]
              toplevel .t1 -use $w1
          }
          update
          dobg {
              after 200 {destroy .t1}
          }
          after 400
          focus -force .f1
          update
      
      ==== Test generated error:
      error flushing "file10": broken pipe
      ---- Result should have been:
      
      ==== unixEmbed-5.2 FAILED
      
      ==== unixEmbed-5.3 EmbedFocusProc procedure, FocusOut events FAILED
      ==== Contents of test case:
      
          foreach w [winfo child .] {
              catch {destroy $w}
          }
          frame .f1 -container 1 -width 200 -height 50
          pack .f1
          dobg "set w1 [winfo id .f1]"
          dobg {
              eval destroy [winfo child .]
              toplevel .t1 -use $w1
              bind .t1 <FocusIn> {lappend x "focus in %W"}
              bind .t1 <FocusOut> {lappend x "focus out %W"}
              set x {}
          }
          focus -force .f1
          update
          set x [dobg {update; set x}]
          focus .
          update
          list $x [dobg {update; set x}]
      
      ==== Test generated error:
      error flushing "file10": broken pipe
      ---- Result should have been:
      {{focus in .t1}} {{focus in .t1} {focus out .t1}}
      ==== unixEmbed-5.3 FAILED
      
      ==== unixEmbed-6.1 EmbedGeometryRequest procedure, window changes size
      FAILED
      ==== Contents of test case:
      
          foreach w [winfo child .] {
              catch {destroy $w}
          }
          frame .f1 -container 1 -width 200 -height 50
          pack .f1
          dobg "set w1 [winfo id .f1]"
          dobg {
              eval destroy [winfo child .]
              toplevel .t1 -use $w1
          }
          update
          dobg {
              bind .t1 <Configure> {lappend x {configure .t1 %w %h}}
              set x {}
              .t1 configure -width 300 -height 120
              update
              list $x [winfo geom .t1]
          }
      
      ==== Test generated error:
      error flushing "file10": broken pipe
      ---- Result should have been:
      {{configure .t1 300 120}} 300x120+0+0
      ==== unixEmbed-6.1 FAILED
      
      ==== unixEmbed-6.2 EmbedGeometryRequest procedure, window changes size
      FAILED
      ==== Contents of test case:
      
          foreach w [winfo child .] {
              catch {destroy $w}
          }
          frame .f1 -container 1 -width 200 -height 50
          place .f1 -width 200 -height 200
          dobg "set w1 [winfo id .f1]"
          dobg {
              eval destroy [winfo child .]
              toplevel .t1 -use $w1
          }
          after 300 {set x done}
          vwait x
          dobg {
              bind .t1 <Configure> {lappend x {configure .t1 %w %h}}
              set x {}
              .t1 configure -width 300 -height 120
              update
              list $x [winfo geom .t1]
          }
      
      ==== Test generated error:
      error flushing "file10": broken pipe
      ---- Result should have been:
      {{configure .t1 200 200}} 200x200+0+0
      ==== unixEmbed-6.2 FAILED
      
      ==== unixEmbed-7.1 TkpRedirectKeyEvent procedure, forward keystroke
      FAILED
      ==== Contents of test case:
      
          foreach w [winfo child .] {
              catch {destroy $w}
          }
          frame .f1 -container 1 -width 200 -height 50
          pack .f1
          dobg "set w1 [winfo id .f1]"
          dobg {
              eval destroy [winfo child .]
              toplevel .t1 -use $w1
          }
          focus -force .
          bind . <KeyPress> {lappend x {key %A %E}}
          set x {}
          set y [dobg {
              update
              bind .t1 <KeyPress> {lappend y {key %A}}
              set y {}
              event generate .t1 <KeyPress> -keysym a
              set y
          }]
          update
          bind . <KeyPress> {}
          list $x $y
      
      ==== Test generated error:
      error flushing "file10": broken pipe
      ---- Result should have been:
      {{key a 1}} {}
      ==== unixEmbed-7.1 FAILED
      
      ==== unixEmbed-7.2 TkpRedirectKeyEvent procedure, don't forward
      keystroke width FAILED
      ==== Contents of test case:
      
          foreach w [winfo child .] {
              catch {destroy $w}
          }
          frame .f1 -container 1 -width 200 -height 50
          pack .f1
          dobg "set w1 [winfo id .f1]"
          dobg {
              eval destroy [winfo child .]
              toplevel .t1 -use $w1
          }
          update
          focus -force .f1
          update
          bind . <KeyPress> {lappend x {key %A}}
          set x {}
          set y [dobg {
              update
              bind .t1 <KeyPress> {lappend y {key %A}}
              set y {}
              event generate .t1 <KeyPress> -keysym b
              set y
          }]
          update
          bind . <KeyPress> {}
          list $x $y
      
      ==== Test generated error:
      error flushing "file10": broken pipe
      ---- Result should have been:
      {} {{key b}}
      ==== unixEmbed-7.2 FAILED
      
      ==== unixEmbed-8.1 TkpClaimFocus procedure FAILED
      ==== Contents of test case:
      
          foreach w [winfo child .] {
              catch {destroy $w}
          }
          frame .f1 -container 1 -width 200 -height 50
          frame .f2 -width 200 -height 50
          pack .f1 .f2
          dobg "set w1 [winfo id .f1]"
          dobg {
              eval destroy [winfo child .]
              toplevel .t1 -use $w1 -highlightthickness 2 -bd 2 -relief sunken
          }
          focus -force .f2
          update
          list [dobg {
              focus .t1
              set x [list [focus]]
              update
              after 500
              update
              lappend x [focus]
          }] [focus]
      
      ==== Test generated error:
      error flushing "file10": broken pipe
      ---- Result should have been:
      {{} .t1} .f1
      ==== unixEmbed-8.1 FAILED
      
      ==== unixEmbed-9.2 EmbedWindowDeleted procedure, check embeddedPtr
      FAILED
      ==== Contents of test case:
      
          foreach w [winfo child .] {
              catch {destroy $w}
          }
          frame .f1 -container 1 -width 200 -height 50
          pack .f1
          dobg "set w1 [winfo id .f1]"
          dobg {
              eval destroy [winfo child .]
              toplevel .t1 -use $w1 -highlightthickness 2 -bd 2 -relief sunken
              set x {}
              lappend x [testembed]
              destroy .t1
              lappend x [testembed]
          }
      
      ==== Test generated error:
      error flushing "file10": broken pipe
      ---- Result should have been:
      {{XXX {} {} .t1}} {}
      ==== unixEmbed-9.2 FAILED
      
      unixFont.test
      
      ==== unixfont-5.4 Tk_MeasureChars procedure: reached right edge FAILED
      ==== Contents of test case:
      
          .b.l config -text "0000000000000"
          getsize
      
      ---- Result was:
      60 26
      ---- Result should have been:
      60.0 26
      ==== unixfont-5.4 FAILED
      
      ==== unixfont-5.5 Tk_MeasureChars procedure: ran out of chars FAILED
      ==== Contents of test case:
      
          .b.l config -text "000000"
          getsize
      
      ---- Result was:
      36 13
      ---- Result should have been:
      36.0 13
      ==== unixfont-5.5 FAILED
      
      ==== unixfont-5.6 Tk_MeasureChars procedure: find last word FAILED
      ==== Contents of test case:
      
          .b.l config -text "000000 00000"
          getsize
      
      ---- Result was:
      36 26
      ---- Result should have been:
      36.0 26
      ==== unixfont-5.6 FAILED
      
      ==== unixfont-5.7 Tk_MeasureChars procedure: already saw space in line
      FAILED
      ==== Contents of test case:
      
          .b.l config -text "000000     00000"
          getsize
      
      ---- Result was:
      36 26
      ---- Result should have been:
      36.0 26
      ==== unixfont-5.7 FAILED
      
      ==== unixfont-5.8 Tk_MeasureChars procedure: internal spaces significant
      FAILED
      ==== Contents of test case:
      
          .b.l config -text "00  000     00000"
          getsize
      
      ---- Result was:
      42 26
      ---- Result should have been:
      42.0 26
      ==== unixfont-5.8 FAILED
      
      ==== unixfont-5.10 Tk_MeasureChars procedure: TK_AT_LEAST_ONE FAILED
      ==== Contents of test case:
      
          .b.l config -text "000000000000"
          getsize
      
      ---- Result was:
      60 26
      ---- Result should have been:
      60.0 26
      ==== unixfont-5.10 FAILED
      
      ==== unixfont-5.11 Tk_MeasureChars: TK_AT_LEAST_ONE + not even one char
      fit! FAILED
      ==== Contents of test case:
      
          set a [.b.l cget -wrap]
          .b.l config -text "000000" -wrap 1
          set x [getsize]
          .b.l config -wrap $a
          set x
      
      ---- Result was:
      6 78
      ---- Result should have been:
      6 78.0
      ==== unixfont-5.11 FAILED
      
      ==== unixfont-5.12 Tk_MeasureChars procedure: include eol spaces FAILED
      ==== Contents of test case:
      
          .b.l config -text "000   \n000"
          getsize
      
      ---- Result was:
      36 26
      ---- Result should have been:
      36.0 26
      ==== unixfont-5.12 FAILED
      
      ==== unixfont-8.4 AllocFont procedure: classify characters FAILED
      ==== Contents of test case:
      
          set x 0
          incr x [font measure $courier "\u4000"]   ;# 6
          incr x [font measure $courier "\002"]   ;# 4
          incr x [font measure $courier "\012"]   ;# 2
          incr x [font measure $courier "\101"]   ;# 1
          set x
      
      ---- Result was:
      78
      ---- Result should have been:
      78.0
      ==== unixfont-8.4 FAILED
      
      ==== unixfont-8.6 AllocFont procedure: setup widths of special chars
      FAILED
      ==== Contents of test case:
      
          set x 0
          incr x [font measure $courier "\001"]   ;# 4
          incr x [font measure $courier "\002"]   ;# 4
          incr x [font measure $courier "\012"]   ;# 2
          set x
      
      ---- Result was:
      60
      ---- Result should have been:
      60.0
      ==== unixfont-8.6 FAILED
      
      unixMenu.test
      unixSend.test
      
      ==== unixSend-10.19 SendEventProc procedure, send exits FAILED
      ==== Contents of test case:
      
              setupbg
              dobg {tk appname t_s_3}
              set x [list [catch {send t_s_3 exit} msg] $msg]
              close $fd
              set x
      
      ==== Test generated error:
      can not find channel named "file7"
      ---- Result should have been:
      1 {target application died}
      ==== unixSend-10.19 FAILED
      
      ==== unixSend-12.2 TimeoutProc procedure FAILED
      ==== Contents of test case:
      
          winfo interps
          tk appname tktest
          update
          setupbg
          puts $fd {after 10 {after 5000; exit}; puts [tk appname]; puts
      **DONE**; flush stdout}
          set ::test::bgDone 0
          set ::test::bgData {}
          flush $fd
          tkwait variable ::test::bgDone
          set app $::test::bgData
          after 200
          set result [list [catch {send $app foo} msg] $msg]
          close $fd
          set result
      
      ==== Test generated error:
      can not find channel named "file7"
      ---- Result should have been:
      1 {target application died}
      ==== unixSend-12.2 FAILED
      
      unixWm.test
      
      ==== unixWm-2.1 moving window while mapped FAILED
      ==== Contents of test case:
      
              wm geom .t $geom
              update
              scan [wm geom .t] %dx%d%1s%d%1s%d width height xsign x ysign y
              format "%s%d%s%d" $xsign [eval expr $x$xsign$xerr] $ysign  [eval
      expr $y$ysign$yerr]
      
      ==== Test generated error:
      expected integer but got "20.0"
      ---- Result should have been:
      +20+80
      ==== unixWm-2.1 FAILED
      
      ==== unixWm-2.2 moving window while mapped FAILED
      ==== Contents of test case:
      
              wm geom .t $geom
              update
              scan [wm geom .t] %dx%d%1s%d%1s%d width height xsign x ysign y
              format "%s%d%s%d" $xsign [eval expr $x$xsign$xerr] $ysign  [eval
      expr $y$ysign$yerr]
      
      ==== Test generated error:
      expected integer but got "80.0"
      ---- Result should have been:
      +80+20
      ==== unixWm-2.2 FAILED
      
      ==== unixWm-2.7 moving window while mapped FAILED
      ==== Contents of test case:
      
              wm geom .t $geom
              update
              scan [wm geom .t] %dx%d%1s%d%1s%d width height xsign x ysign y
              format "%s%d%s%d" $xsign [eval expr $x$xsign$xerr] $ysign  [eval
      expr $y$ysign$yerr]
      
      ==== Test generated error:
      expected integer but got "10.0"
      ---- Result should have been:
      -10-5
      ==== unixWm-2.7 FAILED
      
      ==== unixWm-2.8 moving window while mapped FAILED
      ==== Contents of test case:
      
              wm geom .t $geom
              update
              scan [wm geom .t] %dx%d%1s%d%1s%d width height xsign x ysign y
              format "%s%d%s%d" $xsign [eval expr $x$xsign$xerr] $ysign  [eval
      expr $y$ysign$yerr]
      
      ==== Test generated error:
      expected integer but got "10.0"
      ---- Result should have been:
      -10+5
      ==== unixWm-2.8 FAILED
      
      ==== unixWm-2.9 moving window while mapped FAILED
      ==== Contents of test case:
      
              wm geom .t $geom
              update
              scan [wm geom .t] %dx%d%1s%d%1s%d width height xsign x ysign y
              format "%s%d%s%d" $xsign [eval expr $x$xsign$xerr] $ysign  [eval
      expr $y$ysign$yerr]
      
      ==== Test generated error:
      expected integer but got "10.0"
      ---- Result should have been:
      +10-5
      ==== unixWm-2.9 FAILED
      
      ==== unixWm-3.1 moving window while iconified FAILED
      ==== Contents of test case:
      
              wm iconify .t
              sleep 200
              wm geom .t $geom
              update
              wm deiconify .t
              scan [wm geom .t] %dx%d%1s%d%1s%d width height xsign x ysign y
              format "%s%d%s%d" $xsign [eval expr $x$xsign$xerr] $ysign  [eval
      expr $y$ysign$yerr]
      
      ==== Test generated error:
      expected integer but got "20.0"
      ---- Result should have been:
      +20+80
      ==== unixWm-3.1 FAILED
      
      ==== unixWm-3.2 moving window while iconified FAILED
      ==== Contents of test case:
      
              wm iconify .t
              sleep 200
              wm geom .t $geom
              update
              wm deiconify .t
              scan [wm geom .t] %dx%d%1s%d%1s%d width height xsign x ysign y
              format "%s%d%s%d" $xsign [eval expr $x$xsign$xerr] $ysign  [eval
      expr $y$ysign$yerr]
      
      ==== Test generated error:
      expected integer but got "80.0"
      ---- Result should have been:
      +80+20
      ==== unixWm-3.2 FAILED
      
      ==== unixWm-3.7 moving window while iconified FAILED
      ==== Contents of test case:
      
              wm iconify .t
              sleep 200
              wm geom .t $geom
              update
              wm deiconify .t
              scan [wm geom .t] %dx%d%1s%d%1s%d width height xsign x ysign y
              format "%s%d%s%d" $xsign [eval expr $x$xsign$xerr] $ysign  [eval
      expr $y$ysign$yerr]
      
      ==== Test generated error:
      expected integer but got "10.0"
      ---- Result should have been:
      -10-5
      ==== unixWm-3.7 FAILED
      
      ==== unixWm-3.8 moving window while iconified FAILED
      ==== Contents of test case:
      
              wm iconify .t
              sleep 200
              wm geom .t $geom
              update
              wm deiconify .t
              scan [wm geom .t] %dx%d%1s%d%1s%d width height xsign x ysign y
              format "%s%d%s%d" $xsign [eval expr $x$xsign$xerr] $ysign  [eval
      expr $y$ysign$yerr]
      
      ==== Test generated error:
      expected integer but got "10.0"
      ---- Result should have been:
      -10+5
      ==== unixWm-3.8 FAILED
      
      ==== unixWm-3.9 moving window while iconified FAILED
      ==== Contents of test case:
      
              wm iconify .t
              sleep 200
              wm geom .t $geom
              update
              wm deiconify .t
              scan [wm geom .t] %dx%d%1s%d%1s%d width height xsign x ysign y
              format "%s%d%s%d" $xsign [eval expr $x$xsign$xerr] $ysign  [eval
      expr $y$ysign$yerr]
      
      ==== Test generated error:
      expected integer but got "10.0"
      ---- Result should have been:
      +10-5
      ==== unixWm-3.9 FAILED
      
      bad geometry specifier "+100.0+200"
      
      visual.test
      expected integer but got "0.0"
      
      winfo.test
      
      ==== winfo-3.4 "winfo colormapfull" command FAILED
      ==== Contents of test case:
      
              eatColors .t {-colormap new}
              set result [list [winfo colormapfull .] [winfo colormapfull .t]]
              .t.c delete 34
              lappend result [winfo colormapfull .t]
              .t.c create rectangle 30 30 80 80 -fill #441739
              lappend result [winfo colormapfull .t]
              .t.c create rectangle 40 40 90 90 -fill #ffeedd
              lappend result [winfo colormapfull .t]
              destroy .t.c
              lappend result [winfo colormapfull .t]
      
      ==== Test generated error:
      expected integer but got "0.0"
      ---- Result should have been:
      0 1 0 0 1 0
      ==== winfo-3.4 FAILED
      
      This application hasn't been compiled with the testwrapper command,
      therefore I am skipping all of these tests.
      
      Tests ended at Mon Mar 29 13:20:52 EST 1999
      all.tcl:        Total   6054    Passed  5844    Skipped 163     Failed
      47
      Sourced 68 Test Files.
      Files with failing tests: canvText.test clipboard.test config.test
      focus.test grid.test main.test safe.test send.test textDisp.test
      unixEmbed.test unixFont.test unixSend.test util.test winfo.test

  DesiredBehavior:
      I would expect that tests should succeed.


  Marked tests nonPortable:
  canvText-6.1
  config-8.9
  grid-6.9

  Already fixed bug in test suite or source code:
  main-1.1: bug in test
  safe-5.1: bug in interp deletion

  Haven't reproduced these yet:
  focus-6.1
  clipboard-6.2
  send-8.1,10.19,12.2
  textDisp-2.22,2.23,24.9
  unixEmbed 1.3,1.4: I think these were fixed.

  We fixed a bug in how integer values get returned in Tcl8.1b2.  This fix probably fixed many of the other failures.
  -hershey

  This has narrowed down to 2 test suite failures for Larry in 8.1.1
  in the related bug id. 
  -- 08/31/1999 hobbs


tkt_uuid: 1881892fffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 38. [tk_messageBox]
priority: 5 Medium
foundin: obsolete: 8.5.0
resolution: Fixed
title: Incorrect default title for tk_messageBox on Windows
comment:
  The default title if you don't specify a "-title" is "Error", whereas according to the manual page (and other platforms) it should be the empty string.


tkt_uuid: 525728ffffffffffffffffffffffffffffffffff
type: Bug
status: Open
subsystem: 68. Win Window Operations
priority: 5 Medium
foundin: obsolete: 8.3.4
resolution: None
title: window resize handles hiccup
comment:
  On m.s. windows the resize handles seem to have 
  a "hole" where they suddenly change back to the 
  original pointer (e.g. an arrow) as you move the mouse 
  over the left, right, or bottom edge (but strangely, 
  not the top edge - i.e. at the title). Also the 
  diagonal lower right corner.

  To duplicate, simply run wish so you have the . window 
  open. No code needed. However, this occurs on all 
  toplevel windows.

  Now, move the mouse left and right over the right hand 
  border. 

  You will see the cursor change to <--> then blink back 
  to the pointer, then the <--> a second time, then 
  finally back to the cursor. This happens on all tcl/tk 
  windows maybe 50% of the time. 

  This makes it difficult to grab hold of the windows 
  edge to resize it.


  In all other windows apps (i.e. not tcl/tk), this does 
  not occur.

  But tcl/tk seems to have a hole in the middle, where 
  it might be losing focus or something. Often if you 
  have the mouse positioned to resize, then press the 
  mouse button, the slight movement (say 1 pixel) is 
  enough to have the cursor change before you can "grab" 
  it.


tkt_uuid: 2949774fffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 12. Unix Menus
priority: 5 Medium
foundin: obsolete: 8.6b1.1
resolution: Fixed
title: Cascade menus not unposted
comment:
  TIP 360 seems to have introduced a problem with cascade menus not being unposted when traversing a menu. This is an example:

  menu .m -tearoff 0
  . configure -menu .m
  .m add cascade -label M -menu .m.m
  menu .m.m -tearoff 0
  .m.m add cascade -label A -menu .m.m.a
  .m.m add command -label B
  .m.m add command -label C
  menu .m.m.a -tearoff 0
  .m.m.a add command -label X
  .m.m.a add command -label Y

  Now click on the menubar entry "M", and move the mouse down over the menu. When the pointer is over "A", a submenu appears (which is ok). However, when moving the mouse further down (over the "B" and "C" entries), the submenu should disappear and this does not happen.


tkt_uuid: 2155237fffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 88. Themed Tk
priority: 5 Medium
foundin: obsolete: 8.5.4
resolution: Wont Fix
title: ttk::entry test independence
comment:
  in tests/ttk/entry.test, test
  entry-3.0 defines a number of
  variables which later tests
  need in order to pass, or even
  run without error.  When testing
  options cause entry-3.0 to be
  skipped, things break.

  Tests should be independent.


tkt_uuid: 220587ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 84. Unix Build
priority: 2
foundin: obsolete: 8.2
resolution: Fixed
title: Makefile generated by configure specifies wrong ldAix
comment:
  OriginalBugID: 2624 Bug
  Version: 8.2
  SubmitDate: '1999-08-31'
  LastModified: '1999-09-15'
  Severity: CRIT
  Status: Released
  Submitter: techsupp
  ChangedBy: hobbs
  RelatedBugIDs: 2685
  OS: AIX
  OSVersion: 4.3.3
  Machine: RS6000
  FixedDate: '1999-09-15'
  FixedInVersion: 8.2.1


  Name:
  Dave Marquardt

  Comments:
  I would have modified configure.in if I could have found these lines
      there, but they don't seem to be
      there--I guess the distribution is missing something w.r.t. the
      configuration files and autoconf.

      I thought I'd submitted this bug report before, but I've lost all traces
      of it, and can't find it in the DejaNews archive of postings to
      comp.lang.tcl.

  ReproducibleScript:
  Download tk 8.2 to an AIX 4.3.2 system.  Unpack it.  Change to unix
      subdirectory.  Run

      ./configure --enable-shared

      Run make.  Note that it fails because it specifies ldAix in the TK
      source directory rather than the Tcl
      source directory, where it actually exists.

  ObservedBehavior:
  libtk fails to bind.

      Here are the lines from make's output where ldAix is specified in the
      wrong directory:

              rm -f libtk8.2.so
              /usr/local/src/tk8.2.0/unix/ldAix /bin/ld -bhalt:4 -bM:SRE
      -bE:lib.exp -H512 -T512 -bnoentry -o libtk8.2.so tk3d.o tkArgv.o
      tkAtom.o tkBind.o tkBitmap.o tkClipboard.o tkCmds.o  tkColor.o
      tkConfig.o tkConsole.o tkCursor.o tkError.o tkEvent.o  tkFocus.o
      tkFont.o tkGet.o tkGC.o tkGeometry.o tkGrab.o tkGrid.o  tkMain.o tkObj.o
      tkOldConfig.o tkOption.o tkPack.o tkPlace.o  tkSelect.o tkUtil.o
      tkVisual.o tkWindow.o   tkUnix.o tkUnix3d.o tkUnixButton.o tkUnixColor.o
      tkUnixConfig.o  tkUnixCursor.o tkUnixDraw.o tkUnixEmbed.o tkUnixEvent.o
      tkUnixFocus.o tkUnixFont.o tkUnixInit.o tkUnixKey.o tkUnixMenu.o
      tkUnixMenubu.o tkUnixScale.o tkUnixScrlbr.o tkUnixSelect.o  tkUnixSend.o
      tkUnixWm.o tkUnixXId.o tkStubInit.o tkStubLib.o tkButton.o tkEntry.o
      tkFrame.o tkListbox.o  tkMenu.o tkMenubutton.o tkMenuDraw.o tkMessage.o
      tkScale.o  tkScrollbar.o tkCanvas.o tkCanvArc.o tkCanvBmap.o tkCanvImg.o
       tkCanvLine.o tkCanvPoly.o tkCanvPs.o tkCanvText.o  tkCanvUtil.o
      tkCanvWind.o tkRectOval.o tkT!
      rig.o tkImage.o tkImgBmap.o tkImgGIF.o tkImgPPM.o tkImgPhoto.o tkText.o
      tkTextBTree.o tkTextDisp.o tkTextImage.o tkTextIndex.o  tkTextMark.o
      tkTextTag.o tkTextWind.o -L/usr/local/lib -L/usr/local/src/tcl8.2.0/unix
       -lX11 -ldl -lm -lc
      /bin/sh: /usr/local/src/tk8.2.0/unix/ldAix:  not found.

  DesiredBehavior:
  The generated Makefile should specify an existing copy of ldAix.

  Patch:
  *** configure~  Fri Aug 13 17:06:14 1999
  --- configure   Mon Aug 23 15:22:28 1999
  ***************
  *** 1524,1530 ****
        case $system in
          AIX-4.[2-9])
              SHLIB_CFLAGS=""
  !           SHLIB_LD="$fullSrcDir/ldAix /bin/ld -bhalt:4 -bM:SRE -bE:lib.exp -H512 -T512 -bnoentry"
              SHLIB_LD_LIBS='${LIBS}'
              SHLIB_SUFFIX=".so"
              DL_OBJS="tclLoadDl.o"
  --- 1524,1530 ----
        case $system in
          AIX-4.[2-9])
              SHLIB_CFLAGS=""
  !           SHLIB_LD=$TCL_SHLIB_LD
              SHLIB_LD_LIBS='${LIBS}'
              SHLIB_SUFFIX=".so"
              DL_OBJS="tclLoadDl.o"

  PatchFiles:
  unix/configure



  Fixed. 
  -- 09/15/1999 hobbs


tkt_uuid: 693466ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 80. Release Notes
priority: 9 Immediate
foundin: obsolete: 8.4.2
resolution: Fixed
title: README update for 8.4.2
comment:
  tk/unix/README refers to Tcl 8.4.1 -- ought to be 8.4.2

  tk/macosx/README claims some features were added
  in 8.4.3.  Unless that's a prediction about future
  releases, it should be corrected.


tkt_uuid: 3603397fffffffffffffffffffffffffffffffff
type: Bug
status: Open
subsystem: 88. Themed Tk
priority: 5 Medium
foundin: None
resolution: None
title: ttk::sizegrip should be hidden for maximised windows
comment:
  On MS Windows, the sizegrip should be hidden when the toplevel it's a part of is maximised. This is the default behaviour in all other Windows apps which have a sizegrip. (I can't speak for other OSes/window managers, but it seems more sensible to me in all cases.)

  Failing that, it should at least do nothing (and preferably not change the cursor, either) when the window is maximised - it's very weird that, when the window is maximised, you can drag the sizegrip to alter the size the window will have when deiconified.


tkt_uuid: 1012331fffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 04. Canvas Basics
priority: 5 Medium
foundin: obsolete: 8.5a2
resolution: Fixed
title: canvas-17.1 fails
comment:
  ==== canvas-17.1 default smooth method handling FAILED
  ==== Contents of test case:

      destroy .c; canvas .c
      set id [.c create line {0 0 1 1 2 2 3 3 4 4 5 5 6 6}]
      set result [.c itemcget $id -smooth]
      foreach smoother {yes 1 bezier raw r b} {
          .c itemconfigure $id -smooth $smoother
          lappend result [.c itemcget $id -smooth]
      }

  ---- Result was:

  ---- Result should have been (exact matching):
  0 true true true raw raw true
  ==== canvas-17.1 FAILED


tkt_uuid: 2919709fffffffffffffffffffffffffffffffff
type: Bug
status: Open
subsystem: 13. Win Menus
priority: 5 Medium
foundin: obsolete: 8.5.8
resolution: None
title: Windows menus don't honor Windows theme changes
comment:
  In Windows XP, when the system theme is changes, persistens menus (i.e. submenus of the main application menu) do not honor the change.

  To demonstrate just select and apply some system theme having considerably darker or lighter colors than those of the currently active theme -- the background color of persistent pull-down menus will remain that of the old theme.

  Pat Thoyts proposed that this can be caused by WM_SYSCOLORCHANGE message not being propagated to menus.


tkt_uuid: 500846ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: None
priority: 5 Medium
foundin: obsolete: 8.4a4
resolution: Fixed
title: tktest crashes immediately
comment:
  Platform: SPARC Solaris 2.6 Sun compiler and CDE window
  manager.

  Compiled with debugging.

  When i do a make test, I get this error:
  export LD_LIBRARY_PATH; \
  LIBPATH=`pwd`:/vol/tclsrcsol/tcl84/tcl/unix:; export
  LIBPATH; \
  SHLIB_PATH=`pwd`:/vol/tclsrcsol/tcl84/tcl/unix:; \
  export SHLIB_PATH; \
  TCL_LIBRARY=/vol/tclsrcsol/tcl84/tcl/library; export
  TCL_LIBRARY; \
  TK_LIBRARY=/vol/tclsrcsol/tcl84/tk/library; export
  TK_LIBRARY; \
  ./tktest /vol/tclsrcsol/tcl84/tk/unix/../tests/all.tcl
  -geometry +0+0 \
   
  Segmentation Fault - core dumped
  make: *** [test] Error 1139

  dbx tktest core
  (dbx 7) where
    [1] Tcl_GetString(objPtr = (nil)), line 792 in
  "tclObj.c"
  =>[2] TclGetStartupScriptFileName(), line 178 in
  "tclMain.c"
    [3] Tk_MainEx(argc = 4, argv = 0xefffe39c,
  appInitProc = 0x28cf8 = &Tcl_AppInit(Tcl_Interp
  *interp), interp = 0x48110), line 145 in "tkMain.c"
    [4] main(argc = 4, argv = 0xefffe39c), line 77 in
  "tkAppInit.c"

  TclGetStartupScriptFileName should not call
  Tcl_GetString without checking that the return is
  non-null - or Tcl_GetString should check that the
  pointer given to it is non-null rather than just using
  it.

  Then, of course, there is the whole matter of why
  tclgetstartupscriptpath is returning null...


tkt_uuid: 1323974fffffffffffffffffffffffffffffffff
type: Bug
status: Open
subsystem: 18. [text]
priority: 8
foundin: obsolete: 8.5a4
resolution: None
title: failing tests
comment:
  ==== textDisp-27.7 SizeOfTab procedure, center
  alignment, wrap -none (potential numerical problems) FAILED
  ==== Contents of test case:

      .t delete 1.0 end
      set cm [winfo fpixels .t 1c]
      .t configure -tabs {1c 2c center 3c 4c 5c 6c 7c 8c}
  -wrap none -width 40
      .t insert 1.0
  a\tb\tc\td\te\n012345678934567890a\tbb\tcc\tdd
      set width [expr {$fixedWidth * 19}]
      set tab $cm
      while {$tab < $width} {
          set tab [expr {$tab + $cm}]
      }
      # Now we've calculated to the end of the tab after
  'a', add one
      # more for 'bb\t' and we're there, with 4 for the
  border.  Since
      # Tk_GetPixelsFromObj uses the standard 'int(0.5 +
  float)' rounding,
      # so must we.
      set tab [expr {4 + int(0.5 + $tab + $cm)}]
      update
      set res [.t bbox 2.23]
      lset res 0 [expr {[lindex $res 0] - $tab}]
      set res

  ---- Result was:
  -16 18 7 13
  ---- Result should have been (exact matching):
  -28 18 7 13
  ==== textDisp-27.7 FAILED


  ==== textImage-3.2 delayed image management FAILED
  ==== Contents of test case:

          catch {
              image create photo small -width 5 -height 5
              small put red -to 0 0 4 4
          }
          catch {destroy .t}
          text .t -font test_font -bd 0
  -highlightthickness 0 -padx 0 -pady 0
          pack .t
          .t image create end -name test
          update
          set result ""
          lappend result [.t bbox test]
          .t image configure test -image small -align top
          update
          lappend result [.t bbox test]

  ---- Result was:
  {0 8 0 0} {0 0 5 5}
  ---- Result should have been (exact matching):
  {} {0 0 5 5}
  ==== textImage-3.2 FAILED


tkt_uuid: 220312ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 84. Unix Build
priority: 1 Zero
foundin: obsolete: 8.3.1
resolution: Invalid
title: Compiling fails for Tk 8.3.1
comment:
  OriginalBugID: 5976 Bug
  Version: 8.3.1
  SubmitDate: '2000-07-06'
  LastModified: '2000-08-14'
  Severity: SER
  Status: Closed
  Submitter: techsupp
  ChangedBy: ericm
  OS: Linux
  OSVersion: TurboLinux 6.x
  Machine: custom built AMD K6/450 64 MB RAM, 2 IDE 2 SCSI hard drives, SiS
  ClosedDate: '2000-08-14'


  Name:
  John Buell

  ReproducibleScript:
  Tcl 8.3.1 is already compiled, cannot compile Tk 8.3.1.
  System is TurboLinux 6.x running 2.2.14 kernel and 2.95.3 gcc. 
  Ran this command for configuration:
  ./configure --with-tcl=/root/Software/tcl8.3.1/unix/ --enable-gcc
  then invoked GNU make (3.78.1) with 'make'

  ObservedBehavior:
  received this a couple of times:
  gcc -pipe -c -O -D__NO_STRING_INLINES -D__NO_MATH_INLINES -Wall -Wconversion -Wno-implicit-int -fPIC -I/root/Software/tk8.3.1/unix -I/root/Software/tk8.3.1/unix/../generic -I/root/Software/tk8.3.1/unix/../bitmaps -I/root/Software/tcl8.3.1/generic -I/usr/X11R6/include -DHAVE_UNISTD_H=1 -DHAVE_LIMITS_H=1 -DSTDC_HEADERS=1 -DHAVE_SYS_TIME_H=1 -DTIME_WITH_SYS_TIME=1 -DHAVE_PW_GECOS=1      -DTCL_NO_DEPRECATED   /root/Software/tk8.3.1/unix/../generic/tkCanvPs.c
  {standard input}: Assembler messages:
  {standard input}:4160: Error: no such 386 instruction: `filds'
  {standard input}:4165: Error: no such 386 instruction: `filds'
  {standard input}:4170: Error: no such 386 instruction: `filds'
  {standard input}:4278: Error: no such 386 instruction: `filds'
  {standard input}:4283: Error: no such 386 instruction: `filds'
  {standard input}:4288: Error: no such 386 instruction: `filds'
  {standard input}:4441: Error: no such 386 instruction: `filds'
  {standard input}:4446: Error: no such 386 instruction: `filds'
  {standard input}:4451: Error: no such 386 instruction: `filds'
  make: *** [tkCanvPs.o] Error 1

  This error also crops up if I do NOT specify the --enable-gcc flag for 'configure'

  DesiredBehavior:
  A compiled working copy of Tk 8.3.1 :)



  This looks like a compiler problem, because there is no inlined assembly code in the Tcl/Tk core.  It looks like the compiler is producing bad assembly.  We use gcc 2.91.66 to do our compiles on Linux and we have no problems with that.  I suggest that you try that compiler.

     Eric Melski                            The Other Tcl Guy
     ericm at ajubasolutions.com            Ajuba Solutions

  -- 08/14/2000 ericm


tkt_uuid: 220777ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 48. Geometry Management
priority: 1 Zero
foundin: obsolete: 8.2
resolution: Duplicate
title: pack v grid: Geometry managers contend for control of containers
comment:
  OriginalBugID: 677 Bug
  Version: 8.2
  SubmitDate: '1998-09-11'
  LastModified: '1999-12-14'
  Severity: MED
  Status: Assigned
  Submitter: lfb
  ChangedBy: hobbs
  RelatedBugIDs: 2444
  OS: Linux
  OSVersion: NA
  Machine: NA
  FixedInVersion: NA


  Mixing pack and grid in the same container can cause the two geometry managers to contend for who is going to control the size of the container (unless pack propagate is turned off).  This manifests itself in various ways, usually as an infiinite loop.  On Linux, I have seen this crash the Xserver.



  It looks like we need to register the fact that the first manager is managng that container, and be more graceful when the second manager tries to interfere.  Though I do not think that people should mix geometry managers in the same container, it is more often accident than artiface, and we should handle this more gracefully.  (lfb)


tkt_uuid: 220793ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 13. Win Menus
priority: 5 Medium
foundin: obsolete: 8.1b1
resolution: Invalid
title: Can't add items to system menu on W98
comment:
  OriginalBugID: 1463 Bug
  Version: 8.1b1
  SubmitDate: '1999-03-08'
  LastModified: '1999-11-07'
  Severity: SER
  Status: Assigned
  Submitter: pat
  ChangedBy: hobbs
  OS: Windows 98
  Machine: X86


  Name:
  Christopher Nelson

  ReproducibleScript:
      menu .menubar
      . configure -menu .menubar
      menu .menubar.system
      .menubar.system add command -label "Surprise" -command {puts "Boo!"}

  ObservedBehavior:
  Nothing happens.  I click on the icon in the upper left corner of . and
  I don't see my entry.

  DesiredBehavior:
      I expect my entry to be added to the system menu.


tkt_uuid: 3526668fffffffffffffffffffffffffffffffff
type: RFE
status: Open
subsystem: 28. Utility Functions
priority: 5 Medium
foundin: None
resolution: None
title: Need display boundry info
comment:
  I have an application (filerunner on Sourceforge) that pops up 'tooltips' or balloon help messages.  To do this it needs to know where the display boundries are.  This is especially true of multi head systems.  The code I have written to attempt to determine this is slow, must account for different windowing systems and seems to depend on hidden and unknown (at least to me) timings in the display system and is way too big.

  It seems to me that at some level Tk knows this information and could just put a documented name on it.

  To give an idea of what I needed to do, I have attached the code I wrote.  Just reading the comments should give you an idea of the problem.


tkt_uuid: 220163ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: None
priority: 1 Zero
foundin: obsolete: 8.1b3
resolution: Invalid
title: Docs missing for Tk_BackgroundError API
comment:
  OriginalBugID: 1856 Bug
  Version: 8.1b3
  SubmitDate: '1999-04-16'
  LastModified: '1999-04-28'
  Severity: MED
  Status: Closed
  Submitter: surles
  ChangedBy: kenj
  OS: All
  OSVersion: NA
  Machine: NA
  FixedInVersion: NA
  ClosedDate: '1999-04-28'




  04/28/1999 14:00 - kenj - Former Tk function now incorporated in Tcl. Tcl API documented in the Tcl man pages. Tk usage deprecated.


tkt_uuid: 845189ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 37. [tk_get*File]
priority: 5 Medium
foundin: obsolete: 8.4.4
resolution: Fixed
title: The first call to tk_get*File modifies the following calls
comment:
  On tk-8.4.4 installed on Linux RedHat 7.2 kernel
  2.4.20, the first time you call tk_get*File -filetypes
  "typelist", the program sets the global variable
  data(extUsed) to indicate if -defaultextension option
  has been used with a non-empty value (see file
  tkfbox.tcl of the standard tk release 8.4.4 line1356
  and its 2 following blocks).  No subsequent calls of
  tk_get*File -filetypes "typelist" will change the
  original value of data(extUsed) and the decision to use
  the -defaultextension option will always depend on the
  first call to tk_get*File -filetypes "typelist".

  For example, test.tcl:

  ***************************************
  proc save_as {} {
    set typelist {
      {{Text} {.txt}}
      {{All} {*}}
    }
    set file [tk_getSaveFile -defaultextension .exe
  -filetypes $typelist]
    puts $file
  }

  pack [button .save -text "Save as" -command save_as]
  pack [button .quit -text Quit -command exit]
  set file [tk_getOpenFile -filetypes {"All *"}]
  puts $file

  **************************************
  "wish test.tcl" will add the extension .txt instead of
  .exe when the user press the "Save as" button and type
  a file without extension.  This is due to the fact that
  the call to tk_getOpenFile did not use the
  -defaultextension option and the program will always
  consider that this option is not used when tk_get*File
  is called after.  Commenting out the last two lines of
  the program will let the program behaves as it should.

  My suggestion is to delete the lines 1356 and 1362 ("if
  {![info exists data(extUsed)]} {" and "}") of the file
  tkfbox.tcl to reset data(extUsed) EVERYTIME tk_get*File
  is called according to the value of the current
  -defaultextension option value.

  Michel Pitermann


tkt_uuid: 3069474fffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 85. Win Build
priority: 5 Medium
foundin: None
resolution: Fixed
title: undefined reference to `_TkFinalize
comment:
  patch 3059923 fixes this compiler error by removing usage of SEH on this case (gcc, have_no_seh, win64)

  environment:
  windows7 x64 - gcc-4.5.1 mingw64 - w64 target

  x86_64-w64-mingw32-gcc -shared -O2 -fomit-frame-pointer -DUNICODE -D_UNICODE  -o tk86.dll -pipe            -Wl,--out-implib,libtk86.a tkConsole.o tkUnixMenubu.o tkUnixScale.o xcolors.o xdraw.o xgc.o ximage.o xutil.o tkWin3d.o tkWin32Dll.o tkWinButton.o tkWinClipboard.o tkWinColor.o tkWinConfig.o tkWinCursor.o tkWinDialog.o tkWinDraw.o tkWinEmbed.o tkWinFont.o tkWinImage.o tkWinInit.o tkWinKey.o tkWinMenu.o tkWinPixmap.o tkWinPointer.o tkWinRegion.o tkWinScrlbr.o tkWinSend.o tkWinSendCom.o tkWinWindow.o tkWinWm.o tkWinX.o stubs.o tk3d.o tkArgv.o tkAtom.o tkBind.o tkBitmap.o tkBusy.o tkButton.o tkCanvArc.o tkCanvBmap.o tkCanvImg.o tkCanvLine.o tkCanvPoly.o tkCanvPs.o tkCanvText.o tkCanvUtil.o tkCanvWind.o tkCanvas.o tkClipboard.o tkCmds.o tkColor.o tkConfig.o tkCursor.o tkEntry.o tkError.o tkEvent.o tkFileFilter.o tkFocus.o tkFont.o tkFrame.o tkGC.o tkGeometry.o tkGet.o tkGrab.o tkGrid.o tkImage.o tkImgBmap.o tkImgGIF.o tkImgPNG.o tkImgPPM.o tkImgPhoto.o tkImgPhInstance.o tkImgUtil.o tkListbox.o tkMacWinMenu.o tkMain.o tkMenu.o tkMenubutton.o tkMenuDraw.o tkMessage.o tkPanedWindow.o tkObj.o tkOldConfig.o tkOption.o tkPack.o tkPlace.o tkPointer.o tkRectOval.o tkScale.o tkScrollbar.o tkSelect.o tkStyle.o tkText.o tkTextBTree.o tkTextDisp.o tkTextImage.o tkTextIndex.o tkTextMark.o tkTextTag.o tkTextWind.o tkTrig.o tkUndo.o tkUtil.o tkVisual.o tkStubInit.o tkWindow.o ttkWinMonitor.o ttkWinTheme.o ttkWinXPTheme.o ttkBlink.o ttkButton.o ttkCache.o ttkClamTheme.o ttkClassicTheme.o ttkDefaultTheme.o ttkElements.o ttkEntry.o ttkFrame.o ttkImage.o ttkInit.o ttkLabel.o ttkLayout.o ttkManager.o ttkNotebook.o ttkPanedwindow.o ttkProgress.o ttkScale.o ttkScrollbar.o ttkScroll.o ttkSeparator.o ttkSquare.o ttkState.o ttkTagSet.o ttkTheme.o ttkTrace.o ttkTrack.o ttkTreeview.o ttkWidget.o ttkStubInit.o tk.res.o "/c/pd/tcltk-cvs/tcl/win/libtclstub86.a" -lkernel32 -luser32 -ladvapi32 -lws2_32 -lgdi32 -lcomdlg32 -limm32 -lcomctl32 -lshell32 -luuid -lole32 -loleaut32
  Creating library file: libtk86.atkWin32Dll.o:tkWin32Dll.c:(.text+0x59): undefined reference to `_TkFinalize
  '
  collect2: ld returned 1 exit status
  make: *** [tk86.dll] Error 1


tkt_uuid: 1847018fffffffffffffffffffffffffffffffff
type: Bug
status: Open
subsystem: 67. Unix Window Operations
priority: 8
foundin: obsolete: 8.5b3
resolution: None
title: X Error ...
comment:
  tk8.5b3 compiled under MacOSX Leopard + X11,
  suddenly crashes with:

  X Error of failed request:  BadMatch (invalid parameter attributes)
    Major opcode of failed request:  70 (X_PolyFillRectangle)
    Serial number of failed request:  543
    Current serial number in output stream:  544


tkt_uuid: 1887169fffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 13. Win Menus
priority: 5 Medium
foundin: None
resolution: Accepted
title: small error in menu.n about windows system menu
comment:
  The phrase "This menu has an icon representing a spacebar" is incorrect (well, it was correct before windows 95!).  It's actually the application icon.


tkt_uuid: 594836ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 85. Win Build
priority: 5 Medium
foundin: None
resolution: Invalid
title: Bad graphics corruption
comment:
  Hi,

  I noticed some bad graphics corruption *most* of the latest 
  windows releases.  Listboxes for example are most times initially 
  drawn with half the listbox corrupted - almost black out but with 
  distorted horizontal lines in in.   Noticed this on canvas widgets 
  aswell.

  Selecting and item in the listbox usually takes it away and the box 
  is drawn normally.  Sometimes resizing the wondow removes the 
  garbage from listbox and canvas widgets but mostly just re-
  corrupts thier display.

  Sorry if this has already been long posted.


tkt_uuid: 3600251fffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 18. [text]
priority: 5 Medium
foundin: current: 8.6.0
resolution: Fixed
title: Inappropriate replacement of Mac binding
comment:
  The (trunk and core-8-6-0) library/text.tcl replaced a Mac-only binding to <Control-v> with a binding to <<Paste>>.

  This is inappropriate because on the Mac, <Control-v> does not correspond to <<Paste>>.  The Mac-only binding to <Control-v> scrolls down one page.  This unusual binding is still found in some non-Tk Mac applications.

  I expect the Tk developers are also aware that some other revisions in 8.6.0 have not yet been merged back into the trunk.


tkt_uuid: 1081603fffffffffffffffffffffffffffffffff
type: Bug
status: Open
subsystem: 05. Canvas Items
priority: 5 Medium
foundin: obsolete: 8.4.7
resolution: None
title: Arc item anomalies under Windows
comment:
  WinXP Pro SP2 / ActiveTCL 8.4.7

  Canvas arc items seem to have a few (rounding related?)
  issues that cause various display problems.  The 
  problems are illustrated in the following script:


  =============
  canvas .c -width 400 -height 400
  pack .c

  # four radiused corners
  .c create arc 100 300 200 200 \
      -start 180 -extent 90 -style arc
  .c create arc 100 100 200 200 \
      -start 90 -extent 90 -style arc
  .c create arc 200 100 300 200 \
      -start 0   -extent 90 -style arc
  .c create arc 200 200 300 300 \
      -start 270 -extent 90 -style arc

  # center arc segment
  .c create arc 190 190 210 210 -start 3 -extent 5

  # edge lines
  .c create line 150 100 250 100
  .c create line 150 300 250 300
  .c create line 100 150 100 250
  .c create line 300 150 300 250
  ========

  The code just creates a square with radiused corners 
  and an internal arc segment. Using Windows XP Pro SP2 
  and ActiveTCL 8.4.7, I notice the following:

  1. The arc in the upper left hand corner does not 
  connect with the left hand vertical line (at its 9 o'clock 
  position)
  2. The arc in the lower left hand corner does not 
  connect with the lower horizontal line (at its 6 o'clock 
  position)
  3. The arc draw in the center of the figure (described as 
  a total of 5 included degrees) is drawn as a complete 
  circle.

  If you comment out the "-style arc" option on the first 4 
  arcs and comment out the 4 line segments, you can see 
  some problems with the several of the "corner" arcs with 
  respect to how their endpoints relate to the edges of 
  the "pie slice". For instance, on the lower left hand arc, 
  the 6 o'clock position doesn't quite meet the edge and 
  the 9 o'clock position is drawn a pixel or two past the 
  edge. This, in turn, is what leads to the "gaps" seen in 
  the test program.

  Interestingly, running the same example on the same 
  hardware, but under Linux (in this case, Puppy Linux) 
  everything looks as expected. The outer object 
  boundary appears to be completely connected, and the 
  center arc segment is drawn correctly (not as a 
  complete circle).

  Jeff


tkt_uuid: 220095ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: None
priority: 1 Zero
foundin: obsolete: 8.0.3
resolution: Invalid
title: prowish80 window labeled prowish80.bin
comment:
  OriginalBugID: 423 Bug
  Version: 1.0b8
  SubmitDate: '1998-08-24'
  LastModified: '1999-12-14'
  Severity: LOW
  Status: Closed
  Submitter: hershey
  ChangedBy: hobbs
  RelatedBugIDs: 1013
  OS: All
  OSVersion: NA
  Machine: NA
  FixedInVersion: NA
  ClosedDate: '1999-12-14'


  when I run prowish80, I get a main window labeled "prowish80.bin".

  This is because it's derived from the appname, no other
  title was specified.  Was there another desired behavior? 
  -- 12/14/1999 hobbs


tkt_uuid: 726351ffffffffffffffffffffffffffffffffff
type: Bug
status: Open
subsystem: 12. Unix Menus
priority: 5 Medium
foundin: obsolete: 8.4.2
resolution: None
title: Toplevel menu doesn't request height.
comment:
  Has been observed with Linux + KDE and Linux + 
  WindowMaker.

  [code]
  global var lbvar
  set lbvar 
  {}
  listbox .lstbx -height 20 -listvar lbvar
  for {set z 0} {$z < 19} 
  {incr z} {lappend lbvar $z}
  lappend lbvar "Try to make me 
  smaller"
  pack .lstbx

  if {$argc} {
   menu .foo
   .foo 
  add cascade -label "Bar" -menu .bar
   menu .bar -type normal -
  tearoff 0
   .bar add command -label "Barian" -command {}
   . 
  configure -menu .foo
  }

  update

  wm minsize . 
  [winfo reqwidth .] [winfo reqheight .]
  [/code]


tkt_uuid: 220680ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 36. [tk_chooseDirectory]
priority: 5 Medium
foundin: obsolete: 8.3.1
resolution: Fixed
title: UNIX tk_chooseDirectory uses incorrect syntax for -mustexist
comment:
  OriginalBugID: 4182 Bug
  Version: 8.3
  SubmitDate: '2000-02-15'
  LastModified: '2000-02-15'
  Severity: MED
  Status: Released
  Submitter: ericm
  ChangedBy: ericm
  OS: All Unix
  FixedDate: '2000-02-15'


  On Windows, tk_chooseDirectory allows the specification of the -mustexist parameter, which requires that a boolean value be specified (ie, "-mustexist true" or "-mustexist false").  The documentation for the command confirms this behavior.

  On UNIX, -mustexist is treated as a flag, so its absence is equivalent to "-mustexist false" on Windows, and its presence is equivalent to "-mustexist true" on Windows.

  The UNIX implementation, therefore, is incompatible with the Windows implementation.  Because the Windows implementation is a native widget and cannot be changed, the UNIX implementation should be corrected to use the same syntax.

  A workaround is to wrap the call to tk_chooseDirectory with a platform dependancy check:

  if { $::tcl_platform(platform) == "windows" } {
  tk_chooseDirectory -mustexist true -intialdir ...
  } else {
  tk_chooseDirectory -mustexist -initialdir ...
  }

  Note that "-mustexist false" is assumed by both implementations if nothing is specified, so if the usage does not require -mustexist to be true, then it is adequate to simply omit the flag.  This will work across platforms.

  - eric



  This is fixed in the CVS repository.  The UNIX implementation was altered to handle -mustexist the same way it is handled on Windows.

  - eric


tkt_uuid: 220262ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 23. Option Parsing
priority: 1 Zero
foundin: obsolete: 8.0p2
resolution: Invalid
title: strange values for abbrievated options from the configure widget command
comment:
  OriginalBugID: 3811 Bug
  Version: 8.0p2
  SubmitDate: '1999-12-08'
  LastModified: '1999-12-09'
  Severity: MED
  Status: Closed
  Submitter: techsupp
  ChangedBy: hobbs
  OS: Solaris
  Machine: SunOS  5.6 Generic_105181-13 sun4m sparc SUNW,SPARCstation-10
  ClosedDate: '1999-12-09'


  Name: Drew Gutstein

  ReproducibleScript:
  This bug is very easy to reproduce and effects most tk widgets.  In this example I created a label and called that widgets configure command with no arguments.  The result is the usual big list of options and their values but abrievated options such as -bg, -fg, and -bd  have a different format.

  Here's the example:

  /u/drew> prowish80
  % label .l
  .l
  % .l configure
  {-anchor anchor Anchor center center} {-background background Background #d9d9d9 #AE00B200C300} {-bd borderWidth} {-bg background} {-bitmap bitmap Bitmap {} {}} {-borderwidth borderWidth BorderWidth 2 2} {-cursor cursor Cursor {} {}} {-fg foreground} {-font font Font {Helvetica -12 bold} {-dt-interface user-medium-r-normal-s*-*-*-*-*-*-*-*-*}} {-foreground foreground Foreground Black #000000000000} {-height height Height 0 0} {-highlightbackground highlightBackground HighlightBackground #d9d9d9 #d9d9d9} {-highlightcolor highlightColor HighlightColor Black Black} {-highlightthickness highlightThickness HighlightThickness 0 0} {-image image Image {} {}} {-justify justify Justify center center} {-padx padX Pad 1 1} {-pady padY Pad 1 1} {-relief relief Relief flat flat} {-takefocus takeFocus TakeFocus 0 0} {-text text Text {} {}} {-textvariable textVariable Variable {} {}} {-underline underline Underline -1 -1} {-width width Width 0 0} {-wraplength wrapLength WrapLength 0 0}
  %

  ObservedBehavior:
  Instead of the usual five element list you get a two element list which looks something like this: 
   {-bd borderWidth}.
  -bg, -fg, and -bd seem to be the only options which are synonyms for other options, so the problem is easy worked around.

  DesiredBehavior:
  the configure command shoud use the same format for abrievated options as is does when you call configure with just the single argument like this
  % .l configure -bd
  -borderwidth borderWidth BorderWidth 2 2
  %



  This is the designed and desired behavior, so you can introspect
  and see what are also valid synonyms (any options with llength==2).
  This is as documented. 
  -- 12/09/1999 hobbs


tkt_uuid: 1193614fffffffffffffffffffffffffffffffff
type: Patch
status: Closed
subsystem: 66. Aqua Window Operations
priority: 5 Medium
foundin: None
resolution: Fixed
title: Aqua message box key bindings
comment:
  Two fixes for the native aqua tk_messageBox:
  1) whitespace police
  2) added Apple standard key bindings to dialog

  Mats


tkt_uuid: 1656283fffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 74. Application Embedding
priority: 5 Medium
foundin: obsolete: 8.5a5
resolution: Fixed
title: comment in tkInitScript.h is incorrect
comment:
  The following comment in $tk_src_dir/generic/tkInitScript.h is incorrect, $tcl_library/../tk$tk_version is _not_ a directory that is searched.  This directory is often included by coincidence, because it's often a subdir of auto_path, but it's not actually searched for directly.  Look at the logic in tcl_findLibrary to verify.

  " * In order to find tk.tcl during initialization, the following script is
  * invoked by Tk_Init(). It looks in several different directories:
  *
  * $tk_library - can specify a primary location, if set no
  * other locations will be checked
  *
  * $env(TK_LIBRARY) - highest priority so user can always override
  * the search path unless the application has
  * specified an exact directory above
  *
  * $tcl_library/../tk$tk_version
  * - look relative to init.tcl in an installed
  * lib directory (e.g. /usr/local)
  "


tkt_uuid: 220629ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 07. [entry]
priority: 2
foundin: obsolete: 8.2.2
resolution: Fixed
title: Body of tkEntrySeeInsert
comment:
  OriginalBugID: 3696 Bug
  Version: 8.2.2
  SubmitDate: '1999-11-29'
  LastModified: '1999-11-29'
  Severity: LOW
  Status: Released
  Submitter: techsupp
  ChangedBy: hobbs
  OS: Linux-SuSE
  FixedDate: '1999-11-29'
  FixedInVersion: 8.3b1


  Name:
  Csaba Nemethi

  ObservedBehavior:
  In Tk 8.2.2, the body of the tkEntrySeeInsert procedure in the file entry.tcl has been changed by eliminating a while loop.  The new version is, however, much more complicated than it should be.

  DesiredBehavior:
  Here is the improved code:

  proc tkEntrySeeInsert w {
      set c [$w index insert]
      if {($c < [$w index @0]) || ($c > [$w index @[winfo width $w]])} {
  $w xview $c
      }
  }



  updated in 8.3 
  -- 11/29/1999 hobbs


tkt_uuid: 220116ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 61. Safe Tk
priority: 1 Zero
foundin: obsolete: 8.1a2
resolution: Invalid
title: safeTk does not clean up the safe::tkInit array when the interpreter is deleted
comment:
  OriginalBugID: 938 Bug
  Version: 8.1a2
  SubmitDate: '1998-12-07'
  LastModified: '2000-04-03'
  Severity: SER
  Status: Closed
  Submitter: stanton
  ChangedBy: ericm
  RelatedBugIDs: 1523
  OS: All
  OSVersion: NA
  Machine: NA
  FixedInVersion: NA
  ClosedDate: '2000-04-03'


  The safe::tkInit array may contain stale information because it is not cleared when an interpreter is deleted.  This may lead to the arguments for one safeTk instance being installed into another instance.



  This looks like it was fixed along with Bug 1523.

  - eric
   
  -- 04/03/2000 ericm


tkt_uuid: 219907ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 69. Events
priority: 1 Zero
foundin: obsolete: 8.0.3
resolution: Duplicate
title: tk window configure -cursor option does not report valid options
comment:
  OriginalBugID: 841 Bug
  Version: 8.0.3
  SubmitDate: '1998-11-24'
  LastModified: '1999-08-14'
  Severity: MED
  Status: Closed
  Submitter: pat
  ChangedBy: hobbs
  RelatedBugIDs: 945
  OS: All
  OSVersion: NA
  Machine: NA
  FixedInVersion: NA
  ClosedDate: '1999-08-14'


   > Name:  Larry W. Virden
   > email:  lvirden@cas.org
   > Support:  Upgrade
   > Severity:  3
   > OperatingSystem:  Sun Solaris
   > OperatingSystemVersion:  2.6
   > Extensions:  tk
   > CustomShell:  none
   > Interpreter:  Wish
   > InterpreterVersion:  whatever version prowish80 is
   > Synopsis:  tk window configure -cursor option does not report valid options
   > 
   > ReproducibleScript:
   > . configure -cursor something
   > 
   > ObservedBehavior:
   > When I run the above line in prowish80
   > the results are
   > bad cursor spec "something"
   > 
   > DesiredBehavior:
   > bad cursor spec "something" - should be X_cursor, arrow, based_arrow_down, b
       ased_arrow_up, boat, bogosity,
   > and so forth thru the entire list.
   > 
   > Comments:
   > Having this behavior in the Unix and
   > Windows mac would solve a recurring confusion for people.


tkt_uuid: 996070ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 69. Events
priority: 5 Medium
foundin: None
resolution: Invalid
title: events to previously unmapped windows are silently dropped
comment:
  code snippet to illustrate the issue:

  bind <<test>> "puts hi!"

  proc blah {} {
  toplevel .test
  event generate .test <<test>>
  }

  % blah
  %

  an event to a window that truly does not exist will
  throw an error:

  bad window path name ".test"
      while executing
  "event generate .test <<test>>"


  i think ideally a case should be added to [event] to
  make the window "exist" or somehow fire the event
  anyways. but im not aware of all the internal things
  going on here so that is just a suggestion. at the very
  least i believe it should be documented that your
  events will be lost.


tkt_uuid: 697652ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 08. [(label)frame] and [toplevel]
priority: 5 Medium
foundin: None
resolution: Fixed
title: toplevel/frame can't take empty -colormap or -use
comment:
  I think you should be able to do:

  toplevel .t -colormap ""

  seeing as [. cget -colormap] returns an empty string.

  Similarly:

  toplevel .t -use ""

  should not cause an error.


tkt_uuid: 721030ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 04. Canvas Basics
priority: 5 Medium
foundin: None
resolution: Invalid
title: memory leak caused by color usage
comment:
  set ::id ""
  proc incrLineColor {win i} {
    $win delete $::id
    set col [format {%12.12x} $i]
    set ::id [$win create rect 0 4 200 200 -fill "#$col"]
    incr i 
    after 1 [list incrLineColor $win $i]
  }
  proc main {} {
    pack [canvas .c]; tk appname SEEME; update
    incrLineColor .c 1
  }
  main

  This code causes a memory leak.  It doesn't help if
  delete all is used, or a specified tag is used instead.
   If a -fill color is used that is the same throughout
  the loop, such as "red" or "#FF0000" then the leak
  isn't noticable.  

  When drawing gradients the Tk canvas is unusable,
  because it uses far too much memory, despite the lines
  of the gradient being deleted before each redraw on
  <Configure>.  As the number of redraws on <Configure>
  increases, so too does the memory usage.

  I've tested this with Tcl/Tk 8.0.5 and 8.4.1 in Windows
  XP.  I also asked Arjen Markus to help test some
  similar code.  He reported that it leaked on a Solaris
  system, and in XP using 8.4.1.


tkt_uuid: 829686ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 84. Unix Build
priority: 7 High
foundin: obsolete: 8.5a0
resolution: Fixed
title: AIX 64bit configure
comment:
  configure sets SHLIB_LD_FLAGS correctly but Makefile.in 
  does not use it.

  The following patch fixes the problem:
  Index: Makefile.in
  =====================================
  ==============================
  RCS file: /cvsroot/tktoolkit/tk/unix/Makefile.in,v
  retrieving revision 1.89
  diff -u -r1.89 Makefile.in
  --- Makefile.in 31 May 2003 18:32:20 -0000      1.89
  +++ Makefile.in 24 Oct 2003 15:30:32 -0000
  @@ -236,6 +236,7 @@
   STLIB_LD               = @STLIB_LD@
   SHLIB_LD               = @SHLIB_LD@
   SHLIB_LD_LIBS          = @SHLIB_LD_LIBS@
  +SHLIB_LD_FLAGS         = @SHLIB_LD_FLAGS@
   TK_SHLIB_LD_EXTRAS     = @TK_SHLIB_LD_EXTRAS@
   
   # Additional search flags needed to find the various shared 
  libraries


tkt_uuid: 1083728fffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 16. [scrollbar]
priority: 5 Medium
foundin: obsolete: 8.4.9
resolution: Fixed
title: TkAqua:scrolling
comment:
  The scrollbars don't move well when linked to objects that have 
  quantal scrolling (like a text box).
  I think this has been a problem with thr Aqua version for a while 
  now.

  Example:
  toplevel .t
  grid [scrollbar .t.sc -command ".t.txt yview"] -row 1 -column 2 
  -sticky nws
  grid [text .t.txt -yscrollcommand ".t.sc set"] -row 1 -column 1 
  -sticky nswe
  grid rowconfigure .t 1 -weight 1
  grid columnconfigure .t 1 -weight 1
  .t.txt insert 1.0 [string repeat "a\n" 30]

  if you try to drag the scroll moderately slowly up or down, it 
  doesn't move.

  The problem is that each call to the yscrollcommand resets the 
  stored mouse position, so that each scrolling step is less than the 
  text moves, so nothing happens.

  you can work around this by:
  bind .t.sc <Button-1> {set mousedown %Y; set scrollmdown 
  [lindex [%W get] 0]}
  .t.sc configure -command "vertscroll .t"

  proc vertscroll {w args} {
    global mousedown scrollmdown
    if {[lindex $args 0] == "moveto"} {
    #catch the moveto- this is mouse movement
     #I assume the arrows are at the bottom and ~40pixels high
     #the moveto value is the fraction the scrollbar was at when 
     #the mouse was first clicked plus the fraction the mouse has
     # moved

    #the fraction the mouse has moved is the difference between
    #where the mouse was first clicked and where it is now, divided
    #by the length of the scrollbar in pixels.

      set moveto [expr {$scrollmdown+(1.0*[winfo pointery .]-
  $mousedown)/([winfo height $w.sc]-40)}]
      $w.txt yview moveto $moveto
    } else {
      #all of the other commands are fine
      eval [concat $w.txt yview $args]
    }
  }

  now, all is good.


tkt_uuid: 1613519fffffffffffffffffffffffffffffffff
type: Bug
status: Open
subsystem: 83. Mac OS X Build
priority: 5 Medium
foundin: obsolete: 8.4.14
resolution: None
title: Changing Input Language Using Shortcut Doesn't Work
comment:
  Changing the input language using the global shortcut set in system 
  preferences, doesn't work in any Tk application running in the Wish Shell. 
  This issue was posted by a user of aMSN (CF. http://
  forums.cocoaforge.com/viewtopic.php?t=8763).

  [NB]Moved from the TclTkAquaBI tracker.[/NB]


tkt_uuid: 489756ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 04. Canvas Basics
priority: 2
foundin: obsolete: 8.3.4
resolution: Wont Fix
title: Embedded windows obscure the border
comment:
  Embedded windows when partially scrolled out of the
  current view of the canvas are drawn over the 3d border
  of the canvas instead of below.


tkt_uuid: 3414693fffffffffffffffffffffffffffffffff
type: Bug
status: Open
subsystem: 35. [tk_dialog]
priority: 5 Medium
foundin: None
resolution: None
title: tk_dialog: (mis)placement
comment:
  tk_dialog is centered in relation to "physical" screen - and, unfortunately, not to "root window", like e.g. tk_messageBox is.


tkt_uuid: 1247115fffffffffffffffffffffffffffffffff
type: Bug
status: Open
subsystem: 21. [panedwindow]
priority: 5 Medium
foundin: None
resolution: None
title: Proxy window not visible with "flat" sashrelief
comment:
  A flat sashrelief is common for panedwindow, when it
  separate two widgets with sunken relief.
  In this configuration, the proxy window is not well
  visible, since it uses the same sashrelief option.
  Using a harcoded raised relief, like for the
  borderwidth of 2 pixels, appears to be a better
  altenative (function DisplayProxyWindow()).


tkt_uuid: 3565533fffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 06. Canvas Postscript
priority: 7 High
foundin: obsolete: 8.6b3
resolution: Fixed
title: uninitialized variable "written"
comment:
  Got a compiler warning:

  tkCanvPs.c: In function ‘TkCanvPostscriptCmd’:
  tkCanvPs.c:173: warning: ‘written’ may be used uninitialized in this function

  Looking at lines 614-619, I think the warning is in
  fact pointing out a programming error.  Shouldn't
  "written" be storing the value returned by the
  Tcl_WriteObj() call?


tkt_uuid: 739957ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 10. Generic Menus
priority: 5 Medium
foundin: obsolete: 8.5a0
resolution: None
title: menuDraw-15.3 fails
comment:
  ==== menuDraw-15.3 TkPostTearoffMenu - post command FAILED
  ==== Contents of test case:

      catch {destroy .m1}
      catch {unset foo}
      menu .m1 -postcommand "set foo .m1"
      .m1 add command -label "foo"
      list [catch {tk::TearOffMenu .m1 40 40}] [set foo]
  [unset foo] [destroy .m1]

  ---- Test generated error; Return code was: 1
  ---- Return code should have been one of: 0 2
  ---- errorInfo: can't read "foo": no such variable
      while executing
  "set foo"
      invoked from within
  "list [catch {tk::TearOffMenu .m1 40 40}] [set foo]
  [unset foo] [destroy .m1]"
      ("uplevel" body line 6)
      invoked from within
  "uplevel 1 $script"
  ---- errorCode: NONE
  ==== menuDraw-15.3 FAILED

  looks like event management is not robust.


tkt_uuid: 3025033fffffffffffffffffffffffffffffffff
type: Bug
status: Open
subsystem: 85. Win Build
priority: 5 Medium
foundin: obsolete: 8.6b1
resolution: None
title: APPCRASH if open IME on Win32
comment:
  Downloaded tcl 8.6 from ActiveTcl, playing those demos on Win7 32 bit, if you open IME (input method fro non-English languages) in any of the textbox, the whole app crash.


tkt_uuid: 1160563fffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 36. [tk_chooseDirectory]
priority: 5 Medium
foundin: None
resolution: Duplicate
title: tk_chooseDirectory -mustexist 1 can return non-existant dir
comment:
  tk_chooseDirectory -mustexist 1

  Enter non-existant directory
  Popup appears saying directory does not exist
  Press cancel
  non-existant directory is returned by the dialog

  This is with Tk 8.4.9


tkt_uuid: 220370ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 68. Win Window Operations
priority: 2
foundin: obsolete: 8.0p2
resolution: Fixed
title: Tk_GetPixmap() broken on WinNT
comment:
  OriginalBugID: 638 Bug
  Version: 8.0p2
  SubmitDate: '1998-05-25'
  LastModified: '1999-11-02'
  Severity: MED
  Status: Released
  Submitter: hershey
  ChangedBy: hobbs
  OS: Windows NT
  FixedDate: '1999-11-02'
  FixedInVersion: 8.0.5


  kirka@analogy.com

     I am trying to print color images on NT, and I have just finished
  emulating XGetImage() and would like to test it.  But I crash when I
  call Tk_GetPixmap().  The code doesn't seem like it could work on NT.
  To  parallel the UNIX side, where Tk_GetPixmap() is just the thinest
  wrapper around XGetPixmap(), the second parameter is a Drawable.  But
  the windows code tries to cast that XID into a pointer to a
  TkWinDrawable.  That just doesn't seem like it is going to work.  And I
  don't see why one would want to  create all these new Windows drawable
  struct types.  A plain X window struct has a palette an any of other
  things one would need.  I don't see why the deviation from X.

    I would appreciate any information on how I could implement printing
  of color images on NT, or what the future of Tk_GetPixmap() will be, so
  I could stay compatible with future releases.

   Thanks, Kirk

  Tk_GetPixmap works as necessary on 8.0.5 and the 8.1+ Tk versions. 
  -- 11/02/1999 hobbs


tkt_uuid: 1755313fffffffffffffffffffffffffffffffff
type: Bug
status: Open
subsystem: 18. [text]
priority: 5 Medium
foundin: None
resolution: None
title: Big difference in speed between x and y scrolling in text wi
comment:
  The y scrolling is significantly slower than the x scrolling for a text widget filled with tagged text.

  The attached script displays a text widget with equal width and height. The text inside is arranged so that a given amount of scrolling in x and y shows the same amount of characters, tags, and tagged characters.

  Output: time needed to scroll 100% of the total width/height by 10% steps.

  Some results:

  Tcl/Tk 8.4.15 - Mac OS X 10.4.10 - G4 1.2 GHz
      X scroll :  3 516 756 microseconds per iteration
      Y scroll : 42 130 794 microseconds per iteration

  Tcl/Tk 8.4.14 - Linux 2.6.9 - AMD Opteron
      X scroll :    187 251 microseconds per iteration
      Y scroll : 15 521 640 microseconds per tieration

  Tcl/Tk 8.5.0a6 - Linux 2.6.9 - AMD Opteron
      X scroll :    194 166 microseconds per iteration
      Y scroll : 16 266 219 microseconds per tieration

  Tcl/Tk 8.4.14 - Windows XP SP2 - P4
      X scroll :  1 253 936 microseconds per iteration
      Y scroll : 21 507 107 microseconds per iteration 


tkt_uuid: 220069ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 99. Other
priority: 1 Zero
foundin: obsolete: 8.3
resolution: Duplicate
title: Please bring back link to "options" on all Tk widget help pages.
comment:
  OriginalBugID: 4250 RFE
  Version: 8.3
  SubmitDate: '2000-02-28'
  LastModified: '2000-02-28'
  Severity: LOW
  Status: Closed
  Submitter: techsupp
  ChangedBy: hobbs
  RelatedBugIDs: 4156
  OS: All Windows
  ClosedDate: '2000-02-28'


  Name:
  Brian Schmidt

  DesiredBehavior:
  In previous versions of Tcl/Tk on Windows, in the Tcl/Tk reference help file there was a clickable link to "options" that explained the details of all Standard Options.  This clickable link is now gone and we have to do an index search for "options" or define a bookmark.  The clickable link we had before was handier.
  Thanks!


tkt_uuid: 220601ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: None
priority: 2
foundin: obsolete: 8.2
resolution: Fixed
title: tk_getOpenFile & tk_getSaveFile core dump
comment:
  OriginalBugID: 2995 Bug
  Version: 8.2
  SubmitDate: '1999-09-29'
  LastModified: '1999-10-22'
  Severity: SER
  Status: Released
  Submitter: techsupp
  ChangedBy: hobbs
  OS: Digital Unix
  OSVersion: Tru64Unix 4.0f
  Machine: Other
  FixedDate: '1999-10-22'
  FixedInVersion: 8.2.1


  Name:
  Ingo Brunberg

  ReproducibleScript:
  start up wish8.2
      tk_getOpenFile or tk_getSaveFile

  ObservedBehavior:
  unable to alloc 0 bytes
      Abort (core dumped)

  DesiredBehavior:
  a Filechooser Dialogbox coming up



  This was fixed in 8.2.1. 
  -- 10/22/1999 hobbs


tkt_uuid: 653156ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 18. [text]
priority: 5 Medium
foundin: None
resolution: Fixed
title: search start wrong when elided chars
comment:
  bug with text-widget search function.
  When there are elided chars,
  the start index of search is wrong.

  % info patchlevel
  8.4b1
  (bin) 2 % pack [text .text]
  (bin) 3 % .text insert 1.0 "1234 ab ab ab ab ab ab ab"
  (bin) 4 % .text tag add hidden 1.0 1.4
  (bin) 5 % .text search ab 1.5 end
  1.5
  (bin) 6 % .text tag configure hidden -elide yes
  (bin) 7 % .text search ab 1.5 end
  1.11
  (bin) 8 % 

  Before the letter sequence 1234 was hidden, 
  the start index was taken correctly.
  When the letter sequence 1234 is hidden, 
  the start index is obviously 1.5 + 4 chars  = 1.9,
  so the next found occurrence of ab was 11.


tkt_uuid: 3439581fffffffffffffffffffffffffffffffff
type: RFE
status: Open
subsystem: 88. Themed Tk (Ttk)
priority: 5 Medium
foundin: None
resolution: None
title: ttk::style element image auto-adjusts width
comment:
  The ttk element image should recalculate it's width each time the image changes.

  ************
      set inull [image create bitmap]
      set ierror [image create photo -file ".../14x14/error.png"]
      set iwarning [image create photo -file ".../14x14/warning.png"]

      toplevel .tt
      ttk::entry .tt.e1
      pack .tt.e1 -fill x -expand yes

      ttk::style element create Warning image [list $iwarning user1
  $inull]
      ttk::style element create Error image [list $ierror user2 $inull]

      ttk::style layout TEntry {Entry.field -sticky nswe -children
  {Entry.padding -sticky nswe -children {Error -side right -sticky w
  Warning -side right -sticky e Entry.textarea}}}

      .tt.e1 state user2 
  ***************

  Details see here: http://groups.google.com/group/comp.lang.tcl/browse_thread/thread/f397b04c019aed9e/9dd04232b096556b?hl=en#9dd04232b096556b

  thx


tkt_uuid: 220359ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 47. Win Fonts
priority: 2
foundin: obsolete: 8.0p2
resolution: Fixed
title: Use correct character widths on Windows
comment:
  OriginalBugID: 601 Bug
  Version: 8.0p2
  SubmitDate: '1998-05-21'
  LastModified: '1998-08-05'
  Severity: LOW
  Status: Released
  Submitter: stanton
  ChangedBy: stanton
  OS: All
  OSVersion: NA
  Machine: NA
  FixedInVersion: 8.0.3
  ClosedDate: '1998-08-05'


  The following comment appears in both Tk8.0p2 and Tk8.1a2 in the

  Tk_MeasureChars function in tkWinFont.c:


      /*

       * On the authority of the Gates Empire, Windows does not use kerning

       * or fractional character widths when displaying text on the screen.

       * So that means we can safely measure individual characters or spans

       * of characters and add up the widths w/o any "off-by-one pixel" 

       * errors.  

       */


  This comment is unfortunately not correct.  At least on Windows NT

  4.0, for at least some fonts, Windows does use kerning.  You can see

  this most obviously by creating a window which holds text in a bold

  font, and selecting characters with the mouse.  As you drag the mouse

  over characters, they will shift slightly.  This is because Tk is not

  computing the character widths consistently with how they are being

  displayed on the screen.


  The appended patch fixes this problem.


  This patch is for Tk8.0p2.  The code in Tk8.1a2 has changed fairly

  substantially, but, as far as I can tell, the code continues to have

  the same bug.  I hope this patch will indicate how Tk8.1a2 should be

  changed.  I can help port the patch to Tk8.1a2 if necessary.


  Ian Taylor

  ian@cygnus.com


  *** /5g/ian/tk8.0p2/win/tkWinFont.c     Thu May 15 20:15:03 1997

  --- tkWinFont.c Thu Apr 16 15:06:28 1998

  *************** typedef struct WinFont {

  *** 26,32 ****

        HFONT hFont;              /* Windows information about font. */

        HWND hwnd;                        /* Toplevel window of application that owns

                                   * this font, used for getting HDC. */

  -     int widths[256];          /* Widths of first 256 chars in this font. */

    } WinFont;


    /*

  --- 26,31 ----

  *************** Tk_MeasureChars(tkfont, source, numChars

  *** 332,345 ****

        HFONT hFont;

        int curX, curIdx;


  -     /*

  -      * On the authority of the Gates Empire, Windows does not use kerning

  -      * or fractional character widths when displaying text on the screen.

  -      * So that means we can safely measure individual characters or spans

  -      * of characters and add up the widths w/o any "off-by-one pixel" 

  -      * errors.  

  -      */

  - 

        fontPtr = (WinFont *) tkfont;


        hdc = GetDC(fontPtr->hwnd);

  --- 331,336 ----

  *************** Tk_MeasureChars(tkfont, source, numChars

  *** 351,425 ****

        } else if (maxLength <= 0) {

          SIZE size;


  !       GetTextExtentPoint(hdc, source, numChars, &size);

          curX = size.cx;

          curIdx = numChars;

        } else {

  !       int newX, termX, sawNonSpace;

  !       CONST char *term, *end, *p;

  !       int ch;


  !       ch = UCHAR(*source);

  !       newX = curX = termX = 0;

  !       

  !       term = source;

  !       end = source + numChars;


  !       sawNonSpace = !isspace(ch);

  !       for (p = source; ; ) {

  !           newX += fontPtr->widths[ch];

  !           if (newX > maxLength) {

  !               break;

              }

  !           curX = newX;

  !           p++;

  !           if (p >= end) {

  !               term = end;

  !               termX = curX;

  !               break;

              }


  !           ch = UCHAR(*p);

  !           if (isspace(ch)) {

  !               if (sawNonSpace) {

  !                   term = p;

  !                   termX = curX;

  !                   sawNonSpace = 0;

  !               }

  !           } else {

  !               sawNonSpace = 1;

  !           }

          }


  !       /*

  !        * P points to the first character that doesn't fit in the desired

  !        * span.  Use the flags to figure out what to return.

  !        */


  -       if ((flags & TK_PARTIAL_OK) && (p < end) && (curX < maxLength)) {

              /*

  !            * Include the first character that didn't quite fit in the desired

  !            * span.  The width returned will include the width of that extra

  !            * character.

               */

  ! 

  !           curX = newX;

  !           p++;

  !       }

  !       if ((flags & TK_AT_LEAST_ONE) && (term == source) && (p < end)) {

  !           term = p;

  !           termX = curX;

  !           if (term == source) {

  !               term++;

  !               termX = newX;

  !           }

  !       } else if ((p >= end) || !(flags & TK_WHOLE_WORDS)) {

  !           term = p;

  !           termX = curX;

          }


  !       curX = termX;

  !       curIdx = term - source; 

        }


        SelectObject(hdc, hFont);

  --- 342,411 ----

        } else if (maxLength <= 0) {

          SIZE size;


  !       GetTextExtentPoint32(hdc, source, numChars, &size);

          curX = size.cx;

          curIdx = numChars;

        } else {

  !       int max;

  !       int *partials;

  !       SIZE size;


  !       partials = (int *) ckalloc(numChars * sizeof (int));

  !       GetTextExtentExPoint(hdc, source, numChars, maxLength, &max,

  !                   partials, &size);


  !       if ((flags & TK_WHOLE_WORDS) && max < numChars) {

  !           int i;

  ! 

  !           /*

  !            * We need to back up through the word that fits at the

  !            * end of the line, and then back through any space

  !            * characters that may precede that word.  We start

  !            * backing up at MAX, because if MAX is a space we can

  !            * stop at MAX - 1.

  !            */

  !           i = max;

  !           while (i >= 0 && !isspace(source[i])) {

  !               --i;

              }

  !           while (i >= 0 && isspace(source[i])) {

  !               --i;

              }


  !           /*

  !            * We must have executed at least one --i, so this will

  !            * not set MAX larger than the original value.

  !            */

  !           max = i + 1;

          }


  !       if (max == 0) {

  !           curX = 0;

  !       } else {

  !           curX = partials[max - 1];

  !       }

  ! 

  !       if (((flags & TK_PARTIAL_OK)

  !            && max < numChars

  !            && curX < maxLength)

  !           || ((flags & TK_AT_LEAST_ONE)

  !               && max == 0

  !               && numChars > 0)) {


              /*

  !            * We want to include the first character that didn't

  !            * quite fit.  Call the function again to include the

  !            * width of the extra character.

               */

  !           GetTextExtentExPoint(hdc, source, max + 1, 0, NULL, partials,

  !                       &size);

  !           curX = partials[max];

  !           ++max;

          }


  !       ckfree((char *) partials);

  ! 

  !       curIdx = max;

        }


        SelectObject(hdc, hFont);

  *************** AllocFont(tkFontPtr, tkwin, hFont)

  *** 613,619 ****

        hFont = SelectObject(hdc, hFont);

        GetTextFace(hdc, sizeof(buf), buf);

        GetTextMetrics(hdc, &tm);

  -     GetCharWidth(hdc, 0, 255, fontPtr->widths);


        fontPtr->font.fid = (Font) fontPtr;


  --- 599,604 ----


tkt_uuid: 1174269fffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 18. [text]
priority: 5 Medium
foundin: obsolete: 8.5a3
resolution: Fixed
title: elide searching problems
comment:
  There are a few bugs in searching in the text widget
  with elided characters (both before and after the
  recent multi-line elide display fix in Tk).  One of
  these bugs has just been reported on comp.lang.tcl.

  The attached tests illustrate the problem.

  No fix yet.


tkt_uuid: 3605283fffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 88. Themed Tk
priority: 5 Medium
severity: Minor
foundin: current: 8.6.0
resolution: Fixed
title: ttk::entry xview end
comment:
  The Ttk entry widget does not accept the index "end" in its xview command.
  Perhaps this affects all ttk widgets.


tkt_uuid: 220349ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 68. Win Window Operations
priority: 2
foundin: obsolete: 8.0p2
resolution: Fixed
title: focus -force works poorly on Windows
comment:
  OriginalBugID: 587 Bug
  Version: 8.0p2
  SubmitDate: '1998-05-21'
  LastModified: '1998-06-12'
  Severity: LOW
  Status: Released
  Submitter: stanton
  ChangedBy: stanton
  OS: All Windows
  OSVersion: NA
  Machine: NA
  FixedInVersion: NA
  ClosedDate: '1998-06-12'


  With Tk8.0p2 and Tk8.1a2 on Windows, the focus -force option only
  calls SetFocus.  This is OK, but when focus -force is used in practice
  on Windows I think the user really wants to make the window the new
  foreground window, particularly since Tk doesn't provide any other
  mechanism to set the foreground window.

  The appended patch implements this suggested change.

  Ian Taylor
  ian@cygnus.com


  *** /5g/ian/tk8.0p2/win/tkWinPointer.c  Fri Oct 31 11:40:05 1997
  --- tkWinPointer.c      Wed Apr 15 15:13:30 1998
  *************** TkpChangeFocus(winPtr, force)
  *** 409,414 ****
  --- 409,419 ----
        if (winPtr->window == None) {
          panic("ChangeXFocus got null X window");
        }
  + 
  +     if (force) {
  +       SetForegroundWindow(Tk_GetHWND(winPtr->window));
  +     }
  + 
        XSetInputFocus(dispPtr->display, winPtr->window, RevertToParent,
              CurrentTime);
    



  The supplied patch seems to work correctly, so I have integrated it. (SS)


tkt_uuid: 3485342fffffffffffffffffffffffffffffffff
type: RFE
status: Closed
subsystem: 37. [tk_get*File]
priority: 5 Medium
severity: Minor
foundin: None
resolution: Fixed
title: Add -confirmonwrite option to tk_get*File on nt
comment:
  We should, when possible, use the same interface to get saveasfilename, etc.
  On nt, the -confirmonwrite option is neither known or used (whereas on aix/linux, this option is supported).

  I added a small patch to this request, that allow to switch on/off the OFN_OVERWRITEPROMPT switch used in tkWinDialogs.c

  Regards,
  Eloi


tkt_uuid: 1566949fffffffffffffffffffffffffffffffff
type: Bug
status: Open
subsystem: 18. [text]
priority: 5 Medium
foundin: obsolete: 8.5a4
resolution: None
title: [text yview] shows strange behaviour
comment:
  [$text yview] returns two fractions. When using the
  first fraction in [$text yview moveto $fraction] I
  would expect the fractions returned by [$text yview]
  after this moveto to be the same as before the moveto.
  Most of the time this is the case. 

  Using [$text yview] with Tcl 8.5a4 on Windows shows
  some strange behaviour. The fractions before and after
  a moveto call are the same, except when the contents of
  the text widget are deleted and insert in between the
  first [$text yview] and [$text yview moveto $fraction],
  even if the contents stay the same.

  I've added an example script to show this bug. [test]
  shows some output without deleting and replacing the
  contents and [test true] shows the output with deleting
  and replacing the contents. Notice the difference! I
  think this bug might be related to #1499165.


tkt_uuid: 532120ffffffffffffffffffffffffffffffffff
type: RFE
status: Closed
subsystem: 02. Appearance
priority: 5 Medium
foundin: None
resolution: Wont Fix
title: sunken widget bordercolors from parent
comment:
  I think that 'sunken' widgets (e.g. entry, text,
  listbox, spinbox, others?) should set their
  bordercolors (hilight, shadow) relative to their
  parent, or rather their geometry master. For example,
  if you pack an entry, with a white background, in a
  blue frame, the hilight/shadow colors should be shades
  of blue, not gray.


tkt_uuid: 220150ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 49. [grid]
priority: 1 Zero
foundin: obsolete: 8.0.4
resolution: Invalid
title: bug in ArrangeGrid procedure
comment:
  OriginalBugID: 1588 Bug
  Version: 8.0.4
  SubmitDate: '1999-03-22'
  LastModified: '1999-10-21'
  Severity: SER
  Status: Closed
  Submitter: pat
  ChangedBy: hobbs
  OS: Other
  OSVersion: Linux 6.0 + glibc
  Machine: NA
  ClosedDate: '1999-10-21'


  Name:
  Andreas otto

  Extensions:
  adadtcl,

  CustomShell:
  See 6)

  ReproducibleScript:
          Lib:        libtk8.0
      
          Error:      Generate a CORE
                      Structure clientData was not initialised during
      idle-event-handling
      
          File:       generic/tkGrid.c
          Procedure:  ArrangeGrid
          Line:       ~ 1217
          Code:       Add ...
                          if(  masterPtr->column  > 1000  ||
                               masterPtr->row     > 1000  ||
                               masterPtr->numCols > 1000  ||
                               masterPtr->numRows > 1000      ) {
                          return;
                          }
                      ... to identify a not initialised clientData strukture
      
                      => this is a workaround
      
      



  ObservedBehavior:
      During an idle task the procedure ArrangeGrid was called with an invalid
      ClientData Pointer => CoreDump
      
      Workaround: test the pointer to be valid 
      all columns/rows must be less than 1000
      
      better add an extra field with Structur-Check Information
      => Identify if an pointe on a struc is valid
      



  DesiredBehavior:
      No CoreDump
      




  This appears to be the fault of whatever is passing in the
  bad clientData structure.  Is this adadtcl?  Since this is
  the only report of this type, we can only assume the custom
  shell is at fault. 
  -- 10/21/1999 hobbs


tkt_uuid: 220192ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 09. [listbox]
priority: 1 Zero
foundin: obsolete: 8.1
resolution: Invalid
title: listbox browse mode allows multiple selectins
comment:
  OriginalBugID: 2086 Bug
  Version: 8.1
  SubmitDate: '1999-05-17'
  LastModified: '1999-08-08'
  Severity: MED
  Status: Closed
  Submitter: pat
  ChangedBy: hobbs
  RelatedBugIDs: 1358
  OS: Windows NT
  Machine: X86
  ClosedDate: '1999-08-08'


  Name:
  Christopher Nelson

  Comments:
  This is present in Tk 8.0 on UNIX, too.

  ReproducibleScript:
  # The select mode defaults to "browse" which is a one-at-a-time
      # mode but using selection set, it is possible to select more than one.
      listbox .lb -exportselection 0
      pack .lb -padx 3m -pady 3m
      puts ".lb's mode is [.lb cget -selectmode]"
      
      for {set i 0} {$i < 5} {incr i} {
          .lb insert end "item $i"
          .lb selection set $i
      }

  ObservedBehavior:
  All the items in the lsitbox are selected

  DesiredBehavior:
  Only the last one should be selected



  This is the intended behavior.  The listbox -selectmode is an
  option that the bindings use to interpret user interaction.  If
  the selection method is called by the programmer, then it can go
  against this behavior without problem. 
  -- 08/08/1999 hobbs


tkt_uuid: 219971ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 63. Tk_Win Functions
priority: 1 Zero
foundin: obsolete: 8.1b3
resolution: Duplicate
title: Tk_InitStubs() not usable in tk81.dll
comment:
  OriginalBugID: 1842 Bug
  Version: 8.1b3
  SubmitDate: '1999-04-15'
  LastModified: '2000-01-25'
  Severity: LOW
  Status: Closed
  Submitter: pat
  ChangedBy: hobbs
  RelatedBugIDs: 1841 2078
  OS: Windows NT
  OSVersion: 4.0 SP3
  Machine: X86
  ClosedDate: '2000-01-25'


  Name:

  Jan Nijtmans


  ReproducibleScript:

  This is the same bug as described in "Tcl_InitStubs() not usable in

      tcl81.dll",

      submitted for tcl8.1b3. The patch supplied is not really a fix; It

      just removes Tk_InitStubs from the dll so there isn't any mis-

      understanding about the fact that linking a Stub-enabled extension

      against tk81.dll should never be done.


      However for Tk, there is an additional argument why this fix is

      needed. Currently Tk_InitStubs() doesn't use the EXPORT macro,

      which makes that it doesn't work with extensions compiled with C++.

      The patch below fixes this, and in addition fixes everything

      described in the "Tcl_InitStubs() not usable in tcl81.dll"

      bug report, but then for Tk.


  Patch:

  *** generic/tk.h.origWed Apr 14 22:31:14 1999

  --- generic/tk.hWed Apr 14 22:34:22 1999

  ***************

  *** 1159,1173 ****

    #define Tk_Main(argc, argv, proc) \

        Tk_MainEx(argc, argv, proc, Tcl_CreateInterp())


  - char *Tk_InitStubs _ANSI_ARGS_((Tcl_Interp *interp, char *version, int exact));

  - 

  - #ifndef USE_TK_STUBS

  - 

  - #define Tk_InitStubs(interp, version, exact) \

  -     Tcl_PkgRequire(interp, "Tk", version, exact)

  - 

  - #endif

  - 

    

    /*

     *--------------------------------------------------------------

  --- 1159,1164 ----

  ***************

  *** 1205,1210 ****

  --- 1196,1213 ----

     * Tcl commands exported by Tk:

     */


  + #undef TCL_STORAGE_CLASS

  + #define TCL_STORAGE_CLASS

  + 

  + EXTERN char *Tk_InitStubs _ANSI_ARGS_((Tcl_Interp *interp,

  +     char *version, int exact));

  + 

  + #ifndef USE_TK_STUBS

  + 

  + #define Tk_InitStubs(interp, version, exact) \

  +     Tcl_PkgRequire(interp, "Tk", version, exact)

  + 

  + #endif


    #endif /* RESOURCE_INCLUDED */


  *** generic/tkWindow.c.origWed Apr 14 22:31:19 1999

  --- generic/tkWindow.cWed Apr 14 22:35:23 1999

  ***************

  *** 2945,2955 ****

  --- 2945,2957 ----

    goto done;

        }


  + #ifndef __WIN32__

    #ifdef Tk_InitStubs

    #undef Tk_InitStubs

    #endif


        Tk_InitStubs(interp, TK_VERSION, 1);

  + #endif


        /*

         * Invoke platform-specific initialization.

  *** win/makefile.vc.origWed Apr 14 22:35:46 1999

  --- win/makefile.vcWed Apr 14 22:37:00 1999

  ***************

  *** 208,214 ****

    $(TMPDIR)\tkUtil.obj \

    $(TMPDIR)\tkVisual.obj \

    $(TMPDIR)\tkStubInit.obj \

  - $(TMPDIR)\tkStubLib.obj \

    $(TMPDIR)\tkWindow.obj


    TKSTUBOBJS = $(TMPDIR)\tkStubLib.obj \

  --- 208,213 ----


  PatchFiles:

  tk.h tkWindow.c makefile.vc




  4/22/99 - redman - After talking with Scott S., we're going to try another scheme to work around the problem described (exporting the symbols in question and removing the need to use -DUSE_TCL_STUBS).  This really isn't a critical issue and can wait.
  --
  2078 includes 8.1.0 based patch. 
  -- 01/25/2000 hobbs


tkt_uuid: 3314770fffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 37. [tk_get*File]
priority: 8
foundin: obsolete: 8.5.9
resolution: Fixed
title: regression - Windows file dialogs not resizable
comment:
  In changes to support the latest look in Windows, we lost the ability to resize the dialog.  I think the only thing that needs to be added is OFN_ENABLESIZING to the ofn.Flags in GetFileNameA|W.


tkt_uuid: 220727ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 68. Win Window Operations
priority: 2
foundin: final: 8.2.3
resolution: Fixed
title: Errant top level behaviour with Xmouse
comment:
  OriginalBugID: 5031 Bug
  Version: 8.2.3
  SubmitDate: '2000-04-12'
  LastModified: '2000-04-25'
  Severity: MED
  Status: Released
  Submitter: techsupp
  ChangedBy: hobbs
  RelatedBugIDs: 2272
  OS: All Windows
  OSVersion: Windows 98 Second Edition
  Machine: Any intel PC
  FixedDate: '2000-04-25'
  FixedInVersion: 8.3.1


  Name: Haneef Mohammed

  Comments:
  We in our organization moved from a primarily Unix platform to
      a windoze platform and everybody is so used to this Xmouse behaviour.
      I am trying to move our development to Tcl/Tk but it has not been
      received very well by the end users because of this (in my opinion
      minor irritant).

  ReproducibleScript:
  1. Enable Xmouse on your Windows. You can do this using TweakUI
     (in Control Panel) in the Mouse Tab. You can install TweakUI from
     the Windows 98 PLUS CD. You can apparently also enable Xmouse on Win95
     and WinNT4.0 by setting the following registry entry...
         \My Computer\HKEY_CURRENT_USER\Control Panel\Mouse = 0x1
  2. When Xmouse is enabled, the top level windows get activted (and get
     focus) when the mouse moves over the window without raising that window.
  3. Invoke Wish. This will create two top level windows. Arrange these windows
     such that they overlap somewhat.
  4. Activate one of the Wish top levels and now move your mouse (without
     clicking) from one window to the other. You will notice that these windows
     are automatically raising themselves. This is not correct behaviour
  5. Now activate some other window. Notice that you can activate any non-tk
     window just by moving your mouse over it.
  6. Move the mouse back to any tk window. You will notice that the Tk windows
     never activate unless you actually click your mouse in it. This is also
     not correct behaviour.

  ObservedBehavior:
  1. Top level windows should not auto-raise just because they
     get activated.

  2. The WM_MOUSEACTIVATE event should be handled just like the
     Windows Default procedure does.

  3. I have tried the tk_focusFollowsMouse but that only seems to work
     within the Tk window hierarchy.

  DesiredBehavior:
  The problem is with the handling of WM_MOUSEACTIVATE, in win/tkWinWm.c
  If I let the DefWindowProc handle this event, everything works fine. But
  seems like Tk wanted to handle this event itself (I guess to emulate
  grabbing properly). I do not know enough about Tk to be able to fix this
  bug myself. I have already documented the expected behaviour in my instructions
  to duplicate the problem.



  Verified with 8.3.0 on NT with TweakUI 1.1. 
  -- 04/25/2000 hobbs
  Fixed for 8.3.1 (see related bug 2272). 
  -- 04/25/2000 hobbs


tkt_uuid: 3059923fffffffffffffffffffffffffffffffff
type: Patch
status: Closed
subsystem: 81. Portability
priority: 5 Medium
severity: Minor
foundin: None
resolution: Out of Date
title: fixes for mingw64 - gcc4.5.1 tdm64-1
comment:
  mingw64 doesn't have SEH, and apparently amd64 arch (w64) doesn't need it.
  also fixes a conflicting value for _WIN32_IE on mingw64 environment.


tkt_uuid: 220003ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 75. wish
priority: 1 Zero
foundin: final: 8.1.1
resolution: Duplicate
title: Pipe to 16 bit program not working under Windows NT 4
comment:
  OriginalBugID: 2330 Bug
  Version: 8.1.1
  SubmitDate: '1999-07-06'
  LastModified: '1999-08-05'
  Severity: SER
  Status: Closed
  Submitter: techsupp
  ChangedBy: hobbs
  RelatedBugIDs: 2368
  OS: Windows NT
  OSVersion: Win NT 4.0 + ServicePack 4
  Machine: X86
  ClosedDate: '1999-08-05'


  Name:
  Martin Conrad

  Extensions:
  no

  CustomShell:
  no

  Comments:
  Best regards,
      
      Martin

  ReproducibleScript:
  The following scripts can be invoked by tclsh81 or wish81. First you
      must insert a formatted high density floppy disk into drive A:, then you
      type
      
      tclsh81 initfd
      
      or
      
      wish81 initfd
      
      In both cases, the script sends commands to debug which build a new BIOS
      parameter block, FAT tables and an empty directory (for higher total
      capacity).
      
      If you use tclsh81, you can see some output on the console screen, if
      you use wish, you see nothing, but the floppy drive LED should be turned
      on and off.
      
      Here the scripts:
      ------------------------------------------ initfd (1st version)
      
      puts "Start initialization drive 0"
      set fdp [open "| debug" w]
      puts $fdp "
      l200 0 0 2
      f20d,20d 8
      f211,211 30
      f215,215 f0
      f216,216 2
      f400,400 f0
      f403,11ff 0
      f800,802 f0 ff ff
      w200 0 0 8
      q
      "
      puts "Close command pipe now"
      close $fdp
      puts "Initialisierung beendet"
      exit
      
      --------------------------------------------------------- initfd (2nd
      version)
      
      exec debug << "
      l200 0 0 2
      f20d,20d 8
      f211,211 30
      f215,215 f0
      f216,216 2
      f400,400 f0
      f403,11ff 0
      f800,802 f0 ff ff
      w200 0 0 8
      q
      "
      exit
      
      ---------------------------------------------------------

  ObservedBehavior:
  If you use wish81, the script hangs. The task manager shows a process
      NTVDM.EXE,
      which consumes nearly all cpu time. If you stop that process, an error
      message
      pops up, with the following contents (1st version):
              broken pipechild process exited abnormally
                while executing
              "close $fdp"
                (file "...\initfd" line 16)
      Contents for 2nd version:
              child process exited abnormally
                while executing
              "exec debug << "
                   :
                   :
                      q
              ""
                (file "...\initfd" line 1

  DesiredBehavior:
  As with wish80, the debug commands written to the pipe should be
      executed and
      the script should stop afterwards.


tkt_uuid: 3517803fffffffffffffffffffffffffffffffff
type: Bug
status: Open
subsystem: 56. [grab]
priority: 5 Medium
foundin: None
resolution: None
title: Modality not properly working
comment:
  I have the following case:

  .help is a help top level window
  .application.fileSelBox is a modal top level window (using local grab).

  Currently I cannot use the .help window if .application.fileSelBox is mapped, because .help is catching all mouse events. I think this is a bug, because if I look at the implementation of TkGrabState() - which is used in TkPointerEvent(), which handles the modality - something is weird:

  int
  TkGrabState(
      TkWindow *winPtr)           /* Window for which grab information is
                                                    * needed. */
  {
      TkWindow *grabWinPtr = winPtr->dispPtr->grabWinPtr;

      if (grabWinPtr == NULL) {
          return TK_GRAB_NONE;
      }
      if ((winPtr->mainPtr != grabWinPtr->mainPtr)
              && !(winPtr->dispPtr->grabFlags & GRAB_GLOBAL)) {
          return TK_GRAB_NONE;
      }

      return TkPositionInTree(winPtr, grabWinPtr);
  }

  The condition "winPtr->mainPtr != grabWinPtr->mainPtr" is always true, because winPtr->mainPtr is "." in every case. I think that this is a bug, and something like "SecondLastToplevel(winPtr) != SecondLastToplevel(grabWinPtr)" was intended. This means that the correct implementation should be:

  int
  TkGrabState(
      TkWindow *winPtr)           /* Window for which grab information is
                                                    * needed. */
  {
      TkWindow *grabWinPtr = winPtr->dispPtr->grabWinPtr;

      if (grabWinPtr == NULL) {
          return TK_GRAB_NONE;
      }
      if (!(winPtr->dispPtr->grabFlags & GRAB_GLOBAL) &&
              winPtr != grabWinPtr && /* this is an often case */
              (SecondLastToplevel(winPtr) != SecondLastToplevel(grabWinPtr))) {
          return TK_GRAB_NONE;
      }

      return TkPositionInTree(winPtr, grabWinPtr);
  }

  /* SecondLastToplevel() returns the toplevel window which is a descendant
   * of ".", or it returns the argument if such a second last toplevel is
   * not exisiting. */
  static TkWindow *
  SecondLastToplevel(
      TkWindow *winPtr)           /* Window for which second last
                                                    * toplevel is needed. */
  {
      TkWindow *prevTopLevelWinPtr = winPtr->mainPtr->winPtr;
      TkWindow *topLevelWinPtr = winPtr->mainPtr->winPtr;

      while (winPtr && !(winPtr->flags & TK_TOP_HIERARCHY)) {
          topLevelWinPtr = prevTopLevelWinPtr;
          prevTopLevelWinPtr = winPtr;
          winPtr = winPtr->parentPtr;
      }

      return topLevelWinPtr;
  }

  In my case SecondLastToplevel() will return .help and .application, respectively, which do not match.  Now the application will work as expected, I can use the .help window although the modal window .application.fsbox is mapped, but I cannot use the ancestor .application. The fixed implementation of TkGrabState() takes the tree hierarchy into account, the current implementation in the Tk library is ignoring the tree hierarchy.


tkt_uuid: 220419ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 58. [send]
priority: 2
foundin: obsolete: 8.1b1
resolution: Fixed
title: send and DDE don't work on Windows
comment:
  OriginalBugID: 1058 Bug
  Version: 8.1b1
  SubmitDate: '1999-01-15'
  LastModified: '1999-03-31'
  Severity: MED
  Status: Released
  Submitter: pat
  ChangedBy: redman
  OS: Windows 95
  OSVersion: 4.00.950 B
  Machine: X86
  FixedDate: '1999-03-31'


  Name:
  Kevin B. Kenny

  Extensions:
  None relevant

  CustomShell:
  Identical failures on "out-of-the-box"

  ReproducibleScript:
  # This is a dummy test of the 'send' command

  console show
  set d [file dirname [info script]]
  set fn [file join $d script2.tcl]
  set f [open $fn w]
  puts $f {
      console show
      set parent [lindex $argv 0]
      if {[catch {
  send $parent {puts "it worked"}
      } result]} {
  puts "send failed: $result"
      }
  }
  close $f
  exec [info nameof] $fn [tk appname] &




  ObservedBehavior:
  Virtually any use of the 'dde' or 'send' commands under Windows results
  in errors.  When I spoke to Scott Stanton and Syd Polk about this issue
  in September in San Diego, Syd led me to believe that the problem was that
  the internationalization changes cause incorrect string lengths to be
  presented to the DDE calls.  In particular, the script above causes
  the child process to print:

  send failed: invalid data returned from server

  One clue is that the after the script executes, the parent process's
  errorInfo variable contains the string:

  extra characters after close-quote
      while compiling
  "puts "it worked"



  DesiredBehavior:
  I kind of expect 'send' to work...  8-)





  The symptoms differ slightly on Win98 and Win-NT 4.0, but the failure is
  present on those platforms as well.
  03/31/1999 15:53 - redman - Fixed, DDE doesn't give the correct data length.


tkt_uuid: 220644ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 99. Other
priority: 2
foundin: obsolete: 8.3b1
resolution: Fixed
title: Improper use of after, eval, and uplevel
comment:
  OriginalBugID: 3943 Bug
  Version: 8.3b1
  SubmitDate: '1999-12-27'
  LastModified: '2000-01-03'
  Severity: MED
  Status: Released
  Submitter: techsupp
  ChangedBy: hobbs
  OS: Linux-SuSE
  FixedDate: '2000-01-03'
  FixedInVersion: 8.3b2


  Name:

  Dr. Csaba Nemethi


  Comments:

  Most people use only letters, digits, and underscore in the components

  of widget names, and a lot of Tcl/Tk code is potentionally broken

  because of the erronous assumption that widget names cannot have any 

  other characters (except the dot).  This is probably the reason for the

  above, very long-standing bug.


  ReproducibleScript:

  According to the Tcl man page, ".my entry" is a legal "word" and hence 

  a valid widget and command name.  For example, the following script is 

  both syntactically and semantically correct:


  pack [entry ".my entry"]

  ".my entry" insert 0 "any text"


  ObservedBehavior:

  When the mouse leaves this entry widget with button 1 down, the

  following error message is displayed:


      called "tkEntryAutoScan" with too many arguments

          while executing

      "tkEntryAutoScan .my entry"

          ("after" script)


  The reason is obvious:  In line 433 of the library file entry.tcl, the

  after-ID of the next auto-scan command to be executed for the given

  entry widget is set to [after 50 tkEntryAutoScan $w], where w has the

  value ".my entry". The after command concatenates its arguments,

  therefore tkEntryAutoScan are passed the arguments ".my" and "entry"

  instead of the single argument ".my entry".


  This is just one example of improper invocation of the after command in

  Tk library files, and there are similar problems with eval and uplevel.


  DesiredBehavior:

  The invocations of after, eval, and uplevel should make use of the list 

  command, in order to work for widget names containing spaces or other

  special characters.


  Patch:

  *** entry.tcl.OLD       Tue Nov 30 08:27:01 1999

  --- entry.tcl.NEW       Sun Dec 26 12:04:44 1999

  ***************

  *** 430,436 ****

          $w xview scroll -2 units

          tkEntryMouseSelect $w $x

        }

  !     set tkPriv(afterId) [after 50 tkEntryAutoScan $w]

    }


    # tkEntryKeySelect --

  --- 430,436 ----

          $w xview scroll -2 units

          tkEntryMouseSelect $w $x

        }

  !     set tkPriv(afterId) [after 50 [list tkEntryAutoScan $w]]

    }


    # tkEntryKeySelect --

  *** listbox.tcl.OLD     Wed Dec 22 00:55:27 1999

  --- listbox.tcl.NEW     Sun Dec 26 12:05:53 1999

  ***************

  *** 347,353 ****

          return

        }

        tkListboxMotion $w [$w index @$x,$y]

  !     set tkPriv(afterId) [after 50 tkListboxAutoScan $w]

    }


    # tkListboxUpDown --

  --- 347,353 ----

          return

        }

        tkListboxMotion $w [$w index @$x,$y]

  !     set tkPriv(afterId) [after 50 [list tkListboxAutoScan $w]]

    }


    # tkListboxUpDown --

  *** scale.tcl.OLD       Thu Sep  2 19:02:53 1999

  --- scale.tcl.NEW       Sun Dec 26 12:08:52 1999

  ***************

  *** 211,222 ****


        if {[string equal $repeat "again"]} {

          set tkPriv(afterId) [after [$w cget -repeatinterval] \

  !               tkScaleIncrement $w $dir $big again]

        } elseif {[string equal $repeat "initial"]} {

          set delay [$w cget -repeatdelay]

          if {$delay > 0} {

              set tkPriv(afterId) [after $delay \

  !                   tkScaleIncrement $w $dir $big again]

          }

        }

    }

  --- 211,222 ----


        if {[string equal $repeat "again"]} {

          set tkPriv(afterId) [after [$w cget -repeatinterval] \

  !               [list tkScaleIncrement $w $dir $big again]]

        } elseif {[string equal $repeat "initial"]} {

          set delay [$w cget -repeatdelay]

          if {$delay > 0} {

              set tkPriv(afterId) [after $delay \

  !                   [list tkScaleIncrement $w $dir $big again]]

          }

        }

    }

  *** scrlbar.tcl.OLD     Wed Oct 20 03:02:24 1999

  --- scrlbar.tcl.NEW     Sun Dec 26 12:45:49 1999

  ***************

  *** 198,208 ****

        }

        if {[string equal $repeat "again"]} {

          set tkPriv(afterId) [after [$w cget -repeatinterval] \

  !               tkScrollSelect $w $element again]

        } elseif {[string equal $repeat "initial"]} {

          set delay [$w cget -repeatdelay]

          if {$delay > 0} {

  !           set tkPriv(afterId) [after $delay tkScrollSelect $w $element again]

          }

        }

    }

  --- 198,209 ----

        }

        if {[string equal $repeat "again"]} {

          set tkPriv(afterId) [after [$w cget -repeatinterval] \

  !               [list tkScrollSelect $w $element again]]

        } elseif {[string equal $repeat "initial"]} {

          set delay [$w cget -repeatdelay]

          if {$delay > 0} {

  !           set tkPriv(afterId) [after $delay \

  !                   [list tkScrollSelect $w $element again]]

          }

        }

    }

  ***************

  *** 258,266 ****

                      [expr {[lindex $tkPriv(initValues) 1] + $delta}]

          } else {

              set delta [expr {round($delta * [lindex $tkPriv(initValues) 0])}]

  !           eval $w set [lreplace $tkPriv(initValues) 2 3 \

                      [expr {[lindex $tkPriv(initValues) 2] + $delta}] \

  !                   [expr {[lindex $tkPriv(initValues) 3] + $delta}]]

          }

        } else {

          tkScrollToPos $w [expr {$tkPriv(initPos) + $delta}]

  --- 259,267 ----

                      [expr {[lindex $tkPriv(initValues) 1] + $delta}]

          } else {

              set delta [expr {round($delta * [lindex $tkPriv(initValues) 0])}]

  !           eval [list $w set [lreplace $tkPriv(initValues) 2 3 \

                      [expr {[lindex $tkPriv(initValues) 2] + $delta}] \

  !                   [expr {[lindex $tkPriv(initValues) 3] + $delta}]]]

          }

        } else {

          tkScrollToPos $w [expr {$tkPriv(initPos) + $delta}]

  *** tearoff.tcl.OLD     Thu Sep  2 19:02:53 1999

  --- tearoff.tcl.NEW     Sun Dec 26 20:02:51 1999

  ***************

  *** 93,99 ****


        set cmd [$w cget -tearoffcommand]

        if {[string compare $cmd ""]} {

  !       uplevel #0 $cmd $w $menu

        }

        return $menu

    }

  --- 93,99 ----


        set cmd [$w cget -tearoffcommand]

        if {[string compare $cmd ""]} {

  !       uplevel #0 $cmd [list $w $menu]

        }

        return $menu

    }

  *** text.tcl.OLD        Thu Sep  2 19:02:53 1999

  --- text.tcl.NEW        Sun Dec 26 12:15:11 1999

  ***************

  *** 634,640 ****

          return

        }

        tkTextSelectTo $w $tkPriv(x) $tkPriv(y)

  !     set tkPriv(afterId) [after 50 tkTextAutoScan $w]

    }


    # tkTextSetCursor

  --- 634,640 ----

          return

        }

        tkTextSelectTo $w $tkPriv(x) $tkPriv(y)

  !     set tkPriv(afterId) [after 50 [list tkTextAutoScan $w]]

    }


    # tkTextSetCursor

  *** tkfbox.tcl.OLD      Thu Dec 16 22:57:53 1999

  --- tkfbox.tcl.NEW      Sun Dec 26 12:22:25 1999

  ***************

  *** 150,156 ****

        }


        tkIconList_Motion1 $w $x $y

  !     set tkPriv(afterId) [after 50 tkIconList_AutoScan $w]

    }


    # Deletes all the items inside the canvas subwidget and reset the IconList's

  --- 150,156 ----

        }


        tkIconList_Motion1 $w $x $y

  !     set tkPriv(afterId) [after 50 [list tkIconList_AutoScan $w]]

    }


    # Deletes all the items inside the canvas subwidget and reset the IconList's

  ***************

  *** 555,561 ****

        catch {

          after cancel $tkPriv(ILAccel,$w,afterId)

        }

  !     set tkPriv(ILAccel,$w,afterId) [after 500 tkIconList_Reset $w]

    }


    proc tkIconList_Goto {w text} {

  --- 555,561 ----

        catch {

          after cancel $tkPriv(ILAccel,$w,afterId)

        }

  !     set tkPriv(ILAccel,$w,afterId) [after 500 [list tkIconList_Reset $w]]

    }


    proc tkIconList_Goto {w text} {

  ***************

  *** 933,939 ****

        if {[info exists data(updateId)]} {

          return

        } else {

  !       set data(updateId) [after idle tkFDialog_Update $w]

        }

    }


  --- 933,939 ----

        if {[info exists data(updateId)]} {

          return

        } else {

  !       set data(updateId) [after idle [list tkFDialog_Update $w]]

        }

    }


  *** xmfbox.tcl.OLD      Wed Nov 24 21:59:06 1999

  --- xmfbox.tcl.NEW      Sun Dec 26 12:26:13 1999

  ***************

  *** 786,792 ****

        catch {

          after cancel $tkPriv(lbAccel,$w,afterId)

        }

  !     set tkPriv(lbAccel,$w,afterId) [after 500 tkListBoxKeyAccel_Reset $w]

    }


    proc tkListBoxKeyAccel_Goto {w string} {

  --- 786,792 ----

        catch {

          after cancel $tkPriv(lbAccel,$w,afterId)

        }

  !     set tkPriv(lbAccel,$w,afterId) [after 500 [list tkListBoxKeyAccel_Reset $w]]

    }


    proc tkListBoxKeyAccel_Goto {w string} {


  PatchFiles:

  entry.tcl

      focus.tcl

      listbox.tcl

      scale.tcl

      scrlbar.tcl

      tearoff.tcl

      text.tcl

      tkfbox.tcl

      xmfbox.tcl




  fixed in 8.3b2 
  -- 01/03/2000 hobbs


tkt_uuid: 220501ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 40. Bitmap Images
priority: 2
foundin: obsolete: 8.1b3
resolution: Fixed
title: segmentation error with faulty stipple Bitmap
comment:
  OriginalBugID: 1853 Bug
  Version: 8.1b3
  SubmitDate: '1999-04-16'
  LastModified: '1999-04-16'
  Severity: SER
  Status: Released
  Submitter: pat
  ChangedBy: rjohnson
  OS: Solaris
  OSVersion: 2.5.1
  Machine: Other
  FixedDate: '1999-04-16'
  FixedInVersion: 8.1


  Name:

  Peter Weigand



  Comments:

  It is all over in the code: check if interp is not NULL and then call

      Tcl_AppendResult, Tcl_SetResult, ...

      Why not checking for interp not NULL in these functions instead of all

      over in the code. It makes life easier but execution of an application

      might be a little bit slower but it decreases the code size when the

      checking is done in the place where it should be (where you need the

      interp).

      If the checking for interp is done in the low level functions then it

      also removes some maybe still missing checks for "is the interp valid?".

      Actually the interp should be known globally so you do not have to pass

      it all the time and you can get all information returned. Just make a

      function like Tcl_GetActiveInterp and you never need to pass it. This

      might be a bit tricky to find out what is the interp I should use but If

      you have just one interp then it is really simple.



  ReproducibleScript:

  do a stipple bitmap where the bitmap has errors in a canvas create

      command



  ObservedBehavior:

  It results in a segmentation error because TkReadBitmapFile has no

      interp passed and then it calls TkGetBitmapData with interp NULL.

      Because of the faulty bitmap data it calls TclSetResult with interp NULL

      and there the segmentation error happens.



  DesiredBehavior:

  No segmentation errors at all.



  Patch:

  *** tkImgBmap.cWed Feb 17 03:18:35 1999

  --- tkImgBmap.c.newFri Apr 16 19:15:59 1999

  ***************

  *** 630,636 ****

        return data;

    

        error:

  !     Tcl_SetResult(interp, "format error in bitmap data", TCL_STATIC);

    

        errorCleanup:

        if (data != NULL) {

  --- 630,638 ----

        return data;

    

        error:

  !     if (interp != NULL) {

  ! Tcl_SetResult(interp, "format error in bitmap data", TCL_STATIC);

  !     }

    

        errorCleanup:

        if (data != NULL) {



  PatchFiles:

  tkImgBmap.c





  Applied patch - 04/16/1999 19:34 - rjohnson -


tkt_uuid: 1072904fffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 04. Canvas Basics
priority: 5 Medium
foundin: None
resolution: Wont Fix
title: -highlightthickness/-borderwidth change canvas origin
comment:
  The -borderwidth and -highlightthickness options will steal pixels from    
  the  upper left side of a canvas and give them to the lower right.
            
  Example code:
  pack [canvas .c -height 100 -width 100 -bg red]
  .c create rectangle 1 1 10 10
  .c create rectangle 90 90 99 99
  .c configure -borderwidth 0 -highlightthickness 0

  There is a 1 pixel space between the rectangle and the left and top
  edges of the canvas, and no space between the rectangle and the
  bottom/right edges of the canvas.

  .c configure -borderwidth 1

  There is now no space between the rectangle and the left/top edges
  of the canvas, and a 1 pixel space between the rectangle and the
  bottom/right edges.

  Increasing the borderwidth, or highlightthickness steals more pixels
  from the upper left, and adds more to the lower right.

  This behavior exists at least as far back as wish 4.0.

  Changing -borderwidth and -hightlightthickness on a label widget
  does not change the appearance of the label.


   
   


tkt_uuid: 556350ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 99. Other
priority: 5 Medium
foundin: None
resolution: Fixed
title: Tk 8.4a5 core dump on Exit
comment:
  I am attaching a transcript of a core dump found in the
  Tk 8.4a5 from May 7, 2002 snapshot stored at
  activestate.com's ftp site.

  When running the following program:
  #!/bin/sh
  # the next line restarts using wish \
  exec /usr/tcl84/bin/wish "$0" "$@"

  package require Iwidgets

  button .exit_bt -text "Exit" -command "destroy ."

  iwidgets::combobox .combo -textfont {Helvetica -12 bold}

  pack .exit_bt

  and pressing the resulting button, I get a core dump.
  The stack trace included appears to be pointing to Tk
  from what I can tell.

  Tcl/Tk from CVS head
  Compiled with Sun's C compiler under SPARC Solaris 2.6.
  Running on CDE wm Solaris 8 Sun Blade.


tkt_uuid: 3587262fffffffffffffffffffffffffffffffff
type: Bug
status: Open
subsystem: 03. [*button] and [label]
priority: 5 Medium
foundin: obsolete: 8.5.11
resolution: None
title: Width of menubutton too short on aqua with textvariable
comment:
  The attached code shows a bug in menubutton on MacOS (aqua): if I specify the font and use textvariable then the menubutton is displayed in a width that is far too narrow.

  I tried to work around it using update idletasks and had no luck.

  One workaround that does work is to change the font size in the option database and then change it back again. This causes an ugly display glitch but it's better than nothing.


tkt_uuid: 3122271fffffffffffffffffffffffffffffffff
type: Bug
status: Open
subsystem: 88. Themed Tk
priority: 5 Medium
foundin: obsolete: 8.5.8
resolution: None
title: Selecting in a ttk::combobox listbox can remove focus
comment:
  On Linux systems, hitting enter on a listbox item of a ttk::combobox causes the combobox to lose focus if the combobox's parent window has the overrideredirect flag set. No such problems on Windows. All is well if the overrideredirect setting is removed.


tkt_uuid: 2817531fffffffffffffffffffffffffffffffff
type: Bug
status: Open
subsystem: 08. [(label)frame] and [toplevel]
priority: 5 Medium
foundin: obsolete: 8.5.7
resolution: None
title: "wm manage" is deficient and flickering
comment:
  NOTE:
  I tried the following with x11 windowing system. I don't know
  the behaviour with win32 and aqua.

  Please try the following code:
  ----------------------------------------------------------------------------------------
  wm withdraw .
  frame .f1 -width 800 -height 800
  frame .f2 -width 800 -height 800
  button .f1.l -text Undock -command { Undock .f2 }
  pack .f1.l
  pack .f1 .f2
  ::tk::PlaceWindow . center
  wm deiconify .
  proc Undock {w} {
     pack forget $w
     wm manage $w
     wm overrideredirect $w
     wm protocol $w WM_DELETE_WINDOW [list Dock $w]
     ::tk::PlaceWindow $w center [winfo parent $w]
  }
  proc Dock {w} {
     wm forget $w
     pack $w
  }
  ----------------------------------------------------------------------------------------

  1. I'm using large windows too make it easier too see the problem.
  2. "wm overrideredirect" is not working. It comes too late because
     the (managed)  window is already mapped. But I cannot use this
     before managing.
  3. The popup is flickering a lot. This has two reasons:
     a) In function WmManageCmd (unix/tkUnixWm.c) you see:
            2675: TkWmMapWindow(winPtr);
            2676: Tk_UnmapWindow(frameWin);
         This must flicker. These statements are superfluous.
         I tried this without these two lines and the function
         is working! But it flickers still a bit because:
     b) ::tk::PlaceWindow comes too late because the
         (managed) window is already mapped (normally 
        in the upper left corner). It should help if
        "wm manage" has an option like -unmapped.
        Without such an option the window cannot be placed
        flicker-free. And without such an option you
       cannot use "wm overrideredirect".


tkt_uuid: 3301552fffffffffffffffffffffffffffffffff
type: Bug
status: Open
subsystem: 88. Themed Tk
priority: 1 Zero
foundin: obsolete: 8.5.9
resolution: None
title: ttk::spinbox -font does not resize buttons
comment:
  tk8.5.9 on Windows Vista with native theme.
  ttk::spinbox with a custom large font.
  There apears space between the spinbuttons.
  See http://wiki.tcl.tk/22156 for an example and a screenshot

  This is not a bug, but the graphical presentation might be nicer.

  Thank you for all the work making Ttk so great !


tkt_uuid: 3130038fffffffffffffffffffffffffffffffff
type: Bug
status: Open
subsystem: 04. Canvas Basics
priority: 5 Medium
foundin: obsolete: 8.5.9
resolution: None
title: -dash crash in canvas lines
comment:
  The canvas -dash option regularly causes X_CreateGC X errors when running on Mac OS X in X11 mode over ssh to a debian etch (linux) desktop. I don't have console access to a Mac to test this locally so I cannot say if it's reproducable when using a local X11 server or when using the aqua native interface.

  The example code:

  set c [canvas .c -bg black]
  pack .c -fill both -expand 1
  bind .c <Any-Motion> {xhair_move .c %x %y}
  bind .c <Any-Leave> {.c delete withtag xhair}

  proc xhair_move {c x y} {
      $c delete withtag xhair
      $c create line $x 0 $x 1000 -tags xhair -fill green -dash {6 4 2 4 2 4}
      $c create line 0 $y 1000 $y -tags xhair -fill green -dash {6 4 2 4 2 4}
  }

  On linux this works fine. On Mac OS (darwin 9.8.0) with a local build of tk 8.5.9 it sometimes draws a line and sometimes fails with:

  X Error of failed request:  BadValue (integer parameter out of range for operation)
    Major opcode of failed request:  55 (X_CreateGC)
    Value in failed request:  0x340000a
    Serial number of failed request:  316
    Current serial number in output stream:  324

  This is inside the X libraries:

  #0  0x945b8c75 in exit ()
  #1  0x0014e0ea in _XDefaultError ()
  #2  0x0b01a2c6 in ErrorProc (display=0x80da00, errEventPtr=0xbfffe020) at /nfs/sam_scratch/jkb/src/tk8.5.9/unix/../generic/tkError.c:285
  #3  0x0014e1ef in _XError ()
  #4  0x0014e7d3 in _XReply ()
  #5  0x0014877a in XSync ()
  #6  0x00148819 in _XSyncFunction ()
  #7  0x0012aa49 in XCreateGC ()
  #8  0x0b0238a7 in Tk_GetGC (tkwin=0x4323b0, valueMask=3145972, valuePtr=0xbfffe268) at /nfs/sam_scratch/jkb/src/tk8.5.9/unix/../generic/tkGC.c:256
  #9  0x0b0795fc in ConfigureLine (interp=0x806a00, canvas=0x4264e0, itemPtr=0x48a650, objc=6, objv=0xe53a4, flags=0) at /nfs/sam_scratch/jkb/src/tk8.5.9/unix/../generic/tkCanvLine.c:524
  #10 0x0b079087 in CreateLine (interp=0x806a00, canvas=0x4264e0, itemPtr=0x48a650, objc=10, objv=0xe5394) at /nfs/sam_scratch/jkb/src/tk8.5.9/unix/../generic/tkCanvLine.c:334
  #11 0x0b069688 in CanvasWidgetCmd (clientData=0x4264e0, interp=0x806a00, objc=13, objv=0xe5388) at /nfs/sam_scratch/jkb/src/tk8.5.9/unix/../generic/tkCanvas.c:977

  Bizarrely, using "-dash -.." works, despite this in theory being identical to {6 4 2 4 2 4}. Also {6 4 2 4} works. Experimentally it just seems to be any dash pattern longer than that, so maybe it's a corruption in the dash parsing code.


tkt_uuid: 1962404fffffffffffffffffffffffffffffffff
type: Bug
status: Open
subsystem: 08. [(label)frame] and [toplevel]
priority: 5 Medium
foundin: obsolete: 8.4.19
resolution: None
title: "exit handlers were created during Tcl_Finalize" error
comment:
  DestroyNotify events on frames call TkSetWindowMenuBar to configure the menu for thr frame, which in turn registers for notice of program exit. Unfortunately if the window is being destroyed due to program exit then this causes the Tcl_Finalize function to abort() with a "exit handlers were created during Tcl_Finalize" message.

  The following example demonstrates it:

  wm protocol . WM_DELETE_WINDOW "exit"
  . configure -menu .m

  A workaround is to reset the frame menus before exiting. Eg:

  wm protocol . WM_DELETE_WINDOW "shutdown"
  . configure -menu .m

  proc shutdown {} {
      . configure -menu {}
      exit
  }

  This only happens when WM_DELETE_WINDOW is used on a window configured to have a menu, but I'm not entirely sure why.

  Commenting out the TkSetWindowMenuBar call cures the problem. Ie:

  *** tkFrame.c~  Sun Apr 29 03:24:02 2007
  --- tkFrame.c   Mon May 12 14:57:26 2008
  ***************
  *** 1627,1634 ****
          goto redraw;
        } else if (eventPtr->type == DestroyNotify) {
          if (framePtr->menuName != NULL) {
  -           TkSetWindowMenuBar(framePtr->interp, framePtr->tkwin,
  -                   framePtr->menuName, NULL);
              ckfree(framePtr->menuName);
              framePtr->menuName = NULL;
          }
  --- 1627,1632 ----

  I'm unsure of the impact of this change though. I cannot see why we'd ever want to reconfigure the menu bar of a window that is about to be destroyed, but that most likely means I'm missing something here.

  James


tkt_uuid: 3598564fffffffffffffffffffffffffffffffff
type: Bug
status: Open
subsystem: 62. Geometry Functions
priority: 5 Medium
foundin: current: 8.6.0
resolution: None
title: wm maxsize does not take into account task bar on Windows 7
comment:
  On my Windows 7 box with a 768px screen, wm maxsize returns 750. This does not take into account the size of the task bar, which means that natural height of windows can be more than the \"usable\" screen height, making the window appear _behind_ the task bar (see screenshot).

  This problem is visible e.g. when one widget has a fixed height, but the one stacked below it does not. In that case, the window\'s natural size should be limited to the usable screen size so that it stops right above the task bar. What happens at the moment is that the second widget, which has no fixed size, only shrinks when the window would exceed the value of \"wm maxsize\". This example (used in the screenshot) illustrates the problem:
  toplevel .w
  text .w.t1 -height 25
  text .w.t2
  grid .w.t1
  grid .w.t2
  update
  wm geometry .w
  wm maxsize .w

  (Just change \"-height 25\" so that the first text box takes the most part of your screen\'s height.)


  This problem also happened with Tk 8.5. I have not tested this under Windows 7 SP1 (upgrade bug).


tkt_uuid: 574075ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 44. Generic Fonts
priority: 5 Medium
foundin: obsolete: 8.4a5
resolution: Duplicate
title: 8.4b1 font.test fails during make test
comment:
  something in the changes in the last 24 hrs or so for
  tk now causes this test suite failure:

  font.test

  ==== font-32.1 Tk_TextLayoutToPostscript: ensure buffer
  doesn't overflow FAILED
  ==== Contents of test case:

      # If there were a whole bunch of returns or tabs in
  a row, then the
      # temporary buffer could overflow and write on the
  stack.
      
      csetup
  "qwertyuiopasdfghjklzxcvbnm1234qwertyuiopasdfghjklzxcvbnm\n"
      .b.c itemconfig text -width 800
      .b.c insert text end
  "qwertyuiopasdfghjklzxcvbnm1234qwertyuiopasdfghjklzxcvb
  nm\n"
      .b.c insert text end
  "\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n
  \n\n\n"
      .b.c insert text end "end"
      set x [.b.c postscript]
      set i [string first "(qwerty" $x] 
      string range $x $i [expr {$i + 213}]

  ---- Result was:
  (qwertyuiopasdfghjklzxcvbnm1234qwertyuiopasdfghjklzxcvbnm)]
  [(qwertyuiopasdfghjklzxcvbnm1234qwertyuiopasdfghjklzxcvbnm)]
  [()]
  [()]
  [()]
  [()]
  [()]
  [()]
  [()]
  [()]
  [()]
  [()]
  [()]
  [()]
  [()]
  [()]
  [()]
  [()]
  [()]
  [()]
  [()
  ---- Result should have been:
  (qwertyuiopasdfghjklzxcvbnm1234qwertyuiopasdfghjklzxcvbnm)
  (qwertyuiopasdfghjklzxcvbnm1234qwertyuiopasdfghjklzxcvbnm)
  ()
  ()
  ()
  ()
  ()
  ()
  ()
  ()
  ()
  ()
  ()
  ()
  ()
  ()
  ()
  ()
  ()
  ()
  ()
  ()
  ()
  ()
  ()
  ()
  ()
  ()
  ()
  ()
  ()
  ()
  (end)
  ==== font-32.1 FAILED


  Platform: SPARC Solaris 2.6
  Sun C compiler
  Desktop: CDE (Solaris 8)
  Tcl/Tk 8.4b1 built from the June 26, 2002 download of
  cvs head from activestate's ftp site.


tkt_uuid: 3613675fffffffffffffffffffffffffffffffff
type: Bug
status: Open
subsystem: 05. Canvas Items
priority: 5 Medium
foundin: None
resolution: None
title: canvText-17.1 is font sensitive
comment:
  canvText-17.1 fails on systems where a request
  for a {Courier 12 italic} font does not lead to something
  with the name matching */Courier-Oblique* getting
  put in the Postscript.


tkt_uuid: 220388ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 10. Generic Menus
priority: 2
foundin: obsolete: 8.0.3
resolution: Fixed
title: F10 does not post a menu on Win NT
comment:
  OriginalBugID: 746 Bug
  Version: 8.0.3
  SubmitDate: '1998-10-21'
  LastModified: '1999-08-06'
  Severity: MED
  Status: Released
  Submitter: pat
  ChangedBy: hobbs
  OS: All
  OSVersion: NA
  Machine: NA
  FixedDate: '1999-08-06'
  FixedInVersion: 8.2


  Test script:

  wm title . "Solitaire"

  frame .mbar -borderwidth 2 -relief raised
  pack .mbar -side top -fill x

  menubutton .mbar.game -text "Game" -menu .mbar.game.menu
  pack .mbar.game -side left -padx 4

  menu .mbar.game.menu
  .mbar.game.menu add command -label "Deal" -command {
      exit
  }
  .mbar.game.menu add separator
  .mbar.game.menu add command -label "Quit" -command {
      exit
  }

  Run this script on Solaris and press F10. The first menu button is activated. This does not happen on Win NT. However, if the menu is created by assigning it to the toplevel window with -menu, the F10 key seems to work fine. The new menu is created as follows:

  wm title . "Solitaire"

  menu .mbar 
  . configure -menu .mbar

  .mbar add cascade -label "Game" -menu .mbar.game
  menu .mbar.game
  .mbar.game add command -label "Deal" -command {
      exit
  }
  .mbar.game add command -label "Quit" -command {
      exit
  }



  8.2 (fixed somewhere earlier) has the bindings for F10 and
  regular menubuttons in core now. 
  -- 08/06/1999 hobbs


tkt_uuid: 853398ffffffffffffffffffffffffffffffffff
type: Bug
status: Open
subsystem: 86. Test Tools
priority: 5 Medium
foundin: obsolete: 8.4.5
resolution: None
title: unixEmbed-5.1 EmbedFocusProc procedure, FocusIn events FAILE
comment:
  On Tru64Unix 5.1A with tk8.4.5 I get:

  $ ./tktest ../tests/unixEmbed.test -verbose e

  ==== unixEmbed-5.1 EmbedFocusProc procedure, FocusIn
  events FAILED
  ---- Result was:

  ---- Result should have been (exact matching):
  {focus in .t1}
  ==== unixEmbed-5.1 FAILED

  unixEmbed.test: Total   33      Passed  29      Skipped
  3       Failed  1
  Number of tests skipped for each constraint:
          3       nonPortable
  $


tkt_uuid: 446699ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 03. [*button] and [label]
priority: 5 Medium
foundin: obsolete: 8.3.3
resolution: Works For Me
title: label configure -state active crashes
comment:
  Running tcl/tk 8.3.3 on Windows 2000; fatal crash when feeding the following script to wish83:
      label .l -text Foo -highlightthickness 2 -background white -highlightcolor red -highlightbackground green
      pack .l
      .l configure -state active


tkt_uuid: 220334ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 18. [text]
priority: 2
foundin: obsolete: 8.4a1
resolution: Fixed
title: Keypress binding keystrokes appear in text widget
comment:
  OriginalBugID: 5943 Bug
  Version: 8.4a1
  SubmitDate: '2000-06-24'
  LastModified: '2000-06-25'
  Severity: LOW
  Status: Released
  Submitter: shawn
  ChangedBy: shawn
  OS: Windows 2000
  ClosedDate: '2000-06-25'


  I have a binding a binding on a toplevel widget that causes the focus to enter an entry widget - where I anticipate entering some text - the binding is <KeyPress-:> so that I expect the ":" not to appear in the text widget - and I also don't expect to see it in the entry widget (i explicitly put in in the entry widget with this code). 

  This behavior doesn't change if I change the binding to be explicitly on the text widget. 

  Perhaps this is the expected result- since I find that if I bind explicitly to the text widget and break out of the binding it gives the expected behavior. 

  To reproduce execute this code: 

  set env(command) ""
  set win [toplevel .t ]
  set env(dialog) [text $win.a -width 40]
  pack $env(dialog) -fill both -expand true 
  set env(commandWin) [entry $win.b -textvariable env(command)]

  pack $win.b -fill x -expand true 
  bind $env(dialog) <Escape> {

      bind $win <KeyPress-:> {
          focus -force $env(commandWin)
          bind $win <KeyPress-:> {}
          $env(commandWin) insert end :
          bind <FocusOut> $env(commandWin) { 
              switch -regexp $env(command)  {
                  {^:w } {
                       # assumes filename is the balance of the command 
                       set filename [regsub {^:w } $env(command) ""]
                       saveFile $filename 
                  }

                  * {} 
             }
             bind <FocusOut> $env(commandWin) {}      
         }
  #       focus $env(dialog)
      }

      bind $win <KeyPress-/> {
          focus $env(commandWin)
          # Put bindings for searches here 
          bind $win <KeyPress-/> {}
          $env(commandWin) insert end /
          bind <FocusOut> $env(commandWin) {}      
   #      focus $env(dialog)
      }
  }

  #eof

  Force focus on the text widget by clicking in the window with the mouse.  strike the <escape> key and then type a slash {/} to trigger the bindings. Notice that the / appears in the text widget - 

  Expected result:  I expect not to see the slash in the text widget - but instead just to have that keystroke trigger the binding.  

  This binding will give the expected result:

  #
    bind $env(dialog) <KeyPress-/> {
          focus $env(commandWin)
          # Put bindings for searches here 
          bind $win <KeyPress-/> {}
          $env(commandWin) insert end /
          bind <FocusOut> $env(commandWin) {}      
   #      focus $env(dialog)
          break
      }
  #eof



  This is the expected behavior.  From the bind manpage:

  MULTIPLE MATCHES
         It  is  possible  for  several bindings to match a given X
         event.  If the  bindings  are  associated  with  different
         tag's,  then  each  of  the  bindings will be executed, in
         order.  By default, a binding for the widget will be  exe-
         cuted  first,  followed  by a class binding, a binding for
         its toplevel, and an all binding.   The  bindtags  command
         may  be  used to change this order for a particular window
         or to associate additional binding tags with the window.

         The continue and break commands may be used inside a bind-
         ing  script to control the processing of matching scripts.
         If continue is invoked, then the current binding script is
         terminated but Tk will continue processing binding scripts
         associated with other tag's.   If  the  break  command  is
         invoked  within  a binding script, then that script termi-
         nates and no other scripts will be invoked for the  event.

  This is exactly what you have already discovered; when multiple bindings match an event, and each is attached to a different bindtag, then all of the bindings are executed.  In this case, your custom binding and the default text widget KeyPress binding (which inserts the typed character) are both firing.  As you noted, you can use break to change this behavior.

  - eric

  -- 06/25/2000 ericm

  I am happy 

  -- 06/25/2000 shawn


tkt_uuid: 673687ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 01. Bindings
priority: 5 Medium
foundin: None
resolution: None
title: Entry widget inputs goes right-to-left
comment:
  Sometimes when you are typing into an entry widget, the
  characters
  will be inserted from right to left instead of from
  left to right.
  To see this, first create an entry widget.  For example:

         entry .e -width 30
         pack .e -padx 10 -pady 10

  Now enter some text into this widget.  With the mouse,
  click to
  the right of the text and drag the mouse all the way to
  the left past
  the beginning of the widget.  All text in the widget
  should become
  highlighted.  Continue holding down the mouse button
  and start
  typing.  The first key press deletes the selected text
  (which is correct)
  and inserts the typed key.  The second key press is
  inserted to the left
  of the first character instead of to the right.

  You can well argue that this is an unusual case since
  not many people
  begin typing with the mouse button still held down. 
  But sometimes
  (on the OS of the monopolist) a stray button-press
  event will leak into
  a widget as the widget is being created.  Thus Tk might
  think the
  button is being held down even when it is not.  (This
  is rare, and
  perhaps another bug - but it does happen.)

  The fix to this problem is simply to add a call to
  ::tk::CancelRepeat in the <KeyPress> binding of
  the entry widget.  I'll do that straight away.  The
  purpose of this bug report is merely to document
  what was done.


tkt_uuid: 1158738fffffffffffffffffffffffffffffffff
type: Bug
status: Open
subsystem: 68. Win Window Operations
priority: 6
foundin: obsolete: 8.4.11
resolution: None
title: transient window madness
comment:
  On Windows XP Home SP2.
  This also happens in 8.4.9.

  2 examples. Copy/paste each line into the wish console 
  separately, or copy all lines (except the last line) of 
  each example. Comments show the problem.

  # Example 1 -- transient won't show itself
  toplevel .t1 ; wm withdraw .t1 ; update
  toplevel .t2 ; wm withdraw .t2 ; wm transient .t2 .t1 ; 
  update
  wm deiconify .t1 ; update ; # Displays ok
  wm deiconify .t2 ; update ; # Doesn't display
  raise .t2 ; # Now displays. Or minimize .t1 and restore -
  > .t2 appears

  # Example 2 -- transient isn't transient
  toplevel .t1 ; wm withdraw .t1 ; update
  toplevel .t2 ; wm withdraw .t2 ; update
  wm transient .t2 .t1 ; update
  wm deiconify .t1 ; update ; # Displays ok
  wm deiconify .t2 ; update ; # Displays ok, but not 
  transient to .t1
  wm withdraw .t1 ; update ; wm deiconify .t1 ; # Now .t2 
  appears/acts transient


tkt_uuid: 621811ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 18. [text]
priority: 5 Medium
foundin: obsolete: 8.4.0
resolution: Fixed
title: search -count var ignores elided chars
comment:
  when textwidget searches a sequence with elided chars
  inside, counting the found chars doesn't work properly.
  Try this:

  (bin) 1 % info patchlevel
  8.4.0
  (bin) 2 % pack [text .t]
  (bin) 3 % .t insert 1.0 {My name is Otto.}
  (bin) 4 % .t search -count cnt Otto 1.0
  1.11
  (bin) 5 % set cnt
  4
  (bin) 6 % # as expected
  (bin) 7 % .t tag configure hidden -elide yes
  (bin) 8 % .t tag add hidden 1.12 1.14
  (bin) 9 % # .t displays: My name is Oo.
  (bin) 10 % .t search -count cnt Oo 1.0
  1.11
  (bin) 11 % set cnt
  2
  (bin) 12 % # cnt contains 2 (the visible letters Oo)
  (bin) 13 % # but should contain 4 (including the hidden tt)

  workaround: find out, which chars are elided by
  programming. Quite heavy. 


tkt_uuid: 1662959fffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 37. [tk_get*File]
priority: 9 Immediate
foundin: obsolete: 8.4.14
resolution: Fixed
title: tk_getOpenFile: can't read "textList(0)": no such variable
comment:
  Steps to reproduce:

  $ mkdir empty_dir
  $ wish
  % tk_getOpenFile -initialdir empty_dir

  Click on the canvas in the file selection dialog.
  Press <Esc>.

  An error messagebox pops up:
  --------------------
  can't read "textList(0)": no such variable
      while executing
  "string range $textList($i) 0 $len0"
      (procedure "IconList_Goto" line 29)
      invoked from within
  "IconList_Goto $w $Priv(ILAccel,$w)"
      (procedure "tk::IconList_KeyPress" line 5)
      invoked from within
  "tk::IconList_KeyPress .__tk_filedialog.icons \x1b"
      (command bound to event)
  --------------------

  Observed on tk-8.4.14 (and also previous versions), running on Linux Fedora Core 5.


  Regards,
    Grigory Trenin


tkt_uuid: 903415ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 85. Win Build
priority: 5 Medium
foundin: obsolete: 8.5a0
resolution: Invalid
title: Build warnings under mingw
comment:
  Building with mingw gcc under win2k produces some warnings:

  gcc.exe (GCC) 3.2 (mingw special 20020817-1)

  Michael


tkt_uuid: 219965ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 42. Photo Image|GIF
priority: 1 Zero
foundin: obsolete: 8.1b2
resolution: Duplicate
title: Displaying Gif-Images on an EBCDIC machine
comment:
  OriginalBugID: 1723 Bug
  Version: 8.1b2
  SubmitDate: '1999-04-05'
  LastModified: '1999-04-05'
  Severity: MED
  Status: Closed
  Submitter: pat
  ChangedBy: pat
  OS: Other
  OSVersion: OS/390 4.0
  Machine: NA
  ClosedDate: '1999-04-05'


  Name:

  Christian Krone



  Extensions:

  Expect



  ReproducibleScript:

  On an EBCDIC machine (OS/390) Tk doesn't display gif images.



  DesiredBehavior:

  Tk should display gif images on an EBCDIC machine,

      if you transfer the images binary (without conversion from ascii to

      ebcdic).



  Patch:

  *** tkImgGIF.c.orgSat Mar 13 19:09:20 1999

  --- tkImgGIF.cTue Mar 23 14:54:04 1999

  ***************

  *** 61,66 ****

  --- 61,89 ----

    #include "tkPort.h"

    

    /*

  +  * EBCDIC-Support:

  +  * Images in the GIF format contain binary pixel values and must not be

  +  * victim of an ASCII to EBCDIC translation. Unfortunately, the GIF header

  +  * and some special markers inside the file are still ASCII characters

  +  * then. They cannot be compared to EBCDIC strings and chars, which are

  +  * produced by the compiler.

  +  */

  + 

  + #if ' ' == 0x20 /*ASCII*/

  + #  define GIF87a         "GIF87a"

  + #  define GIF89a         "GIF89a"

  + #  define GIF_TERMINATOR ';'

  + #  define GIF_EXTENSION  '!'

  + #  define GIF_START      ','

  + #else /* EBCDIC */

  + #  define GIF87a         "\x47\x49\x46\x38\x37\x61"

  + #  define GIF89a         "\x47\x49\x46\x38\x39\x61"

  + #  define GIF_TERMINATOR 0x3b

  + #  define GIF_EXTENSION  0x21

  + #  define GIF_START      0x2c

  + #endif

  + 

  + /*

     *  HACK ALERT!!  HACK ALERT!!  HACK ALERT!!

     * This code is hard-wired for reading from files.  In order to read

     * from a data stream, we'll trick fread so we can reuse the same code

  ***************

  *** 276,282 ****

        break;

    }

    

  ! if (buf[0] == ';') {

        /*

         * GIF terminator.

         */

  --- 299,305 ----

        break;

    }

    

  ! if (buf[0] == GIF_TERMINATOR) {

        /*

         * GIF terminator.

         */

  ***************

  *** 284,290 ****

        break;

    }

    

  ! if (buf[0] == '!') {

        /*

         * This is a GIF extension.

         */

  --- 307,313 ----

        break;

    }

    

  ! if (buf[0] == GIF_EXTENSION) {

        /*

         * This is a GIF extension.

         */

  ***************

  *** 303,309 ****

        continue;

    }

    

  ! if (buf[0] != ',') {

        /*

         * Not a valid start character; ignore it.

         */

  --- 326,332 ----

        continue;

    }

    

  ! if (buf[0] != GIF_START) {

        /*

         * Not a valid start character; ignore it.

         */

  ***************

  *** 405,412 ****

        mInit((unsigned char *) string, &handle);

        got = Mread(header, 10, 1, &handle);

        if (got != 10

  !     || ((strncmp("GIF87a", (char *) header, 6) != 0)

  !     && (strncmp("GIF89a", (char *) header, 6) != 0))) {

    return 0;

        }

        *widthPtr = LM_to_uint(header[6],header[7]);

  --- 428,435 ----

        mInit((unsigned char *) string, &handle);

        got = Mread(header, 10, 1, &handle);

        if (got != 10

  !     || ((strncmp(GIF87a, (char *) header, 6) != 0)

  !     && (strncmp(GIF89a, (char *) header, 6) != 0))) {

    return 0;

        }

        *widthPtr = LM_to_uint(header[6],header[7]);

  ***************

  *** 489,496 ****

        unsigned char buf[7];

    

        if ((Fread(buf, 1, 6, chan) != 6)

  !     || ((strncmp("GIF87a", (char *) buf, 6) != 0)

  !     && (strncmp("GIF89a", (char *) buf, 6) != 0))) {

    return 0;

        }

    

  --- 512,519 ----

        unsigned char buf[7];

    

        if ((Fread(buf, 1, 6, chan) != 6)

  !     || ((strncmp(GIF87a, (char *) buf, 6) != 0)

  !     && (strncmp(GIF89a, (char *) buf, 6) != 0))) {

    return 0;

        }



  PatchFiles:

  tkImgGIF.c





  04/05/1999 12:03 - pat -duplicate of 1605


tkt_uuid: 2814003fffffffffffffffffffffffffffffffff
type: Bug
status: Open
subsystem: 56. [grab]
priority: 5 Medium
foundin: obsolete: 8.5.7
resolution: None
title: tk_messageBox unresponsive on global grab
comment:
  A message box is inresponsive, if there is a global grab on another widget.

  Example:
  pack [button .b -text t -command "tk_messageBox"]
  focus .b
  raise .
  grab -global .b

  This might be seen as feature, but it might be helpful, to replace the grab of message box by the existing grab, and restore it afterwards.

  On Windows XP, tk 8.5.7


tkt_uuid: 1224235fffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 33. Generic Dialog Support
priority: 5 Medium
foundin: obsolete: 8.5a3
resolution: Fixed
title: bgerrorDialog error message truncation
comment:
  bgerrorDialog truncates long error messages, to avoid
  popping up a gonzo huge modal dialog box.  This is a
  good thing, but I think the current limit of 30
  characters is too conservative.  (For example: if a
  script calls "checkbuton $foo..." (note mispeling), the
  error dialog will say 'Error: invalid command name
  "checkbut...').

  Following the typographer's rule of "one and a half to
  two alphabets", perhaps 40-52 characters would be a
  better upper limit?


tkt_uuid: 220507ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 56. [grab]
priority: 2
foundin: obsolete: 8.1b3
resolution: Fixed
title: Docs missing for Tk_Grab API
comment:
  OriginalBugID: 1868 Bug
  Version: 8.1b3
  SubmitDate: '1999-04-16'
  LastModified: '2000-04-24'
  Severity: MED
  Status: Released
  Submitter: surles
  ChangedBy: ericm
  OS: All
  OSVersion: NA
  Machine: NA
  FixedDate: '2000-04-24'
  FixedInVersion: 8.3.1


  .

  I added a man entry for this API for 8.3.1.

  - eric
   
  -- 04/24/2000 ericm


tkt_uuid: 1923684fffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 03. [*button] and [label]
priority: 8
foundin: None
resolution: Fixed
title: checkbox incompatible behaviour
comment:
  This thing:
  ---
    checkbutton $w.taskBar.dtwo -text "2-D" -onvalue "--dtwo" -offvalue "" -variable ${w}dtwo
  ---
  acts(drawn) as tristate checkbox, but such behaviour was not implied by the command.
  Such behaviour is not compatible with 8.14 tk.

  Andrey Gusev
  ag888@rambler.ru


tkt_uuid: 1696913fffffffffffffffffffffffffffffffff
type: Bug
status: Open
subsystem: 84. Unix Build
priority: 5 Medium
foundin: obsolete: 8.5a5
resolution: None
title: "--enable-xft" - compile error / missing in README
comment:
  Three things:

  1) "--enable-xft" isn't documented in the file unix/README; I only noticed this option while reading the newsgroup comp.lang.tcl ...

  2) This option causes an error while compiling the source on "FreeBSD 6.0-RELEASE": "./configure --enable-xft" fully works without an error, but "make" fails:

  -----------------------------------------------------------------------

  ld -Bshareable -x -o libtk8.5.so tk3d.o tkArgv.o tkAtom.o tkBind.o tkBitmap.o tkClipboard.o  tkCmds.o tkColor.o tkConfig.o tkConsole.o tkCursor.o tkError.o  tkEvent.o tkFocus.o tkFont.o tkGet.o tkGC.o tkGeometry.o tkGrab.o  tkGrid.o tkMain.o tkObj.o tkOldConfig.o tkOption.o tkPack.o tkPlace.o  tkSelect.o tkStyle.o tkUndo.o tkUtil.o tkVisual.o tkWindow.o tkButton.o tkEntry.o tkFrame.o tkListbox.o  tkMenu.o tkMenubutton.o tkMenuDraw.o tkMessage.o  tkPanedWindow.o tkScale.o tkScrollbar.o tkCanvas.o tkCanvArc.o tkCanvBmap.o tkCanvImg.o  tkCanvLine.o tkCanvPoly.o tkCanvPs.o tkCanvText.o  tkCanvUtil.o tkCanvWind.o tkRectOval.o tkTrig.o tkImage.o tkImgBmap.o tkImgGIF.o tkImgPPM.o tkImgPhoto.o tkText.o tkTextBTree.o tkTextDisp.o tkTextImage.o tkTextIndex.o  tkTextMark.o tkTextTag.o tkTextWind.o  tkStubInit.o tkStubLib.o tkUnix.o tkUnix3d.o tkUnixButton.o tkUnixColor.o tkUnixConfig.o  tkUnixCursor.o tkUnixDraw.o tkUnixEmbed.o tkUnixEvent.o  tkUnixFocus.o  tkUnixRFont.o tkUnixInit.o tkUnixKey.o tkUnixMenu.o  tkUnixMenubu.o tkUnixScale.o tkUnixScrlbr.o tkUnixSelect.o  tkUnixSend.o tkUnixWm.o tkUnixXId.o -L/usr/X11R6/lib -lX11 -lXss -lXext -L/usr/X11R6/lib -lXft -lX11 -L/usr/local/lib -Wl,--rpath -Wl,/usr/local/lib -lfreetype -lz -L/usr/X11R6/lib -lfontconfig -L/usr/X11R6/lib -lXrender -lX11 -lXext   -lm -L/home/jo/tcl8.5a5/unix -ltclstub8.5   -rpath /usr/local/lib:/usr/X11R6/lib
  ld: unrecognized option '-Wl,--rpath'
  ld: use the --help option for usage information
  *** Error code 1

  Stop in /usr/home/jo/tk8.5a5/unix.

  -----------------------------------------------------------------------

  Without this option everything works.

  3) Found some referers to version 8.4:

  | jo@jeroboam ~>  grep -r "package require" tk8.5a5/ | grep "8.4"
  | tk8.5a5/library/demos/ixset:package require Tcl 8.4
  | tk8.5a5/library/demos/rmt:package require Tcl 8.4
  | tk8.5a5/library/demos/tcolor:package require Tk 8.4
  | tk8.5a5/library/demos/timer:package require Tcl 8.4
  | tk8.5a5/tests/all.tcl:package require Tcl 8.4
  | tk8.5a5/tests/constraints.tcl:package require Tcl 8.4
  | tk8.5a5/tests/constraints.tcl:package require Tk 8.4

  reported by: Joachim Moskalewski <tmp07@jmos.de>


tkt_uuid: 920695ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 23. Option Parsing
priority: 5 Medium
foundin: None
resolution: Fixed
title: Documentation bug in Tk_ConfigureWidget
comment:
  In the section that describes the
  TK_CONFIG_STRING option, it is mentioned that
  memory management is done with malloc/free.
  This is clearly wrong, as memory management
  is performed by ckalloc/ckfree in Tk's core.
  This section should be corrected, and perhaps
  a warning should be added whwn old C extensions
  are ported to newer tk versions about mixing them
  with malloc/free, as memory corruption can
  occur under some operating systems (like
  windows).

  George


tkt_uuid: 220514ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 18. [text]
priority: 2
foundin: obsolete: 8.0.4
resolution: Fixed
title: wish crashes when a text widget is created
comment:
  OriginalBugID: 1945 Bug
  Version: 8.0.4
  SubmitDate: '1999-04-27'
  LastModified: '1999-11-12'
  Severity: CRIT
  Status: Released
  Submitter: pat
  ChangedBy: hobbs
  OS: Linux-Red Hat
  OSVersion: 5.2
  Machine: Intel
  FixedDate: '1999-11-12'
  FixedInVersion: 8.2


  Name:  Martin Foressen
  CVS:  tkText.c 1.1.4.3   tkText.h 1.1.4.2

  ReproducibleScript:
  Start wish and give the command: text .t

  ObservedBehavior:
  wish dumps a core

  DesiredBehavior:
  No core

  Patch:
  Index: generic/tkText.c
  ===================================================================
  RCS file: /cvsroot/tk/generic/tkText.c,v
  retrieving revision 1.1.4.3
  diff -c -r1.1.4.3 tkText.c
  *** tkText.c    1999/01/07 02:42:51     1.1.4.3
  --- tkText.c    1999/01/30 14:25:07
  ***************
  *** 785,794 ****
         * the geometry and setting the background from a 3-D border.
         */

  !     if ((textPtr->state != tkTextNormalUid)
  !           && (textPtr->state != tkTextDisabledUid)) {
  !       Tcl_AppendResult(interp, "bad state value \"", textPtr->state,
  !               "\": must be normal or disabled", (char *) NULL);
          textPtr->state = tkTextNormalUid;
          return TCL_ERROR;
        }
  --- 785,794 ----
         * the geometry and setting the background from a 3-D border.
         */

  !     if ((textPtr->state != TK_STATE_NORMAL)
  !           && (textPtr->state != TK_STATE_DISABLED)) {
  !       Tcl_AppendResult(interp, "bad state value must be normal or disabled",
  !               (char *) NULL);
          textPtr->state = tkTextNormalUid;
          return TCL_ERROR;
        }
  Index: generic/tkText.h
  ===================================================================
  RCS file: /cvsroot/tk/generic/tkText.h,v
  retrieving revision 1.1.4.2
  diff -c -r1.1.4.2 tkText.h
  *** tkText.h    1998/09/30 02:17:21     1.1.4.2
  --- tkText.h    1999/01/30 14:25:42
  ***************
  *** 470,476 ****
                                   * image segment doesn't yet have an
                                   * associated image, there is no entry for
                                   * it here. */
  !     Tk_Uid state;             /* Normal or disabled.  Text is read-only
                                   * when disabled. */

        /*
  --- 470,476 ----
                                   * image segment doesn't yet have an
                                   * associated image, there is no entry for
                                   * it here. */
  !     int state;                        /* Normal or disabled.  Text is read-onl
  y
                                   * when disabled. */

        /*

  PatchFiles:
  tkText.c
  tkText.h



  This was changed to Tk_GetUid() calls sometime before 8.2. 
  -- 11/12/1999 hobbs


tkt_uuid: 462375ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 49. [grid]
priority: 5 Medium
foundin: obsolete: 8.4a4
resolution: Fixed
title: Inconsistent [grid] error messages
comment:
  On Linux/Alpha, the error messages returned
  by [grid] are inconsistent, apparently
  depending on command execution history:

  $ wish
  % grid x
  can't determine master window
  % grid
  wrong # args: should be "grid option arg ?arg ...?"
  % grid x
  bad argument "x": must be name of window

  This is a new bug, somehow introduced along
  with the Obj-ification of [grid] and [pack].
  I rolled back to the following revisions:

  generic/tkGrid.c1.12
  generic/tkInt.h1.37
  generic/tkPack.c1.7
  generic/tkWindow.c1.34

  and the inconsistency went away.

  This bug is the cause of the 20 failed tests
  previously reported (Tk Bug 462338).

  I do not see this buggy behavior on Solaris.
  I do not yet know why different platforms yield
  different behavior.


tkt_uuid: 1213188fffffffffffffffffffffffffffffffff
type: Patch
status: Closed
subsystem: 28. Utility Functions
priority: 5 Medium
foundin: None
resolution: Fixed
title: [tk inactive] for Solaris 10 (sparc64)
comment:
  The current HEAD code for the [tk inactive] feature
  doesn't work on Solaris 10 - at least on the sparc
  version. This is for two reasons. First the configure
  code insists on a -lXss library that is not needed on
  this platform. Secondly, the XScreenSaverQueryVersion
  function is returning 256.0 for major.minor. This is
  likely a byte ordering issue. However, there doesn't
  seen any real need to check the version. The
  XScreenSaverQueryInfo function returns a 0 status if
  the feature is unsupported which should be enough for
  our purposes.

  The attached patch fixes these problems on solaris10
  sparc and I checked it on Linux x86 to ensure it
  doesn't mess anything up there.


tkt_uuid: 627471ffffffffffffffffffffffffffffffffff
type: RFE
status: Open
subsystem: 76. Widget Tour
priority: 8
foundin: None
resolution: None
title: Add a simple game to the Widget tour
comment:
  It might be a nice idea to add a game to the demos,
  such as appear on the Wiki. This will show:
  - How to interact with the keyboard/mouse
  - How to set up a game board (a more complicated
  picture)
  - How to do the logic for a game


tkt_uuid: 220926ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 30. Color Names
priority: 5 Medium
foundin: obsolete: 8.4a1
resolution: Fixed
title: tk v8.4a1 (and v8.3.1) fails test color-2.6 under both CDE and OW
comment:
  OriginalBugID: 5873 Bug
  Version: 8.4a1
  SubmitDate: '2000-06-12'
  LastModified: 
  Severity: MED
  Status: UnAssn
  Submitter: techsupp
  OS: Solaris
  OSVersion: Solaris 7 (with 11/99 patches)
  Machine: Sun Ultra5


  Name:
  David R. Linn

  Extensions:
  whatever is in the Tcl/Tk v8.4a1 bundle

  CustomShell:
  no changes

  Comments:
  Test color=2.6 was added between Tk v8.3.0 and Tk v8.3.1 and Tk v8.3.1
      fails in the same
      way as Tk v8.4a1.

  ReproducibleScript:
  cd tk*/unix
  setenv TBD ../../tcl*/unix
  make TCL_BIN_DIR=$TBD test

  ObservedBehavior:
  output from the above command includes

  ...
  clrpick.test
  cmds.test
  color.test

  ==== color-2.6 Tk_GetColor procedure FAILED
  ==== Contents of test case:

      winfo rgb .t red

  ---- Result was:
  64000 4864 16384
  ---- Result should have been:
  65535 0 0
  ==== color-2.6 FAILED

  config.test
  cursor.test
  ...
  Tests ended at Sat Jun 10 11:10:19 CDT 2000
  all.tcl:Total7025Passed6599Skipped425Failed1
  Sourced 86 Test Files.
  Files with failing tests: color.test
  Number of tests skipped for each constraint:
  2altDisplay
  3colorsLeftover
  2emptyTest
  44macOnly
  15macOrPc
  132nonPortable
  226pcOnly
  1userInteraction

  DesiredBehavior:
  ...
  Tests ended at Sat Jun 10 11:10:19 CDT 2000
  all.tcl:Total7025Passed6600Skipped425Failed0

  i.e. Tk should pass all of its bundled tests or there should be a note telling the installer that
  this test will fail and that it's okay to put a release into production with a failed test.


tkt_uuid: 220669ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 67. Unix Window Operations
priority: 2
foundin: obsolete: 8.2.1
resolution: Fixed
title: `winfo cont' crashes due to BadWindow in X_TranslateCoords
comment:
  OriginalBugID: 4106 Bug
  Version: 8.2.1
  SubmitDate: '2000-01-31'
  LastModified: '2000-01-31'
  Severity: CRIT
  Status: Released
  Submitter: techsupp
  ChangedBy: hobbs
  RelatedBugIDs: 716
  OS: BSD
  OSVersion: BSD/OS 2.1
  Machine: PII-350/64M/XFree86 vendor release number 3120
  FixedDate: '2000-01-31'
  FixedInVersion: 8.3b1


  Name:
  Jeff Epler

  Comments:
  The window hierarchy changes while Tk_CoordsToWindow is traversing it,
      because the window manager is tearing down the window ".t" and its
      decorations.

      The problem crops up at least on fvwm2 and icewm.  Since it depends on
      the actions of the wm the severity may depend on the one in use.

  ReproducibleScript:
  toplevel .t
  button .t.b -command {
          set px [winfo pointerx .]
          set py [winfo pointery .]
          destroy .t
          if { [winfo cont $px $py] != ".t.b" } {
                  puts "leave"
          }
  } -text {d}
  pack .t.b
  puts {Now invoke the "d" button}

  ObservedBehavior:
  % /tmp/tcl8/bin/wish8.2 ~/2tl.tcl 
  X Error of failed request:  BadWindow (invalid Window parameter)
    Major opcode of failed request:  40 (X_TranslateCoords)
    Resource id in failed request:  0x1c004f9
    Serial number of failed request:  202
    Current serial number in output stream:  202

  GDB produces the following stack trace when breaking on _XError:
  Starting program: /tmp/tcl8/bin/wish8.2 ~/2tl.tcl
  Now invoke the "d" button

  Breakpoint 1, 0xf7721 in _XError ()
  (gdb) where
  #0  0xf7721 in _XError ()
  #1  0xf612a in _XReply ()
  #2  0x101420 in XTranslateCoordinates ()
  #3  0x2996f in Tk_CoordsToWindow (rootX=519, rootY=543, tkwin=0x69c500)
      at ./tkUnixWm.c:3532
  #4  0x68e5 in Tk_WinfoObjCmd (clientData=0x69c500, interp=0x69d000, objc=4, 
      objv=0x6a1014) at ./../generic/tkCmds.c:1279
  #5  0xc03c3 in TclExecuteByteCode ()
  #6  0xa0b25 in Tcl_EvalObjEx ()
  #7  0x2d000 in TkInvokeButton (butPtr=0x749f00) at ./../generic/tkButton.c:1457
  #8  0x2c29a in ButtonWidgetObjCmd (clientData=0x749f00, interp=0x69d000, 
      objc=2, objv=0x6a100c) at ./../generic/tkButton.c:835

  DesiredBehavior:
  No X protocol error.  return value from `winfo' should probably not indicate .t or .t.b



  Already fixed in 8.3b1 with patch from bug 716. 
  -- 01/31/2000 hobbs


tkt_uuid: 220533ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 99. Other
priority: 2
foundin: final: 8.1.1
resolution: Fixed
title: When compiling Tk from makefile.vc various errors are encountered.
comment:
  OriginalBugID: 2164 Bug
  Version: 8.1.1
  SubmitDate: '1999-06-03'
  LastModified: '1999-08-14'
  Severity: MED
  Status: Released
  Submitter: techsupp
  ChangedBy: hobbs
  OS: Windows NT
  Machine: X86
  FixedDate: '1999-08-14'
  FixedInVersion: 8.2


  Name:
  Lindsay Gill

  ReproducibleScript:
  nmake /f "makfile.vc" test

  ObservedBehavior:
  --------------------Configuration: compile files - Win32
      Debug--------------------
      Microsoft (R) Program Maintenance Utility   Version 6.00.8168.0
      Copyright (C) Microsoft Corp 1988-1998. All rights reserved.
       set TCL_LIBRARY=..\..\tcl8.1.1/library
       set PATH=..\..\tcl8.1.1\win\Release;C:\Program Files\Microsoft Visual
      Studio\Common\MSDev98\Bin;C:\Program Files\Microsoft Visual
      Studio\VC98\BIN;C:\Program Files\Microsoft Visual
      Studio\Common\TOOLS;C:\Program Files\Microsoft Visual Studio\Common TOOLS\WINNT;C:\WINNT\system32;C:\WINNT;C:\PROGRA~1\Tcl\bin
       .\Release\tktest.exe ../tests/all.tcl | .\Release\cat32.exe
      Tk 8.1.1 tests running in interp:  D:/tk8.1.1/compile
      files/Release/tktest.exe
      Tests running in working dir:  D:/tk8.1.1/compile files
      Tests began at Thu Jun 03 14:58:51 Central Daylight Time 1999
      bell.test
      Bell should ring now ...
      bgerror.test
      bind.test
      bitmap.test
      border.test
      button.test
      canvImg.test
      canvPs.test
      canvRect.test
      canvText.test
      canvWind.test
      canvas.test
      clipboard.test
      clrpick.test
      cmds.test
      color.test
      config.test
      cursor.test
      ==== cursor-3.1 Tk_FreeCursorFromObj - reference counts FAILED
      ==== Contents of test case:
          set x arrow
          destroy .b1 .b2 .b3
          button .b1 -cursor $x
          button .b3 -cursor $x
          button .b2 -cursor $x
          set result {}
          lappend result [testcursor arrow]
          destroy .b1
          lappend result [testcursor arrow]
          destroy .b2
          lappend result [testcursor arrow]
          destroy .b3
          lappend result [testcursor arrow]
      ---- Result was:
      {{9 5}} {{8 5}} {{7 5}} {{6 5}}
      ---- Result should have been:
      {{3 1}} {{2 1}} {{1 1}} {}
      ==== cursor-3.1 FAILED
      ==== cursor-4.1 FreeCursorObjProc FAILED
      ==== Contents of test case:
          destroy .b
          set x [format arrow]
          button .b -cursor $x
          set y [format arrow]
          .b configure -cursor $y
          set z [format arrow]
          .b configure -cursor $z
          set result {}
          lappend result [testcursor arrow]
          set x red
          lappend result [testcursor arrow]
          set z 32
          lappend result [testcursor arrow]
          destroy .b
          lappend result [testcursor arrow]
          set y bogus
          set result
      ---- Result was:
      {{7 7}} {{7 6}} {{7 5}} {{6 5}}
      ---- Result should have been:
      {{1 3}} {{1 2}} {{1 1}} {}
      ==== cursor-4.1 FAILED
      entry.test
      event.test
      filebox.test
      focus.test
      can't read "::tcltest::fd": no such variable
      focusTcl.test
      font.test
      frame.test
      geometry.test
      get.test
      grid.test
      ==== grid-11.14 default widget placement FAILED
      ==== Contents of test case:
          foreach i {1 2 3} {
       frame .f$i -width 50 -height 50 -highlightthickness 0 -bg red
          }
          grid .f1 .f2
          grid  ^  .f3
          update
          set a ""
          foreach i {1 2 3} {
       lappend a "[winfo x .f$i],[winfo y .f$i]  [winfo width .f$i],[winfo
      height .f$i]"
          }
          set a
      ---- Result was:
      {2,25  50,50} {52,0  50,50} {52,50  50,50}
      ---- Result should have been:
      {0,25  50,50} {50,0  50,50} {50,50  50,50}
      ==== grid-11.14 FAILED
      id.test
      This application hasn't been compiled with the testwrapper command,
      therefore I am skipping all of these tests.
      image.test
      imgBmap.test
      imgPPM.test
      imgPhoto.test
      listbox.test
      macEmbed.test
      macFont.test
      skipping: Mac only tests...
      macMenu.test
      skipping: Mac only tests...
      macWinMenu.test
      macscrollbar.test
      skipping: Mac only tests...
      main.test
      menu.test
      menuDraw.test
      menubut.test
      msgbox.test
      obj.test
      oldpack.test
      option.test
      pack.test
      place.test
      raise.test
      safe.test
      ==== safe-1.2 Safe Tk loading into an interpreter FAILED
      ==== Contents of test case:
          catch {safe::interpDelete a}
          safe::interpCreate a
          safe::loadTk a
          set l [lsort [interp hidden a]]
          safe::interpDelete a
          set l
      ---- Result was:
      bell cd clipboard encoding exec exit fconfigure file glob grab load menu
      open pwd selection socket source tk tk_chooseColor tk_chooseDirectory
      tk_getOpenFile tk_getSaveFile tk_messageBox toplevel wm
      ---- Result should have been:
      bell cd clipboard encoding exec exit fconfigure file glob grab load menu
      open pwd selection socket source tk tk_chooseColor tk_getOpenFile
      tk_getSaveFile tk_messageBox toplevel wm
      ==== safe-1.2 FAILED
      scale.test
      scrollbar.test
      ==== scrollbar-6.27 ScrollbarPosition procedure FAILED
      ==== Contents of test case:
          .s identify [expr [winfo width .s] / 2] [expr int(.4 / [.s delta 0
      1])  + [testmetrics cyvscroll]]
      ---- Result was:
      slider
      ---- Result should have been:
      trough2
      ==== scrollbar-6.27 FAILED
      select.test
      send.test
      xhost application isn't available - skipping tests
      text.test
      textBTree.test
      textDisp.test
      skipping font-sensitive tests
      ==== textDisp-4.12 UpdateDisplayInfo, filling in extra vertical space
      FAILED
      ==== Contents of test case:
          .t delete 1.0 end
          .t insert end "1\n2\n3\n4\n5\n7\n8\n9\n10\n11\n12"
          button .b -text "Test" -bd 2 -highlightthickness 2
          .t window create 3.end -window .b
          .t yview moveto 1
          update
          .t yview moveto 0
          update
          .t yview moveto 1
          update
          winfo ismapped .b
      ---- Result was:
      1
      ---- Result should have been:
      0
      ==== textDisp-4.12 FAILED
      textImage.test
      textIndex.test
      textMark.test
      textTag.test
      textWind.test
      ==== textWind-10.1 EmbWinLayoutProc procedure FAILED
      ==== Contents of test case:
          .t delete 1.0 end
          .t insert 1.0 "Some sample text"
          .t window create 1.5 -create {
       frame .f -width 10 -height 20 -bg $color
          }
          update
          list [winfo exists .f] [winfo geom .f] [.t index .f]
      ---- Result was:
      1 10x20+45+5 1.5
      ---- Result should have been:
      1 10x20+40+5 1.5
      ==== textWind-10.1 FAILED
      ==== textWind-10.11 EmbWinLayoutProc procedure, doesn't fit on line
      FAILED
      ==== Contents of test case:
          .t configure -wrap none
          .t delete 1.0 end
          .t insert 1.0 "Some sample text"
          frame .f -width 130 -height 20 -bg $color -bd 2 -relief raised
          .t window create 1.12 -window .f
          update
          list [.t bbox .f] [.t bbox 1.13]
      ---- Result was:
      {101 5 130 20} {231 6 8 17}
      ---- Result should have been:
      {89 5 126 20} {}
      ==== textWind-10.11 FAILED
      ==== textWind-11.1 EmbWinDisplayProc procedure, geometry transforms
      FAILED
      ==== Contents of test case:
          .t delete 1.0 end
          .t insert 1.0 "Some sample text"
          pack forget .t
          place .t -x 30 -y 50
          frame .f -width 30 -height 20 -bg $color
          .t window create 1.12 -window .f
          update
          winfo geom .f
      ---- Result was:
      30x20+131+55
      ---- Result should have been:
      30x20+119+55
      ==== textWind-11.1 FAILED
      ==== textWind-11.2 EmbWinDisplayProc procedure, geometry transforms
      FAILED
      ==== Contents of test case:
          .t delete 1.0 end
          .t insert 1.0 "Some sample text"
          pack forget .t
          place .t -x 30 -y 50
          frame .t.f -width 30 -height 20 -bg $color
          .t window create 1.12 -window .t.f
          update
          winfo geom .t.f
      ---- Result was:
      30x20+101+5
      ---- Result should have been:
      30x20+89+5
      ==== textWind-11.2 FAILED
      ==== textWind-13.1 EmbWinBboxProc procedure FAILED
      ==== Contents of test case:
          .t delete 1.0 end
          .t insert 1.0 "Some sample text"
          frame .f -width 5 -height 5 -bg $color
          .t window create 1.2 -window .f -align top -padx 2 -pady 1
          update
          list [winfo geom .f] [.t bbox .f]
      ---- Result was:
      5x5+23+6 {23 6 5 5}
      ---- Result should have been:
      5x5+21+6 {21 6 5 5}
      ==== textWind-13.1 FAILED
      ==== textWind-13.2 EmbWinBboxProc procedure FAILED
      ==== Contents of test case:
          .t delete 1.0 end
          .t insert 1.0 "Some sample text"
          frame .f -width 5 -height 5 -bg $color
          .t window create 1.2 -window .f -align center -padx 2 -pady 1
          update
          list [winfo geom .f] [.t bbox .f]
      ---- Result was:
      5x5+23+11 {23 11 5 5}
      ---- Result should have been:
      5x5+21+9 {21 9 5 5}
      ==== textWind-13.2 FAILED
      ==== textWind-13.9 EmbWinBboxProc procedure, spacing options FAILED
      ==== Contents of test case:
          .t configure -spacing1 5 -spacing3 2
          .t delete 1.0 end
          .t insert 1.0 "Some sample text"
          frame .f -width 5 -height 5 -bg $color
          .t window create 1.2 -window .f -align center -padx 2 -pady 1
          update
          list [winfo geom .f] [.t bbox .f]
      ---- Result was:
      5x5+23+16 {23 16 5 5}
      ---- Result should have been:
      5x5+21+14 {21 14 5 5}
      ==== textWind-13.9 FAILED
      ==== textWind-16.2 EmbWinTextStructureProc procedure FAILED
      ==== Contents of test case:
          .t configure -wrap none
          .t delete 1.0 end
          .t insert 1.0 "Some sample text"
          frame .f -width 30 -height 20 -bg $color
          .t window create 1.6 -window .f
          update
          set result {}
          lappend result [winfo geom .f] [.t bbox .f]
          frame .f2 -width 150 -height 30 -bd 2 -relief raised
          pack .f2 -before .t
          update
          lappend result [winfo geom .f] [.t bbox .f]
      ---- Result was:
      30x20+53+5 {53 5 30 20} 30x20+53+35 {53 5 30 20}
      ---- Result should have been:
      30x20+47+5 {47 5 30 20} 30x20+47+35 {47 5 30 20}
      ==== textWind-16.2 FAILED
      ==== textWind-16.4 EmbWinTextStructureProc procedure FAILED
      ==== Contents of test case:
          .t configure -wrap none
          .t delete 1.0 end
          .t insert 1.0 "Some sample text"
          frame .t.f -width 30 -height 20 -bg $color
          .t window create 1.6 -window .t.f
          update
          pack forget .t
          update
          list [winfo ismapped .t.f] [.t bbox .t.f]
      ---- Result was:
      1 {53 5 30 20}
      ---- Result should have been:
      1 {47 5 30 20}
      ==== textWind-16.4 FAILED
      tk.test
      unixButton.test
      skipping: Unix only tests...
      unixEmbed.test
      skipping: Unix only tests...
      unixFont.test
      skipping: Unix only tests...
      unixMenu.test
      skipping: Unix only tests...
      unixSend.test
      skipping: Unix only tests...
      unixWm.test
      skipping: Unix only tests...
      util.test
      visual.test
      visual_bb.test
      winButton.test
      winClipboard.test
      winDialog.test
      winFont.test
      winMenu.test
      winSend.test
      skipping: Unimplemented send command
      winWm.test
      ==== winWm-5.1 UpdateGeometryInfo: menu resizing FAILED
      ==== Contents of test case:
          set result {}
          toplevel .t
          frame .t.f -width 150 -height 50 -bg red
          pack .t.f
          update
          set result [winfo height .t]
          menu .t.m
          .t.m add command -label foo
          .t conf -menu .t.m
          update
          lappend result [winfo height .t]
          .t.m add command -label "thisisreallylong"
          .t.m add command -label "thisisreallylong"
          update
          lappend result [winfo height .t]
          destroy .t
          set result
      ---- Result was:
      50 50 32
      ---- Result should have been:
      50 50 50
      ==== winWm-5.1 FAILED
      window.test
      winfo.test
      xmfbox.test
      Tests ended at Thu Jun 03 14:59:25 Central Daylight Time 1999
      all.tcl: Total 5844 Passed 5224 Skipped 604 Failed 16
      Sourced 82 Test Files.
      Files with failing tests: cursor.test grid.test safe.test scrollbar.test
      textDisp.test textWind.test winWm.test
      Number of tests skipped for each constraint:
       5 emptyTest
       245 fonts
       1 knownBug
       44 macOnly
       15 macOrUnix
       58 nonPortable
       77 nonUnixUserInteraction
       3 pseudocolor
       1 tempNotPc
       136 unixOnly
       19 userInteraction
      stderr32

      compile files.exe - 0 error(s), 0 warning(s)



  The same system config with Tk 8.2.0 does not produce these errors
  here.  I will assume they have been clarified in/before 8.2.0. 
  -- 08/14/1999 hobbs


tkt_uuid: 684319ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 66. Aqua Window Operations
priority: 5 Medium
foundin: obsolete: 8.4.1
resolution: Duplicate
title: Incorrect screen positions reported, Aqua
comment:
  Screen positions reported by winfo rootx and winfo rooty are 
  sometimes incorrect in Aqua Tk 8.4.1.  When I bring up a toplevel 
  Tix window, all other toplevel windows in the application after 
  being moved report that their rootx, rooty position equals that of 
  the Tix toplevel.  This situation persists until the Tix toplevel is 
  unmapped or destroyed.

  This problem occurs using a port of the Tix meta-widget package 
  to Mac Aqua that is not yet distributed so I cannot easily provide 
  test code to demonstrate the problem.

  I have tracked the problem to Tk source code file

       tk8.4.1/macosx/tkMacOSXMouseEvent.c

  line 292 in function TkMacOSXProcessMouseEvent():

          case inDrag:
              DragWindow(medPtr->whichWin, where, NULL);
              where2.h = where2.v = 0;
              LocalToGlobal(&where2);
              if (EqualPt(where, where2)) {
                  return false;
              }

  The LocalToGlobal() call in this code uses the current graphics 
  port, but the port is not set anywhere nearby above this call.  In 
  the above incorrect rootx,rooty situation the wrong port is current.  
  Adding a SetPortWindowPort() before the LocalToGlobal() call 
  fixed the problem.

          case inDrag:
              DragWindow(medPtr->whichWin, where, NULL);
              where2.h = where2.v = 0;
  SetPortWindowPort(medPtr->whichWin);    /* Added by Tom G to 
  fix wrong window position bug. */
              LocalToGlobal(&where2);
              if (EqualPt(where, where2)) {
                  return false;
              }

  I am not familiar enough with the code to know if this is the 
  correct solution.

  Tom Goddard
  goddard@cgl.ucsf.edu


tkt_uuid: 791273ffffffffffffffffffffffffffffffffff
type: Patch
status: Closed
subsystem: 02. Appearance
priority: 5 Medium
foundin: None
resolution: Accepted
title: Improved 3D borders on Windows
comment:
  This patch ever so slightly tweaks Windows 3D borders
  by flipping the dark and dark2 colors of
  TK_RELIEF_SUNKEN.  This results in the black color
  getting drawn on the inside of the top/left border
  instead of the outside.

  This makes 3D borders appear more like standard Windows
  borders.

  To apply:

  cd $TK_SRC_DIR
  patch -p1 < tk-windows-borders.patch


tkt_uuid: 220565ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 44. Generic Fonts
priority: 2
foundin: final: 8.1.1
resolution: Fixed
title: Character search on Windows slow
comment:
  OriginalBugID: 2407 Bug
  Version: 8.1.1
  SubmitDate: '1999-07-19'
  LastModified: '1999-12-16'
  Severity: MED
  Status: Released
  Submitter: techsupp
  ChangedBy: hobbs
  OS: Windows 95
  OSVersion: OSR3+IE5.0
  Machine: X86
  FixedDate: '1999-12-16'
  FixedInVersion: 8.3b1


  Name: Kevin Kenny



  CustomShell:

  Patched as per my other bug report



  Comments:

  The patch above does NOT solve the entire problem of searching for a

      font

      capable of rendering the text.  What it does it to place "Bitstream

      Cyberbit"

      (by far the most popular CJK font for Win95/98 in North America)

      into the global fallback table.  This change at least gets Cyberbit

      searched as the fifth font or so, rather than the 361st, and allows

      Chinese

      text to be rendered at a more reasonable speed.  A real fix is still

      needed

      so that Tk doesn't freeze if it tries to display a burst of nonexistent

      glyphs.



  ReproducibleScript:

  # If many fonts are installed (my system returns 361 for 

      # [llength [font families]]), the search for a font to render a

      character

      # is horribly slow.  Try executing:

      font create x -family times -size 24

      label .l -font x -text "The Chinese name of Tk is \u592a\u9177"

      grid .l



  ObservedBehavior:

  The label takes several seconds to create.  Displaying a text widget

      containing

      a paragraph of Chinese text had not come back after several hours.



  DesiredBehavior:

  It would be nice if some of the capability information (which fonts

      support

      which characters) could be cached in memory.  Apparently, any time that

      the

      system has to search all the fonts, it must make many, many expensive

      GDI

      calls to do so.



  Patch:

  *** Tcl8.1/src/tk8.1/generic/tkFont.cThu Apr 29 15:37:50 1999

  --- Tcl8.1-from-source/src/tk8.1/generic/tkFont.cSat Jul 17 18:05:16 1999

  ***************

  *** 310,315 ****

  --- 310,316 ----

        "symbol",/* All platforms. */

    /* Unix. */

        "lucida sans unicode",/* Windows. */

  +     "bitstream cyberbit",

        "chicago",/* Mac. */

        NULL

    };



  PatchFiles:

  tkFont.c





  Added to 8.3b1. 
  -- 12/16/1999 hobbs


tkt_uuid: 2243962fffffffffffffffffffffffffffffffff
type: Patch
status: Closed
subsystem: 84. Unix Build
priority: 7 High
foundin: None
resolution: Accepted
title: Adding a tk.pc to be used by pkg-config
comment:
  Attached is a patch to configure.in and Makefile.in, and a tk.pc.in.  These will create a tk.pc file at compile-time, which will be added to the system-wide pkgconfig on install.  This lets developers use pkg-config to determine the include paths and linker flags.


tkt_uuid: 1191258fffffffffffffffffffffffffffffffff
type: Bug
status: Open
subsystem: 18. [text]
priority: 5 Medium
foundin: obsolete: 8.4.9
resolution: None
title: text/entry become very inefficients with long lines
comment:
  After Tcl/Tk 8.3.3 text and entry widgeds become very 
  inefficients working with long single lines, (without end of 
  lines)

  e.g this is very inefficient with 8.4.9 version (it was better 
  with 8.3.3)

  text .t
  .t insert 1.0 [string repeat "x" 100000]

  but this works ok:
  text .t
  .t insert 1.0 [string repeat "x\n" 100000]


tkt_uuid: 1884782fffffffffffffffffffffffffffffffff
type: Bug
status: Open
subsystem: 46. Unix Fonts
priority: 5 Medium
foundin: obsolete: 8.4.7
resolution: None
title: simple Tk app to display data crashes wish
comment:
  A developer contacted me asking me for help. He had data in a Chinese encoding that he needed to display in a Tcl/Tk application. After asking on the wiki and comp.lang.tcl, it appears that Tcl doesn't support this encoding. It was recommended that he use iconv to convert the encoding into one that is supported.
  He did so, then, with the following application, attempted to display the data. Note that when _I_ run this script, I get the chinese output as expected. When he runs it, he gets a Bus error core dump on SPARC Solaris 9... This is with a standard Tcl interpreter.

  Okay, here's the application:

     package require Tk
     frame .f
     text .text -bg white -wrap word 
   
     pack .f -side top
     pack .text -side left -expand true -fill both
   
     .text configure -font "helvetica-22"
   
     .text delete 1.0 end
   
      set f [open "~/foo.utf8" "r"]
      fconfigure $f -encoding "utf-8"
      set buf [read $f 32000]
   
      .text insert end $buf
   
      close $f

  I will attempt to attach the foo.utf8 to this ticket.

  Note that while the original report of this problem is from Tcl/Tk 8.4.7 - the developer reports seeing the same problem with 8.5.0. However, I don't have the stack trace from the tcl/tk 8.5 attempt - just this one.
  The stack trace is:
   $ dbx -f /usr/tcl84/bin/tclsh core
  For information about new features see `help changes'
  To remove this message, put `dbxenv suppress_startup_message 7.0' in your .dbxrc
  Reading tclsh
  core file header read successfully
  Reading ld.so.1
  Reading libtcl8.4g.so
  Reading libdl.so.1
  Reading libsocket.so.1
  Reading libnsl.so.1
  Reading libm.so.1
  Reading libc.so.1
  Reading libmp.so.2
  Reading libc_psr.so.1
  Reading libtk8.4g.so
  Reading libX11.so.4
  Reading libXext.so.0
  program terminated by signal BUS (invalid address alignment)
  Current function is Tcl_UtfToUniChar
    338                       | ((str[1] & 0x3F) << 6) | (str[2] & 0x3F));
  (dbx 1) where                                                         
  =>[1] Tcl_UtfToUniChar(str = 0xffbfdaad "\xe5\x80\x80\xff\xbf\xdc\x9c", chPtr = 0xffbfda9d), line 338 in "tclUtf.c"
    [2] UtfToUcs2beProc(clientData = (nil), src = 0xffbfdaad "\xe5\x80\x80\xff\xbf\xdc\x9c", srcLen = 3, flags = 7, statePtr = 0xffbfd9c4, dst = 0xffbfda9d "", dstLen = 14, srcReadPtr = 0xffbfd9d0, dstWrotePtr = 0xffbfd9cc, dstCharsPtr = 0xffbfd9c8), line 616 in "tkUnixFont.c"
    [3] Tcl_UtfToExternal(interp = (nil), encoding = 0x3e950, src = 0xffbfdaad "\xe5\x80\x80\xff\xbf\xdc\x9c", srcLen = 3, flags = 7, statePtr = 0xffbfd9c4, dst = 0xffbfda9d "", dstLen = 14, srcReadPtr = 0xffbfd9d0, dstWrotePtr = 0xffbfd9cc, dstCharsPtr = 0xffbfd9c8), line 1093 in "tclEncoding.c"
    [4] FontMapLoadPage(subFontPtr = 0xffbfdc9c, row = 20), line 2097 in "tkUnixFont.c"
    [5] FontMapLookup(subFontPtr = 0xffbfdc9c, ch = 21457), line 1985 in "tkUnixFont.c"
    [6] CanUseFallback(fontPtr = 0xc91e8, faceName = 0xc3978 "fixed", ch = 21457, fixSubFontPtrPtr = (nil)), line 2429 in "tkUnixFont.c"
    [7] FindSubFontForChar(fontPtr = 0xc91e8, ch = 21457, fixSubFontPtrPtr = (nil)), line 1858 in "tkUnixFont.c"
    [8] Tk_MeasureChars(tkfont = 0xc91e8, source = 0xc96a4 "<\xe5\x8f\x91\xe6\x98\x8e\xef\xbc\x88\xe8\xae\xbe\xe8\xae\xa1\xef\xbc\x89\xe4\xba\xba>=\xe5\x89\x8d,\xe6\xbb\x9d,\xe8\xbf\x9b\n", numBytes = 35, maxLength = 560, flags = 0, lengthPtr = 0xffbfe08c), line 1051 in "tkUnixFont.c"
    [9] MeasureChars(tkfont = 0xc91e8, source = 0xc96a4 "<\xe5\x8f\x91\xe6\x98\x8e\xef\xbc\x88\xe8\xae\xbe\xe8\xae\xa1\xef\xbc\x89\xe4\xba\xba>=\xe5\x89\x8d,\xe6\xbb\x9d,\xe8\xbf\x9b\n", maxBytes = 36, startX = 0, maxX = 560, tabOrigin = 0, nextXPtr = 0xffbfe124), line 5216 in "tkTextDisp.c"
    [10] TkTextCharLayoutProc(textPtr = 0x31500, indexPtr = 0xffbfe20c, segPtr = 0xc9698, byteOffset = 0, maxX = 560, maxBytes = 36, noCharsYet = 1, wrapMode = TEXT_WRAPMODE_WORD, chunkPtr = 0x3a198), line 4485 in "tkTextDisp.c"
    [11] LayoutDLine(textPtr = 0x31500, indexPtr = 0xffbfe2d4), line 1007 in "tkTextDisp.c"
    [12] UpdateDisplayInfo(textPtr = 0x31500), line 1321 in "tkTextDisp.c"
    [13] TkTextPixelIndex(textPtr = 0x31500, x = 0, y = 0, indexPtr = 0xffbfe42c), line 4139 in "tkTextDisp.c"
    [14] TkTextPickCurrent(textPtr = 0x31500, eventPtr = 0x316b4), line 1411 in "tkTextTag.c"
    [15] DisplayText(clientData = 0x31500), line 2248 in "tkTextDisp.c"
    [16] TclServiceIdle(), line 704 in "tclTimer.c"
    [17] Tcl_DoOneEvent(flags = -3), line 955 in "tclNotify.c"
    [18] Tk_MainLoop(), line 1500 in "tkEvent.c"
    [19] Tcl_Main(argc = 1, argv = 0xffbfe8c0, appInitProc = 0x10820 = &Tcl_AppInit(Tcl_Interp *interp)), line 485 in "tclMain.c"
    [20] main(argc = 2, argv = 0xffbfe8bc), line 90 in "tclAppInit.c"
  (dbx 2) 


tkt_uuid: 2764263fffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 86. Test Tools
priority: 2
foundin: None
resolution: Fixed
title: Stray @ in Makefile.in test target.
comment:
  There is a single @ in the test target.

  test: test-classic test-ttk
         @


  After running the tests, OpenBSD's make stops with:
  : not found
  *** Error code 1

  Attached patch against core-8-5-branch removes the @.


tkt_uuid: 580362ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 18. [text]
priority: 5 Medium
foundin: obsolete: 8.4b1
resolution: Fixed
title: isDirty flag not updated during undo
comment:
  Since the tkUndo.c-related changes to tkText.c, the 
  isDirty flag is no longer decremented when undoing an 
  edit. Previously the isDirtyIncrement was set to -1 during 
  undo.


tkt_uuid: 2912962fffffffffffffffffffffffffffffffff
type: Bug
status: Open
subsystem: 88. Themed Tk
priority: 5 Medium
foundin: None
resolution: None
title: Notebook does not set TTK_STATE_USER1
comment:
  The TabState function in ttkNotebook.c is not setting the TTK_STATE_USER1 flag correctly. This happend when tabs added to the notebook before the tab currently visible in first position was added, are now hidden. The TabState function check 'index == 0' but this is not working correctly when tab are hidden. Looking for the first visible tab should skip hidden tabs. The attached script triggers this problem with the tileqt theme. The attached C file has a patched TabState function.


tkt_uuid: 1168533fffffffffffffffffffffffffffffffff
type: Patch
status: Closed
subsystem: 66. Aqua Window Operations
priority: 3 Low
foundin: None
resolution: Accepted
title: Aqua Dock Icon bouncing
comment:
  I just made a patch to Tk for OS X that lets you cause the dock icon 
  for the application to bounce, using a command like: 


      wm attributes . -notify 1 


  And stop it bouncing with: 


      wm attributes . -notify 0 


  I chose this setup because it should be expandable to allow other 
  platforms to implement similar features.  For example, Windows 
  could have the taskbar item for the window blink.  I'd implement that 
  myself, but I don't have a Windows build environment, currently. 


tkt_uuid: 1501749fffffffffffffffffffffffffffffffff
type: Bug
status: Open
subsystem: 18. [text]
priority: 5 Medium
foundin: None
resolution: None
title: Wish core dump with window-delete + index
comment:
  Wish core dumps with the script below.  To reproduce
  run it and press <PgDn> then <Down> until the window
  gets mapped, deleted and replaced with blue text.
  Does not occur every time, but has been reproduced
  under versions Tk 8.3, 8.4 and 8.5 and CVS HEAD.

  Following is the gdb traceback of CVS HEAD.

  **************************************
  #0  0x400d7b8e in TkTextUpdateLineMetrics
  (textPtr=0x80e8ca8, lineNum=103, 
      endLine=202, doThisMuch=256)
      at
  /home/pcmacdon/tmp/TclCvs/tk/unix/../generic/tkTextDisp.c:3035
  3035                if (TkBTreeLinePixelEpoch(textPtr,
  linePtr)

  (gdb) p linePtr->pixels
  $3 = (int *) 0x1

  (gdb) bt
  #0  0x400d7b8e in TkTextUpdateLineMetrics
  (textPtr=0x80e8ca8, lineNum=103, 
      endLine=202, doThisMuch=256)
      at
  /home/pcmacdon/tmp/TclCvs/tk/unix/../generic/tkTextDisp.c:3035
  #1  0x400d78fd in AsyncUpdateLineMetrics
  (clientData=0x80e8ca8)
      at
  /home/pcmacdon/tmp/TclCvs/tk/unix/../generic/tkTextDisp.c:2901
  #2  0x401c3ac5 in TimerHandlerEventProc ()
     from /home/pcmacdon/tmp/TclCvs/lib/libtcl8.5.so
  #3  0x401a9a3a in Tcl_ServiceEvent ()
     from /home/pcmacdon/tmp/TclCvs/lib/libtcl8.5.so
  #4  0x401a9d3c in Tcl_DoOneEvent ()
     from /home/pcmacdon/tmp/TclCvs/lib/libtcl8.5.so
  #5  0x40042146 in Tk_MainLoop ()
      at
  /home/pcmacdon/tmp/TclCvs/tk/unix/../generic/tkEvent.c:2150
  #6  0x40053579 in Tk_MainEx (argc=-1, argv=0xbffff63c, 
      appInitProc=0x804887c <Tcl_AppInit>, interp=0x804b360)
      at
  /home/pcmacdon/tmp/TclCvs/tk/unix/../generic/tkMain.c:308
  #7  0x08048864 in main (argc=2, argv=0xbffff634)
      at
  /home/pcmacdon/tmp/TclCvs/tk/unix/../unix/tkAppInit.c:68
  #8  0x42017499 in __libc_start_main () from
  /lib/i686/libc.so.6

  (gdb) l
  3030
  3031                /*
  3032                 * Now update the line's metrics if
  necessary.
  3033                 */
  3034
  3035                if (TkBTreeLinePixelEpoch(textPtr,
  linePtr)
  3036                    !=
  textPtr->dInfoPtr->lineMetricUpdateEpoch) {
  3037                    if (doThisMuch == -1) {
  3038                        count += 8 *
  TkTextUpdateOneLine(textPtr, linePtr,
  0,
  3039                                NULL, 0);

  ***********************************************************

  # Demonstrate TEXT using a window frame as placeholder for 
  # a section rendering.  When window gets mapped, it's
  # deleted and the section gets rendered.
  set str [string repeat "The quick red fox jumped over
  the lazy brown dog\n" 100]
  pack [text .t] -fill both -expand y -side left
  pack [scrollbar .sb -command ".t yview"] -fill y -side left
  .t conf -yscrollc ".sb set"
  .t insert end $str\n
  .t window create end -window [frame .f1 -width 800
  -height 800]
  .t insert end \n$str
  .t tag conf foo -background lightblue
  proc MAPPED w {
    puts "MAPPED"
    set i [.t index $w]
    set oi [.t index @0,0]
    .t delete $w
    destroy $w
    .t insert $i [string toupper $::str] foo
    .t mark set insert $oi
    .t see $oi
  }
  bind .f1 <Map> "MAPPED %W"
  focus .t


tkt_uuid: 3495198fffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 04. Canvas Basics
priority: 5 Medium
foundin: obsolete: 8.6b2
resolution: Fixed
title: color/bitmap mixup in canvas bitmap man page
comment:
  The man page for canvas bitmap says:

  -activebackground bitmap
  -disabledbackground bitmap
  -activeforeground bitmap
  -disabledforeground bitmap

  In each of these cases, "bitmap" should be "color".


tkt_uuid: 886915ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 68. Win Window Operations
priority: 5 Medium
foundin: obsolete: 8.4.5
resolution: Fixed
title: Toplevel problems under Windows
comment:
  I have found two problems with bgerror under windows,
  with wish8.4.5. The problem occurs with bgerror, but I
  think these are more related to windows toplevel.
  The following script:

     after idle error

  * started in a file, nothings happen: . is not mapped,
  neither the bgerror dialog.

  * in a wish console, the bgerror dialog "flash" before
  being displayed. This looks like an old bug (fixed in
  version 1.12 of win/tkWinWm.c ?)


tkt_uuid: 2941732fffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 54. [console]
priority: 5 Medium
foundin: obsolete: 8.5.2
resolution: Out of Date
title: wish85.exe, error hitting funtion-key [F9]
comment:
  hitting function-key [F9] at the gives an error

  system : Windows
  file      : \Tcl\bin\wish85.exe
  version:  8.5.2.2
  wish for windows console error hiting function-key [F9]


tkt_uuid: 2073526fffffffffffffffffffffffffffffffff
type: Bug
status: Open
subsystem: 18. [text]
priority: 5 Medium
foundin: obsolete: 8.4.7
resolution: None
title: Accented characters in text widget, linux
comment:
  I've observed this problem using an old version of Tk (8.4.7). Maybe it's solved in newer versions, but I couldn't check. I happens in Linux, but not in Windows.

  The problem happens when I try to type an accented character like á (this is &aacute; in HTML, in case that you cannot see correctly). To try this with an English keyboard, there should be an accent character if you press AltGr+#, for instance.

  The problem is the following one. If I do:

  > text .t
  > pack .t

  The accented characters work, and I can type á by pressing first the ´ character, releasing the key, and then typing the a.

  But if I pack any other widget afterwards, for instance:

  > frame .f
  > pack .f

  Then the accented characters stop working and I can only type a.

  Finally, if I create another text widget:

  > text .u
  > pack .u

  I can only type á in the second text, but the first one still doesn't work.

  I've traced the binding for <Key> in the Text class. When I pack only the first text, .t, the binding executes only after I've hit the two keys:

  tk::TextInsert .t á

  And after I've packed the frame .f, it executes immediately after I hit each key:

  tk::TextInsert .t {}        <-- when I hit ´
  tk::TextInsert .t a         <-- when I hit a


tkt_uuid: 2999889fffffffffffffffffffffffffffffffff
type: Patch
status: Closed
subsystem: 01. Bindings
priority: 5 Medium
foundin: None
resolution: Fixed
title: TkCopyAndGlobalEval obsolete
comment:
  In the Changelog I see (see below)...

  Would it not be better just to remove it from
  the stub table?
  =======================================
  2009-07-23  Donal K. Fellows  <dkf@users.sf.net>
      ....
      (LostSelection, Tk_SelectionObjCmd): Stop using the vastly inefficient
      TkCopyAndGlobalEval; better to use Tcl_Obj refcount management.


tkt_uuid: 220351ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 68. Win Window Operations
priority: 2
foundin: obsolete: 8.0p2
resolution: Fixed
title: Fix wm frame on Windows
comment:
  OriginalBugID: 589 Bug
  Version: 8.0p2
  SubmitDate: '1998-05-21'
  LastModified: '1998-08-05'
  Severity: LOW
  Status: Released
  Submitter: stanton
  ChangedBy: stanton
  OS: All Windows
  OSVersion: NA
  Machine: NA
  FixedInVersion: 8.0.3
  ClosedDate: '1998-08-05'


  On Windows, using tk8.0p2, if you call wm frame immediately after

  creating a window, you are liable to get a segmentation violation.

  The Tk code does not check whether a window exists before getting the

  window identifier.



  The appended patch fixes this problem.  This patch appears to be

  required in Tk8.1a2 as well.



  Ian Taylor

  ian@cygnus.com





  *** /5g/ian/tk8.0p2/win/tkWinWm.c       Fri Oct 31 12:57:07 1997

  --- tkWinWm.c   Wed Apr 15 15:58:45 1998

  *************** Tk_WmCmd(clientData, interp, argc, argv)

  *** 1354,1359 ****

  --- 1354,1362 ----

                      argv[0], " frame window\"", (char *) NULL);

              return TCL_ERROR;

          }

  +       if (Tk_WindowId((Tk_Window) winPtr) == None) {

  +           Tk_MakeWindowExist((Tk_Window) winPtr);

  +       }

          hwnd = wmPtr->wrapper;

          if (hwnd == NULL) {

              hwnd = Tk_GetHWND(Tk_WindowId((Tk_Window) winPtr));





  applied patch 8/5/98 (SS)


tkt_uuid: 3519896fffffffffffffffffffffffffffffffff
type: Bug
status: Pending
subsystem: 88. Themed Tk
priority: 5 Medium
foundin: obsolete: 8.5.10
resolution: Invalid
title: configure font not working properly
comment:
  TLabelframe does not list 'label' as a child, but TLabelframe.label does return a list of elements including -font. ttk.Style().configure('TLabelframe.label', font='fontname') does not change the font used, but using 'TLabelframe.Label' instead does work (note uppercase 'L'). 

  For TButton which lists label as a child, TButton.label (or .Label) does not change the font, while TButton alone does.. TCheckbutton is the same.

  For TEntry, I could not find any value that worked to change the font.  I tried with and without .label/.Label, with .textarea/Textarea, and both in combination.

  I am testing on OSX and Windows using Python 2.7.2, and Tcl/Tk 8.5.11.


tkt_uuid: 220706ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 09. [listbox]
priority: 2
foundin: obsolete: 8.3
resolution: Fixed
title: Crash: Null pointer read (tkwin is NULL) in tkListbox.c line 1450.
comment:
  OriginalBugID: 4385 Bug
  Version: 8.3
  SubmitDate: '2000-03-16'
  LastModified: '2000-03-23'
  Severity: CRIT
  Status: Released
  Submitter: techsupp
  ChangedBy: hobbs
  OS: Solaris
  OSVersion: Solaris 2.5.1
  Machine: Solaris
  FixedDate: '2000-03-23'
  FixedInVersion: 8.3.1


  Name:

  Douglas Selph


  Extensions:

  tcl 8.3.0, tk8.3.0, itcl3.1.0,  blt2.4m, iwidgets3.0.0


  Comments:

  Although I haven't worked out a reproducible example, looking at the

      code, I believe it is quite clear where the problem lies.  I am not

      exactly sure the right way to fix it though so I don't have a proposed

      patch.


      Analysis:


      The problem occurs on line 1598 of tkConfig.c:


              case TK_OPTION_CURSOR:

                  if (internalFormExists) {

                      if (*((Tk_Cursor *) internalPtr) != None) {

                          Tk_FreeCursor(Tk_Display(tkwin),

                                  *((Tk_Cursor *) internalPtr));

                          *((Tk_Cursor *) internalPtr) = None;

                      }


      The value of 'tkwin' is NULL, therefore the above code crashes.


      The stack trace above it is:


                  FreeResources  [tkConfig.c:1598]

                  Tk_FreeConfigOptions [tkConfig.c:1500]

                                     oldInternalPtr = NULL;

                                 }

                                 if (optionPtr->flags & OPTION_NEEDS_FREEING)

      {

                  =>                 FreeResources(optionPtr, oldPtr,

      oldInternalPtr, tkwin);

                                 }

                                 if (oldPtr != NULL) {

                                     Tcl_DecrRefCount(oldPtr);

                  DestroyListbox [tkListbox.c:1450]

                             Tk_FreeGC(listPtr->display, listPtr->selTextGC);

                         }

                         Tk_FreeConfigOptions((char *)listPtr,

      listPtr->optionTable,

                  =>             listPtr->tkwin);

                         ckfree((char *) listPtr);

                     }


                  ListboxEventProc [tkListbox.c:2365]

                             if (listPtr->flags & REDRAW_PENDING) {

                                 Tcl_CancelIdleCall(DisplayListbox,

      (ClientData) listPtr);

                             }

                  =>         Tcl_EventuallyFree((ClientData) listPtr,

      DestroyListbox);

                         } else if (eventPtr->type == ConfigureNotify) {

                             int vertSpace;


      Now, tkwin is indeed NULL in the functions FreeResources,

      Tk_FreeConfigOptions, and DestroyListbox.  (I saw this in the

      debugger).


      And if you look in ListboxEventProc, just before the call to 


      Tcl_EventuallyFree((ClientData) listPtr, DestroyListbox);


      occurs, you will see the following lines:


              if (listPtr->tkwin != NULL) {

                  if (listPtr->setGrid) {

                      Tk_UnsetGrid(listPtr->tkwin);

                  }

                  listPtr->tkwin = NULL;

                  Tcl_DeleteCommandFromToken(listPtr->interp,

      listPtr->widgetCmd);

              }

              if (listPtr->flags & REDRAW_PENDING) {

                  Tcl_CancelIdleCall(DisplayListbox, (ClientData) listPtr);

              }

              Tcl_EventuallyFree((ClientData) listPtr, DestroyListbox);


      Notice in the above lines that 'tkwin' is explicitly getting set to

      NULL!

      And as I peruse the tkListbox.c code I see that tkwin is indeed allowed

      to be NULL in a number of places.

      However, in tkConfig.c it appears that tkwin is assumed NOT to be NULL.


      Why I couldn't find and apply a suitable patch:


      Where does one apply the fix?  Should you start detecting for a NULL

      tkwin in tkConfig.c?  If you do that, it seems to me you have to do it

      everywhere in that file.


      If you check for a NULL tkwin in tkListbox.c, ie. not calling 

      Tk_FreeConfigOptions((char *)listPtr, listPtr->optionTable,

                  listPtr->tkwin);

      on line 1450 when tkwin is NULL, then you loose all the other

      freeing benefits of the same call.  So what to do?


  ReproducibleScript:

  (I can only reproduce this within my wish under a complex set of circumstances.  I did not spend the time to try and find an indepedent working reproducible example.  However, even so, I believe I have found a convincing case that the code in tkConfig.c and tkListbox.c has some notable problems.  I describe this in detail below.  If this is still not good enough (please be good enough), I can try and come up with a reproducible senario.)


  ObservedBehavior:

  Program crashed.


  Stack Trace:


        NPR: Null pointer read

        This is occurring while in:

              FreeResources  [tkConfig.c:1598]

                             if (internalFormExists) {

                                 if (*((Tk_Cursor *) internalPtr) != None) {

                                     Tk_FreeCursor(Tk_Display(tkwin),

              =>                             *((Tk_Cursor *) internalPtr));

                                     *((Tk_Cursor *) internalPtr) = None;

                                 }

                             } else if (objPtr != NULL) {

              Tk_FreeConfigOptions [tkConfig.c:1500]

                                 oldInternalPtr = NULL;

                             }

                             if (optionPtr->flags & OPTION_NEEDS_FREEING) {

              =>                 FreeResources(optionPtr, oldPtr, oldInternalPtr,

  tkwin);

                             }

                             if (oldPtr != NULL) {

                                 Tcl_DecrRefCount(oldPtr);

              DestroyListbox [tkListbox.c:1450]

                         Tk_FreeGC(listPtr->display, listPtr->selTextGC);

                     }

                     Tk_FreeConfigOptions((char *)listPtr, listPtr->optionTable,

              =>             listPtr->tkwin);

                     ckfree((char *) listPtr);

                 }


              ListboxEventProc [tkListbox.c:2365]

                         if (listPtr->flags & REDRAW_PENDING) {

                             Tcl_CancelIdleCall(DisplayListbox, (ClientData)

  listPtr);

                         }

              =>         Tcl_EventuallyFree((ClientData) listPtr,

  DestroyListbox);

                     } else if (eventPtr->type == ConfigureNotify) {

                         int vertSpace;


              Tk_HandleEvent [tkEvent.c:722]

              Tk_DestroyWindow [tkWindow.c:1237]

              Tk_DestroyWindow [tkWindow.c:1180]

              Tk_DestroyWindow [tkWindow.c:1180]

              Tk_DestroyWindow [tkWindow.c:1180]

              Tk_DestroyWindow [tkWindow.c:1180]

              Tk_DestroyWindow [tkWindow.c:1180]

              Tk_DestroyWindow [tkWindow.c:1180]

              Tk_DestroyWindow [tkWindow.c:1180]

              Tk_DestroyWindow [tkWindow.c:1180]

              Tk_DestroyWindow [tkWindow.c:1180]

              Tk_DestroyWindow [tkWindow.c:1180]

              Tk_DestroyWindow [tkWindow.c:1180]

              DeleteWindowsExitProc [tkWindow.c:2552]

              Tcl_Finalize   [tclLoadDl.c]

              Tcl_Exit       [tclLoadDl.c]

              StdinProc      [tkMain.c:325]

              Tcl_NotifyChannel [tclLoadDl.c]

              FileHandlerEventProc [tclUnixNotfy.c]

              Tcl_ServiceEvent [tclLoadDl.c]

              Tcl_DoOneEvent [tclLoadDl.c]

              Tk_MainLoop    [tkEvent.c:1130]

              Tk_MainEx      [tkMain.c:281]

              main           [tkAppInit.o]

              _start         [crt1.o]

        Reading 4 bytes from 0x0




  This sounds like the problem with setting the listbox cursor
  and then destroying the listbox (introduced for 8.3, fixed
  in 8.3.1 already). 
  -- 03/23/2000 hobbs


tkt_uuid: 2969401fffffffffffffffffffffffffffffffff
type: Bug
status: Open
subsystem: 62. Geometry Functions
priority: 5 Medium
foundin: obsolete: 8.6b1
resolution: None
title: Coordinates reported wrongly on ppc
comment:
  This applies to all versions from 8.4.7 up through 8.6b1.1 when running on a ppc-based Mac with OSX 10.3. After you move a window by dragging its titlebar, the geometry is subsequently reported wrongly. For instance if it is a toplevel window, the command 'winfo geometry .' gives the result 200x200+0+22, wherever the window is moved to (the size is reported correctly, the offset is wrong). Also the coordinates returned for the mouse position relative to the window in bound commands are wrong;  the %x and %y keywords are substituted with the same values as the %X and %Y keywords.
  The correct behaviour can be restored after moving the window, by maximizing and then normalizing it.


tkt_uuid: 1845164fffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 88. Themed Tk
priority: 5 Medium
foundin: obsolete: 8.5b3
resolution: Fixed
title: ttk::combobox trims display text in long view
comment:
  If you run the combobox demo, see code, and then add "-fill x -expand 1" to the final 4 pack lines and rerun, you can see this in the head.  Resize the window a bit wider for obvious effect.

  If I type in 0123456789abcdefghijklmnopqrst into the top entry, it stops displaying at l (ell).  If you play around with the cursor, you see that the "entry" portion of the combobox just seems to be truncated.

  No problem seen on X11, Win32.


tkt_uuid: 2800684fffffffffffffffffffffffffffffffff
type: Bug
status: Open
subsystem: 88. Themed Tk
priority: 5 Medium
foundin: None
resolution: None
title: ttk::notebook rendering is slow on Windows platform
comment:
  ttk::notebook rendering is considerably slower than rendering of other widgets on Windows platform. This looks ugly when resizing a window with notebook or paned window. 

  For example, in this code

  package require Tk
  pack [panedwindow .p -orient vertical] -fill both -expand 1
  .p add [text .p.t1]
  .p add [text .p.t2]
  .p add [ttk::notebook .p.nb]
  .p.nb add [text .p.nb.t] -text Text

  moving the upper sash redraws considerably faster, than that when moving the lower sash. This holds both for Tk 8.5 and 8.6, Windows XP and Vista


tkt_uuid: 219998ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 99. Other
priority: 1 Zero
foundin: final: 8.0.5
resolution: Duplicate
title: Word-wrapping problem with 8-bit strings (latin1 accented chars) and other related problems
comment:
  OriginalBugID: 2288 Bug
  Version: 8.0.5
  SubmitDate: '1999-06-25'
  LastModified: '1999-08-05'
  Severity: LOW
  Status: Closed
  Submitter: techsupp
  ChangedBy: hobbs
  RelatedBugIDs: 2305
  OS: Windows 98
  Machine: X86
  ClosedDate: '1999-08-05'


  Name:
  Frédéric BONNET

  Comments:
  I believe there are many places in Tcl and Tk where is-routines are used
      (isspace, isupper...). Most seem to be called with signed chars as
      argument. The solution would be to find them all and wrap their
      arguments with UCHAR(). Strangely, this macro had been defined (in
      tclInt.h) several years ago in order for is-routines to be called
      safely, but newer code doesn't seem to take it into account. I don't
      think this problem still exist under Tcl8.1 now that it uses UTF-8.

  ReproducibleScript:
  # Try it on Windows. Other platforms may need different pixel values
      # for the bug to occur.

      # Notice the accented e in the third word
      label .l -font "Arial 16" -wraplength 130  -text "azertyuiop azertyuiop azértyuiop"

      # After packing, notice how the 3rd word is incorrectly cut
      pack .l -expand 1 -fill both

  ObservedBehavior:
  The Tk_MeasureChars() function, when used with the TK_WHOLE_WORDS flags,
      is supposed to wrap strings at word boundaries (ie spaces). To do so, it
      uses the ANSI C function isspace(), but it forgets to cast the char
      argument into an unsigned char using the UCHAR() macro. The consequence
      is that some words are broken at 8-bit chars such as accented chars. I
      observed this problem on Windows, where isspace() is a macro doing a
      lookup in a static table using the char value as the index. When this
      value is negative the lookup is done outside the table boundary and so
      reports unpredictable results, as it is documented in the MS VC++
      documentation ("is, isw routines").

  DesiredBehavior:
  Correct handling of 8-bit characters with is-routines.



  patch provided in related report, but 8.0.5 has no plans for
  an 8.0.6. 
  -- 08/05/1999 hobbs


tkt_uuid: 220273ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 44. Generic Fonts
priority: 1 Zero
foundin: obsolete: 8.2
resolution: Invalid
title: Character widths wrong in Unicode text
comment:
  OriginalBugID: 4075 Bug
  Version: 8.2
  SubmitDate: '2000-01-24'
  LastModified: '2000-05-18'
  Severity: MED
  Status: Closed
  Submitter: techsupp
  ChangedBy: hobbs
  RelatedBugIDs: 2027
  OS: Linux
  ClosedDate: '2000-05-18'


  Name:
  Raphael Finkel

  ReproducibleScript:
  set width 40
  set blanks "                                        "; # 40 

  set convert(b) "\u5d1"

  text .here -height 2 -width [expr 2*$width] -font OEMFixed
  .here insert end $blanks
  focus .here; # so it gets a cursor
  pack .here 

  proc reduce {character numeric} {
          global convert
          if {$numeric > 0 && $numeric < 256} {
                  if {[info exists convert($character)]} {
                          return $convert($character)
                  } else {
                          return [format %c $numeric]
                  }
          } else {
                  return ""
          }
  }; # reduce

  set lineString {} ;# unicode representation

  bind Text <KeyPress> { ;# overriding the usual binding
          set reduced [reduce %K %N]
          set length [string length $reduced]
          if {$length > 0 && $length < 4} { ;# printable character
                  if {[string length $lineString] == 0} {
                          set rtlPlace [expr $width - 1]
                  }
                  append lineString $reduced
                  incr rtlPlace -1
                  .here delete 1.$rtlPlace
                  .here insert 1.$rtlPlace $reduced
          } 
  } ;# bind Text <KeyPress>

  vwait foo

  ObservedBehavior:
  type into the window a few "b" characters.  The Hebrew letter "beyt" will appear.  Each time you type "b", the program deletes a space on the left and inserts a "beyt" in its place.  Notice how the right hand margin creeps to the right.  It shouldn't.  After a few "b" characters, type "a" characters.  The
  "a"s will also be placed on the left, in the same way.  No more creepage.  It seems that Hebrew letters are misjudged as to screen width.  I have this problem
  both with font OEMFixed and font -misc-fixed-medium-r-normal--20-200-75-75-c-100-iso10646-1 .

  DesiredBehavior:
  The right-hand margin should not move as characters are typed, whether "b" or "a".



  The problem here appears to be just that the font really isn't
  of fixed width, so the spaces are smaller than the chars that
  are inserted.  This is backed up by the following:

  (tkcon) 64 % font metrics OEMFixed
  -ascent 15 -descent 3 -linespace 18 -fixed 0
   
  -- 05/18/2000 hobbs


tkt_uuid: 2995339fffffffffffffffffffffffffffffffff
type: Bug
status: Open
subsystem: 88. Themed Tk
priority: 5 Medium
foundin: obsolete: 8.5.8
resolution: None
title: ttk::sizegrip strange behaviour
comment:
  Sometimes, yet to be determined, grabbing the sizegrip MOVES (instead of resizes) the window. The window is shifted by 10 pixels or so to the bottom of the screen.
  The sizegrip is packed to the right of an expanded frame packed to the bottom of the toplevel.


tkt_uuid: 3307625fffffffffffffffffffffffffffffffff
type: Bug
status: Open
subsystem: 04. Canvas Basics
priority: 5 Medium
foundin: obsolete: 8.5.9
resolution: None
title: scroll region of text limited to 32767 pixels
comment:
  Attached script adds a [text] item of 5000 lines
  to a canvas.  Attempts to scroll to the end get 
  stuck as they try to pass 32767 pixels.


tkt_uuid: 3593334fffffffffffffffffffffffffffffffff
type: Bug
status: Open
subsystem: 03. [*button] and [label]
priority: 5 Medium
foundin: obsolete: 8.5.13
resolution: None
title: checkbutton bitmap via config not highlighted on Aqua
comment:
  On Aqua I observe that the behavior of checkbuttons and radiobuttons that use bitmaps is correct if the bitmap is supplied at creation, but not if supplied via config later. Here is test code that demonstrates the issue for checkbutton.

  checkbutton .b
  checkbutton .c -bitmap question
  pack .c
  .b config -bitmap question
  pack .b

  In the test code below observe that the top button changes appearance when checked and the bottom one does not. Also, the bottom button is smaller and appears to be missing its border  (which maybe part of the problem, but does not explain everything, since the top button turns gray all over when pressed).

  Note that on Aqua the indicator is not shown if the button is a bitmap (unlike on unix), so the bitmap needs to change appearance to indicate the state of the button.


tkt_uuid: 3604914fffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 01. Bindings
priority: 5 Medium
foundin: current: 8.6.0
resolution: Duplicate
title: cocoa 8.6.0 Text <<Paste>> not bound to tk_textPaste
comment:
  Should 
  bind Text <<Paste>>
  return 
  tk::TextScrollPages %W 1
  ?

  It seems like it should be
  tk_textPaste %W

  is there a reason for this change?


tkt_uuid: 655788ffffffffffffffffffffffffffffffffff
type: RFE
status: Closed
subsystem: 18. [text]
priority: 5 Medium
foundin: None
resolution: None
title: R-click "cut/copy/paste" menu as default
comment:
  The most basic and common feature of editable text is 
  being able to right-click the text and having a menu pop-
  up that gives (at a minimum) cut-copy-paste options.  

  Any Windows or Linux program has this, and Perl/TK 
  has this too, as a default.  Tcl/TK should absolutely 
  have this feature, since it is much more Windows/Linux -
  friendly in general. 

  It would be really nice to see these five options:

  cut
  copy
  paste
  -------
  undo
  select all


tkt_uuid: 1078646fffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 51. [place]
priority: 4
foundin: obsolete: 8.4.9
resolution: None
title: place-14.1 fails : memory leak!
comment:
  On Solaris, build Tcl/Tk 8.4.9 
  with --disable-shared 
  --enable-threads --enable-symbols=all

  then

  make test TESTFLAGS="-debug 1"

  There will be a flood of error messages
  about bad tests (subject for another
  a report), but in the midst is a failed test:

  ==== place-14.1 memory leak testing FAILED
  ==== Contents of test case:

      # Test all manners of forgetting a slave
      frame .f
      frame .f.f
      stress {
          place .f.f -x [expr {1 + 1}] -y [expr {2 + 2}]
          place forget .f.f
      } {
          place .f.f -x [expr {1 + 1}] -y [expr {2 + 2}]
          pack .f.f
      } {
          place .f.f -x [expr {1 + 1}] -y [expr {2 + 2}]
          destroy .f
          frame .f
          frame .f.f
      }

  ---- Result was:
  0 0 52
  ---- Result should have been (exact matching):
  0 0 0
  ==== place-14.1 FAILED

  This failure indicates a memory leak.

  Fix would be great, but even reproduction
  of this would be helpful.


tkt_uuid: 1887171fffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 12. Unix Menus
priority: 5 Medium
foundin: None
resolution: Duplicate
title: help menu should not be right justified
comment:
  While it should continue to be the last menu, having it right justified in the menubar is a holdover from Motif... systems like KDE and Gnome don't do that anymore


tkt_uuid: 1719285fffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 67. Unix Window Operations
priority: 5 Medium
foundin: obsolete: 8.5a6
resolution: Invalid
title: unixwm test suite 4.x failures
comment:
  platform: sparc solaris 9, sun c compiler, latest tcl/tk cvs head, windows xp pro/exceed 10 x server

  ==== unixWm-4.1 moving window while withdrawn FAILED
  ==== Contents of test case:

          wm withdraw .t
          sleep 200
          wm geom .t $geom
          update
          wm deiconify .t
          wm geom .t
      
  ---- Result was:
  100x150+57+80
  ---- Result should have been (exact matching):
  100x150+20+80
  ==== unixWm-4.1 FAILED

  ==== unixWm-4.3 moving window while withdrawn FAILED
  ==== Contents of test case:

          wm withdraw .t
          sleep 200
          wm geom .t $geom
          update
          wm deiconify .t
          wm geom .t
      
  ---- Result was:
  100x150+57+39
  ---- Result should have been (exact matching):
  100x150+0+0
  ==== unixWm-4.3 FAILED

  ==== unixWm-48.13 ParseGeometry procedure, resize causes window to move FAILED
  ==== Contents of test case:

      catch {destroy .t}
      toplevel .t -width 200 -height 200
      wm geom .t +0+0
      update
      wm geom .t -0-0
      update
      set x [winfo x .t]
      set y [winfo y .t]
      wm geometry .t 150x300
      update
      list [expr [winfo x .t] - $x] [expr [winfo y .t] - $y]  [winfo width .t] [wi
  nfo height .t]

  ---- Result was:
  0 0 150 300
  ---- Result should have been (exact matching):
  50 -100 150 300
  ==== unixWm-48.13 FAILED
  ==== unixWm-50.1 Tk_CoordsToWindow procedure, finding a toplevel, x-coords FAILE
  D
  ==== Contents of test case:

      deleteWindows
      toplevel .t -width 300 -height 400 -bg green
      wm geom .t +40+0
      tkwait visibility .t
      toplevel .t2 -width 100 -height 80 -bg red
      wm geom .t2 +140+200
      tkwait visibility .t2
      raise .t2
      set x [winfo rootx .t]
      set y [winfo rooty .t]
      list [winfo containing [expr $x - 30] [expr $y + 250]]  [winfo containing [e
  xpr $x - 1] [expr $y + 250]]  [winfo containing $x [expr $y + 250]]  [winfo cont
  aining [expr $x + 99] [expr $y + 250]]  [winfo containing [expr $x + 100] [expr 
  $y + 250]]  [winfo containing [expr $x + 199] [expr $y + 250]]  [winfo containin
  g [expr $x + 200] [expr $y + 250]]  [winfo containing [expr $x + 220] [expr $y +
   250]]

  ---- Result was:
  {} {} .t .t .t .t .t .t
  ---- Result should have been (exact matching):
  {} {} .t {} .t2 .t2 {} .t
  ==== unixWm-50.1 FAILED
  ==== unixWm-50.8 Tk_CoordsToWindow procedure, more basics FAILED
  ==== Contents of test case:

      catch {destroy .t}
      toplevel .t -width 400 -height 300 -bg green
      wm geom .t +0+0
      frame .t.f -width 200 -height 100 -bd 2 -relief raised
      place .t.f -x 100 -y 100
      frame .t.f.f -width 200 -height 100 -bd 2 -relief raised
      place .t.f.f -x 100 -y 0
      update
      set x [winfo rooty .t]
      set y [expr [winfo rooty .t] + 150]
      list [winfo containing [expr $x + 50] $y]  [winfo containing [expr $x + 150]
   $y]  [winfo containing [expr $x + 250] $y]  [winfo containing [expr $x + 350] $
  y]  [winfo containing [expr $x + 450] $y]

  ---- Result was:
  .t.f .t.f.f .t {} {}
  ---- Result should have been (exact matching):
  .t .t.f .t.f.f .t {}
  ==== unixWm-50.8 FAILED
  ==== unixWm-50.10 Tk_CoordsToWindow procedure, unmapped windows FAILED
  ==== Contents of test case:

      catch {destroy .t}
      toplevel .t -width 200 -height 200 -bg green
      wm geometry .t +0+0
      frame .t.f -width 150 -height 150 -bd 2 -relief raised
      place .t.f -x 25 -y 25
      tkwait visibility .t.f
      set result [list [winfo containing 100 100]]
      place forget .t.f
      update
      lappend result [winfo containing 100 100]

  ---- Result was:
  .t .t
  ---- Result should have been (exact matching):
  .t.f .t
  ==== unixWm-50.10 FAILED


tkt_uuid: 3564189fffffffffffffffffffffffffffffffff
type: Bug
status: Open
subsystem: 23. Option Parsing
priority: 5 Medium
foundin: obsolete: 8.5.12
resolution: None
title: configure gives inconsistent result for aliased option
comment:
  Example:
  1 % info patchlevel
  8.5.12
  2 % canvas .c
  .c
  3 % join [.c configure] \n
  -background background Background SystemButtonFace SystemButtonFace
  -bd borderWidth
  -bg background
  -borderwidth borderWidth BorderWidth 0 0
  ...
  % frame .f
  .f
  5 % join [.f configure] \n
  -bd -borderwidth
  -borderwidth borderWidth BorderWidth 0 0
  ...
  -background background Background SystemButtonFace SystemButtonFace
  -bg -background
  ...
  Expected:
  dbName without dash in all cases. This is what the manual says for Tk_ConfigureInfo.


tkt_uuid: 220663ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 63. Tk_Win Functions
priority: 2
foundin: obsolete: 8.3b2
resolution: Fixed
title: crash on exit when creating windows in destroy
comment:
  OriginalBugID: 4079 Bug
  Version: 8.3b2
  SubmitDate: '2000-01-24'
  LastModified: '2000-03-06'
  Severity: CRIT
  Status: Released
  Submitter: techsupp
  ChangedBy: ericm
  OS: All
  FixedDate: '2000-03-06'
  FixedInVersion: 8.3.1


  Name:
  Vince Darley

  ReproducibleScript:
  The problem is Tk_NameToWindow is called with a null tkwin argument.

  Script:
  # Double-click on this script under WindowsNT and
  # select 'quit' from the file menu to show the crash.
  menu .menubar
  menu .menubar.mfile
  menu .menubar.mrecent

  .menubar add cascade -menu .menubar.mfile -label "File"
  .menubar.mfile add cascade -menu .menubar.mrecent -label "Recent"
  .menubar.mfile add command -label "Quit" -command exit
  . configure -menu .menubar
  toplevel .t
  bind Toplevel <Destroy> {menu .menubar.mrecent}

  ObservedBehavior:
  Crash

  Complete call stack:

  Tk_NameToWindow(Tcl_Interp * 0x0015cab0, char * 0x00ced5a0, Tk_Window_ * 0x00000000) line 2113 + 7 bytes
  Tk_CreateWindowFromPath(Tcl_Interp * 0x0015cab0, Tk_Window_ * 0x00000000, char * 0x00d390c0, char * 0x0031e444) line 1045 + 17 bytes
  MenuCmd(int * 0x001ca880, Tcl_Interp * 0x0015cab0, int 2, Tcl_Obj * const * 0x0012f2c8) line 478 + 31 bytes
  EvalObjv(Tcl_Interp * 0x0015cab0, int 2, Tcl_Obj * const * 0x0012f2c8, char * 0x0012f4e0, int 21, int 0) line 932 + 25 bytes
  Tcl_EvalEx(Tcl_Interp * 0x0015cab0, char * 0x0012f4e0, int 21, int 0) line 1393 + 30 bytes
  Tcl_Eval(Tcl_Interp * 0x0015cab0, char * 0x0012f4e0) line 1512 + 17 bytes
  Tcl_GlobalEval(Tcl_Interp * 0x0015cab0, char * 0x0012f4e0) line 4139 + 13 bytes
  Tk_BindEvent(Tk_BindingTable_ * 0x00168ac0, _XEvent * 0x0012f6b0, Tk_Window_ * 0x00d19760, int 0, int * * 0x0012f5f8) line 1789 + 23 bytes
  TkBindEventProc(TkWindow * 0x00d19760, _XEvent * 0x0012f6b0) line 245 + 31 bytes
  Tk_HandleEvent(_XEvent * 0x0012f6b0) line 737 + 13 bytes
  Tk_DestroyWindow(Tk_Window_ * 0x00d19760) line 1237 + 9 bytes
  Tk_DestroyWindow(Tk_Window_ * 0x0016f7d0) line 1180 + 9 bytes
  DeleteWindowsExitProc(int * 0x00000000) line 2552 + 15 bytes
  Tcl_Finalize() line 764 + 12 bytes
  Tcl_Exit(int 0) line 561
  Tcl_ExitObjCmd(int * 0x00000000, Tcl_Interp * 0x0015cab0, int 1, Tcl_Obj * const * 0x00174ae0) line 672 + 9 bytes
  TclExecuteByteCode(Tcl_Interp * 0x0015cab0, ByteCode * 0x00234b20) line 846 + 25 bytes
  Tcl_EvalObjEx(Tcl_Interp * 0x0015cab0, Tcl_Obj * 0x00d0c7e8, int 131072) line 2723 + 13 bytes
  TkInvokeMenu(Tcl_Interp * 0x0015cab0, TkMenu * 0x00d19e60, int 2) line 1113 + 27 bytes
  TkWinHandleMenuEvent(HWND__ * * 0x0012fc4c, unsigned int * 0x0012fc50, unsigned int * 0x0012fc54, long * 0x0012fc58, long * 0x0012fc40) line 988 + 23 bytes
  WmProc(HWND__ * 0x00eb0890, unsigned int 273, unsigned int 35, long 0) line 4179 + 25 bytes
  USER32! 77e71268()



  Verified on Solaris7 and NT. 
  -- 01/25/2000 hobbs

  A simpler case:

  ------------------------------------
  bind Toplevel <Destroy> {menu .menu}
  toplevel .t
  exit
  ------------------------------------

  In general, this happens anytime the result from Tk_MainWindow is used without checking for NULL, which includes the creation of most widgets and the creation of photo images.

  I fixed the problem by putting protection against NULL tkwin in Tk_NameToWindow and in Tk_ConfigureWidget (which handles the photo case).  This fix will be in 8.3.1.

  - eric

  -- 03/06/2000 ericm


tkt_uuid: 220504ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 68. Win Window Operations
priority: 2
foundin: obsolete: 8.1b3
resolution: Fixed
title: Docs missing for Tk_GetHWND API
comment:
  OriginalBugID: 1863 Bug
  Version: 8.1b3
  SubmitDate: '1999-04-16'
  LastModified: '2000-04-24'
  Severity: MED
  Status: Released
  Submitter: surles
  ChangedBy: ericm
  OS: All
  OSVersion: NA
  Machine: NA
  FixedDate: '2000-04-24'
  FixedInVersion: 8.3.1


  .

  I added a man page for this API for 8.3.1.

  - eric
   
  -- 04/24/2000 ericm


tkt_uuid: 1723059fffffffffffffffffffffffffffffffff
type: Bug
status: Open
subsystem: 10. Generic Menus
priority: 5 Medium
foundin: obsolete: 8.5a6
resolution: None
title: Entryconfigure destroys submenus
comment:
  When creating a toplevel menubar (. configure -menu ...) and assigning it the same cascade submenu as it has and then replacing submenu with another the previous submenu is destroyed!

  Bad explanation, attached script demonstrates behaviour.


tkt_uuid: 220714ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 69. Events
priority: 2
foundin: obsolete: 8.3
resolution: Fixed
title: event generate can't generate Alt-* events
comment:
  OriginalBugID: 4611 Bug
  Version: 8.3
  SubmitDate: '2000-03-27'
  LastModified: '2000-04-11'
  Severity: MED
  Status: Released
  Submitter: hobbs
  ChangedBy: ericm
  OS: All
  FixedDate: '2000-04-11'
  FixedInVersion: 8.3.1


  As synopsis says, it effects all systems, but subtly different
  between Unix and Windows (Unix can generate them when using
  the Meta specifier).  Just do:

    pack [entry .e]
    bind .e <Alt-z> "puts alt-z'ed"
  # type alt-z to see that it works
    focus -force .e ; event generate .e <Alt-z>
  # this will just type a z into the widget

  Using Control works just fine.

  Verified; event generate is not creating the x event structure correctly for alt and meta keys.  I have a fix for this, almost done.

  - eric

  -- 04/10/2000 ericm

  Fixed is checked in and verified on Linux and NT.  As noted, the problem was basically this:

  to handle [event generate], we fake up an XEvent structure.  Part of that structure has a field that marks which modifier keys are set.  In Tk, we have two different views of modifier keys:  the Tk view, and the display specific view.  We were setting this modifier field to the values given by the Tk view, but then testing against the values for the display view.  I changed this to set the field to the values given by the display view.

  This only half fixed the problem.  The next issue was that the display view of the modifier bits was being determined lazily, only when Tk had to evaluate a key binding.  Of course, by the time it did that, we had already created our XEvent structure in [event generate].  The symptom of this was that [event generate $w <Alt-z>] would only work if it was the second key event handled by Tk for that display (ie, a "throw away" [event generate] would cause the initialization, as would a physical keypress of Alt-z).  I added code to cause this initialization (if necessary) in [event generate] as well, fixing this problem.

  This fix is in CVS now, and will go out with 8.3.1.  Good bug find to whomever actually noticed this one -- the bug has been around since [event generate] was introduced (in 8.0.?).

  - eric

  -- 04/11/2000 ericm


tkt_uuid: 2829363fffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 88. Themed Tk
priority: 5 Medium
foundin: obsolete: 8.5.7
resolution: Fixed
title: Treeview 'see' function
comment:
  Hi,

  I'm having a problem with the treeview 'see' command. If I create a treeview with several levels of hierarchy and try to see one of them with the see command. however, after issuing the command nothing happens until another event happen in the window. For example, with the following program:

  ttk::treeview .t -show tree 

  pack .t -side left -fill both -expand 1
  .t insert {} end -id a -text a
  .t insert a  end -id b -text b
  .t insert b  end -id c -text c

  after executing with
  > wish8.5
  % source prog.tk
  c
  % .t see c

  Then I need to do something like maximize the window or something like it, so that the item c is visible.

  Any help with this problem is appreciated.

  Best Regards,
  Daniel Barden


tkt_uuid: 442835ffffffffffffffffffffffffffffffffff
type: Patch
status: Closed
subsystem: 35. [tk_dialog]
priority: 5 Medium
foundin: None
resolution: Fixed
title: enhanced dialog.tcl - windows tk_dialog
comment:
  The tk_dialog file (dialog.tcl) has been enhanced for the windows platform to provide a frame and 
  button spacing that is cleaner and more consistent with the unix tk_dialog.  

  The frames that split the upper text area from the lower button (grid) area now display with a 
  raised relief and border width(1), as in unix,  and the pads on the text area were increased slightly 
  for better readability.

  The button area spacing has been corrected by adding a -pady value to the grid definition.


  M Harris


tkt_uuid: 1395558fffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 84. Unix Build
priority: 5 Medium
foundin: obsolete: 8.4.12
resolution: Out of Date
title: configure error with tk 8.4.12
comment:
  Using bash 3.1  I get the below error.

  line 6067: syntax error near unexpected token `('
  ./configure: line 6067: `  case `(ac_space=' '; set |
  grep ac_space) 2>&1` in'

  If I remove the ( ) I then get the below error.

  ./configure: line 6112: syntax error near unexpected
  token `{}\\'
  ./configure: line 6112: `s%[   
  `~#$^&*(){}\\|;'"<>?]%\\&%g'


tkt_uuid: 220677ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 36. [tk_chooseDirectory]
priority: 5 Medium
foundin: obsolete: 8.3.1
resolution: Fixed
title: tk_chooseDirectory fails to close after browsing the directory tree.
comment:
  OriginalBugID: 4157 Bug
  Version: 8.3
  SubmitDate: '2000-02-11'
  LastModified: '2000-09-07'
  Severity: SER
  Status: Released
  Submitter: sven
  ChangedBy: sven
  OS: All Windows
  FixedDate: '2000-09-07'
  FixedInVersion: 8.4


  When I use tk_choosDirectory on Windows NT, the following steps cause a problem:

  1. Bring up the dialog.
  2. Change the drive and select a directory name.
  3. When I now press the OK button nothing happens.
  4. I have to click on the entry widget to make the OK button work.

  Expected behavior:
  - The dialog should close and return the selected path



  This happened when the user selected the initial directory without selecting anything else and then pressed ok. I changed the involved routine to always return the directory shown in the entry field. This seems to be the expected behavior for Windows NT.  
  -- 03/15/2000 sven


tkt_uuid: 220012ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 33. Generic Dialog Support
priority: 1 Zero
foundin: obsolete: 8.2
resolution: Duplicate
title: Misbehaviour of common dialog boxes on Windows 9x/NT if multiple toplevels are used.
comment:
  OriginalBugID: 2589 RFE
  Version: 8.2
  SubmitDate: '1999-08-20'
  LastModified: '2000-01-29'
  Severity: SER
  Status: Closed
  Submitter: techsupp
  ChangedBy: hobbs
  RelatedBugIDs: 602
  OS: Other
  Machine: NA
  ClosedDate: '2000-01-29'


  Name:
  Christian Werner

  Comments:
  I think this is a long standing bug which appeared in Tcl/Tk 8.0 when
      native look-and-feel was invented.
      
      The problem  would disappear if the call of
      Tcl_SetServiceMode(TCL_SERVICE_ALL) would be removed before
      the Win32 API function MessageBox() is called (but then no redraws of
      other windows take place while the dialog
      box is open).
      
      An (IMHO unacceptable) workaround on Win32 is not to have more than one
      toplevel per application.

  ReproducibleScript:
  proc mktop w {
          if {[string length $w]} {
              set top [toplevel $w]
          } else {
              set top .
          }
          set bar [menu $w.menu]
          $top configure -menu $bar
          set m [menu $bar.menu]
          $bar add cascade -menu $m -label File
          $m add command -label "Hit Me" -command [list hitme $top]
          $m add command -label "Exit" -command [list destroy $top]
          button $w.button -text "Hit Me" -command [list hitme $top]
          pack $w.button -padx 20 -pady 20
      }
      proc hitme w {
          tk_messageBox -parent $w -type ok -title "Hit Me" -message "You hit
      me!"
      }
      foreach w {{} .t0 .t1 .t2 .t0.t1 .t0.t2 .t1.t1 .t2.t1} {
          mktop $w
      }
      
      # Invocation; (UNIX)           wish this-script
      #                   (Windows)     double-click in explorer
      #
      # Opens some toplevel windows where you can press a button or activate a
      menu item
      # in order to get a standard "ok" type dialog box. The dialog box should
      be application
      # modal which is not the case if run on windows.

  ObservedBehavior:
  UNIX: the script behaves as expected, ie the dialog boxes are modal
      (local grab).
      
      Windows 9X/NT:  the modality is restricted to the toplevel on whose
      behalf the dialog box is popped up.
      If a menu is torn off before the "Hit Me" button is pressed, another
      dialog box can be opened by activating the
      tear off menu. Sometimes an application crash happens if the main
      toplevel window (= .) is closed.
      
      MacOS: not tested

  DesiredBehavior:
  As the documentation of "tk_dialog" states:
      
      While waiting for the user to respond, tk_dialog sets a local grab.
      This prevents the user from interacting with the application in any way
      except to invoke the dialog box.



  The user cites the tk_dialog docs when complaining about the
  tk_messageBox.  Indeed, tk_dialog does set an application level
  grab, as the docs say, but tk_messageBox does not, nor do the
  docs for it claim to.  I am dup'ing this to 602, which is an
  RFE for a -modal switch on Windows that would take care of this. 
  -- 01/29/2000 hobbs


tkt_uuid: 1862340fffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 30. Color Names
priority: 5 Medium
foundin: None
resolution: Later
title: systemMetalBackground produces black
comment:
  In the list of supported colors at http://www.tcl.tk/man/tcl8.4/TkCmd/colors.htm we have some Mac specific colors.

  systemModelessDialogBackgroundActive works fine and provides the Pinstripe texture, systemMetalBackground doesn't and provides black.

  Example:

  pack [::label .l -text "Hello world." -background systemMetalBackground]

  This is on Tcl/Tk 8.4.16 (Activestate release).


tkt_uuid: 860307ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 53. [selection]
priority: 5 Medium
foundin: obsolete: 8.4.5.1
resolution: Invalid
title: Remove ::tk::GetSelection?
comment:
  Now it seems that tkUnixSelect.c can handle UTF8_STRING
  selections (see change from 2002-09-30), is
  ::tk::GetSelection in tk.tcl still needed?


tkt_uuid: 1191097fffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 66. Aqua Window Operations
priority: 5 Medium
foundin: None
resolution: Fixed
title: typo? in tkMacOSXNotify causes crash
comment:
  Current CVS about line 804 of tkMacOSXNotify.c:

   typo>           if (timePtr == NULL) {
                  waitTime = kEventDurationForever;
              } else {
          waitTime = myTimePtr->sec  * kEventDurationSecond 
    + myTimePtr->usec * kEventDurationMicrosecond;
              }

  Should be:

   if (myTimePtr == NULL) {


tkt_uuid: 590704ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 48. Geometry Management
priority: 5 Medium
foundin: obsolete: 8.4b1
resolution: Invalid
title: unmap crash in PackReqProc(), tkPack.c
comment:
  I'm using the C interface, on win-32. I'm using mostly 
  script calls (Tcl_Eval) but some Tk library calls where 
  necessary.

  When a Tk dialog is being unmapped, I crash in 
  PackReqProc(), tkPack.c. This happens if I have made 
  the dialog a "transient" to another dialog. If the dialog is 
  not a transient, it can be unmapped without crashing. 
  The unmapping is being done totally under script control.

  On line 482 in tkPack.c, PackReqProc(), it is casting 
  the clientData into packPtr. But packPtr->masterPtr 
  (next line of code) is 0xddddddd (probably not what the 
  author had in mind!).

  The call stack makes me think we shouldn't even be 
  going down this far - it looks like the dialog has already 
  been unmapped but we keep running until we get down 
  to PackReqProc(). Here's the call stack:

  PackReqProc()
  Tk_GeometryRequest()
  ArrangeGrid()
  TclServiceIdle() 
  Tcl_ServiceAll() 
  TkWinChildProc() 
  USER32! 
  USER32! 
  USER32! 
  USER32! 
  NTDLL! 
  Tk_UnmapWindow() line 1733: XUnmapWindow

  As I follow the Tk_UnmapWindow() calling down 
  ultimately to Tk_GeometryRequest(), I get confused by 
  all the cast and nested pointers so I'm afraid I can't offer 
  more insight... 

  Why would we be packing something that's already 
  been unmapped - Can we assume that NTDLL and 
  USER32 are busy trashing the window, following the 
  XUnmapWindow call?


tkt_uuid: 1782105fffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 66. Aqua Window Operations
priority: 9 Immediate
foundin: obsolete: 8.4.15
resolution: Fixed
title: tk_chooseColor returns garbage
comment:
  Similar to bug 1743786 also tk_chooseColor returns garbage,
  in this case for the "Ok" _and_ the "Cancel" button case.
  I get return values like "after#25" for the Cancel button
  and "after#25#fefefe" for the "Ok" button.
  As in 1743786 this shows up in my application but is not
  reproducible with plain wish.

  Maybe this is, because in tkMacOSXDialog.c:Tk_ChooseColorObjCmd()
  only Tcl_AppendResult() is used for "Ok", and no change to the
  result is attempted for "Cancel"?

  best regards,
  Randolf,
  -- 
  http://www.ayam3d.org/    Ayam, taming the RenderMan interface.


tkt_uuid: 1683795fffffffffffffffffffffffffffffffff
type: Bug
status: Open
subsystem: 03. [*button] and [label]
priority: 5 Medium
foundin: None
resolution: None
title: -padx obscures button text on Aqua
comment:
  button .b -text Foobazzulous -padx 5 ; pack .b

  This blots out the edges of the text in the Carbon-based Aqua native version of Tk (all versions I've tried: 8.4.x, 8.5a5).  This behavior is not observed on XWindows-based implementations of Tk.

  A related concern is a cross-platform incompatibility: a small -padx is necessary in many cases on XWindows versions to avoid the text crowding against the edges of the button, however in Aqua-native such padding is unnecessary.  Not sure what to suggest here however.


tkt_uuid: 220781ffffffffffffffffffffffffffffffffff
type: Bug
status: Open
subsystem: 13. Win Menus
priority: 5 Medium
foundin: obsolete: 8.0.3
resolution: None
title: wm overrideredirect zaps additions to system menu
comment:
  OriginalBugID: 955 Bug
  Version: 8.0.3
  SubmitDate: '1998-12-14'
  LastModified: '2000-01-06'
  Severity: MED
  Status: Assigned
  Submitter: pat
  ChangedBy: hobbs
  OS: All Windows
  Machine: X86


  Name: Tim Wilson

  ReproducibleScript:
  Working on Wish for Win95:

  % menu .m
  .m
  % menu .m.system
  .m.system
  % .m add cascade -menu .m.system
  % .m.system add command -label Hello
  % . configure -menu .m
  (Observe new "Hello" entry in system menu.)
  % . cget -menu
  .m
  (Confirm Tk knows about menu.)
  % wm overrideredirect . 0
  (I would expect this to be a no-op, but
  observe that "Hello" entry has disappeared from system menu.  BUG!)
  % . cget -menu
  .m
  (Tk thinks menu is there... but it isn't displaying it any more.)
  % . configure -menu .m
  (Observe that this doesn't fix it.)
  % . configure -menu {}
  % . configure -menu .m
  (This pair of operations successfully restores the additions to the system menu.)



  Verified that something really screwy is going on in 8.3b1.
  The 'wm override' does cause a loss of the system menu additions.
  It also causes . to increase in size with each call.  Clicking
  on the system menu after it disappears caused . to disappear on
  me, but you can reconfigure it otherwise. 
  -- 01/06/2000 hobbs
  Partial fix in 8.3b2 - 'wm override' will not do anything unless
  you are really changing values, becoming a true noop in the above
  case. 
  -- 01/06/2000 hobbs


tkt_uuid: 449428ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 36. [tk_chooseDirectory]
priority: 5 Medium
foundin: obsolete: 8.3.3
resolution: Works For Me
title: Does not work with invalid directory
comment:
  With the currrent implementation it is impossible to
  enter
  a name of an invalid directory, even if "-mustexist
  false" is specified. Looks like the sourcecode has to
  be changed as the attached patch shows.


tkt_uuid: 1240221fffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 18. [text]
priority: 7 High
foundin: obsolete: 8.5a4
resolution: Fixed
title: mark previous crashes
comment:
  The above script crashes with segfault with all Tk 8.5
  I've tried.

  package require Tk
  pack [text .t]
  .t insert end [string repeat "1 2 3 4 5 6 7 8 9 0\n" 12]
  .t mark set 1.0 10.0
  update
  # then this crash Tk:
  .t mark previous 10.10


tkt_uuid: 2805928fffffffffffffffffffffffffffffffff
type: Bug
status: Open
subsystem: 65. Generic Window Operations
priority: 5 Medium
foundin: obsolete: 8.5.7
resolution: None
title: wm iconphoto -default in slave interp affects other interps
comment:
  After using the -default switch of the [wm iconphoto] command in a slave interpreter, new toplevels in other interps, including the master, get the icon specified in the slave. This seems at odds with the statement in the interp manual page that "[e]ach interpreter is independent from the others". Also the wm manual page does not mention this contamination between interps.

  The best solution would be if each interp had its own concept of a default icon. But if that's not possible due to restrictions of the involved functions provided by the underlying window manager, there should be a clear warning about this in the wm manual page.

  Tested with Tk 8.5.7 on OpenSuSE 11.1


tkt_uuid: 2123813fffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 09. [listbox]
priority: 5 Medium
foundin: obsolete: 8.6a2
resolution: Fixed
title: listbox manual references non-existent ttk_listbox
comment:
  The bottom of the listbox manuals says to see also ttk_listbox, which does not exist in my installation.


tkt_uuid: 1495718fffffffffffffffffffffffffffffffff
type: Bug
status: Open
subsystem: 85. Win Build
priority: 5 Medium
foundin: obsolete: 8.5a4
resolution: None
title: Inconsistent link to standard debug libraries.
comment:
  This change:
  http://tktoolkit.cvs.sourceforge.net/tktoolkit/tk/win/rules.vc?r1=1.5.2.1&r2=1.5.2.2
  yanked the DBGX variable from win/rules.vc:
  It was:

  !if $(DEBUG)
  BUILDDIRTOP = Debug
  DBGX    = g
  !else
  BUILDDIRTOP = Release
  DBGX    =
  SUFX    = $(SUFX:g=)
  !endif

  and is now:

  !if $(DEBUG)
  BUILDDIRTOP = Debug
  !else
  BUILDDIRTOP = Release
  !endif

  This variable is critical though, for it is used in
  win/makefile.vc that way:

  !if $(MSVCRT)
  !if "$(DBGX)" == ""
  crt = -MD
  !else
  crt = -MDd
  !endif
  !else
  !if "$(DBGX)" == ""
  crt = -MT
  !else
  crt = -MTd
  !endif
  !endif

  Now that DBGX is not defined anymore, debug build of
  Tcl/Tk are linked against the wrong (non-debug)
  standard library (libcmt or msvcrt instead of libcmtd
  or msvcrtd). This causes problem with larger projects
  that link against Tcl/Tk (especially static ones),
  where the compiler will complain about two standard
  libraries being included.

  Note that this is done correctly in Tcl (DBGX is used
  exactly the same way). DBGX is actually not used for
  anything else in both Tcl and Tk.

  Please revert to:

  !if $(DEBUG)
  BUILDDIRTOP = Debug
  DBGX    = g
  !else
  BUILDDIRTOP = Release
  DBGX    =
  SUFX    = $(SUFX:g=)
  !endif

  Thanks.


tkt_uuid: 3019563fffffffffffffffffffffffffffffffff
type: Bug
status: Open
subsystem: 07. [entry]
priority: 5 Medium
foundin: obsolete: 8.6b1.1
resolution: None
title: copy and paste from Tk entry fails
comment:
  Platform: SPARC Solaris 10, tk 8.6 cvs head (happens in older versions of Tk as well)
  displaying on Windows XP SP 3 via either Hummingbird Exceed or Cygwin/X
  Program:
  package require Tk
  entry .e
  entry .f
  pack .e .f


  Case 1:
  I type the words "English1 English2" into the entry box.
  I press down on the mouse button, and drag across the first word.
  I press control-c to copy the text.
  I move the mouse into Microsoft Word 
  I press control-v to paste.
  Only the first character of the text is pasted.

  Case 2:
  Using the same program, with the same text in the entry, I double click on the string "English1".
  I press control-c to copy
  I move the mouse into Microsoft Word and press control-v.
  The word "English1" is pasted.
  I move the mouse back to the Tk entry widget, and double click on the word "English2".
  I press control-c to copy.
  I move the mouse back to Microsoft Word and press control-v.
  The world "English1" - which was the previous item copied to the clipboard - is pasted.

  Note that if I move the mouse to the second entry box, type some text there, and double click it, then move back to the first box and double click English2, 
  press control-c, move the mouse into Microsoft Word and press control-v, the correct word is pasted. 


tkt_uuid: 220144ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 05. Canvas Items
priority: 1 Zero
foundin: obsolete: 8.1b1
resolution: Invalid
title: Code hangs after changing an ovals binding
comment:
  OriginalBugID: 1513 Bug
  Version: 8.1b1
  SubmitDate: '1999-03-16'
  LastModified: '1999-03-25'
  Severity: CRIT
  Status: Closed
  Submitter: pat
  ChangedBy: surles
  OS: HP-UX
  OSVersion: B.10.20
  Machine: Other
  ClosedDate: '1999-03-25'


  Name:
  John Engebretsen

  ReproducibleScript:
      #!/bin/sh
      # the next line restarts using wish  exec wish "$0" "$@"
      
      button .b -command exit -bg black -fg white -text exit
      pack .b
      
      message .m -aspect 300 -bg blue -fg white -text "Is this a bug?
      Move the cursor over a corner of the square.
      A red dot should appear.
      When the cursor leaves the dot,
      the dot disappears
      
      Now click button 1"
      
      pack .m -fill x -expand true
      
      set w [canvas .draw -width 300 -height 300 -bg black]
      pack $w
      
      global nodeDT
      
      $w create line 100 100 100 200 200 200 200 100 100 100 -fill green -tags
      BOX
      
      set x 100
      set y 100
      set nodeDT(1) [$w create oval [expr $x-10] [expr $y-10] [expr $x+10] [expr
      $y+10] -outline "" -fill "" -tags NODE]
      set x 100
      set y 200
      set nodeDT(2) [$w create oval [expr $x-10] [expr $y-10] [expr $x+10] [expr
      $y+10] -outline "" -fill "" -tags NODE]
      set x 200
      set y 100
      set nodeDT(3) [$w create oval [expr $x-10] [expr $y-10] [expr $x+10] [expr
      $y+10] -outline "" -fill "" -tags NODE]
      set x 200
      set y 200
      set nodeDT(4) [$w create oval [expr $x-10] [expr $y-10] [expr $x+10] [expr
      $y+10] -outline "" -fill "" -tags NODE]
      
      $w bind NODE <Any-Enter> {
              set item [$w find withtag current]
              $w itemconfigure current -outline "" -fill red
      }
      
      $w bind NODE <Any-Leave> {
              $w itemconfigure current -outline "" -fill ""
      }
      
      bind $w <Button-3> {exit}
      
      bind $w <Button-1> {
              $w bind NODE <Any-Enter> {
                      set item [$w find withtag current]
                      $w itemconfigure current -outline red -fill ""
              }
              $w bind NODE <Any-Leave> {
                      $w itemconfigure current -outline "" -fill ""
              }
              .m configure -aspect 300 -text "
      Move the cursor over a corner of the square.
      Now the dots should be circles
      But the widget locks up (note: exit button), why?"
      }
      
      



  ObservedBehavior:
      Instructions are inculded in the example. When the bindings change for
      the ovals (tagged with NODE) the program hangs.
      



  DesiredBehavior:
      Small circles should surround corners of the square when
      the cursor passes over them. The corners of the square need
      to be visible for the real application.
      





      I'm not sure this should work, leaving an unfilled item may not have
      meaning.
      But it should not cause the code to hang.
      I have tried this on 8.03, 8.05, and 8.1b1, all beahve the same way.
  -----
  This is not a bug.  It is the way the Canvas handles filled items.  Take a look at the modified code
  sample below.  Notice the "update" command.  If you remove this, the "hanging" will appear, otherwise you will notice the output in the console.  The bindings on Enter and Leave are being fired infinately because the dots are being drawn then removed.
  03/25/1999 11:51 - surles -

  if {$tcl_platform(platform) == "windows"} {
      console show
  }

  set w [canvas .draw -width 300 -height 300 -bg black]
  $w create oval 100 100 200 200 -fill "green" -tags BOX
  pack $w

  $w bind BOX <Any-Leave> [list badLeave $w]
  $w bind BOX <Any-Enter> [list badEnter $w]

  set badCounter 0
  proc badLeave {w} {
      puts "Leave$::badCounter"
      $w itemconfigure current -outline "" -fill ""
  }
  proc badEnter {w} {
      puts "Enter$::badCounter"
      incr ::badCounter

      set item [$w find withtag current]
      $w itemconfigure $item -outline red -fill ""
      update
  }


tkt_uuid: 3469780fffffffffffffffffffffffffffffffff
type: Patch
status: Open
subsystem: 18. [text]
priority: 5 Medium
foundin: None
resolution: None
title: Additional options for text widget tags
comment:
  Proposals for implementation of  Tk Feature Request #1759972

  https://sourceforge.net/tracker/?func=detail&aid=1759972&group_id=12997&atid=362997


tkt_uuid: 1991930fffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 88. Themed Tk
priority: 5 Medium
foundin: obsolete: 8.5.2
resolution: Fixed
title: ttk combobox dropdown behind taskbar
comment:
  On windows XP SP2 using tcl/tk 8.5.2 from ActiveState.

  Part of the dropdown from a ttk combobox can be hidden behind the taskbar.

  The combobox is using the screen edge to determine whether to the display the dropdown above or below the entry box. It should either allow for the reduced dimensions due to the taskbar, or it should display in front of the taskbar even when taskbar is marked "on top".

  The following code will produce two combo boxes at the bottom edge of their window. When the window is maximised or moved near bottom of screen, the short list for the first combo box appears behind the taskbar whilst the longer list for the second combo box is correctly shown above it's entry box.


  package require Tk 8.5
  ttk::combobox .combo1 -state readonly -values {a}
  ttk::combobox .combo2 -state readonly -values {a b c d e f}
  grid .combo1 -column 0 -row 0 -sticky s
  grid .combo2 -column 1 -row 0 -sticky s
  grid columnconfigure . 0 -weight 1
  grid columnconfigure . 1 -weight 1
  grid rowconfigure . 0 -weight 1


  Checked what happens in a couple of other applications (Firefox and Internet Explorer), in both cases the dropdown from the address box appears in front of the taskbar. Suggest tk does the same.


tkt_uuid: 220108ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 65. Generic Window Operations
priority: 1 Zero
foundin: obsolete: 8.0p2
resolution: Invalid
title: bug in wm callbacks?
comment:
  OriginalBugID: 643 Bug
  Version: 8.0p2
  SubmitDate: '1998-05-25'
  LastModified: '1999-08-15'
  Severity: LOW
  Status: Closed
  Submitter: hershey
  ChangedBy: hobbs
  OS: All Windows
  OSVersion: NA
  Machine: NA
  FixedInVersion: NA
  ClosedDate: '1999-08-15'


  I noticed the following behavior in tcl8.0p2.
  When binding to Destroy  or using
  wm protocol WM_DELETE_WINDOW,
  in the callback, [winfo viewable $window] == 1,
  even though [winfo exists $win] == 0. This would
  be meaningful if one were saving the geometry of
  the window and wanted to test for its presence before
  saving.

  A workaround is to
  catch "wm geometry $win" var, but I didn't think it logical
  that the window could not exist, yet still be viewable.

  From: Robert Karen <robert@namsi.com>

  This is the desired behavior.  There was previously a bug where
  the winfo exists would actually return 1, which could really
  cause confusion and problems.  What is occuring is that the window
  is in the middle of being destroyed.  Since total destruction is
  imminent, exists is made to return 0.  However, the window is
  still (for the moment) physically viewable.

  If you throw some after calls in there, you will see that the
  window is still viewable, but interacting with it is not fully
  enabled because it is in the destruction process. 
  -- 08/15/1999 hobbs


tkt_uuid: 526180ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 09. [listbox]
priority: 5 Medium
foundin: None
resolution: Invalid
title: Bad scroll on ListBox with MouseWheel
comment:
  Hello, 

  A user of my program send me a bug with his Microsoft 
  mouse with Wheel.

  When a sample list is displayed, with no binding at 
  all, the list scroll normaly when he turn the Wheel. 
  But when he click on it (not turn but click) and drag 
  up or down his mouse, the list scroll in the bad 
  direction 

  I suppose that it's a problem in the default binding 
  of the listbox. I don't have this kind of mouse so I 
  can't test, but do you know something about this 
  problem ?... 

  Thanks, Etienne 


tkt_uuid: 606658ffffffffffffffffffffffffffffffffff
type: Patch
status: Closed
subsystem: 66. Aqua Window Operations
priority: 5 Medium
foundin: None
resolution: Fixed
title: various MacOSX fixes.
comment:
  The attached patch provides fixes for the following 
  problems:

  tk.tcl:
  (1) ctrl-z/x/c/v are used for cut/copy/etc.  This 
  should be 'command' on aqua.
  (2) dialogs can appear under the menubar.

  tkMacOSXKeyEvent.c:
  (1) Keypress/release events for pure modifier keys 
  were not being passed to Tk.
  (2) Deadkey presses were inserting null characters 
  into text windows.  Now they do nothing.  (Still not 
  ideal, but better than before!)

  tkMacOSXMenu.c:
  (1) Allow more than 200 menus to exist.  (Increased 
  to 2000).

  tkMacOSXMouseEvent.c:
  (1) Bad interactions between floating windows and 
  ordinary ones.  Ensure that local<->global 
  coordinate transformations are wrt to the correct 
  window.

  tkMacOSXWm.c:
  (1) Better error msg for 'wm attributes'
  (2) Remove crash in 'wm transient'
  (3) Add 'noActivates' and 'noUpdates' flags to 
  unsupported command.


tkt_uuid: 2658821fffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 37. [tk_get*File]
priority: 5 Medium
foundin: obsolete: 8.5.6
resolution: Out of Date
title: tk_getOpenFile uses uninitialized memory
comment:
  On the Windows build (Windows Server 2003, VS 2005), a call to tk_getOpenFile causes an uninitialized variable to be read. In the debug build, this causes a Run-Time Check Failure dialog for each file type pattern. My call to tk_getOpenFile looks like this:

  tk_getOpenFile -parent . -title "Select DAT File" -filetypes { { {DAT Files} {.dat} } { {All Files} {*} } }

  The runtime error occurs in AddClause() in tkfilefilter.c on this line:

  if (ostypeCount > 0 && ostypeList != NULL) {

  I traced through the execution of AddClause() and ostypeCount does not get set anywhere using the Tk code above. I believe simply initializing ostypeCount in the declaration will solve the problem and ensure correct behavior. Changing:

  int globCount, ostypeCount, i, code = TCL_OK;

  to:

  int globCount, ostypeCount = 0, i, code = TCL_OK;

  should solve the problem.

  This is likely an issue on other platforms as well - just not noticed.


tkt_uuid: 3110361fffffffffffffffffffffffffffffffff
type: Patch
status: Open
subsystem: 12. Unix Menus
priority: 5 Medium
foundin: None
resolution: None
title: More visible indicator for radiobutton menu entries on X11
comment:
  The default indicator for radiobutton menu entries on X11 is too small and hard to see on modern displays. Attached  patch makes them a bit more visible


tkt_uuid: 553208ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 85. Win Build
priority: 5 Medium
foundin: obsolete: 8.4a5
resolution: Fixed
title: TCLDIR needs backslashes
comment:
  If I do 'nmake winhelp' with 'TCLDIR=../../tcl8.4' 
  then a 'copy' syntax error is reported.  One has to 
  use backslashes (TCLDIR=..\..\tcl8.4).  No other make 
  operations seem to require backslashes, so it seems 
  this restriction ought to be removed.


tkt_uuid: 220053ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 39. Image Basics
priority: 1 Zero
foundin: obsolete: 8.3b1
resolution: Duplicate
title: Backwards compatibility problem in images
comment:
  OriginalBugID: 3967 Bug
  Version: 8.3b1
  SubmitDate: '2000-01-03'
  LastModified: '2000-02-08'
  Severity: MED
  Status: Closed
  Submitter: techsupp
  ChangedBy: hobbs
  RelatedBugIDs: 4060
  OS: All
  ClosedDate: '2000-02-08'


  Name:

  Jan Nijtmans


  Comments:

  It is true that the new Image interface is not 100% binary comparible with the old Image interface in all possible

  situations. But with help of the above Tk_InitImageArgs() function, the remaining gap can be closed, resulting

  in Stub-enabled old-style loadable image extensions which runs with Tk8.1 and higher.

  When not using Stubs, only the flag -DUSE_OLD_IMAGE needs to be used to make it source compatible. When

  using Stubs, an additional function call is needed. That's all.


  ReproducibleScript:

  Comple tkTest.c as loadable extension using Stubs, using the Tk8.2 header files, then load it dynamically

  into Tk8.3: The test image then doesn't work.


  ObservedBehavior:

  The problem only occurs when using Stubs, and also only when using the old Image interface. In all

  other situations the patch below has no effect.

  This patch introduces a new function Tk_InitImageArgs(), which checks at runtime if Tk

  provides the old or the new Image interface. If Tk turns out to be version 8.2 or older,

  then Tk_InitImageArgs() just behaves as a NOP. Otherwise, the arguments are

  converted from objects to strings automatically. The Tk_InitImageArgs() function

  is placed in the stub table, thereby making sure that the extension can use

  it even when running under an older Tk version.

  Porting an old-style image type to Tk 8.3 becomes very simple, while still

  assuring that it works in all situations:

  - Compile it with the -DUSE_OLD_IMAGE flag

  - Add a call to the function Tk_InitImageArgs() in the beginning of the CreateImage

    function (this call is a NOP in most cases, only not in the problematic situation

    described above).

  In tkTest.c, the test image is modified to server as an example how to do this.


  Patch:

  *** generic/tk.h.origWed Dec 29 22:34:30 1999

  --- generic/tk.hSun Jan  2 22:27:01 2000

  ***************

  *** 1273,1279 ****

    EXTERN voidTk_CreateOldPhotoImageFormat _ANSI_ARGS_((

    Tk_PhotoImageFormat *formatPtr));


  ! #ifdef USE_OLD_IMAGE

    #define Tk_CreateImageType Tk_CreateOldImageType

    #define Tk_CreatePhotoImageFormat Tk_CreateOldPhotoImageFormat

    #endif

  --- 1273,1279 ----

    EXTERN voidTk_CreateOldPhotoImageFormat _ANSI_ARGS_((

    Tk_PhotoImageFormat *formatPtr));


  ! #if !defined(USE_TK_STUBS) && defined(USE_OLD_IMAGE)

    #define Tk_CreateImageType Tk_CreateOldImageType

    #define Tk_CreatePhotoImageFormat Tk_CreateOldPhotoImageFormat

    #endif

  ***************

  *** 1334,1339 ****

  --- 1334,1347 ----


    #define Tk_InitStubs(interp, version, exact) \

        Tcl_PkgRequire(interp, "Tk", version, exact)

  + 

  + #endif

  + 

  + void Tk_InitImageArgs _ANSI_ARGS_((Tcl_Interp *interp, int argc, char ***argv));

  + 

  + #if !defined(USE_TK_STUBS) || !defined(USE_OLD_IMAGE)

  + 

  + #define Tk_InitImageArgs(interp, argc, argv) /**/


    #endif


  *** generic/tkStubImg.c.origSun Jan  2 22:31:19 2000

  --- generic/tkStubImg.cSun Jan  2 22:17:41 2000

  ***************

  *** 0 ****

  --- 1,70 ----

  + /* 

  +  * tkStubImg.c --

  +  *

  +  *Stub object that will be statically linked into extensions that wish

  +  *to access Tk.

  +  *

  +  * Copyright (c) 1999 Jan Nijtmans.

  +  * Copyright (c) 1998-1999 by Scriptics Corporation.

  +  *

  +  * See the file "license.terms" for information on usage and redistribution

  +  * of this file, and for a DISCLAIMER OF ALL WARRANTIES.

  +  *

  +  * RCS: @(#) $Id: tkStubImg.c,v 1.0 2000/01/03 01:31:06 nijtmans Exp $

  +  */

  + 

  + #include "tcl.h"

  + 

  + 

  + /*

  +  *----------------------------------------------------------------------

  +  *

  +  * Tk_InitImageArgs --

  +  *

  +  *Checks that the correct version of Tk is loaded and that it

  +  *supports stubs. It then initialises the stub table pointers.

  +  *

  +  * Results:

  +  *The actual version of Tk that satisfies the request, or

  +  *NULL to indicate that an error occurred.

  +  *

  +  * Side effects:

  +  *Sets the stub table pointers.

  +  *

  +  *----------------------------------------------------------------------

  +  */

  + 

  + #ifdef Tk_InitImageArgs

  + #undef Tk_InitImageArgs

  + #endif

  + 

  + void

  + Tk_InitImageArgs(interp, argc, argvPtr)

  +     Tcl_Interp *interp;

  +     int argc;

  +     char ***argvPtr;

  + {

  +     static useNewImage = -1;

  +     static char **argv = NULL;

  + 

  +     if (useNewImage < 0) {

  + Tcl_CmdInfo cmdInfo;

  + if (!tclStubsPtr->tcl_GetCommandInfo(interp,"image", &cmdInfo)) {

  +     tclStubsPtr->tcl_Panic("cannot find the \"image\" command");

  + }

  + if (cmdInfo.isNativeObjectProc == 1) {

  +     useNewImage = 1; /* Tk uses the new image interface */

  + }

  +     }

  +     if (useNewImage) {

  + int i;

  + if (argv) {

  +     tclStubsPtr->tcl_Free((char *) argv);

  + }

  + argv = (char **) tclStubsPtr->tcl_Alloc(argc * sizeof(char *));

  + for (i = 0; i < argc; i++) {

  +     argv[i] = tclStubsPtr->tcl_GetString((Tcl_Obj *)(*argvPtr)[i]);

  + }

  + *argvPtr = (char **) argv;

  +     }

  + }

  *** tkTest.c.origSun Jan  2 22:33:29 2000

  --- tkTest.cSun Jan  2 22:41:14 2000

  ***************

  *** 16,21 ****

  --- 16,25 ----

     * RCS: @(#) $Id: tkTest.c,v 1.9 1999/12/14 06:52:31 hobbs Exp $

     */


  + #ifdef MAC_TCL

  + #define USE_OLD_IMAGE

  + #endif

  + 

    #include "tkInt.h"

    #include "tkPort.h"

    #include "tkText.h"

  ***************

  *** 61,70 ****

  --- 65,81 ----

     * The type record for test images:

     */


  + #ifdef USE_OLD_IMAGE

  + static intImageCreate _ANSI_ARGS_((Tcl_Interp *interp,

  +     char *name, int argc, char **argv,

  +     Tk_ImageType *typePtr, Tk_ImageMaster master,

  +     ClientData *clientDataPtr));

  + #else

    static intImageCreate _ANSI_ARGS_((Tcl_Interp *interp,

        char *name, int argc, Tcl_Obj *CONST objv[],

        Tk_ImageType *typePtr, Tk_ImageMaster master,

        ClientData *clientDataPtr));

  + #endif

    static ClientDataImageGet _ANSI_ARGS_((Tk_Window tkwin,

        ClientData clientData));

    static voidImageDisplay _ANSI_ARGS_((ClientData clientData,

  ***************

  *** 78,84 ****


    static Tk_ImageType imageType = {

        "test",/* name */

  !     ImageCreate,/* createProc */

        ImageGet,/* getProc */

        ImageDisplay,/* displayProc */

        ImageFree,/* freeProc */

  --- 89,95 ----


    static Tk_ImageType imageType = {

        "test",/* name */

  !     (Tk_ImageCreateProc *) ImageCreate, /* createProc */

        ImageGet,/* getProc */

        ImageDisplay,/* displayProc */

        ImageFree,/* freeProc */

  ***************

  *** 1557,1562 ****

  --- 1568,1608 ----

     */


    /* ARGSUSED */

  + #ifdef USE_OLD_IMAGE

  + static int

  + ImageCreate(interp, name, argc, argv, typePtr, master, clientDataPtr)

  +     Tcl_Interp *interp;/* Interpreter for application containing

  +  * image. */

  +     char *name;/* Name to use for image. */

  +     int argc;/* Number of arguments. */

  +     char **argv;/* Argument strings for options (doesn't

  +  * include image name or type). */

  +     Tk_ImageType *typePtr;/* Pointer to our type record (not used). */

  +     Tk_ImageMaster master;/* Token for image, to be used by us in

  +  * later callbacks. */

  +     ClientData *clientDataPtr;/* Store manager's token for image here;

  +  * it will be returned in later callbacks. */

  + {

  +     TImageMaster *timPtr;

  +     char *varName;

  +     int i;

  + 

  +     Tk_InitImageArgs(interp, argc, &argv);

  +     varName = "log";

  +     for (i = 0; i < argc; i += 2) {

  + if (strcmp(argv[i], "-variable") != 0) {

  +     Tcl_AppendResult(interp, "bad option name \"",

  +     argv[i], "\"", (char *) NULL);

  +     return TCL_ERROR;

  + }

  + if ((i+1) == argc) {

  +     Tcl_AppendResult(interp, "no value given for \"",

  +     argv[i], "\" option", (char *) NULL);

  +     return TCL_ERROR;

  + }

  + varName = argv[i+1];

  +     }

  + #else

    static int

    ImageCreate(interp, name, objc, objv, typePtr, master, clientDataPtr)

        Tcl_Interp *interp;/* Interpreter for application containing

  ***************

  *** 1589,1594 ****

  --- 1635,1641 ----

    }

    varName = Tcl_GetString(objv[i+1]);

        }

  + #endif

        timPtr = (TImageMaster *) ckalloc(sizeof(TImageMaster));

        timPtr->master = master;

        timPtr->interp = interp;

  *** unix/Makefile.in.origSun Jan  2 21:42:16 2000

  --- unix/Makefile.inSun Jan  2 22:28:43 2000

  ***************

  *** 270,276 ****

    tkUnixMenubu.o tkUnixScale.o tkUnixScrlbr.o tkUnixSelect.o \

    tkUnixSend.o tkUnixWm.o tkUnixXId.o tkStubInit.o tkStubLib.o


  ! STUB_LIB_OBJS = tkStubLib.o


    OBJS =  tk3d.o tkArgv.o tkAtom.o tkBind.o tkBitmap.o tkClipboard.o tkCmds.o \

    tkColor.o tkConfig.o tkConsole.o tkCursor.o tkError.o tkEvent.o \

  --- 270,276 ----

    tkUnixMenubu.o tkUnixScale.o tkUnixScrlbr.o tkUnixSelect.o \

    tkUnixSend.o tkUnixWm.o tkUnixXId.o tkStubInit.o tkStubLib.o


  ! STUB_LIB_OBJS = tkStubLib.o tkStubImg.o


    OBJS =  tk3d.o tkArgv.o tkAtom.o tkBind.o tkBitmap.o tkClipboard.o tkCmds.o \

    tkColor.o tkConfig.o tkConsole.o tkCursor.o tkError.o tkEvent.o \

  ***************

  *** 799,804 ****

  --- 799,807 ----


    tkStubLib.o: $(GENERIC_DIR)/tkStubLib.c

    $(CC) -c $(CC_SWITCHES) $(GENERIC_DIR)/tkStubLib.c

  + 

  + tkStubImg.o: $(GENERIC_DIR)/tkStubImg.c

  + $(CC) -c $(CC_SWITCHES) $(GENERIC_DIR)/tkStubImg.c


    tkUnix.o: $(UNIX_DIR)/tkUnix.c

    $(CC) -c $(CC_SWITCHES) $(UNIX_DIR)/tkUnix.c

  *** win/Makefile.in.origSun Jan  2 21:43:36 2000

  --- win/Makefile.inSun Jan  2 21:44:28 2000

  ***************

  *** 331,337 ****

    tkWindow.$(OBJEXT)


    STUB_OBJS = \

  ! tkStubLib.$(OBJEXT)


    TCL_DOCS = "$(TCL_SRC_DIR_NATIVE)"/../doc/*.[13n]

    TK_DOCS = "$(ROOT_DIR_NATIVE)"/doc/*.[13n]

  --- 331,338 ----

    tkWindow.$(OBJEXT)


    STUB_OBJS = \

  ! tkStubLib.$(OBJEXT) \

  ! tkStubImg.$(OBJEXT)


    TCL_DOCS = "$(TCL_SRC_DIR_NATIVE)"/../doc/*.[13n]

    TK_DOCS = "$(ROOT_DIR_NATIVE)"/doc/*.[13n]

  *** win/makefile.vc.origSun Jan  2 21:43:46 2000

  --- win/makefile.vcSun Jan  2 21:45:42 2000

  ***************

  *** 216,221 ****

  --- 216,222 ----

    $(TMPDIR)\tkWindow.obj


    TKSTUBOBJS = $(TMPDIR)\tkStubLib.obj \

  + $(TMPDIR)\tkStubImg.obj


    cc32= "$(TOOLS32)\bin\cl.exe"


  PatchFiles:

  tk.h tkStubImg.c (new file) tkTest.c Makefile.in (for UNIX and WIN)

      makefile.vc




  This is handled by the patch in 4060 which was applied for 8.3.0. 
  -- 02/08/2000 hobbs


tkt_uuid: 489328ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 18. [text]
priority: 5 Medium
foundin: obsolete: 8.3.4
resolution: Fixed
title: cursor steps into elided text
comment:
  When using the "-elide" option in the Tk text widget
  (Tcl/Tk 8.3.4) we noticed that the cursor movements
  don't skip the "hidden" parts.

  Enter the following code in a wish console.

  ##### Start of example #####

  text .t
  pack .t
  .t insert end "1111111111\n"
  .t insert end "2222222222\n" hide_me
  .t insert end "3333333333\n"
  .t tag configure hide_me -elide 1
  .t mark set insert 1.5

  ##### End of example #####

  The cursor should now be at char 5 on the first line.

  Now press the "down" arrow key.
  The cursor disappears, it is in the "elided" (=hidden
  part).
  Press "down" ones more, and the cursor is back (on the
  line containing the 3's).

  Second test. Press "up" key.
  The cursor disappears.
  Now enter ".t tag configure hide_me -elide 0" in the
  wish console.
  The second line (containg 2's) should become visible
  and the insert cursor is on this line.

  These simple tests show that the elide-patch is incomplete.

  If you attach scrolbars to a text widget that contains
  elided text, you will also notice "strange" scrolbars
  changes.


tkt_uuid: 220323ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 10. Generic Menus
priority: 1 Zero
foundin: obsolete: 8.3
resolution: Invalid
title: menu entrycget and entrycofigure failw above separator
comment:
  OriginalBugID: 6139 Bug
  Version: 8.3
  SubmitDate: '2000-08-16'
  LastModified: '2000-08-16'
  Severity: SER
  Status: Closed
  Submitter: techsupp
  ChangedBy: ericm
  OS: Windows 98
  OSVersion: work; NT 4.00.1381  home:?
  Machine: work: Fujitsu  home: Siemens Gujitsu
  ClosedDate: '2000-08-16'


  Name:
  Agnar Renolen

  CVS:
  May/June 2000.

  ReproducibleScript:
  wm withdraw .
  console show

  toplevel .w -menu .w.mb
  menu .w.mb
  .w.mb add cascade -label MyMeny -menu .w.mb.m1
  menu .w.mb.m1 -tearoff 0
  .w.mb.m1 add command -label "Hello" -command {puts [.w.mb.m1 entrycget  0 -label]}
  .w.mb.m1 add command -label "World" -command {puts [.w.mb.m1 entrycget  1 -label]}
  .w.mb.m1 add separator
  .w.mb.m1 add command -label "My" -command {puts [.w.mb.m1 entrycget  3 -label]}
  .w.mb.m1 add command -label "Name" -command {puts [.w.mb.m1 entrycget  4 -label]}
  .w.mb.m1 add command -label "is" -command {puts [.w.mb.m1 entrycget  5 -label]}
  .w.mb.m1 add command -label "Agnar" -command {puts [.w.mb.m1 entrycget  7 -label]}
  .w.mb.m1 add separator
  .w.mb.m1 add command -label "Exit" -command {exit}

  ObservedBehavior:
  When selecting the "Agnar" menu item, i get:
   Error: Unknown option "-label"

  Stack trace:

  unknown option "-label"
      while executing
  ".w.mb.m1 entrycget  7 -label"
      (menu invoke)

  An application I'm developing at home, generated an error for all menu items above separator lines.  I have Window 98 at home.

  I have Windows NT at work, and here I only got an error for the "Agnar" item. The "World" item works correctly(??)

  This makes it pretty hard to disable the "Agnar" menu item, as the entryconfigure command produced the exact same result.



  This is likely because in the command for the "Agnar" entry, you have
  indicated entry number 7, which corresponds to the separator entry,
  instead of entry number 6, which corresponds to the "Agnar" entry.  When I
  modified the command for the "Agnar" entry like this:

  .w.mb.m1 entryconfigure 6 -command {puts [.w.mb.m1 entryconfigure 6 -label]}

  It works as expected.

     Eric Melski                            The Other Tcl Guy
     ericm at ajubasolutions.com            Ajuba Solutions

   
  -- 08/16/2000 ericm


tkt_uuid: 220468ffffffffffffffffffffffffffffffffff
type: RFE
status: Closed
subsystem: -- New Stub Entries
priority: 2
foundin: None
resolution: Fixed
title: Need platform-dependent include file
comment:
  OriginalBugID: 1621 RFE
  Version: 8.0.5
  SubmitDate: '1999-03-24'
  LastModified: '1999-11-16'
  Severity: LOW
  Status: Released
  Submitter: pat
  ChangedBy: hobbs
  OS: All
  FixedDate: '1999-11-16'
  FixedInVersion: 8.2


  Comments from Lothar Linhard:



  I want to ask for one thing we need with TclPro:

  >

  > * A possibility to get MS-Window's window handle (HWND)

  >   from a TK Drawable (on C-level).

  >

  >The purpose for that is, that for performance reasons,

  >our C-level TK extension draws directly to the native

  >HDC rather than thru TK's xlib emulation.

  >

  >With tcl/tk 8.0p2 we include tkWinInt.h and use the

  >Macros TkWinGetHWND(w) and TkWinGetHDC(w) but they

  >are not available with TclPro, because the include file

  >tkWinInt.h is missing.

  >Here is a piece of code, that we use with tcl/tk 8.0p2:

  >

  > #ifdef WIN32

  > #define _TKPORT         /* don't need to include tkPort.h */

  > #include <tkWinInt.h>

  > #endif

  > ...

  >        // Get the new device context

  >        //

  > Drawable d = ...;

  >        TkWinDrawable* twdPtr = (TkWinDrawable*)d;

  >        if (twdPtr->type == TWD_WINDOW) {

  >            impl_.dc = GetDC( TkWinGetHWND(twdPtr) );

  >            impl_.bitmap = 0;

  >        } else if (twdPtr->type == TWD_WINDC) {

  >            impl_.dc = TkWinGetHDC(twdPtr);

  >            impl_.bitmap = 0;

  >        } else {

  >     ....

  >

  >We understand, that using tkWinInt.h's in that way makes our

  >C-level TK extension sensitive to changes in your TK structs.

  >Therefore, for a long term, we would appreciate, if Scriptics

  >could provide Tk_WinGetHWND(w) and Tk_WinGetHDC(w) as an

  >interface functions (rather than' macros).  

  >

  Tk_GetHWND, et al are now public functions, and are also in
  the stubs tables for 8.2+. 
  -- 11/16/1999 hobbs


tkt_uuid: 220290ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 39. Image Basics
priority: 1 Zero
foundin: obsolete: 8.3
resolution: Invalid
title: info exists does not see image create photo
comment:
  OriginalBugID: 4498 Bug
  Version: 8.3
  SubmitDate: '2000-03-23'
  LastModified: '2000-03-23'
  Severity: MED
  Status: Closed
  Submitter: techsupp
  ChangedBy: hobbs
  OS: BSD
  OSVersion: BSDi BSD/OS 4.1
  Machine: PC Pentium-class
  ClosedDate: '2000-03-23'


  Name: Richard Ross-Langley

  Comments:
  Same bug was found on Tcl/Tk 8.0
      Workaround is to 'set flag 1' when 'catch' succeeds, and test [info
      exists flag]
      Maybe an image as created by Tk is not a normal variable?

  ReproducibleScript:
  BSDi % wish test2.tcl

  # where test2.tcl is

  puts "Tcl patchlevel [info patchlevel]"
  set picname "f1bar.gif"
  if {[catch [list  image create photo pic -format "gif" -file "$picname"  ] ] == 0} {
    puts "image create to variable pic (from $picname) succeeded! "
  } else {
    puts "*** image create FAILED "
  }
  if {[info exists pic]} {
    puts "Photo variable pic from $picname exists! "
  } else {
    puts "*** Photo variable pic (from $picname) does NOT exist "
  }
  exit

  ObservedBehavior:
  Image was created but [info exists] says it is not a variable.

  Output from the test program -

  Tcl patchlevel 8.3.0
  image create to variable pic (from f1bar.gif) succeeded! 
  *** Photo variable pic (from f1bar.gif) does NOT exist

  DesiredBehavior:
  Tcl patchlevel 8.3.0
  image create to variable pic (from f1bar.gif) succeeded! 
  Photo variable pic from f1bar.gif exists!



  Pilot error: image create creates a command, not a var. 
  -- 03/23/2000 hobbs


tkt_uuid: 1229263fffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 38. [tk_messageBox]
priority: 9 Immediate
foundin: obsolete: 8.4.9
resolution: Out of Date
title: Crash ap when closing message box
comment:
  On Windows XP SP 2 the following small program crashes:

  wm title . "Crash"
  set font {Helvetica 14}
  frame .reaper
  pack .reaper -expand 1 -fill both -side left
  tk_messageBox -icon info -message "Reaping complete."
  -type ok -parent .reaper

  If the value for the -parent is changed to "." instead
  of ".reaper"
  the small program does not crash.

  Apparently, since .reaper is not on the screen yet,
  using it as a parent causes a major error.

  This is 100 percent reproducible on my system, a
  1600 MHz Pentium M with 512 MB of memory.


tkt_uuid: 220071ffffffffffffffffffffffffffffffffff
type: Bug
status: Deleted
subsystem: 06. Canvas Postscript
priority: 1 Zero
foundin: obsolete: 8.3
resolution: Duplicate
title: patch to enable Poscript creation for photo images
comment:
  OriginalBugID: 4268 RFE
  Version: 8.3
  SubmitDate: '2000-02-29'
  LastModified: '2000-04-14'
  Severity: CRIT
  Status: Closed
  Submitter: techsupp
  ChangedBy: hobbs
  RelatedBugIDs: 5030
  OS: Windows 98
  Machine: Pentium // 300Mhz 32 MB RAM 24 bit color screen
  ClosedDate: '2000-04-14'


  Name:

  Alberto Biancardi



  Comments:

  The Postscript created handles transparency (due to a bug in some

      hp printers a pixel is transparent when alpha is equal to zero or one)

      The Postscript created is Level 2 only, but I think that handling

      transparencies is a big bonus.

      

      On the C code side.

      There is a kind of deadlock owing to TkPostscriptInfo and Image

      structures being opaque outside their respective files; I did not

      change anything, but I had to make the decision of passsing

      the masterData pointer to the postscriptProc and then bounce

      back to the tkImgPhoto.c after getting the colorLevel info ...

      

      I tried my best to test the code, but, even if I need to run wish

      on Windows, I can only compile on linux.

      Anyway I think my patch works on other platforms as well ...



  ReproducibleScript:

  cd $tk_library/images

  pack [canvas .c -width 600 -height 800]

  .c create image 300 400 -image \

  [image create photo -file pwrdLogo75.gif]

  .c postscript -file test.ps



  ObservedBehavior:

  Wish crashes because XGetImage is not implemented.



  DesiredBehavior:

  In my opinion using XGetImage is not necessary, it is not

  portable and links the color level of the output to the visual

  of the canvas (which is something unusual).



  By looking at the sources I think that most of the neccessary changes

  are already in place: any image type should provide its own

  image-to-postscript function.

  Moreover it would benefit from working directly on the master data

  avoiding any dithering or, at any rate, letting the postscript

  device do whatever it thinks optimal.





  Now, what I do not understand is why the function Tk_PostscriptImage

  does not check whether a Tk_ImagePostscriptProc is defined or not

  for the current image.

  Secondly, I would define a TkPostscriptPhoto which specialises

  postscript generation for photo images.



  Patch:

  *** tkCanvPs.c.origTue Dec 14 07:52:26 1999

  --- tkCanvPs.cMon Feb 28 11:26:33 2000

  ***************

  *** 1681,1683 ****

  --- 1681,1856 ----

        ckfree((char *) cdata.colors);

        return TCL_OK;

    }

  + 

  + 

  + 

  + 

  + /*

  +  *--------------------------------------------------------------

  +  *

  +  * TkPostscriptPhoto --

  +  *

  +  *This procedure is called to output the contents of a

  +  *photo image in Postscript by calling the AppendPhotoPsData

  +  *      function.

  +  *

  +  * Results:

  +  *Returns a standard Tcl return value.

  +  *

  +  * Side effects:

  +  *None.

  +  *

  +  *--------------------------------------------------------------

  +  */

  + 

  + int

  + TkPostscriptPhoto(clientData, interp, tkwin, psInfo,

  +         x, y, width, height, prepass)

  +     ClientData clientData;      /* photo image pointer*/

  +     Tcl_Interp *interp;

  +     Tk_Window tkwin;

  +     Tk_PostscriptInfo psInfo;/* postscript info */

  +     int x, y;/* First pixel to output */

  +     int width, height;/* Width and height of area */

  +     int prepass;

  + {

  +     

  +     TkPostscriptInfo *psInfoPtr = (TkPostscriptInfo *) psInfo;

  +     static int codeIncluded = 0;

  +     int level = psInfoPtr->colorLevel;

  + 

  + 

  +     if (psInfoPtr->prepass) {

  + codeIncluded = 0;

  + return TCL_OK;

  +     }

  + 

  + 

  +     /*

  +      * Define the "colTrImage" function, which is a modified version

  +      * of the original "transparentimage" function posted

  +      * by ian@five-d.com (Ian Kemmish) to comp.lang.postscript.

  +      */

  + 

  +     if( !codeIncluded && level!=0) {

  + codeIncluded = !0;

  + Tcl_AppendResult( interp,

  + "/TkPhoto { \n",

  + "  gsave \n",

  + "  32 dict begin \n",

  + "  /tinteger exch def \n",

  + "  /transparent 1 string def \n",

  + "  transparent 0 tinteger put \n",

  + "  /olddict exch def \n",

  + "  olddict /DataSource get dup type /filetype ne { \n",

  + "    olddict /DataSource 3 -1 roll \n",

  + "    0 () /SubFileDecode filter put \n",

  + "  } { \n",

  + "    pop \n",

  + "  } ifelse \n",

  + "  /newdict olddict maxlength dict def \n",

  + "  olddict newdict copy pop \n",

  + "  /w newdict /Width get def \n",

  + "  /crpp newdict /Decode get length 2 idiv def \n",

  + "  /str w string def \n",

  + "  /pix w crpp mul string def \n",

  + "  /substrlen 2 w log 2 log div floor exp cvi def \n",

  + "  /substrs [ \n",

  + "  { \n",

  + "     substrlen string \n",

  + "     0 1 substrlen 1 sub { \n",

  + "       1 index exch tinteger put \n",

  + "     } for \n",

  + "     /substrlen substrlen 2 idiv def \n",

  + "     substrlen 0 eq {exit} if \n",

  + "  } loop \n",

  + "  ] def \n",

  + "  /h newdict /Height get def \n",

  + "  1 w div 1 h div matrix scale \n",

  + "  olddict /ImageMatrix get exch matrix concatmatrix \n",

  + "  matrix invertmatrix concat \n",

  + "  newdict /Height 1 put \n",

  + "  newdict /DataSource pix put \n",

  + "  /mat [w 0 0 h 0 0] def \n",

  + "  newdict /ImageMatrix mat put \n",

  + "  0 1 h 1 sub { \n",

  + "    mat 5 3 -1 roll neg put \n",

  + "    olddict /DataSource get str readstring pop pop \n",

  + "    /tail str def \n",

  + "    /x 0 def \n",

  + "    olddict /DataSource get pix readstring pop pop \n",

  + "    { \n",

  + "      tail transparent search dup /done exch not def \n",

  + "      {exch pop exch pop} if \n",

  + "      /w1 exch length def \n",

  + "      w1 0 ne { \n",

  + "        newdict /DataSource ",

  +           " pix x crpp mul w1 crpp mul getinterval put \n",

  + "        newdict /Width w1 put \n",

  + "        mat 4 x neg put \n",

  + "        /x x w1 add def \n",

  + "        newdict image \n",

  + "        /tail tail w1 tail length w1 sub getinterval def \n",

  + "      } if \n",

  + "      done {exit} if \n",

  + "      tail substrs { \n",

  + "        anchorsearch {pop} if \n",

  + "      } forall \n",

  + "      /tail exch def \n",

  + "      tail length 0 eq {exit} if \n",

  + "      /x w tail length sub def \n",

  + "    } loop \n",

  + "  } for \n",

  + "  end \n",

  + "  grestore \n",

  + "} bind def \n\n\n", (char *) NULL);

  +     } else if( !codeIncluded ) {

  + /*

  +  * Append monochrome-only code

  +  */

  + codeIncluded = !0;

  + Tcl_AppendResult( interp,

  + "/TkPhoto { \n",

  + "  gsave \n",

  + "  32 dict begin \n",

  + "  /dummyInteger exch def \n",

  + "  /olddict exch def \n",

  + "  olddict /DataSource get dup type /filetype ne { \n",

  + "    olddict /DataSource 3 -1 roll \n",

  + "    0 () /SubFileDecode filter put \n",

  + "  } { \n",

  + "    pop \n",

  + "  } ifelse \n",

  + "  /newdict olddict maxlength dict def \n",

  + "  olddict newdict copy pop \n",

  + "  /w newdict /Width get def \n",

  + "  /pix w 7 add 8 idiv string def \n",

  + "  /h newdict /Height get def \n",

  + "  1 w div 1 h div matrix scale \n",

  + "  olddict /ImageMatrix get exch matrix concatmatrix \n",

  + "  matrix invertmatrix concat \n",

  + "  newdict /Height 1 put \n",

  + "  newdict /DataSource pix put \n",

  + "  /mat [w 0 0 h 0 0] def \n",

  + "  newdict /ImageMatrix mat put \n",

  + "  0 1 h 1 sub { \n",

  + "    mat 5 3 -1 roll neg put \n",

  + "    0.000 0.000 0.000 setrgbcolor \n",

  + "    olddict /DataSource get pix readstring pop pop \n",

  + "    newdict /DataSource pix put \n",

  + "    newdict imagemask \n",

  + "    1.000 1.000 1.000 setrgbcolor \n",

  + "    olddict /DataSource get pix readstring pop pop \n",

  + "    newdict /DataSource pix put \n",

  + "    newdict imagemask \n",

  + "  } for \n",

  + "  end \n",

  + "  grestore \n",

  + "} bind def \n\n\n", (char *) NULL);

  +     }

  + 

  + 

  + 

  +     return TkAppendPhotoPsData( clientData, interp,

  +     x, y, width, height, level);

  + }

  *** tkImage.c.origTue Dec 14 07:52:28 1999

  --- tkImage.cThu Feb 24 14:54:58 2000

  ***************

  *** 634,644 ****

  --- 634,669 ----

        int width, height;/* Dimensions of region to redraw. */

        int prepass;

    {

  +     Image *imagePtr = (Image *) image;

        int result;

        XImage *ximage;

        Pixmap pmap;

        GC newGC;

        XGCValues gcValues;

  + 

  + 

  +     if (imagePtr->masterPtr->typePtr == NULL) {

  + /*

  +  * No master for image, so nothing to display on postscript.

  +  */

  + 

  + return TCL_OK;

  +     }

  + 

  + 

  +     /*

  +      * Check if an image specific postscript-generation function

  +      * exists; otherwise go on with generic code.

  +      */

  + 

  +     if (imagePtr->masterPtr->typePtr->postscriptProc != NULL) {

  +         return (*imagePtr->masterPtr->typePtr->postscriptProc)(

  +         imagePtr->masterPtr->masterData, interp, tkwin, psinfo,

  + x, y, width, height, prepass);

  +     }

  + 

  + 

  + 

        if (prepass) {

    return TCL_OK;

        }

  *** tkImgPhoto.c.origTue Feb  8 12:31:33 2000

  --- tkImgPhoto.cMon Feb 28 11:31:45 2000

  ***************

  *** 31,37 ****

     * Declaration for internal Xlib function used here:

     */

    

  ! extern _XInitImageFuncPtrs _ANSI_ARGS_((XImage *image));

    

    /*

     * A signed 8-bit integral type.  If chars are unsigned and the compiler

  --- 31,37 ----

     * Declaration for internal Xlib function used here:

     */

    

  ! extern void _XInitImageFuncPtrs _ANSI_ARGS_((XImage *image));

    

    /*

     * A signed 8-bit integral type.  If chars are unsigned and the compiler

  ***************

  *** 301,307 ****

        ImgPhotoDisplay,/* displayProc */

        ImgPhotoFree,/* freeProc */

        ImgPhotoDelete,/* deleteProc */

  !     (Tk_ImagePostscriptProc *) NULL, /* postscriptProc */

        (Tk_ImageType *) NULL/* nextPtr */

    };

    

  --- 301,307 ----

        ImgPhotoDisplay,/* displayProc */

        ImgPhotoFree,/* freeProc */

        ImgPhotoDelete,/* deleteProc */

  !     TkPostscriptPhoto,          /* postscriptProc */

        (Tk_ImageType *) NULL/* nextPtr */

    };

    

  ***************

  *** 5111,5114 ****

  --- 5111,5411 ----

        ptr->nextPtr = list;

        Tcl_SetAssocData(interp, "photoOption", PhotoOptionCleanupProc,

    (ClientData) ptr);

  + }

  + 

  + 

  + 

  + 

  + /*

  +  *--------------------------------------------------------------

  +  *

  +  * TkAppendPostscriptData --

  +  *

  +  *This procedure is called to output the contents of a

  +  *photo image in Postscript, using a format appropriate for 

  +  *      the requested postscript color mode (i.e. one byte per pixel

  +  *      in gray, and three bytes per pixel in color).

  +  *

  +  * Results:

  +  *Returns a standard Tcl return value.  If an error occurs

  +  *then an error message will be left in interp->result.

  +  *If no error occurs, then additional Postscript will be

  +  *appended to interp->result.

  +  *

  +  * Side effects:

  +  *None.

  +  *

  +  *--------------------------------------------------------------

  +  */

  + 

  + 

  + int

  + TkAppendPhotoPsData( clientData, interp, x, y, width, height, colorLevel)

  +     ClientData clientData;      /* photo image pointer*/

  +     Tcl_Interp *interp;

  +     int x, y;/* First pixel to output */

  +     int width, height;/* Width and height of area */

  +     int colorLevel;

  + {

  +     PhotoMaster *masterPtr = (PhotoMaster *)  clientData;

  +     unsigned char *pixelPtr;

  +     char buffer[256], cspace[40], decode[40];

  +     int bpc;

  +     int xx, yy, lineLen;

  +     float red, green, blue;

  +     int alpha;

  +     int bytesPerLine=0, maxWidth=0;

  + 

  + 

  +     /*

  +      * Check that at least one row of the image can be represented

  +      * with a string less than 64 KB long (this is a limit in the 

  +      * Postscript interpreter).

  +      */

  + 

  +     switch (colorLevel)

  +     {

  + case 0: bytesPerLine = (width + 7) / 8;  maxWidth = 240000;  break;

  + case 1: bytesPerLine = 2 * width;  maxWidth = 30000;  break;

  + default: bytesPerLine = 4 * width;  maxWidth = 15000;  break;

  +     }

  + 

  +     if (bytesPerLine > 60000) {

  + Tcl_ResetResult(interp);

  + sprintf(buffer,

  + "Can't generate Postscript for images more than %d pixels wide",

  + maxWidth);

  + Tcl_AppendResult(interp, buffer, (char *) NULL);

  + return TCL_ERROR;

  +     }

  + 

  + 

  + #if 0

  +     if (colorLevel!=0) {

  + sprintf(buffer, "0 %d translate\n", height);

  + Tcl_AppendResult(interp, buffer, (char *) NULL);

  +     }

  + #endif

  + 

  + 

  +     switch (colorLevel) {

  + case 0: 

  +     strcpy( cspace, "/DeviceGray");

  +     strcpy( decode, "[1 0]");

  +     bpc = 1;

  +     break;

  + case 1: 

  +     strcpy( cspace, "/DeviceGray");

  +     strcpy( decode, "[0 1]");

  +     bpc = 8;

  +     break;

  + default:

  +     strcpy( cspace, "/DeviceRGB");

  +     strcpy( decode, "[0 1 0 1 0 1]");

  +     bpc = 8;

  +     break;

  +     }

  + 

  + 

  +     sprintf(buffer,

  +     "\n%%%%0 -%d translate\ngsave\n%d  %d scale\n",

  +     height, width, height);

  + 

  +     Tcl_AppendResult(interp, buffer,

  +     cspace, " setcolorspace\n\n",

  +     (char *) NULL);

  + 

  +     sprintf(buffer,

  +     "  /Width %d\n  /Height %d\n  /BitsPerComponent %d\n",

  +     width, height,  bpc);

  + 

  +     Tcl_AppendResult(interp,

  +     "<<\n  /ImageType 1\n", buffer,

  +     "  /DataSource currentfile /ASCIIHexDecode filter\n",

  +     (char *) NULL);

  + 

  + 

  +     sprintf(buffer,

  +     "  /ImageMatrix [%d 0 0 -%d 0 %d]\n",  width, height, height);

  + 

  + 

  + 

  +     /* per le immagini mono devo generare 2 set di pixel

  +      * uno per i pixel bianchi e 1 x quelli neri ed usare imagemask!

  +      */

  + 

  +     Tcl_AppendResult(interp, buffer,

  +     "  /Decode ", decode,

  +     "\n>>\n1 TkPhoto\n",

  +     (char *) NULL);

  + 

  +     for (yy = y, lineLen=0; yy < y+height; yy++) {

  + switch (colorLevel) {

  +     case 0: {

  + /*

  +  * Generate data for image in monochrome mode.

  +  * No attempt at dithering is made--instead, just

  +  * set a threshold.

  +  * To handle transparecies we need to output two lines:

  +  * one for the black pixels, one for the white ones.

  +  */

  + 

  + unsigned char mask=0x80;

  + unsigned char data=0x00;

  + for (xx = x; xx< x+width; xx++) {

  +     pixelPtr = masterPtr->pix24 + 

  + (yy * masterPtr->width + xx) * 4;

  +     red = *(pixelPtr++);

  +     green = *(pixelPtr++);

  +     blue = *(pixelPtr++);

  +     alpha = *(pixelPtr++);

  + 

  +     /*

  +      * If pixel is than threshold, then it is black.

  +      */

  + 

  +     if ((alpha != 0) && 

  + ( 0.3086 * red + 0.6094 * green + 0.082 * blue < 128))

  + data |= mask;

  +     mask >>= 1;

  +     if (mask == 0) {

  + sprintf(buffer, "%02X", data);

  + Tcl_AppendResult(interp, buffer, (char *) NULL);

  + lineLen += 2;

  + if (lineLen >= 60) {

  +     lineLen = 0;

  +     Tcl_AppendResult(interp, "\n", (char *) NULL);

  + }

  + mask=0x80;

  + data=0x00;

  +     }

  + }

  + if ((width % 8) != 0) {

  +     sprintf(buffer, "%02X", data);

  +     Tcl_AppendResult(interp, buffer, (char *) NULL);

  +     mask=0x80;

  +     data=0x00;

  + }

  + 

  + mask=0x80;

  + data=0x00;

  + for (xx = x; xx< x+width; xx++) {

  +     pixelPtr = masterPtr->pix24 + 

  + (yy * masterPtr->width + xx) * 4;

  +     red = *(pixelPtr++);

  +     green = *(pixelPtr++);

  +     blue = *(pixelPtr++);

  +     alpha = *(pixelPtr++);

  + 

  +     /*

  +      * If pixel is than threshold, then it is black.

  +      */

  + 

  +     if ((alpha != 0) && 

  + ( 0.3086 * red + 0.6094 * green + 0.082 * blue >= 128))

  + data |= mask;

  +     mask >>= 1;

  +     if (mask == 0) {

  + sprintf(buffer, "%02X", data);

  + Tcl_AppendResult(interp, buffer, (char *) NULL);

  + lineLen += 2;

  + if (lineLen >= 60) {

  +     lineLen = 0;

  +     Tcl_AppendResult(interp, "\n", (char *) NULL);

  + }

  + mask=0x80;

  + data=0x00;

  +     }

  + }

  + if ((width % 8) != 0) {

  +     sprintf(buffer, "%02X", data);

  +     Tcl_AppendResult(interp, buffer, (char *) NULL);

  +     mask=0x80;

  +     data=0x00;

  + }

  + break;

  +     }

  +     case 1: {

  + /*

  +  * Generate transparency data.

  +  */

  + for (xx = x; xx < x+width; xx ++) {

  +     pixelPtr = masterPtr->pix24 + 

  +     (yy * masterPtr->width + xx) * 4;

  +     sprintf(buffer, "%02X", pixelPtr[3] | 0x01);

  +     Tcl_AppendResult(interp, buffer, (char *) NULL);

  +     lineLen += 2;

  +     if (lineLen >= 60) {

  + lineLen = 0;

  + Tcl_AppendResult(interp, "\n", (char *) NULL);

  +     }

  + }

  + 

  + 

  + /*

  +  * Generate data in gray mode--in this case, take a 

  +  * weighted sum of the red, green, and blue values.

  +  */

  + 

  + for (xx = x; xx < x+width; xx ++) {

  +     pixelPtr = masterPtr->pix24 + 

  +     (yy * masterPtr->width + xx) * 4;

  +     red = *(pixelPtr++);

  +     green = *(pixelPtr++);

  +     blue = *(pixelPtr++);

  +     sprintf(buffer, "%02X", (int) floor(0.5 +

  +     ( 0.3086 * red 

  +     + 0.6094 * green 

  +     + 0.0820 * blue)));

  +     Tcl_AppendResult(interp, buffer, (char *) NULL);

  +     lineLen += 2;

  +     if (lineLen >= 60) {

  + lineLen = 0;

  + Tcl_AppendResult(interp, "\n", (char *) NULL);

  +     }

  + }

  + break;

  +     }

  +     default: {

  + /*

  +  * Generate transparency data.

  +  */

  + for (xx = x; xx < x+width; xx ++) {

  +     pixelPtr = masterPtr->pix24 + 

  +     (yy * masterPtr->width + xx) * 4;

  +     sprintf(buffer, "%02X", pixelPtr[3] | 0x01);

  +     Tcl_AppendResult(interp, buffer, (char *) NULL);

  +     lineLen += 2;

  +     if (lineLen >= 60) {

  + lineLen = 0;

  + Tcl_AppendResult(interp, "\n", (char *) NULL);

  +     }

  + }

  + 

  + 

  + /*

  +  * Finally, color mode.  Here, just output the red, green,

  +  * and blue values directly.

  +  */

  + 

  + for (xx = x; xx < x+width; xx++) {

  +     pixelPtr = masterPtr->pix24 + 

  +     (yy * masterPtr->width + xx) * 4;

  +     sprintf(buffer, "%02X%02X%02X",

  +     pixelPtr[0], pixelPtr[1], pixelPtr[2]);

  +     Tcl_AppendResult(interp, buffer, (char *) NULL);

  +     lineLen += 6;

  +     if (lineLen >= 60) {

  + lineLen = 0;

  + Tcl_AppendResult(interp, "\n", (char *) NULL);

  +     }

  + }

  + break;

  +     }

  + }

  +     }

  + 

  +     Tcl_AppendResult(interp, ">\n grestore\n", (char *) NULL);

  +     return TCL_OK;

  + 

    }

  *** tkInt.h.origFri Jan 21 04:54:41 2000

  --- tkInt.hThu Feb 24 14:21:54 2000

  ***************

  *** 999,1004 ****

  --- 999,1009 ----

    EXTERN intTk_WmCmd _ANSI_ARGS_((ClientData clientData,

        Tcl_Interp *interp, int argc, char **argv));

    

  + EXTERN int              TkAppendPhotoPsData _ANSI_ARGS_((

  +                             ClientData clientData, Tcl_Interp *interp,

  +     int x, int y, int width, int height,

  +     int colorLevel));

  + 

    voidTkConsolePrint _ANSI_ARGS_((Tcl_Interp *interp,

        int devId, char *buffer, long size));

    

  ***************

  *** 1052,1057 ****

  --- 1057,1067 ----

        Tk_Window tkwin, Tk_PostscriptInfo psInfo,

        XImage *ximage, int x, int y, int width,

        int height));

  + EXTERN intTkPostscriptPhoto _ANSI_ARGS_((

  +     ClientData clientData, Tcl_Interp *interp,

  +     Tk_Window tkwin, Tk_PostscriptInfo psInfo,

  +     int x, int y, int width, int height,

  +     int prepass));

    EXTERN intTkSmoothParseProc _ANSI_ARGS_((ClientData clientData,

        Tcl_Interp *interp, Tk_Window tkwin,

        CONST char *value, char *recordPtr, int offset));



  PatchFiles:

  tkInt.h tkCanvPs.c tkImage.c tkImgPhoto.c


tkt_uuid: 220234ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 41. Photo Images
priority: 1 Zero
foundin: obsolete: 8.2
resolution: Invalid
title: Subscript out of range in tkImg*.c
comment:
  OriginalBugID: 2724 Bug
  Version: 8.2
  SubmitDate: '1999-09-10'
  LastModified: '1999-09-10'
  Severity: SER
  Status: Closed
  Submitter: techsupp
  ChangedBy: hobbs
  OS: IRIX
  OSVersion: IRIX 6.5
  Machine: Other
  ClosedDate: '1999-09-10'


  Name:
  Rob Ratcliff

  Extensions:
  Tix, Sox, incrTk

  ReproducibleScript:
  It appears that the dimension of the structure member "offset" isn't
      large enough
      in the file tk.h
      
      Excerpt from file tk.h
         941  /*
         942   * The following structure describes a block of pixels in
      memory:
         943   */
                 
         944  typedef struct Tk_PhotoImageBlock {
         945      unsigned char *pixelPtr;    /* Pointer to the first pixel.
      */
         946      int     width;      /* Width of block, in pixels. */
         947      int     height;     /* Height of block, in pixels. */
         948      int     pitch;      /* Address difference between
      corresponding
         949                   * pixels in successive lines. */
         950      int     pixelSize;  /* Address difference between successive
         951                   * pixels in the same line. */
         952      int     offset[3];  /* Address differences between the red,
      green
         953                   * and blue components of the pixel and the
         954                   * pixel as a whole. */
         955      int     reserved;   /* Reserved for extensions (dash patch)
      */
         956  } Tk_PhotoImageBlock;
      
      cc -c -O   -I. -I./../generic -I./../bitmaps
      -I/usr3/people/rrr6399/tk/tcl8.2.0/tcl8.2.0/generic  -n32  -DHAVE_UNIS
      TD_H=1 -DHAVE_LIMITS_H=1 -DSTDC_HEADERS=1 -DHAVE_SYS_TIME_H=1
      -DTIME_WITH_SYS_TIME=1 -DHAVE_PW_GECOS=1 -D__CHAR_UNS
      IGNED__=1      -DTCL_NO_DEPRECATED   ./../generic/tkImgGIF.c
      "./../generic/tkImgGIF.c", line 266: warning(1172): subscript out of
      range
            block.offset[3] = 0;
            ^
      
      cc -c -O   -I. -I./../generic -I./../bitmaps
      -I/usr3/people/rrr6399/tk/tcl8.2.0/tcl8.2.0/generic  -n32  -DHAVE_UNIS
      TD_H=1 -DHAVE_LIMITS_H=1 -DSTDC_HEADERS=1 -DHAVE_SYS_TIME_H=1
      -DTIME_WITH_SYS_TIME=1 -DHAVE_PW_GECOS=1 -D__CHAR_UNS
      IGNED__=1      -DTCL_NO_DEPRECATED   ./../generic/tkImgPPM.c
      "./../generic/tkImgPPM.c", line 186: warning(1172): subscript out of
      range
            block.offset[3] = 0;
            ^
      
      cc -c -O   -I. -I./../generic -I./../bitmaps
      -I/usr3/people/rrr6399/tk/tcl8.2.0/tcl8.2.0/generic  -n32  -DHAVE_UNIS
      TD_H=1 -DHAVE_LIMITS_H=1 -DSTDC_HEADERS=1 -DHAVE_SYS_TIME_H=1
      -DTIME_WITH_SYS_TIME=1 -DHAVE_PW_GECOS=1 -D__CHAR_UNS
      IGNED__=1      -DTCL_NO_DEPRECATED   ./../generic/tkImgPhoto.c
      "./../generic/tkImgPhoto.c", line 805: warning(1172): subscript out of
      range
              block.offset[3] = 0;
              ^
      
      "./../generic/tkImgPhoto.c", line 4177: warning(1172): subscript out of
      range
            blockPtr->offset[3] = 0;
            ^



  This is not really a bug.  As Jan Nijtmans pointed out, this will
  actually acccess the 'reserved' int, which is there for that
  purpose.  This was a pseudo-transitional for the Img patch, which
  is likely to be included in larger part in 8.3. 
  -- 09/10/1999 hobbs


tkt_uuid: 220283ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 65. Generic Window Operations
priority: 1 Zero
foundin: obsolete: 8.3
resolution: Invalid
title: "winfo children ." returns incorrect stacking order
comment:
  OriginalBugID: 4241 Bug
  Version: 8.3
  SubmitDate: '2000-02-25'
  LastModified: '2000-02-25'
  Severity: SER
  Status: Closed
  Submitter: techsupp
  ChangedBy: hobbs
  OS: Windows NT
  ClosedDate: '2000-02-25'


  Name:
  Roger Lucas

  ReproducibleScript:
  Open a WISH console and type the following :
  % toplevel .one
  .one
  % toplevel .two
  .two
  % raise .one .two
  % winfo children .
  .one .two
  % raise .two .one 
  % winfo children .
  .one .two

  ObservedBehavior:
  According to the help manual, "winfo children ." will return a list of the toplevel windows in their stacking order.  It does not.  It returns them in their creation order.  

  This is confirmed behaviour on both Windows NT and Windows 98

  DesiredBehavior:
  Please make the "winfo children ." command match the documentation, and return the toplevel windows in their stacking order.



  The docs here are unclear, but the extra note about toplevels is
  meant to say that they are handled (and returned) differently than
  other Tk widget children.  This works correctly for child widgets,
  but toplevels are returned in creation order because their order
  is really maintained by the window manager. 
  -- 02/25/2000 hobbs


tkt_uuid: 2830360fffffffffffffffffffffffffffffffff
type: Bug
status: Open
subsystem: 88. Themed Tk
priority: 5 Medium
foundin: obsolete: 8.6b1.1
resolution: None
title: ttk::entry looses state invalid at focus events
comment:
  Platforms: Unix X11 and Windows

  Example to reproduce
  %  pack .e
  % bind .e <FocusIn> {puts "%W <FocusIn> %d: [.e state]"}
  %  bind .e <FocusOut> {puts "%W <FocusOut> %d: [.e state]"}
  %  bind .e <Return> {.e state invalid}

  After pressing Return inside the field and focussing outside the entryfield,
  the state invalid is lost.
  It also happens if you set state invalid from  the console and focus into the entryfield.


tkt_uuid: 2956100fffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 18. [text]
priority: 1 Zero
foundin: obsolete ----
resolution: Duplicate
title: Text widgets with "-" in names vs anchor tags
comment:
  Try this:

  pack [text .t] -side top
  pack [text .t-2] -side top

  .t insert end "Double click me"
  .t-2 insert end "Double click me"

  and follow instructions.  Double-clicking on a word in .t-2 raises an error "bad text index "tk::anchor.t-2 - 1c"
  bad text index "tk::anchor.t-2 - 1c"
      while executing
  "$w compare $cur < $first"
      (procedure "tk::TextSelectTo" line 33)
      invoked from within
  "tk::TextSelectTo .t-2 96 15"
      (command bound to event)


tkt_uuid: 3394337fffffffffffffffffffffffffffffffff
type: Bug
status: Open
subsystem: 02. Appearance
priority: 5 Medium
foundin: obsolete: 8.6b2
resolution: None
title: ttk::notebook slider not correct
comment:
  In ttk::notebook the last slider wasn't correctly displayed. In 8.5.9 it runs perfect. 

  The behavior can be seen at:
  8.5.9  http://www.ets.uni-due.de/~honerla/tcl/8.5.png
  8.6.b2 http://www.ets.uni-due.de/~honerla/tcl/8.6.png

  System Linux/Xorg x86_64
  Tcl/Tk 8.6.b2  build from source code
  Tcl/Tk 8.5.9 from distribution DVD (Opensuse 11.4)


tkt_uuid: 220899ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 44. Generic Fonts
priority: 5 Medium
foundin: obsolete: 8.2
resolution: Fixed
title: Unicode Box characters use wrong font
comment:
  OriginalBugID: 4363 Bug
  Version: 8.2
  SubmitDate: '2000-03-10'
  LastModified: '2000-03-30'
  Severity: SER
  Status: UnAssn
  Submitter: techsupp
  ChangedBy: hobbs
  OS: Solaris
  OSVersion: 2.6
  Machine: SunOS bksmx1 5.6 Generic_105181-16 sun4u sparc SUNW,UltraAX-MP


  Name:
  Tom Allard

  Extensions:
  none

  CustomShell:
  None.  Using prowish82 provided with TclPro 1.3.

  ReproducibleScript:
  set text [text .t -wrap none -font 6x10]
      pack $text -expand 1 -fill both
      if {[string match $tk_version "8.0"]} {
  set sample "\x0D\x12\x18\x12\x0C\n"
  append sample "\x19\A\x19\B\x19\n"
  append sample "\x15\x12\x0F\x12\x16\n"
  append sample "\x19\C\x19\D\x19\n"
  append sample "\x0E\x12\x17\x12\x0B\n"
      } else {
  set sample "\u250f\u2501\u2533\u2501\u2513\n"
  append sample "\u2502A\u2502B\u2502\n"
  append sample "\u251D\u2501\u254B\u2501\u252B\n"
  append sample "\u2502C\u2502D\u2502\n"
  append sample "\u2517\u2501\u2537\u2501\u251B\n"
      }
      $text insert end $sample

  ObservedBehavior:
  In Tcl/Tk 8.0, a 4x4 box is created and properly aligned.  In 8.2, the box characters are not from the 6x10 font and the box no longer lines properly.

  DesiredBehavior:
  The 8.2 version using unicode should be able to look identical to the 8.0 version.


tkt_uuid: 2992129fffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 68. Win Window Operations
priority: 8
foundin: obsolete: 8.5.8
resolution: Fixed
title: crash when using Pinyin or Japanese (Hiragana) IME input
comment:
  8.5.8/8.5.8.1 does crash when using Pinyin or Japanese (Hiragana) IME input, which 8.4.19 does function correctly.
  OS:WinXP pro with sp3
  windows report:
  AppName: wish85.exe AppVer: 8.5.2.8 ModName: ntdll.dll
  ModVer: 5.1.2600.5755 Offset: 0000120e


tkt_uuid: 2184632fffffffffffffffffffffffffffffffff
type: Bug
status: Open
subsystem: 11. Aqua Menus
priority: 5 Medium
foundin: None
resolution: None
title: postcascade <index> does not work
comment:
  Explicitly calling postcascade to attempt to pop up a menu from the menubar does on work.  Tested on OS X 10.5, Tcl/Tk 8.4.7, 8.6a1:


  menu .mbar -tearoff 0
  . configure -menu .mbar
  menu .mbar.apple -tearoff 0
  .mbar add cascade -menu .mbar.apple
  .mbar.apple add command -label "About Foo" -command { puts "About" }
  menu .mbar.file -tearoff 0
  .mbar.file add command -label "Dummy" -command { puts "Dummy" }
  .mbar add cascade -label "File" -menu .mbar.file

  after 5000 { .mbar postcascade 0 }


  Nothing happens, and no error is generated.

  (The use case for calling this in user code is to simulate platform compliance using bindings, for the following: Command-? activates Help menu, Control-F2 activates Apple menu.)


tkt_uuid: 220606ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 09. [listbox]
priority: 2
foundin: obsolete: 8.2.1
resolution: Fixed
title: -listvar for listbox
comment:
  OriginalBugID: 3301 RFE
  Version: 8.2.1
  SubmitDate: '1999-11-05'
  LastModified: '1999-12-09'
  Severity: LOW
  Status: Released
  Submitter: hobbs
  ChangedBy: hobbs
  OS: All
  FixedDate: '1999-12-09'
  FixedInVersion: 8.3b1


  -listvar would be equiv to entry's -textvar.

  Somewhat mutually exclusive to the RFE to add itemconfigure
  (ability to change fg/bg color, font for specific listbox items),
  but may be more useful.


tkt_uuid: 749010ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 21. [panedwindow]
priority: 5 Medium
foundin: obsolete: 8.5a0
resolution: Invalid
title: panedwindow.test fails
comment:
  This test fails on Tru64Unix 5.1A with tcl8.4.3/tk-cvs
  but NOT tcl8.4.3/tk8.4.3(maybe it's expected when
  messing up versions):

  ==== panedwindow-23.2 PanedWindowReqProc, react to
  slave geometry changes FAILED
  ==== Contents of test case:

      panedwindow .p -orient horizontal -sashpad 0
  -sashwidth 2
      .p add [frame .f1 -width 10] [frame .f2 -width 10]
      set result [winfo reqwidth .p]
      .f1 configure -width 20
      lappend result [winfo reqwidth .p]
      destroy .p .f1 .f2
      set result

  ---- Result was:
  32 32
  ---- Result should have been (exact matching):
  32 42
  ==== panedwindow-23.2 FAILED


tkt_uuid: 586955ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 86. Test Tools
priority: 5 Medium
foundin: obsolete: 8.4b2
resolution: Wont Fix
title: update for tests/README suggested
comment:
  A note should be added to this file indicating that the
  user should use tktest rather than tcltest when running
  the individual tests.

  Right now the README says to use the tcl/tests/README
  for info about the test suite - and that file says to
  use tcltest ...


tkt_uuid: 428784ffffffffffffffffffffffffffffffffff
type: Patch
status: Closed
subsystem: 04. Canvas Basics
priority: 5 Medium
foundin: None
resolution: Duplicate
title: Fix for bug #226357 Overlapping with Pol
comment:
  Remove test for polygon fill that was causing
  problems and provided no benefit.

  Test case (good result):

  $ wish8.4
  % pack [canvas .c]
  % .c create poly 30 30 30 90 90 90 90 30 -fill ""
  -outline black
  1
  % .c find over 45 45 45 45
  1
  % .c find over 0 0 0 0
  % info patch
  8.4a3
  % 


tkt_uuid: 963020ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 84. Unix Build
priority: 5 Medium
foundin: obsolete: 8.5a1
resolution: Out of Date
title: Problem compiling tk8.5a1
comment:
  # gmake
  gcc -pipe -c -s -O3 -march=i686 -O2 -Wall -Wconversion
  -Wno-implicit-int -fPIC -I/tmp/tk8.5a1/unix
  -I/tmp/tk8.5a1/unix/../generic
  -I/tmp/tk8.5a1/unix/../bitmaps -I/tmp/tcl8.5a1/generic
  -I/usr/X11R6/include -DPACKAGE_NAME=\"\"
  -DPACKAGE_TARNAME=\"\" -DPACKAGE_VERSION=\"\"
  -DPACKAGE_STRING=\"\" -DPACKAGE_BUGREPORT=\"\"
  -DSTDC_HEADERS=1 -DHAVE_SYS_TYPES_H=1
  -DHAVE_SYS_STAT_H=1 -DHAVE_STDLIB_H=1 -DHAVE_STRING_H=1
  -DHAVE_MEMORY_H=1 -DHAVE_STRINGS_H=1
  -DHAVE_INTTYPES_H=1 -DHAVE_STDINT_H=1 -DHAVE_UNISTD_H=1
  -DHAVE_UNISTD_H=1 -DHAVE_LIMITS_H=1
  -D_LARGEFILE64_SOURCE=1 -DTCL_WIDE_INT_TYPE=long\ long
  -DHAVE_STRUCT_STAT64=1 -DHAVE_TYPE_OFF64_T=1
  -DTCL_THREADS=1 -D_REENTRANT=1 -D_THREAD_SAFE=1
  -DPEEK_XCLOSEIM=1 -DTCL_CFG_OPTIMIZED=1
  -DTCL_CFG_DEBUG=1 -DHAVE_SYS_TIME_H=1
  -DTIME_WITH_SYS_TIME=1 -DHAVE_PW_GECOS=1 -DHAVE_XFT=1 
      -DTCL_NO_DEPRECATED -DUSE_TCL_STUBS 
  /tmp/tk8.5a1/unix/../generic/tk3d.c
  In file included from /usr/local/include/tclInt.h:2266,
                   from
  /tmp/tk8.5a1/unix/../generic/../unix/tkUnixPort.h:224,
                   from
  /tmp/tk8.5a1/unix/../generic/tkPort.h:34,
                   from
  /tmp/tk8.5a1/unix/../generic/tkInt.h:27,
                   from
  /tmp/tk8.5a1/unix/../generic/tk3d.h:18,
                   from
  /tmp/tk8.5a1/unix/../generic/tk3d.c:16:
  /usr/local/include/tclIntDecls.h:322: error: parse
  error before '->' token
  /usr/local/include/tclIntDecls.h:326: error: parse
  error before '->' token
  /usr/local/include/tclIntDecls.h:330: error: parse
  error before '->' token
  /usr/local/include/tclIntDecls.h:333: error: parse
  error before '->' token
  /usr/local/include/tclIntDecls.h:337: error: parse
  error before '->' token
  /usr/local/include/tclIntDecls.h:341: error: parse
  error before '->' token
  /usr/local/include/tclIntDecls.h:357: error: parse
  error before '->' token
  /usr/local/include/tclIntDecls.h:360: error: parse
  error before '->' token
  /usr/local/include/tclIntDecls.h:363: error: parse
  error before '->' token
  /usr/local/include/tclIntDecls.h:367: error: parse
  error before '->' token
  /usr/local/include/tclIntDecls.h:370: error: parse
  error before '->' token
  /usr/local/include/tclIntDecls.h:377: error: parse
  error before '->' token
  gmake: *** [tk3d.o] Error 1


tkt_uuid: 220217ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 63. Tk_Win Functions
priority: 1 Zero
foundin: obsolete: 8.0
resolution: Invalid
title: tk_DestroyWindow when called from a command results in crash
comment:
  OriginalBugID: 2464 Bug
  Version: 8.0
  SubmitDate: '1999-07-28'
  LastModified: '2000-01-07'
  Severity: CRIT
  Status: Closed
  Submitter: techsupp
  ChangedBy: hobbs
  OS: Windows 95
  Machine: X86
  ClosedDate: '2000-01-07'


  Name:
  Seema

  CustomShell:
  Yes

  ReproducibleScript:
  Environment: windows 95 and win NT
                            Tcl 7.6 Tk 4.2
      Application coded in VC 5.0
      From within the code I'm calling Tcl_CreateInterp to create interpreter.
      Also I'm creating some commands using "Tcl_CreateCommand".
      
      Problem : 
      I have written a command by name "exit"which finds the tk window and
      destroys it
      -----------code for
      command-------------------------------------------------------
      Tk_Window tkwin = Tk_MainWindow ( interp );
      if( tkwin ) Tk_DestroyWindow ( tkwin );   // CRASH POINT
      return TCL_OK;
      -------------------------------------------------------------------------
      ----------------------
      
      If I write a tcl script as :
      -------------------------------------------------------------------------
      ----------------------
      tk_messageBox -message "hello"
      exit
      -------------------------------------------------------------------------
      ----------------------
      
      My application crashes while executing exit command.The crash occurs 
      only for this combination of commands.
      The crash occurs while executing "Tk_DestroyWindow " command.
      Tk throws some exception while executing this command , I'm not able to 
      identify the cause of exception. My application crashes after this.
      If I execute a script with some other set of commands followed by "exit"
      
      command (that I implemented) , there is no problem and run goes smooth.
      It is only for consequent execution of tk_messageBox" and "exit" command
      that the crash occurs.After the exception occurs even interp->Result is
      empty 
      and I can't trace back any reason for the crash.

  DesiredBehavior:
  I would like to know the reason for this behaviour.
      Also if you could suggest some recovery mechanism.



  Note the version is 4.2.  That version is many years old, and
  we don't work on it anymore. 
  -- 01/07/2000 hobbs


tkt_uuid: 220337ffffffffffffffffffffffffffffffffff
type: Bug
status: Closed
subsystem: 85. Win Build
priority: 2
foundin: obsolete: 8.0.3
resolution: Fixed
title: prowish not as fast as tcl8.0p2
comment:
  OriginalBugID: 212 Bug
  Version: 1.0b4
  SubmitDate: '1998-07-23'
  LastModified: '1999-12-14'
  Severity: LOW
  Status: Fix/AA
  Submitter: hershey
  ChangedBy: hobbs
  OS: All Windows
  OSVersion: NA
  Machine: NA
  FixedDate: '1999-12-14'
  FixedInVersion: 1.3


  I discovered that standard WISH80.EXE runs my code at a good speed, 
  however running PROWISH.EXE slowed my program by about 5 times, 
  compiling it with PROCOMP and running "PROWISH source.TBC" was 
  same as uncompiled.


  (ems 8/28/98) set the OS field to "All Windows", this is not a generic problem

  (ems 8/28/98) There is definitely a performance degradation in protclsh, although not necessarily 5 times slower (other users have reported twice as slow, and that is consistent with a quick-and-dirty bekchmark I did). The reason is that we switched to VC++ 5.0 from Borland, and decided not to tighten the optimization flags for fear that the optimizer would generate bad code. I ran the following test script on a number of platforms, see results below:

  proc f {i} {
      set x [expr {$i * $i}]
      return $x
  }
  puts [time {f 2} 50000]

  8.0.3 with default VC++ flags  :                         12 microseconds per iteration
  8.0.3 with maximum optimization (-O2) :         7 microseconds per iteration
  8.0p2 with default VC++ flags :                        10 microseconds per iteration
  8.0p2 with Borland compiler  :                            6 microseconds per iteration
  tclpro  :                                                                   12 microseconds per iteration
  tclpro with maximum optimization (-O2)   :     7 microseconds per iteration

  (ems 8/28/98) Also, compiling a .tcl script into .tbc won't change runtime performance: the .tbc file contains the same bytecodes that the .tcl file would generate. There may be an improvement in loading performance if the .tbc file is smaller enough than the .tcl file that I/O gains overshadow the added expense of decoding the .tbc file.

  (pat 9/2/98) Under Windows, Tcl code executed by the Tclpro shells (protclsh80.exe and
  prowish80.exe) will run slower than if it were executed in 8.0p2 shells.

  This is because TclPro switched from Borland to VC++ as the compiler of
  choice with the Tcl/Tk builds. The optimization flags for VC++ were left at a
  somewhat loose level, because we were worried that more aggressive optimization
  would generate bad codes, and there wasn't enough time to do extensive
  testing to make sure that the optimizer behaved.

  As a consequence, the TclPro interpreters are slower than 8.0p2. Note that
  protclsh80.exe and prowish80.exe are NOT slower than 8.0.3 interpreters built
  with VC++ and the makefile.vc in the win directories. They will be slower than
  8.0.3 interpreters built with -O2, however; for example, if someone creates
  a DevStudio project, sets it to "Maximize Speed", generates the DLL and the
  EXE, those interpreters will be faster than ours.
  --
  work-arounds:

  This is a possible workaround:

  1) rebuild the Tcl 8.0.3 DLL from the source distribution, using VC++ 5.0
     with optimization flags set to -O2. For example, this can be done from
     the Developer Studio IDE by selecting the C/C++ tab in "Settings", the
     "Optimizations" category, and the "Maximize Speed" drop-down choice.

  2) replace tcl80.dll in win32-ix86/bin with the one you built in step 1.
     Don't forget to make a copy of the original in case you want to switch
     back.

  The TclPro-generated tcl80.dll was built from the same distribution as the
  8.0.3 tcl80.dll, so replacing it should be OK. The unknown here is how well
  the code optimizer in VC++ works, in particular will it generate bad code.
  --
  More recent versions of Tcl (and TclPro) use -O2, as well as newer
  versions of VC++. 
  -- 12/14/1999 hobbs


tkt_uuid: 511431ffffffffffffffffffffffffffffffffff
type: Bug
status: Open
subsystem: 04. Canvas Basics
priority: 5 Medium
foundin: obsolete: 8.3.4
resolution: None
title: Error processing events (bug&workaround)
comment:
  Please watch the code below, run it
  an call nogo. Behavior:
  Tcl-Error for generated event. The idea behind the
  code is to generate an event when an item in the
  canvas is picked ny the user.
  The function doeswork does the same with a frame
  and widgets, here processing generated events
  works fine.
  The code has been distilled from a much more
  complex example.

  proc f {} {
      catch {event generate $::evw <Button-1> -x 15 -y 15
  -when mark}
  }
  proc cb1 {} {puts cb1}
  proc cb2 {} {puts cb2; f}

  proc nogo {} {
      toplevel .t
      set ::evw [canvas .t.c];
      pack .t.c -fill both -expand 1
      set ::r1 [.t.c create rect 10 10 20 20 -fill red]
      set ::r2 [.t.c create rect 100 10 110 20 -fill
  green]
      $::evw bind $::r1 <ButtonPress-1> "cb1";
      $::evw bind $::r2 <ButtonPress-1> "cb2";
  }

  proc doeswork {} {
      toplevel .t
      set ::r1 [frame .t.f1 -bg green -width 10 -height
  10];
      place .t.f1 -x 10 -y 10
      set ::r2 [frame .t.f2 -bg red -width 10 -height
  10];
      place .t.f2 -x 100 -y 10
      set ::evw $::r1;
      bind $::r1 <ButtonPress-1> cb1;
      bind $::r2 <ButtonPress-1> cb2;
  }


  Possible WORKAROUND:
  in generic/tkEvent.cTk_HandleEvent, lines 559..578:
  deactive these lines with #if 0/#endif will make
  this example and many other cases work, but it
  breaks some of the tests coming with Tk.
  I have currently no idea about the consequences
  of this workaround, but I used it for 8.3.2/8.3.3
  as well. I assume the correct fix needs to touch
  the canvas widget C-code dealing with event handling.


