Back to index

python3.2  3.2.2
Public Member Functions | Static Public Attributes
tkinter.Wm Class Reference
Inheritance diagram for tkinter.Wm:
Inheritance graph
[legend]

List of all members.

Public Member Functions

def wm_aspect
def wm_attributes
def wm_client
def wm_colormapwindows
def wm_command
def wm_deiconify
def wm_focusmodel
def wm_frame
def wm_geometry
def wm_grid
def wm_group
def wm_iconbitmap
def wm_iconify
def wm_iconmask
def wm_iconname
def wm_iconposition
def wm_iconwindow
def wm_maxsize
def wm_minsize
def wm_overrideredirect
def wm_positionfrom
def wm_protocol
def wm_resizable
def wm_sizefrom
def wm_state
def wm_title
def wm_transient
def wm_withdraw

Static Public Attributes

 aspect = wm_aspect
 client = wm_client
 colormapwindows = wm_colormapwindows
 command = wm_command
 deiconify = wm_deiconify
 focusmodel = wm_focusmodel
 frame = wm_frame
 geometry = wm_geometry
 grid = wm_grid
 group = wm_group
 iconbitmap = wm_iconbitmap
 iconify = wm_iconify
 iconmask = wm_iconmask
 iconname = wm_iconname
 iconposition = wm_iconposition
 iconwindow = wm_iconwindow
 maxsize = wm_maxsize
 minsize = wm_minsize
 overrideredirect = wm_overrideredirect
 positionfrom = wm_positionfrom
 protocol = wm_protocol
 resizable = wm_resizable
 sizefrom = wm_sizefrom
 state = wm_state
 title = wm_title
 transient = wm_transient
 withdraw = wm_withdraw

Detailed Description

Provides functions for the communication with the window manager.

Definition at line 1448 of file __init__.py.


Member Function Documentation

def tkinter.Wm.wm_aspect (   self,
  minNumer = None,
  minDenom = None,
  maxNumer = None,
  maxDenom = None 
)
Instruct the window manager to set the aspect ratio (width/height)
of this widget to be between MINNUMER/MINDENOM and MAXNUMER/MAXDENOM. Return a tuple
of the actual values if no argument is given.

Definition at line 1453 of file __init__.py.

01453 
01454               maxNumer=None, maxDenom=None):
01455         """Instruct the window manager to set the aspect ratio (width/height)
01456         of this widget to be between MINNUMER/MINDENOM and MAXNUMER/MAXDENOM. Return a tuple
01457         of the actual values if no argument is given."""
01458         return self._getints(
01459             self.tk.call('wm', 'aspect', self._w,
01460                      minNumer, minDenom,
                     maxNumer, maxDenom))

Here is the call graph for this function:

def tkinter.Wm.wm_attributes (   self,
  args 
)
This subcommand returns or sets platform specific attributes

The first form returns a list of the platform specific flags and
their values. The second form returns the value for the specific
option. The third form sets one or more of the values. The values
are as follows:

On Windows, -disabled gets or sets whether the window is in a
disabled state. -toolwindow gets or sets the style of the window
to toolwindow (as defined in the MSDN). -topmost gets or sets
whether this is a topmost window (displays above all other
windows).

On Macintosh, XXXXX

On Unix, there are currently no special attribute values.

Definition at line 1463 of file __init__.py.

01463 
01464     def wm_attributes(self, *args):
01465         """This subcommand returns or sets platform specific attributes
01466 
01467         The first form returns a list of the platform specific flags and
01468         their values. The second form returns the value for the specific
01469         option. The third form sets one or more of the values. The values
01470         are as follows:
01471 
01472         On Windows, -disabled gets or sets whether the window is in a
01473         disabled state. -toolwindow gets or sets the style of the window
01474         to toolwindow (as defined in the MSDN). -topmost gets or sets
01475         whether this is a topmost window (displays above all other
01476         windows).
01477 
01478         On Macintosh, XXXXX
01479 
01480         On Unix, there are currently no special attribute values.
01481         """
01482         args = ('wm', 'attributes', self._w) + args
        return self.tk.call(args)
