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

Certain special characters yield malformed output #2

Closed
pteridin opened this issue Aug 23, 2023 · 2 comments · Fixed by JanMarvin/openxlsx2#757
Closed

Certain special characters yield malformed output #2

pteridin opened this issue Aug 23, 2023 · 2 comments · Fixed by JanMarvin/openxlsx2#757
Assignees
Labels
bug Something isn't working

Comments

@pteridin
Copy link
Owner

pteridin commented Aug 23, 2023

Just saw that gtsummary output with "less than x" content will get malformed to e.g.:

<r><rPr/><t>8 (<0.1%)</t></r>
  • Need to escape those characters
@pteridin pteridin added the bug Something isn't working label Aug 23, 2023
@pteridin pteridin self-assigned this Aug 23, 2023
@JanMarvin
Copy link
Contributor

JanMarvin commented Aug 23, 2023

This should be escaped in openxlsx2. We simply never came across this. fmt_txt() should call escape_xml().

Edit: unless that's a basic inlineStr. I'll have a look.

JanMarvin added a commit to JanMarvin/openxlsx2 that referenced this issue Aug 23, 2023
pteridin added a commit that referenced this issue Aug 23, 2023
@pteridin
Copy link
Owner Author

Thank you @JanMarvin!

Weaved in a workaround for older openxlsx2 versions <= 0.8.0.9000 that is more or less your implementation of escaping the non-illegal, though troublesome, characters.

JanMarvin added a commit to JanMarvin/openxlsx2 that referenced this issue Aug 23, 2023
JanMarvin added a commit to JanMarvin/openxlsx2 that referenced this issue Aug 23, 2023
* [fmt_txt] escape xml

fixes pteridin/flexlsx#2 (comment)

* redoc
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants