Hi @Patryk Stepien,
Welcome to Microsoft Q&A!
I tested on my side and was unable to find a setting to change the indentation behavior in C++.
You can request a feature by selecting “Help” menu > Send Feedback > Suggest a Feature.
Update:
I found it is different between VS2022 Community version 17.4.2 and version 17.6.2.
In version 17.4.2, the indentation behaves as you expect.
You can try to roll back to your VS2022 to the version 17.4.x if you need.
Or you can report it to product team in Developer Community.
Sincerely,
Anna
If the answer is the right solution, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".
Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.