def tkinter.Wm.wm_client (   self,
  name = None 
)
Store NAME in WM_CLIENT_MACHINE property of this widget. Return
current value.

Definition at line 1485 of file __init__.py.

01485 
01486     def wm_client(self, name=None):
01487         """Store NAME in WM_CLIENT_MACHINE property of this widget. Return
01488         current value."""
        return self.tk.call('wm', 'client', self._w, name)
def tkinter.Wm.wm_colormapwindows (   self,
  wlist 
)
Store list of window names (WLIST) into WM_COLORMAPWINDOWS property
of this widget. This list contains windows whose colormaps differ from their
parents. Return current list of widgets if WLIST is empty.

Definition at line 1490 of file __init__.py.

01490 
01491     def wm_colormapwindows(self, *wlist):
01492         """Store list of window names (WLIST) into WM_COLORMAPWINDOWS property
01493         of this widget. This list contains windows whose colormaps differ from their
01494         parents. Return current list of widgets if WLIST is empty."""
01495         if len(wlist) > 1:
01496             wlist = (wlist,) # Tk needs a list of windows here
01497         args = ('wm', 'colormapwindows', self._w) + wlist
        return [self._nametowidget(x) for x in  self.tk.call(args)]
def tkinter.Wm.wm_command (   self,
  value = None 
)
Store VALUE in WM_COMMAND property. It is the command
which shall be used to invoke the application. Return current
command if VALUE is None.

Definition at line 1499 of file __init__.py.

01499 
01500     def wm_command(self, value=None):
01501         """Store VALUE in WM_COMMAND property. It is the command
01502         which shall be used to invoke the application. Return current
01503         command if VALUE is None."""
        return self.tk.call('wm', 'command', self._w, value)
def tkinter.Wm.wm_deiconify (   self)
Deiconify this widget. If it was never mapped it will not be mapped.
On Windows it will raise this widget and give it the focus.

Definition at line 1505 of file __init__.py.

01505 
01506     def wm_deiconify(self):
01507         """Deiconify this widget. If it was never mapped it will not be mapped.
01508         On Windows it will raise this widget and give it the focus."""
        return self.tk.call('wm', 'deiconify', self._w)

Here is the caller graph for this function:

def tkinter.Wm.wm_focusmodel (   self,
  model = None 
)
Set focus model to MODEL. "active" means that this widget will claim
the focus itself, "passive" means that the window manager shall give
the focus. Return current focus model if MODEL is None.

Definition at line 1510 of file __init__.py.

01510 
01511     def wm_focusmodel(self, model=None):
01512         """Set focus model to MODEL. "active" means that this widget will claim
01513         the focus itself, "passive" means that the window manager shall give
01514         the focus. Return current focus model if MODEL is None."""
        return self.tk.call('wm', 'focusmodel', self._w, model)
def tkinter.Wm.wm_frame (   self)
Return identifier for decorative frame of this widget if present.

Definition at line 1516 of file __init__.py.

01516 
01517     def wm_frame(self):
01518         """Return identifier for decorative frame of this widget if present."""
        return self.tk.call('wm', 'frame', self._w)
def tkinter.Wm.wm_geometry (   self,
  newGeometry = None 
)
Set geometry to NEWGEOMETRY of the form =widthxheight+x+y. Return
current value if None is given.

Definition at line 1520 of file __init__.py.

01520 
01521     def wm_geometry(self, newGeometry=None):
01522         """Set geometry to NEWGEOMETRY of the form =widthxheight+x+y. Return
01523         current value if None is given."""
        return self.tk.call('wm', 'geometry', self._w, newGeometry)
