configure

configure(*args)
Class Public methods

def configure(win, *args)

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

grid

doc_ruby_on_rails
2015-04-11 19:12:25
Comments
Leave a Comment

Please login to continue.