The size of a level is determined by the Height Field Size and the Square Size.
The Height Field Size is the number of "terrain tiles" per side that the level will have. (It is in fact the number of pixels of the HField.pcx/HField.png file and other files in the level folder.) All DH2004 and DH2005 levels use 640 x 640 here, or 640 terrain tiles per side. TH2003 levels use 64, 128, 256, 512 or 1024 terrain tiles per side.
The Square Size is the size of each "terrain tile" in decimeters. All DH2004 and DH2005 levels use 40 here, or 4 meters per terrain tile. TH2003 levels use 20, 30, 40, 60, 80, 100, 120 or 160.
These values are shown when creating a new level. They can be changed in TH2003 but not in DH2004 or DH2005.
The size of the level is the number of terrain tiles x the terrain tile size, the Height Field size x the Square Size.
In DH2004/05: 640 x 40 = 25600dm = 2560m, so just over 2.5km.
In TH2003 any combination of the values mentioned above. (Which result in levels of 128, 192, 256, 384, 512, 640, 768, 1024, 1280, 1536, 2048, 2560, 3072, 4096, 5120, 6144, 8192, 10240, 12288 or 16384m per side.)
So ranging from 128m to over 16km.
2) Now this is how to make a level any size you like:
First create a new level. Fill in the New Level Data. For TH2003 choose the Height Field Size you want to use (see below). Immediately save the new level and exit the editor.
Go to your level folder and open the level.ter with notepad. Scroll down until you see the line PixelSize = 40.000000; and change to Pixelsize = 31.250000; This value is the Square Size and we now can change this to anything we want. A higher number gives a bigger level and a lower number a smaller level.
Save and close. Open the level again in the editor and start building.
3) But what values to use?
As we have seen above, Level Size = Height Field size x Square Size. So: Square Size = Level Size : Height Field Size.
Now if we want to make a level of, for example, 3072m wide in DH2004/05 the Square Size should be 30720 : 640 = 48. So we change the Pixelsize in notepad to Pixelsize = 48.000000;
In TH2003 we have to decide first which Height Field Size suits our new level best and choose this when creating the level (see above). If we want to make a level of, for example, 2560m wide and want to use a Height Field Size of 512 the Square Size should be 25600 : 512 = 50. So we change the Pixelsize in notepad to Pixelsize = 50.000000;
Theres just one restriction in DH2004/05, the game won't accept levels smaller than 2km. So the smallest Square Size you can use in DH2004/05 is 20000 : 640 = 31.25 -> Pixelsize = 31.250000;