Subversion-Projekte lars-tiefland.php_share

Revision

Details | Letzte Änderung | Log anzeigen | RSS feed

Revision Autor Zeilennr. Zeile
1 lars 1
<?php
2
// $Header: /cvsroot/html2ps/config.inc.php,v 1.50 2007/05/17 13:55:13 Konstantin Exp $
3
 
4
/**
5
 * Common configuration options
6
 */
7
 
8
// Directory containing HTML2PS script files (with traling slash)
9
if (!defined('HTML2PS_DIR')) {
10
  define('HTML2PS_DIR', dirname(__FILE__).DIRECTORY_SEPARATOR);
11
};
12
 
13
// User-Agent HTTP header to send when requesting a file
14
define('DEFAULT_USER_AGENT',"Mozilla/5.0 (Windows; U; Windows NT 5.1; rv:1.7) Gecko/20040803 Firefox/0.9.3");
15
 
16
// Default PDF or PS file name to use
17
define('OUTPUT_DEFAULT_NAME','unnamed');
18
 
19
// Default text encoding to use when no encoding information is available
20
define('DEFAULT_ENCODING', 'iso-8859-1');
21
 
22
/**
23
 * Postscript-specific configuration options
24
 */
25
 
26
// Path to Ghostscript executable
27
define('GS_PATH','c:\Program Files\gs\gs8.54\bin\gswin32c.exe');
28
 
29
// Path to font metric files (AFM files).
30
// NOTE: Trailing backslash required
31
define('TYPE1_FONTS_REPOSITORY', "c:\\Program Files\\gs\\fonts\\");
32
// define('TYPE1_FONTS_REPOSITORY',"/usr/share/ghostscript/fonts/");
33
 
34
/**
35
 * PDFLIB-specific configuration options
36
 */
37
 
38
// Path to PDFLIB dynamically loaded library (if not configured in php.ini to load automatically)
39
define('PDFLIB_DL_PATH','pdflib.so');
40
 
41
// Uncomment this if you have PDFLIB license key and want to use it
42
// define('PDFLIB_LICENSE', 'YOUR LICENSE KEY');
43
 
44
// This variable defines the path to PDFLIB configuration file; in particular, it contains
45
// information about the supported encodings.
46
//
47
// define('PDFLIB_UPR_PATH',"c:/php/php4.4.0/pdf-related/pdflib.upr");
48
// define('PDFLIB_UPR_PATH',"c:/php/pdf-related/pdflib.upr");
49
 
50
// Path to directory containing fonts used by PDFLIB / FPDF
51
// Trailing backslash required
52
define('TTF_FONTS_REPOSITORY',HTML2PS_DIR."fonts/");
53
 
54
// Determines how font files are embedded. May be:
55
// 'all' - embed all fonts
56
// 'none' - do not embed any fonts
57
// 'config' - whether font is embedded is determined by html2ps.config 'embed' attribute value for this font
58
define('FONT_EMBEDDING_MODE', 'config');
59
 
60
/**
61
 * Some constants you better not change.
62
 *
63
 * They're created in order to avoid using too much "magic numbers" in the script source,
64
 * but it is very unlikely you'll need to change them
65
 */
66
 
67
define('EPSILON',0.001);
68
define('DEFAULT_SUBMIT_TEXT','Submit');
69
define('DEFAULT_RESET_TEXT' ,'Reset');
70
define('DEFAULT_BUTTON_TEXT','Send request');
71
define('CHECKBOX_SIZE','15px');
72
define('RADIOBUTTON_SIZE','15px');
73
define('SELECT_BUTTON_TRIANGLE_PADDING',1.5);
74
define('BROKEN_IMAGE_DEFAULT_SIZE_PX',24);
75
define('BROKEN_IMAGE_ALT_SIZE_PT',10);
76
define('BASE_FONT_SIZE_PT',12);
77
define('DEFAULT_TEXT_SIZE',20);
78
define('EM_KOEFF',1);
79
 
80
// Note that Firefox calculated ex for each font separately, while
81
// IE uses fixed value of 'ex' unit. We behave like IE here.
82
define('EX_KOEFF',0.50);
83
 
