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

QGraphicsSimpleTextItem says it is a QGraphicsItem when printed with qDebug()

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: P4: Low P4: Low
    • None
    • 6.3.2
    • Widgets: GraphicsView
    • None
    • Linux/Wayland

      If I type

      QGraphicsSimpleTextItem *test_simple_text = new QGraphicsSimpleTextItem(QStringLiteral("test simple text")); qDebug() << "*** QGraphicsSimpleTextItem:" << test_simple_text;

      it shows

      *** QGraphicsSimpleTextItem: QGraphicsItem(0x562fda1f7250, pos=0,0)

      I would expect it to display

      ** *QGraphicsSimpleTextItem: QGraphicsSimpleTextItem(0x562fda1f7250, pos=0,0, flags=(ItemUsesExtendedStyleOption))

       

      Thats's said, it works as expected with QGraphicsTextItem.

      QGraphicsTextItem *test_text = new QGraphicsTextItem("test text"); qDebug() << "*** QGraphicsTextItem:" << test_text;

      it displays

      *** QGraphicsTextItem: QGraphicsTextItem(0x562fda57e950, pos=0,0, flags=(ItemUsesExtendedStyleOption))

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

            bibr Andreas Aardal Hanssen
            delaune Olivier Delaune
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:

                There are no open Gerrit changes