Issue 113249 - HTML clipboard broken
Summary: HTML clipboard broken
Status: CLOSED FIXED
Alias: None
Product: Calc
Classification: Application
Component: open-import (show other issues)
Version: OOO330m1
Hardware: All All
: P3 Trivial (vote)
Target Milestone: ---
Assignee: oc
QA Contact: issues@sc
URL:
Keywords:
Depends on:
Blocks: 111112
  Show dependency tree
 
Reported: 2010-07-19 15:11 UTC by oc
Modified: 2017-05-20 10:33 UTC (History)
1 user (show)

See Also:
Issue Type: DEFECT
Latest Confirmation in: ---
Developer Difficulty: ---


Attachments
Example file (HTML in UCS2 with BOM) (156 bytes, text/html)
2010-07-20 18:09 UTC, niklas.nebel
no flags Details
diff for simple fix (1.03 KB, text/plain)
2010-07-28 09:41 UTC, Mathias_Bauer
no flags Details

Note You need to log in before you can comment on or make changes to this issue.
Description oc 2010-07-19 15:11:19 UTC
In Firefox select some contents and copy to Spreadsheet via ctrl-c ctrl-v => the
content of the clipboard is pasted in one cell as HTML-source instead of
multiple cells in HTML format
Comment 1 niklas.nebel 2010-07-20 18:10:00 UTC
Created attachment 70721 [details]
Example file (HTML in UCS2 with BOM)
Comment 2 niklas.nebel 2010-07-20 18:11:10 UTC
The problem with Copy&Paste from Firefox is only on Linux/Solaris, but the same
effect can be seen on all platforms by opening the attached file as HTML (Calc).

It's caused by the missing SetSwitchToUCS2 call in EditHTMLParser (used to be
derived from SfxHTMLParser).
Comment 3 niklas.nebel 2010-07-20 18:14:27 UTC
Note: Writer doesn't seem to call SetSwitchToUCS2 either, but doesn't have the
problem. It's probably handled in a different way.
Comment 4 niklas.nebel 2010-07-20 18:31:54 UTC
Ignore the previous comment. Writer of course doesn't have a problem because it
still uses SfxHTMLParser (but the call can't be removed from SfxHTMLParser).
Comment 5 Mathias_Bauer 2010-07-28 09:40:42 UTC
I don't understand the last comment, but anyway: the fix is easy, just copy some
code from the ctor of SfxHTMLParser to the EditEngHTMLParser.

As all existing HTML parsers use that code, perhaps we can move that to the base
class later. For a showstopper fix that would be too much, IMHO.
Comment 6 Mathias_Bauer 2010-07-28 09:41:49 UTC
Created attachment 70857 [details]
diff for simple fix
Comment 7 Mathias_Bauer 2010-07-28 09:42:21 UTC
Carsten, please integrate this fix into a suitable CWS.
Comment 8 mikhail.voytenko 2010-08-12 12:01:27 UTC
mav->oc: Please verify the issue.
Comment 9 oc 2010-08-24 16:44:35 UTC
verified in internal build cws_fwk152