-
-
Notifications
You must be signed in to change notification settings - Fork 7.9k
[Doc] Minor consistency changes and correction of Marker docs #27520
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
Show all changes
2 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -47,15 +47,15 @@ | |
``11`` (``CARETDOWNBASE``) |m36| caretdown (centered at base) | ||
``"none"`` or ``"None"`` nothing | ||
``" "`` or ``""`` nothing | ||
``'$...$'`` |m37| Render the string using mathtext. | ||
``"$...$"`` |m37| Render the string using mathtext. | ||
E.g ``"$f$"`` for marker showing the | ||
letter ``f``. | ||
``verts`` A list of (x, y) pairs used for Path | ||
vertices. The center of the marker is | ||
located at (0, 0) and the size is | ||
normalized, such that the created path | ||
is encapsulated inside the unit cell. | ||
path A `~matplotlib.path.Path` instance. | ||
``path`` A `~matplotlib.path.Path` instance. | ||
``(numsides, 0, angle)`` A regular polygon with ``numsides`` | ||
sides, rotated by ``angle``. | ||
``(numsides, 1, angle)`` A star-like symbol with ``numsides`` | ||
|
@@ -64,11 +64,6 @@ | |
rotated by ``angle``. | ||
============================== ====== ========================================= | ||
|
||
As a deprecated feature, ``None`` also means 'nothing' when directly | ||
constructing a `.MarkerStyle`, but note that there are other contexts where | ||
``marker=None`` instead means "the default marker" (e.g. :rc:`scatter.marker` | ||
for `.Axes.scatter`). | ||
|
||
Note that special symbols can be defined via the | ||
:ref:`STIX math font <mathtext>`, | ||
e.g. ``"$\u266B$"``. For an overview over the STIX font symbols refer to the | ||
|
@@ -227,24 +222,22 @@ def __init__(self, marker, | |
""" | ||
Parameters | ||
---------- | ||
marker : str, array-like, Path, MarkerStyle, or None | ||
- Another instance of *MarkerStyle* copies the details of that | ||
``marker``. | ||
- *None* means no marker. This is the deprecated default. | ||
marker : str, array-like, Path, MarkerStyle | ||
- Another instance of `MarkerStyle` copies the details of that *marker*. | ||
- For other possible marker values, see the module docstring | ||
`matplotlib.markers`. | ||
|
||
fillstyle : str, default: :rc:`markers.fillstyle` | ||
One of 'full', 'left', 'right', 'bottom', 'top', 'none'. | ||
|
||
transform : transforms.Transform, default: None | ||
transform : `~matplotlib.transforms.Transform`, optional | ||
Transform that will be combined with the native transform of the | ||
marker. | ||
|
||
capstyle : `.CapStyle` or %(CapStyle)s, default: None | ||
capstyle : `.CapStyle` or %(CapStyle)s, optional | ||
Cap style that will override the default cap style of the marker. | ||
|
||
joinstyle : `.JoinStyle` or %(JoinStyle)s, default: None | ||
joinstyle : `.JoinStyle` or %(JoinStyle)s, optional | ||
Join style that will override the default join style of the marker. | ||
""" | ||
self._marker_function = None | ||
8000
|
@@ -309,10 +302,8 @@ def _set_marker(self, marker): | |
|
||
Parameters | ||
---------- | ||
marker : str, array-like, Path, MarkerStyle, or None, default: None | ||
- Another instance of *MarkerStyle* copies the details of that | ||
``marker``. | ||
- *None* means no marker. | ||
oscargus marked this conversation as resolved.
Show resolved
Hide resolved
|
||
marker : str, array-like, Path, MarkerStyle | ||
- Another instance of `MarkerStyle` copies the details of that *marker*. | ||
- For other possible marker values see the module docstring | ||
`matplotlib.markers`. | ||
""" | ||
|
@@ -388,13 +379,13 @@ def get_user_transform(self): | |
if self._user_transform is not None: | ||
return self._user_transform.frozen() | ||
|
||
def transformed(self, transform: Affine2D): | ||
def transformed(self, transform): | ||
""" | ||
Return a new version of this marker with the transform applied. | ||
|
||
Parameters | ||
---------- | ||
transform : `~matplotlib.transforms.Affine2D`, default: None | ||
transform : `~matplotlib.transforms.Affine2D` | ||
Transform will be combined with current user supplied transform. | ||
""" | ||
new_marker = MarkerStyle(self) | ||
|
@@ -410,10 +401,10 @@ def rotated(self, *, deg=None, rad=None): | |
|
||
Parameters | ||
---------- | ||
deg : float, default: None | ||
deg : float, optional | ||
Rotation angle in degrees. | ||
|
||
rad : float, default: None | ||
rad : float, optional | ||
Rotation angle in radians. | ||
|
||
.. note:: You must specify exactly one of deg or rad. | ||
|
@@ -437,14 +428,14 @@ def scaled(self, sx, sy=None): | |
""" | ||
Return new marker scaled by specified scale factors. | ||
|
||
If *sy* is None, the same scale is applied in both the *x*- and | ||
If *sy* is not given, the same scale is applied in both the *x*- and | ||
*y*-directions. | ||
|
||
Parameters | ||
---------- | ||
sx : float | ||
*X*-direction scaling factor. | ||
sy : float, default: None | ||
sy : float, optional | ||
*Y*-direction scaling factor. | ||
""" | ||
if sy is None: | ||
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.