def tkinter.Wm.wm_grid (   self,
  baseWidth = None,
  baseHeight = None,
  widthInc = None,
  heightInc = None 
)
Instruct the window manager that this widget shall only be
resized on grid boundaries. WIDTHINC and HEIGHTINC are the width and
height of a grid unit in pixels. BASEWIDTH and BASEHEIGHT are the
number of grid units requested in Tk_GeometryRequest.

Definition at line 1527 of file __init__.py.

01527 
01528          widthInc=None, heightInc=None):
01529         """Instruct the window manager that this widget shall only be
01530         resized on grid boundaries. WIDTHINC and HEIGHTINC are the width and
01531         height of a grid unit in pixels. BASEWIDTH and BASEHEIGHT are the
01532         number of grid units requested in Tk_GeometryRequest."""
01533         return self._getints(self.tk.call(
01534             'wm', 'grid', self._w,
            baseWidth, baseHeight, widthInc, heightInc))

Here is the call graph for this function:

def tkinter.Wm.wm_group (   self,
  pathName = None 
)
Set the group leader widgets for related widgets to PATHNAME. Return
the group leader of this widget if None is given.

Definition at line 1536 of file __init__.py.

01536 
01537     def wm_group(self, pathName=None):
01538         """Set the group leader widgets for related widgets to PATHNAME. Return
01539         the group leader of this widget if None is given."""
        return self.tk.call('wm', 'group', self._w, pathName)
def tkinter.Wm.wm_iconbitmap (   self,
  bitmap = None,
  default = None 
)
Set bitmap for the iconified widget to BITMAP. Return
the bitmap if None is given.

Under Windows, the DEFAULT parameter can be used to set the icon
for the widget and any descendents that don't have an icon set
explicitly.  DEFAULT can be the relative path to a .ico file
(example: root.iconbitmap(default='myicon.ico') ).  See Tk
documentation for more information.

Definition at line 1541 of file __init__.py.

01541 
01542     def wm_iconbitmap(self, bitmap=None, default=None):
01543         """Set bitmap for the iconified widget to BITMAP. Return
01544         the bitmap if None is given.
01545 
01546         Under Windows, the DEFAULT parameter can be used to set the icon
01547         for the widget and any descendents that don't have an icon set
01548         explicitly.  DEFAULT can be the relative path to a .ico file
01549         (example: root.iconbitmap(default='myicon.ico') ).  See Tk
01550         documentation for more information."""
01551         if default:
01552             return self.tk.call('wm', 'iconbitmap', self._w, '-default', default)
01553         else:
            return self.tk.call('wm', 'iconbitmap', self._w, bitmap)
def tkinter.Wm.wm_iconify (   self)
Display widget as icon.

Definition at line 1555 of file __init__.py.

01555 
01556     def wm_iconify(self):
01557         """Display widget as icon."""
        return self.tk.call('wm', 'iconify', self._w)
def tkinter.Wm.wm_iconmask (   self,
  bitmap = None 
)
Set mask for the icon bitmap of this widget. Return the
mask if None is given.

Definition at line 1559 of file __init__.py.

01559 
01560     def wm_iconmask(self, bitmap=None):
01561         """Set mask for the icon bitmap of this widget. Return the
01562         mask if None is given."""
        return self.tk.call('wm', 'iconmask', self._w, bitmap)
def tkinter.Wm.wm_iconname (   self,
  newName = None 
)
Set the name of the icon for this widget. Return the name if
None is given.

Definition at line 1564 of file __init__.py.

01564 
01565     def wm_iconname(self, newName=None):
01566         """Set the name of the icon for this widget. Return the name if
01567         None is given."""
        return self.tk.call('wm', 'iconname', self._w, newName)
def tkinter.Wm.wm_iconposition (   self,
  x = None,
  y = None 
)
Set the position of the icon of this widget to X and Y. Return
a tuple of the current values of X and X if None is given.

Definition at line 1569 of file __init__.py.

01569 
01570     def wm_iconposition(self, x=None, y=None):
01571         """Set the position of the icon of this widget to X and Y. Return
01572         a tuple of the current values of X and X if None is given."""
01573         return self._getints(self.tk.call(
            'wm', 'iconposition', self._w, x, y))

