src/remove.[ch]: Converted plain comments into doxygen comments.
[geda-pcb/pcjc2.git] / globalconst.h
blobd7c9d42f19127174fee2f133840cb6e6511719c8
1 /*
2 * COPYRIGHT
4 * PCB, interactive printed circuit board design
5 * Copyright (C) 1994,1995,1996 Thomas Nau
7 * This program is free software; you can redistribute it and/or modify
8 * it under the terms of the GNU General Public License as published by
9 * the Free Software Foundation; either version 2 of the License, or
10 * (at your option) any later version.
12 * This program is distributed in the hope that it will be useful,
13 * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 * GNU General Public License for more details.
17 * You should have received a copy of the GNU General Public License
18 * along with this program; if not, write to the Free Software
19 * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
21 * Contact addresses for paper mail and Email:
22 * Thomas Nau, Schlehenweg 15, 88471 Baustetten, Germany
23 * Thomas.Nau@rz.uni-ulm.de
27 /* global constants
28 * most of these values are also required by files outside the source tree
29 * (manuals...)
32 #ifndef __GLOBALCONST_INCLUDED__
33 #define __GLOBALCONST_INCLUDED__
35 #ifdef HAVE_CONFIG_H
36 #include "config.h"
37 #endif
39 #include <limits.h>
41 #ifdef HAVE_STDINT_H
42 #include <stdint.h>
43 #endif
45 /* ---------------------------------------------------------------------------
46 * some file-, directory- and environment names
48 #define EMERGENCY_NAME "PCB.%.8i.save" /* %i --> pid */
49 #define BACKUP_NAME "PCB.%.8i.backup" /* %i --> pid */
51 /* ---------------------------------------------------------------------------
52 * some default values
54 #define DEFAULT_SIZE "7000x5000" /* default layout size */
55 #define DEFAULT_MEDIASIZE "a4" /* default output media */
56 #define DEFAULT_CELLSIZE 50 /* default cell size for symbols */
57 #define CLICK_TIME 200 /* default time for click expiration */
58 #define SCROLL_TIME 25 /* time between scrolls when drawing beyond border */
59 #define COLUMNS 8 /* number of columns for found pin report */
61 /* ---------------------------------------------------------------------------
62 * frame between the groundplane and the copper
64 #define GROUNDPLANEFRAME MIL_TO_COORD(15)
65 #define MASKFRAME MIL_TO_COORD(3)
67 /* ---------------------------------------------------------------------------
68 * some limit specifications
70 #define LARGE_VALUE (COORD_MAX / 2 - 1) /* maximum extent of board and elements */
72 #define MAX_LAYER 16 /* max number of copper layers */
73 #define MAX_GROUP MAX_LAYER /* max number of layer groups */
74 #define NUM_STYLES 4
75 #define MIN_LINESIZE MIL_TO_COORD(0.01) /* thickness of lines */
76 #define MAX_LINESIZE LARGE_VALUE
77 #define MIN_TEXTSCALE 10 /* scaling of text objects in percent */
78 #define MAX_TEXTSCALE 10000
79 #define MIN_PINORVIASIZE MIL_TO_COORD(20) /* size of a pin or via */
80 #define MIN_PINORVIAHOLE MIL_TO_COORD(4) /* size of a pins or vias drilling hole */
81 #define MAX_PINORVIASIZE LARGE_VALUE
82 #define MIN_PINORVIACOPPER MIL_TO_COORD(4) /* min difference outer-inner diameter */
83 #define MIN_PADSIZE MIL_TO_COORD(1) /* min size of a pad */
84 #define MAX_PADSIZE LARGE_VALUE /* max size of a pad */
85 #define MIN_DRC_VALUE MIL_TO_COORD(0.1)
86 #define MAX_DRC_VALUE MIL_TO_COORD(500)
87 #define MIN_DRC_SILK MIL_TO_COORD(1)
88 #define MAX_DRC_SILK MIL_TO_COORD(30)
89 #define MIN_DRC_DRILL MIL_TO_COORD(1)
90 #define MAX_DRC_DRILL MIL_TO_COORD(50)
91 #define MIN_DRC_RING 0
92 #define MAX_DRC_RING MIL_TO_COORD(100)
93 #define MIN_GRID 1
94 #define MAX_GRID MIL_TO_COORD(1000)
95 #define MAX_FONTPOSITION 255 /* upper limit of characters in my font */
97 #define MAX_COORD LARGE_VALUE /* coordinate limits */
98 #define MIN_SIZE MIL_TO_COORD(10) /* lowest width and height of the board */
99 #define MAX_BUFFER 5 /* number of pastebuffers */
100 /* additional changes in menu.c are */
101 /* also required to select more buffers */
103 #define DEFAULT_DRILLINGHOLE 40 /* default inner/outer ratio for */
104 /* pins/vias in percent */
106 #if MAX_LINESIZE > MAX_PINORVIASIZE /* maximum size value */
107 #define MAX_SIZE MAX_LINESIZE
108 #else
109 #define MAX_SIZE MAX_PINORVIASIZE
110 #endif
112 #ifndef MAXPATHLEN /* maximum path length */
113 #ifdef PATH_MAX
114 #define MAXPATHLEN PATH_MAX
115 #else
116 #define MAXPATHLEN 2048
117 #endif
118 #endif
120 #define MAX_LINE_POINT_DISTANCE 0 /* maximum distance when searching */
121 /* line points */
122 #define MAX_POLYGON_POINT_DISTANCE 0 /* maximum distance when searching */
123 /* polygon points */
124 #define MAX_ARC_POINT_DISTANCE 0 /* maximum distance when searching */
125 /* arc points */
126 #define MAX_ELEMENTNAMES 3 /* number of supported names of */
127 /* an element */
128 #define MAX_LIBRARY_LINE_LENGTH 255 /* maximum line length in the */
129 /* library-description file */
130 #define MAX_NETLIST_LINE_LENGTH 255 /* maximum line length for netlist files */
131 #define MAX_MODESTACK_DEPTH 16 /* maximum depth of mode stack */
132 #define MAX_CROSSHAIRSTACK_DEPTH 16 /* maximum depth of state stack */
133 #define MIN_GRID_DISTANCE 4 /* minimum distance between point */
134 /* to enable grid drawing */
135 /* size of diamond element mark */
136 #define EMARK_SIZE MIL_TO_COORD (10)
138 /* (Approximate) capheight size of the default PCB font */
139 #define FONT_CAPHEIGHT MIL_TO_COORD (45)
140 #endif