From ce2ef4c9977fa26163cced59832d7de8687a4ad2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Yvonne=20Fr=C3=B6hlich?= Date: Tue, 7 Apr 2026 14:55:44 +0200 Subject: [PATCH 1/2] Use new Frame and Axis parameter classes --- examples/gallery/basemaps/ternary.py | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/examples/gallery/basemaps/ternary.py b/examples/gallery/basemaps/ternary.py index 3900447cef7..68d820b0a43 100644 --- a/examples/gallery/basemaps/ternary.py +++ b/examples/gallery/basemaps/ternary.py @@ -14,7 +14,7 @@ # %% import pygmt -from pygmt.params import Position +from pygmt.params import Axis, Frame, Position fig = pygmt.Figure() @@ -34,11 +34,13 @@ blabel="Water", clabel="Air", cmap=True, - frame=[ - "aafg+lLimestone component+u %", - "bafg+lWater component+u %", - "cafg+lAir component+u %", - ], + frame=Frame( + axis=Axis( + annot=True, tick=True, grid=True, label="Limestone component", unit="%" + ), + bxis=Axis(annot=True, tick=True, grid=True, label="Water component", unit="%"), + cxis=Axis(annot=True, tick=True, grid=True, label="Air component", unit="%"), + ), ) # Add a colorbar indicating the values given in the fourth column of the input dataset From 8b8d6e670d9de9ef3a3ac8af558fac6267d7a3f1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Yvonne=20Fr=C3=B6hlich?= Date: Tue, 7 Apr 2026 15:03:59 +0200 Subject: [PATCH 2/2] Fix typo --- examples/gallery/basemaps/ternary.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/examples/gallery/basemaps/ternary.py b/examples/gallery/basemaps/ternary.py index 68d820b0a43..6a7ab357570 100644 --- a/examples/gallery/basemaps/ternary.py +++ b/examples/gallery/basemaps/ternary.py @@ -35,11 +35,11 @@ clabel="Air", cmap=True, frame=Frame( - axis=Axis( + aaxis=Axis( annot=True, tick=True, grid=True, label="Limestone component", unit="%" ), - bxis=Axis(annot=True, tick=True, grid=True, label="Water component", unit="%"), - cxis=Axis(annot=True, tick=True, grid=True, label="Air component", unit="%"), + baxis=Axis(annot=True, tick=True, grid=True, label="Water component", unit="%"), + caxis=Axis(annot=True, tick=True, grid=True, label="Air component", unit="%"), ), )