[Bug 18191] Notepad should detect text type and prompt to change saved file encoding automatically

wine-bugs at winehq.org wine-bugs at winehq.org
Tue Jul 7 15:30:49 CDT 2009


http://bugs.winehq.org/show_bug.cgi?id=18191





--- Comment #25 from Austin English <austinenglish at gmail.com>  2009-07-07 15:30:49 ---
(In reply to comment #24)
> (In reply to comment #23)
> > Created an attachment (id=22231)
 --> (http://bugs.winehq.org/attachment.cgi?id=22231) [details] [details]
> > screenshot
> > 
> > Almost there. test-utf8-nobom.txt still has a problem. See screenshot.
> > 
> > Thanks for all your work!
> 
> This screenshot shows that Wine Notepad has opened the <utf8 -bom> file in
> Latin1, and WinXP has opened it in UTF-8. This is expected behaviour for Wine
> Notepad if there is no byte-order mark (0xef, 0xbb, 0xbf). I think WinXP
> Notepad should do the same as Wine, unless it has a heuristic for detecting
> UTF-8. When opening the <utf8 -bom> file, what encoding does WinXP Notepad
> select in the Open dialog? Did you override it?

It shows UTF-8. Keep in mind that utf16-le/be with no bom work fine. It's only
utf-8 that's broken.

> Maybe the byte-order mark was added back? If the file was saved within Notepad
> (either WinXP or Wine), then this would happen automatically. Try forcing
> Latin1 in WinXP and see whether the file starts with the characters  (i with
> two dots, right guillemet, inverted ?).

No, it wasn't. It's fresh from your tarball. Forcing it to open as ANSI gives:
«utf8 -bom ßłøþ»

which looks a lot like wine, except for 'Ÿ'.

Perhaps you need to use the IsTextUnicode() function here...

-- 
Configure bugmail: http://bugs.winehq.org/userprefs.cgi?tab=email
Do not reply to this email, post in Bugzilla using the
above URL to reply.
------- You are receiving this mail because: -------
You are watching all bug changes.


More information about the wine-bugs mailing list