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. How to make overloaded constructors?
Forum Updated to NodeBB v4.3 + New Features

How to make overloaded constructors?

Scheduled Pinned Locked Moved General and Desktop
2 Posts 2 Posters 1.0k 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.
  • N Offline
    N Offline
    nicky j
    wrote on 15 Mar 2014, 23:27 last edited by
    #1

    Hey there,

    How can I make a subclass of QAction with overloaded constructors. I would like to make a few different versions of my QAction subclass all with different arguments. How do I do this?

    Thanks!

    1 Reply Last reply
    0
    • C Offline
      C Offline
      ChrisW67
      wrote on 16 Mar 2014, 04:47 last edited by
      #2

      You overload constructors exactly the same way you overload any other function. There are plenty of such examples in the Qt API docs, including QAction itself.

      1 Reply Last reply
      0

      1/2

      15 Mar 2014, 23:27

      • Login

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