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. Code folding with #pragma region "name"
Forum Update on Monday, May 27th 2025

Code folding with #pragma region "name"

Scheduled Pinned Locked Moved Solved General and Desktop
code regionsqt editorpreprocessor
3 Posts 2 Posters 529 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.
  • SavizS Offline
    SavizS Offline
    Saviz
    wrote on last edited by
    #1

    Hello everyone. I hope you are all doing well.

    I am new to the Qt framework and environment.

    I was wondering if there is any preprocessor directive similar to #pragma region "name" for creating custom code folding regions in the Qt Editor?

    I am fully aware of the "Display folding markers" settings option found under Edit->Preferences->TextEditor. Unfortunately, this option only creates folding for blocks in the code. But, I want to be able to create my own regions. Is there any solution?

    JonBJ 1 Reply Last reply
    0
    • SavizS Saviz

      Hello everyone. I hope you are all doing well.

      I am new to the Qt framework and environment.

      I was wondering if there is any preprocessor directive similar to #pragma region "name" for creating custom code folding regions in the Qt Editor?

      I am fully aware of the "Display folding markers" settings option found under Edit->Preferences->TextEditor. Unfortunately, this option only creates folding for blocks in the code. But, I want to be able to create my own regions. Is there any solution?

      JonBJ Offline
      JonBJ Offline
      JonB
      wrote on last edited by
      #2

      @Saviz
      No, sadly, there is not. At least for all the Qt Creator version I have used. Sorely missing :(

      SavizS 1 Reply Last reply
      2
      • JonBJ JonB

        @Saviz
        No, sadly, there is not. At least for all the Qt Creator version I have used. Sorely missing :(

        SavizS Offline
        SavizS Offline
        Saviz
        wrote on last edited by
        #3

        @JonB Thank you very much. At least now I know there is not a way :)

        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