Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Qt Creator and other tools
  4. Qt Creator "Follow Symbol Under Cursor"
Forum Updated to NodeBB v4.3 + New Features

Qt Creator "Follow Symbol Under Cursor"

Scheduled Pinned Locked Moved Qt Creator and other tools
qt creatorfile navigation
3 Posts 2 Posters 4.5k 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.
  • S Offline
    S Offline
    stoptherock1
    wrote on 1 Apr 2015, 12:00 last edited by stoptherock1 4 Sept 2015, 14:11
    #1

    Hello everyone,

    I find "Follow Symbol Under Cursor" feature very useful and I use it frequently in my everyday work. But there is one issue, which sometimes makes this feature totally useless.
    Mostly I am working with C/C++ projects in Qt Creator and if I have some function defined in 1 header (interface), but there is several different implementations (depending on build configuration), pressing the "Follow Symbol Under Cursor" shortcut just moves me to one of the implementations, so I have no chance to choose, in which implementation I am interested in right now.
    From my point of view, it will be more useful, if in case of more than 1 implementation Qt Creator will ask me about it (some drop-down list, for example), so I will be able to choose particular implementation.

    Is there any additional configuration options in Qt Creator, which I should check, or there is no such functionality so far?

    UPDATE: I've created a suggestion ticket Qt's JIRA:
    https://bugreports.qt.io/browse/QTCREATORBUG-14257

    1 Reply Last reply
    0
    • J Offline
      J Offline
      Jeroentjehome
      wrote on 1 Apr 2015, 12:22 last edited by
      #2

      Hi,
      The solution is in multiple files. When you have multiple definitions of your functions and only 1 declaration you should place those definitions into multiple files and in your project file include the right cpp or c file that holds the wanted definition.
      e.g.
      #(CONFIGURED_A) // Or something like this, read the docs
      SOURCES += MyFirstFile.c
      #else
      SOURCES += MySecondFile.c
      #endif

      Greetz, Jeroen

      S 1 Reply Last reply 1 Apr 2015, 15:31
      1
      • J Jeroentjehome
        1 Apr 2015, 12:22

        Hi,
        The solution is in multiple files. When you have multiple definitions of your functions and only 1 declaration you should place those definitions into multiple files and in your project file include the right cpp or c file that holds the wanted definition.
        e.g.
        #(CONFIGURED_A) // Or something like this, read the docs
        SOURCES += MyFirstFile.c
        #else
        SOURCES += MySecondFile.c
        #endif

        S Offline
        S Offline
        stoptherock1
        wrote on 1 Apr 2015, 15:31 last edited by stoptherock1 4 Jan 2015, 15:32
        #3

        @Jeroentjehome
        Thanks for the reply. It fixes the problem, for sure.
        But in the other hand such feature would be very useful.
        I will create a feature request and post it here later, if somebody else is also interested.

        1 Reply Last reply
        0

        2/3

        1 Apr 2015, 12:22

        • Login

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