Here is the call graph for this function:

def tkinter.Wm.wm_iconwindow (   self,
  pathName = None 
)
Set widget PATHNAME to be displayed instead of icon. Return the current
value if None is given.

Definition at line 1575 of file __init__.py.

01575 
01576     def wm_iconwindow(self, pathName=None):
01577         """Set widget PATHNAME to be displayed instead of icon. Return the current
01578         value if None is given."""
        return self.tk.call('wm', 'iconwindow', self._w, pathName)
def tkinter.Wm.wm_maxsize (   self,
  width = None,
  height = None 
)
Set max WIDTH and HEIGHT for this widget. If the window is gridded
the values are given in grid units. Return the current values if None
is given.

Definition at line 1580 of file __init__.py.

01580 
01581     def wm_maxsize(self, width=None, height=None):
01582         """Set max WIDTH and HEIGHT for this widget. If the window is gridded
01583         the values are given in grid units. Return the current values if None
01584         is given."""
01585         return self._getints(self.tk.call(
            'wm', 'maxsize', self._w, width, height))

Here is the call graph for this function:

def tkinter.Wm.wm_minsize (   self,
  width = None,
  height = None 
)
Set min WIDTH and HEIGHT for this widget. If the window is gridded
the values are given in grid units. Return the current values if None
is given.

Definition at line 1587 of file __init__.py.

01587 
01588     def wm_minsize(self, width=None, height=None):
01589         """Set min WIDTH and HEIGHT for this widget. If the window is gridded
01590         the values are given in grid units. Return the current values if None
01591         is given."""
01592         return self._getints(self.tk.call(
            'wm', 'minsize', self._w, width, height))

Here is the call graph for this function:

def tkinter.Wm.wm_overrideredirect (   self,
  boolean = None 
)
Instruct the window manager to ignore this widget
if BOOLEAN is given with 1. Return the current value if None
is given.

Definition at line 1594 of file __init__.py.

01594 
01595     def wm_overrideredirect(self, boolean=None):
01596         """Instruct the window manager to ignore this widget
01597         if BOOLEAN is given with 1. Return the current value if None
01598         is given."""
01599         return self._getboolean(self.tk.call(
            'wm', 'overrideredirect', self._w, boolean))

Here is the call graph for this function:

def tkinter.Wm.wm_positionfrom (   self,
  who = None 
)
Instruct the window manager that the position of this widget shall
be defined by the user if WHO is "user", and by its own policy if WHO is
"program".

Definition at line 1601 of file __init__.py.

01601 
01602     def wm_positionfrom(self, who=None):
01603         """Instruct the window manager that the position of this widget shall
01604         be defined by the user if WHO is "user", and by its own policy if WHO is
01605         "program"."""
        return self.tk.call('wm', 'positionfrom', self._w, who)
def tkinter.Wm.wm_protocol (   self,
  name = None,
  func = None 
)
Bind function FUNC to command NAME for this widget.
Return the function bound to NAME if None is given. NAME could be
e.g. "WM_SAVE_YOURSELF" or "WM_DELETE_WINDOW".

Definition at line 1607 of file __init__.py.

01607 
01608     def wm_protocol(self, name=None, func=None):
01609         """Bind function FUNC to command NAME for this widget.
01610         Return the function bound to NAME if None is given. NAME could be
01611         e.g. "WM_SAVE_YOURSELF" or "WM_DELETE_WINDOW"."""
01612         if hasattr(func, '__call__'):
01613             command = self._register(func)
01614         else:
01615             command = func
01616         return self.tk.call(
            'wm', 'protocol', self._w, name, command)

Here is the call graph for this function:

Here is the caller graph for this function:

def tkinter.Wm.wm_resizable (   self,
  width = None,
  height = None 
)
Instruct the window manager whether this width can be resized
in WIDTH or HEIGHT. Both values are boolean values.

