configure(*args)
Class Public methods
def configure(win, *args)
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 | if args[- 1 ].kind_of?( Hash ) opts = args.pop else opts = {} end params = [] params.push(_epath(win)) args. each {|win| case win when '-' , 'x' , '^' # RELATIVE PLACEMENT params.push(win) else params.push(_epath(win)) end } opts. each {|k, v| params.push( "-#{k}" ) params.push((v.kind_of?(TkObject))? v.epath: v) } if Tk:: TCL_MAJOR_VERSION < 8 || (Tk:: TCL_MAJOR_VERSION == 8 && Tk:: TCL_MINOR_VERSION <= 3 ) if params[ 0 ] == '-' || params[ 0 ] == 'x' || params[ 0 ] == '^' tk_call_without_enc( 'grid' , *params) else tk_call_without_enc( 'grid' , 'configure' , *params) end else tk_call_without_enc( 'grid' , 'configure' , *params) end |
end
Please login to continue.