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

jk/remove figureposition #1075

Merged
merged 9 commits into from Jul 5, 2021
Merged

jk/remove figureposition #1075

merged 9 commits into from Jul 5, 2021

Conversation

jkrumbiegel
Copy link
Collaborator

@jkrumbiegel jkrumbiegel commented Jun 27, 2021

FigurePosition and FigureSubposition were mirroring GridPosition and GridSubposition from GridLayoutBase, with the only difference that they stored a Figure reference so they could be used in commands like Axis(f[1, 1]). What didn't work was plotting into similar looking GridPositions:

f = Figure()
f[1, 1] = gl = GridLayout()
Axis(gl[1, 1]) # would error because gl had no reference to f

This works now because GridLayouts have a parent field which can optionally be set to some parent object (usually a Figure) so that it's known who the GridLayout belongs to. I could delete all the mirrored code and gain some functionality, but it's of course slightly breaking, in case people were writing functions with FigurePosition or FigureSubposition arguments. These would need to be changed to GridPosition and GridSubposition. All other syntax stayed the same.

@jkrumbiegel jkrumbiegel merged commit 385358c into master Jul 5, 2021
@jkrumbiegel jkrumbiegel deleted the jk/remove-figureposition branch July 5, 2021 14:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant