Results 1 to 1 of 1

Thread: QSvgRenderer crash

  1. #1
    Join Date
    Nov 2010
    Posts
    31
    Thanks
    11
    Qt products
    Qt4
    Platforms
    Unix/X11

    Default QSvgRenderer crash

    Hi all.

    I have encountered an svg icon that is crashing my application, however icon is properly visible under any image viewer.
    When application is crashing it gives little information about what may caused it to crash, I have prepared an example which does as follow:
    load svg icon into QGraphicsSvgItem, set scale of the item, and then render this item on QImage as a test.png file.
    Project is attached, you can simply start it in QtCreator.
    Can someone point me what can be wrong with this icon, or maybe there is a bug in QtSVG ? I'm using Qt 4.7.3 on Linux machine.
    Output from debugger is:

    Thread 1 (Thread 0xb62c0710 (LWP 8531)):
    #0 0xb6a78c6f in ?? () from /home/franki/QtSDK/Desktop/Qt/473/gcc/lib/libQtGui.so.4
    No symbol table info available.
    #1 0xb6a7990f in ?? () from /home/franki/QtSDK/Desktop/Qt/473/gcc/lib/libQtGui.so.4
    No symbol table info available.
    #2 0xb6a7fd82 in QFontDatabase::load(QFontPrivate const*, int) () from /home/franki/QtSDK/Desktop/Qt/473/gcc/lib/libQtGui.so.4
    No symbol table info available.
    #3 0xb6a57615 in QFontPrivate::engineForScript(int) const () from /home/franki/QtSDK/Desktop/Qt/473/gcc/lib/libQtGui.so.4
    No symbol table info available.
    #4 0xb6a953d6 in ?? () from /home/franki/QtSDK/Desktop/Qt/473/gcc/lib/libQtGui.so.4
    No symbol table info available.
    #5 0xb6aa3395 in QTextLine::layout_helper(int) () from /home/franki/QtSDK/Desktop/Qt/473/gcc/lib/libQtGui.so.4
    No symbol table info available.
    #6 0xb6aa4fa0 in QTextLine::setNumColumns(int) () from /home/franki/QtSDK/Desktop/Qt/473/gcc/lib/libQtGui.so.4
    No symbol table info available.
    #7 0xb6aa5103 in QTextLayout::createLine() () from /home/franki/QtSDK/Desktop/Qt/473/gcc/lib/libQtGui.so.4
    No symbol table info available.
    #8 0xb7785082 in ?? () from /home/franki/QtSDK/Desktop/Qt/473/gcc/lib/libQtSvg.so.4
    No symbol table info available.
    #9 0xb77a77f3 in ?? () from /home/franki/QtSDK/Desktop/Qt/473/gcc/lib/libQtSvg.so.4
    No symbol table info available.
    #10 0xb77a77f3 in ?? () from /home/franki/QtSDK/Desktop/Qt/473/gcc/lib/libQtSvg.so.4
    No symbol table info available.
    #11 0xb77aed53 in QSvgTinyDocument::draw(QPainter*, QRectF const&) () from /home/franki/QtSDK/Desktop/Qt/473/gcc/lib/libQtSvg.so.4
    No symbol table info available.
    #12 0xb77aee29 in QSvgTinyDocument::draw(QPainter*) () from /home/franki/QtSDK/Desktop/Qt/473/gcc/lib/libQtSvg.so.4
    No symbol table info available.
    #13 0xb77b0efe in QSvgRenderer::render(QPainter*) () from /home/franki/QtSDK/Desktop/Qt/473/gcc/lib/libQtSvg.so.4
    No symbol table info available.
    #14 0x080493da in main (argc=1, argv=0xbffa4684) at main.cpp:30
    a = <incomplete type>
    itemRenderer = 0x9205ca0
    scale = 0.69999999999999996
    size = {wd = 100, ht = 100}
    svgFileName = {static null = {<No data fields>}, static shared_null = {ref = {_q_value = 235}, alloc = 0, size = 0, data = 0x804b3e6, clean = 0, simpletext = 0, righttoleft = 0, asciiCache = 0, capacity = 0, reserved = 0, array = {0}}, static shared_empty = {ref = {_q_value = 1}, alloc = 0, size = 0, data = 0xb7772132, clean = 0, simpletext = 0, righttoleft = 0, asciiCache = 0, capacity = 0, reserved = 0, array = {0}}, d = 0x92057b0, static codecForCStrings = 0x0}
    img = 0x9205ea8
    pai = 0x92168b8
    item = 0x91fcb28
    args = {<QList<QString>> = {{p = {static shared_null = {ref = {_q_value = 263}, alloc = 0, begin = 0, end = 0, sharable = 1, array = {0x0}}, d = 0x91fcaf8}, d = 0x91fcaf8}}, <No data fields>}
    outFile = {static null = {<No data fields>}, static shared_null = {ref = {_q_value = 235}, alloc = 0, size = 0, data = 0x804b3e6, clean = 0, simpletext = 0, righttoleft = 0, asciiCache = 0, capacity = 0, reserved = 0, array = {0}}, static shared_empty = {ref = {_q_value = 1}, alloc = 0, size = 0, data = 0xb7772132, clean = 0, simpletext = 0, righttoleft = 0, asciiCache = 0, capacity = 0, reserved = 0, array = {0}}, d = 0x920e7f8, static codecForCStrings = 0x0}
    result = 8

    Best Regards
    Marek
    Attached Files Attached Files

Similar Threads

  1. QSvgRenderer antialiasing
    By jonks in forum Qt Programming
    Replies: 4
    Last Post: 19th July 2013, 09:39
  2. QSvgRenderer and QWidget
    By lexqqq in forum Qt Programming
    Replies: 0
    Last Post: 31st October 2010, 11:51
  3. QSvgRenderer not always working
    By BlandSauce in forum Newbie
    Replies: 3
    Last Post: 29th March 2010, 04:08
  4. QSvgRenderer and object's shape
    By Dusdan in forum Qt Programming
    Replies: 8
    Last Post: 3rd December 2007, 12:42
  5. About QSvgRenderer
    By guher in forum Qt Programming
    Replies: 1
    Last Post: 22nd November 2007, 10:21

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.