hello everyone
I want to use shift_origin to draw multiple graphics on a canvas, and then draw the labels from each graphic into the same legend. Here is my code, but the result of the legend doesn’t seem to be very good. How can I separate the three stacked labels
import pygmt
fig = pygmt.Figure()
font ="15p,Helvetica-Bold"
fig.basemap(region=[0,30,0,12],
projection="X30c/20c",
frame=["af"],)
fig.plot(x=1, y=2, style="t0.7c",pen="0.5p black",fill="red", label="1")
fig.text(position="TL", text="(a)",offset="j+1c/0.5c", font=font)
fig.shift_origin(xshift="31c", yshift="10c")
fig.basemap(region=[0,15,0,8],
projection="X15c/8c",
frame=["af"])
fig.plot(x=1, y=2, style="t0.7c",pen="0.5p black",fill="black", label="2")
fig.text(position="TL",text="(b)", offset="j+1c/0.5c", font=font)
fig.shift_origin(yshift="-9c")
fig.basemap(region=[0,12,0,8],
projection="X15c/8c",
frame=["af"])
fig.plot(x=1, y=2, style="t0.7c",pen="0.5p black",fill="blue", label="3")
fig.text(position="TL", text="(c)", offset="j+1c/0.5c", font=font)
fig.legend(position="JBR+jBR+o5.5c/-1c", box=True)
fig.show()