diff options
author | Mike Kaganski <mike.kaganski@collabora.com> | 2024-04-30 15:40:41 +0500 |
---|---|---|
committer | Mike Kaganski <mike.kaganski@collabora.com> | 2024-04-30 19:11:32 +0200 |
commit | acbb6c98ae1335da5aca4f1a55de5f3ae35a5d02 (patch) | |
tree | fe21b7daf69fde6c759e6e726ec5dc50529dba62 /svtools/source | |
parent | 6104316fd50076d41039c33a5338b016e93259fe (diff) |
tdf#160867: restore HTML map export for text hyperlinks in frames
The most exciting was to discover that this functionality was actually
already implemented prior to 2001, and then accidentally dropped, and
nobody noticed, until Noel did his great cleanups, and made an amazing
investigation in commit ed2ae3c3bb0a708cafc3de6a01adc9ddc43fb859 (remove
dead SwNoteURL, 2018-03-14). The detailed commit message made my task
so much easier: I knew where and what to restore.
So this change restores relevant pieces removed over the time in commits
* 1b666235f6b0b0f0b13f473bf3b639f4f5f0b12f (loplugin:singlevalfields
improve copy constructor check, 2018-01-03),
* be8c414567f49242164b1fdfb12764b16be355c1 (loplugin:unusedmethods also
check for functions returning bool, 2018-01-19),
* 73139fe600fc1399ae828077981a2498cb0a0b0c (loplugin:unusedmethods,
2018-01-20)
* bb7ade140df807b6a0f12766a1365b8f8d0fd342 (loplugin:unusedmethods,
2018-03-08),
* ed2ae3c3bb0a708cafc3de6a01adc9ddc43fb859 (remove dead SwNoteURL,
2018-03-14),
* fd1cfd25b48cb4bd5c87e9cb317b37699ca3a1d6 (PortionType::Url is unused,
2019-01-18).
It re-implements the functionality accidentally removed in commit
da7671e4f7482110ecd0cfbfd7dbd9e0b873c81c (Opt.(FME): The new attribute
handler makes a lot of code superfluous, 2001-03-15), moving it into
SwAttrHandler, which replaced the ChgFnt in SwTxtAttr.
It also fixes the code writing the HTML image map, to output valid HTML.
And finally, it adds a unit test, to avoid repeating the story :-)
Change-Id: I72ae3cf30f0e9689f50a2c877e1622e4ae46de49
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/166924
Tested-by: Jenkins
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
Diffstat (limited to 'svtools/source')
-rw-r--r-- | svtools/source/svhtml/htmlout.cxx | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/svtools/source/svhtml/htmlout.cxx b/svtools/source/svhtml/htmlout.cxx index 956546269708..d165a8922f02 100644 --- a/svtools/source/svhtml/htmlout.cxx +++ b/svtools/source/svhtml/htmlout.cxx @@ -702,7 +702,7 @@ SvStream& HTMLOutFuncs::Out_ImageMap( SvStream& rStream, sOut.append(OString::Concat("<") + OOO_STRING_SVTOOLS_HTML_area " " OOO_STRING_SVTOOLS_HTML_O_shape - "=" + pShape + " " + "=\"" + pShape + "\" " OOO_STRING_SVTOOLS_HTML_O_coords "=\"" + aCoords + "\" "); rStream.WriteOString( sOut ); @@ -756,7 +756,7 @@ SvStream& HTMLOutFuncs::Out_ImageMap( SvStream& rStream, Out_Events( rStream, rMacroTab, pEventTable, bOutStarBasic ); - rStream.WriteChar( '>' ); + rStream.WriteOString("/>"); } } |