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

LaTeX: keep scope of \fboxsep local #1709

Merged

Conversation

jfbu
Copy link
Contributor

@jfbu jfbu commented Feb 12, 2021

In case of texcomments=True or usage of escapeinside, arbitrary LaTeX
can be executed. The \PY@bc is executed at top level hence should not
set \fboxsep at this level but keep the change to a local scope.

There is another instance but it is part of PR #1708

Related:

P.-S. I think I may have a few years back either opened a ticket or even done a PR on bitbucket but I can't find trace. For this one and also #1708

In case of texcomments=True or usage of escapeinside, arbitrary LaTeX
can be executed. The \PY@bc is executed at top level hence should not
set \fboxsep at this level but keep the change to a local scope.

There is another instance but it is part of PR pygments#1708
@birkenfeld
Copy link
Member

Sure, makes sense.

@birkenfeld birkenfeld merged commit 7eeb03e into pygments:master Feb 12, 2021
@birkenfeld birkenfeld added the changelog-update Items which need to get mentioned in the changelog label Feb 12, 2021
@birkenfeld
Copy link
Member

@Anteru I set "changelog-update" for a general mention of all the small fixes in LaTeX output.

@Anteru
Copy link
Collaborator

Anteru commented Feb 12, 2021

Sounds good, thanks!

@Anteru Anteru added this to the 2.8 milestone Feb 12, 2021
@jfbu jfbu deleted the LaTeX_avoid_setting_fboxsep_at_top_level branch February 12, 2021 22:15
@Anteru Anteru removed the changelog-update Items which need to get mentioned in the changelog label Feb 14, 2021
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

3 participants