[Solved] Snippet with parameter in Qt Creator?


  • Moderators

    I'm reading about the new goodies in Qt Creator.

    I like the way we can add our own code snippets using autocompletion and local storage ( I don't know if it was already there, but i didn't use it before in Qt Creator)

    I wondered if it's possible to use parameters in a snippit?
    Eg.
    Void foo( int $PARAMETER$) {
    int width = $PARAMETER$;
    ...
    }

    when you insert the snippit you get an input to change the parameter with what you want?


  • Moderators

    qt Creator Reference documentation says you have to use TAB to go to the parameter you want, then change it and all occurences will change also.

    Nice!


Log in to reply
 

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.