Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

GLMakie: Annotate cell/boundary region color bar #38

Merged
merged 1 commit into from
Nov 27, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

### Added

- `gridplot` with `PyPlot` has now a color bar with annotation `boundary regions`
- `gridplot` with `GLMakie` and `PyPlot` now annotates the color bars with `boundary regions` and `cell regions`

## [1.9.0] - 2024-11-25

Expand Down
4 changes: 4 additions & 0 deletions src/makie.jl
Original file line number Diff line number Diff line change
Expand Up @@ -538,13 +538,15 @@ function makescene_grid(ctx)
limits = (0.5, ncol + 0.5),
ticks = 1:ncol,
width = 15,
label = "cell regions",
)
GL[1, 3] = XMakie.Colorbar(
ctx[:figure];
colormap = XMakie.cgrad(ctx[:bcmap]; categorical = true),
limits = (0.5, nbcol + 0.5),
ticks = 1:nbcol,
width = 15,
label = "boundary regions",
)
elseif ctx[:colorbar] == :horizontal
GL[2, 1] = XMakie.Colorbar(
Expand All @@ -553,13 +555,15 @@ function makescene_grid(ctx)
limits = (1, ncol),
height = 15,
vertical = false,
label = "cell regions",
)
GL[3, 1] = XMakie.Colorbar(
ctx[:figure];
colormap = XMakie.cgrad(ctx[:bcmap]; categorical = true),
limits = (1, nbcol),
height = 15,
vertical = false,
label = "boundary regions",
)
end
end
Expand Down
Loading