84
define('DEFAULT_CHAR_WIDTH', 600);
85
define('WHITESPACE_FONT_SIZE_FRACTION', 0.25);
86
define('SIZE_SPACE_KOEFF', 1.2);
87
define('INPUT_SIZE_EM_KOEFF', 0.48);
88
define('INPUT_SIZE_BASE_EM', 2.2);
89
define('SELECT_SPACE_PADDING', 5);
90
define('LEGEND_HORIZONTAL_OFFSET', '5pt');
91
define('BULLET_SIZE_KOEFF', 0.15);
92
define('HEIGHT_KOEFF', 0.7);
93
define('MAX_FRAME_NESTING_LEVEL', 4);
94
 
95
// Maximal value of the free  space in justified line; if there's more
96
// free  space, line  will be  left-aligned to  avoid making  too much
97
// space  between words (set  to 1  if all  lines should  be justified
98
// regardless of free space)
99
define('MAX_JUSTIFY_FRACTION', 0.33);
100
 
101
define('HILIGHT_COLOR_ALPHA', 0.6);
102
define('MAX_REDIRECTS', 5);
103
 
104
// Maximal length of line inside the stream data
105
// (we need to limit this, as most postscript interpreters will complain
106
// on long strings)
107
//
108
// Note it is measured in BYTES! Each byte will be represented by TWO characters
109
// in the hexadecimal form
110
//
111
define("MAX_LINE_LENGTH", 100);
112
define('MAX_IMAGE_ROW_LEN',16);
113
define('MAX_TRANSPARENT_IMAGE_ROW_LEN',16);
114
 
115
define('CACHE_DIR', HTML2PS_DIR.'cache/');
116
define('OUTPUT_FILE_DIRECTORY', HTML2PS_DIR.'out/');
117
define('FPDF_PATH', HTML2PS_DIR.'fpdf/');
118
 
119
// Trailing directory separator ('/' or '\', depending on your system)
120
// SHOULD BE OMITTED
121
define('WRITER_TEMPDIR', HTML2PS_DIR.'temp');
122
define('WRITER_FILE_PREFIX','PS_');
123
 
124
// number of retries to generate unique filename in case we have had troubles with
125
// tempnam function
126
define('WRITER_RETRIES',10);
127
define('WRITER_CANNOT_CREATE_FILE',"Cannot create unique temporary filename, sorry");
128
 
129
define('HTML2PS_CONNECTION_TIMEOUT', 10);
130
 
131
// directory to restrict 'file://' access to
132
// empty string for no restrictions
133
define('FILE_PROTOCOL_RESTRICT', HTML2PS_DIR);
134
 
135
define('FOOTNOTE_LINE_PERCENT', 30);
136
define('FOOTNOTE_LINE_TOP_GAP', 1); // Content points
137
define('FOOTNOTE_LINE_BOTTOM_GAP', 3); // Content points
138
define('FOOTNOTE_MARKER_MARGIN', 1); // Content points
139
define('FOOTNOTE_GAP', 2); // Space between footnotes
140
 
141
if (!defined('DEBUG_MODE')) {
142
  // define('DEBUG_MODE',1);
143
};
144
 
145
define('HTML2PS_VERSION_MAJOR', 2);
146
define('HTML2PS_VERSION_MINOR', 0);
147
define('HTML2PS_SUBVERSION', 43);
148
 
149
define('MAX_UNPENALIZED_FREE_FRACTION', 0.25);
150
define('MAX_FREE_FRACTION',             0.5);
151
define('MAX_PAGE_BREAK_HEIGHT_PENALTY',  10000);
152
define('MAX_PAGE_BREAK_PENALTY',       1000000);
153
define('FORCED_PAGE_BREAK_BONUS',     -1000000);
154
define('PAGE_BREAK_INSIDE_AVOID_PENALTY',  300);
155
define('PAGE_BREAK_AFTER_AVOID_PENALTY',  5100);
156
define('PAGE_BREAK_BEFORE_AVOID_PENALTY', 1100);
157
define('PAGE_BREAK_ORPHANS_PENALTY',      1000);
158
define('PAGE_BREAK_WIDOWS_PENALTY',       1000);
159
define('PAGE_BREAK_LINE_PENALTY',            0);
160
define('PAGE_BREAK_BORDER_PENALTY',        150);
161
 
162
define('OVERLINE_POSITION', 1);
163
define('UNDERLINE_POSITION', 0.1);
164
define('LINE_THROUGH_POSITION', 0.4);
165
 
166
?>