Default file layout in C ++ Builder (and Delphi)

I have been seriously annoyed with the C ++ Builder IDE for some time. When I code, I always use the standard layout for code files. I have a standard header that I use, including, i.e. License of file, file name, date, etc.

But I could not find anywhere to insert this, so when I - for example - create a new block, automatically insert this header. Of course, I can insert it every time, but it's a little annoying to use this time.

So my question is: is it possible to create a file template for C ++ files by default or modify existing ones so that they always start with my predefined layout. My fear is that, like most other things in the C ++ Builder development environment, this is hard-coded in it.

Creating a new module is currently creating a .cpp file with:

//---------------------------------------------------------------------------


#pragma hdrstop

#include "Unit1.h"

//---------------------------------------------------------------------------

#pragma package(smart_init)

and the corresponding header file:

//---------------------------------------------------------------------------

#ifndef Unit1H
#define Unit1H
//---------------------------------------------------------------------------
#endif

This is what I want to change into my own layout.

I am using Codegear C ++ Builder 2007.

+3
source share
2 answers

See "Adding items to the object repository" in the help file.

,  1. (),  2. Project →  3. .  4. → ...

. , , .

+4
+1

Source: https://habr.com/ru/post/1708898/


All Articles