|
99 | 99 | # Filling the quadrants |
100 | 100 | # --------------------- |
101 | 101 | # |
102 | | -# Use the parameters ``compressionfill`` and ``extensionfill`` to fill the quadrants |
| 102 | +# Use the parameters ``compression_fill`` and ``extension_fill`` to fill the quadrants |
103 | 103 | # with different colors or :class:`patterns <pygmt.params.Pattern>`. |
104 | 104 | fig = pygmt.Figure() |
105 | 105 | fig.basemap(region=region, projection=projection, frame=frame) |
|
110 | 110 | longitude=-2, |
111 | 111 | latitude=0, |
112 | 112 | depth=0, |
113 | | - compressionfill="darkorange", |
114 | | - extensionfill="cornsilk", |
| 113 | + compression_fill="darkorange", |
| 114 | + extension_fill="cornsilk", |
115 | 115 | ) |
116 | 116 |
|
117 | 117 | fig.meca( |
|
120 | 120 | longitude=2, |
121 | 121 | latitude=0, |
122 | 122 | depth=0, |
123 | | - compressionfill=Pattern(8), |
124 | | - extensionfill=Pattern(31), |
| 123 | + compression_fill=Pattern(8), |
| 124 | + extension_fill=Pattern(31), |
125 | 125 | outline=True, |
126 | 126 | ) |
127 | 127 |
|
|
168 | 168 | # both, ``"1"`` to the first, and ``"2"`` to the second nodal plane(s). Only the |
169 | 169 | # circumference and the specified nodal plane(s) are plotted, i.e. the quadrants |
170 | 170 | # remain unfilled (transparent). We can make use of the stacking concept of (Py)GMT, |
171 | | -# and use ``nodal`` in combination with the ``outline``, ``compressionfill`` / |
172 | | -# ``extensionfill`` and ``pen`` parameters. |
| 171 | +# and use ``nodal`` in combination with the ``outline``, ``compression_fill`` / |
| 172 | +# ``extension_fill`` and ``pen`` parameters. |
173 | 173 |
|
174 | 174 | fig = pygmt.Figure() |
175 | 175 | fig.basemap(region=region, projection=projection, frame=frame) |
|
188 | 188 | # (ii) Plot the first nodal plane and the circumference in darkorange |
189 | 189 | # (iii) Plot the circumference in black on top; use "-" to not fill the quadrants |
190 | 190 | for kwargs in [ |
191 | | - {"compressionfill": "lightorange"}, |
| 191 | + {"compression_fill": "lightorange"}, |
192 | 192 | {"nodal": "1/1p,darkorange"}, |
193 | | - {"compressionfill": "-", "extensionfill": "-", "pen": "1p,gray30"}, |
| 193 | + {"compression_fill": "-", "extension_fill": "-", "pen": "1p,gray30"}, |
194 | 194 | ]: |
195 | 195 | fig.meca( |
196 | 196 | spec=aki_single, |
|
238 | 238 | plot_longitude=1, |
239 | 239 | plot_latitude=2, |
240 | 240 | offset="+p1p,darkorange+s0.25c", |
241 | | - compressionfill="lightorange", |
| 241 | + compression_fill="lightorange", |
242 | 242 | ) |
243 | 243 |
|
244 | 244 | fig.show() |
|
284 | 284 | # parameter. Additionally, the location of the label relative to the beachball [Default |
285 | 285 | # is ``"TC"``, i.e., Top Center] can be changed by appending **+j** and an offset can |
286 | 286 | # be applied by appending **+o** with values for *dx*\ /*dy*. Add a colored [Default is |
287 | | -# white] box behind the label via the label ``labelbox``. Force a fixed size of the |
| 287 | +# white] box behind the label via the parameter ``label_box``. Force a fixed size of the |
288 | 288 | # beachball by appending **+m** to the argument passed to the ``scale`` parameter. |
289 | 289 |
|
290 | 290 | fig = pygmt.Figure() |
291 | 291 | fig.coast(region="d", projection="N10c", land="lightgray", frame=True) |
292 | 292 |
|
293 | | -fig.meca(spec=aki_multiple, scale="0.4c+m+f5p", labelbox="white@30", offset="+s0.1c") |
| 293 | +fig.meca(spec=aki_multiple, scale="0.4c+m+f5p", label_box="white@30", offset="+s0.1c") |
294 | 294 |
|
295 | 295 | fig.show() |
296 | 296 |
|
|
315 | 315 | spec=aki_multiple, |
316 | 316 | scale="0.4c+f5p", |
317 | 317 | offset="0.2p,gray30+s0.1c", |
318 | | - labelbox="white@30", |
| 318 | + label_box="white@30", |
319 | 319 | cmap=True, |
320 | 320 | outline="0.2p,gray30", |
321 | 321 | ) |
|
0 commit comments