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

simplify html created by qtextedit (again)

XMLWordPrintable

    • Icon: Suggestion Suggestion
    • Resolution: Out of scope
    • Icon: Not Evaluated Not Evaluated
    • None
    • 4.6.0
    • GUI: Text handling
    • None

      quoting a user:

      Up to Qt 4.5, a simple formatted text with 10 and 12pt text I would get HTML code like this one:

              <source>&lt;h3&gt;QHiMDTransfer, Version 0.0.1&lt;/h3&gt;
              &lt;p&gt;&lt;p&gt;
              &lt;p&gt;A free music transfer software for MiniDisc walkman.&lt;/p&gt;
              &lt;p&gt;&lt;p&gt;
              &lt;p&gt;Brought to you by the linux-minidisc project:&lt;/p&gt;
              &lt;p&gt;&lt;p&gt;
              &lt;p&gt;https://wiki.physik.fu-berlin.de/linux-minidisc&lt;/p&gt;
              &lt;p&gt;&lt;p&gt;
              &lt;p&gt;This software is covered by the GNU GPL v2 license. See the
               file LICENSE in the program folder for more information.&lt;/p&gt;</source>
      

      Now, using Qt Creator from Qt 4.6.2 (1.3.1) to edit and display the same text would result in a far more complex HTML code:

      <source>&lt;!DOCTYPE HTML PUBLIC &quot;-//W3C//DTD HTML 4.0//EN&quot; &quot;http://www.w3.org/TR/REC-html40/strict.dtd&quot;&gt;
      &lt;html&gt;&lt;head&gt;&lt;meta name=&quot;qrichtext&quot; content=&quot;1&quot; /&gt;&lt;style type=&quot;text/css&quot;&gt;
      p, li { white-space: pre-wrap; }
      &lt;/style&gt;&lt;/head&gt;&lt;body style=&quot; font-family:&apos;Sans&apos;; font-size:10pt; font-weight:400; font-style:normal;&quot;&gt;
      &lt;p style=&quot; margin-top:14px; margin-bottom:12px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;&quot;&gt;&lt;span style=&quot; font-size:large; font-weight:600;&quot;&gt;QHiMDTransfer, Version 0.0.1&lt;/span&gt; &lt;/p&gt;
      &lt;p style=&quot; margin-top:12px; margin-bottom:12px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;&quot;&gt;A free music transfer software for MiniDisc walkman. &lt;/p&gt;
      &lt;p style=&quot; margin-top:12px; margin-bottom:12px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;&quot;&gt;Brought to you by the linux-minidisc project: &lt;/p&gt;
      &lt;p style=&quot; margin-top:12px; margin-bottom:12px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;&quot;&gt;https://wiki.physik.fu-berlin.de/linux-minidisc &lt;/p&gt;
      &lt;p style=&quot; margin-top:12px; margin-bottom:12px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;&quot;&gt;This software is covered by the GNU GPL v2 license. See the file LICENSE in the program folder for more information.&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</source>
      

      Since Qt Linguist does not render the HTML but displays the raw source code, translators which not necessarily have in-depth HTML knowledge face the problem having to deal with that raw and really complex HTML code. Even for people with HTML knowledge, editing the text for translation is very tedious.

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

            esabraha Eskil Abrahamsen Blomfeldt
            buddenha Oswald Buddenhagen
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved:

                There are no open Gerrit changes