Overview
Artifact ID: | 31b66ade4ca7bde4f09e7cb3f78604e17fa39b6dc7419fe3c70b7a4b710fa114 |
---|---|
Ticket: | 45668dbdf0a50fd901270781643f771c23811dd7
ScrollableFrame fails with too many widgets |
User & Date: | anonymous 2017-10-22 09:22:24 |
Changes
- assignee changed to: "nobody"
- closer changed to: "nobody"
- cmimetype changed to: "text/x-fossil-wiki"
- comment changed to:
If a ScrollableFrame contains too many widgets, it does not display / scroll them correctly anymore. Either the frame does not scroll below a certain point (even if there would be more widgets), or - sometimes - widgets that should be placed towards the bottom of the frame, show up at the top. This script demonstrates the issue: <verbatim> #!/usr/bin/env tclsh package require Tk 8.6 package require BWidget 1.9.7 set widgetCount 200 set widgetHeight 20 # UI # ScrollableFrame .sf grid .sf -column 0 -row 0 -sticky nsew grid columnconfigure . 0 -weight 1 # Scroll bindings # bind . <Button-4> [list .sf yview scroll -1 unit] bind . <Button-5> [list .sf yview scroll 1 unit] grid rowconfigure . 0 -weight 1 # Create widgets # for {set i 1} {$i <= $widgetCount} {incr i} { grid [label [.sf getframe].$i -text $i -height $widgetHeight] } </verbatim> (run and try to scroll to label #200) Notes: * If the problem does not reproduce, try increasing the 'widgetHeight' and / or 'widgetCount' vars. * The key factor seems to be the total height of widgets in the frame and not their number. i.e. the same effect could be reproduced with less widgets, if they are higher.
- foundin changed to: "1.9.10"
- is_private changed to: "0"
- login: "anonymous"
- priority changed to: "5 Medium"
- private_contact changed to: "0d5810a6d532ee60fe454fd2bdbe8e482821d713"
- resolution changed to: "None"
- severity changed to: "Minor"
- status changed to: "Open"
- submitter changed to: "anonymous"
- subsystem changed to: "bwidget"
- title changed to: "ScrollableFrame fails with too many widgets"
- type changed to: "Bug"