Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. [Solved] How do I create a subclass of QLabel through the Qt Creator C++ Wizard?
Qt 6.11 is out! See what's new in the release blog

[Solved] How do I create a subclass of QLabel through the Qt Creator C++ Wizard?

Scheduled Pinned Locked Moved General and Desktop
2 Posts 2 Posters 2.8k Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • ? Offline
    ? Offline
    A Former User
    wrote on last edited by
    #1

    Update: had an install issue which was causing the "symbol(s) not found" error.

    Environment: Qt 5.1 Qt Creator 2.8 OSX 1.7.5

    How do I create a subclass of QLabel through the Qt Creator C++ Wizard?

    Specifically, what is the base class and type information? I have tried it about three different ways and end up with various compile errors (below). Qt has been working fine so doesn't seem like an install issue so it must be a...user issue.

    I'm new to Qt, coming from XCode/iOS dev but I'd swear I have done this before in Qt Creator.


    (this is the C++ Wizard w/ the settings I am unsure about)

    !http://i.stack.imgur.com/Gc1N3.png()!


    If I set the type information to QWidget or None I get the error

          _symbol(s) not found for architecture x86_64_
    

    If I set the type information to QObject I get the error:

           _invalid conversion from 'QObject*' to 'QWidget*'_
    
    1 Reply Last reply
    0
    • D Offline
      D Offline
      dbzhang800
      wrote on last edited by
      #2

      base class ==> QLabel

      `type information ==> QWidget

      --
      BTW, any thing can be selected in the Wizard, as all of them can be changed after the wizard in the source code.

      1 Reply Last reply
      0

      • Login

      • Login or register to search.
      • First post
        Last post
      0
      • Categories
      • Recent
      • Tags
      • Popular
      • Users
      • Groups
      • Search
      • Get Qt Extensions
      • Unsolved