Uh oh!
There was an error while loading. Please reload this page.
Figure.logo: Add parameters position/width/height to specify logo position and dimensions - #4014
Merged
Conversation
seisman
marked this pull request as ready for review
September 12, 2025 04:45
seisman
commented
Dec 16, 2025
| raise GMTInvalidInput(msg) | ||
| # Default position at the plot origin. | ||
| if position is None: |
MemberAuthor
There was a problem hiding this comment.
Force the default position to x0/0 if position is not given.
| [**g**\|\ **j**\|\ **J**\|\ **n**\|\ **x**]\ *refpoint*\ | ||
| **+w**\ *width*\ [**+j**\ *justify*]\ [**+o**\ *dx*\ [/*dy*]]. | ||
| Set reference point on the map for the image. | ||
| position |
MemberAuthor
There was a problem hiding this comment.
Currently, position accept a Position object. I'm debating if we should support a tuple or an anchor code:
position=(0, 2): equivalent toposition=Position((0, 2))and is converted to"x0/2"position="BL": equivalent toposition=Position("BL")and is converted to"jBL".
seisman
commented
Dec 17, 2025
MemberAuthor
@GenericMappingTools/pygmt-maintainers Please give this PR a final review. Plan to merge in 24 hours if no further comments. |
michaelgrund
approved these changes
Dec 17, 2025
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Co-authored-by: Michael Grund <23025878+michaelgrund@users.noreply.github.com>
This was referenced Dec 17, 2025
Merged
Uh oh!
There was an error while loading. Please reload this page.
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 freeto 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.
The
logomodule's-Doption has the following syntax:[g|j|J|n|x]refpoint[+jjustify][+odx[/dy]]is common to GMT embellishments and use thePositionclass+h:height+w:widthPreview: https://pygmt-dev--4014.org.readthedocs.build/en/4014/api/generated/pygmt.Figure.logo.html
Related to #4165.