Changeset 2860 for trunk/python


Ignore:
Timestamp:
10/10/13 13:43:31 (11 years ago)
Author:
WataruKawasaki
Message:

New Development: No

JIRA Issue: No

Ready for Test: Yes

Interface Changes: No

What Interface Changed:

Test Programs:

Put in Release Notes: No

Module(s): sd

Description: bugfix in sd.plotter2.get_linestyleindex() and minor clean-up


File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/python/plotter2.py

    r2830 r2860  
    9393    def set_range(self, xmin, xmax, ymin, ymax, vpid=None):
    9494        """\
    95         set 2D range of area to be displayed in a viewport.
     95        set 2D range to be displayed in the specified viewport.
    9696        by default, the display range is set automatically.
    9797
     
    109109    def set_xrange(self, xmin, xmax, vpid=None):
    110110        """\
    111         set x range of area to be displayed in a viewport.
     111        set x range to be displayed in the specified viewport.
    112112        by default, the display range is set automatically.
    113113
     
    123123    def set_yrange(self, ymin, ymax, vpid=None):
    124124        """\
    125         set y range of area to be displayed in a viewport.
     125        set y range to be displayed in the specified viewport.
    126126        by default, the display range is set automatically.
    127127
     
    137137    def get_xrange(self, vpid=None):
    138138        """\
    139         returns x range of display area of the specified viewport in
    140         a shape of (xmin, xmax).
     139        returns x range of displayed region of the specified viewport
     140        as a list of [xmin, xmax].
    141141
    142142        Parameter:
     
    149149    def get_yrange(self, vpid=None):
    150150        """\
    151         returns y range of display area of the specified viewport in
    152         a shape of (ymin, ymax).
     151        returns y range of displayed region in the specified viewport
     152        as a list of [ymin, ymax].
    153153
    154154        Parameter:
     
    161161    def set_autorange(self, vpid=None):
    162162        """\
    163         set 2D range of display area of the specified viewport to be
    164         automatic depending on the given data.
    165         the x range will be the exact range of the x values of data,
    166         whereas y range has a margin of 10% of the range of y values of data.
     163        set the 2-Dimensional range of displayed area of the specified
     164        viewport to automatically enclose the given data.
     165        the x range will be from the minimum up to the maximum value
     166        of the given x values, whereas y range has margins of 10% of
     167        the y value range both at the top and the bottom sides.
    167168
    168169        Parameter:
     
    175176    def set_xautorange(self, vpid=None):
    176177        """\
    177         set x range of display area of the specified viewport to be
    178         automatic depending on the given data.
    179         the x range will be the exact range of the x values of data,
     178        set x range of displayed area of the specified viewport to
     179        automatically enclose the given data with no margins.
    180180
    181181        Parameter:
     
    188188    def set_yautorange(self, vpid=None):
    189189        """\
    190         set y range of display area of the specified viewport to be
    191         automatic depending on the given data.
    192         the y range has a margin of 10% of the range of y values of data.
     190        set y range of displayed area of the specified viewport to
     191        automatically enclose the given data with margins of 10% of
     192        the y value range both at the top and the bottom sides.
    193193
    194194        Parameter:
     
    341341
    342342        Parameters:
    343             color: line color specified by color name. available colors
    344                    can be listed via list_colornames().
    345             width: line width. default is 1.
    346             style: line style. available styles can be listed via
    347                    list_linestyles().
    348             vpid:   viewport id. when not given, the last viewport
    349                     will be the target.
    350             dataid: dataset id. when not given, the last dataset used.
     343            color:  line color specified by color name. available colors
     344                    can be listed via list_colornames().
     345            width:  line width. default is 1.
     346            style:  line style. available styles can be listed via
     347                    list_linestyles().
     348            vpid:   viewport id. when not given, the last viewport
     349                    will be the target of operation.
     350            dataid: dataset id. when not given, the last dataset for the
     351                    specified viewport is the target.
    351352        """
    352353        if width  is None: width  = 1
     
    477478                   default is the center of x axis.
    478479            posy:  y position of label string.
    479             vpid:   viewport id. when not given, the last viewport
    480                     will be the target.
     480            vpid:  viewport id. when not given, the last viewport
     481                   will be the target.
    481482        """
    482483        if style is None: style = ""
     
    642643        """
    643644        style = fstyle.strip().lower()
    644         if style == "solid":        idx = 1
    645         if style == "outline":      idx = 2
    646         if style == "hatched":      idx = 3
    647         if style == "crosshatched": idx = 4
     645        if style == "solid":               idx = 1
     646        if style == "dashed":              idx = 2
     647        if style == "dash-dotted":         idx = 3
     648        if style == "dotted":              idx = 4
     649        if style == "dash-dot-dot-dotted": idx = 5
    648650       
    649651        return idx
Note: See TracChangeset for help on using the changeset viewer.