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. What class of Qt can replace the class CPtrList of MFC?

What class of Qt can replace the class CPtrList of MFC?

Scheduled Pinned Locked Moved Solved General and Desktop
5 Posts 4 Posters 1.0k Views
  • 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.
  • small_birdS Offline
    small_birdS Offline
    small_bird
    wrote on last edited by
    #1

    The question is as the title: What class of Qt can replace the class CPtrList of MFC?

    beeckscheB 1 Reply Last reply
    0
    • small_birdS small_bird

      The question is as the title: What class of Qt can replace the class CPtrList of MFC?

      beeckscheB Offline
      beeckscheB Offline
      beecksche
      wrote on last edited by
      #2

      @small_bird
      I don't know what the CPtrList class normally does, but as i think it is a list which stores pointers?

      Have a look here.

      1 Reply Last reply
      0
      • E Offline
        E Offline
        Eeli K
        wrote on last edited by
        #3

        Yes it seems to be a list of pointers, https://msdn.microsoft.com/en-us/library/0sbwsc4e.aspx. Beecksche gave a proper link. But in many cases you can also use the standard C++ STL containers if you want (http://en.cppreference.com/w/cpp/container, http://www.cplusplus.com/reference/stl/).

        beeckscheB 1 Reply Last reply
        0
        • E Eeli K

          Yes it seems to be a list of pointers, https://msdn.microsoft.com/en-us/library/0sbwsc4e.aspx. Beecksche gave a proper link. But in many cases you can also use the standard C++ STL containers if you want (http://en.cppreference.com/w/cpp/container, http://www.cplusplus.com/reference/stl/).

          beeckscheB Offline
          beeckscheB Offline
          beecksche
          wrote on last edited by
          #4

          @Eeli-K
          When using the Qt Framework i would prefer the Qt containers:

          These container classes are designed to be lighter, safer, and easier to use than the STL containers

          mrjjM 1 Reply Last reply
          1
          • beeckscheB beecksche

            @Eeli-K
            When using the Qt Framework i would prefer the Qt containers:

            These container classes are designed to be lighter, safer, and easier to use than the STL containers

            mrjjM Offline
            mrjjM Offline
            mrjj
            Lifetime Qt Champion
            wrote on last edited by mrjj
            #5

            @beecksche
            a QList<Type *> would work the same it seems.
            The access functions are very similar but of course named differently.

            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