Definition at line 1618 of file __init__.py.

01618 
01619     def wm_resizable(self, width=None, height=None):
01620         """Instruct the window manager whether this width can be resized
01621         in WIDTH or HEIGHT. Both values are boolean values."""
        return self.tk.call('wm', 'resizable', self._w, width, height)
def tkinter.Wm.wm_sizefrom (   self,
  who = None 
)
Instruct the window manager that the size of this widget shall
be defined by the user if WHO is "user", and by its own policy if WHO is
"program".

Definition at line 1623 of file __init__.py.

01623 
01624     def wm_sizefrom(self, who=None):
01625         """Instruct the window manager that the size of this widget shall
01626         be defined by the user if WHO is "user", and by its own policy if WHO is
01627         "program"."""
        return self.tk.call('wm', 'sizefrom', self._w, who)
def tkinter.Wm.wm_state (   self,
  newstate = None 
)
Query or set the state of this widget as one of normal, icon,
iconic (see wm_iconwindow), withdrawn, or zoomed (Windows only).

Definition at line 1629 of file __init__.py.

01629 
01630     def wm_state(self, newstate=None):
01631         """Query or set the state of this widget as one of normal, icon,
01632         iconic (see wm_iconwindow), withdrawn, or zoomed (Windows only)."""
        return self.tk.call('wm', 'state', self._w, newstate)

Here is the caller graph for this function:

def tkinter.Wm.wm_title (   self,
  string = None 
)
Set the title of this widget.

Definition at line 1634 of file __init__.py.

01634 
01635     def wm_title(self, string=None):
01636         """Set the title of this widget."""
        return self.tk.call('wm', 'title', self._w, string)

Here is the caller graph for this function:

def tkinter.Wm.wm_transient (   self,
  master = None 
)
Instruct the window manager that this widget is transient
with regard to widget MASTER.

Definition at line 1638 of file __init__.py.

01638 
01639     def wm_transient(self, master=None):
01640         """Instruct the window manager that this widget is transient
01641         with regard to widget MASTER."""
        return self.tk.call('wm', 'transient', self._w, master)
def tkinter.Wm.wm_withdraw (   self)
Withdraw this widget from the screen such that it is unmapped
and forgotten by the window manager. Re-draw it with wm_deiconify.

Definition at line 1643 of file __init__.py.

01643 
01644     def wm_withdraw(self):
01645         """Withdraw this widget from the screen such that it is unmapped
01646         and forgotten by the window manager. Re-draw it with wm_deiconify."""
        return self.tk.call('wm', 'withdraw', self._w)

Here is the caller graph for this function:


Member Data Documentation

Definition at line 1461 of file __init__.py.

Definition at line 1489 of file __init__.py.

Definition at line 1498 of file __init__.py.

Definition at line 1504 of file __init__.py.

Definition at line 1509 of file __init__.py.

Definition at line 1515 of file __init__.py.

Definition at line 1519 of file __init__.py.

Definition at line 1524 of file __init__.py.

Definition at line 1535 of file __init__.py.

Definition at line 1540 of file __init__.py.

Definition at line 1554 of file __init__.py.

Definition at line 1558 of file __init__.py.

Definition at line 1563 of file __init__.py.

Definition at line 1568 of file __init__.py.

Definition at line 1574 of file __init__.py.

Definition at line 1579 of file __init__.py.

Definition at line 1586 of file __init__.py.

Definition at line 1593 of file __init__.py.

Definition at line 1600 of file __init__.py.

Definition at line 1606 of file __init__.py.

Definition at line 1617 of file __init__.py.

Definition at line 1622 of file __init__.py.

Definition at line 1628 of file __init__.py.

Definition at line 1633 of file __init__.py.

Definition at line 1637 of file __init__.py.

Definition at line 1642 of file __init__.py.

Definition at line 1647 of file __init__.py.


The documentation for this class was generated from the following file: