Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'source/blender/python/api2_2x/doc/Draw.py')
-rw-r--r--source/blender/python/api2_2x/doc/Draw.py8
1 files changed, 5 insertions, 3 deletions
diff --git a/source/blender/python/api2_2x/doc/Draw.py b/source/blender/python/api2_2x/doc/Draw.py
index 97e22797902..127f37bfbad 100644
--- a/source/blender/python/api2_2x/doc/Draw.py
+++ b/source/blender/python/api2_2x/doc/Draw.py
@@ -235,19 +235,21 @@ def EndAlign():
Use after BeginAlign() to stop aligning the buttons (button layout only).
"""
-def UIBlock(draw):
+def UIBlock(draw, mouse_exit=1):
"""
This function creates a popup area where buttons, labels, sliders etc can be drawn.
+ @type mouse_exit: int
+ @param mouse_exit: When zero the popup wont close when the mouse moves away from the popup.
@type draw: function
@param draw: A function to draw to the popup area, taking no arguments: draw().
@note: The size of the popup will expand to fit the bounds of the buttons created in the draw function.
- @note: Be sure to use the mouse coordinates to position the buttons under the mouse,
+ @note: If mouse_exit is nonzero be sure to use the mouse coordinates if to position the buttons under the mouse,
so the popup dosn't exit as soon as it opens.
The coordinates for buttons start 0,0 at the bottom left hand side of the screen.
@note: Within this popup, Redraw events and the registered button callback will not work.
- For buttons to run events, use per button callbacks.
+ For buttons to run events, use per button callbacks instead.
@note: OpenGL drawing functions wont work within this popup, for text use L{Label} rather then L{Text}
@warning: L{Menu} will not work properly within a UIBlock, this is a limitation with blenders user interface internals.
"""