[webkit-reviews] review denied: [Bug 5187] UTF-8 in long text files breaks at some point : [Attachment 4173] proposed patch

bugzilla-request-daemon at opendarwin.org bugzilla-request-daemon at opendarwin.org
Thu Oct 6 10:25:09 PDT 2005


Darin Adler <darin at apple.com> has denied Alexey Proskuryakov <ap at nypop.com>'s
request for review:
Bug 5187: UTF-8 in long text files breaks at some point
http://bugzilla.opendarwin.org/show_bug.cgi?id=5187

Attachment 4173: proposed patch
http://bugzilla.opendarwin.org/attachment.cgi?id=4173&action=edit

------- Additional Comments from Darin Adler <darin at apple.com>
The long term fix for this is to implement text viewing using the HTML view --
we've planned to make this change for a while, but in the mean time this is a
great fix to have.

Since the WebCoreDecoder class is new code, the headers should say 2005, not
2003.

No need to initialize variables to 0 in Objective-C, they are all set to 0
automatically.

I think the code in appendReceivedData would read better if textEncodingName
was set inside the if instead of having two separate branches that both create
a decoder.

WebCoreDecoder needs a finalize method that deletes the QTextCodec for when
we're used in GC mode.

For files in the KWQ directory, we should use the real filenames with ""
instead of the Qt names with <>. So #import "KWQTextCodec.h".

initWithEncodingName should use QTextCodec::codecForName. I don't think that
it's worth it to use KGlobal and KCharsets just to get the Latin-1 default.
It's just two lines of code. Or we could consider having WebCoreDecoder return
nil when passed an encoding name it doesn't know, and have the "fall back on
Latin-1" rule out in WebTextView.



More information about the webkit-reviews mailing list