Bugfix: Malformed tables.
All argument lists with `**Arguments:**`
This commit is contained in:
parent
2279775244
commit
2a13994a2a
@ -47,8 +47,8 @@ class ArrowItem(QtGui.QGraphicsPathItem):
|
||||
Changes the appearance of the arrow.
|
||||
All arguments are optional:
|
||||
|
||||
================= =================================================
|
||||
**Keyword Arguments:**
|
||||
====================== =================================================
|
||||
**Keyword**
|
||||
angle Orientation of the arrow in degrees. Default is
|
||||
0; arrow pointing to the left.
|
||||
headLen Length of the arrow head, from tip to base.
|
||||
@ -67,7 +67,7 @@ class ArrowItem(QtGui.QGraphicsPathItem):
|
||||
tailWidth Width of the tail. default=3
|
||||
pen The pen used to draw the outline of the arrow.
|
||||
brush The brush used to fill the arrow.
|
||||
================= =================================================
|
||||
====================== =================================================
|
||||
"""
|
||||
self.opts.update(opts)
|
||||
|
||||
|
@ -156,8 +156,8 @@ class AxisItem(GraphicsWidget):
|
||||
def setLabel(self, text=None, units=None, unitPrefix=None, **args):
|
||||
"""Set the text displayed adjacent to the axis.
|
||||
|
||||
============= =============================================================
|
||||
Arguments
|
||||
============== =============================================================
|
||||
**Arguments:**
|
||||
text The text (excluding units) to display on the label for this
|
||||
axis.
|
||||
units The units for this axis. Units should generally be given
|
||||
@ -166,7 +166,7 @@ class AxisItem(GraphicsWidget):
|
||||
range of data displayed.
|
||||
**args All extra keyword arguments become CSS style options for
|
||||
the <span> tag which will surround the axis label and units.
|
||||
============= =============================================================
|
||||
============== =============================================================
|
||||
|
||||
The final text generated for the label will look like::
|
||||
|
||||
|
@ -35,14 +35,14 @@ class TickSliderItem(GraphicsWidget):
|
||||
|
||||
def __init__(self, orientation='bottom', allowAdd=True, **kargs):
|
||||
"""
|
||||
============= =================================================================================
|
||||
============== =================================================================================
|
||||
**Arguments:**
|
||||
orientation Set the orientation of the gradient. Options are: 'left', 'right'
|
||||
'top', and 'bottom'.
|
||||
allowAdd Specifies whether ticks can be added to the item by the user.
|
||||
tickPen Default is white. Specifies the color of the outline of the ticks.
|
||||
Can be any of the valid arguments for :func:`mkPen <pyqtgraph.mkPen>`
|
||||
============= =================================================================================
|
||||
============== =================================================================================
|
||||
"""
|
||||
## public
|
||||
GraphicsWidget.__init__(self)
|
||||
@ -103,13 +103,13 @@ class TickSliderItem(GraphicsWidget):
|
||||
## public
|
||||
"""Set the orientation of the TickSliderItem.
|
||||
|
||||
============= ===================================================================
|
||||
============== ===================================================================
|
||||
**Arguments:**
|
||||
orientation Options are: 'left', 'right', 'top', 'bottom'
|
||||
The orientation option specifies which side of the slider the
|
||||
ticks are on, as well as whether the slider is vertical ('right'
|
||||
and 'left') or horizontal ('top' and 'bottom').
|
||||
============= ===================================================================
|
||||
============== ===================================================================
|
||||
"""
|
||||
self.orientation = orientation
|
||||
self.setMaxDim()
|
||||
@ -136,13 +136,13 @@ class TickSliderItem(GraphicsWidget):
|
||||
"""
|
||||
Add a tick to the item.
|
||||
|
||||
============= ==================================================================
|
||||
============== ==================================================================
|
||||
**Arguments:**
|
||||
x Position where tick should be added.
|
||||
color Color of added tick. If color is not specified, the color will be
|
||||
white.
|
||||
movable Specifies whether the tick is movable with the mouse.
|
||||
============= ==================================================================
|
||||
============== ==================================================================
|
||||
"""
|
||||
|
||||
if color is None:
|
||||
@ -265,14 +265,14 @@ class TickSliderItem(GraphicsWidget):
|
||||
def setTickColor(self, tick, color):
|
||||
"""Set the color of the specified tick.
|
||||
|
||||
============= ==================================================================
|
||||
============== ==================================================================
|
||||
**Arguments:**
|
||||
tick Can be either an integer corresponding to the index of the tick
|
||||
or a Tick object. Ex: if you had a slider with 3 ticks and you
|
||||
wanted to change the middle tick, the index would be 1.
|
||||
color The color to make the tick. Can be any argument that is valid for
|
||||
:func:`mkBrush <pyqtgraph.mkBrush>`
|
||||
============= ==================================================================
|
||||
============== ==================================================================
|
||||
"""
|
||||
tick = self.getTick(tick)
|
||||
tick.color = color
|
||||
@ -284,14 +284,14 @@ class TickSliderItem(GraphicsWidget):
|
||||
"""
|
||||
Set the position (along the slider) of the tick.
|
||||
|
||||
============= ==================================================================
|
||||
============== ==================================================================
|
||||
**Arguments:**
|
||||
tick Can be either an integer corresponding to the index of the tick
|
||||
or a Tick object. Ex: if you had a slider with 3 ticks and you
|
||||
wanted to change the middle tick, the index would be 1.
|
||||
val The desired position of the tick. If val is < 0, position will be
|
||||
set to 0. If val is > 1, position will be set to 1.
|
||||
============= ==================================================================
|
||||
============== ==================================================================
|
||||
"""
|
||||
tick = self.getTick(tick)
|
||||
val = min(max(0.0, val), 1.0)
|
||||
@ -305,12 +305,12 @@ class TickSliderItem(GraphicsWidget):
|
||||
## public
|
||||
"""Return the value (from 0.0 to 1.0) of the specified tick.
|
||||
|
||||
============= ==================================================================
|
||||
============== ==================================================================
|
||||
**Arguments:**
|
||||
tick Can be either an integer corresponding to the index of the tick
|
||||
or a Tick object. Ex: if you had a slider with 3 ticks and you
|
||||
wanted the value of the middle tick, the index would be 1.
|
||||
============= ==================================================================
|
||||
============== ==================================================================
|
||||
"""
|
||||
tick = self.getTick(tick)
|
||||
return self.ticks[tick]
|
||||
@ -319,11 +319,11 @@ class TickSliderItem(GraphicsWidget):
|
||||
## public
|
||||
"""Return the Tick object at the specified index.
|
||||
|
||||
============= ==================================================================
|
||||
============== ==================================================================
|
||||
**Arguments:**
|
||||
tick An integer corresponding to the index of the desired tick. If the
|
||||
argument is not an integer it will be returned unchanged.
|
||||
============= ==================================================================
|
||||
============== ==================================================================
|
||||
"""
|
||||
if type(tick) is int:
|
||||
tick = self.listTicks()[tick][0]
|
||||
@ -366,14 +366,14 @@ class GradientEditorItem(TickSliderItem):
|
||||
Create a new GradientEditorItem.
|
||||
All arguments are passed to :func:`TickSliderItem.__init__ <pyqtgraph.TickSliderItem.__init__>`
|
||||
|
||||
============= =================================================================================
|
||||
=============== =================================================================================
|
||||
**Arguments:**
|
||||
orientation Set the orientation of the gradient. Options are: 'left', 'right'
|
||||
'top', and 'bottom'.
|
||||
allowAdd Default is True. Specifies whether ticks can be added to the item.
|
||||
tickPen Default is white. Specifies the color of the outline of the ticks.
|
||||
Can be any of the valid arguments for :func:`mkPen <pyqtgraph.mkPen>`
|
||||
============= =================================================================================
|
||||
=============== =================================================================================
|
||||
"""
|
||||
self.currentTick = None
|
||||
self.currentTickColor = None
|
||||
@ -445,13 +445,13 @@ class GradientEditorItem(TickSliderItem):
|
||||
"""
|
||||
Set the orientation of the GradientEditorItem.
|
||||
|
||||
============= ===================================================================
|
||||
============== ===================================================================
|
||||
**Arguments:**
|
||||
orientation Options are: 'left', 'right', 'top', 'bottom'
|
||||
The orientation option specifies which side of the gradient the
|
||||
ticks are on, as well as whether the gradient is vertical ('right'
|
||||
and 'left') or horizontal ('top' and 'bottom').
|
||||
============= ===================================================================
|
||||
============== ===================================================================
|
||||
"""
|
||||
TickSliderItem.setOrientation(self, orientation)
|
||||
self.translate(0, self.rectSize)
|
||||
@ -588,11 +588,11 @@ class GradientEditorItem(TickSliderItem):
|
||||
"""
|
||||
Return a color for a given value.
|
||||
|
||||
============= ==================================================================
|
||||
============== ==================================================================
|
||||
**Arguments:**
|
||||
x Value (position on gradient) of requested color.
|
||||
toQColor If true, returns a QColor object, else returns a (r,g,b,a) tuple.
|
||||
============= ==================================================================
|
||||
============== ==================================================================
|
||||
"""
|
||||
ticks = self.listTicks()
|
||||
if x <= ticks[0][1]:
|
||||
@ -648,12 +648,12 @@ class GradientEditorItem(TickSliderItem):
|
||||
"""
|
||||
Return an RGB(A) lookup table (ndarray).
|
||||
|
||||
============= ============================================================================
|
||||
============== ============================================================================
|
||||
**Arguments:**
|
||||
nPts The number of points in the returned lookup table.
|
||||
alpha True, False, or None - Specifies whether or not alpha values are included
|
||||
in the table.If alpha is None, alpha will be automatically determined.
|
||||
============= ============================================================================
|
||||
============== ============================================================================
|
||||
"""
|
||||
if alpha is None:
|
||||
alpha = self.usesAlpha()
|
||||
@ -702,13 +702,13 @@ class GradientEditorItem(TickSliderItem):
|
||||
"""
|
||||
Add a tick to the gradient. Return the tick.
|
||||
|
||||
============= ==================================================================
|
||||
============== ==================================================================
|
||||
**Arguments:**
|
||||
x Position where tick should be added.
|
||||
color Color of added tick. If color is not specified, the color will be
|
||||
the color of the gradient at the specified position.
|
||||
movable Specifies whether the tick is movable with the mouse.
|
||||
============= ==================================================================
|
||||
============== ==================================================================
|
||||
"""
|
||||
|
||||
|
||||
@ -748,7 +748,7 @@ class GradientEditorItem(TickSliderItem):
|
||||
"""
|
||||
Restore the gradient specified in state.
|
||||
|
||||
============= ====================================================================
|
||||
============== ====================================================================
|
||||
**Arguments:**
|
||||
state A dictionary with same structure as those returned by
|
||||
:func:`saveState <pyqtgraph.GradientEditorItem.saveState>`
|
||||
@ -757,7 +757,7 @@ class GradientEditorItem(TickSliderItem):
|
||||
|
||||
- 'mode': hsv or rgb
|
||||
- 'ticks': a list of tuples (pos, (r,g,b,a))
|
||||
============= ====================================================================
|
||||
============== ====================================================================
|
||||
"""
|
||||
## public
|
||||
self.setColorMode(state['mode'])
|
||||
|
@ -28,8 +28,8 @@ class GraphItem(GraphicsObject):
|
||||
"""
|
||||
Change the data displayed by the graph.
|
||||
|
||||
============ =========================================================
|
||||
Arguments
|
||||
============== =========================================================
|
||||
**Arguments:**
|
||||
pos (N,2) array of the positions of each node in the graph.
|
||||
adj (M,2) array of connection data. Each row contains indexes
|
||||
of two nodes that are connected.
|
||||
@ -50,7 +50,7 @@ class GraphItem(GraphicsObject):
|
||||
:func:`ScatterPlotItem.setData() <pyqtgraph.ScatterPlotItem.setData>`
|
||||
to affect the appearance of nodes (symbol, size, brush,
|
||||
etc.)
|
||||
============ =========================================================
|
||||
============== =========================================================
|
||||
"""
|
||||
if 'adj' in kwds:
|
||||
self.adjacency = kwds.pop('adj')
|
||||
|
@ -28,7 +28,7 @@ class InfiniteLine(GraphicsObject):
|
||||
|
||||
def __init__(self, pos=None, angle=90, pen=None, movable=False, bounds=None):
|
||||
"""
|
||||
============= ==================================================================
|
||||
============== ==================================================================
|
||||
**Arguments:**
|
||||
pos Position of the line. This can be a QPointF or a single value for
|
||||
vertical/horizontal lines.
|
||||
|
@ -18,14 +18,14 @@ class IsocurveItem(GraphicsObject):
|
||||
"""
|
||||
Create a new isocurve item.
|
||||
|
||||
============= ===============================================================
|
||||
============== ===============================================================
|
||||
**Arguments:**
|
||||
data A 2-dimensional ndarray. Can be initialized as None, and set
|
||||
later using :func:`setData <pyqtgraph.IsocurveItem.setData>`
|
||||
level The cutoff value at which to draw the isocurve.
|
||||
pen The color of the curve item. Can be anything valid for
|
||||
:func:`mkPen <pyqtgraph.mkPen>`
|
||||
============= ===============================================================
|
||||
============== ===============================================================
|
||||
"""
|
||||
GraphicsObject.__init__(self)
|
||||
|
||||
@ -45,12 +45,12 @@ class IsocurveItem(GraphicsObject):
|
||||
"""
|
||||
Set the data/image to draw isocurves for.
|
||||
|
||||
============= ========================================================================
|
||||
============== ========================================================================
|
||||
**Arguments:**
|
||||
data A 2-dimensional ndarray.
|
||||
level The cutoff value at which to draw the curve. If level is not specified,
|
||||
the previously set level is used.
|
||||
============= ========================================================================
|
||||
============== ========================================================================
|
||||
"""
|
||||
if level is None:
|
||||
level = self.level
|
||||
|
@ -38,7 +38,7 @@ class LabelItem(GraphicsWidget, GraphicsWidgetAnchor):
|
||||
a CSS style string:
|
||||
|
||||
==================== ==============================
|
||||
**Style Arguments:**
|
||||
**Style**
|
||||
color (str) example: 'CCFF00'
|
||||
size (str) example: '8pt'
|
||||
bold (bool)
|
||||
|
@ -21,8 +21,8 @@ class LegendItem(GraphicsWidget, GraphicsWidgetAnchor):
|
||||
"""
|
||||
def __init__(self, size=None, offset=None):
|
||||
"""
|
||||
========== ===============================================================
|
||||
Arguments
|
||||
============== ===============================================================
|
||||
**Arguments:**
|
||||
size Specifies the fixed size (width, height) of the legend. If
|
||||
this argument is omitted, the legend will autimatically resize
|
||||
to fit its contents.
|
||||
@ -31,7 +31,7 @@ class LegendItem(GraphicsWidget, GraphicsWidgetAnchor):
|
||||
offset from the right or bottom. If offset is None, the
|
||||
legend must be anchored manually by calling anchor() or
|
||||
positioned by calling setPos().
|
||||
========== ===============================================================
|
||||
============== ===============================================================
|
||||
|
||||
"""
|
||||
|
||||
@ -61,14 +61,14 @@ class LegendItem(GraphicsWidget, GraphicsWidgetAnchor):
|
||||
"""
|
||||
Add a new entry to the legend.
|
||||
|
||||
=========== ========================================================
|
||||
Arguments
|
||||
============== ========================================================
|
||||
**Arguments:**
|
||||
item A PlotDataItem from which the line and point style
|
||||
of the item will be determined or an instance of
|
||||
ItemSample (or a subclass), allowing the item display
|
||||
to be customized.
|
||||
title The title to display for this item. Simple HTML allowed.
|
||||
=========== ========================================================
|
||||
============== ========================================================
|
||||
"""
|
||||
label = LabelItem(name)
|
||||
if isinstance(item, ItemSample):
|
||||
@ -85,10 +85,10 @@ class LegendItem(GraphicsWidget, GraphicsWidgetAnchor):
|
||||
"""
|
||||
Removes one item from the legend.
|
||||
|
||||
=========== ========================================================
|
||||
Arguments
|
||||
============== ========================================================
|
||||
**Arguments:**
|
||||
title The title displayed for this item.
|
||||
=========== ========================================================
|
||||
============== ========================================================
|
||||
"""
|
||||
# Thanks, Ulrich!
|
||||
# cycle for a match
|
||||
|
@ -30,7 +30,7 @@ class LinearRegionItem(UIGraphicsItem):
|
||||
def __init__(self, values=[0,1], orientation=None, brush=None, movable=True, bounds=None):
|
||||
"""Create a new LinearRegionItem.
|
||||
|
||||
============= =====================================================================
|
||||
============== =====================================================================
|
||||
**Arguments:**
|
||||
values A list of the positions of the lines in the region. These are not
|
||||
limits; limits can be set by specifying bounds.
|
||||
|
@ -291,8 +291,8 @@ class PlotDataItem(GraphicsObject):
|
||||
Set the downsampling mode of this item. Downsampling reduces the number
|
||||
of samples drawn to increase performance.
|
||||
|
||||
=========== =================================================================
|
||||
Arguments
|
||||
============== =================================================================
|
||||
**Arguments:**
|
||||
ds (int) Reduce visible plot samples by this factor. To disable,
|
||||
set ds=1.
|
||||
auto (bool) If True, automatically pick *ds* based on visible range
|
||||
@ -302,7 +302,7 @@ class PlotDataItem(GraphicsObject):
|
||||
'peak': Downsample by drawing a saw wave that follows the min
|
||||
and max of the original data. This method produces the best
|
||||
visual representation of the data but is slower.
|
||||
=========== =================================================================
|
||||
============== =================================================================
|
||||
"""
|
||||
changed = False
|
||||
if ds is not None:
|
||||
|
@ -931,8 +931,8 @@ class PlotItem(GraphicsWidget):
|
||||
def setDownsampling(self, ds=None, auto=None, mode=None):
|
||||
"""Change the default downsampling mode for all PlotDataItems managed by this plot.
|
||||
|
||||
=========== =================================================================
|
||||
Arguments
|
||||
============== =================================================================
|
||||
**Arguments:**
|
||||
ds (int) Reduce visible plot samples by this factor, or
|
||||
(bool) To enable/disable downsampling without changing the value.
|
||||
auto (bool) If True, automatically pick *ds* based on visible range
|
||||
@ -942,7 +942,7 @@ class PlotItem(GraphicsWidget):
|
||||
'peak': Downsample by drawing a saw wave that follows the min
|
||||
and max of the original data. This method produces the best
|
||||
visual representation of the data but is slower.
|
||||
=========== =================================================================
|
||||
============= =================================================================
|
||||
"""
|
||||
if ds is not None:
|
||||
if ds is False:
|
||||
@ -1113,7 +1113,7 @@ class PlotItem(GraphicsWidget):
|
||||
"""
|
||||
Set the label for an axis. Basic HTML formatting is allowed.
|
||||
|
||||
============= =================================================================
|
||||
============== =================================================================
|
||||
**Arguments:**
|
||||
axis must be one of 'left', 'bottom', 'right', or 'top'
|
||||
text text to display along the axis. HTML allowed.
|
||||
@ -1121,7 +1121,7 @@ class PlotItem(GraphicsWidget):
|
||||
then an SI prefix will be automatically appended
|
||||
and the axis values will be scaled accordingly.
|
||||
(ie, use 'V' instead of 'mV'; 'm' will be added automatically)
|
||||
============= =================================================================
|
||||
============== =================================================================
|
||||
"""
|
||||
self.getAxis(axis).setLabel(text=text, units=units, **args)
|
||||
self.showAxis(axis)
|
||||
|
@ -253,13 +253,13 @@ class ScatterPlotItem(GraphicsObject):
|
||||
|
||||
def setData(self, *args, **kargs):
|
||||
"""
|
||||
**Ordered Arguments:**
|
||||
**Ordered**
|
||||
|
||||
* If there is only one unnamed argument, it will be interpreted like the 'spots' argument.
|
||||
* If there are two unnamed arguments, they will be interpreted as sequences of x and y values.
|
||||
|
||||
====================== ===============================================================================================
|
||||
**Keyword Arguments:**
|
||||
**Keyword**
|
||||
*spots* Optional list of dicts. Each dict specifies parameters for a single spot:
|
||||
{'pos': (x,y), 'size', 'pen', 'brush', 'symbol'}. This is just an alternate method
|
||||
of passing in data for the corresponding arguments.
|
||||
|
@ -9,7 +9,7 @@ class TextItem(UIGraphicsItem):
|
||||
"""
|
||||
def __init__(self, text='', color=(200,200,200), html=None, anchor=(0,0), border=None, fill=None, angle=0):
|
||||
"""
|
||||
=========== =================================================================================
|
||||
============== =================================================================================
|
||||
**Arguments:**
|
||||
*text* The text to display
|
||||
*color* The color of the text (any format accepted by pg.mkColor)
|
||||
|
@ -19,7 +19,7 @@ class VTickGroup(UIGraphicsItem):
|
||||
"""
|
||||
def __init__(self, xvals=None, yrange=None, pen=None):
|
||||
"""
|
||||
============= ===================================================================
|
||||
============== ===================================================================
|
||||
**Arguments:**
|
||||
xvals A list of x values (in data coordinates) at which to draw ticks.
|
||||
yrange A list of [low, high] limits for the tick. 0 is the bottom of
|
||||
@ -27,7 +27,7 @@ class VTickGroup(UIGraphicsItem):
|
||||
fifth of the view.
|
||||
pen The pen to use for drawing ticks. Default is grey. Can be specified
|
||||
as any argument valid for :func:`mkPen<pyqtgraph.mkPen>`
|
||||
============= ===================================================================
|
||||
============== ===================================================================
|
||||
"""
|
||||
if yrange is None:
|
||||
yrange = [0, 1]
|
||||
|
@ -71,7 +71,7 @@ class ViewBox(GraphicsWidget):
|
||||
|
||||
def __init__(self, parent=None, border=None, lockAspect=False, enableMouse=True, invertY=False, enableMenu=True, name=None):
|
||||
"""
|
||||
============= =============================================================
|
||||
============== =============================================================
|
||||
**Arguments:**
|
||||
*parent* (QGraphicsWidget) Optional parent widget
|
||||
*border* (QPen) Do draw a border around the view, give any
|
||||
@ -80,7 +80,7 @@ class ViewBox(GraphicsWidget):
|
||||
coorinates to. (or False to allow the ratio to change)
|
||||
*enableMouse* (bool) Whether mouse can be used to scale/pan the view
|
||||
*invertY* (bool) See :func:`invertY <pyqtgraph.ViewBox.invertY>`
|
||||
============= =============================================================
|
||||
============== =============================================================
|
||||
"""
|
||||
|
||||
|
||||
@ -562,14 +562,14 @@ class ViewBox(GraphicsWidget):
|
||||
Note that this is not the same as enableAutoRange, which causes the view to
|
||||
automatically auto-range whenever its contents are changed.
|
||||
|
||||
=========== ============================================================
|
||||
Arguments
|
||||
============== ============================================================
|
||||
**Arguments:**
|
||||
padding The fraction of the total data range to add on to the final
|
||||
visible range. By default, this value is set between 0.02
|
||||
and 0.1 depending on the size of the ViewBox.
|
||||
items If specified, this is a list of items to consider when
|
||||
determining the visible range.
|
||||
=========== ============================================================
|
||||
============== ============================================================
|
||||
"""
|
||||
if item is None:
|
||||
bounds = self.childrenBoundingRect(items=items)
|
||||
|
@ -38,7 +38,7 @@ class Process(RemoteEventHandler):
|
||||
|
||||
def __init__(self, name=None, target=None, executable=None, copySysPath=True, debug=False, timeout=20, wrapStdout=None):
|
||||
"""
|
||||
============ =============================================================
|
||||
============== =============================================================
|
||||
**Arguments:**
|
||||
name Optional name for this process used when printing messages
|
||||
from the remote process.
|
||||
@ -56,7 +56,7 @@ class Process(RemoteEventHandler):
|
||||
for a python bug: http://bugs.python.org/issue3905
|
||||
but has the side effect that child output is significantly
|
||||
delayed relative to the parent output.
|
||||
============ =============================================================
|
||||
============== =============================================================
|
||||
"""
|
||||
if target is None:
|
||||
target = startEventLoop
|
||||
|
@ -299,7 +299,7 @@ class RemoteEventHandler(object):
|
||||
(The docstring has information that is nevertheless useful to the programmer
|
||||
as it describes the internal protocol used to communicate between processes)
|
||||
|
||||
========== ====================================================================
|
||||
============== ====================================================================
|
||||
**Arguments:**
|
||||
request String describing the type of request being sent (see below)
|
||||
reqId Integer uniquely linking a result back to the request that generated
|
||||
@ -315,7 +315,7 @@ class RemoteEventHandler(object):
|
||||
byteData If specified, this is a list of objects to be sent as byte messages
|
||||
to the remote process.
|
||||
This is used to send large arrays without the cost of pickling.
|
||||
========== ====================================================================
|
||||
============== ====================================================================
|
||||
|
||||
Description of request strings and options allowed for each:
|
||||
|
||||
|
@ -23,8 +23,8 @@ class MeshData(object):
|
||||
|
||||
def __init__(self, vertexes=None, faces=None, edges=None, vertexColors=None, faceColors=None):
|
||||
"""
|
||||
============= =====================================================
|
||||
Arguments
|
||||
============== =====================================================
|
||||
**Arguments:**
|
||||
vertexes (Nv, 3) array of vertex coordinates.
|
||||
If faces is not specified, then this will instead be
|
||||
interpreted as (Nf, 3, 3) array of coordinates.
|
||||
@ -34,7 +34,7 @@ class MeshData(object):
|
||||
If faces is not specified, then this will instead be
|
||||
interpreted as (Nf, 3, 4) array of colors.
|
||||
faceColors (Nf, 4) array of face colors.
|
||||
============= =====================================================
|
||||
============== =====================================================
|
||||
|
||||
All arguments are optional.
|
||||
"""
|
||||
|
@ -19,7 +19,7 @@ class GLMeshItem(GLGraphicsItem):
|
||||
def __init__(self, **kwds):
|
||||
"""
|
||||
============== =====================================================
|
||||
Arguments
|
||||
**Arguments:**
|
||||
meshdata MeshData object from which to determine geometry for
|
||||
this item.
|
||||
color Default face color used if no vertex or face colors
|
||||
|
@ -36,14 +36,14 @@ class GLSurfacePlotItem(GLMeshItem):
|
||||
"""
|
||||
Update the data in this surface plot.
|
||||
|
||||
========== =====================================================================
|
||||
Arguments
|
||||
============== =====================================================================
|
||||
**Arguments:**
|
||||
x,y 1D arrays of values specifying the x,y positions of vertexes in the
|
||||
grid. If these are omitted, then the values will be assumed to be
|
||||
integers.
|
||||
z 2D array of height values for each grid vertex.
|
||||
colors (width, height, 4) array of vertex colors.
|
||||
========== =====================================================================
|
||||
============== =====================================================================
|
||||
|
||||
All arguments are optional.
|
||||
|
||||
|
@ -108,7 +108,7 @@ class Parameter(QtCore.QObject):
|
||||
by most Parameter subclasses.
|
||||
|
||||
======================= =========================================================
|
||||
**Keyword Arguments:**
|
||||
**Keyword**
|
||||
name The name to give this Parameter. This is the name that
|
||||
will appear in the left-most column of a ParameterTree
|
||||
for this Parameter.
|
||||
@ -675,13 +675,13 @@ class Parameter(QtCore.QObject):
|
||||
"""
|
||||
Called when the state of any sub-parameter has changed.
|
||||
|
||||
========== ================================================================
|
||||
Arguments:
|
||||
============== ================================================================
|
||||
**Arguments:**
|
||||
param The immediate child whose tree state has changed.
|
||||
note that the change may have originated from a grandchild.
|
||||
changes List of tuples describing all changes that have been made
|
||||
in this event: (param, changeDescr, data)
|
||||
========== ================================================================
|
||||
============== ================================================================
|
||||
|
||||
This function can be extended to react to tree state changes.
|
||||
"""
|
||||
|
@ -86,14 +86,14 @@ class ColorMapParameter(ptree.types.GroupParameter):
|
||||
"""
|
||||
Return an array of colors corresponding to *data*.
|
||||
|
||||
========= =================================================================
|
||||
Arguments
|
||||
============== =================================================================
|
||||
**Arguments:**
|
||||
data A numpy record array where the fields in data.dtype match those
|
||||
defined by a prior call to setFields().
|
||||
mode Either 'byte' or 'float'. For 'byte', the method returns an array
|
||||
of dtype ubyte with values scaled 0-255. For 'float', colors are
|
||||
returned as 0.0-1.0 float values.
|
||||
========= =================================================================
|
||||
============== =================================================================
|
||||
"""
|
||||
colors = np.zeros((len(data),4))
|
||||
for item in self.children():
|
||||
|
@ -16,8 +16,8 @@ class ValueLabel(QtGui.QLabel):
|
||||
|
||||
def __init__(self, parent=None, suffix='', siPrefix=False, averageTime=0, formatStr=None):
|
||||
"""
|
||||
============ ==================================================================================
|
||||
Arguments
|
||||
============== ==================================================================================
|
||||
**Arguments:**
|
||||
suffix (str or None) The suffix to place after the value
|
||||
siPrefix (bool) Whether to add an SI prefix to the units and display a scaled value
|
||||
averageTime (float) The length of time in seconds to average values. If this value
|
||||
@ -27,7 +27,7 @@ class ValueLabel(QtGui.QLabel):
|
||||
will be generated by calling formatStr.format(value=, avgValue=, suffix=)
|
||||
(see Python documentation on str.format)
|
||||
This option is not compatible with siPrefix
|
||||
============ ==================================================================================
|
||||
============== ==================================================================================
|
||||
"""
|
||||
QtGui.QLabel.__init__(self, parent)
|
||||
self.values = []
|
||||
|
Loading…
Reference in New Issue
Block a user