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

QPainter drops e.g. lines using small (< 1e-12) user world coords

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Reported
    • Priority: P2: Important
    • Resolution: Unresolved
    • Affects Version/s: 5.12.0
    • Fix Version/s: None
    • Component/s: GUI: Painting
    • Labels:
      None
    • Environment:
      MacOS 10.11, 10.12 XCode
      Windows 8, 10 Visual Studio

      Description

      QCosmeticStroker::drawLine(const QPointF &p1, const QPointF &p2)

      performs a comparison of both input QPointF parameters BEFORE they are transformed into device coords!

      If the coordinates are < 1e-12 only a single point is drawn because of usage of qFuzzyIsNull in operator==

       

      We use scientific data, like pico and nano amps! Most likely there are more issues of this nature!

       

      SOURCE CODE

      void QCosmeticStroker::drawLine(const QPointF &p1, const QPointF &p2)

      }{{   

      // comparison should be on start and end below, not p1 and p2

      {{  if (p1 == p2) }}

        { }}{{          

          drawPoints(&p1, 1);{{        }}

          return;{{    }}

         } {{    }}

         QPointF start = p1 * state->matrix;{{    }}

         QPointF end = p2 * state->matrix;

         .

         .

         .

      }

        Attachments

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

          Activity

            People

            • Assignee:
              vgt Eirik Aavitsland
              Reporter:
              ulix Ulrich Rexhausen
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:

                Gerrit Reviews

                There are no open Gerrit changes