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

QPainter::drawTextItem crash

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: P1: Critical
    • Resolution: Done
    • Affects Version/s: 5.9.1
    • Fix Version/s: 5.9.2
    • Component/s: GUI: Font handling
    • Labels:
      None
    • Environment:

      Description

       Code that works on 5.6.2 crashes when compiled against 5.9.1:

      1 FPFontCopyGlyphPath 0x7fffb8fe0209 
      2 CGFontCreateGlyphPath 0x7fffbae14ffb 
      3 CGFontCreateGlyphBitmapWithDilation 0x7fffbaaecce5 
      4 CGGlyphBuilder::create_missing_bitmaps(CGGlyphIdentifier const *, unsigned long, CGGlyphBitmap const * *) 0x7fffbad640a5 
      5 CGGlyphBuilder::lock_glyph_bitmaps(CGGlyphIdentifier const *, unsigned long, CGGlyphBitmap const * *) 0x7fffbad63df4 
      6 render_glyphs 0x7fffbaad6d87 
      7 draw_glyph_bitmaps 0x7fffbaad69c2 
      8 ripc_DrawGlyphs 0x7fffbaad5ae4 
      9 draw_glyphs 0x7fffbad92a1e 
      10 DrawSbixGlyphsAtPositions(TFont const *, unsigned short const *, CGPoint const *, unsigned long, CGContext *, CGAffineTransform, CGAffineTransform) 0x7fffbbc1ec00 
      11 CTFontDrawGlyphs 0x7fffbbc1f0cd 
      12 QCoreTextFontEngine::imageForGlyph(unsigned int, QFixed, bool, QTransform const&) 0x10956f9d5 
      13 QCoreTextFontEngine::alphaRGBMapForGlyph(unsigned int, QFixed, QTransform const&) 0x10956fcde 
      14 QImageTextureGlyphCache::fillTexture(QTextureGlyphCache::Coord const&, unsigned int, QFixed) 0x10615bcd4 
      15 QTextureGlyphCache::fillInPendingGlyphs() 0x10615b843 
      16 QRasterPaintEngine::drawCachedGlyphs(int, unsigned int const *, QFixedPoint const *, QFontEngine *) 0x1060f696a 
      17 QRasterPaintEngine::drawTextItem(QPointF const&, QTextItem const&) 0x1060f7636 
      18 QPainterPrivate::drawTextItem(QPointF const&, QTextItem const&, QTextEngine *) 0x106111c79 
      19 QPainter::drawText(QPointF const&, QString const&, int, int) 0x10610ef3c 
      20 QPainter::drawText(int, int, QString const&) qpainter.h 892 0x10008bfd5 
      21 ccGLWindow::renderText(int, int, QString const&, QFont const&) ccGLWindow.cpp 6543 0x100376419 
      22 ccGLWindow::drawForeground(ccGLDrawContext&, ccGLWindow::RenderingParams&) ccGLWindow.cpp 2470 0x10037b41e 
      23 ccGLWindow::fullRenderingPass(ccGLDrawContext&, ccGLWindow::RenderingParams&) ccGLWindow.cpp 2102 0x1003791d1 
      24 ccGLWindow::paintGL() ccGLWindow.cpp 1521 0x1003770c7 
      ...

       
      Stack trace on Windows:

      1  QPaintEngineEx::state                qpaintengineex_p.h      141  0x7ffaaa92472e 
      2  QRasterPaintEngine::state            qpaintengine_raster_p.h 157  0x7ffaaa9247a3 
      3  QRasterPaintEnginePrivate::clip      qpaintengine_raster_p.h 487  0x7ffaaabe4142 
      4  QRasterPaintEngine::alphaPenBlt      qpaintengine_raster.cpp 2569 0x7ffaaabeff63 
      5  QRasterPaintEngine::drawCachedGlyphs qpaintengine_raster.cpp 2874 0x7ffaaabefad0 
      6  QRasterPaintEngine::drawTextItem     qpaintengine_raster.cpp 3081 0x7ffaaabed23f 
      7  QPainterPrivate::drawTextItem        qpainter.cpp            6512 0x7ffaaac19a20 
      8  QTextLine::draw                      qtextlayout.cpp         2612 0x7ffaaaa13ca1 
      9  qt_format_text                       qpainter.cpp            7641 0x7ffaaac1c752 
      10 QPainter::drawText                   qpainter.cpp            5938 0x7ffaaac13f56 
      11 drawStr                              main.cpp                21   0x7ff7391026f7 
      12 main                                 main.cpp                33   0x7ff739102842 
      13 WinMain                              qtmain_win.cpp          104  0x7ff739105d4d 
      14 __tmainCRTStartup                    crtexe.c                618  0x7ff7391050e1 
      15 WinMainCRTStartup                    crtexe.c                466  0x7ff739104e5e 
      16 BaseThreadInitThunk                  KERNEL32                     0x7ffaee628364 
      17 RtlUserThreadStart                   ntdll                        0x7ffaef1170d1 
      

      This is when compiling the CloudCompare project which is rather large. If nobody has any insight or suggestions I will try to reproduce with a small example.

        Attachments

          Issue Links

          For Gerrit Dashboard: QTBUG-61863
          # Subject Branch Project Status CR V

            Activity

              People

              Assignee:
              allan.jensen Allan Sandfeld Jensen
              Reporter:
              asm Andy M
              Votes:
              0 Vote for this issue
              Watchers:
              5 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:

                  Gerrit Reviews

                  There are no open Gerrit changes