File tree Expand file tree Collapse file tree 1 file changed +25
-0
lines changed Expand file tree Collapse file tree 1 file changed +25
-0
lines changed Original file line number Diff line number Diff line change @@ -1655,6 +1655,31 @@ def plot_types(self):
1655
1655
"""
1656
1656
return self ._plot_types
1657
1657
1658
+ def set_plot_type (self , plot_type , type_value ):
1659
+ """ Sets the plot type.
1660
+
1661
+ By default, the following plot types are possible: *ctrlpts*, *evalpts*
1662
+
1663
+ By default, the following plot type values are possible:
1664
+
1665
+ * For control points (*ctrlpts*): points, quads
1666
+ * For surface points (*evalpts*): points, quads, triangles
1667
+
1668
+ :param plot_type: plot type
1669
+ :type plot_type: str
1670
+ :param type_value: type value
1671
+ :type type_value: str
1672
+ :return:
1673
+ """
1674
+ if not isinstance (plot_type , str ) or not isinstance (type_value , str ):
1675
+ raise TypeError ("Plot type and its value should be string type" )
1676
+
1677
+ if plot_type not in self ._plot_types .keys ():
1678
+ raise KeyError (plot_type + " is not a type. Possible types: " +
1679
+ ", " .join ([k for k in self ._plot_types .keys ()]))
1680
+
1681
+ self ._plot_types [plot_type ] = type_value
1682
+
1658
1683
def set_ctrlpts_offset (self , offset_value ):
1659
1684
""" Sets an offset for the control points grid plot.
1660
1685
You can’t perform that action at this time.
0 commit comments