Skip to content

Commit 698cb64

Browse files
committed
Merge branch 'main' into refactor/legend
2 parents 1b4b78d + 938e8ec commit 698cb64

23 files changed

+314
-78
lines changed

.github/ISSUE_TEMPLATE/5-bump_gmt_checklist.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@ mamba install -c conda-forge gmt=X.Y.Z
3131
- [ ] Run `grep -r "# TODO(GMT.*)" --include="*.py" .` to find TODO items related to GMT
3232
- [ ] Remove related workarounds/patches
3333
- [ ] Fix tests with pytest `xfail`/`skipif` markers that now pass
34+
- [ ] Update URLs to manually inserted images of the GMT documentation
3435
- [ ] Update this checklist if necessary
3536

3637
**To-Do for bumping the minimum required GMT version**:

.github/workflows/benchmarks.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -84,7 +84,7 @@ jobs:
8484

8585
# Run the benchmark tests
8686
- name: Run benchmarks
87-
uses: CodSpeedHQ/action@6a8e2b874c338bf81cc5e8be715ada75908d3871 # v4.3.4
87+
uses: CodSpeedHQ/action@346a2d8a8d9d38909abd0bc3d23f773110f076ad # v4.4.1
8888
with:
8989
mode: "instrumentation"
9090
# 'bash -el -c' is needed to use the custom shell.

.github/workflows/ci_tests.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -151,7 +151,7 @@ jobs:
151151
GH_TOKEN: ${{ github.token }}
152152

153153
- name: Install uv
154-
uses: astral-sh/setup-uv@1e862dfacbd1d6d858c55d9b792c756523627244 # v7.1.4
154+
uses: astral-sh/setup-uv@681c641aba71e4a1c380be3ab5e12ad51f415867 # v7.1.6
155155
with:
156156
activate-environment: true
157157
python-version: ${{ matrix.python-version }}

doc/contributing.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -488,10 +488,10 @@ integration systems will warn us and you can make a new commit with the formatte
488488
Even better, you can just write `/format` in the first line of any comment in a
489489
pull request to lint the code automatically.
490490

491-
When wrapping a new alias, use an underscore to separate words bridged by vowels
492-
(aeiou), such as `no_skip` and `z_only`. Do not use an underscore to separate
493-
words bridged only by consonants, such as `distcalc`, and `crossprofile`. This
494-
convention is not applied by the code checking tools, but the PyGMT maintainers
491+
When introducing a new parameter name, use an underscore to separate words. This improves
492+
readability and aligns with the [PEP 8 style guide](https://peps.python.org/pep-0008/).
493+
For common shortcuts no underscore is needed, e.g., `surftype`, `outgrid`, or `timefmt`.
494+
This convention is not applied by the code checking tools, but the PyGMT maintainers
495495
will comment on any pull requests as needed.
496496

497497
When working on a tutorial or a gallery plot, it is good practice to use code

examples/gallery/embellishments/gmt_logo.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,12 +7,12 @@
77

88
# %%
99
import pygmt
10+
from pygmt.params import Position
1011

1112
fig = pygmt.Figure()
1213
fig.basemap(region=[0, 10, 0, 2], projection="X6c", frame=True)
1314

1415
# Add the GMT logo in the Top Right (TR) corner of the current plot, scaled up to be 3
1516
# centimeters wide and offset by 0.3 cm in x-direction and 0.6 cm in y-direction.
16-
fig.logo(position="jTR+o0.3c/0.6c+w3c")
17-
17+
fig.logo(position=Position("TR", offset=(0.3, 0.6)), width="3c")
1818
fig.show()

examples/projections/cyl/cyl_universal_transverse_mercator.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
1515
.. _GMT_utm_zones:
1616
17-
.. figure:: https://docs.generic-mapping-tools.org/latest/_images/GMT_utm_zones.png
17+
.. figure:: https://docs.generic-mapping-tools.org/6.6/_images/GMT_utm_zones.png
1818
:width: 700 px
1919
:align: center
2020

examples/tutorials/advanced/cartesian_histograms.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -320,7 +320,7 @@
320320
# Grouped bars
321321
# ------------
322322
#
323-
# By setting the ``barwidth`` parameter in respect to the values passed to the
323+
# By setting the ``bar_width`` parameter in respect to the values passed to the
324324
# ``series`` parameter histograms with grouped bars can be created.
325325
#
326326
# Limitations of histograms with grouped bars are:
@@ -347,7 +347,7 @@
347347
# of the bin width
348348
# Offset ("+o") the bars to align each bar with the left limit of the corresponding
349349
# bin
350-
barwidth=f"{binwidth / 2}+o-{binwidth / 4}",
350+
bar_width=f"{binwidth / 2}+o-{binwidth / 4}",
351351
label="data01",
352352
)
353353

@@ -358,7 +358,7 @@
358358
fill="orange",
359359
pen="1p,darkgray,solid",
360360
histtype=0,
361-
barwidth=f"{binwidth / 2}+o{binwidth / 4}",
361+
bar_width=f"{binwidth / 2}+o{binwidth / 4}",
362362
label="data02",
363363
)
364364

pygmt/encodings.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
----------
1717
1818
- GMT-octal-codes: https://github.com/seisman/GMT-octal-codes
19-
- GMT documentation: https://docs.generic-mapping-tools.org/dev/reference/octal-codes.html
19+
- GMT documentation: https://docs.generic-mapping-tools.org/6.6/reference/octal-codes.html
2020
- Adobe Postscript Language Reference: https://www.adobe.com/jp/print/postscript/pdfs/PLRM.pdf
2121
- Adobe ISOLatin1+: https://en.wikipedia.org/wiki/PostScript_Latin_1_Encoding
2222
- Adobe Symbol: https://en.wikipedia.org/wiki/Symbol_(typeface)

pygmt/params/pattern.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ class Pattern(BaseParam):
2626
GMT provides 90 predefined patterns that can be used in PyGMT. The patterns are
2727
numbered from 1 to 90, and shown below:
2828
29-
.. figure:: https://docs.generic-mapping-tools.org/6.5/_images/GMT_App_E.png
29+
.. figure:: https://docs.generic-mapping-tools.org/6.6/_images/GMT_App_E.png
3030
:alt: The 90 predefined bit-patterns provided with GMT
3131
:width: 75%
3232
:align: center

pygmt/params/position.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ class Position(BaseParam):
1818
"""
1919
Class for positioning embellishments on a plot.
2020
21-
.. figure:: https://docs.generic-mapping-tools.org/dev/_images/GMT_anchor.png
21+
.. figure:: https://docs.generic-mapping-tools.org/6.6/_images/GMT_anchor.png
2222
:width: 600 px
2323
:align: center
2424

0 commit comments

Comments
 (0)