*** yours 2006-01-23 17:10:24.000000000 -0800 --- mine 2006-01-23 17:13:53.000000000 -0800 *** 43,64 **** + if {[expr {$gbpr > 150}]} {set gbpr 150} + + # Insert the value into the combo box list, if it isn't there already. ! + set found 0 ! + foreach item $gbprlist { ! + if {$item == $gbpr} { ! + set found 1 ! + } ! + } ! + if {[expr {$found == 0}]} { + lappend gbprlist $gbpr + $Widgets(b-bytes_per_row) list insert end $gbpr + } + + set s $gsize ! + if {[expr {$s == 3}]} {set s 4} ! + if {[expr {$s == 5}]} {set s 8} + set rem [expr {$gbpr % $s}] ! + if {[expr {$rem != 0}]} { + # The bytes-per-row is not a multiple of the size. + set gbpr [expr {$gbpr + ($s - $rem)}] + } --- 53,70 ---- + if {[expr {$gbpr > 150}]} {set gbpr 150} + + # Insert the value into the combo box list, if it isn't there already. ! + set found [lsearch $gbprlist $gbpr] ! + ! + if {$found == -1} { + lappend gbprlist $gbpr + $Widgets(b-bytes_per_row) list insert end $gbpr + } + + set s $gsize ! + if {$s == 3} {set s 4} ! + if {$s == 5} {set s 8} + set rem [expr {$gbpr % $s}] ! + if {$rem != 0} { + # The bytes-per-row is not a multiple of the size. + set gbpr [expr {$gbpr + ($s - $rem)}] + }