.. wxPython Phoenix documentation This file was generated by Phoenix's sphinx generator and associated tools, do not edit by hand. Copyright: (c) 2011-2020 by Total Control Software License: wxWindows License .. include:: headings.inc .. currentmodule:: wx.lib.ogl.composit .. highlight:: python .. _wx.lib.ogl.composit.DivisionShape: ========================================================================================================================================== |phoenix_title| **wx.lib.ogl.composit.DivisionShape** ========================================================================================================================================== A :class:`DivisionShape` class is a composite with special properties, to be used for containment. It's a subdivision of a container. A containing node image consists of a composite with a main child shape such as rounded rectangle, plus a list of division objects. It needs to be a composite because a division contains pieces of diagram. .. note:: A container has at least one wxDivisionShape for consistency. This can be subdivided, so it turns into two objects, then each of these can be subdivided, etc. | |class_hierarchy| Class Hierarchy ================================= .. raw:: html
Inheritance diagram for class DivisionShape:
| |super_classes| Known Superclasses ================================== :class:`wx.lib.ogl.composit.CompositeShape` | |method_summary| Methods Summary ================================ ================================================================================ ================================================================================ :meth:`~wx.lib.ogl.composit.DivisionShape.__init__` Default class constructor. :meth:`~wx.lib.ogl.composit.DivisionShape.AdjustLeft` Adjust a side. :meth:`~wx.lib.ogl.composit.DivisionShape.AdjustRight` Adjust a side. :meth:`~wx.lib.ogl.composit.DivisionShape.AdjustTop` Adjust a side. :meth:`~wx.lib.ogl.composit.DivisionShape.CalculateSize` not implemented??? :meth:`~wx.lib.ogl.composit.DivisionShape.Divide` Divide this division into two further divisions. :meth:`~wx.lib.ogl.composit.DivisionShape.EditEdge` :meth:`~wx.lib.ogl.composit.DivisionShape.GetBottomSide` Return the division on the bottom side of this division. :meth:`~wx.lib.ogl.composit.DivisionShape.GetHandleSide` Return the side which the handle appears on. :meth:`~wx.lib.ogl.composit.DivisionShape.GetLeftSide` Return the division on the left side of this division. :meth:`~wx.lib.ogl.composit.DivisionShape.GetLeftSideColour` Return the colour used for drawing the left side of the division. :meth:`~wx.lib.ogl.composit.DivisionShape.GetLeftSidePen` Return the pen used for drawing the left side of the division. :meth:`~wx.lib.ogl.composit.DivisionShape.GetLeftSideStyle` Return the style used for the left side of the division. :meth:`~wx.lib.ogl.composit.DivisionShape.GetRightSide` Return the division on the right side of this division. :meth:`~wx.lib.ogl.composit.DivisionShape.GetTopSide` Return the division on the top side of this division. :meth:`~wx.lib.ogl.composit.DivisionShape.GetTopSideColour` Return the colour used for drawing the top side of the division. :meth:`~wx.lib.ogl.composit.DivisionShape.GetTopSidePen` Return the pen used for drawing the top side of the division. :meth:`~wx.lib.ogl.composit.DivisionShape.GetTopSideStyle` Return the style used for the top side of the division. :meth:`~wx.lib.ogl.composit.DivisionShape.MakeControlPoints` Make control points. :meth:`~wx.lib.ogl.composit.DivisionShape.MakeMandatoryControlPoints` Make mandatory control points. :meth:`~wx.lib.ogl.composit.DivisionShape.OnBeginDragLeft` The begin drag left handler. :meth:`~wx.lib.ogl.composit.DivisionShape.OnDragLeft` The drag left handler. :meth:`~wx.lib.ogl.composit.DivisionShape.OnDraw` The draw handler. :meth:`~wx.lib.ogl.composit.DivisionShape.OnDrawContents` The draw contents handler. :meth:`~wx.lib.ogl.composit.DivisionShape.OnEndDragLeft` The end drag left handler. :meth:`~wx.lib.ogl.composit.DivisionShape.OnMovePre` The move 'pre' handler. :meth:`~wx.lib.ogl.composit.DivisionShape.OnRightClick` The right click handler. :meth:`~wx.lib.ogl.composit.DivisionShape.PopupMenu` Popup menu handler. :meth:`~wx.lib.ogl.composit.DivisionShape.ResetControlPoints` Reset control points. :meth:`~wx.lib.ogl.composit.DivisionShape.ResetMandatoryControlPoints` Reset mandatory control points. :meth:`~wx.lib.ogl.composit.DivisionShape.ResizeAdjoining` Resize adjoining divisions at the given side. :meth:`~wx.lib.ogl.composit.DivisionShape.SetBottomSide` Set the the division on the bottom side of this division. :meth:`~wx.lib.ogl.composit.DivisionShape.SetHandleSide` Sets the side which the handle appears on. :meth:`~wx.lib.ogl.composit.DivisionShape.SetLeftSide` Set the the division on the left side of this division. :meth:`~wx.lib.ogl.composit.DivisionShape.SetLeftSideColour` Set the colour for drawing the left side of the division. :meth:`~wx.lib.ogl.composit.DivisionShape.SetLeftSidePen` Set the colour for drawing the left side of the division. :meth:`~wx.lib.ogl.composit.DivisionShape.SetLeftSideStyle` Set the left side style. :meth:`~wx.lib.ogl.composit.DivisionShape.SetRightSide` Set the the division on the right side of this division. :meth:`~wx.lib.ogl.composit.DivisionShape.SetSize` Set the size. :meth:`~wx.lib.ogl.composit.DivisionShape.SetTopSide` Set the the division on the top side of this division. :meth:`~wx.lib.ogl.composit.DivisionShape.SetTopSideColour` Set the colour for drawing the top side of the division. :meth:`~wx.lib.ogl.composit.DivisionShape.SetTopSidePen` Set the colour for drawing the top side of the division. :meth:`~wx.lib.ogl.composit.DivisionShape.SetTopSideStyle` Set the top side style. ================================================================================ ================================================================================ | |api| Class API =============== .. class:: DivisionShape(CompositeShape) A :class:`DivisionShape` class is a composite with special properties, to be used for containment. It's a subdivision of a container. A containing node image consists of a composite with a main child shape such as rounded rectangle, plus a list of division objects. It needs to be a composite because a division contains pieces of diagram. .. note:: A container has at least one wxDivisionShape for consistency. This can be subdivided, so it turns into two objects, then each of these can be subdivided, etc. .. method:: __init__(self) Default class constructor. .. method:: AdjustLeft(self, left, test) Adjust a side. :param `left`: desired left position ??? :param `test`: if `True` just a test :returns: `False` if it's not physically possible to adjust it to this point. .. method:: AdjustRight(self, right, test) Adjust a side. :param `right`: desired right position ??? :param `test`: if `True` just a test :returns: `False` if it's not physically possible to adjust it to this point. .. method:: AdjustTop(self, top, test) Adjust a side. :param `top`: desired top position ??? :param `test`: if `True` just a test :returns: `False` if it's not physically possible to adjust it to this point. .. method:: CalculateSize(self) not implemented??? .. method:: Divide(self, direction) Divide this division into two further divisions. :param `direction`: `wx.HORIZONTAL` for horizontal or `wx.VERTICAL` for vertical division. .. method:: EditEdge(self, side) .. method:: GetBottomSide(self) Return the division on the bottom side of this division. .. method:: GetHandleSide(self) Return the side which the handle appears on. .. method:: GetLeftSide(self) Return the division on the left side of this division. .. method:: GetLeftSideColour(self) Return the colour used for drawing the left side of the division. .. method:: GetLeftSidePen(self) Return the pen used for drawing the left side of the division. .. method:: GetLeftSideStyle(self) Return the style used for the left side of the division. .. method:: GetRightSide(self) Return the division on the right side of this division. .. method:: GetTopSide(self) Return the division on the top side of this division. .. method:: GetTopSideColour(self) Return the colour used for drawing the top side of the division. .. method:: GetTopSidePen(self) Return the pen used for drawing the top side of the division. .. method:: GetTopSideStyle(self) Return the style used for the top side of the division. .. method:: MakeControlPoints(self) Make control points. .. method:: MakeMandatoryControlPoints(self) Make mandatory control points. .. method:: OnBeginDragLeft(self, x, y, keys = 0, attachment = 0) The begin drag left handler. .. method:: OnDragLeft(self, draw, x, y, keys = 0, attachment = 0) The drag left handler. .. method:: OnDraw(self, dc) The draw handler. .. method:: OnDrawContents(self, dc) The draw contents handler. .. method:: OnEndDragLeft(self, x, y, keys = 0, attachment = 0) The end drag left handler. .. method:: OnMovePre(self, dc, x, y, oldx, oldy, display = True) The move 'pre' handler. .. method:: OnRightClick(self, x, y, keys = 0, attachment = 0) The right click handler. .. method:: PopupMenu(self, x, y) Popup menu handler. .. method:: ResetControlPoints(self) Reset control points. .. method:: ResetMandatoryControlPoints(self) Reset mandatory control points. .. method:: ResizeAdjoining(self, side, newPos, test) Resize adjoining divisions at the given side. :param `side`: can be one of ======================= ======================= Side option Description ======================= ======================= `DIVISION_SIDE_NONE` no side `DIVISION_SIDE_LEFT` Left side `DIVISION_SIDE_TOP` Top side `DIVISION_SIDE_RIGHT` Right side `DIVISION_SIDE_BOTTOM` Bottom side ======================= ======================= :param `newPos`: new position :param `test`: if `True`, just see whether it's possible for each adjoining region, returning `False` if it's not. .. method:: SetBottomSide(self, shape) Set the the division on the bottom side of this division. .. method:: SetHandleSide(self, side) Sets the side which the handle appears on. :param `side`: Either DIVISION_SIDE_LEFT or DIVISION_SIDE_TOP. .. method:: SetLeftSide(self, shape) Set the the division on the left side of this division. .. method:: SetLeftSideColour(self, colour) Set the colour for drawing the left side of the division. .. method:: SetLeftSidePen(self, pen) Set the colour for drawing the left side of the division. .. method:: SetLeftSideStyle(self, style) Set the left side style. :param `style`: valid values ??? .. method:: SetRightSide(self, shape) Set the the division on the right side of this division. .. method:: SetSize(self, w, h, recursive = True) Set the size. :param `w`: the width :param `h`: the height :param `recursive`: `True` recurse all children .. method:: SetTopSide(self, shape) Set the the division on the top side of this division. .. method:: SetTopSideColour(self, colour) Set the colour for drawing the top side of the division. .. method:: SetTopSidePen(self, pen) Set the colour for drawing the top side of the division. .. method:: SetTopSideStyle(self, style) Set the top side style. :param `style`: valid values ???