cstkingkey / docx-rs

A Rust library for parsing and generating docx files.
MIT License
12 stars 12 forks source link

Hyperlinks' display string disappears sometimes #24

Open alpha-tango-kilo opened 1 month ago

alpha-tango-kilo commented 1 month ago

A minimised doc containing moreorless just a link: missing link repro.docx

If you rummage around and pull out the ParagraphContent::Link -> Hyperlink.content, it only contains the close double quote, nothing else. In fact, if you load this file as a Docx and debug print the whole thing, "beep boop" is nowhere to be found

Am I missing something here, is this a bug in the library, or is this a bug or some other weird behaviour in Word? Strangely, if you try and cut down the reproducer much more (e.g. remove the leading space) then the link content appears as expected