#2877 Modifying canvas line item forgets to refresh

obsolete: 8.6b1.1

Using "insert" to modify a line item, as in

$canvas insert $line $position {$coords}

misses the refresh, as can be seen in

pack [canvas .c]
set line [.c create line 10 10 210 10 -fill blue]
after 2000
.c insert $line 2 {110 110}

Partially obscuring the canvas with another window and exposing it again fixes the display.
Tested on Debian Gnu/Linux squeeze with Tk 8.4, 8.5 and 8.6 (the first two are standard distro packages).

Alexandre Ferrieux kindly provided a patch in cmp.lang.tcl, which I attach (I haven't had the time to test it yet, though).

References: comp.lang.tcl:<87fws1v827.fsf@floh.bas23>, comp.lang.tcl:<dc596818-a0d4-4e3a-99a5-55446de6e574@s3g2000vbf.googlegroups.com>


  • Donal K. Fellows

    Confirmed with current Tk. Assigning to Alex since he has a patch.

  • Donal K. Fellows

    • milestone: --> obsolete: 8.6b1.1
    • priority: 5 --> 9
    • assigned_to: hobbs --> ferrieux
  • Alexandre Ferrieux

    use final length instead of initial !

  • Alexandre Ferrieux

    Thanks, will commit as soon as there is a place to commit to :}

  • Alexandre Ferrieux

    Committed to fossil at core.tcl.tk/tcl

  • Alexandre Ferrieux

    • status: open --> closed-fixed
  • Don Porter

    Don Porter - 2011-06-10

    backported to all active branches