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

Math layout: Don’t add frames for MetaElems #4019

Closed

Conversation

bluebear94
Copy link
Contributor

See #3727

The tests still pass, but this is probably not the correct solution. Wondering if there’s another way to fix this.

@laurmaedje laurmaedje added the waiting-on-review This PR is waiting to be reviewed. label May 6, 2024
@laurmaedje
Copy link
Member

This will indeed break introspection in math, e.g.:

$ #metadata("hi") $
#context query(metadata)

To fix it properly, MetaElem::data probably needs to be handled in better non-frame way by the math layout.

@laurmaedje laurmaedje removed the waiting-on-review This PR is waiting to be reviewed. label May 7, 2024
The tests still pass, but this is probably not the correct solution.
@bluebear94 bluebear94 force-pushed the mf/fix-contextual-math-class branch from 99220e8 to d4a16da Compare May 7, 2024 18:28
@bluebear94
Copy link
Contributor Author

bluebear94 commented May 7, 2024

For some reason, $ a class("relation", "--") #metadata("hi") b $ also produces incorrect spacing in the current development version (though not in 0.11). I think it has to do with removing the custom Behaved implementation from MetadataElem.

@bluebear94
Copy link
Contributor Author

Also, Content::layout_math flattens nested sequence elements, but it can’t see through realization steps (context blocks, Show implementations). I wonder if a more general solution is needed, perhaps assigning a behavior to each MathFragment.

@laurmaedje
Copy link
Member

laurmaedje commented May 13, 2024

For some reason, $ a class("relation", "--") #metadata("hi") b $ also produces incorrect spacing in the current development version (though not in 0.11). I think it has to do with removing the custom Behaved implementation from MetadataElem.

That's more a bug with math than with the Behaved implementation. The whole math thing is all just approximate pseudo-realization. I'm trying to also unify the math realization with the proper one as part of the realization improvements.

@bluebear94
Copy link
Contributor Author

Fair enough; do you want to close this for now since the underlying issue would be solved by unifying math realization with the proper one?

@laurmaedje
Copy link
Member

Yeah, let's close this for now.

@laurmaedje laurmaedje closed this May 13, 2024
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

2 participants