@@ -26,8 +26,8 @@ def get_tikz_code(
26
26
tex_relative_path_to_data = None ,
27
27
strict = False ,
28
28
wrap = True ,
29
- extra_axis_opt = None ,
30
- extra_picture_opt = None ,
29
+ extra_axis_parameters = set () ,
30
+ extra_tikzpicture_parameters = set () ,
31
31
dpi = None ,
32
32
show_info = True
33
33
):
@@ -84,13 +84,13 @@ def get_tikz_code(
84
84
Default is ``True``.
85
85
:type wrap: bool
86
86
87
- :param extra_axis_opt : Extra axis options to be passed (as a set) to pgfplots.
87
+ :param extra_axis_parameters : Extra axis options to be passed (as a set) to pgfplots.
88
88
Default is ``None``.
89
- :type extra_axis_opt : a set of strings for the pfgplots axes.
89
+ :type extra_axis_parameters : a set of strings for the pfgplots axes.
90
90
91
- :param extra_picture_opt : Extra tikzpicture options to be passed (as a set) to pgfplots.
92
- Default is ``None``.
93
- :type extra_picture_opt : a set of strings for the pfgplots tikzpicture.
91
+ :param extra_tikzpicture_parameters : Extra tikzpicture options to be passed (as a set) to pgfplots.
92
+
93
+ :type extra_tikzpicture_parameters : a set of strings for the pfgplots tikzpicture.
94
94
95
95
:param dpi: The resolution in dots per inch of the rendered image in case
96
96
of QuadMesh plots. If ``None`` it will default to the value
@@ -122,19 +122,15 @@ def get_tikz_code(
122
122
data ['pgfplots libs' ] = set ()
123
123
data ['font size' ] = textsize
124
124
data ['custom colors' ] = {}
125
+ data ['extra tikzpicture parameters' ] = extra_tikzpicture_parameters
125
126
# rectangle_legends is used to keep track of which rectangles have already
126
127
# had \addlegendimage added. There should be only one \addlegenimage per
127
128
# bar chart data series.
128
129
data ['rectangle_legends' ] = set ()
129
- if extra_axis_opt :
130
- data ['extra axis options [base]' ] = extra_axis_opt .copy ()
131
- else :
132
- data ['extra axis options [base]' ] = set ()
133
-
134
- if extra_picture_opt :
135
- data ['extra picture options' ] = extra_picture_opt .copy ()
136
- else :
137
- data ['extra picture options' ] = set ()
130
+ #if extra_axis_parameters:
131
+ data ['extra axis options [base]' ] = extra_axis_parameters .copy ()
132
+ #else:
133
+ # data['extra axis options [base]'] = set()
138
134
139
135
if dpi is None :
140
136
savefig_dpi = mpl .rcParams ['savefig.dpi' ]
@@ -162,10 +158,8 @@ def get_tikz_code(
162
158
# write the contents
163
159
if wrap :
164
160
code += '\\ begin{tikzpicture}\n \n '
165
- if extra_picture_opt :
166
- for options in data ['extra picture options' ]:
167
- code += options + ',\n '
168
-
161
+ code += ',\n ' .join (data ['extra tikzpicture parameters' ])
162
+ code += '\n '
169
163
170
164
coldefs = _get_color_definitions (data )
171
165
if coldefs :
0 commit comments