Issue 113249

Summary: HTML clipboard broken
Product: Calc Reporter: oc
Component: open-importAssignee: oc
Status: CLOSED FIXED QA Contact: issues@sc <issues>
Severity: Trivial    
Priority: P3 CC: issues
Version: OOO330m1   
Target Milestone: ---   
Hardware: All   
OS: All   
Issue Type: DEFECT Latest Confirmation in: ---
Developer Difficulty: ---
Issue Depends on:    
Issue Blocks: 111112    
Attachments:
Description Flags
Example file (HTML in UCS2 with BOM)
none
diff for simple fix none

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