Implement the frame='none' syntax for no frames#4404
Open
Conversation
Contributor
Summary of changed imagesThis is an auto-generated report of images that have changed on the DVC remote
Image diff(s)Report last updated at commit 2f8a3c8 |
Contributor
There was a problem hiding this comment.
Pull request overview
Adds a Pythonic frame="none" option across PyGMT plotting APIs to request “no frame” behavior by translating it to GMT’s -B+n under the hood.
Changes:
- Map
frame="none"to the GMT-B+nsyntax in the alias system (common-Bhandling). - Expand
frametype annotations across affected plotting functions to includeLiteral["none"]. - Add/extend tests, baseline image, and update docs/examples to demonstrate the new syntax.
Reviewed changes
Copilot reviewed 27 out of 27 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| pygmt/alias.py | Implements the frame="none" → +n mapping for common -B handling. |
| pygmt/helpers/decorators.py | Updates common frame docstring snippet to document frame="none". |
| pygmt/src/basemap.py | Updates frame type hint to accept "none". |
| pygmt/src/coast.py | Updates frame type hint to accept "none". |
| pygmt/src/colorbar.py | Updates frame type hint and documents frame="none" behavior. |
| pygmt/src/contour.py | Updates frame type hint to accept "none". |
| pygmt/src/grdcontour.py | Updates frame type hint to accept "none". |
| pygmt/src/grdimage.py | Updates frame type hint to accept "none". |
| pygmt/src/grdview.py | Updates frame type hint to accept "none". |
| pygmt/src/histogram.py | Updates frame type hint to accept "none". |
| pygmt/src/image.py | Updates frame type hint to accept "none". |
| pygmt/src/legend.py | Updates frame type hint to accept "none". |
| pygmt/src/meca.py | Updates frame type hint to accept "none". |
| pygmt/src/plot.py | Updates frame type hint to accept "none". |
| pygmt/src/plot3d.py | Updates frame type hint to accept "none". |
| pygmt/src/rose.py | Updates frame type hint to accept "none". |
| pygmt/src/solar.py | Updates frame type hint to accept "none". |
| pygmt/src/subplot.py | Updates frame type hint to accept "none". |
| pygmt/src/ternary.py | Updates frame type hint to accept "none". |
| pygmt/src/text.py | Updates frame type hint to accept "none". |
| pygmt/src/tilemap.py | Updates frame type hint to accept "none". |
| pygmt/src/velo.py | Updates frame type hint to accept "none". |
| pygmt/src/wiggle.py | Updates frame type hint to accept "none". |
| pygmt/tests/test_alias_system.py | Adds coverage asserting frame="none" becomes -B+n via common-parameter aliasing. |
| pygmt/tests/test_basemap.py | Adds an image-comparison test covering frame="none" in basemap and colorbar. |
| pygmt/tests/baseline/test_basemap_frame_none.png.dvc | Adds the baseline artifact metadata for the new image test. |
| examples/gallery/maps/choropleth_map.py | Updates an example to use frame="none" instead of raw "+n". |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.

Closes #4403.
Preview: https://pygmt-dev--4404.org.readthedocs.build/en/4404/api/generated/pygmt.Figure.basemap.html#pygmt.Figure.basemap