Method: Tk::Wm.maxsize
- Defined in:
- lib/tk/wm.rb
.maxsize(win, *args) ⇒ Object
def Wm.manage(win, use_id = nil)
# Tcl/Tk 8.5+ feature
# --------------------------------------------------------------
# In the future release, I want to support to embed the 'win'
# into the container which has window-id 'use-id'.
# It may give users frexibility on controlling their GUI.
# However, it may be difficult for current Tcl/Tk (Tcl/Tk8.5.1),
# because it seems to require to modify Tcl/Tk's source code.
# --------------------------------------------------------------
if use_id
tk_call_without_enc('wm', 'manage', win.epath, '-use', use_id)
else
tk_call_without_enc('wm', 'manage', win.epath)
end
win
end
326 327 328 329 330 331 332 333 334 |
# File 'lib/tk/wm.rb', line 326 def Wm.maxsize(win, *args) if args.size == 0 list(tk_call_without_enc('wm', 'maxsize', win.epath)) else args = args[0] if args.length == 1 && args[0].kind_of?(Array) tk_call_without_enc('wm', 'maxsize', win.epath, *args) win end end |