Skip to content

Simplify GridSpec setup in make_axes_gridspec.#27306

Merged
oscargus merged 1 commit intomatplotlib:mainfrom
anntzer:mag
Nov 15, 2023
Merged

Simplify GridSpec setup in make_axes_gridspec.#27306
oscargus merged 1 commit intomatplotlib:mainfrom
anntzer:mag

Conversation

@anntzer
Copy link
Copy Markdown
Contributor

@anntzer anntzer commented Nov 11, 2023

Currently, make_axes_gridspec uses two nested gridspecs, first a horizontal (1, 2) gridspec and second a vertical (3, 1) gridspec to position an axes A and the associated left-colorbar C as

A.
AC
A.

(and similarly for colorbars on other sides of the main axes). Instead, this can be done with a single (3, 2) gridspec to position both A and C.

PR summary

PR checklist

Currently, make_axes_gridspec uses two nested gridspecs, first a
horizontal (1, 2) gridspec and second a vertical (3, 1) gridspec to
position an axes A and the associated left-colorbar C as
```
A.
AC
A.
```
(and similarly for colorbars on other sides of the main axes).  Instead,
this can be done with a single (3, 2) gridspec to position both A and C.
@anntzer anntzer added topic: geometry manager LayoutEngine, Constrained layout, Tight layout Maintenance labels Nov 11, 2023
@oscargus oscargus merged commit 2a840e4 into matplotlib:main Nov 15, 2023
@anntzer anntzer deleted the mag branch November 15, 2023 08:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Maintenance topic: geometry manager LayoutEngine, Constrained layout, Tight layout

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants