winex11.drv: import X11's "text/html" as "HTML Format" (try 2)

Damjan Jovanovic damjan.jov at gmail.com
Thu Jul 24 13:07:26 CDT 2014


Implements proper importing of "text/html" into Windows's "HTML
Format". Does conversion from (Firefox's) UTF16-LE with BOM into UTF-8
w/o BOM if necessary, rewrites the HTML with libxml2 to generate a
complete HTML document with <HTML> and <BODY> tags, finds the location
of the <BODY> tag and uses its contents surrounded by
<!--startFragment --> and <!--endFragment --> comments for the
StartFragment/EndFragment addresses.

Fixes pasting rich text into a large number of apps and closes #7372.

Try 2 doesn't use C99 features, correctly calculates lengths of
unsigned ints in the HTML Format description as 10 instead of 8 bytes,
and has a better worded error message if libxml2 wasn't available at
compile time.

Feedback is appreciated.

Damjan Jovanovic
---
 dlls/winex11.drv/Makefile.in |   4 +-
 dlls/winex11.drv/clipboard.c | 157 ++++++++++++++++++++++++++++++++++++++++++-
 2 files changed, 158 insertions(+), 3 deletions(-)
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-winex11.drv-import-X11-s-text-html-as-HTML-Format.txt
Type: text/x-patch
Size: 7522 bytes
Desc: not available
URL: <http://www.winehq.org/pipermail/wine-patches/attachments/20140724/2e5e855c/attachment.bin>


More information about the wine-patches mailing list