Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-134000

Reuse charset parser from QtNetwork elsewhere

    XMLWordPrintable

Details

    Description

      Charset parsing is done in at least

      • QStringConverter::encodingForHtml()
      • qtwebengine/src/core/net/url_request_custom_job_proxy.cpp in QtWebengine
      • ...

      Unconfirmed further hits:

      • qtbase/src/corelib/io/qdataurl.cpp
      • qtbase/src/gui/platform/darwin/qutimimeconverter.mm
      • qtbase/src/gui/text/qcssparser.cpp (probably different syntax, so maybe not applicable)
      • qtbase/src/gui/text/qtexthtmlparser.cpp (in a ### comment)
      • qtbase/ src/plugins/platforms/xcb/qxcbmime.cpp

      We should make the code from QtNetwork more accessible (move to _p.h), move it to QtCore (to satisfy dependency chain) and then port the other parsers to it, because the QtNetwork one is the only one that can actually parse the full RFC.

      Note that some users (sometimes manually) parse HTML/XML attributes and others parse MIME headers. The QtNetwork code parses MIME, so it may be only partially applicable, and/or needs to be extended for other users.

      Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            cnn Qt Core & Network
            mmutz Marc Mutz
            Vladimir Minenko Vladimir Minenko
            Alex Blasche Alex Blasche
            Votes:
            0 Vote for this issue
            Watchers:
            6 Start watching this issue

            Dates

              Created:
              Updated:

              Gerrit Reviews

                There are no open Gerrit changes