|
32 | 32 | it="use_word", |
33 | 33 | w="wrap", |
34 | 34 | ) |
35 | | -def text_( # noqa: PLR0912, PLR0913 |
| 35 | +def text_( # noqa: PLR0912, PLR0913, PLR0915 |
36 | 36 | self, |
37 | 37 | textfiles: PathLike | TableLike | None = None, |
38 | 38 | x=None, |
@@ -118,12 +118,12 @@ def text_( # noqa: PLR0912, PLR0913 |
118 | 118 | of the map. |
119 | 119 | text |
120 | 120 | The text string, or an array of strings to plot on the figure. |
121 | | - angle: float, str, bool or list |
| 121 | + angle |
122 | 122 | Set the angle measured in degrees counter-clockwise from |
123 | 123 | horizontal (e.g. 30 sets the text at 30 degrees). If no angle is |
124 | 124 | explicitly given (i.e. ``angle=True``) then the input to ``textfiles`` |
125 | 125 | must have this as a column. |
126 | | - font : str, bool or list of str |
| 126 | + font |
127 | 127 | Set the font specification with format *size*\ ,\ *font*\ ,\ *color* |
128 | 128 | where *size* is text size in points, *font* is the font to use, and |
129 | 129 | *color* sets the font color. For example, |
@@ -228,13 +228,15 @@ def text_( # noqa: PLR0912, PLR0913 |
228 | 228 |
|
229 | 229 | # Build the -F option. |
230 | 230 | if kwargs.get("F") is None and any( |
231 | | - v is not None for v in (position, angle, font, justify) |
| 231 | + v is not None or v is not False for v in (position, angle, font, justify) |
232 | 232 | ): |
233 | 233 | kwargs.update({"F": ""}) |
234 | 234 |
|
235 | 235 | for arg, flag, _ in array_args: |
236 | 236 | if arg is True: |
237 | 237 | kwargs["F"] += flag |
| 238 | + elif arg is False: |
| 239 | + pass |
238 | 240 | elif isinstance(arg, int | float | str): |
239 | 241 | kwargs["F"] += f"{flag}{arg}" |
240 | 242 |
|
|
0 commit comments