Inset within subplot : -D*anchor* is lost

Open
#7,397 3 comments 0 reactions 0 assignees View on GitHub

Maintainers usually reply within 1 day

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
35/100
Issue type
Bug
Clarity
Mostly clear
Activity status
Stale
Tech stack
c

Research direction

Run the provided GMT subplot and inset command sequence and compare the two inset positions, especially the -DJTR anchor and +o1c offset. Trace the subplot and inset entry points involved in handling those options; done means both insets are positioned relative to the active subplot while preserving their anchor and offset.

Written by the indexing model from the issue text.

Description

bug

Inset not taking into account the subplot environment:

gmt begin test png
	gmt subplot begin 3x1 -Fs5c  -R0/1/0/1
	gmt subplot set
		gmt basemap -Bafg
	gmt subplot set
		gmt basemap -Bafg
	gmt subplot set
		gmt basemap -Bafg
		gmt inset begin -DJTR -Rg -JG0/-90/1c -F+gred
			gmt basemap -Bafg
		gmt inset end
		gmt inset begin -DJTR+o1c -Rg -JG0/-90/1c -F+gblue
			gmt basemap -Bafg
		gmt inset end
	gmt subplot end
gmt end show
Dominant language
C
Stars
997
Forks
420
Avg merge
13h 27m
Merged PRs (30d)
47

Getting set up

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from GenericMappingTools/gmt

All issues in GenericMappingTools/gmt

Similar issues

More C issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.