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

Support "list-style-type: none" in CSS parsing

    XMLWordPrintable

Details

    • 2a70677b64e61d7b136e4fa3725be53258327b42

    Description

      There is a very simple 1 line change to support this. The code already deals with parsing the "none" tag and not drawing any bullets. I would suggest in "src/gui/text/qtexthtmlparser.cpp", in function "QTextHtmlParserNode::setListStyle" adding:

      case QCss::Value_None: hasOwnListStyle = true; listStyle = QTextListFormat::ListStyleUndefined; break;

      to the case statement. Then html code such as the example given below will function.

      Thanks,
      Paul

      -------------------------
      <html>

      <head>
      <meta http-equiv="content-type" content="text/html; charset=us-ascii">
      <style type="text/css">
      ul.none

      { list-style-type: none; }

      </style>
      </head>

      <body>
      <ul class="none">
      <li>menu: <em>File->Export</em>
      <li>Symbols, and diffs can be exported.
      <li>This file might be very large!
      </ul>

      </body>
      </html>

      Attachments

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

        Activity

          People

            dvratil Daniel Vrátil
            pstark Paul Stark
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes