Tk Source Code

Ticket Change Details
Login
Overview

Artifact ID: 24672bc088cf9331c4066a9564cf10384d2372da
Ticket: 61bfd35c57a90372b3025d7f2915674c89ffee45
Scrollbars keep flickering indefinitely after being destroyed
User & Date: linusnyberg 2014-12-21 20:41:49
Changes

  1. assignee changed to: "nobody"
  2. closer changed to: "nobody"
  3. cmimetype changed to: "text/plain"
  4. comment changed to:
    The problem is Mac-only. It has been introduced some time AFTER Tcl/Tk 8.6.1. The below replication steps do not cause flickering there.
    Replicated with latest source (8.6.3) as of 2014-12-21:
    
    Do:
    - Run the below script in Wish.
    - Move the mouse around in the window.
    - Also try resizing the window.
    
    Happens:
    Each time the mouse motion even triggers, the since-long destroyed scrollbar keeps appearing (flickering) on the screen.
    
    Expected:
    That the scrollbar is simply gone, since it was destroyed.
    
    Here's the script:
    ###########################
    proc main {} {
    	console show
    	wm geometry . 800x600
    	frame .f -width 750 -height 550 -bg grey75
    	place .f -x 50 -y 50 -anchor nw
    	button .f.b -text hello
    	place .f.b -x 100 -y 100 -anchor nw
    	set w [create_window .f 10 10 300 300]
    	update
    	destroy $w
    
    	bind all <Motion> {
    		.f.b configure -text [clock seconds]
    	}
    }
    
    proc create_window {parent_w x y width height} {
    	set w $parent_w.c_container
    	frame $w -bg grey75 -bd 0 -width $width -height $width
    	scrollbar $w.vscroll -command "$w.c yview"
    	canvas $w.c -highlightthickness 0 -width [expr {$width - 15}] -height [expr {$width}] -relief sunken -bg grey85 -bd 0 -yscrollcommand "$w.vscroll set"
    	grid $w.c -padx 1 -pady 1 -row 0 -column 0 -rowspan 1 -columnspan 1 -sticky news
    	grid $w.vscroll -padx 1 -pady 1 -row 0 -column 1 -rowspan 1 -columnspan 1 -sticky news
    
    	place $w -x $x -y $y -anchor nw
    	return $w
    }
    
    after 10 main
    
  5. foundin changed to: "8.6.3"
  6. is_private changed to: "0"
  7. login: "linusnyberg"
  8. priority changed to: "5 Medium"
  9. private_contact changed to: "14b3a2938e33673267beada540e11569b4c12b7b"
  10. resolution changed to: "None"
  11. severity changed to: "Severe"
  12. status changed to: "Open"
  13. submitter changed to: "linusnyberg"
  14. subsystem changed to: "66. Aqua Window Operations"
  15. title changed to:
    Scrollbars keep flickering indefinitely after being destroyed
    
  16. type changed to: "Bug"