SKRIPSI
This commit is contained in:
commit
dc5ef29160
|
@ -0,0 +1,15 @@
|
|||
# top-most EditorConfig file
|
||||
root = true
|
||||
|
||||
# Unix-style newlines with a newline ending every file
|
||||
[*]
|
||||
end_of_line = lf
|
||||
insert_final_newline = true
|
||||
|
||||
# Matches multiple files with brace expansion notation
|
||||
# Set default charset
|
||||
[*]
|
||||
charset = utf-8
|
||||
|
||||
# Tab indentation (no size specified)
|
||||
indent_style = tab
|
|
@ -0,0 +1,31 @@
|
|||
.DS_Store
|
||||
|
||||
application/cache/*
|
||||
!application/cache/index.html
|
||||
|
||||
application/logs/*
|
||||
!application/logs/index.html
|
||||
|
||||
!application/*/.htaccess
|
||||
|
||||
composer.lock
|
||||
|
||||
user_guide_src/build/*
|
||||
user_guide_src/cilexer/build/*
|
||||
user_guide_src/cilexer/dist/*
|
||||
user_guide_src/cilexer/pycilexer.egg-info/*
|
||||
/vendor/
|
||||
|
||||
# IDE Files
|
||||
#-------------------------
|
||||
/nbproject/
|
||||
.idea/*
|
||||
|
||||
## Sublime Text cache files
|
||||
*.tmlanguage.cache
|
||||
*.tmPreferences.cache
|
||||
*.stTheme.cache
|
||||
*.sublime-workspace
|
||||
*.sublime-project
|
||||
/tests/tests/
|
||||
/tests/results/
|
|
@ -0,0 +1,4 @@
|
|||
RewriteEngine On
|
||||
RewriteCond %{REQUEST_FILENAME} !-f
|
||||
RewriteCond %{REQUEST_FILENAME} !-d
|
||||
RewriteRule ^(.*)$ index.php/$1 [L]
|
|
@ -0,0 +1,6 @@
|
|||
<IfModule authz_core_module>
|
||||
Require all denied
|
||||
</IfModule>
|
||||
<IfModule !authz_core_module>
|
||||
Deny from all
|
||||
</IfModule>
|
|
@ -0,0 +1,11 @@
|
|||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<title>403 Forbidden</title>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<p>Directory access is forbidden.</p>
|
||||
|
||||
</body>
|
||||
</html>
|
|
@ -0,0 +1,135 @@
|
|||
<?php
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
|
||||
/*
|
||||
| -------------------------------------------------------------------
|
||||
| AUTO-LOADER
|
||||
| -------------------------------------------------------------------
|
||||
| This file specifies which systems should be loaded by default.
|
||||
|
|
||||
| In order to keep the framework as light-weight as possible only the
|
||||
| absolute minimal resources are loaded by default. For example,
|
||||
| the database is not connected to automatically since no assumption
|
||||
| is made regarding whether you intend to use it. This file lets
|
||||
| you globally define which systems you would like loaded with every
|
||||
| request.
|
||||
|
|
||||
| -------------------------------------------------------------------
|
||||
| Instructions
|
||||
| -------------------------------------------------------------------
|
||||
|
|
||||
| These are the things you can load automatically:
|
||||
|
|
||||
| 1. Packages
|
||||
| 2. Libraries
|
||||
| 3. Drivers
|
||||
| 4. Helper files
|
||||
| 5. Custom config files
|
||||
| 6. Language files
|
||||
| 7. Models
|
||||
|
|
||||
*/
|
||||
|
||||
/*
|
||||
| -------------------------------------------------------------------
|
||||
| Auto-load Packages
|
||||
| -------------------------------------------------------------------
|
||||
| Prototype:
|
||||
|
|
||||
| $autoload['packages'] = array(APPPATH.'third_party', '/usr/local/shared');
|
||||
|
|
||||
*/
|
||||
$autoload['packages'] = array();
|
||||
|
||||
/*
|
||||
| -------------------------------------------------------------------
|
||||
| Auto-load Libraries
|
||||
| -------------------------------------------------------------------
|
||||
| These are the classes located in system/libraries/ or your
|
||||
| application/libraries/ directory, with the addition of the
|
||||
| 'database' library, which is somewhat of a special case.
|
||||
|
|
||||
| Prototype:
|
||||
|
|
||||
| $autoload['libraries'] = array('database', 'email', 'session');
|
||||
|
|
||||
| You can also supply an alternative library name to be assigned
|
||||
| in the controller:
|
||||
|
|
||||
| $autoload['libraries'] = array('user_agent' => 'ua');
|
||||
*/
|
||||
$autoload['libraries'] = array('database', 'email', 'session', 'form_validation');
|
||||
|
||||
/*
|
||||
| -------------------------------------------------------------------
|
||||
| Auto-load Drivers
|
||||
| -------------------------------------------------------------------
|
||||
| These classes are located in system/libraries/ or in your
|
||||
| application/libraries/ directory, but are also placed inside their
|
||||
| own subdirectory and they extend the CI_Driver_Library class. They
|
||||
| offer multiple interchangeable driver options.
|
||||
|
|
||||
| Prototype:
|
||||
|
|
||||
| $autoload['drivers'] = array('cache');
|
||||
|
|
||||
| You can also supply an alternative property name to be assigned in
|
||||
| the controller:
|
||||
|
|
||||
| $autoload['drivers'] = array('cache' => 'cch');
|
||||
|
|
||||
*/
|
||||
$autoload['drivers'] = array();
|
||||
|
||||
/*
|
||||
| -------------------------------------------------------------------
|
||||
| Auto-load Helper Files
|
||||
| -------------------------------------------------------------------
|
||||
| Prototype:
|
||||
|
|
||||
| $autoload['helper'] = array('url', 'file');
|
||||
*/
|
||||
$autoload['helper'] = array('url', 'file', 'security','verif');
|
||||
|
||||
/*
|
||||
| -------------------------------------------------------------------
|
||||
| Auto-load Config files
|
||||
| -------------------------------------------------------------------
|
||||
| Prototype:
|
||||
|
|
||||
| $autoload['config'] = array('config1', 'config2');
|
||||
|
|
||||
| NOTE: This item is intended for use ONLY if you have created custom
|
||||
| config files. Otherwise, leave it blank.
|
||||
|
|
||||
*/
|
||||
$autoload['config'] = array();
|
||||
|
||||
/*
|
||||
| -------------------------------------------------------------------
|
||||
| Auto-load Language files
|
||||
| -------------------------------------------------------------------
|
||||
| Prototype:
|
||||
|
|
||||
| $autoload['language'] = array('lang1', 'lang2');
|
||||
|
|
||||
| NOTE: Do not include the "_lang" part of your file. For example
|
||||
| "codeigniter_lang.php" would be referenced as array('codeigniter');
|
||||
|
|
||||
*/
|
||||
$autoload['language'] = array();
|
||||
|
||||
/*
|
||||
| -------------------------------------------------------------------
|
||||
| Auto-load Models
|
||||
| -------------------------------------------------------------------
|
||||
| Prototype:
|
||||
|
|
||||
| $autoload['model'] = array('first_model', 'second_model');
|
||||
|
|
||||
| You can also supply an alternative model name to be assigned
|
||||
| in the controller:
|
||||
|
|
||||
| $autoload['model'] = array('first_model' => 'first');
|
||||
*/
|
||||
$autoload['model'] = array();
|
|
@ -0,0 +1,523 @@
|
|||
<?php
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Base Site URL
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| URL to your CodeIgniter root. Typically this will be your base URL,
|
||||
| WITH a trailing slash:
|
||||
|
|
||||
| http://example.com/
|
||||
|
|
||||
| WARNING: You MUST set this value!
|
||||
|
|
||||
| If it is not set, then CodeIgniter will try guess the protocol and path
|
||||
| your installation, but due to security concerns the hostname will be set
|
||||
| to $_SERVER['SERVER_ADDR'] if available, or localhost otherwise.
|
||||
| The auto-detection mechanism exists only for convenience during
|
||||
| development and MUST NOT be used in production!
|
||||
|
|
||||
| If you need to allow multiple domains, remember that this file is still
|
||||
| a PHP script and you can easily do that on your own.
|
||||
|
|
||||
*/
|
||||
$config['base_url'] = 'http://localhost/forecasting/';
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Index File
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Typically this will be your index.php file, unless you've renamed it to
|
||||
| something else. If you are using mod_rewrite to remove the page set this
|
||||
| variable so that it is blank.
|
||||
|
|
||||
*/
|
||||
$config['index_page'] = '';
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| URI PROTOCOL
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| This item determines which server global should be used to retrieve the
|
||||
| URI string. The default setting of 'REQUEST_URI' works for most servers.
|
||||
| If your links do not seem to work, try one of the other delicious flavors:
|
||||
|
|
||||
| 'REQUEST_URI' Uses $_SERVER['REQUEST_URI']
|
||||
| 'QUERY_STRING' Uses $_SERVER['QUERY_STRING']
|
||||
| 'PATH_INFO' Uses $_SERVER['PATH_INFO']
|
||||
|
|
||||
| WARNING: If you set this to 'PATH_INFO', URIs will always be URL-decoded!
|
||||
*/
|
||||
$config['uri_protocol'] = 'REQUEST_URI';
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| URL suffix
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| This option allows you to add a suffix to all URLs generated by CodeIgniter.
|
||||
| For more information please see the user guide:
|
||||
|
|
||||
| https://codeigniter.com/user_guide/general/urls.html
|
||||
*/
|
||||
$config['url_suffix'] = '';
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Default Language
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| This determines which set of language files should be used. Make sure
|
||||
| there is an available translation if you intend to use something other
|
||||
| than english.
|
||||
|
|
||||
*/
|
||||
$config['language'] = 'english';
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Default Character Set
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| This determines which character set is used by default in various methods
|
||||
| that require a character set to be provided.
|
||||
|
|
||||
| See http://php.net/htmlspecialchars for a list of supported charsets.
|
||||
|
|
||||
*/
|
||||
$config['charset'] = 'UTF-8';
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Enable/Disable System Hooks
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| If you would like to use the 'hooks' feature you must enable it by
|
||||
| setting this variable to TRUE (boolean). See the user guide for details.
|
||||
|
|
||||
*/
|
||||
$config['enable_hooks'] = FALSE;
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Class Extension Prefix
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| This item allows you to set the filename/classname prefix when extending
|
||||
| native libraries. For more information please see the user guide:
|
||||
|
|
||||
| https://codeigniter.com/user_guide/general/core_classes.html
|
||||
| https://codeigniter.com/user_guide/general/creating_libraries.html
|
||||
|
|
||||
*/
|
||||
$config['subclass_prefix'] = 'MY_';
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Composer auto-loading
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Enabling this setting will tell CodeIgniter to look for a Composer
|
||||
| package auto-loader script in application/vendor/autoload.php.
|
||||
|
|
||||
| $config['composer_autoload'] = TRUE;
|
||||
|
|
||||
| Or if you have your vendor/ directory located somewhere else, you
|
||||
| can opt to set a specific path as well:
|
||||
|
|
||||
| $config['composer_autoload'] = '/path/to/vendor/autoload.php';
|
||||
|
|
||||
| For more information about Composer, please visit http://getcomposer.org/
|
||||
|
|
||||
| Note: This will NOT disable or override the CodeIgniter-specific
|
||||
| autoloading (application/config/autoload.php)
|
||||
*/
|
||||
$config['composer_autoload'] = 'vendor/autoload.php';
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Allowed URL Characters
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| This lets you specify which characters are permitted within your URLs.
|
||||
| When someone tries to submit a URL with disallowed characters they will
|
||||
| get a warning message.
|
||||
|
|
||||
| As a security measure you are STRONGLY encouraged to restrict URLs to
|
||||
| as few characters as possible. By default only these are allowed: a-z 0-9~%.:_-
|
||||
|
|
||||
| Leave blank to allow all characters -- but only if you are insane.
|
||||
|
|
||||
| The configured value is actually a regular expression character group
|
||||
| and it will be executed as: ! preg_match('/^[<permitted_uri_chars>]+$/i
|
||||
|
|
||||
| DO NOT CHANGE THIS UNLESS YOU FULLY UNDERSTAND THE REPERCUSSIONS!!
|
||||
|
|
||||
*/
|
||||
$config['permitted_uri_chars'] = 'a-z 0-9~%.:_\-';
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Enable Query Strings
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| By default CodeIgniter uses search-engine friendly segment based URLs:
|
||||
| example.com/who/what/where/
|
||||
|
|
||||
| You can optionally enable standard query string based URLs:
|
||||
| example.com?who=me&what=something&where=here
|
||||
|
|
||||
| Options are: TRUE or FALSE (boolean)
|
||||
|
|
||||
| The other items let you set the query string 'words' that will
|
||||
| invoke your controllers and its functions:
|
||||
| example.com/index.php?c=controller&m=function
|
||||
|
|
||||
| Please note that some of the helpers won't work as expected when
|
||||
| this feature is enabled, since CodeIgniter is designed primarily to
|
||||
| use segment based URLs.
|
||||
|
|
||||
*/
|
||||
$config['enable_query_strings'] = FALSE;
|
||||
$config['controller_trigger'] = 'c';
|
||||
$config['function_trigger'] = 'm';
|
||||
$config['directory_trigger'] = 'd';
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Allow $_GET array
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| By default CodeIgniter enables access to the $_GET array. If for some
|
||||
| reason you would like to disable it, set 'allow_get_array' to FALSE.
|
||||
|
|
||||
| WARNING: This feature is DEPRECATED and currently available only
|
||||
| for backwards compatibility purposes!
|
||||
|
|
||||
*/
|
||||
$config['allow_get_array'] = TRUE;
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Error Logging Threshold
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| You can enable error logging by setting a threshold over zero. The
|
||||
| threshold determines what gets logged. Threshold options are:
|
||||
|
|
||||
| 0 = Disables logging, Error logging TURNED OFF
|
||||
| 1 = Error Messages (including PHP errors)
|
||||
| 2 = Debug Messages
|
||||
| 3 = Informational Messages
|
||||
| 4 = All Messages
|
||||
|
|
||||
| You can also pass an array with threshold levels to show individual error types
|
||||
|
|
||||
| array(2) = Debug Messages, without Error Messages
|
||||
|
|
||||
| For a live site you'll usually only enable Errors (1) to be logged otherwise
|
||||
| your log files will fill up very fast.
|
||||
|
|
||||
*/
|
||||
$config['log_threshold'] = 0;
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Error Logging Directory Path
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Leave this BLANK unless you would like to set something other than the default
|
||||
| application/logs/ directory. Use a full server path with trailing slash.
|
||||
|
|
||||
*/
|
||||
$config['log_path'] = '';
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Log File Extension
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| The default filename extension for log files. The default 'php' allows for
|
||||
| protecting the log files via basic scripting, when they are to be stored
|
||||
| under a publicly accessible directory.
|
||||
|
|
||||
| Note: Leaving it blank will default to 'php'.
|
||||
|
|
||||
*/
|
||||
$config['log_file_extension'] = '';
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Log File Permissions
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| The file system permissions to be applied on newly created log files.
|
||||
|
|
||||
| IMPORTANT: This MUST be an integer (no quotes) and you MUST use octal
|
||||
| integer notation (i.e. 0700, 0644, etc.)
|
||||
*/
|
||||
$config['log_file_permissions'] = 0644;
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Date Format for Logs
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Each item that is logged has an associated date. You can use PHP date
|
||||
| codes to set your own date formatting
|
||||
|
|
||||
*/
|
||||
$config['log_date_format'] = 'Y-m-d H:i:s';
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Error Views Directory Path
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Leave this BLANK unless you would like to set something other than the default
|
||||
| application/views/errors/ directory. Use a full server path with trailing slash.
|
||||
|
|
||||
*/
|
||||
$config['error_views_path'] = '';
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Cache Directory Path
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Leave this BLANK unless you would like to set something other than the default
|
||||
| application/cache/ directory. Use a full server path with trailing slash.
|
||||
|
|
||||
*/
|
||||
$config['cache_path'] = '';
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Cache Include Query String
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Whether to take the URL query string into consideration when generating
|
||||
| output cache files. Valid options are:
|
||||
|
|
||||
| FALSE = Disabled
|
||||
| TRUE = Enabled, take all query parameters into account.
|
||||
| Please be aware that this may result in numerous cache
|
||||
| files generated for the same page over and over again.
|
||||
| array('q') = Enabled, but only take into account the specified list
|
||||
| of query parameters.
|
||||
|
|
||||
*/
|
||||
$config['cache_query_string'] = FALSE;
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Encryption Key
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| If you use the Encryption class, you must set an encryption key.
|
||||
| See the user guide for more info.
|
||||
|
|
||||
| https://codeigniter.com/user_guide/libraries/encryption.html
|
||||
|
|
||||
*/
|
||||
$config['encryption_key'] = '';
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Session Variables
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| 'sess_driver'
|
||||
|
|
||||
| The storage driver to use: files, database, redis, memcached
|
||||
|
|
||||
| 'sess_cookie_name'
|
||||
|
|
||||
| The session cookie name, must contain only [0-9a-z_-] characters
|
||||
|
|
||||
| 'sess_expiration'
|
||||
|
|
||||
| The number of SECONDS you want the session to last.
|
||||
| Setting to 0 (zero) means expire when the browser is closed.
|
||||
|
|
||||
| 'sess_save_path'
|
||||
|
|
||||
| The location to save sessions to, driver dependent.
|
||||
|
|
||||
| For the 'files' driver, it's a path to a writable directory.
|
||||
| WARNING: Only absolute paths are supported!
|
||||
|
|
||||
| For the 'database' driver, it's a table name.
|
||||
| Please read up the manual for the format with other session drivers.
|
||||
|
|
||||
| IMPORTANT: You are REQUIRED to set a valid save path!
|
||||
|
|
||||
| 'sess_match_ip'
|
||||
|
|
||||
| Whether to match the user's IP address when reading the session data.
|
||||
|
|
||||
| WARNING: If you're using the database driver, don't forget to update
|
||||
| your session table's PRIMARY KEY when changing this setting.
|
||||
|
|
||||
| 'sess_time_to_update'
|
||||
|
|
||||
| How many seconds between CI regenerating the session ID.
|
||||
|
|
||||
| 'sess_regenerate_destroy'
|
||||
|
|
||||
| Whether to destroy session data associated with the old session ID
|
||||
| when auto-regenerating the session ID. When set to FALSE, the data
|
||||
| will be later deleted by the garbage collector.
|
||||
|
|
||||
| Other session cookie settings are shared with the rest of the application,
|
||||
| except for 'cookie_prefix' and 'cookie_httponly', which are ignored here.
|
||||
|
|
||||
*/
|
||||
$config['sess_driver'] = 'files';
|
||||
$config['sess_cookie_name'] = 'ci_session';
|
||||
$config['sess_expiration'] = 7200;
|
||||
$config['sess_save_path'] = NULL;
|
||||
$config['sess_match_ip'] = FALSE;
|
||||
$config['sess_time_to_update'] = 300;
|
||||
$config['sess_regenerate_destroy'] = FALSE;
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Cookie Related Variables
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| 'cookie_prefix' = Set a cookie name prefix if you need to avoid collisions
|
||||
| 'cookie_domain' = Set to .your-domain.com for site-wide cookies
|
||||
| 'cookie_path' = Typically will be a forward slash
|
||||
| 'cookie_secure' = Cookie will only be set if a secure HTTPS connection exists.
|
||||
| 'cookie_httponly' = Cookie will only be accessible via HTTP(S) (no javascript)
|
||||
|
|
||||
| Note: These settings (with the exception of 'cookie_prefix' and
|
||||
| 'cookie_httponly') will also affect sessions.
|
||||
|
|
||||
*/
|
||||
$config['cookie_prefix'] = '';
|
||||
$config['cookie_domain'] = '';
|
||||
$config['cookie_path'] = '/';
|
||||
$config['cookie_secure'] = FALSE;
|
||||
$config['cookie_httponly'] = FALSE;
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Standardize newlines
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Determines whether to standardize newline characters in input data,
|
||||
| meaning to replace \r\n, \r, \n occurrences with the PHP_EOL value.
|
||||
|
|
||||
| WARNING: This feature is DEPRECATED and currently available only
|
||||
| for backwards compatibility purposes!
|
||||
|
|
||||
*/
|
||||
$config['standardize_newlines'] = FALSE;
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Global XSS Filtering
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Determines whether the XSS filter is always active when GET, POST or
|
||||
| COOKIE data is encountered
|
||||
|
|
||||
| WARNING: This feature is DEPRECATED and currently available only
|
||||
| for backwards compatibility purposes!
|
||||
|
|
||||
*/
|
||||
$config['global_xss_filtering'] = FALSE;
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Cross Site Request Forgery
|
||||
|--------------------------------------------------------------------------
|
||||
| Enables a CSRF cookie token to be set. When set to TRUE, token will be
|
||||
| checked on a submitted form. If you are accepting user data, it is strongly
|
||||
| recommended CSRF protection be enabled.
|
||||
|
|
||||
| 'csrf_token_name' = The token name
|
||||
| 'csrf_cookie_name' = The cookie name
|
||||
| 'csrf_expire' = The number in seconds the token should expire.
|
||||
| 'csrf_regenerate' = Regenerate token on every submission
|
||||
| 'csrf_exclude_uris' = Array of URIs which ignore CSRF checks
|
||||
*/
|
||||
$config['csrf_protection'] = FALSE;
|
||||
$config['csrf_token_name'] = 'csrf_test_name';
|
||||
$config['csrf_cookie_name'] = 'csrf_cookie_name';
|
||||
$config['csrf_expire'] = 7200;
|
||||
$config['csrf_regenerate'] = TRUE;
|
||||
$config['csrf_exclude_uris'] = array();
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Output Compression
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Enables Gzip output compression for faster page loads. When enabled,
|
||||
| the output class will test whether your server supports Gzip.
|
||||
| Even if it does, however, not all browsers support compression
|
||||
| so enable only if you are reasonably sure your visitors can handle it.
|
||||
|
|
||||
| Only used if zlib.output_compression is turned off in your php.ini.
|
||||
| Please do not use it together with httpd-level output compression.
|
||||
|
|
||||
| VERY IMPORTANT: If you are getting a blank page when compression is enabled it
|
||||
| means you are prematurely outputting something to your browser. It could
|
||||
| even be a line of whitespace at the end of one of your scripts. For
|
||||
| compression to work, nothing can be sent before the output buffer is called
|
||||
| by the output class. Do not 'echo' any values with compression enabled.
|
||||
|
|
||||
*/
|
||||
$config['compress_output'] = FALSE;
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Master Time Reference
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Options are 'local' or any PHP supported timezone. This preference tells
|
||||
| the system whether to use your server's local time as the master 'now'
|
||||
| reference, or convert it to the configured one timezone. See the 'date
|
||||
| helper' page of the user guide for information regarding date handling.
|
||||
|
|
||||
*/
|
||||
$config['time_reference'] = 'local';
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Rewrite PHP Short Tags
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| If your PHP installation does not have short tag support enabled CI
|
||||
| can rewrite the tags on-the-fly, enabling you to utilize that syntax
|
||||
| in your view files. Options are TRUE or FALSE (boolean)
|
||||
|
|
||||
| Note: You need to have eval() enabled for this to work.
|
||||
|
|
||||
*/
|
||||
$config['rewrite_short_tags'] = FALSE;
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Reverse Proxy IPs
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| If your server is behind a reverse proxy, you must whitelist the proxy
|
||||
| IP addresses from which CodeIgniter should trust headers such as
|
||||
| HTTP_X_FORWARDED_FOR and HTTP_CLIENT_IP in order to properly identify
|
||||
| the visitor's IP address.
|
||||
|
|
||||
| You can use both an array or a comma-separated list of proxy addresses,
|
||||
| as well as specifying whole subnets. Here are a few examples:
|
||||
|
|
||||
| Comma-separated: '10.0.1.200,192.168.5.0/24'
|
||||
| Array: array('10.0.1.200', '192.168.5.0/24')
|
||||
*/
|
||||
$config['proxy_ips'] = '';
|
|
@ -0,0 +1,85 @@
|
|||
<?php
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Display Debug backtrace
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| If set to TRUE, a backtrace will be displayed along with php errors. If
|
||||
| error_reporting is disabled, the backtrace will not display, regardless
|
||||
| of this setting
|
||||
|
|
||||
*/
|
||||
defined('SHOW_DEBUG_BACKTRACE') OR define('SHOW_DEBUG_BACKTRACE', TRUE);
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| File and Directory Modes
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| These prefs are used when checking and setting modes when working
|
||||
| with the file system. The defaults are fine on servers with proper
|
||||
| security, but you may wish (or even need) to change the values in
|
||||
| certain environments (Apache running a separate process for each
|
||||
| user, PHP under CGI with Apache suEXEC, etc.). Octal values should
|
||||
| always be used to set the mode correctly.
|
||||
|
|
||||
*/
|
||||
defined('FILE_READ_MODE') OR define('FILE_READ_MODE', 0644);
|
||||
defined('FILE_WRITE_MODE') OR define('FILE_WRITE_MODE', 0666);
|
||||
defined('DIR_READ_MODE') OR define('DIR_READ_MODE', 0755);
|
||||
defined('DIR_WRITE_MODE') OR define('DIR_WRITE_MODE', 0755);
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| File Stream Modes
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| These modes are used when working with fopen()/popen()
|
||||
|
|
||||
*/
|
||||
defined('FOPEN_READ') OR define('FOPEN_READ', 'rb');
|
||||
defined('FOPEN_READ_WRITE') OR define('FOPEN_READ_WRITE', 'r+b');
|
||||
defined('FOPEN_WRITE_CREATE_DESTRUCTIVE') OR define('FOPEN_WRITE_CREATE_DESTRUCTIVE', 'wb'); // truncates existing file data, use with care
|
||||
defined('FOPEN_READ_WRITE_CREATE_DESTRUCTIVE') OR define('FOPEN_READ_WRITE_CREATE_DESTRUCTIVE', 'w+b'); // truncates existing file data, use with care
|
||||
defined('FOPEN_WRITE_CREATE') OR define('FOPEN_WRITE_CREATE', 'ab');
|
||||
defined('FOPEN_READ_WRITE_CREATE') OR define('FOPEN_READ_WRITE_CREATE', 'a+b');
|
||||
defined('FOPEN_WRITE_CREATE_STRICT') OR define('FOPEN_WRITE_CREATE_STRICT', 'xb');
|
||||
defined('FOPEN_READ_WRITE_CREATE_STRICT') OR define('FOPEN_READ_WRITE_CREATE_STRICT', 'x+b');
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Exit Status Codes
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Used to indicate the conditions under which the script is exit()ing.
|
||||
| While there is no universal standard for error codes, there are some
|
||||
| broad conventions. Three such conventions are mentioned below, for
|
||||
| those who wish to make use of them. The CodeIgniter defaults were
|
||||
| chosen for the least overlap with these conventions, while still
|
||||
| leaving room for others to be defined in future versions and user
|
||||
| applications.
|
||||
|
|
||||
| The three main conventions used for determining exit status codes
|
||||
| are as follows:
|
||||
|
|
||||
| Standard C/C++ Library (stdlibc):
|
||||
| http://www.gnu.org/software/libc/manual/html_node/Exit-Status.html
|
||||
| (This link also contains other GNU-specific conventions)
|
||||
| BSD sysexits.h:
|
||||
| http://www.gsp.com/cgi-bin/man.cgi?section=3&topic=sysexits
|
||||
| Bash scripting:
|
||||
| http://tldp.org/LDP/abs/html/exitcodes.html
|
||||
|
|
||||
*/
|
||||
defined('EXIT_SUCCESS') OR define('EXIT_SUCCESS', 0); // no errors
|
||||
defined('EXIT_ERROR') OR define('EXIT_ERROR', 1); // generic error
|
||||
defined('EXIT_CONFIG') OR define('EXIT_CONFIG', 3); // configuration error
|
||||
defined('EXIT_UNKNOWN_FILE') OR define('EXIT_UNKNOWN_FILE', 4); // file not found
|
||||
defined('EXIT_UNKNOWN_CLASS') OR define('EXIT_UNKNOWN_CLASS', 5); // unknown class
|
||||
defined('EXIT_UNKNOWN_METHOD') OR define('EXIT_UNKNOWN_METHOD', 6); // unknown class member
|
||||
defined('EXIT_USER_INPUT') OR define('EXIT_USER_INPUT', 7); // invalid user input
|
||||
defined('EXIT_DATABASE') OR define('EXIT_DATABASE', 8); // database error
|
||||
defined('EXIT__AUTO_MIN') OR define('EXIT__AUTO_MIN', 9); // lowest automatically-assigned error code
|
||||
defined('EXIT__AUTO_MAX') OR define('EXIT__AUTO_MAX', 125); // highest automatically-assigned error code
|
|
@ -0,0 +1,96 @@
|
|||
<?php
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
|
||||
/*
|
||||
| -------------------------------------------------------------------
|
||||
| DATABASE CONNECTIVITY SETTINGS
|
||||
| -------------------------------------------------------------------
|
||||
| This file will contain the settings needed to access your database.
|
||||
|
|
||||
| For complete instructions please consult the 'Database Connection'
|
||||
| page of the User Guide.
|
||||
|
|
||||
| -------------------------------------------------------------------
|
||||
| EXPLANATION OF VARIABLES
|
||||
| -------------------------------------------------------------------
|
||||
|
|
||||
| ['dsn'] The full DSN string describe a connection to the database.
|
||||
| ['hostname'] The hostname of your database server.
|
||||
| ['username'] The username used to connect to the database
|
||||
| ['password'] The password used to connect to the database
|
||||
| ['database'] The name of the database you want to connect to
|
||||
| ['dbdriver'] The database driver. e.g.: mysqli.
|
||||
| Currently supported:
|
||||
| cubrid, ibase, mssql, mysql, mysqli, oci8,
|
||||
| odbc, pdo, postgre, sqlite, sqlite3, sqlsrv
|
||||
| ['dbprefix'] You can add an optional prefix, which will be added
|
||||
| to the table name when using the Query Builder class
|
||||
| ['pconnect'] TRUE/FALSE - Whether to use a persistent connection
|
||||
| ['db_debug'] TRUE/FALSE - Whether database errors should be displayed.
|
||||
| ['cache_on'] TRUE/FALSE - Enables/disables query caching
|
||||
| ['cachedir'] The path to the folder where cache files should be stored
|
||||
| ['char_set'] The character set used in communicating with the database
|
||||
| ['dbcollat'] The character collation used in communicating with the database
|
||||
| NOTE: For MySQL and MySQLi databases, this setting is only used
|
||||
| as a backup if your server is running PHP < 5.2.3 or MySQL < 5.0.7
|
||||
| (and in table creation queries made with DB Forge).
|
||||
| There is an incompatibility in PHP with mysql_real_escape_string() which
|
||||
| can make your site vulnerable to SQL injection if you are using a
|
||||
| multi-byte character set and are running versions lower than these.
|
||||
| Sites using Latin-1 or UTF-8 database character set and collation are unaffected.
|
||||
| ['swap_pre'] A default table prefix that should be swapped with the dbprefix
|
||||
| ['encrypt'] Whether or not to use an encrypted connection.
|
||||
|
|
||||
| 'mysql' (deprecated), 'sqlsrv' and 'pdo/sqlsrv' drivers accept TRUE/FALSE
|
||||
| 'mysqli' and 'pdo/mysql' drivers accept an array with the following options:
|
||||
|
|
||||
| 'ssl_key' - Path to the private key file
|
||||
| 'ssl_cert' - Path to the public key certificate file
|
||||
| 'ssl_ca' - Path to the certificate authority file
|
||||
| 'ssl_capath' - Path to a directory containing trusted CA certificates in PEM format
|
||||
| 'ssl_cipher' - List of *allowed* ciphers to be used for the encryption, separated by colons (':')
|
||||
| 'ssl_verify' - TRUE/FALSE; Whether verify the server certificate or not
|
||||
|
|
||||
| ['compress'] Whether or not to use client compression (MySQL only)
|
||||
| ['stricton'] TRUE/FALSE - forces 'Strict Mode' connections
|
||||
| - good for ensuring strict SQL while developing
|
||||
| ['ssl_options'] Used to set various SSL options that can be used when making SSL connections.
|
||||
| ['failover'] array - A array with 0 or more data for connections if the main should fail.
|
||||
| ['save_queries'] TRUE/FALSE - Whether to "save" all executed queries.
|
||||
| NOTE: Disabling this will also effectively disable both
|
||||
| $this->db->last_query() and profiling of DB queries.
|
||||
| When you run a query, with this setting set to TRUE (default),
|
||||
| CodeIgniter will store the SQL statement for debugging purposes.
|
||||
| However, this may cause high memory usage, especially if you run
|
||||
| a lot of SQL queries ... disable this to avoid that problem.
|
||||
|
|
||||
| The $active_group variable lets you choose which connection group to
|
||||
| make active. By default there is only one group (the 'default' group).
|
||||
|
|
||||
| The $query_builder variables lets you determine whether or not to load
|
||||
| the query builder class.
|
||||
*/
|
||||
$active_group = 'default';
|
||||
$query_builder = TRUE;
|
||||
|
||||
$db['default'] = array(
|
||||
'dsn' => '',
|
||||
'hostname' => 'localhost',
|
||||
'username' => 'root',
|
||||
'password' => '',
|
||||
'database' => 'forecast',
|
||||
'dbdriver' => 'mysqli',
|
||||
'dbprefix' => '',
|
||||
'pconnect' => FALSE,
|
||||
'db_debug' => (ENVIRONMENT !== 'production'),
|
||||
'cache_on' => FALSE,
|
||||
'cachedir' => '',
|
||||
'char_set' => 'utf8',
|
||||
'dbcollat' => 'utf8_general_ci',
|
||||
'swap_pre' => '',
|
||||
'encrypt' => FALSE,
|
||||
'compress' => FALSE,
|
||||
'stricton' => FALSE,
|
||||
'failover' => array(),
|
||||
'save_queries' => TRUE
|
||||
);
|
|
@ -0,0 +1,24 @@
|
|||
<?php
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
|
||||
$_doctypes = array(
|
||||
'xhtml11' => '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">',
|
||||
'xhtml1-strict' => '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">',
|
||||
'xhtml1-trans' => '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">',
|
||||
'xhtml1-frame' => '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Frameset//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-frameset.dtd">',
|
||||
'xhtml-basic11' => '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML Basic 1.1//EN" "http://www.w3.org/TR/xhtml-basic/xhtml-basic11.dtd">',
|
||||
'html5' => '<!DOCTYPE html>',
|
||||
'html4-strict' => '<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">',
|
||||
'html4-trans' => '<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">',
|
||||
'html4-frame' => '<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Frameset//EN" "http://www.w3.org/TR/html4/frameset.dtd">',
|
||||
'mathml1' => '<!DOCTYPE math SYSTEM "http://www.w3.org/Math/DTD/mathml1/mathml.dtd">',
|
||||
'mathml2' => '<!DOCTYPE math PUBLIC "-//W3C//DTD MathML 2.0//EN" "http://www.w3.org/Math/DTD/mathml2/mathml2.dtd">',
|
||||
'svg10' => '<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.0//EN" "http://www.w3.org/TR/2001/REC-SVG-20010904/DTD/svg10.dtd">',
|
||||
'svg11' => '<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">',
|
||||
'svg11-basic' => '<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1 Basic//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11-basic.dtd">',
|
||||
'svg11-tiny' => '<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1 Tiny//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11-tiny.dtd">',
|
||||
'xhtml-math-svg-xh' => '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1 plus MathML 2.0 plus SVG 1.1//EN" "http://www.w3.org/2002/04/xhtml-math-svg/xhtml-math-svg.dtd">',
|
||||
'xhtml-math-svg-sh' => '<!DOCTYPE svg:svg PUBLIC "-//W3C//DTD XHTML 1.1 plus MathML 2.0 plus SVG 1.1//EN" "http://www.w3.org/2002/04/xhtml-math-svg/xhtml-math-svg.dtd">',
|
||||
'xhtml-rdfa-1' => '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML+RDFa 1.0//EN" "http://www.w3.org/MarkUp/DTD/xhtml-rdfa-1.dtd">',
|
||||
'xhtml-rdfa-2' => '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML+RDFa 1.1//EN" "http://www.w3.org/MarkUp/DTD/xhtml-rdfa-2.dtd">'
|
||||
);
|
|
@ -0,0 +1,114 @@
|
|||
<?php
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
|
||||
/*
|
||||
| -------------------------------------------------------------------
|
||||
| Foreign Characters
|
||||
| -------------------------------------------------------------------
|
||||
| This file contains an array of foreign characters for transliteration
|
||||
| conversion used by the Text helper
|
||||
|
|
||||
*/
|
||||
$foreign_characters = array(
|
||||
'/ä|æ|ǽ/' => 'ae',
|
||||
'/ö|œ/' => 'oe',
|
||||
'/ü/' => 'ue',
|
||||
'/Ä/' => 'Ae',
|
||||
'/Ü/' => 'Ue',
|
||||
'/Ö/' => 'Oe',
|
||||
'/À|Á|Â|Ã|Ä|Å|Ǻ|Ā|Ă|Ą|Ǎ|Α|Ά|Ả|Ạ|Ầ|Ẫ|Ẩ|Ậ|Ằ|Ắ|Ẵ|Ẳ|Ặ|А/' => 'A',
|
||||
'/à|á|â|ã|å|ǻ|ā|ă|ą|ǎ|ª|α|ά|ả|ạ|ầ|ấ|ẫ|ẩ|ậ|ằ|ắ|ẵ|ẳ|ặ|а/' => 'a',
|
||||
'/Б/' => 'B',
|
||||
'/б/' => 'b',
|
||||
'/Ç|Ć|Ĉ|Ċ|Č/' => 'C',
|
||||
'/ç|ć|ĉ|ċ|č/' => 'c',
|
||||
'/Д|Δ/' => 'D',
|
||||
'/д|δ/' => 'd',
|
||||
'/Ð|Ď|Đ/' => 'Dj',
|
||||
'/ð|ď|đ/' => 'dj',
|
||||
'/È|É|Ê|Ë|Ē|Ĕ|Ė|Ę|Ě|Ε|Έ|Ẽ|Ẻ|Ẹ|Ề|Ế|Ễ|Ể|Ệ|Е|Э/' => 'E',
|
||||
'/è|é|ê|ë|ē|ĕ|ė|ę|ě|έ|ε|ẽ|ẻ|ẹ|ề|ế|ễ|ể|ệ|е|э/' => 'e',
|
||||
'/Ф/' => 'F',
|
||||
'/ф/' => 'f',
|
||||
'/Ĝ|Ğ|Ġ|Ģ|Γ|Г|Ґ/' => 'G',
|
||||
'/ĝ|ğ|ġ|ģ|γ|г|ґ/' => 'g',
|
||||
'/Ĥ|Ħ/' => 'H',
|
||||
'/ĥ|ħ/' => 'h',
|
||||
'/Ì|Í|Î|Ï|Ĩ|Ī|Ĭ|Ǐ|Į|İ|Η|Ή|Ί|Ι|Ϊ|Ỉ|Ị|И|Ы/' => 'I',
|
||||
'/ì|í|î|ï|ĩ|ī|ĭ|ǐ|į|ı|η|ή|ί|ι|ϊ|ỉ|ị|и|ы|ї/' => 'i',
|
||||
'/Ĵ/' => 'J',
|
||||
'/ĵ/' => 'j',
|
||||
'/Θ/' => 'TH',
|
||||
'/θ/' => 'th',
|
||||
'/Ķ|Κ|К/' => 'K',
|
||||
'/ķ|κ|к/' => 'k',
|
||||
'/Ĺ|Ļ|Ľ|Ŀ|Ł|Λ|Л/' => 'L',
|
||||
'/ĺ|ļ|ľ|ŀ|ł|λ|л/' => 'l',
|
||||
'/М/' => 'M',
|
||||
'/м/' => 'm',
|
||||
'/Ñ|Ń|Ņ|Ň|Ν|Н/' => 'N',
|
||||
'/ñ|ń|ņ|ň|ʼn|ν|н/' => 'n',
|
||||
'/Ò|Ó|Ô|Õ|Ō|Ŏ|Ǒ|Ő|Ơ|Ø|Ǿ|Ο|Ό|Ω|Ώ|Ỏ|Ọ|Ồ|Ố|Ỗ|Ổ|Ộ|Ờ|Ớ|Ỡ|Ở|Ợ|О/' => 'O',
|
||||
'/ò|ó|ô|õ|ō|ŏ|ǒ|ő|ơ|ø|ǿ|º|ο|ό|ω|ώ|ỏ|ọ|ồ|ố|ỗ|ổ|ộ|ờ|ớ|ỡ|ở|ợ|о/' => 'o',
|
||||
'/П/' => 'P',
|
||||
'/п/' => 'p',
|
||||
'/Ŕ|Ŗ|Ř|Ρ|Р/' => 'R',
|
||||
'/ŕ|ŗ|ř|ρ|р/' => 'r',
|
||||
'/Ś|Ŝ|Ş|Ș|Š|Σ|С/' => 'S',
|
||||
'/ś|ŝ|ş|ș|š|ſ|σ|ς|с/' => 's',
|
||||
'/Ț|Ţ|Ť|Ŧ|Τ|Т/' => 'T',
|
||||
'/ț|ţ|ť|ŧ|τ|т/' => 't',
|
||||
'/Þ|þ/' => 'th',
|
||||
'/Ù|Ú|Û|Ũ|Ū|Ŭ|Ů|Ű|Ų|Ư|Ǔ|Ǖ|Ǘ|Ǚ|Ǜ|Ũ|Ủ|Ụ|Ừ|Ứ|Ữ|Ử|Ự|У/' => 'U',
|
||||
'/ù|ú|û|ũ|ū|ŭ|ů|ű|ų|ư|ǔ|ǖ|ǘ|ǚ|ǜ|υ|ύ|ϋ|ủ|ụ|ừ|ứ|ữ|ử|ự|у/' => 'u',
|
||||
'/Ƴ|Ɏ|Ỵ|Ẏ|Ӳ|Ӯ|Ў|Ý|Ÿ|Ŷ|Υ|Ύ|Ϋ|Ỳ|Ỹ|Ỷ|Ỵ|Й/' => 'Y',
|
||||
'/ẙ|ʏ|ƴ|ɏ|ỵ|ẏ|ӳ|ӯ|ў|ý|ÿ|ŷ|ỳ|ỹ|ỷ|ỵ|й/' => 'y',
|
||||
'/В/' => 'V',
|
||||
'/в/' => 'v',
|
||||
'/Ŵ/' => 'W',
|
||||
'/ŵ/' => 'w',
|
||||
'/Φ/' => 'F',
|
||||
'/φ/' => 'f',
|
||||
'/Χ/' => 'CH',
|
||||
'/χ/' => 'ch',
|
||||
'/Ź|Ż|Ž|Ζ|З/' => 'Z',
|
||||
'/ź|ż|ž|ζ|з/' => 'z',
|
||||
'/Æ|Ǽ/' => 'AE',
|
||||
'/ß/' => 'ss',
|
||||
'/IJ/' => 'IJ',
|
||||
'/ij/' => 'ij',
|
||||
'/Œ/' => 'OE',
|
||||
'/ƒ/' => 'f',
|
||||
'/Ξ/' => 'KS',
|
||||
'/ξ/' => 'ks',
|
||||
'/Π/' => 'P',
|
||||
'/π/' => 'p',
|
||||
'/Β/' => 'V',
|
||||
'/β/' => 'v',
|
||||
'/Μ/' => 'M',
|
||||
'/μ/' => 'm',
|
||||
'/Ψ/' => 'PS',
|
||||
'/ψ/' => 'ps',
|
||||
'/Ё/' => 'Yo',
|
||||
'/ё/' => 'yo',
|
||||
'/Є/' => 'Ye',
|
||||
'/є/' => 'ye',
|
||||
'/Ї/' => 'Yi',
|
||||
'/Ж/' => 'Zh',
|
||||
'/ж/' => 'zh',
|
||||
'/Х/' => 'Kh',
|
||||
'/х/' => 'kh',
|
||||
'/Ц/' => 'Ts',
|
||||
'/ц/' => 'ts',
|
||||
'/Ч/' => 'Ch',
|
||||
'/ч/' => 'ch',
|
||||
'/Ш/' => 'Sh',
|
||||
'/ш/' => 'sh',
|
||||
'/Щ/' => 'Shch',
|
||||
'/щ/' => 'shch',
|
||||
'/Ъ|ъ|Ь|ь/' => '',
|
||||
'/Ю/' => 'Yu',
|
||||
'/ю/' => 'yu',
|
||||
'/Я/' => 'Ya',
|
||||
'/я/' => 'ya'
|
||||
);
|
|
@ -0,0 +1,13 @@
|
|||
<?php
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
|
||||
/*
|
||||
| -------------------------------------------------------------------------
|
||||
| Hooks
|
||||
| -------------------------------------------------------------------------
|
||||
| This file lets you define "hooks" to extend CI without hacking the core
|
||||
| files. Please see the user guide for info:
|
||||
|
|
||||
| https://codeigniter.com/user_guide/general/hooks.html
|
||||
|
|
||||
*/
|
|
@ -0,0 +1,11 @@
|
|||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<title>403 Forbidden</title>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<p>Directory access is forbidden.</p>
|
||||
|
||||
</body>
|
||||
</html>
|
|
@ -0,0 +1,19 @@
|
|||
<?php
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
|
||||
/*
|
||||
| -------------------------------------------------------------------------
|
||||
| Memcached settings
|
||||
| -------------------------------------------------------------------------
|
||||
| Your Memcached servers can be specified below.
|
||||
|
|
||||
| See: https://codeigniter.com/user_guide/libraries/caching.html#memcached
|
||||
|
|
||||
*/
|
||||
$config = array(
|
||||
'default' => array(
|
||||
'hostname' => '127.0.0.1',
|
||||
'port' => '11211',
|
||||
'weight' => '1',
|
||||
),
|
||||
);
|
|
@ -0,0 +1,84 @@
|
|||
<?php
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Enable/Disable Migrations
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Migrations are disabled by default for security reasons.
|
||||
| You should enable migrations whenever you intend to do a schema migration
|
||||
| and disable it back when you're done.
|
||||
|
|
||||
*/
|
||||
$config['migration_enabled'] = FALSE;
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Migration Type
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Migration file names may be based on a sequential identifier or on
|
||||
| a timestamp. Options are:
|
||||
|
|
||||
| 'sequential' = Sequential migration naming (001_add_blog.php)
|
||||
| 'timestamp' = Timestamp migration naming (20121031104401_add_blog.php)
|
||||
| Use timestamp format YYYYMMDDHHIISS.
|
||||
|
|
||||
| Note: If this configuration value is missing the Migration library
|
||||
| defaults to 'sequential' for backward compatibility with CI2.
|
||||
|
|
||||
*/
|
||||
$config['migration_type'] = 'timestamp';
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Migrations table
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| This is the name of the table that will store the current migrations state.
|
||||
| When migrations runs it will store in a database table which migration
|
||||
| level the system is at. It then compares the migration level in this
|
||||
| table to the $config['migration_version'] if they are not the same it
|
||||
| will migrate up. This must be set.
|
||||
|
|
||||
*/
|
||||
$config['migration_table'] = 'migrations';
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Auto Migrate To Latest
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| If this is set to TRUE when you load the migrations class and have
|
||||
| $config['migration_enabled'] set to TRUE the system will auto migrate
|
||||
| to your latest migration (whatever $config['migration_version'] is
|
||||
| set to). This way you do not have to call migrations anywhere else
|
||||
| in your code to have the latest migration.
|
||||
|
|
||||
*/
|
||||
$config['migration_auto_latest'] = FALSE;
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Migrations version
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| This is used to set migration version that the file system should be on.
|
||||
| If you run $this->migration->current() this is the version that schema will
|
||||
| be upgraded / downgraded to.
|
||||
|
|
||||
*/
|
||||
$config['migration_version'] = 0;
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Migrations Path
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Path to your migrations folder.
|
||||
| Typically, it will be within your application path.
|
||||
| Also, writing permission is required within the migrations path.
|
||||
|
|
||||
*/
|
||||
$config['migration_path'] = APPPATH.'migrations/';
|
|
@ -0,0 +1,184 @@
|
|||
<?php
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
|
||||
/*
|
||||
| -------------------------------------------------------------------
|
||||
| MIME TYPES
|
||||
| -------------------------------------------------------------------
|
||||
| This file contains an array of mime types. It is used by the
|
||||
| Upload class to help identify allowed file types.
|
||||
|
|
||||
*/
|
||||
return array(
|
||||
'hqx' => array('application/mac-binhex40', 'application/mac-binhex', 'application/x-binhex40', 'application/x-mac-binhex40'),
|
||||
'cpt' => 'application/mac-compactpro',
|
||||
'csv' => array('text/x-comma-separated-values', 'text/comma-separated-values', 'application/octet-stream', 'application/vnd.ms-excel', 'application/x-csv', 'text/x-csv', 'text/csv', 'application/csv', 'application/excel', 'application/vnd.msexcel', 'text/plain'),
|
||||
'bin' => array('application/macbinary', 'application/mac-binary', 'application/octet-stream', 'application/x-binary', 'application/x-macbinary'),
|
||||
'dms' => 'application/octet-stream',
|
||||
'lha' => 'application/octet-stream',
|
||||
'lzh' => 'application/octet-stream',
|
||||
'exe' => array('application/octet-stream', 'application/x-msdownload'),
|
||||
'class' => 'application/octet-stream',
|
||||
'psd' => array('application/x-photoshop', 'image/vnd.adobe.photoshop'),
|
||||
'so' => 'application/octet-stream',
|
||||
'sea' => 'application/octet-stream',
|
||||
'dll' => 'application/octet-stream',
|
||||
'oda' => 'application/oda',
|
||||
'pdf' => array('application/pdf', 'application/force-download', 'application/x-download', 'binary/octet-stream'),
|
||||
'ai' => array('application/pdf', 'application/postscript'),
|
||||
'eps' => 'application/postscript',
|
||||
'ps' => 'application/postscript',
|
||||
'smi' => 'application/smil',
|
||||
'smil' => 'application/smil',
|
||||
'mif' => 'application/vnd.mif',
|
||||
'xls' => array('application/vnd.ms-excel', 'application/msexcel', 'application/x-msexcel', 'application/x-ms-excel', 'application/x-excel', 'application/x-dos_ms_excel', 'application/xls', 'application/x-xls', 'application/excel', 'application/download', 'application/vnd.ms-office', 'application/msword'),
|
||||
'ppt' => array('application/powerpoint', 'application/vnd.ms-powerpoint', 'application/vnd.ms-office', 'application/msword'),
|
||||
'pptx' => array('application/vnd.openxmlformats-officedocument.presentationml.presentation', 'application/x-zip', 'application/zip'),
|
||||
'wbxml' => 'application/wbxml',
|
||||
'wmlc' => 'application/wmlc',
|
||||
'dcr' => 'application/x-director',
|
||||
'dir' => 'application/x-director',
|
||||
'dxr' => 'application/x-director',
|
||||
'dvi' => 'application/x-dvi',
|
||||
'gtar' => 'application/x-gtar',
|
||||
'gz' => 'application/x-gzip',
|
||||
'gzip' => 'application/x-gzip',
|
||||
'php' => array('application/x-httpd-php', 'application/php', 'application/x-php', 'text/php', 'text/x-php', 'application/x-httpd-php-source'),
|
||||
'php4' => 'application/x-httpd-php',
|
||||
'php3' => 'application/x-httpd-php',
|
||||
'phtml' => 'application/x-httpd-php',
|
||||
'phps' => 'application/x-httpd-php-source',
|
||||
'js' => array('application/x-javascript', 'text/plain'),
|
||||
'swf' => 'application/x-shockwave-flash',
|
||||
'sit' => 'application/x-stuffit',
|
||||
'tar' => 'application/x-tar',
|
||||
'tgz' => array('application/x-tar', 'application/x-gzip-compressed'),
|
||||
'z' => 'application/x-compress',
|
||||
'xhtml' => 'application/xhtml+xml',
|
||||
'xht' => 'application/xhtml+xml',
|
||||
'zip' => array('application/x-zip', 'application/zip', 'application/x-zip-compressed', 'application/s-compressed', 'multipart/x-zip'),
|
||||
'rar' => array('application/x-rar', 'application/rar', 'application/x-rar-compressed'),
|
||||
'mid' => 'audio/midi',
|
||||
'midi' => 'audio/midi',
|
||||
'mpga' => 'audio/mpeg',
|
||||
'mp2' => 'audio/mpeg',
|
||||
'mp3' => array('audio/mpeg', 'audio/mpg', 'audio/mpeg3', 'audio/mp3'),
|
||||
'aif' => array('audio/x-aiff', 'audio/aiff'),
|
||||
'aiff' => array('audio/x-aiff', 'audio/aiff'),
|
||||
'aifc' => 'audio/x-aiff',
|
||||
'ram' => 'audio/x-pn-realaudio',
|
||||
'rm' => 'audio/x-pn-realaudio',
|
||||
'rpm' => 'audio/x-pn-realaudio-plugin',
|
||||
'ra' => 'audio/x-realaudio',
|
||||
'rv' => 'video/vnd.rn-realvideo',
|
||||
'wav' => array('audio/x-wav', 'audio/wave', 'audio/wav'),
|
||||
'bmp' => array('image/bmp', 'image/x-bmp', 'image/x-bitmap', 'image/x-xbitmap', 'image/x-win-bitmap', 'image/x-windows-bmp', 'image/ms-bmp', 'image/x-ms-bmp', 'application/bmp', 'application/x-bmp', 'application/x-win-bitmap'),
|
||||
'gif' => 'image/gif',
|
||||
'jpeg' => array('image/jpeg', 'image/pjpeg'),
|
||||
'jpg' => array('image/jpeg', 'image/pjpeg'),
|
||||
'jpe' => array('image/jpeg', 'image/pjpeg'),
|
||||
'jp2' => array('image/jp2', 'video/mj2', 'image/jpx', 'image/jpm'),
|
||||
'j2k' => array('image/jp2', 'video/mj2', 'image/jpx', 'image/jpm'),
|
||||
'jpf' => array('image/jp2', 'video/mj2', 'image/jpx', 'image/jpm'),
|
||||
'jpg2' => array('image/jp2', 'video/mj2', 'image/jpx', 'image/jpm'),
|
||||
'jpx' => array('image/jp2', 'video/mj2', 'image/jpx', 'image/jpm'),
|
||||
'jpm' => array('image/jp2', 'video/mj2', 'image/jpx', 'image/jpm'),
|
||||
'mj2' => array('image/jp2', 'video/mj2', 'image/jpx', 'image/jpm'),
|
||||
'mjp2' => array('image/jp2', 'video/mj2', 'image/jpx', 'image/jpm'),
|
||||
'png' => array('image/png', 'image/x-png'),
|
||||
'tiff' => 'image/tiff',
|
||||
'tif' => 'image/tiff',
|
||||
'css' => array('text/css', 'text/plain'),
|
||||
'html' => array('text/html', 'text/plain'),
|
||||
'htm' => array('text/html', 'text/plain'),
|
||||
'shtml' => array('text/html', 'text/plain'),
|
||||
'txt' => 'text/plain',
|
||||
'text' => 'text/plain',
|
||||
'log' => array('text/plain', 'text/x-log'),
|
||||
'rtx' => 'text/richtext',
|
||||
'rtf' => 'text/rtf',
|
||||
'xml' => array('application/xml', 'text/xml', 'text/plain'),
|
||||
'xsl' => array('application/xml', 'text/xsl', 'text/xml'),
|
||||
'mpeg' => 'video/mpeg',
|
||||
'mpg' => 'video/mpeg',
|
||||
'mpe' => 'video/mpeg',
|
||||
'qt' => 'video/quicktime',
|
||||
'mov' => 'video/quicktime',
|
||||
'avi' => array('video/x-msvideo', 'video/msvideo', 'video/avi', 'application/x-troff-msvideo'),
|
||||
'movie' => 'video/x-sgi-movie',
|
||||
'doc' => array('application/msword', 'application/vnd.ms-office'),
|
||||
'docx' => array('application/vnd.openxmlformats-officedocument.wordprocessingml.document', 'application/zip', 'application/msword', 'application/x-zip'),
|
||||
'dot' => array('application/msword', 'application/vnd.ms-office'),
|
||||
'dotx' => array('application/vnd.openxmlformats-officedocument.wordprocessingml.document', 'application/zip', 'application/msword'),
|
||||
'xlsx' => array('application/vnd.openxmlformats-officedocument.spreadsheetml.sheet', 'application/zip', 'application/vnd.ms-excel', 'application/msword', 'application/x-zip'),
|
||||
'word' => array('application/msword', 'application/octet-stream'),
|
||||
'xl' => 'application/excel',
|
||||
'eml' => 'message/rfc822',
|
||||
'json' => array('application/json', 'text/json'),
|
||||
'pem' => array('application/x-x509-user-cert', 'application/x-pem-file', 'application/octet-stream'),
|
||||
'p10' => array('application/x-pkcs10', 'application/pkcs10'),
|
||||
'p12' => 'application/x-pkcs12',
|
||||
'p7a' => 'application/x-pkcs7-signature',
|
||||
'p7c' => array('application/pkcs7-mime', 'application/x-pkcs7-mime'),
|
||||
'p7m' => array('application/pkcs7-mime', 'application/x-pkcs7-mime'),
|
||||
'p7r' => 'application/x-pkcs7-certreqresp',
|
||||
'p7s' => 'application/pkcs7-signature',
|
||||
'crt' => array('application/x-x509-ca-cert', 'application/x-x509-user-cert', 'application/pkix-cert'),
|
||||
'crl' => array('application/pkix-crl', 'application/pkcs-crl'),
|
||||
'der' => 'application/x-x509-ca-cert',
|
||||
'kdb' => 'application/octet-stream',
|
||||
'pgp' => 'application/pgp',
|
||||
'gpg' => 'application/gpg-keys',
|
||||
'sst' => 'application/octet-stream',
|
||||
'csr' => 'application/octet-stream',
|
||||
'rsa' => 'application/x-pkcs7',
|
||||
'cer' => array('application/pkix-cert', 'application/x-x509-ca-cert'),
|
||||
'3g2' => 'video/3gpp2',
|
||||
'3gp' => array('video/3gp', 'video/3gpp'),
|
||||
'mp4' => 'video/mp4',
|
||||
'm4a' => 'audio/x-m4a',
|
||||
'f4v' => array('video/mp4', 'video/x-f4v'),
|
||||
'flv' => 'video/x-flv',
|
||||
'webm' => 'video/webm',
|
||||
'aac' => array('audio/x-aac', 'audio/aac'),
|
||||
'm4u' => 'application/vnd.mpegurl',
|
||||
'm3u' => 'text/plain',
|
||||
'xspf' => 'application/xspf+xml',
|
||||
'vlc' => 'application/videolan',
|
||||
'wmv' => array('video/x-ms-wmv', 'video/x-ms-asf'),
|
||||
'au' => 'audio/x-au',
|
||||
'ac3' => 'audio/ac3',
|
||||
'flac' => 'audio/x-flac',
|
||||
'ogg' => array('audio/ogg', 'video/ogg', 'application/ogg'),
|
||||
'kmz' => array('application/vnd.google-earth.kmz', 'application/zip', 'application/x-zip'),
|
||||
'kml' => array('application/vnd.google-earth.kml+xml', 'application/xml', 'text/xml'),
|
||||
'ics' => 'text/calendar',
|
||||
'ical' => 'text/calendar',
|
||||
'zsh' => 'text/x-scriptzsh',
|
||||
'7z' => array('application/x-7z-compressed', 'application/x-compressed', 'application/x-zip-compressed', 'application/zip', 'multipart/x-zip'),
|
||||
'7zip' => array('application/x-7z-compressed', 'application/x-compressed', 'application/x-zip-compressed', 'application/zip', 'multipart/x-zip'),
|
||||
'cdr' => array('application/cdr', 'application/coreldraw', 'application/x-cdr', 'application/x-coreldraw', 'image/cdr', 'image/x-cdr', 'zz-application/zz-winassoc-cdr'),
|
||||
'wma' => array('audio/x-ms-wma', 'video/x-ms-asf'),
|
||||
'jar' => array('application/java-archive', 'application/x-java-application', 'application/x-jar', 'application/x-compressed'),
|
||||
'svg' => array('image/svg+xml', 'application/xml', 'text/xml'),
|
||||
'vcf' => 'text/x-vcard',
|
||||
'srt' => array('text/srt', 'text/plain'),
|
||||
'vtt' => array('text/vtt', 'text/plain'),
|
||||
'ico' => array('image/x-icon', 'image/x-ico', 'image/vnd.microsoft.icon'),
|
||||
'odc' => 'application/vnd.oasis.opendocument.chart',
|
||||
'otc' => 'application/vnd.oasis.opendocument.chart-template',
|
||||
'odf' => 'application/vnd.oasis.opendocument.formula',
|
||||
'otf' => 'application/vnd.oasis.opendocument.formula-template',
|
||||
'odg' => 'application/vnd.oasis.opendocument.graphics',
|
||||
'otg' => 'application/vnd.oasis.opendocument.graphics-template',
|
||||
'odi' => 'application/vnd.oasis.opendocument.image',
|
||||
'oti' => 'application/vnd.oasis.opendocument.image-template',
|
||||
'odp' => 'application/vnd.oasis.opendocument.presentation',
|
||||
'otp' => 'application/vnd.oasis.opendocument.presentation-template',
|
||||
'ods' => 'application/vnd.oasis.opendocument.spreadsheet',
|
||||
'ots' => 'application/vnd.oasis.opendocument.spreadsheet-template',
|
||||
'odt' => 'application/vnd.oasis.opendocument.text',
|
||||
'odm' => 'application/vnd.oasis.opendocument.text-master',
|
||||
'ott' => 'application/vnd.oasis.opendocument.text-template',
|
||||
'oth' => 'application/vnd.oasis.opendocument.text-web'
|
||||
);
|
|
@ -0,0 +1,14 @@
|
|||
<?php
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
|
||||
/*
|
||||
| -------------------------------------------------------------------------
|
||||
| Profiler Sections
|
||||
| -------------------------------------------------------------------------
|
||||
| This file lets you determine whether or not various sections of Profiler
|
||||
| data are displayed when the Profiler is enabled.
|
||||
| Please see the user guide for info:
|
||||
|
|
||||
| https://codeigniter.com/user_guide/general/profiling.html
|
||||
|
|
||||
*/
|
|
@ -0,0 +1,54 @@
|
|||
<?php
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
|
||||
/*
|
||||
| -------------------------------------------------------------------------
|
||||
| URI ROUTING
|
||||
| -------------------------------------------------------------------------
|
||||
| This file lets you re-map URI requests to specific controller functions.
|
||||
|
|
||||
| Typically there is a one-to-one relationship between a URL string
|
||||
| and its corresponding controller class/method. The segments in a
|
||||
| URL normally follow this pattern:
|
||||
|
|
||||
| example.com/class/method/id/
|
||||
|
|
||||
| In some instances, however, you may want to remap this relationship
|
||||
| so that a different class/function is called than the one
|
||||
| corresponding to the URL.
|
||||
|
|
||||
| Please see the user guide for complete details:
|
||||
|
|
||||
| https://codeigniter.com/user_guide/general/routing.html
|
||||
|
|
||||
| -------------------------------------------------------------------------
|
||||
| RESERVED ROUTES
|
||||
| -------------------------------------------------------------------------
|
||||
|
|
||||
| There are three reserved routes:
|
||||
|
|
||||
| $route['default_controller'] = 'welcome';
|
||||
|
|
||||
| This route indicates which controller class should be loaded if the
|
||||
| URI contains no data. In the above example, the "welcome" class
|
||||
| would be loaded.
|
||||
|
|
||||
| $route['404_override'] = 'errors/page_missing';
|
||||
|
|
||||
| This route will tell the Router which controller/method to use if those
|
||||
| provided in the URL cannot be matched to a valid route.
|
||||
|
|
||||
| $route['translate_uri_dashes'] = FALSE;
|
||||
|
|
||||
| This is not exactly a route, but allows you to automatically route
|
||||
| controller and method names that contain dashes. '-' isn't a valid
|
||||
| class or method name character, so it requires translation.
|
||||
| When you set this option to TRUE, it will replace ALL dashes in the
|
||||
| controller and method URI segments.
|
||||
|
|
||||
| Examples: my-controller/index -> my_controller/index
|
||||
| my-controller/my-method -> my_controller/my_method
|
||||
*/
|
||||
$route['default_controller'] = 'auth';
|
||||
$route['404_override'] = '';
|
||||
$route['translate_uri_dashes'] = FALSE;
|
|
@ -0,0 +1,64 @@
|
|||
<?php
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
|
||||
/*
|
||||
| -------------------------------------------------------------------
|
||||
| SMILEYS
|
||||
| -------------------------------------------------------------------
|
||||
| This file contains an array of smileys for use with the emoticon helper.
|
||||
| Individual images can be used to replace multiple smileys. For example:
|
||||
| :-) and :) use the same image replacement.
|
||||
|
|
||||
| Please see user guide for more info:
|
||||
| https://codeigniter.com/user_guide/helpers/smiley_helper.html
|
||||
|
|
||||
*/
|
||||
$smileys = array(
|
||||
|
||||
// smiley image name width height alt
|
||||
|
||||
':-)' => array('grin.gif', '19', '19', 'grin'),
|
||||
':lol:' => array('lol.gif', '19', '19', 'LOL'),
|
||||
':cheese:' => array('cheese.gif', '19', '19', 'cheese'),
|
||||
':)' => array('smile.gif', '19', '19', 'smile'),
|
||||
';-)' => array('wink.gif', '19', '19', 'wink'),
|
||||
';)' => array('wink.gif', '19', '19', 'wink'),
|
||||
':smirk:' => array('smirk.gif', '19', '19', 'smirk'),
|
||||
':roll:' => array('rolleyes.gif', '19', '19', 'rolleyes'),
|
||||
':-S' => array('confused.gif', '19', '19', 'confused'),
|
||||
':wow:' => array('surprise.gif', '19', '19', 'surprised'),
|
||||
':bug:' => array('bigsurprise.gif', '19', '19', 'big surprise'),
|
||||
':-P' => array('tongue_laugh.gif', '19', '19', 'tongue laugh'),
|
||||
'%-P' => array('tongue_rolleye.gif', '19', '19', 'tongue rolleye'),
|
||||
';-P' => array('tongue_wink.gif', '19', '19', 'tongue wink'),
|
||||
':P' => array('raspberry.gif', '19', '19', 'raspberry'),
|
||||
':blank:' => array('blank.gif', '19', '19', 'blank stare'),
|
||||
':long:' => array('longface.gif', '19', '19', 'long face'),
|
||||
':ohh:' => array('ohh.gif', '19', '19', 'ohh'),
|
||||
':grrr:' => array('grrr.gif', '19', '19', 'grrr'),
|
||||
':gulp:' => array('gulp.gif', '19', '19', 'gulp'),
|
||||
'8-/' => array('ohoh.gif', '19', '19', 'oh oh'),
|
||||
':down:' => array('downer.gif', '19', '19', 'downer'),
|
||||
':red:' => array('embarrassed.gif', '19', '19', 'red face'),
|
||||
':sick:' => array('sick.gif', '19', '19', 'sick'),
|
||||
':shut:' => array('shuteye.gif', '19', '19', 'shut eye'),
|
||||
':-/' => array('hmm.gif', '19', '19', 'hmmm'),
|
||||
'>:(' => array('mad.gif', '19', '19', 'mad'),
|
||||
':mad:' => array('mad.gif', '19', '19', 'mad'),
|
||||
'>:-(' => array('angry.gif', '19', '19', 'angry'),
|
||||
':angry:' => array('angry.gif', '19', '19', 'angry'),
|
||||
':zip:' => array('zip.gif', '19', '19', 'zipper'),
|
||||
':kiss:' => array('kiss.gif', '19', '19', 'kiss'),
|
||||
':ahhh:' => array('shock.gif', '19', '19', 'shock'),
|
||||
':coolsmile:' => array('shade_smile.gif', '19', '19', 'cool smile'),
|
||||
':coolsmirk:' => array('shade_smirk.gif', '19', '19', 'cool smirk'),
|
||||
':coolgrin:' => array('shade_grin.gif', '19', '19', 'cool grin'),
|
||||
':coolhmm:' => array('shade_hmm.gif', '19', '19', 'cool hmm'),
|
||||
':coolmad:' => array('shade_mad.gif', '19', '19', 'cool mad'),
|
||||
':coolcheese:' => array('shade_cheese.gif', '19', '19', 'cool cheese'),
|
||||
':vampire:' => array('vampire.gif', '19', '19', 'vampire'),
|
||||
':snake:' => array('snake.gif', '19', '19', 'snake'),
|
||||
':exclaim:' => array('exclaim.gif', '19', '19', 'exclaim'),
|
||||
':question:' => array('question.gif', '19', '19', 'question')
|
||||
|
||||
);
|
|
@ -0,0 +1,216 @@
|
|||
<?php
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
|
||||
/*
|
||||
| -------------------------------------------------------------------
|
||||
| USER AGENT TYPES
|
||||
| -------------------------------------------------------------------
|
||||
| This file contains four arrays of user agent data. It is used by the
|
||||
| User Agent Class to help identify browser, platform, robot, and
|
||||
| mobile device data. The array keys are used to identify the device
|
||||
| and the array values are used to set the actual name of the item.
|
||||
*/
|
||||
$platforms = array(
|
||||
'windows nt 10.0' => 'Windows 10',
|
||||
'windows nt 6.3' => 'Windows 8.1',
|
||||
'windows nt 6.2' => 'Windows 8',
|
||||
'windows nt 6.1' => 'Windows 7',
|
||||
'windows nt 6.0' => 'Windows Vista',
|
||||
'windows nt 5.2' => 'Windows 2003',
|
||||
'windows nt 5.1' => 'Windows XP',
|
||||
'windows nt 5.0' => 'Windows 2000',
|
||||
'windows nt 4.0' => 'Windows NT 4.0',
|
||||
'winnt4.0' => 'Windows NT 4.0',
|
||||
'winnt 4.0' => 'Windows NT',
|
||||
'winnt' => 'Windows NT',
|
||||
'windows 98' => 'Windows 98',
|
||||
'win98' => 'Windows 98',
|
||||
'windows 95' => 'Windows 95',
|
||||
'win95' => 'Windows 95',
|
||||
'windows phone' => 'Windows Phone',
|
||||
'windows' => 'Unknown Windows OS',
|
||||
'android' => 'Android',
|
||||
'blackberry' => 'BlackBerry',
|
||||
'iphone' => 'iOS',
|
||||
'ipad' => 'iOS',
|
||||
'ipod' => 'iOS',
|
||||
'os x' => 'Mac OS X',
|
||||
'ppc mac' => 'Power PC Mac',
|
||||
'freebsd' => 'FreeBSD',
|
||||
'ppc' => 'Macintosh',
|
||||
'linux' => 'Linux',
|
||||
'debian' => 'Debian',
|
||||
'sunos' => 'Sun Solaris',
|
||||
'beos' => 'BeOS',
|
||||
'apachebench' => 'ApacheBench',
|
||||
'aix' => 'AIX',
|
||||
'irix' => 'Irix',
|
||||
'osf' => 'DEC OSF',
|
||||
'hp-ux' => 'HP-UX',
|
||||
'netbsd' => 'NetBSD',
|
||||
'bsdi' => 'BSDi',
|
||||
'openbsd' => 'OpenBSD',
|
||||
'gnu' => 'GNU/Linux',
|
||||
'unix' => 'Unknown Unix OS',
|
||||
'symbian' => 'Symbian OS'
|
||||
);
|
||||
|
||||
|
||||
// The order of this array should NOT be changed. Many browsers return
|
||||
// multiple browser types so we want to identify the sub-type first.
|
||||
$browsers = array(
|
||||
'OPR' => 'Opera',
|
||||
'Flock' => 'Flock',
|
||||
'Edge' => 'Edge',
|
||||
'Chrome' => 'Chrome',
|
||||
// Opera 10+ always reports Opera/9.80 and appends Version/<real version> to the user agent string
|
||||
'Opera.*?Version' => 'Opera',
|
||||
'Opera' => 'Opera',
|
||||
'MSIE' => 'Internet Explorer',
|
||||
'Internet Explorer' => 'Internet Explorer',
|
||||
'Trident.* rv' => 'Internet Explorer',
|
||||
'Shiira' => 'Shiira',
|
||||
'Firefox' => 'Firefox',
|
||||
'Chimera' => 'Chimera',
|
||||
'Phoenix' => 'Phoenix',
|
||||
'Firebird' => 'Firebird',
|
||||
'Camino' => 'Camino',
|
||||
'Netscape' => 'Netscape',
|
||||
'OmniWeb' => 'OmniWeb',
|
||||
'Safari' => 'Safari',
|
||||
'Mozilla' => 'Mozilla',
|
||||
'Konqueror' => 'Konqueror',
|
||||
'icab' => 'iCab',
|
||||
'Lynx' => 'Lynx',
|
||||
'Links' => 'Links',
|
||||
'hotjava' => 'HotJava',
|
||||
'amaya' => 'Amaya',
|
||||
'IBrowse' => 'IBrowse',
|
||||
'Maxthon' => 'Maxthon',
|
||||
'Ubuntu' => 'Ubuntu Web Browser'
|
||||
);
|
||||
|
||||
$mobiles = array(
|
||||
// legacy array, old values commented out
|
||||
'mobileexplorer' => 'Mobile Explorer',
|
||||
// 'openwave' => 'Open Wave',
|
||||
// 'opera mini' => 'Opera Mini',
|
||||
// 'operamini' => 'Opera Mini',
|
||||
// 'elaine' => 'Palm',
|
||||
'palmsource' => 'Palm',
|
||||
// 'digital paths' => 'Palm',
|
||||
// 'avantgo' => 'Avantgo',
|
||||
// 'xiino' => 'Xiino',
|
||||
'palmscape' => 'Palmscape',
|
||||
// 'nokia' => 'Nokia',
|
||||
// 'ericsson' => 'Ericsson',
|
||||
// 'blackberry' => 'BlackBerry',
|
||||
// 'motorola' => 'Motorola'
|
||||
|
||||
// Phones and Manufacturers
|
||||
'motorola' => 'Motorola',
|
||||
'nokia' => 'Nokia',
|
||||
'nexus' => 'Nexus',
|
||||
'palm' => 'Palm',
|
||||
'iphone' => 'Apple iPhone',
|
||||
'ipad' => 'iPad',
|
||||
'ipod' => 'Apple iPod Touch',
|
||||
'sony' => 'Sony Ericsson',
|
||||
'ericsson' => 'Sony Ericsson',
|
||||
'blackberry' => 'BlackBerry',
|
||||
'cocoon' => 'O2 Cocoon',
|
||||
'blazer' => 'Treo',
|
||||
'lg' => 'LG',
|
||||
'amoi' => 'Amoi',
|
||||
'xda' => 'XDA',
|
||||
'mda' => 'MDA',
|
||||
'vario' => 'Vario',
|
||||
'htc' => 'HTC',
|
||||
'samsung' => 'Samsung',
|
||||
'sharp' => 'Sharp',
|
||||
'sie-' => 'Siemens',
|
||||
'alcatel' => 'Alcatel',
|
||||
'benq' => 'BenQ',
|
||||
'ipaq' => 'HP iPaq',
|
||||
'mot-' => 'Motorola',
|
||||
'playstation portable' => 'PlayStation Portable',
|
||||
'playstation 3' => 'PlayStation 3',
|
||||
'playstation vita' => 'PlayStation Vita',
|
||||
'hiptop' => 'Danger Hiptop',
|
||||
'nec-' => 'NEC',
|
||||
'panasonic' => 'Panasonic',
|
||||
'philips' => 'Philips',
|
||||
'sagem' => 'Sagem',
|
||||
'sanyo' => 'Sanyo',
|
||||
'spv' => 'SPV',
|
||||
'zte' => 'ZTE',
|
||||
'sendo' => 'Sendo',
|
||||
'nintendo dsi' => 'Nintendo DSi',
|
||||
'nintendo ds' => 'Nintendo DS',
|
||||
'nintendo 3ds' => 'Nintendo 3DS',
|
||||
'wii' => 'Nintendo Wii',
|
||||
'open web' => 'Open Web',
|
||||
'openweb' => 'OpenWeb',
|
||||
'meizu' => 'Meizu',
|
||||
|
||||
// Operating Systems
|
||||
'android' => 'Android',
|
||||
'symbian' => 'Symbian',
|
||||
'SymbianOS' => 'SymbianOS',
|
||||
'elaine' => 'Palm',
|
||||
'series60' => 'Symbian S60',
|
||||
'windows ce' => 'Windows CE',
|
||||
|
||||
// Browsers
|
||||
'obigo' => 'Obigo',
|
||||
'netfront' => 'Netfront Browser',
|
||||
'openwave' => 'Openwave Browser',
|
||||
'mobilexplorer' => 'Mobile Explorer',
|
||||
'operamini' => 'Opera Mini',
|
||||
'opera mini' => 'Opera Mini',
|
||||
'opera mobi' => 'Opera Mobile',
|
||||
'fennec' => 'Firefox Mobile',
|
||||
|
||||
// Other
|
||||
'digital paths' => 'Digital Paths',
|
||||
'avantgo' => 'AvantGo',
|
||||
'xiino' => 'Xiino',
|
||||
'novarra' => 'Novarra Transcoder',
|
||||
'vodafone' => 'Vodafone',
|
||||
'docomo' => 'NTT DoCoMo',
|
||||
'o2' => 'O2',
|
||||
|
||||
// Fallback
|
||||
'mobile' => 'Generic Mobile',
|
||||
'wireless' => 'Generic Mobile',
|
||||
'j2me' => 'Generic Mobile',
|
||||
'midp' => 'Generic Mobile',
|
||||
'cldc' => 'Generic Mobile',
|
||||
'up.link' => 'Generic Mobile',
|
||||
'up.browser' => 'Generic Mobile',
|
||||
'smartphone' => 'Generic Mobile',
|
||||
'cellphone' => 'Generic Mobile'
|
||||
);
|
||||
|
||||
// There are hundreds of bots but these are the most common.
|
||||
$robots = array(
|
||||
'googlebot' => 'Googlebot',
|
||||
'msnbot' => 'MSNBot',
|
||||
'baiduspider' => 'Baiduspider',
|
||||
'bingbot' => 'Bing',
|
||||
'slurp' => 'Inktomi Slurp',
|
||||
'yahoo' => 'Yahoo',
|
||||
'ask jeeves' => 'Ask Jeeves',
|
||||
'fastcrawler' => 'FastCrawler',
|
||||
'infoseek' => 'InfoSeek Robot 1.0',
|
||||
'lycos' => 'Lycos',
|
||||
'yandex' => 'YandexBot',
|
||||
'mediapartners-google' => 'MediaPartners Google',
|
||||
'CRAZYWEBCRAWLER' => 'Crazy Webcrawler',
|
||||
'adsbot-google' => 'AdsBot Google',
|
||||
'feedfetcher-google' => 'Feedfetcher Google',
|
||||
'curious george' => 'Curious George',
|
||||
'ia_archiver' => 'Alexa Crawler',
|
||||
'MJ12bot' => 'Majestic-12',
|
||||
'Uptimebot' => 'Uptimebot'
|
||||
);
|
|
@ -0,0 +1,62 @@
|
|||
<?php
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
|
||||
class Alpha extends CI_Controller {
|
||||
//Mendeklarasikan kelas controller "Alpha"
|
||||
|
||||
/**
|
||||
* Index Page for this controller.
|
||||
*
|
||||
* Maps to the following URL
|
||||
* http://example.com/index.php/welcome
|
||||
* - or -
|
||||
* http://example.com/index.php/welcome/index
|
||||
* - or -
|
||||
* Since this controller is set as the default controller in
|
||||
* config/routes.php, it's displayed at http://example.com/
|
||||
*
|
||||
* So any other public methods not prefixed with an underscore will
|
||||
* map to /index.php/welcome/<method_name>
|
||||
* @see https://codeigniter.com/user_guide/general/urls.html
|
||||
*/
|
||||
public function __construct()
|
||||
{
|
||||
parent::__construct();
|
||||
$this->load->model('User_model');
|
||||
//Memuat model 'User_model' agar dapat digunakan dalam controller ini.
|
||||
$this->load->model('Alpha_model');
|
||||
$this->load->model('Hasil_forecast_model');
|
||||
is_logged_in();
|
||||
//Memanggil fungsi untuk memeriksa apakah pengguna telah login.
|
||||
}
|
||||
public function index()
|
||||
{
|
||||
$data['nama'] = "Parameter Alpha";
|
||||
//Menyiapkan variabel $data['nama'] dengan nilai "Parameter Alpha" untuk ditampilkan di halaman
|
||||
$id_user=$this->session->userdata('id_user');
|
||||
//Mendapatkan id pengguna dari session
|
||||
$data['user']=$this->User_model->get_user($id_user);
|
||||
$data['alpha']=$this->Alpha_model->get_alpha();
|
||||
//Mendapatkan data alpha dari model Alpha dan disimpan dalam variabel
|
||||
$this->form_validation->set_rules('alpha', 'Alpha', 'required');
|
||||
if ($this->form_validation->run() == false) {
|
||||
//Memeriksa apakah validasi form gagal.
|
||||
$this->load->view('Templates/header.php', $data);
|
||||
//Memuat view 'header.php' dari folder "Templates"
|
||||
$this->load->view('Templates/navbar.php', $data);
|
||||
$this->load->view('Templates/leftmenu.php', $data);
|
||||
$this->load->view('Alpha/index.php', $data);
|
||||
$this->load->view('Templates/footer.php', $data);
|
||||
}else{
|
||||
$alpha =$this->input->post('alpha', true);
|
||||
//Mengambil nilai 'alpha' dari form
|
||||
|
||||
$this->Alpha_model->update_alpha($alpha,1);
|
||||
$this->Hasil_forecast_model->update_alpha($alpha);
|
||||
|
||||
$this->session->set_flashdata('flash', 'Diubah');
|
||||
$this->session->set_flashdata('data', 'Alpha');
|
||||
redirect('alpha');
|
||||
}
|
||||
}
|
||||
}
|
|
@ -0,0 +1,126 @@
|
|||
<?php
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
|
||||
class Auth extends CI_Controller {
|
||||
|
||||
/**
|
||||
* Index Page for this controller.
|
||||
*
|
||||
* Maps to the following URL
|
||||
* http://example.com/index.php/welcome
|
||||
* - or -
|
||||
* http://example.com/index.php/welcome/index
|
||||
* - or -
|
||||
* Since this controller is set as the default controller in
|
||||
* config/routes.php, it's displayed at http://example.com/
|
||||
*
|
||||
* So any other public methods not prefixed with an underscore will
|
||||
* map to /index.php/welcome/<method_name>
|
||||
* @see https://codeigniter.com/user_guide/general/urls.html
|
||||
*/
|
||||
public function __construct()
|
||||
{
|
||||
parent::__construct();
|
||||
|
||||
$this->load->library('form_validation');
|
||||
|
||||
}
|
||||
public function index()
|
||||
{
|
||||
$data['nama'] = "Login";
|
||||
$this->form_validation->set_rules('username', 'Username', 'required|trim');
|
||||
$this->form_validation->set_rules('password', 'Password', 'required|trim');
|
||||
if ($this->form_validation->run() == false) {
|
||||
$this->load->view('Auth/index.php', $data);
|
||||
}else{
|
||||
$this->_login();
|
||||
}
|
||||
}
|
||||
public function _login(){
|
||||
$username = $this->input->post('username');
|
||||
$password = $this->input->post('password');
|
||||
$user = $this->db->get_where('m_user', ['username' => $username])->row_array();
|
||||
if ($user) {
|
||||
|
||||
if (password_verify($password, $user['password'])) {
|
||||
|
||||
$data = [
|
||||
'username' => $user['username'],
|
||||
'id_user' => $user['id_user']
|
||||
|
||||
|
||||
];
|
||||
$this->session->set_userdata($data);
|
||||
redirect('home');
|
||||
|
||||
} else {
|
||||
// jika password salaha
|
||||
$this->session->set_flashdata('flash', 'Salah');
|
||||
$this->session->set_flashdata('data', 'Password');
|
||||
$this->session->set_flashdata('message', '<div class="alert alert-danger" role="alert">Password salah</div>');
|
||||
|
||||
redirect('auth');
|
||||
}
|
||||
} else {
|
||||
$this->session->set_flashdata('message', '<div class="alert alert-danger" role="alert">Username belum terdaftar</div>');
|
||||
$this->session->set_flashdata('flash', 'Terdaftar');
|
||||
$this->session->set_flashdata('data', 'Username Anda Belum');
|
||||
redirect('auth');
|
||||
}
|
||||
}
|
||||
public function registration()
|
||||
{
|
||||
|
||||
$this->form_validation->set_rules('username', 'Username', 'required|trim');
|
||||
$this->form_validation->set_rules('email', 'Email', 'required|trim');
|
||||
//rules ngecek email uniq
|
||||
|
||||
$this->form_validation->set_rules(
|
||||
'password',
|
||||
'Password',
|
||||
'required|trim|min_length[3]',
|
||||
[
|
||||
'min_length' => 'Password is too short'
|
||||
]
|
||||
);
|
||||
|
||||
$this->form_validation->set_rules(
|
||||
'con_password',
|
||||
'Confirmation Password',
|
||||
'required|matches[password]',
|
||||
[
|
||||
'matches' => 'The confirmation password does not match the password'
|
||||
]
|
||||
);
|
||||
$data['nama'] = "Registrasi";
|
||||
if ($this->form_validation->run() == false) {
|
||||
$this->load->view('Auth/auth-register', $data);
|
||||
} else {
|
||||
|
||||
$data = [
|
||||
'id_user' => '',
|
||||
'email' => htmlspecialchars($this->input->post('email', true)),
|
||||
'username' => htmlspecialchars($this->input->post('username', true)),
|
||||
'password' => password_hash($this->input->post('password'), PASSWORD_DEFAULT)
|
||||
|
||||
];
|
||||
|
||||
$this->db->insert('m_user', $data);
|
||||
//kasi pesan
|
||||
$this->session->set_flashdata('message', '<div class="alert alert-success" role="alert">Registrasi Sukses</div');
|
||||
$this->session->set_flashdata('flash1', 'Terdaftar');
|
||||
$this->session->set_flashdata('data1', 'Anda Telah');
|
||||
redirect('auth');
|
||||
}
|
||||
}
|
||||
public function logout()
|
||||
{
|
||||
//membersihkan session
|
||||
$this->session->unset_userdata('username');
|
||||
$this->session->unset_userdata('id_user');
|
||||
$this->session->set_flashdata('flash1', 'Logout');
|
||||
$this->session->set_flashdata('data1', 'Anda Telah Berhasil');
|
||||
|
||||
redirect('auth');
|
||||
}
|
||||
}
|
|
@ -0,0 +1,78 @@
|
|||
<?php
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
|
||||
require_once APPPATH . "third_party/vendor/autoload.php";
|
||||
|
||||
|
||||
use Dompdf\Dompdf;
|
||||
|
||||
class Excel extends CI_Controller {
|
||||
|
||||
public function __construct()
|
||||
{
|
||||
parent::__construct();
|
||||
$this->load->model('User_model');
|
||||
$this->load->model('Alpha_model');
|
||||
$this->load->model('Hasil_forecast_model');
|
||||
$this->load->model('Data_kopi_model');
|
||||
$this->load->model('Jenis_model');
|
||||
is_logged_in();
|
||||
}
|
||||
|
||||
public function exportkopi()
|
||||
{
|
||||
$dompdf = new Dompdf();
|
||||
|
||||
$data['title'] = 'Export Produksi Kopi';
|
||||
$data['data_kopi']=$this->Data_kopi_model->get_all_data_kopi();
|
||||
$html = $this->load->view('excel/kopi', $data, TRUE);
|
||||
|
||||
$dompdf->load_html($html);
|
||||
|
||||
$dompdf->render();
|
||||
|
||||
$dompdf->stream('Produksi-Kopi '.date('Y-m-d').'.pdf');
|
||||
}
|
||||
|
||||
public function exportjenis()
|
||||
{
|
||||
$dompdf = new Dompdf();
|
||||
|
||||
$data['title'] = 'Export Jenis Kopi';
|
||||
$data['jenis_kopi']=$this->Jenis_model->get_all_data();
|
||||
$html = $this->load->view('excel/jeniskopi', $data, TRUE);
|
||||
|
||||
$dompdf->load_html($html);
|
||||
|
||||
$dompdf->render();
|
||||
|
||||
$dompdf->stream('Jenis-Kopi '.date('Y-m-d').'.pdf');
|
||||
}
|
||||
|
||||
public function exportresult($jeniskopi)
|
||||
{
|
||||
$dompdf = new Dompdf();
|
||||
|
||||
$data['title'] = 'Export Hasil Forecasting';
|
||||
|
||||
$data['at']=$this->Hasil_forecast_model->get_at($jeniskopi);
|
||||
$data['ft']=$this->Hasil_forecast_model->get_ft($jeniskopi);
|
||||
$data['bulan']=$this->Hasil_forecast_model->get_bulan($jeniskopi);
|
||||
$data['hitung_ses1']=$this->Hasil_forecast_model->get_allses($jeniskopi);
|
||||
$data['mse'] = $this->Hasil_forecast_model->mse($jeniskopi);
|
||||
$data['rmse'] = number_format(sqrt($this->Hasil_forecast_model->mse($jeniskopi)),2);
|
||||
$data['mad'] = $this->Hasil_forecast_model->get_mad($jeniskopi);
|
||||
$data['mape'] = $this->Hasil_forecast_model->get_mape($jeniskopi);
|
||||
$data['bulan_selanjutnya'] = $this->Hasil_forecast_model->bulan_berikut($jeniskopi);
|
||||
|
||||
$data['countall'] = $this->Hasil_forecast_model->count_mse($jeniskopi);
|
||||
|
||||
$html = $this->load->view('excel/result', $data, true);
|
||||
|
||||
$dompdf->load_html($html);
|
||||
|
||||
$dompdf->render();
|
||||
|
||||
$dompdf->stream('Data-Forecasting '.date('Y-m-d').'.pdf');
|
||||
}
|
||||
}
|
|
@ -0,0 +1,71 @@
|
|||
<?php
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
|
||||
class Hasilses extends CI_Controller {
|
||||
|
||||
|
||||
public function __construct()
|
||||
{
|
||||
parent::__construct();
|
||||
$this->load->model('User_model');
|
||||
$this->load->model('Hasil_forecast_model');
|
||||
is_logged_in();
|
||||
}
|
||||
public function index()
|
||||
{
|
||||
$data['nama'] = "Hasil Single Exponential Smooting";
|
||||
$id_user=$this->session->userdata('id_user');
|
||||
$data['user']=$this->User_model->get_user($id_user);
|
||||
|
||||
$data['jenis'] = $this->db->get('jenis_kopi')->result();
|
||||
|
||||
$this->load->view('Templates/header.php', $data);
|
||||
$this->load->view('Templates/navbar.php', $data);
|
||||
$this->load->view('Templates/leftmenu.php', $data);
|
||||
$this->load->view('Hasil_SES/index.php', $data);
|
||||
$this->load->view('Templates/footer.php', $data);
|
||||
|
||||
}
|
||||
|
||||
public function result()
|
||||
{
|
||||
$jeniskopi = $this->input->post('jenis', true);
|
||||
$data['nama'] = "Hasil Single Exponential Smooting";
|
||||
$id_user=$this->session->userdata('id_user');
|
||||
$data['user']=$this->User_model->get_user($id_user);
|
||||
|
||||
$data['jeniskopi']= $jeniskopi;
|
||||
|
||||
|
||||
$data['at']=$this->Hasil_forecast_model->get_at($jeniskopi);
|
||||
$data['ft']=$this->Hasil_forecast_model->get_ft($jeniskopi);
|
||||
$data['bulan']=$this->Hasil_forecast_model->get_bulan($jeniskopi);
|
||||
$data['hitung_ses1']=$this->Hasil_forecast_model->get_allses($jeniskopi);
|
||||
$data['mse'] = $this->Hasil_forecast_model->mse($jeniskopi);
|
||||
$data['rmse'] = number_format(sqrt($this->Hasil_forecast_model->mse($jeniskopi)),2);
|
||||
$data['mad'] = $this->Hasil_forecast_model->get_mad($jeniskopi);
|
||||
$data['mape'] = $this->Hasil_forecast_model->get_mape($jeniskopi);
|
||||
$data['bulan_selanjutnya'] = $this->Hasil_forecast_model->bulan_berikut($jeniskopi);
|
||||
|
||||
$data['countall'] = $this->Hasil_forecast_model->count_mse($jeniskopi);
|
||||
|
||||
$this->db->select('*');
|
||||
$this->db->from('jumlah_forecasting');
|
||||
$this->db->where('id',1);
|
||||
$totaldibuka = $this->db->get()->row_array();
|
||||
|
||||
$totalresult = $totaldibuka['total'] + 1;
|
||||
|
||||
$this->db->set('total', $totalresult);
|
||||
$this->db->where('id',1);
|
||||
$update = $this->db->update('jumlah_forecasting');
|
||||
|
||||
$this->load->view('Templates/header.php', $data);
|
||||
$this->load->view('Templates/navbar.php', $data);
|
||||
$this->load->view('Templates/leftmenu.php', $data);
|
||||
$this->load->view('Hasil_SES/result.php', $data);
|
||||
$this->load->view('Templates/footer.php', $data);
|
||||
|
||||
}
|
||||
|
||||
}
|
|
@ -0,0 +1,33 @@
|
|||
<?php
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
|
||||
class Home extends CI_Controller {
|
||||
|
||||
public function __construct()
|
||||
{
|
||||
parent::__construct();
|
||||
|
||||
$this->load->model('User_model');
|
||||
is_logged_in();
|
||||
}
|
||||
public function index()
|
||||
{
|
||||
$data['nama'] = "Beranda";
|
||||
$id_user=$this->session->userdata('id_user');
|
||||
$data['user']=$this->User_model->get_user($id_user);
|
||||
|
||||
$this->db->select('*');
|
||||
$this->db->from('jumlah_forecasting');
|
||||
$this->db->where('id',1);
|
||||
$data['forecasting'] = $this->db->get()->row_array();
|
||||
$data['jenis'] = $this->db->get('jenis_kopi')->num_rows();
|
||||
$data['data'] = $this->db->get('data_kopi')->num_rows();
|
||||
|
||||
|
||||
$this->load->view('Templates/header.php',$data);
|
||||
$this->load->view('Templates/navbar.php',$data);
|
||||
$this->load->view('Templates/leftmenu.php',$data);
|
||||
$this->load->view('Beranda/index.php',$data);
|
||||
$this->load->view('Templates/footer.php',$data);
|
||||
}
|
||||
}
|
|
@ -0,0 +1,89 @@
|
|||
<?php
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
|
||||
class Jeniskopi extends CI_Controller {
|
||||
|
||||
|
||||
public function __construct()
|
||||
{
|
||||
parent::__construct();
|
||||
$this->load->model('Jenis_model');
|
||||
$this->load->model('User_model');
|
||||
is_logged_in();
|
||||
}
|
||||
public function index()
|
||||
{
|
||||
|
||||
$data['jenis_kopi']=$this->Jenis_model->get_all_data();
|
||||
$id_user=$this->session->userdata('id_user');
|
||||
$data['user']=$this->User_model->get_user($id_user);
|
||||
|
||||
$data['nama'] = "Data Jenis Kopi";
|
||||
|
||||
$this->load->view('Templates/header.php',$data);
|
||||
$this->load->view('Templates/navbar.php',$data);
|
||||
$this->load->view('Templates/leftmenu.php',$data);
|
||||
$this->load->view('jenis/index.php',$data);
|
||||
$this->load->view('Templates/footer.php',$data);
|
||||
}
|
||||
|
||||
public function tambah_jenis()
|
||||
{
|
||||
|
||||
$id_user=$this->session->userdata('id_user');
|
||||
$data['user']=$this->User_model->get_user($id_user);
|
||||
$data['nama'] = "Tambah Data Jenis Kopi";
|
||||
$this->form_validation->set_rules('nama', 'nama', 'required');
|
||||
if ($this->form_validation->run() == false) {
|
||||
$this->load->view('Templates/header.php',$data);
|
||||
$this->load->view('Templates/navbar.php',$data);
|
||||
$this->load->view('Templates/leftmenu.php',$data);
|
||||
$this->load->view('jenis/tambah_jenis.php',$data);
|
||||
$this->load->view('Templates/footer.php',$data);
|
||||
}else{
|
||||
|
||||
$nama=$this->input->post('nama', true);
|
||||
$deskripsi=$this->input->post('deskripsi', true);
|
||||
$this->Jenis_model->add($nama,$deskripsi);
|
||||
$this->session->set_flashdata('flash', 'Ditambahkan');
|
||||
$this->session->set_flashdata('data', 'Data Jenis kopi');
|
||||
|
||||
redirect('jeniskopi');
|
||||
}
|
||||
}
|
||||
|
||||
public function edit_jenis($id)
|
||||
{
|
||||
$data['jenis_kopi']=$this->Jenis_model->get_data_byid($id);
|
||||
$id_user=$this->session->userdata('id_user');
|
||||
$data['user']=$this->User_model->get_user($id_user);
|
||||
$data['nama'] = "Edit Data Jenis Kopi";
|
||||
$this->form_validation->set_rules('nama', 'nama', 'required');
|
||||
if ($this->form_validation->run() == false) {
|
||||
$this->load->view('Templates/header.php',$data);
|
||||
$this->load->view('Templates/navbar.php',$data);
|
||||
$this->load->view('Templates/leftmenu.php',$data);
|
||||
$this->load->view('jenis/edit_jenis.php',$data);
|
||||
$this->load->view('Templates/footer.php',$data);
|
||||
}else{
|
||||
|
||||
$nama=$this->input->post('nama', true);
|
||||
$deskripsi=$this->input->post('deskripsi', true);
|
||||
$this->Jenis_model->edit($id,$nama,$deskripsi);
|
||||
$this->session->set_flashdata('flash', 'Diupdate');
|
||||
$this->session->set_flashdata('data', 'Data Jenis kopi');
|
||||
|
||||
redirect('jeniskopi');
|
||||
}
|
||||
}
|
||||
|
||||
public function hapus_jenis($id)
|
||||
{
|
||||
|
||||
$this->Jenis_model->hapus($id);
|
||||
$this->session->set_flashdata('flash', 'dihapus');
|
||||
$this->session->set_flashdata('data', 'Data Kopi');
|
||||
|
||||
redirect('jeniskopi');
|
||||
}
|
||||
}
|
|
@ -0,0 +1,109 @@
|
|||
<?php
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
|
||||
class Kopi extends CI_Controller {
|
||||
|
||||
|
||||
public function __construct()
|
||||
{
|
||||
parent::__construct();
|
||||
$this->load->model('User_model');
|
||||
$this->load->model('Alpha_model');
|
||||
$this->load->model('Data_kopi_model');
|
||||
$this->load->model('Jenis_model');
|
||||
$this->load->model('Hasil_forecast_model');
|
||||
is_logged_in();
|
||||
}
|
||||
public function index()
|
||||
{
|
||||
|
||||
$data['data_kopi']=$this->Data_kopi_model->get_all_data_kopi();
|
||||
$id_user=$this->session->userdata('id_user');
|
||||
$data['user']=$this->User_model->get_user($id_user);
|
||||
|
||||
$data['nama'] = "Data Produksi Kopi";
|
||||
|
||||
$this->load->view('Templates/header.php',$data);
|
||||
$this->load->view('Templates/navbar.php',$data);
|
||||
$this->load->view('Templates/leftmenu.php',$data);
|
||||
$this->load->view('Minyak/index.php',$data);
|
||||
$this->load->view('Templates/footer.php',$data);
|
||||
}
|
||||
public function tambah_kopi()
|
||||
{
|
||||
|
||||
$data['jenis_kopi']=$this->Jenis_model->get_all_data();
|
||||
$id_user=$this->session->userdata('id_user');
|
||||
$data['user']=$this->User_model->get_user($id_user);
|
||||
$data['nama'] = "Tambah Data Produksi Kopi";
|
||||
$this->form_validation->set_rules('jumlah_kopi', 'jumlah_kopi', 'required');
|
||||
$this->form_validation->set_rules('bulan_tahun', 'bulan_tahun', 'required');
|
||||
$this->form_validation->set_rules('jenis_kopi', 'jenis_kopi', 'required');
|
||||
if ($this->form_validation->run() == false) {
|
||||
$this->load->view('Templates/header.php',$data);
|
||||
$this->load->view('Templates/navbar.php',$data);
|
||||
$this->load->view('Templates/leftmenu.php',$data);
|
||||
$this->load->view('Minyak/tambah_minyak.php',$data);
|
||||
$this->load->view('Templates/footer.php',$data);
|
||||
}else{
|
||||
|
||||
|
||||
$bulan_tahun=date($this->input->post('bulan_tahun', true));
|
||||
$bulan=(integer)date("m",strtotime($bulan_tahun));
|
||||
$tahun=date("Y",strtotime($bulan_tahun));
|
||||
$jumlah_kopi=$this->input->post('jumlah_kopi', true);
|
||||
$jenis_kopi =$this->input->post('jenis_kopi', true);
|
||||
|
||||
$this->Data_kopi_model->add_data_kopi($tahun,$bulan,$jumlah_kopi, $jenis_kopi);
|
||||
$insert_id = $this->db->insert_id();
|
||||
$this->Hasil_forecast_model->create($insert_id,$jenis_kopi,$jumlah_kopi);
|
||||
|
||||
|
||||
$this->session->set_flashdata('flash', 'Ditambahkan');
|
||||
$this->session->set_flashdata('data', 'Data Kopi');
|
||||
|
||||
redirect('kopi');
|
||||
}
|
||||
}
|
||||
public function hapus_kopi($id)
|
||||
{
|
||||
|
||||
$this->Data_kopi_model->hps_data_kopi($id);
|
||||
$this->Data_kopi_model->delete_hasil_ses($id);
|
||||
$this->session->set_flashdata('flash', 'dihapus');
|
||||
$this->session->set_flashdata('data', 'Data Kopi');
|
||||
|
||||
redirect('kopi');
|
||||
}
|
||||
public function edit_kopi($id)
|
||||
{
|
||||
|
||||
$data['jenis_kopi']=$this->Jenis_model->get_all_data();
|
||||
$data['data_kopi']=$this->Data_kopi_model->get_data_kopi_byid($id);
|
||||
$id_user=$this->session->userdata('id_user');
|
||||
$data['user']=$this->User_model->get_user($id_user);
|
||||
$data['nama'] = "Edit Produksi Kopi";
|
||||
|
||||
$this->load->view('Templates/header.php',$data);
|
||||
$this->load->view('Templates/navbar.php',$data);
|
||||
$this->load->view('Templates/leftmenu.php',$data);
|
||||
$this->load->view('Minyak/edit_minyak.php',$data);
|
||||
$this->load->view('Templates/footer.php',$data);
|
||||
}
|
||||
public function save_edit()
|
||||
{
|
||||
$id=$this->input->post('id', true);
|
||||
|
||||
$tahun=date($this->input->post('tahun', true));
|
||||
$bulan=date($this->input->post('bulan', true));
|
||||
|
||||
$jumlah_kopi=$this->input->post('jumlah_kopi', true);
|
||||
|
||||
$this->Data_kopi_model->update_data_kopi($id,$jumlah_kopi,$tahun,$bulan);
|
||||
$this->Hasil_forecast_model->update($id,$jumlah_kopi);
|
||||
|
||||
$this->session->set_flashdata('flash', 'Diupdate');
|
||||
$this->session->set_flashdata('data', 'Data Kopi');
|
||||
redirect('kopi');
|
||||
}
|
||||
}
|
|
@ -0,0 +1,105 @@
|
|||
<?php
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
|
||||
class Users extends CI_Controller {
|
||||
|
||||
|
||||
public function __construct()
|
||||
{
|
||||
parent::__construct();
|
||||
$this->load->model('User_model');
|
||||
is_logged_in();
|
||||
}
|
||||
|
||||
public function index() {
|
||||
$data['users']=$this->User_model->get_user_all();
|
||||
$id_user=$this->session->userdata('id_user');
|
||||
$data['user']=$this->User_model->get_user($id_user);
|
||||
|
||||
$data['nama'] = "Data Users";
|
||||
|
||||
$this->load->view('Templates/header.php',$data);
|
||||
$this->load->view('Templates/navbar.php',$data);
|
||||
$this->load->view('Templates/leftmenu.php',$data);
|
||||
$this->load->view('users/index.php',$data);
|
||||
$this->load->view('Templates/footer.php',$data);
|
||||
}
|
||||
|
||||
public function tambah()
|
||||
{
|
||||
|
||||
$id_user=$this->session->userdata('id_user');
|
||||
$data['user']=$this->User_model->get_user($id_user);
|
||||
$data['nama'] = "Tambah data";
|
||||
|
||||
$this->form_validation->set_rules('email', 'email', 'required|is_unique[m_user.email]');
|
||||
$this->form_validation->set_rules('username', 'username', 'required|is_unique[m_user.username]');
|
||||
$this->form_validation->set_rules('password', 'password', 'required|trim|min_length[3]');
|
||||
|
||||
if ($this->form_validation->run() == false) {
|
||||
|
||||
$this->load->view('Templates/header.php',$data);
|
||||
$this->load->view('Templates/navbar.php',$data);
|
||||
$this->load->view('Templates/leftmenu.php',$data);
|
||||
$this->load->view('users/tambah.php',$data);
|
||||
$this->load->view('Templates/footer.php',$data);
|
||||
|
||||
}else{
|
||||
|
||||
|
||||
$email=$this->input->post('email', true);
|
||||
$username=$this->input->post('username', true);
|
||||
$password =$this->input->post('password', true);
|
||||
|
||||
$this->User_model->add($email,$username,$password);
|
||||
|
||||
|
||||
$this->session->set_flashdata('flash', 'Ditambahkan');
|
||||
$this->session->set_flashdata('data', 'Data Users');
|
||||
|
||||
redirect('users');
|
||||
}
|
||||
}
|
||||
|
||||
public function edit($id)
|
||||
{
|
||||
|
||||
$id_user=$this->session->userdata('id_user');
|
||||
$data['user']=$this->User_model->get_user($id_user);
|
||||
$data['nama'] = "Tambah data";
|
||||
|
||||
$this->form_validation->set_rules('password', 'password', 'required|trim|min_length[3]');
|
||||
|
||||
if ($this->form_validation->run() == false) {
|
||||
|
||||
$this->load->view('Templates/header.php',$data);
|
||||
$this->load->view('Templates/navbar.php',$data);
|
||||
$this->load->view('Templates/leftmenu.php',$data);
|
||||
$this->load->view('users/edit.php',$data);
|
||||
$this->load->view('Templates/footer.php',$data);
|
||||
|
||||
}else{
|
||||
|
||||
|
||||
$password =$this->input->post('password', true);
|
||||
|
||||
$this->User_model->edit($id,$password);
|
||||
|
||||
|
||||
$this->session->set_flashdata('flash', 'Ditambahkan');
|
||||
$this->session->set_flashdata('data', 'Data Users');
|
||||
|
||||
redirect('users');
|
||||
}
|
||||
}
|
||||
|
||||
public function hapus($id)
|
||||
{
|
||||
|
||||
$this->User_model->hapus($id);
|
||||
$this->session->set_flashdata('flash', 'dihapus');
|
||||
$this->session->set_flashdata('data', 'Data Users');
|
||||
|
||||
redirect('users');
|
||||
}
|
||||
}
|
|
@ -0,0 +1,11 @@
|
|||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<title>403 Forbidden</title>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<p>Directory access is forbidden.</p>
|
||||
|
||||
</body>
|
||||
</html>
|
|
@ -0,0 +1,11 @@
|
|||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<title>403 Forbidden</title>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<p>Directory access is forbidden.</p>
|
||||
|
||||
</body>
|
||||
</html>
|
|
@ -0,0 +1,11 @@
|
|||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<title>403 Forbidden</title>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<p>Directory access is forbidden.</p>
|
||||
|
||||
</body>
|
||||
</html>
|
|
@ -0,0 +1,9 @@
|
|||
<?php
|
||||
function is_logged_in()
|
||||
{
|
||||
$ci = get_instance();
|
||||
if (!$ci->session->userdata('id_user')) {
|
||||
|
||||
redirect('auth');
|
||||
}
|
||||
}
|
|
@ -0,0 +1,11 @@
|
|||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<title>403 Forbidden</title>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<p>Directory access is forbidden.</p>
|
||||
|
||||
</body>
|
||||
</html>
|
|
@ -0,0 +1,11 @@
|
|||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<title>403 Forbidden</title>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<p>Directory access is forbidden.</p>
|
||||
|
||||
</body>
|
||||
</html>
|
|
@ -0,0 +1,11 @@
|
|||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<title>403 Forbidden</title>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<p>Directory access is forbidden.</p>
|
||||
|
||||
</body>
|
||||
</html>
|
|
@ -0,0 +1,11 @@
|
|||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<title>403 Forbidden</title>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<p>Directory access is forbidden.</p>
|
||||
|
||||
</body>
|
||||
</html>
|
|
@ -0,0 +1,23 @@
|
|||
<?php defined('BASEPATH') or exit('No direct script access allowed');
|
||||
require_once 'domppdf/autoload.inc.php';
|
||||
use Dompdf\Dompdf;
|
||||
use Dompdf\Options;
|
||||
|
||||
class Pdfgenerator
|
||||
{
|
||||
public function generate($html, $filename = '', $paper = '', $orientation = '', $stream = TRUE)
|
||||
{
|
||||
$options = new Options();
|
||||
$options->set('isRemoteEnabled', TRUE);
|
||||
$dompdf = new Dompdf($options);
|
||||
$dompdf->loadHtml($html);
|
||||
$dompdf->setPaper($paper, $orientation);
|
||||
$dompdf->render();
|
||||
if ($stream) {
|
||||
$dompdf->stream($filename . ".pdf", array("Attachment" => 0));
|
||||
exit();
|
||||
} else {
|
||||
return $dompdf->output();
|
||||
}
|
||||
}
|
||||
}
|
|
@ -0,0 +1,24 @@
|
|||
Dompdf was designed and developed by Benj Carson.
|
||||
|
||||
### Current Team
|
||||
|
||||
* **Brian Sweeney** (maintainer)
|
||||
* **Till Berger**
|
||||
|
||||
### Alumni
|
||||
|
||||
* **Benj Carson** (creator)
|
||||
* **Fabien Ménager**
|
||||
* **Simon Berger**
|
||||
* **Orion Richardson**
|
||||
|
||||
### Contributors
|
||||
* **Gabriel Bull**
|
||||
* **Barry vd. Heuvel**
|
||||
* **Ryan H. Masten**
|
||||
* **Helmut Tischer**
|
||||
* [and many more...](https://github.com/dompdf/dompdf/graphs/contributors)
|
||||
|
||||
### Thanks
|
||||
|
||||
Dompdf would not have been possible without strong community support.
|
|
@ -0,0 +1,456 @@
|
|||
GNU LESSER GENERAL PUBLIC LICENSE
|
||||
Version 2.1, February 1999
|
||||
|
||||
Copyright (C) 1991, 1999 Free Software Foundation, Inc.
|
||||
59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
Everyone is permitted to copy and distribute verbatim copies
|
||||
of this license document, but changing it is not allowed.
|
||||
|
||||
[This is the first released version of the Lesser GPL. It also counts
|
||||
as the successor of the GNU Library Public License, version 2, hence
|
||||
the version number 2.1.]
|
||||
|
||||
Preamble
|
||||
|
||||
The licenses for most software are designed to take away your
|
||||
freedom to share and change it. By contrast, the GNU General Public
|
||||
Licenses are intended to guarantee your freedom to share and change
|
||||
free software--to make sure the software is free for all its users.
|
||||
|
||||
This license, the Lesser General Public License, applies to some
|
||||
specially designated software packages--typically libraries--of the
|
||||
Free Software Foundation and other authors who decide to use it. You
|
||||
can use it too, but we suggest you first think carefully about whether
|
||||
this license or the ordinary General Public License is the better
|
||||
strategy to use in any particular case, based on the explanations below.
|
||||
|
||||
When we speak of free software, we are referring to freedom of use,
|
||||
not price. Our General Public Licenses are designed to make sure that
|
||||
you have the freedom to distribute copies of free software (and charge
|
||||
for this service if you wish); that you receive source code or can get
|
||||
it if you want it; that you can change the software and use pieces of
|
||||
it in new free programs; and that you are informed that you can do
|
||||
these things.
|
||||
|
||||
To protect your rights, we need to make restrictions that forbid
|
||||
distributors to deny you these rights or to ask you to surrender these
|
||||
rights. These restrictions translate to certain responsibilities for
|
||||
you if you distribute copies of the library or if you modify it.
|
||||
|
||||
For example, if you distribute copies of the library, whether gratis
|
||||
or for a fee, you must give the recipients all the rights that we gave
|
||||
you. You must make sure that they, too, receive or can get the source
|
||||
code. If you link other code with the library, you must provide
|
||||
complete object files to the recipients, so that they can relink them
|
||||
with the library after making changes to the library and recompiling
|
||||
it. And you must show them these terms so they know their rights.
|
||||
|
||||
We protect your rights with a two-step method: (1) we copyright the
|
||||
library, and (2) we offer you this license, which gives you legal
|
||||
permission to copy, distribute and/or modify the library.
|
||||
|
||||
To protect each distributor, we want to make it very clear that
|
||||
there is no warranty for the free library. Also, if the library is
|
||||
modified by someone else and passed on, the recipients should know
|
||||
that what they have is not the original version, so that the original
|
||||
author's reputation will not be affected by problems that might be
|
||||
introduced by others.
|
||||
|
||||
Finally, software patents pose a constant threat to the existence of
|
||||
any free program. We wish to make sure that a company cannot
|
||||
effectively restrict the users of a free program by obtaining a
|
||||
restrictive license from a patent holder. Therefore, we insist that
|
||||
any patent license obtained for a version of the library must be
|
||||
consistent with the full freedom of use specified in this license.
|
||||
|
||||
Most GNU software, including some libraries, is covered by the
|
||||
ordinary GNU General Public License. This license, the GNU Lesser
|
||||
General Public License, applies to certain designated libraries, and
|
||||
is quite different from the ordinary General Public License. We use
|
||||
this license for certain libraries in order to permit linking those
|
||||
libraries into non-free programs.
|
||||
|
||||
When a program is linked with a library, whether statically or using
|
||||
a shared library, the combination of the two is legally speaking a
|
||||
combined work, a derivative of the original library. The ordinary
|
||||
General Public License therefore permits such linking only if the
|
||||
entire combination fits its criteria of freedom. The Lesser General
|
||||
Public License permits more lax criteria for linking other code with
|
||||
the library.
|
||||
|
||||
We call this license the "Lesser" General Public License because it
|
||||
does Less to protect the user's freedom than the ordinary General
|
||||
Public License. It also provides other free software developers Less
|
||||
of an advantage over competing non-free programs. These disadvantages
|
||||
are the reason we use the ordinary General Public License for many
|
||||
libraries. However, the Lesser license provides advantages in certain
|
||||
special circumstances.
|
||||
|
||||
For example, on rare occasions, there may be a special need to
|
||||
encourage the widest possible use of a certain library, so that it becomes
|
||||
a de-facto standard. To achieve this, non-free programs must be
|
||||
allowed to use the library. A more frequent case is that a free
|
||||
library does the same job as widely used non-free libraries. In this
|
||||
case, there is little to gain by limiting the free library to free
|
||||
software only, so we use the Lesser General Public License.
|
||||
|
||||
In other cases, permission to use a particular library in non-free
|
||||
programs enables a greater number of people to use a large body of
|
||||
free software. For example, permission to use the GNU C Library in
|
||||
non-free programs enables many more people to use the whole GNU
|
||||
operating system, as well as its variant, the GNU/Linux operating
|
||||
system.
|
||||
|
||||
Although the Lesser General Public License is Less protective of the
|
||||
users' freedom, it does ensure that the user of a program that is
|
||||
linked with the Library has the freedom and the wherewithal to run
|
||||
that program using a modified version of the Library.
|
||||
|
||||
The precise terms and conditions for copying, distribution and
|
||||
modification follow. Pay close attention to the difference between a
|
||||
"work based on the library" and a "work that uses the library". The
|
||||
former contains code derived from the library, whereas the latter must
|
||||
be combined with the library in order to run.
|
||||
|
||||
GNU LESSER GENERAL PUBLIC LICENSE
|
||||
TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
|
||||
|
||||
0. This License Agreement applies to any software library or other
|
||||
program which contains a notice placed by the copyright holder or
|
||||
other authorized party saying it may be distributed under the terms of
|
||||
this Lesser General Public License (also called "this License").
|
||||
Each licensee is addressed as "you".
|
||||
|
||||
A "library" means a collection of software functions and/or data
|
||||
prepared so as to be conveniently linked with application programs
|
||||
(which use some of those functions and data) to form executables.
|
||||
|
||||
The "Library", below, refers to any such software library or work
|
||||
which has been distributed under these terms. A "work based on the
|
||||
Library" means either the Library or any derivative work under
|
||||
copyright law: that is to say, a work containing the Library or a
|
||||
portion of it, either verbatim or with modifications and/or translated
|
||||
straightforwardly into another language. (Hereinafter, translation is
|
||||
included without limitation in the term "modification".)
|
||||
|
||||
"Source code" for a work means the preferred form of the work for
|
||||
making modifications to it. For a library, complete source code means
|
||||
all the source code for all modules it contains, plus any associated
|
||||
interface definition files, plus the scripts used to control compilation
|
||||
and installation of the library.
|
||||
|
||||
Activities other than copying, distribution and modification are not
|
||||
covered by this License; they are outside its scope. The act of
|
||||
running a program using the Library is not restricted, and output from
|
||||
such a program is covered only if its contents constitute a work based
|
||||
on the Library (independent of the use of the Library in a tool for
|
||||
writing it). Whether that is true depends on what the Library does
|
||||
and what the program that uses the Library does.
|
||||
|
||||
1. You may copy and distribute verbatim copies of the Library's
|
||||
complete source code as you receive it, in any medium, provided that
|
||||
you conspicuously and appropriately publish on each copy an
|
||||
appropriate copyright notice and disclaimer of warranty; keep intact
|
||||
all the notices that refer to this License and to the absence of any
|
||||
warranty; and distribute a copy of this License along with the
|
||||
Library.
|
||||
|
||||
You may charge a fee for the physical act of transferring a copy,
|
||||
and you may at your option offer warranty protection in exchange for a
|
||||
fee.
|
||||
|
||||
2. You may modify your copy or copies of the Library or any portion
|
||||
of it, thus forming a work based on the Library, and copy and
|
||||
distribute such modifications or work under the terms of Section 1
|
||||
above, provided that you also meet all of these conditions:
|
||||
|
||||
a) The modified work must itself be a software library.
|
||||
|
||||
b) You must cause the files modified to carry prominent notices
|
||||
stating that you changed the files and the date of any change.
|
||||
|
||||
c) You must cause the whole of the work to be licensed at no
|
||||
charge to all third parties under the terms of this License.
|
||||
|
||||
d) If a facility in the modified Library refers to a function or a
|
||||
table of data to be supplied by an application program that uses
|
||||
the facility, other than as an argument passed when the facility
|
||||
is invoked, then you must make a good faith effort to ensure that,
|
||||
in the event an application does not supply such function or
|
||||
table, the facility still operates, and performs whatever part of
|
||||
its purpose remains meaningful.
|
||||
|
||||
(For example, a function in a library to compute square roots has
|
||||
a purpose that is entirely well-defined independent of the
|
||||
application. Therefore, Subsection 2d requires that any
|
||||
application-supplied function or table used by this function must
|
||||
be optional: if the application does not supply it, the square
|
||||
root function must still compute square roots.)
|
||||
|
||||
These requirements apply to the modified work as a whole. If
|
||||
identifiable sections of that work are not derived from the Library,
|
||||
and can be reasonably considered independent and separate works in
|
||||
themselves, then this License, and its terms, do not apply to those
|
||||
sections when you distribute them as separate works. But when you
|
||||
distribute the same sections as part of a whole which is a work based
|
||||
on the Library, the distribution of the whole must be on the terms of
|
||||
this License, whose permissions for other licensees extend to the
|
||||
entire whole, and thus to each and every part regardless of who wrote
|
||||
it.
|
||||
|
||||
Thus, it is not the intent of this section to claim rights or contest
|
||||
your rights to work written entirely by you; rather, the intent is to
|
||||
exercise the right to control the distribution of derivative or
|
||||
collective works based on the Library.
|
||||
|
||||
In addition, mere aggregation of another work not based on the Library
|
||||
with the Library (or with a work based on the Library) on a volume of
|
||||
a storage or distribution medium does not bring the other work under
|
||||
the scope of this License.
|
||||
|
||||
3. You may opt to apply the terms of the ordinary GNU General Public
|
||||
License instead of this License to a given copy of the Library. To do
|
||||
this, you must alter all the notices that refer to this License, so
|
||||
that they refer to the ordinary GNU General Public License, version 2,
|
||||
instead of to this License. (If a newer version than version 2 of the
|
||||
ordinary GNU General Public License has appeared, then you can specify
|
||||
that version instead if you wish.) Do not make any other change in
|
||||
these notices.
|
||||
|
||||
Once this change is made in a given copy, it is irreversible for
|
||||
that copy, so the ordinary GNU General Public License applies to all
|
||||
subsequent copies and derivative works made from that copy.
|
||||
|
||||
This option is useful when you wish to copy part of the code of
|
||||
the Library into a program that is not a library.
|
||||
|
||||
4. You may copy and distribute the Library (or a portion or
|
||||
derivative of it, under Section 2) in object code or executable form
|
||||
under the terms of Sections 1 and 2 above provided that you accompany
|
||||
it with the complete corresponding machine-readable source code, which
|
||||
must be distributed under the terms of Sections 1 and 2 above on a
|
||||
medium customarily used for software interchange.
|
||||
|
||||
If distribution of object code is made by offering access to copy
|
||||
from a designated place, then offering equivalent access to copy the
|
||||
source code from the same place satisfies the requirement to
|
||||
distribute the source code, even though third parties are not
|
||||
compelled to copy the source along with the object code.
|
||||
|
||||
5. A program that contains no derivative of any portion of the
|
||||
Library, but is designed to work with the Library by being compiled or
|
||||
linked with it, is called a "work that uses the Library". Such a
|
||||
work, in isolation, is not a derivative work of the Library, and
|
||||
therefore falls outside the scope of this License.
|
||||
|
||||
However, linking a "work that uses the Library" with the Library
|
||||
creates an executable that is a derivative of the Library (because it
|
||||
contains portions of the Library), rather than a "work that uses the
|
||||
library". The executable is therefore covered by this License.
|
||||
Section 6 states terms for distribution of such executables.
|
||||
|
||||
When a "work that uses the Library" uses material from a header file
|
||||
that is part of the Library, the object code for the work may be a
|
||||
derivative work of the Library even though the source code is not.
|
||||
Whether this is true is especially significant if the work can be
|
||||
linked without the Library, or if the work is itself a library. The
|
||||
threshold for this to be true is not precisely defined by law.
|
||||
|
||||
If such an object file uses only numerical parameters, data
|
||||
structure layouts and accessors, and small macros and small inline
|
||||
functions (ten lines or less in length), then the use of the object
|
||||
file is unrestricted, regardless of whether it is legally a derivative
|
||||
work. (Executables containing this object code plus portions of the
|
||||
Library will still fall under Section 6.)
|
||||
|
||||
Otherwise, if the work is a derivative of the Library, you may
|
||||
distribute the object code for the work under the terms of Section 6.
|
||||
Any executables containing that work also fall under Section 6,
|
||||
whether or not they are linked directly with the Library itself.
|
||||
|
||||
6. As an exception to the Sections above, you may also combine or
|
||||
link a "work that uses the Library" with the Library to produce a
|
||||
work containing portions of the Library, and distribute that work
|
||||
under terms of your choice, provided that the terms permit
|
||||
modification of the work for the customer's own use and reverse
|
||||
engineering for debugging such modifications.
|
||||
|
||||
You must give prominent notice with each copy of the work that the
|
||||
Library is used in it and that the Library and its use are covered by
|
||||
this License. You must supply a copy of this License. If the work
|
||||
during execution displays copyright notices, you must include the
|
||||
copyright notice for the Library among them, as well as a reference
|
||||
directing the user to the copy of this License. Also, you must do one
|
||||
of these things:
|
||||
|
||||
a) Accompany the work with the complete corresponding
|
||||
machine-readable source code for the Library including whatever
|
||||
changes were used in the work (which must be distributed under
|
||||
Sections 1 and 2 above); and, if the work is an executable linked
|
||||
with the Library, with the complete machine-readable "work that
|
||||
uses the Library", as object code and/or source code, so that the
|
||||
user can modify the Library and then relink to produce a modified
|
||||
executable containing the modified Library. (It is understood
|
||||
that the user who changes the contents of definitions files in the
|
||||
Library will not necessarily be able to recompile the application
|
||||
to use the modified definitions.)
|
||||
|
||||
b) Use a suitable shared library mechanism for linking with the
|
||||
Library. A suitable mechanism is one that (1) uses at run time a
|
||||
copy of the library already present on the user's computer system,
|
||||
rather than copying library functions into the executable, and (2)
|
||||
will operate properly with a modified version of the library, if
|
||||
the user installs one, as long as the modified version is
|
||||
interface-compatible with the version that the work was made with.
|
||||
|
||||
c) Accompany the work with a written offer, valid for at
|
||||
least three years, to give the same user the materials
|
||||
specified in Subsection 6a, above, for a charge no more
|
||||
than the cost of performing this distribution.
|
||||
|
||||
d) If distribution of the work is made by offering access to copy
|
||||
from a designated place, offer equivalent access to copy the above
|
||||
specified materials from the same place.
|
||||
|
||||
e) Verify that the user has already received a copy of these
|
||||
materials or that you have already sent this user a copy.
|
||||
|
||||
For an executable, the required form of the "work that uses the
|
||||
Library" must include any data and utility programs needed for
|
||||
reproducing the executable from it. However, as a special exception,
|
||||
the materials to be distributed need not include anything that is
|
||||
normally distributed (in either source or binary form) with the major
|
||||
components (compiler, kernel, and so on) of the operating system on
|
||||
which the executable runs, unless that component itself accompanies
|
||||
the executable.
|
||||
|
||||
It may happen that this requirement contradicts the license
|
||||
restrictions of other proprietary libraries that do not normally
|
||||
accompany the operating system. Such a contradiction means you cannot
|
||||
use both them and the Library together in an executable that you
|
||||
distribute.
|
||||
|
||||
7. You may place library facilities that are a work based on the
|
||||
Library side-by-side in a single library together with other library
|
||||
facilities not covered by this License, and distribute such a combined
|
||||
library, provided that the separate distribution of the work based on
|
||||
the Library and of the other library facilities is otherwise
|
||||
permitted, and provided that you do these two things:
|
||||
|
||||
a) Accompany the combined library with a copy of the same work
|
||||
based on the Library, uncombined with any other library
|
||||
facilities. This must be distributed under the terms of the
|
||||
Sections above.
|
||||
|
||||
b) Give prominent notice with the combined library of the fact
|
||||
that part of it is a work based on the Library, and explaining
|
||||
where to find the accompanying uncombined form of the same work.
|
||||
|
||||
8. You may not copy, modify, sublicense, link with, or distribute
|
||||
the Library except as expressly provided under this License. Any
|
||||
attempt otherwise to copy, modify, sublicense, link with, or
|
||||
distribute the Library is void, and will automatically terminate your
|
||||
rights under this License. However, parties who have received copies,
|
||||
or rights, from you under this License will not have their licenses
|
||||
terminated so long as such parties remain in full compliance.
|
||||
|
||||
9. You are not required to accept this License, since you have not
|
||||
signed it. However, nothing else grants you permission to modify or
|
||||
distribute the Library or its derivative works. These actions are
|
||||
prohibited by law if you do not accept this License. Therefore, by
|
||||
modifying or distributing the Library (or any work based on the
|
||||
Library), you indicate your acceptance of this License to do so, and
|
||||
all its terms and conditions for copying, distributing or modifying
|
||||
the Library or works based on it.
|
||||
|
||||
10. Each time you redistribute the Library (or any work based on the
|
||||
Library), the recipient automatically receives a license from the
|
||||
original licensor to copy, distribute, link with or modify the Library
|
||||
subject to these terms and conditions. You may not impose any further
|
||||
restrictions on the recipients' exercise of the rights granted herein.
|
||||
You are not responsible for enforcing compliance by third parties with
|
||||
this License.
|
||||
|
||||
11. If, as a consequence of a court judgment or allegation of patent
|
||||
infringement or for any other reason (not limited to patent issues),
|
||||
conditions are imposed on you (whether by court order, agreement or
|
||||
otherwise) that contradict the conditions of this License, they do not
|
||||
excuse you from the conditions of this License. If you cannot
|
||||
distribute so as to satisfy simultaneously your obligations under this
|
||||
License and any other pertinent obligations, then as a consequence you
|
||||
may not distribute the Library at all. For example, if a patent
|
||||
license would not permit royalty-free redistribution of the Library by
|
||||
all those who receive copies directly or indirectly through you, then
|
||||
the only way you could satisfy both it and this License would be to
|
||||
refrain entirely from distribution of the Library.
|
||||
|
||||
If any portion of this section is held invalid or unenforceable under any
|
||||
particular circumstance, the balance of the section is intended to apply,
|
||||
and the section as a whole is intended to apply in other circumstances.
|
||||
|
||||
It is not the purpose of this section to induce you to infringe any
|
||||
patents or other property right claims or to contest validity of any
|
||||
such claims; this section has the sole purpose of protecting the
|
||||
integrity of the free software distribution system which is
|
||||
implemented by public license practices. Many people have made
|
||||
generous contributions to the wide range of software distributed
|
||||
through that system in reliance on consistent application of that
|
||||
system; it is up to the author/donor to decide if he or she is willing
|
||||
to distribute software through any other system and a licensee cannot
|
||||
impose that choice.
|
||||
|
||||
This section is intended to make thoroughly clear what is believed to
|
||||
be a consequence of the rest of this License.
|
||||
|
||||
12. If the distribution and/or use of the Library is restricted in
|
||||
certain countries either by patents or by copyrighted interfaces, the
|
||||
original copyright holder who places the Library under this License may add
|
||||
an explicit geographical distribution limitation excluding those countries,
|
||||
so that distribution is permitted only in or among countries not thus
|
||||
excluded. In such case, this License incorporates the limitation as if
|
||||
written in the body of this License.
|
||||
|
||||
13. The Free Software Foundation may publish revised and/or new
|
||||
versions of the Lesser General Public License from time to time.
|
||||
Such new versions will be similar in spirit to the present version,
|
||||
but may differ in detail to address new problems or concerns.
|
||||
|
||||
Each version is given a distinguishing version number. If the Library
|
||||
specifies a version number of this License which applies to it and
|
||||
"any later version", you have the option of following the terms and
|
||||
conditions either of that version or of any later version published by
|
||||
the Free Software Foundation. If the Library does not specify a
|
||||
license version number, you may choose any version ever published by
|
||||
the Free Software Foundation.
|
||||
|
||||
14. If you wish to incorporate parts of the Library into other free
|
||||
programs whose distribution conditions are incompatible with these,
|
||||
write to the author to ask for permission. For software which is
|
||||
copyrighted by the Free Software Foundation, write to the Free
|
||||
Software Foundation; we sometimes make exceptions for this. Our
|
||||
decision will be guided by the two goals of preserving the free status
|
||||
of all derivatives of our free software and of promoting the sharing
|
||||
and reuse of software generally.
|
||||
|
||||
NO WARRANTY
|
||||
|
||||
15. BECAUSE THE LIBRARY IS LICENSED FREE OF CHARGE, THERE IS NO
|
||||
WARRANTY FOR THE LIBRARY, TO THE EXTENT PERMITTED BY APPLICABLE LAW.
|
||||
EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR
|
||||
OTHER PARTIES PROVIDE THE LIBRARY "AS IS" WITHOUT WARRANTY OF ANY
|
||||
KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE
|
||||
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
|
||||
PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE
|
||||
LIBRARY IS WITH YOU. SHOULD THE LIBRARY PROVE DEFECTIVE, YOU ASSUME
|
||||
THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION.
|
||||
|
||||
16. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN
|
||||
WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY
|
||||
AND/OR REDISTRIBUTE THE LIBRARY AS PERMITTED ABOVE, BE LIABLE TO YOU
|
||||
FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR
|
||||
CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE
|
||||
LIBRARY (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING
|
||||
RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A
|
||||
FAILURE OF THE LIBRARY TO OPERATE WITH ANY OTHER SOFTWARE), EVEN IF
|
||||
SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH
|
||||
DAMAGES.
|
|
@ -0,0 +1,232 @@
|
|||
Dompdf
|
||||
======
|
||||
|
||||
[](https://github.com/dompdf/dompdf/actions/workflows/test.yml)
|
||||
[](https://packagist.org/packages/dompdf/dompdf)
|
||||
[](https://packagist.org/packages/dompdf/dompdf)
|
||||
[](https://packagist.org/packages/dompdf/dompdf)
|
||||
|
||||
**Dompdf is an HTML to PDF converter**
|
||||
|
||||
At its heart, dompdf is (mostly) a [CSS 2.1](http://www.w3.org/TR/CSS2/) compliant
|
||||
HTML layout and rendering engine written in PHP. It is a style-driven renderer:
|
||||
it will download and read external stylesheets, inline style tags, and the style
|
||||
attributes of individual HTML elements. It also supports most presentational
|
||||
HTML attributes.
|
||||
|
||||
*This document applies to the latest stable code which may not reflect the current
|
||||
release. For released code please
|
||||
[navigate to the appropriate tag](https://github.com/dompdf/dompdf/tags).*
|
||||
|
||||
----
|
||||
|
||||
**Check out the [demo](http://eclecticgeek.com/dompdf/debug.php) and ask any
|
||||
question on [StackOverflow](https://stackoverflow.com/questions/tagged/dompdf) or
|
||||
in [Discussions](https://github.com/dompdf/dompdf/discussions).**
|
||||
|
||||
Follow us on [](http://www.twitter.com/dompdf).
|
||||
|
||||
---
|
||||
|
||||
|
||||
|
||||
## Features
|
||||
|
||||
* Handles most CSS 2.1 and a few CSS3 properties, including @import, @media &
|
||||
@page rules
|
||||
* Supports most presentational HTML 4.0 attributes
|
||||
* Supports external stylesheets, either local or through http/ftp (via
|
||||
fopen-wrappers)
|
||||
* Supports complex tables, including row & column spans, separate & collapsed
|
||||
border models, individual cell styling
|
||||
* Image support (gif, png (8, 24 and 32 bit with alpha channel), bmp & jpeg)
|
||||
* No dependencies on external PDF libraries, thanks to the R&OS PDF class
|
||||
* Inline PHP support
|
||||
* Basic SVG support (see "Limitations" below)
|
||||
|
||||
## Requirements
|
||||
|
||||
* PHP version 7.1 or higher
|
||||
* DOM extension
|
||||
* MBString extension
|
||||
* php-font-lib
|
||||
* php-svg-lib
|
||||
|
||||
Note that some required dependencies may have further dependencies
|
||||
(notably php-svg-lib requires sabberworm/php-css-parser).
|
||||
|
||||
### Recommendations
|
||||
|
||||
* OPcache (OPcache, XCache, APC, etc.): improves performance
|
||||
* GD (for image processing)
|
||||
* IMagick or GMagick extension: improves image processing performance
|
||||
|
||||
Visit the wiki for more information:
|
||||
https://github.com/dompdf/dompdf/wiki/Requirements
|
||||
|
||||
## About Fonts & Character Encoding
|
||||
|
||||
PDF documents internally support the following fonts: Helvetica, Times-Roman,
|
||||
Courier, Zapf-Dingbats, & Symbol. These fonts only support Windows ANSI
|
||||
encoding. In order for a PDF to display characters that are not available in
|
||||
Windows ANSI, you must supply an external font. Dompdf will embed any referenced
|
||||
font in the PDF so long as it has been pre-loaded or is accessible to dompdf and
|
||||
reference in CSS @font-face rules. See the
|
||||
[font overview](https://github.com/dompdf/dompdf/wiki/About-Fonts-and-Character-Encoding)
|
||||
for more information on how to use fonts.
|
||||
|
||||
The [DejaVu TrueType fonts](https://dejavu-fonts.github.io/) have been pre-installed
|
||||
to give dompdf decent Unicode character coverage by default. To use the DejaVu
|
||||
fonts reference the font in your stylesheet, e.g. `body { font-family: DejaVu
|
||||
Sans; }` (for DejaVu Sans). The following DejaVu 2.34 fonts are available:
|
||||
DejaVu Sans, DejaVu Serif, and DejaVu Sans Mono.
|
||||
|
||||
## Easy Installation
|
||||
|
||||
### Install with composer
|
||||
|
||||
To install with [Composer](https://getcomposer.org/), simply require the
|
||||
latest version of this package.
|
||||
|
||||
```bash
|
||||
composer require dompdf/dompdf
|
||||
```
|
||||
|
||||
Make sure that the autoload file from Composer is loaded.
|
||||
|
||||
```php
|
||||
// somewhere early in your project's loading, require the Composer autoloader
|
||||
// see: http://getcomposer.org/doc/00-intro.md
|
||||
require 'vendor/autoload.php';
|
||||
|
||||
```
|
||||
|
||||
### Download and install
|
||||
|
||||
Download a packaged archive of dompdf and extract it into the
|
||||
directory where dompdf will reside
|
||||
|
||||
* You can download stable copies of dompdf from
|
||||
https://github.com/dompdf/dompdf/releases
|
||||
* Or download a nightly (the latest, unreleased code) from
|
||||
http://eclecticgeek.com/dompdf
|
||||
|
||||
Use the packaged release autoloader to load dompdf, libraries,
|
||||
and helper functions in your PHP:
|
||||
|
||||
```php
|
||||
// include autoloader
|
||||
require_once 'dompdf/autoload.inc.php';
|
||||
```
|
||||
|
||||
Note: packaged releases are named according using semantic
|
||||
versioning (_dompdf_MAJOR-MINOR-PATCH.zip_). So the 1.0.0
|
||||
release would be dompdf_1-0-0.zip. This is the only download
|
||||
that includes the autoloader for Dompdf and all its dependencies.
|
||||
|
||||
### Install with git
|
||||
|
||||
From the command line, switch to the directory where dompdf will
|
||||
reside and run the following commands:
|
||||
|
||||
```sh
|
||||
git clone https://github.com/dompdf/dompdf.git
|
||||
cd dompdf/lib
|
||||
|
||||
git clone https://github.com/PhenX/php-font-lib.git php-font-lib
|
||||
cd php-font-lib
|
||||
git checkout 0.5.1
|
||||
cd ..
|
||||
|
||||
git clone https://github.com/PhenX/php-svg-lib.git php-svg-lib
|
||||
cd php-svg-lib
|
||||
git checkout v0.3.2
|
||||
cd ..
|
||||
|
||||
git clone https://github.com/sabberworm/PHP-CSS-Parser.git php-css-parser
|
||||
cd php-css-parser
|
||||
git checkout 8.1.0
|
||||
```
|
||||
|
||||
Require dompdf and it's dependencies in your PHP.
|
||||
For details see the [autoloader in the utils project](https://github.com/dompdf/utils/blob/master/autoload.inc.php).
|
||||
|
||||
## Quick Start
|
||||
|
||||
Just pass your HTML in to dompdf and stream the output:
|
||||
|
||||
```php
|
||||
// reference the Dompdf namespace
|
||||
use Dompdf\Dompdf;
|
||||
|
||||
// instantiate and use the dompdf class
|
||||
$dompdf = new Dompdf();
|
||||
$dompdf->loadHtml('hello world');
|
||||
|
||||
// (Optional) Setup the paper size and orientation
|
||||
$dompdf->setPaper('A4', 'landscape');
|
||||
|
||||
// Render the HTML as PDF
|
||||
$dompdf->render();
|
||||
|
||||
// Output the generated PDF to Browser
|
||||
$dompdf->stream();
|
||||
```
|
||||
|
||||
### Setting Options
|
||||
|
||||
Set options during dompdf instantiation:
|
||||
|
||||
```php
|
||||
use Dompdf\Dompdf;
|
||||
use Dompdf\Options;
|
||||
|
||||
$options = new Options();
|
||||
$options->set('defaultFont', 'Courier');
|
||||
$dompdf = new Dompdf($options);
|
||||
```
|
||||
|
||||
or at run time
|
||||
|
||||
```php
|
||||
use Dompdf\Dompdf;
|
||||
|
||||
$dompdf = new Dompdf();
|
||||
$options = $dompdf->getOptions();
|
||||
$options->setDefaultFont('Courier');
|
||||
$dompdf->setOptions($options);
|
||||
```
|
||||
|
||||
See [Dompdf\Options](src/Options.php) for a list of available options.
|
||||
|
||||
### Resource Reference Requirements
|
||||
|
||||
In order to protect potentially sensitive information Dompdf imposes
|
||||
restrictions on files referenced from the local file system or the web.
|
||||
|
||||
Files accessed through web-based protocols have the following requirements:
|
||||
* The Dompdf option "isRemoteEnabled" must be set to "true"
|
||||
* PHP must either have the curl extension enabled or the
|
||||
allow_url_fopen setting set to true
|
||||
|
||||
Files accessed through the local file system have the following requirement:
|
||||
* The file must fall within the path(s) specified for the Dompdf "chroot" option
|
||||
|
||||
## Limitations (Known Issues)
|
||||
|
||||
* Table cells are not pageable, meaning a table row must fit on a single page.
|
||||
* Elements are rendered on the active page when they are parsed.
|
||||
* Embedding "raw" SVG's (`<svg><path...></svg>`) isn't working yet, you need to
|
||||
either link to an external SVG file, or use a DataURI like this:
|
||||
```php
|
||||
$html = '<img src="data:image/svg+xml;base64,' . base64_encode($svg) . '" ...>';
|
||||
```
|
||||
Watch https://github.com/dompdf/dompdf/issues/320 for progress
|
||||
* Does not support CSS flexbox.
|
||||
* Does not support CSS Grid.
|
||||
---
|
||||
|
||||
[](http://goo.gl/DSvWf)
|
||||
|
||||
*If you find this project useful, please consider making a donation.
|
||||
Any funds donated will be used to help further development on this project.)*
|
|
@ -0,0 +1 @@
|
|||
2.0.4
|
|
@ -0,0 +1,47 @@
|
|||
{
|
||||
"name": "dompdf/dompdf",
|
||||
"type": "library",
|
||||
"description": "DOMPDF is a CSS 2.1 compliant HTML to PDF converter",
|
||||
"homepage": "https://github.com/dompdf/dompdf",
|
||||
"license": "LGPL-2.1",
|
||||
"authors": [
|
||||
{
|
||||
"name": "The Dompdf Community",
|
||||
"homepage": "https://github.com/dompdf/dompdf/blob/master/AUTHORS.md"
|
||||
}
|
||||
],
|
||||
"autoload": {
|
||||
"psr-4": {
|
||||
"Dompdf\\": "src/"
|
||||
},
|
||||
"classmap": [
|
||||
"lib/"
|
||||
]
|
||||
},
|
||||
"autoload-dev": {
|
||||
"psr-4": {
|
||||
"Dompdf\\Tests\\": "tests/"
|
||||
}
|
||||
},
|
||||
"require": {
|
||||
"php": "^7.1 || ^8.0",
|
||||
"ext-dom": "*",
|
||||
"ext-mbstring": "*",
|
||||
"masterminds/html5": "^2.0",
|
||||
"phenx/php-font-lib": ">=0.5.4 <1.0.0",
|
||||
"phenx/php-svg-lib": ">=0.3.3 <1.0.0"
|
||||
},
|
||||
"require-dev": {
|
||||
"ext-json": "*",
|
||||
"ext-zip": "*",
|
||||
"phpunit/phpunit": "^7.5 || ^8 || ^9",
|
||||
"squizlabs/php_codesniffer": "^3.5",
|
||||
"mockery/mockery": "^1.3"
|
||||
},
|
||||
"suggest": {
|
||||
"ext-gd": "Needed to process images",
|
||||
"ext-imagick": "Improves image processing performance",
|
||||
"ext-gmagick": "Improves image processing performance",
|
||||
"ext-zlib": "Needed for pdf stream compression"
|
||||
}
|
||||
}
|
File diff suppressed because it is too large
Load Diff
|
@ -0,0 +1,344 @@
|
|||
StartFontMetrics 4.1
|
||||
Comment Copyright (c) 1989, 1990, 1991, 1993, 1997 Adobe Systems Incorporated. All Rights Reserved.
|
||||
Comment Creation Date: Mon Jun 23 16:28:00 0:00:00
|
||||
Comment UniqueID 43048
|
||||
Comment VMusage 41139 52164
|
||||
FontName Courier-Bold
|
||||
FullName Courier Bold
|
||||
FamilyName Courier
|
||||
Weight Bold
|
||||
ItalicAngle 0
|
||||
IsFixedPitch true
|
||||
CharacterSet ExtendedRoman
|
||||
FontBBox -113 -250 749 801
|
||||
UnderlinePosition -100
|
||||
UnderlineThickness 50
|
||||
Version 003.000
|
||||
Notice Copyright (c) 1989, 1990, 1991, 1993, 1997 Adobe Systems Incorporated. All Rights Reserved.
|
||||
EncodingScheme WinAnsiEncoding
|
||||
CapHeight 562
|
||||
XHeight 439
|
||||
Ascender 629
|
||||
Descender -157
|
||||
StdHW 84
|
||||
StdVW 106
|
||||
StartCharMetrics 317
|
||||
C 32 ; WX 600 ; N space ; B 0 0 0 0 ;
|
||||
C 160 ; WX 600 ; N space ; B 0 0 0 0 ;
|
||||
C 33 ; WX 600 ; N exclam ; B 202 -15 398 572 ;
|
||||
C 34 ; WX 600 ; N quotedbl ; B 135 277 465 562 ;
|
||||
C 35 ; WX 600 ; N numbersign ; B 56 -45 544 651 ;
|
||||
C 36 ; WX 600 ; N dollar ; B 82 -126 519 666 ;
|
||||
C 37 ; WX 600 ; N percent ; B 5 -15 595 616 ;
|
||||
C 38 ; WX 600 ; N ampersand ; B 36 -15 546 543 ;
|
||||
C 146 ; WX 600 ; N quoteright ; B 171 277 423 562 ;
|
||||
C 40 ; WX 600 ; N parenleft ; B 219 -102 461 616 ;
|
||||
C 41 ; WX 600 ; N parenright ; B 139 -102 381 616 ;
|
||||
C 42 ; WX 600 ; N asterisk ; B 91 219 509 601 ;
|
||||
C 43 ; WX 600 ; N plus ; B 71 39 529 478 ;
|
||||
C 44 ; WX 600 ; N comma ; B 123 -111 393 174 ;
|
||||
C 45 ; WX 600 ; N hyphen ; B 100 203 500 313 ;
|
||||
C 173 ; WX 600 ; N hyphen ; B 100 203 500 313 ;
|
||||
C 46 ; WX 600 ; N period ; B 192 -15 408 171 ;
|
||||
C 47 ; WX 600 ; N slash ; B 98 -77 502 626 ;
|
||||
C 48 ; WX 600 ; N zero ; B 87 -15 513 616 ;
|
||||
C 49 ; WX 600 ; N one ; B 81 0 539 616 ;
|
||||
C 50 ; WX 600 ; N two ; B 61 0 499 616 ;
|
||||
C 51 ; WX 600 ; N three ; B 63 -15 501 616 ;
|
||||
C 52 ; WX 600 ; N four ; B 53 0 507 616 ;
|
||||
C 53 ; WX 600 ; N five ; B 70 -15 521 601 ;
|
||||
C 54 ; WX 600 ; N six ; B 90 -15 521 616 ;
|
||||
C 55 ; WX 600 ; N seven ; B 55 0 494 601 ;
|
||||
C 56 ; WX 600 ; N eight ; B 83 -15 517 616 ;
|
||||
C 57 ; WX 600 ; N nine ; B 79 -15 510 616 ;
|
||||
C 58 ; WX 600 ; N colon ; B 191 -15 407 425 ;
|
||||
C 59 ; WX 600 ; N semicolon ; B 123 -111 408 425 ;
|
||||
C 60 ; WX 600 ; N less ; B 66 15 523 501 ;
|
||||
C 61 ; WX 600 ; N equal ; B 71 118 529 398 ;
|
||||
C 62 ; WX 600 ; N greater ; B 77 15 534 501 ;
|
||||
C 63 ; WX 600 ; N question ; B 98 -14 501 580 ;
|
||||
C 64 ; WX 600 ; N at ; B 16 -15 584 616 ;
|
||||
C 65 ; WX 600 ; N A ; B -9 0 609 562 ;
|
||||
C 66 ; WX 600 ; N B ; B 30 0 573 562 ;
|
||||
C 67 ; WX 600 ; N C ; B 22 -18 560 580 ;
|
||||
C 68 ; WX 600 ; N D ; B 30 0 594 562 ;
|
||||
C 69 ; WX 600 ; N E ; B 25 0 560 562 ;
|
||||
C 70 ; WX 600 ; N F ; B 39 0 570 562 ;
|
||||
C 71 ; WX 600 ; N G ; B 22 -18 594 580 ;
|
||||
C 72 ; WX 600 ; N H ; B 20 0 580 562 ;
|
||||
C 73 ; WX 600 ; N I ; B 77 0 523 562 ;
|
||||
C 74 ; WX 600 ; N J ; B 37 -18 601 562 ;
|
||||
C 75 ; WX 600 ; N K ; B 21 0 599 562 ;
|
||||
C 76 ; WX 600 ; N L ; B 39 0 578 562 ;
|
||||
C 77 ; WX 600 ; N M ; B -2 0 602 562 ;
|
||||
C 78 ; WX 600 ; N N ; B 8 -12 610 562 ;
|
||||
C 79 ; WX 600 ; N O ; B 22 -18 578 580 ;
|
||||
C 80 ; WX 600 ; N P ; B 48 0 559 562 ;
|
||||
C 81 ; WX 600 ; N Q ; B 32 -138 578 580 ;
|
||||
C 82 ; WX 600 ; N R ; B 24 0 599 562 ;
|
||||
C 83 ; WX 600 ; N S ; B 47 -22 553 582 ;
|
||||
C 84 ; WX 600 ; N T ; B 21 0 579 562 ;
|
||||
C 85 ; WX 600 ; N U ; B 4 -18 596 562 ;
|
||||
C 86 ; WX 600 ; N V ; B -13 0 613 562 ;
|
||||
C 87 ; WX 600 ; N W ; B -18 0 618 562 ;
|
||||
C 88 ; WX 600 ; N X ; B 12 0 588 562 ;
|
||||
C 89 ; WX 600 ; N Y ; B 12 0 589 562 ;
|
||||
C 90 ; WX 600 ; N Z ; B 62 0 539 562 ;
|
||||
C 91 ; WX 600 ; N bracketleft ; B 245 -102 475 616 ;
|
||||
C 92 ; WX 600 ; N backslash ; B 99 -77 503 626 ;
|
||||
C 93 ; WX 600 ; N bracketright ; B 125 -102 355 616 ;
|
||||
C 94 ; WX 600 ; N asciicircum ; B 108 250 492 616 ;
|
||||
C 95 ; WX 600 ; N underscore ; B 0 -125 600 -75 ;
|
||||
C 145 ; WX 600 ; N quoteleft ; B 178 277 428 562 ;
|
||||
C 97 ; WX 600 ; N a ; B 35 -15 570 454 ;
|
||||
C 98 ; WX 600 ; N b ; B 0 -15 584 626 ;
|
||||
C 99 ; WX 600 ; N c ; B 40 -15 545 459 ;
|
||||
C 100 ; WX 600 ; N d ; B 20 -15 591 626 ;
|
||||
C 101 ; WX 600 ; N e ; B 40 -15 563 454 ;
|
||||
C 102 ; WX 600 ; N f ; B 83 0 547 626 ; L i fi ; L l fl ;
|
||||
C 103 ; WX 600 ; N g ; B 30 -146 580 454 ;
|
||||
C 104 ; WX 600 ; N h ; B 5 0 592 626 ;
|
||||
C 105 ; WX 600 ; N i ; B 77 0 523 658 ;
|
||||
C 106 ; WX 600 ; N j ; B 63 -146 440 658 ;
|
||||
C 107 ; WX 600 ; N k ; B 20 0 585 626 ;
|
||||
C 108 ; WX 600 ; N l ; B 77 0 523 626 ;
|
||||
C 109 ; WX 600 ; N m ; B -22 0 626 454 ;
|
||||
C 110 ; WX 600 ; N n ; B 18 0 592 454 ;
|
||||
C 111 ; WX 600 ; N o ; B 30 -15 570 454 ;
|
||||
C 112 ; WX 600 ; N p ; B -1 -142 570 454 ;
|
||||
C 113 ; WX 600 ; N q ; B 20 -142 591 454 ;
|
||||
C 114 ; WX 600 ; N r ; B 47 0 580 454 ;
|
||||
C 115 ; WX 600 ; N s ; B 68 -17 535 459 ;
|
||||
C 116 ; WX 600 ; N t ; B 47 -15 532 562 ;
|
||||
C 117 ; WX 600 ; N u ; B -1 -15 569 439 ;
|
||||
C 118 ; WX 600 ; N v ; B -1 0 601 439 ;
|
||||
C 119 ; WX 600 ; N w ; B -18 0 618 439 ;
|
||||
C 120 ; WX 600 ; N x ; B 6 0 594 439 ;
|
||||
C 121 ; WX 600 ; N y ; B -4 -142 601 439 ;
|
||||
C 122 ; WX 600 ; N z ; B 81 0 520 439 ;
|
||||
C 123 ; WX 600 ; N braceleft ; B 160 -102 464 616 ;
|
||||
C 124 ; WX 600 ; N bar ; B 255 -250 345 750 ;
|
||||
C 125 ; WX 600 ; N braceright ; B 136 -102 440 616 ;
|
||||
C 126 ; WX 600 ; N asciitilde ; B 71 153 530 356 ;
|
||||
C 161 ; WX 600 ; N exclamdown ; B 202 -146 398 449 ;
|
||||
C 162 ; WX 600 ; N cent ; B 66 -49 518 614 ;
|
||||
C 163 ; WX 600 ; N sterling ; B 72 -28 558 611 ;
|
||||
C -1 ; WX 600 ; N fraction ; B 25 -60 576 661 ;
|
||||
C 165 ; WX 600 ; N yen ; B 10 0 590 562 ;
|
||||
C 131 ; WX 600 ; N florin ; B -30 -131 572 616 ;
|
||||
C 167 ; WX 600 ; N section ; B 83 -70 517 580 ;
|
||||
C 164 ; WX 600 ; N currency ; B 54 49 546 517 ;
|
||||
C 39 ; WX 600 ; N quotesingle ; B 227 277 373 562 ;
|
||||
C 147 ; WX 600 ; N quotedblleft ; B 71 277 535 562 ;
|
||||
C 171 ; WX 600 ; N guillemotleft ; B 8 70 553 446 ;
|
||||
C 139 ; WX 600 ; N guilsinglleft ; B 141 70 459 446 ;
|
||||
C 155 ; WX 600 ; N guilsinglright ; B 141 70 459 446 ;
|
||||
C -1 ; WX 600 ; N fi ; B 12 0 593 626 ;
|
||||
C -1 ; WX 600 ; N fl ; B 12 0 593 626 ;
|
||||
C 150 ; WX 600 ; N endash ; B 65 203 535 313 ;
|
||||
C 134 ; WX 600 ; N dagger ; B 106 -70 494 580 ;
|
||||
C 135 ; WX 600 ; N daggerdbl ; B 106 -70 494 580 ;
|
||||
C 183 ; WX 600 ; N periodcentered ; B 196 165 404 351 ;
|
||||
C 182 ; WX 600 ; N paragraph ; B 6 -70 576 580 ;
|
||||
C 149 ; WX 600 ; N bullet ; B 140 132 460 430 ;
|
||||
C 130 ; WX 600 ; N quotesinglbase ; B 175 -142 427 143 ;
|
||||
C 132 ; WX 600 ; N quotedblbase ; B 65 -142 529 143 ;
|
||||
C 148 ; WX 600 ; N quotedblright ; B 61 277 525 562 ;
|
||||
C 187 ; WX 600 ; N guillemotright ; B 47 70 592 446 ;
|
||||
C 133 ; WX 600 ; N ellipsis ; B 26 -15 574 116 ;
|
||||
C 137 ; WX 600 ; N perthousand ; B -113 -15 713 616 ;
|
||||
C 191 ; WX 600 ; N questiondown ; B 99 -146 502 449 ;
|
||||
C 96 ; WX 600 ; N grave ; B 132 508 395 661 ;
|
||||
C 180 ; WX 600 ; N acute ; B 205 508 468 661 ;
|
||||
C 136 ; WX 600 ; N circumflex ; B 103 483 497 657 ;
|
||||
C 152 ; WX 600 ; N tilde ; B 89 493 512 636 ;
|
||||
C 175 ; WX 600 ; N macron ; B 88 505 512 585 ;
|
||||
C -1 ; WX 600 ; N breve ; B 83 468 517 631 ;
|
||||
C -1 ; WX 600 ; N dotaccent ; B 230 498 370 638 ;
|
||||
C 168 ; WX 600 ; N dieresis ; B 128 498 472 638 ;
|
||||
C -1 ; WX 600 ; N ring ; B 198 481 402 678 ;
|
||||
C 184 ; WX 600 ; N cedilla ; B 205 -206 387 0 ;
|
||||
C -1 ; WX 600 ; N hungarumlaut ; B 68 488 588 661 ;
|
||||
C -1 ; WX 600 ; N ogonek ; B 169 -199 400 0 ;
|
||||
C -1 ; WX 600 ; N caron ; B 103 493 497 667 ;
|
||||
C 151 ; WX 600 ; N emdash ; B -10 203 610 313 ;
|
||||
C 198 ; WX 600 ; N AE ; B -29 0 602 562 ;
|
||||
C 170 ; WX 600 ; N ordfeminine ; B 147 196 453 580 ;
|
||||
C -1 ; WX 600 ; N Lslash ; B 39 0 578 562 ;
|
||||
C 216 ; WX 600 ; N Oslash ; B 22 -22 578 584 ;
|
||||
C 140 ; WX 600 ; N OE ; B -25 0 595 562 ;
|
||||
C 186 ; WX 600 ; N ordmasculine ; B 147 196 453 580 ;
|
||||
C 230 ; WX 600 ; N ae ; B -4 -15 601 454 ;
|
||||
C -1 ; WX 600 ; N dotlessi ; B 77 0 523 439 ;
|
||||
C -1 ; WX 600 ; N lslash ; B 77 0 523 626 ;
|
||||
C 248 ; WX 600 ; N oslash ; B 30 -24 570 463 ;
|
||||
C 156 ; WX 600 ; N oe ; B -18 -15 611 454 ;
|
||||
C 223 ; WX 600 ; N germandbls ; B 22 -15 596 626 ;
|
||||
C 207 ; WX 600 ; N Idieresis ; B 77 0 523 761 ;
|
||||
C 233 ; WX 600 ; N eacute ; B 40 -15 563 661 ;
|
||||
C -1 ; WX 600 ; N abreve ; B 35 -15 570 661 ;
|
||||
C -1 ; WX 600 ; N uhungarumlaut ; B -1 -15 628 661 ;
|
||||
C -1 ; WX 600 ; N ecaron ; B 40 -15 563 667 ;
|
||||
C 159 ; WX 600 ; N Ydieresis ; B 12 0 589 761 ;
|
||||
C 247 ; WX 600 ; N divide ; B 71 16 529 500 ;
|
||||
C 221 ; WX 600 ; N Yacute ; B 12 0 589 784 ;
|
||||
C 194 ; WX 600 ; N Acircumflex ; B -9 0 609 780 ;
|
||||
C 225 ; WX 600 ; N aacute ; B 35 -15 570 661 ;
|
||||
C 219 ; WX 600 ; N Ucircumflex ; B 4 -18 596 780 ;
|
||||
C 253 ; WX 600 ; N yacute ; B -4 -142 601 661 ;
|
||||
C -1 ; WX 600 ; N scommaaccent ; B 68 -250 535 459 ;
|
||||
C 234 ; WX 600 ; N ecircumflex ; B 40 -15 563 657 ;
|
||||
C -1 ; WX 600 ; N Uring ; B 4 -18 596 801 ;
|
||||
C 220 ; WX 600 ; N Udieresis ; B 4 -18 596 761 ;
|
||||
C -1 ; WX 600 ; N aogonek ; B 35 -199 586 454 ;
|
||||
C 218 ; WX 600 ; N Uacute ; B 4 -18 596 784 ;
|
||||
C -1 ; WX 600 ; N uogonek ; B -1 -199 585 439 ;
|
||||
C 203 ; WX 600 ; N Edieresis ; B 25 0 560 761 ;
|
||||
C -1 ; WX 600 ; N Dcroat ; B 30 0 594 562 ;
|
||||
C -1 ; WX 600 ; N commaaccent ; B 205 -250 397 -57 ;
|
||||
C 169 ; WX 600 ; N copyright ; B 0 -18 600 580 ;
|
||||
C -1 ; WX 600 ; N Emacron ; B 25 0 560 708 ;
|
||||
C -1 ; WX 600 ; N ccaron ; B 40 -15 545 667 ;
|
||||
C 229 ; WX 600 ; N aring ; B 35 -15 570 678 ;
|
||||
C -1 ; WX 600 ; N Ncommaaccent ; B 8 -250 610 562 ;
|
||||
C -1 ; WX 600 ; N lacute ; B 77 0 523 801 ;
|
||||
C 224 ; WX 600 ; N agrave ; B 35 -15 570 661 ;
|
||||
C -1 ; WX 600 ; N Tcommaaccent ; B 21 -250 579 562 ;
|
||||
C -1 ; WX 600 ; N Cacute ; B 22 -18 560 784 ;
|
||||
C 227 ; WX 600 ; N atilde ; B 35 -15 570 636 ;
|
||||
C -1 ; WX 600 ; N Edotaccent ; B 25 0 560 761 ;
|
||||
C 154 ; WX 600 ; N scaron ; B 68 -17 535 667 ;
|
||||
C -1 ; WX 600 ; N scedilla ; B 68 -206 535 459 ;
|
||||
C 237 ; WX 600 ; N iacute ; B 77 0 523 661 ;
|
||||
C -1 ; WX 600 ; N lozenge ; B 66 0 534 740 ;
|
||||
C -1 ; WX 600 ; N Rcaron ; B 24 0 599 790 ;
|
||||
C -1 ; WX 600 ; N Gcommaaccent ; B 22 -250 594 580 ;
|
||||
C 251 ; WX 600 ; N ucircumflex ; B -1 -15 569 657 ;
|
||||
C 226 ; WX 600 ; N acircumflex ; B 35 -15 570 657 ;
|
||||
C -1 ; WX 600 ; N Amacron ; B -9 0 609 708 ;
|
||||
C -1 ; WX 600 ; N rcaron ; B 47 0 580 667 ;
|
||||
C 231 ; WX 600 ; N ccedilla ; B 40 -206 545 459 ;
|
||||
C -1 ; WX 600 ; N Zdotaccent ; B 62 0 539 761 ;
|
||||
C 222 ; WX 600 ; N Thorn ; B 48 0 557 562 ;
|
||||
C -1 ; WX 600 ; N Omacron ; B 22 -18 578 708 ;
|
||||
C -1 ; WX 600 ; N Racute ; B 24 0 599 784 ;
|
||||
C -1 ; WX 600 ; N Sacute ; B 47 -22 553 784 ;
|
||||
C -1 ; WX 600 ; N dcaron ; B 20 -15 727 626 ;
|
||||
C -1 ; WX 600 ; N Umacron ; B 4 -18 596 708 ;
|
||||
C -1 ; WX 600 ; N uring ; B -1 -15 569 678 ;
|
||||
C 179 ; WX 600 ; N threesuperior ; B 138 222 433 616 ;
|
||||
C 210 ; WX 600 ; N Ograve ; B 22 -18 578 784 ;
|
||||
C 192 ; WX 600 ; N Agrave ; B -9 0 609 784 ;
|
||||
C -1 ; WX 600 ; N Abreve ; B -9 0 609 784 ;
|
||||
C 215 ; WX 600 ; N multiply ; B 81 39 520 478 ;
|
||||
C 250 ; WX 600 ; N uacute ; B -1 -15 569 661 ;
|
||||
C -1 ; WX 600 ; N Tcaron ; B 21 0 579 790 ;
|
||||
C -1 ; WX 600 ; N partialdiff ; B 63 -38 537 728 ;
|
||||
C 255 ; WX 600 ; N ydieresis ; B -4 -142 601 638 ;
|
||||
C -1 ; WX 600 ; N Nacute ; B 8 -12 610 784 ;
|
||||
C 238 ; WX 600 ; N icircumflex ; B 73 0 523 657 ;
|
||||
C 202 ; WX 600 ; N Ecircumflex ; B 25 0 560 780 ;
|
||||
C 228 ; WX 600 ; N adieresis ; B 35 -15 570 638 ;
|
||||
C 235 ; WX 600 ; N edieresis ; B 40 -15 563 638 ;
|
||||
C -1 ; WX 600 ; N cacute ; B 40 -15 545 661 ;
|
||||
C -1 ; WX 600 ; N nacute ; B 18 0 592 661 ;
|
||||
C -1 ; WX 600 ; N umacron ; B -1 -15 569 585 ;
|
||||
C -1 ; WX 600 ; N Ncaron ; B 8 -12 610 790 ;
|
||||
C 205 ; WX 600 ; N Iacute ; B 77 0 523 784 ;
|
||||
C 177 ; WX 600 ; N plusminus ; B 71 24 529 515 ;
|
||||
C 166 ; WX 600 ; N brokenbar ; B 255 -175 345 675 ;
|
||||
C 174 ; WX 600 ; N registered ; B 0 -18 600 580 ;
|
||||
C -1 ; WX 600 ; N Gbreve ; B 22 -18 594 784 ;
|
||||
C -1 ; WX 600 ; N Idotaccent ; B 77 0 523 761 ;
|
||||
C -1 ; WX 600 ; N summation ; B 15 -10 586 706 ;
|
||||
C 200 ; WX 600 ; N Egrave ; B 25 0 560 784 ;
|
||||
C -1 ; WX 600 ; N racute ; B 47 0 580 661 ;
|
||||
C -1 ; WX 600 ; N omacron ; B 30 -15 570 585 ;
|
||||
C -1 ; WX 600 ; N Zacute ; B 62 0 539 784 ;
|
||||
C 142 ; WX 600 ; N Zcaron ; B 62 0 539 790 ;
|
||||
C -1 ; WX 600 ; N greaterequal ; B 26 0 523 696 ;
|
||||
C 208 ; WX 600 ; N Eth ; B 30 0 594 562 ;
|
||||
C 199 ; WX 600 ; N Ccedilla ; B 22 -206 560 580 ;
|
||||
C -1 ; WX 600 ; N lcommaaccent ; B 77 -250 523 626 ;
|
||||
C -1 ; WX 600 ; N tcaron ; B 47 -15 532 703 ;
|
||||
C -1 ; WX 600 ; N eogonek ; B 40 -199 563 454 ;
|
||||
C -1 ; WX 600 ; N Uogonek ; B 4 -199 596 562 ;
|
||||
C 193 ; WX 600 ; N Aacute ; B -9 0 609 784 ;
|
||||
C 196 ; WX 600 ; N Adieresis ; B -9 0 609 761 ;
|
||||
C 232 ; WX 600 ; N egrave ; B 40 -15 563 661 ;
|
||||
C -1 ; WX 600 ; N zacute ; B 81 0 520 661 ;
|
||||
C -1 ; WX 600 ; N iogonek ; B 77 -199 523 658 ;
|
||||
C 211 ; WX 600 ; N Oacute ; B 22 -18 578 784 ;
|
||||
C 243 ; WX 600 ; N oacute ; B 30 -15 570 661 ;
|
||||
C -1 ; WX 600 ; N amacron ; B 35 -15 570 585 ;
|
||||
C -1 ; WX 600 ; N sacute ; B 68 -17 535 661 ;
|
||||
C 239 ; WX 600 ; N idieresis ; B 77 0 523 618 ;
|
||||
C 212 ; WX 600 ; N Ocircumflex ; B 22 -18 578 780 ;
|
||||
C 217 ; WX 600 ; N Ugrave ; B 4 -18 596 784 ;
|
||||
C -1 ; WX 600 ; N Delta ; B 6 0 594 688 ;
|
||||
C 254 ; WX 600 ; N thorn ; B -14 -142 570 626 ;
|
||||
C 178 ; WX 600 ; N twosuperior ; B 143 230 436 616 ;
|
||||
C 214 ; WX 600 ; N Odieresis ; B 22 -18 578 761 ;
|
||||
C 181 ; WX 600 ; N mu ; B -1 -142 569 439 ;
|
||||
C 236 ; WX 600 ; N igrave ; B 77 0 523 661 ;
|
||||
C -1 ; WX 600 ; N ohungarumlaut ; B 30 -15 668 661 ;
|
||||
C -1 ; WX 600 ; N Eogonek ; B 25 -199 576 562 ;
|
||||
C -1 ; WX 600 ; N dcroat ; B 20 -15 591 626 ;
|
||||
C 190 ; WX 600 ; N threequarters ; B -47 -60 648 661 ;
|
||||
C -1 ; WX 600 ; N Scedilla ; B 47 -206 553 582 ;
|
||||
C -1 ; WX 600 ; N lcaron ; B 77 0 597 626 ;
|
||||
C -1 ; WX 600 ; N Kcommaaccent ; B 21 -250 599 562 ;
|
||||
C -1 ; WX 600 ; N Lacute ; B 39 0 578 784 ;
|
||||
C 153 ; WX 600 ; N trademark ; B -9 230 749 562 ;
|
||||
C -1 ; WX 600 ; N edotaccent ; B 40 -15 563 638 ;
|
||||
C 204 ; WX 600 ; N Igrave ; B 77 0 523 784 ;
|
||||
C -1 ; WX 600 ; N Imacron ; B 77 0 523 708 ;
|
||||
C -1 ; WX 600 ; N Lcaron ; B 39 0 637 562 ;
|
||||
C 189 ; WX 600 ; N onehalf ; B -47 -60 648 661 ;
|
||||
C -1 ; WX 600 ; N lessequal ; B 26 0 523 696 ;
|
||||
C 244 ; WX 600 ; N ocircumflex ; B 30 -15 570 657 ;
|
||||
C 241 ; WX 600 ; N ntilde ; B 18 0 592 636 ;
|
||||
C -1 ; WX 600 ; N Uhungarumlaut ; B 4 -18 638 784 ;
|
||||
C 201 ; WX 600 ; N Eacute ; B 25 0 560 784 ;
|
||||
C -1 ; WX 600 ; N emacron ; B 40 -15 563 585 ;
|
||||
C -1 ; WX 600 ; N gbreve ; B 30 -146 580 661 ;
|
||||
C 188 ; WX 600 ; N onequarter ; B -56 -60 656 661 ;
|
||||
C 138 ; WX 600 ; N Scaron ; B 47 -22 553 790 ;
|
||||
C -1 ; WX 600 ; N Scommaaccent ; B 47 -250 553 582 ;
|
||||
C -1 ; WX 600 ; N Ohungarumlaut ; B 22 -18 628 784 ;
|
||||
C 176 ; WX 600 ; N degree ; B 86 243 474 616 ;
|
||||
C 242 ; WX 600 ; N ograve ; B 30 -15 570 661 ;
|
||||
C -1 ; WX 600 ; N Ccaron ; B 22 -18 560 790 ;
|
||||
C 249 ; WX 600 ; N ugrave ; B -1 -15 569 661 ;
|
||||
C -1 ; WX 600 ; N radical ; B -19 -104 473 778 ;
|
||||
C -1 ; WX 600 ; N Dcaron ; B 30 0 594 790 ;
|
||||
C -1 ; WX 600 ; N rcommaaccent ; B 47 -250 580 454 ;
|
||||
C 209 ; WX 600 ; N Ntilde ; B 8 -12 610 759 ;
|
||||
C 245 ; WX 600 ; N otilde ; B 30 -15 570 636 ;
|
||||
C -1 ; WX 600 ; N Rcommaaccent ; B 24 -250 599 562 ;
|
||||
C -1 ; WX 600 ; N Lcommaaccent ; B 39 -250 578 562 ;
|
||||
C 195 ; WX 600 ; N Atilde ; B -9 0 609 759 ;
|
||||
C -1 ; WX 600 ; N Aogonek ; B -9 -199 625 562 ;
|
||||
C 197 ; WX 600 ; N Aring ; B -9 0 609 801 ;
|
||||
C 213 ; WX 600 ; N Otilde ; B 22 -18 578 759 ;
|
||||
C -1 ; WX 600 ; N zdotaccent ; B 81 0 520 638 ;
|
||||
C -1 ; WX 600 ; N Ecaron ; B 25 0 560 790 ;
|
||||
C -1 ; WX 600 ; N Iogonek ; B 77 -199 523 562 ;
|
||||
C -1 ; WX 600 ; N kcommaaccent ; B 20 -250 585 626 ;
|
||||
C -1 ; WX 600 ; N minus ; B 71 203 529 313 ;
|
||||
C 206 ; WX 600 ; N Icircumflex ; B 77 0 523 780 ;
|
||||
C -1 ; WX 600 ; N ncaron ; B 18 0 592 667 ;
|
||||
C -1 ; WX 600 ; N tcommaaccent ; B 47 -250 532 562 ;
|
||||
C 172 ; WX 600 ; N logicalnot ; B 71 103 529 413 ;
|
||||
C 246 ; WX 600 ; N odieresis ; B 30 -15 570 638 ;
|
||||
C 252 ; WX 600 ; N udieresis ; B -1 -15 569 638 ;
|
||||
C -1 ; WX 600 ; N notequal ; B 12 -47 537 563 ;
|
||||
C -1 ; WX 600 ; N gcommaaccent ; B 30 -146 580 714 ;
|
||||
C 240 ; WX 600 ; N eth ; B 58 -27 543 626 ;
|
||||
C 158 ; WX 600 ; N zcaron ; B 81 0 520 667 ;
|
||||
C -1 ; WX 600 ; N ncommaaccent ; B 18 -250 592 454 ;
|
||||
C 185 ; WX 600 ; N onesuperior ; B 153 230 447 616 ;
|
||||
C -1 ; WX 600 ; N imacron ; B 77 0 523 585 ;
|
||||
C 128 ; WX 600 ; N Euro ; B 0 0 0 0 ;
|
||||
EndCharMetrics
|
||||
EndFontMetrics
|
|
@ -0,0 +1,344 @@
|
|||
StartFontMetrics 4.1
|
||||
Comment Copyright (c) 1989, 1990, 1991, 1993, 1997 Adobe Systems Incorporated. All Rights Reserved.
|
||||
Comment Creation Date: Mon Jun 23 16:28:46 0:00:00
|
||||
Comment UniqueID 43049
|
||||
Comment VMusage 17529 79244
|
||||
FontName Courier-BoldOblique
|
||||
FullName Courier Bold Oblique
|
||||
FamilyName Courier
|
||||
Weight Bold
|
||||
ItalicAngle -12
|
||||
IsFixedPitch true
|
||||
CharacterSet ExtendedRoman
|
||||
FontBBox -57 -250 869 801
|
||||
UnderlinePosition -100
|
||||
UnderlineThickness 50
|
||||
Version 3
|
||||
Notice Copyright (c) 1989, 1990, 1991, 1993, 1997 Adobe Systems Incorporated. All Rights Reserved.
|
||||
EncodingScheme WinAnsiEncoding
|
||||
CapHeight 562
|
||||
XHeight 439
|
||||
Ascender 629
|
||||
Descender -157
|
||||
StdHW 84
|
||||
StdVW 106
|
||||
StartCharMetrics 317
|
||||
C 32 ; WX 600 ; N space ; B 0 0 0 0 ;
|
||||
C 160 ; WX 600 ; N space ; B 0 0 0 0 ;
|
||||
C 33 ; WX 600 ; N exclam ; B 215 -15 495 572 ;
|
||||
C 34 ; WX 600 ; N quotedbl ; B 211 277 585 562 ;
|
||||
C 35 ; WX 600 ; N numbersign ; B 88 -45 641 651 ;
|
||||
C 36 ; WX 600 ; N dollar ; B 87 -126 630 666 ;
|
||||
C 37 ; WX 600 ; N percent ; B 101 -15 625 616 ;
|
||||
C 38 ; WX 600 ; N ampersand ; B 61 -15 595 543 ;
|
||||
C 146 ; WX 600 ; N quoteright ; B 229 277 543 562 ;
|
||||
C 40 ; WX 600 ; N parenleft ; B 265 -102 592 616 ;
|
||||
C 41 ; WX 600 ; N parenright ; B 117 -102 444 616 ;
|
||||
C 42 ; WX 600 ; N asterisk ; B 179 219 598 601 ;
|
||||
C 43 ; WX 600 ; N plus ; B 114 39 596 478 ;
|
||||
C 44 ; WX 600 ; N comma ; B 99 -111 430 174 ;
|
||||
C 45 ; WX 600 ; N hyphen ; B 143 203 567 313 ;
|
||||
C 173 ; WX 600 ; N hyphen ; B 143 203 567 313 ;
|
||||
C 46 ; WX 600 ; N period ; B 206 -15 427 171 ;
|
||||
C 47 ; WX 600 ; N slash ; B 90 -77 626 626 ;
|
||||
C 48 ; WX 600 ; N zero ; B 135 -15 593 616 ;
|
||||
C 49 ; WX 600 ; N one ; B 93 0 562 616 ;
|
||||
C 50 ; WX 600 ; N two ; B 61 0 594 616 ;
|
||||
C 51 ; WX 600 ; N three ; B 71 -15 571 616 ;
|
||||
C 52 ; WX 600 ; N four ; B 81 0 559 616 ;
|
||||
C 53 ; WX 600 ; N five ; B 77 -15 621 601 ;
|
||||
C 54 ; WX 600 ; N six ; B 135 -15 652 616 ;
|
||||
C 55 ; WX 600 ; N seven ; B 147 0 622 601 ;
|
||||
C 56 ; WX 600 ; N eight ; B 115 -15 604 616 ;
|
||||
C 57 ; WX 600 ; N nine ; B 75 -15 592 616 ;
|
||||
C 58 ; WX 600 ; N colon ; B 205 -15 480 425 ;
|
||||
C 59 ; WX 600 ; N semicolon ; B 99 -111 481 425 ;
|
||||
C 60 ; WX 600 ; N less ; B 120 15 613 501 ;
|
||||
C 61 ; WX 600 ; N equal ; B 96 118 614 398 ;
|
||||
C 62 ; WX 600 ; N greater ; B 97 15 589 501 ;
|
||||
C 63 ; WX 600 ; N question ; B 183 -14 592 580 ;
|
||||
C 64 ; WX 600 ; N at ; B 65 -15 642 616 ;
|
||||
C 65 ; WX 600 ; N A ; B -9 0 632 562 ;
|
||||
C 66 ; WX 600 ; N B ; B 30 0 630 562 ;
|
||||
C 67 ; WX 600 ; N C ; B 74 -18 675 580 ;
|
||||
C 68 ; WX 600 ; N D ; B 30 0 664 562 ;
|
||||
C 69 ; WX 600 ; N E ; B 25 0 670 562 ;
|
||||
C 70 ; WX 600 ; N F ; B 39 0 684 562 ;
|
||||
C 71 ; WX 600 ; N G ; B 74 -18 675 580 ;
|
||||
C 72 ; WX 600 ; N H ; B 20 0 700 562 ;
|
||||
C 73 ; WX 600 ; N I ; B 77 0 643 562 ;
|
||||
C 74 ; WX 600 ; N J ; B 58 -18 721 562 ;
|
||||
C 75 ; WX 600 ; N K ; B 21 0 692 562 ;
|
||||
C 76 ; WX 600 ; N L ; B 39 0 636 562 ;
|
||||
C 77 ; WX 600 ; N M ; B -2 0 722 562 ;
|
||||
C 78 ; WX 600 ; N N ; B 8 -12 730 562 ;
|
||||
C 79 ; WX 600 ; N O ; B 74 -18 645 580 ;
|
||||
C 80 ; WX 600 ; N P ; B 48 0 643 562 ;
|
||||
C 81 ; WX 600 ; N Q ; B 83 -138 636 580 ;
|
||||
C 82 ; WX 600 ; N R ; B 24 0 617 562 ;
|
||||
C 83 ; WX 600 ; N S ; B 54 -22 673 582 ;
|
||||
C 84 ; WX 600 ; N T ; B 86 0 679 562 ;
|
||||
C 85 ; WX 600 ; N U ; B 101 -18 716 562 ;
|
||||
C 86 ; WX 600 ; N V ; B 84 0 733 562 ;
|
||||
C 87 ; WX 600 ; N W ; B 79 0 738 562 ;
|
||||
C 88 ; WX 600 ; N X ; B 12 0 690 562 ;
|
||||
C 89 ; WX 600 ; N Y ; B 109 0 709 562 ;
|
||||
C 90 ; WX 600 ; N Z ; B 62 0 637 562 ;
|
||||
C 91 ; WX 600 ; N bracketleft ; B 223 -102 606 616 ;
|
||||
C 92 ; WX 600 ; N backslash ; B 222 -77 496 626 ;
|
||||
C 93 ; WX 600 ; N bracketright ; B 103 -102 486 616 ;
|
||||
C 94 ; WX 600 ; N asciicircum ; B 171 250 556 616 ;
|
||||
C 95 ; WX 600 ; N underscore ; B -27 -125 585 -75 ;
|
||||
C 145 ; WX 600 ; N quoteleft ; B 297 277 487 562 ;
|
||||
C 97 ; WX 600 ; N a ; B 61 -15 593 454 ;
|
||||
C 98 ; WX 600 ; N b ; B 13 -15 636 626 ;
|
||||
C 99 ; WX 600 ; N c ; B 81 -15 631 459 ;
|
||||
C 100 ; WX 600 ; N d ; B 60 -15 645 626 ;
|
||||
C 101 ; WX 600 ; N e ; B 81 -15 605 454 ;
|
||||
C 102 ; WX 600 ; N f ; B 83 0 677 626 ; L i fi ; L l fl ;
|
||||
C 103 ; WX 600 ; N g ; B 40 -146 674 454 ;
|
||||
C 104 ; WX 600 ; N h ; B 18 0 615 626 ;
|
||||
C 105 ; WX 600 ; N i ; B 77 0 546 658 ;
|
||||
C 106 ; WX 600 ; N j ; B 36 -146 580 658 ;
|
||||
C 107 ; WX 600 ; N k ; B 33 0 643 626 ;
|
||||
C 108 ; WX 600 ; N l ; B 77 0 546 626 ;
|
||||
C 109 ; WX 600 ; N m ; B -22 0 649 454 ;
|
||||
C 110 ; WX 600 ; N n ; B 18 0 615 454 ;
|
||||
C 111 ; WX 600 ; N o ; B 71 -15 622 454 ;
|
||||
C 112 ; WX 600 ; N p ; B -32 -142 622 454 ;
|
||||
C 113 ; WX 600 ; N q ; B 60 -142 685 454 ;
|
||||
C 114 ; WX 600 ; N r ; B 47 0 655 454 ;
|
||||
C 115 ; WX 600 ; N s ; B 66 -17 608 459 ;
|
||||
C 116 ; WX 600 ; N t ; B 118 -15 567 562 ;
|
||||
C 117 ; WX 600 ; N u ; B 70 -15 592 439 ;
|
||||
C 118 ; WX 600 ; N v ; B 70 0 695 439 ;
|
||||
C 119 ; WX 600 ; N w ; B 53 0 712 439 ;
|
||||
C 120 ; WX 600 ; N x ; B 6 0 671 439 ;
|
||||
C 121 ; WX 600 ; N y ; B -21 -142 695 439 ;
|
||||
C 122 ; WX 600 ; N z ; B 81 0 614 439 ;
|
||||
C 123 ; WX 600 ; N braceleft ; B 203 -102 595 616 ;
|
||||
C 124 ; WX 600 ; N bar ; B 201 -250 505 750 ;
|
||||
C 125 ; WX 600 ; N braceright ; B 114 -102 506 616 ;
|
||||
C 126 ; WX 600 ; N asciitilde ; B 120 153 590 356 ;
|
||||
C 161 ; WX 600 ; N exclamdown ; B 196 -146 477 449 ;
|
||||
C 162 ; WX 600 ; N cent ; B 121 -49 605 614 ;
|
||||
C 163 ; WX 600 ; N sterling ; B 106 -28 650 611 ;
|
||||
C -1 ; WX 600 ; N fraction ; B 22 -60 708 661 ;
|
||||
C 165 ; WX 600 ; N yen ; B 98 0 710 562 ;
|
||||
C 131 ; WX 600 ; N florin ; B -57 -131 702 616 ;
|
||||
C 167 ; WX 600 ; N section ; B 74 -70 620 580 ;
|
||||
C 164 ; WX 600 ; N currency ; B 77 49 644 517 ;
|
||||
C 39 ; WX 600 ; N quotesingle ; B 303 277 493 562 ;
|
||||
C 147 ; WX 600 ; N quotedblleft ; B 190 277 594 562 ;
|
||||
C 171 ; WX 600 ; N guillemotleft ; B 62 70 639 446 ;
|
||||
C 139 ; WX 600 ; N guilsinglleft ; B 195 70 545 446 ;
|
||||
C 155 ; WX 600 ; N guilsinglright ; B 165 70 514 446 ;
|
||||
C -1 ; WX 600 ; N fi ; B 12 0 644 626 ;
|
||||
C -1 ; WX 600 ; N fl ; B 12 0 644 626 ;
|
||||
C 150 ; WX 600 ; N endash ; B 108 203 602 313 ;
|
||||
C 134 ; WX 600 ; N dagger ; B 175 -70 586 580 ;
|
||||
C 135 ; WX 600 ; N daggerdbl ; B 121 -70 587 580 ;
|
||||
C 183 ; WX 600 ; N periodcentered ; B 248 165 461 351 ;
|
||||
C 182 ; WX 600 ; N paragraph ; B 61 -70 700 580 ;
|
||||
C 149 ; WX 600 ; N bullet ; B 196 132 523 430 ;
|
||||
C 130 ; WX 600 ; N quotesinglbase ; B 144 -142 458 143 ;
|
||||
C 132 ; WX 600 ; N quotedblbase ; B 34 -142 560 143 ;
|
||||
C 148 ; WX 600 ; N quotedblright ; B 119 277 645 562 ;
|
||||
C 187 ; WX 600 ; N guillemotright ; B 71 70 647 446 ;
|
||||
C 133 ; WX 600 ; N ellipsis ; B 35 -15 587 116 ;
|
||||
C 137 ; WX 600 ; N perthousand ; B -45 -15 743 616 ;
|
||||
C 191 ; WX 600 ; N questiondown ; B 100 -146 509 449 ;
|
||||
C 96 ; WX 600 ; N grave ; B 272 508 503 661 ;
|
||||
C 180 ; WX 600 ; N acute ; B 312 508 609 661 ;
|
||||
C 136 ; WX 600 ; N circumflex ; B 212 483 607 657 ;
|
||||
C 152 ; WX 600 ; N tilde ; B 199 493 643 636 ;
|
||||
C 175 ; WX 600 ; N macron ; B 195 505 637 585 ;
|
||||
C -1 ; WX 600 ; N breve ; B 217 468 652 631 ;
|
||||
C -1 ; WX 600 ; N dotaccent ; B 348 498 493 638 ;
|
||||
C 168 ; WX 600 ; N dieresis ; B 246 498 595 638 ;
|
||||
C -1 ; WX 600 ; N ring ; B 319 481 528 678 ;
|
||||
C 184 ; WX 600 ; N cedilla ; B 168 -206 368 0 ;
|
||||
C -1 ; WX 600 ; N hungarumlaut ; B 171 488 729 661 ;
|
||||
C -1 ; WX 600 ; N ogonek ; B 143 -199 367 0 ;
|
||||
C -1 ; WX 600 ; N caron ; B 238 493 633 667 ;
|
||||
C 151 ; WX 600 ; N emdash ; B 33 203 677 313 ;
|
||||
C 198 ; WX 600 ; N AE ; B -29 0 708 562 ;
|
||||
C 170 ; WX 600 ; N ordfeminine ; B 188 196 526 580 ;
|
||||
C -1 ; WX 600 ; N Lslash ; B 39 0 636 562 ;
|
||||
C 216 ; WX 600 ; N Oslash ; B 48 -22 673 584 ;
|
||||
C 140 ; WX 600 ; N OE ; B 26 0 701 562 ;
|
||||
C 186 ; WX 600 ; N ordmasculine ; B 188 196 543 580 ;
|
||||
C 230 ; WX 600 ; N ae ; B 21 -15 652 454 ;
|
||||
C -1 ; WX 600 ; N dotlessi ; B 77 0 546 439 ;
|
||||
C -1 ; WX 600 ; N lslash ; B 77 0 587 626 ;
|
||||
C 248 ; WX 600 ; N oslash ; B 54 -24 638 463 ;
|
||||
C 156 ; WX 600 ; N oe ; B 18 -15 662 454 ;
|
||||
C 223 ; WX 600 ; N germandbls ; B 22 -15 629 626 ;
|
||||
C 207 ; WX 600 ; N Idieresis ; B 77 0 643 761 ;
|
||||
C 233 ; WX 600 ; N eacute ; B 81 -15 609 661 ;
|
||||
C -1 ; WX 600 ; N abreve ; B 61 -15 658 661 ;
|
||||
C -1 ; WX 600 ; N uhungarumlaut ; B 70 -15 769 661 ;
|
||||
C -1 ; WX 600 ; N ecaron ; B 81 -15 633 667 ;
|
||||
C 159 ; WX 600 ; N Ydieresis ; B 109 0 709 761 ;
|
||||
C 247 ; WX 600 ; N divide ; B 114 16 596 500 ;
|
||||
C 221 ; WX 600 ; N Yacute ; B 109 0 709 784 ;
|
||||
C 194 ; WX 600 ; N Acircumflex ; B -9 0 632 780 ;
|
||||
C 225 ; WX 600 ; N aacute ; B 61 -15 609 661 ;
|
||||
C 219 ; WX 600 ; N Ucircumflex ; B 101 -18 716 780 ;
|
||||
C 253 ; WX 600 ; N yacute ; B -21 -142 695 661 ;
|
||||
C -1 ; WX 600 ; N scommaaccent ; B 66 -250 608 459 ;
|
||||
C 234 ; WX 600 ; N ecircumflex ; B 81 -15 607 657 ;
|
||||
C -1 ; WX 600 ; N Uring ; B 101 -18 716 801 ;
|
||||
C 220 ; WX 600 ; N Udieresis ; B 101 -18 716 761 ;
|
||||
C -1 ; WX 600 ; N aogonek ; B 61 -199 593 454 ;
|
||||
C 218 ; WX 600 ; N Uacute ; B 101 -18 716 784 ;
|
||||
C -1 ; WX 600 ; N uogonek ; B 70 -199 592 439 ;
|
||||
C 203 ; WX 600 ; N Edieresis ; B 25 0 670 761 ;
|
||||
C -1 ; WX 600 ; N Dcroat ; B 30 0 664 562 ;
|
||||
C -1 ; WX 600 ; N commaaccent ; B 151 -250 385 -57 ;
|
||||
C 169 ; WX 600 ; N copyright ; B 53 -18 667 580 ;
|
||||
C -1 ; WX 600 ; N Emacron ; B 25 0 670 708 ;
|
||||
C -1 ; WX 600 ; N ccaron ; B 81 -15 633 667 ;
|
||||
C 229 ; WX 600 ; N aring ; B 61 -15 593 678 ;
|
||||
C -1 ; WX 600 ; N Ncommaaccent ; B 8 -250 730 562 ;
|
||||
C -1 ; WX 600 ; N lacute ; B 77 0 639 801 ;
|
||||
C 224 ; WX 600 ; N agrave ; B 61 -15 593 661 ;
|
||||
C -1 ; WX 600 ; N Tcommaaccent ; B 86 -250 679 562 ;
|
||||
C -1 ; WX 600 ; N Cacute ; B 74 -18 675 784 ;
|
||||
C 227 ; WX 600 ; N atilde ; B 61 -15 643 636 ;
|
||||
C -1 ; WX 600 ; N Edotaccent ; B 25 0 670 761 ;
|
||||
C 154 ; WX 600 ; N scaron ; B 66 -17 633 667 ;
|
||||
C -1 ; WX 600 ; N scedilla ; B 66 -206 608 459 ;
|
||||
C 237 ; WX 600 ; N iacute ; B 77 0 609 661 ;
|
||||
C -1 ; WX 600 ; N lozenge ; B 145 0 614 740 ;
|
||||
C -1 ; WX 600 ; N Rcaron ; B 24 0 659 790 ;
|
||||
C -1 ; WX 600 ; N Gcommaaccent ; B 74 -250 675 580 ;
|
||||
C 251 ; WX 600 ; N ucircumflex ; B 70 -15 597 657 ;
|
||||
C 226 ; WX 600 ; N acircumflex ; B 61 -15 607 657 ;
|
||||
C -1 ; WX 600 ; N Amacron ; B -9 0 633 708 ;
|
||||
C -1 ; WX 600 ; N rcaron ; B 47 0 655 667 ;
|
||||
C 231 ; WX 600 ; N ccedilla ; B 81 -206 631 459 ;
|
||||
C -1 ; WX 600 ; N Zdotaccent ; B 62 0 637 761 ;
|
||||
C 222 ; WX 600 ; N Thorn ; B 48 0 620 562 ;
|
||||
C -1 ; WX 600 ; N Omacron ; B 74 -18 663 708 ;
|
||||
C -1 ; WX 600 ; N Racute ; B 24 0 665 784 ;
|
||||
C -1 ; WX 600 ; N Sacute ; B 54 -22 673 784 ;
|
||||
C -1 ; WX 600 ; N dcaron ; B 60 -15 861 626 ;
|
||||
C -1 ; WX 600 ; N Umacron ; B 101 -18 716 708 ;
|
||||
C -1 ; WX 600 ; N uring ; B 70 -15 592 678 ;
|
||||
C 179 ; WX 600 ; N threesuperior ; B 193 222 526 616 ;
|
||||
C 210 ; WX 600 ; N Ograve ; B 74 -18 645 784 ;
|
||||
C 192 ; WX 600 ; N Agrave ; B -9 0 632 784 ;
|
||||
C -1 ; WX 600 ; N Abreve ; B -9 0 684 784 ;
|
||||
C 215 ; WX 600 ; N multiply ; B 104 39 606 478 ;
|
||||
C 250 ; WX 600 ; N uacute ; B 70 -15 599 661 ;
|
||||
C -1 ; WX 600 ; N Tcaron ; B 86 0 679 790 ;
|
||||
C -1 ; WX 600 ; N partialdiff ; B 91 -38 627 728 ;
|
||||
C 255 ; WX 600 ; N ydieresis ; B -21 -142 695 638 ;
|
||||
C -1 ; WX 600 ; N Nacute ; B 8 -12 730 784 ;
|
||||
C 238 ; WX 600 ; N icircumflex ; B 77 0 577 657 ;
|
||||
C 202 ; WX 600 ; N Ecircumflex ; B 25 0 670 780 ;
|
||||
C 228 ; WX 600 ; N adieresis ; B 61 -15 595 638 ;
|
||||
C 235 ; WX 600 ; N edieresis ; B 81 -15 605 638 ;
|
||||
C -1 ; WX 600 ; N cacute ; B 81 -15 649 661 ;
|
||||
C -1 ; WX 600 ; N nacute ; B 18 0 639 661 ;
|
||||
C -1 ; WX 600 ; N umacron ; B 70 -15 637 585 ;
|
||||
C -1 ; WX 600 ; N Ncaron ; B 8 -12 730 790 ;
|
||||
C 205 ; WX 600 ; N Iacute ; B 77 0 643 784 ;
|
||||
C 177 ; WX 600 ; N plusminus ; B 76 24 614 515 ;
|
||||
C 166 ; WX 600 ; N brokenbar ; B 217 -175 489 675 ;
|
||||
C 174 ; WX 600 ; N registered ; B 53 -18 667 580 ;
|
||||
C -1 ; WX 600 ; N Gbreve ; B 74 -18 684 784 ;
|
||||
C -1 ; WX 600 ; N Idotaccent ; B 77 0 643 761 ;
|
||||
C -1 ; WX 600 ; N summation ; B 15 -10 672 706 ;
|
||||
C 200 ; WX 600 ; N Egrave ; B 25 0 670 784 ;
|
||||
C -1 ; WX 600 ; N racute ; B 47 0 655 661 ;
|
||||
C -1 ; WX 600 ; N omacron ; B 71 -15 637 585 ;
|
||||
C -1 ; WX 600 ; N Zacute ; B 62 0 665 784 ;
|
||||
C 142 ; WX 600 ; N Zcaron ; B 62 0 659 790 ;
|
||||
C -1 ; WX 600 ; N greaterequal ; B 26 0 627 696 ;
|
||||
C 208 ; WX 600 ; N Eth ; B 30 0 664 562 ;
|
||||
C 199 ; WX 600 ; N Ccedilla ; B 74 -206 675 580 ;
|
||||
C -1 ; WX 600 ; N lcommaaccent ; B 77 -250 546 626 ;
|
||||
C -1 ; WX 600 ; N tcaron ; B 118 -15 627 703 ;
|
||||
C -1 ; WX 600 ; N eogonek ; B 81 -199 605 454 ;
|
||||
C -1 ; WX 600 ; N Uogonek ; B 101 -199 716 562 ;
|
||||
C 193 ; WX 600 ; N Aacute ; B -9 0 655 784 ;
|
||||
C 196 ; WX 600 ; N Adieresis ; B -9 0 632 761 ;
|
||||
C 232 ; WX 600 ; N egrave ; B 81 -15 605 661 ;
|
||||
C -1 ; WX 600 ; N zacute ; B 81 0 614 661 ;
|
||||
C -1 ; WX 600 ; N iogonek ; B 77 -199 546 658 ;
|
||||
C 211 ; WX 600 ; N Oacute ; B 74 -18 645 784 ;
|
||||
C 243 ; WX 600 ; N oacute ; B 71 -15 649 661 ;
|
||||
C -1 ; WX 600 ; N amacron ; B 61 -15 637 585 ;
|
||||
C -1 ; WX 600 ; N sacute ; B 66 -17 609 661 ;
|
||||
C 239 ; WX 600 ; N idieresis ; B 77 0 561 618 ;
|
||||
C 212 ; WX 600 ; N Ocircumflex ; B 74 -18 645 780 ;
|
||||
C 217 ; WX 600 ; N Ugrave ; B 101 -18 716 784 ;
|
||||
C -1 ; WX 600 ; N Delta ; B 6 0 594 688 ;
|
||||
C 254 ; WX 600 ; N thorn ; B -32 -142 622 626 ;
|
||||
C 178 ; WX 600 ; N twosuperior ; B 191 230 542 616 ;
|
||||
C 214 ; WX 600 ; N Odieresis ; B 74 -18 645 761 ;
|
||||
C 181 ; WX 600 ; N mu ; B 49 -142 592 439 ;
|
||||
C 236 ; WX 600 ; N igrave ; B 77 0 546 661 ;
|
||||
C -1 ; WX 600 ; N ohungarumlaut ; B 71 -15 809 661 ;
|
||||
C -1 ; WX 600 ; N Eogonek ; B 25 -199 670 562 ;
|
||||
C -1 ; WX 600 ; N dcroat ; B 60 -15 712 626 ;
|
||||
C 190 ; WX 600 ; N threequarters ; B 8 -60 699 661 ;
|
||||
C -1 ; WX 600 ; N Scedilla ; B 54 -206 673 582 ;
|
||||
C -1 ; WX 600 ; N lcaron ; B 77 0 731 626 ;
|
||||
C -1 ; WX 600 ; N Kcommaaccent ; B 21 -250 692 562 ;
|
||||
C -1 ; WX 600 ; N Lacute ; B 39 0 636 784 ;
|
||||
C 153 ; WX 600 ; N trademark ; B 86 230 869 562 ;
|
||||
C -1 ; WX 600 ; N edotaccent ; B 81 -15 605 638 ;
|
||||
C 204 ; WX 600 ; N Igrave ; B 77 0 643 784 ;
|
||||
C -1 ; WX 600 ; N Imacron ; B 77 0 663 708 ;
|
||||
C -1 ; WX 600 ; N Lcaron ; B 39 0 757 562 ;
|
||||
C 189 ; WX 600 ; N onehalf ; B 22 -60 716 661 ;
|
||||
C -1 ; WX 600 ; N lessequal ; B 26 0 671 696 ;
|
||||
C 244 ; WX 600 ; N ocircumflex ; B 71 -15 622 657 ;
|
||||
C 241 ; WX 600 ; N ntilde ; B 18 0 643 636 ;
|
||||
C -1 ; WX 600 ; N Uhungarumlaut ; B 101 -18 805 784 ;
|
||||
C 201 ; WX 600 ; N Eacute ; B 25 0 670 784 ;
|
||||
C -1 ; WX 600 ; N emacron ; B 81 -15 637 585 ;
|
||||
C -1 ; WX 600 ; N gbreve ; B 40 -146 674 661 ;
|
||||
C 188 ; WX 600 ; N onequarter ; B 13 -60 707 661 ;
|
||||
C 138 ; WX 600 ; N Scaron ; B 54 -22 689 790 ;
|
||||
C -1 ; WX 600 ; N Scommaaccent ; B 54 -250 673 582 ;
|
||||
C -1 ; WX 600 ; N Ohungarumlaut ; B 74 -18 795 784 ;
|
||||
C 176 ; WX 600 ; N degree ; B 173 243 570 616 ;
|
||||
C 242 ; WX 600 ; N ograve ; B 71 -15 622 661 ;
|
||||
C -1 ; WX 600 ; N Ccaron ; B 74 -18 689 790 ;
|
||||
C 249 ; WX 600 ; N ugrave ; B 70 -15 592 661 ;
|
||||
C -1 ; WX 600 ; N radical ; B 67 -104 635 778 ;
|
||||
C -1 ; WX 600 ; N Dcaron ; B 30 0 664 790 ;
|
||||
C -1 ; WX 600 ; N rcommaaccent ; B 47 -250 655 454 ;
|
||||
C 209 ; WX 600 ; N Ntilde ; B 8 -12 730 759 ;
|
||||
C 245 ; WX 600 ; N otilde ; B 71 -15 643 636 ;
|
||||
C -1 ; WX 600 ; N Rcommaaccent ; B 24 -250 617 562 ;
|
||||
C -1 ; WX 600 ; N Lcommaaccent ; B 39 -250 636 562 ;
|
||||
C 195 ; WX 600 ; N Atilde ; B -9 0 669 759 ;
|
||||
C -1 ; WX 600 ; N Aogonek ; B -9 -199 632 562 ;
|
||||
C 197 ; WX 600 ; N Aring ; B -9 0 632 801 ;
|
||||
C 213 ; WX 600 ; N Otilde ; B 74 -18 669 759 ;
|
||||
C -1 ; WX 600 ; N zdotaccent ; B 81 0 614 638 ;
|
||||
C -1 ; WX 600 ; N Ecaron ; B 25 0 670 790 ;
|
||||
C -1 ; WX 600 ; N Iogonek ; B 77 -199 643 562 ;
|
||||
C -1 ; WX 600 ; N kcommaaccent ; B 33 -250 643 626 ;
|
||||
C -1 ; WX 600 ; N minus ; B 114 203 596 313 ;
|
||||
C 206 ; WX 600 ; N Icircumflex ; B 77 0 643 780 ;
|
||||
C -1 ; WX 600 ; N ncaron ; B 18 0 633 667 ;
|
||||
C -1 ; WX 600 ; N tcommaaccent ; B 118 -250 567 562 ;
|
||||
C 172 ; WX 600 ; N logicalnot ; B 135 103 617 413 ;
|
||||
C 246 ; WX 600 ; N odieresis ; B 71 -15 622 638 ;
|
||||
C 252 ; WX 600 ; N udieresis ; B 70 -15 595 638 ;
|
||||
C -1 ; WX 600 ; N notequal ; B 30 -47 626 563 ;
|
||||
C -1 ; WX 600 ; N gcommaaccent ; B 40 -146 674 714 ;
|
||||
C 240 ; WX 600 ; N eth ; B 93 -27 661 626 ;
|
||||
C 158 ; WX 600 ; N zcaron ; B 81 0 643 667 ;
|
||||
C -1 ; WX 600 ; N ncommaaccent ; B 18 -250 615 454 ;
|
||||
C 185 ; WX 600 ; N onesuperior ; B 212 230 514 616 ;
|
||||
C -1 ; WX 600 ; N imacron ; B 77 0 575 585 ;
|
||||
C 128 ; WX 600 ; N Euro ; B 0 0 0 0 ;
|
||||
EndCharMetrics
|
||||
EndFontMetrics
|
|
@ -0,0 +1,344 @@
|
|||
StartFontMetrics 4.1
|
||||
Comment Copyright (c) 1989, 1990, 1991, 1992, 1993, 1997 Adobe Systems Incorporated. All Rights Reserved.
|
||||
Comment Creation Date: Thu May 0:00:00 17:37:52 1997
|
||||
Comment UniqueID 43051
|
||||
Comment VMusage 16248 75829
|
||||
FontName Courier-Oblique
|
||||
FullName Courier Oblique
|
||||
FamilyName Courier
|
||||
Weight Medium
|
||||
ItalicAngle -12
|
||||
IsFixedPitch true
|
||||
CharacterSet ExtendedRoman
|
||||
FontBBox -27 -250 849 805
|
||||
UnderlinePosition -100
|
||||
UnderlineThickness 50
|
||||
Version 003.000
|
||||
Notice Copyright (c) 1989, 1990, 1991, 1992, 1993, 1997 Adobe Systems Incorporated. All Rights Reserved.
|
||||
EncodingScheme WinAnsiEncoding
|
||||
CapHeight 562
|
||||
XHeight 426
|
||||
Ascender 629
|
||||
Descender -157
|
||||
StdHW 51
|
||||
StdVW 51
|
||||
StartCharMetrics 317
|
||||
C 32 ; WX 600 ; N space ; B 0 0 0 0 ;
|
||||
C 160 ; WX 600 ; N space ; B 0 0 0 0 ;
|
||||
C 33 ; WX 600 ; N exclam ; B 243 -15 464 572 ;
|
||||
C 34 ; WX 600 ; N quotedbl ; B 273 328 532 562 ;
|
||||
C 35 ; WX 600 ; N numbersign ; B 133 -32 596 639 ;
|
||||
C 36 ; WX 600 ; N dollar ; B 108 -126 596 662 ;
|
||||
C 37 ; WX 600 ; N percent ; B 134 -15 599 622 ;
|
||||
C 38 ; WX 600 ; N ampersand ; B 87 -15 580 543 ;
|
||||
C 146 ; WX 600 ; N quoteright ; B 283 328 495 562 ;
|
||||
C 40 ; WX 600 ; N parenleft ; B 313 -108 572 622 ;
|
||||
C 41 ; WX 600 ; N parenright ; B 137 -108 396 622 ;
|
||||
C 42 ; WX 600 ; N asterisk ; B 212 257 580 607 ;
|
||||
C 43 ; WX 600 ; N plus ; B 129 44 580 470 ;
|
||||
C 44 ; WX 600 ; N comma ; B 157 -112 370 122 ;
|
||||
C 45 ; WX 600 ; N hyphen ; B 152 231 558 285 ;
|
||||
C 173 ; WX 600 ; N hyphen ; B 152 231 558 285 ;
|
||||
C 46 ; WX 600 ; N period ; B 238 -15 382 109 ;
|
||||
C 47 ; WX 600 ; N slash ; B 112 -80 604 629 ;
|
||||
C 48 ; WX 600 ; N zero ; B 154 -15 575 622 ;
|
||||
C 49 ; WX 600 ; N one ; B 98 0 515 622 ;
|
||||
C 50 ; WX 600 ; N two ; B 70 0 568 622 ;
|
||||
C 51 ; WX 600 ; N three ; B 82 -15 538 622 ;
|
||||
C 52 ; WX 600 ; N four ; B 108 0 541 622 ;
|
||||
C 53 ; WX 600 ; N five ; B 99 -15 589 607 ;
|
||||
C 54 ; WX 600 ; N six ; B 155 -15 629 622 ;
|
||||
C 55 ; WX 600 ; N seven ; B 182 0 612 607 ;
|
||||
C 56 ; WX 600 ; N eight ; B 132 -15 588 622 ;
|
||||
C 57 ; WX 600 ; N nine ; B 93 -15 574 622 ;
|
||||
C 58 ; WX 600 ; N colon ; B 238 -15 441 385 ;
|
||||
C 59 ; WX 600 ; N semicolon ; B 157 -112 441 385 ;
|
||||
C 60 ; WX 600 ; N less ; B 96 42 610 472 ;
|
||||
C 61 ; WX 600 ; N equal ; B 109 138 600 376 ;
|
||||
C 62 ; WX 600 ; N greater ; B 85 42 599 472 ;
|
||||
C 63 ; WX 600 ; N question ; B 222 -15 583 572 ;
|
||||
C 64 ; WX 600 ; N at ; B 127 -15 582 622 ;
|
||||
C 65 ; WX 600 ; N A ; B 3 0 607 562 ;
|
||||
C 66 ; WX 600 ; N B ; B 43 0 616 562 ;
|
||||
C 67 ; WX 600 ; N C ; B 93 -18 655 580 ;
|
||||
C 68 ; WX 600 ; N D ; B 43 0 645 562 ;
|
||||
C 69 ; WX 600 ; N E ; B 53 0 660 562 ;
|
||||
C 70 ; WX 600 ; N F ; B 53 0 660 562 ;
|
||||
C 71 ; WX 600 ; N G ; B 83 -18 645 580 ;
|
||||
C 72 ; WX 600 ; N H ; B 32 0 687 562 ;
|
||||
C 73 ; WX 600 ; N I ; B 96 0 623 562 ;
|
||||
C 74 ; WX 600 ; N J ; B 52 -18 685 562 ;
|
||||
C 75 ; WX 600 ; N K ; B 38 0 671 562 ;
|
||||
C 76 ; WX 600 ; N L ; B 47 0 607 562 ;
|
||||
C 77 ; WX 600 ; N M ; B 4 0 715 562 ;
|
||||
C 78 ; WX 600 ; N N ; B 7 -13 712 562 ;
|
||||
C 79 ; WX 600 ; N O ; B 94 -18 625 580 ;
|
||||
C 80 ; WX 600 ; N P ; B 79 0 644 562 ;
|
||||
C 81 ; WX 600 ; N Q ; B 95 -138 625 580 ;
|
||||
C 82 ; WX 600 ; N R ; B 38 0 598 562 ;
|
||||
C 83 ; WX 600 ; N S ; B 76 -20 650 580 ;
|
||||
C 84 ; WX 600 ; N T ; B 108 0 665 562 ;
|
||||
C 85 ; WX 600 ; N U ; B 125 -18 702 562 ;
|
||||
C 86 ; WX 600 ; N V ; B 105 -13 723 562 ;
|
||||
C 87 ; WX 600 ; N W ; B 106 -13 722 562 ;
|
||||
C 88 ; WX 600 ; N X ; B 23 0 675 562 ;
|
||||
C 89 ; WX 600 ; N Y ; B 133 0 695 562 ;
|
||||
C 90 ; WX 600 ; N Z ; B 86 0 610 562 ;
|
||||
C 91 ; WX 600 ; N bracketleft ; B 246 -108 574 622 ;
|
||||
C 92 ; WX 600 ; N backslash ; B 249 -80 468 629 ;
|
||||
C 93 ; WX 600 ; N bracketright ; B 135 -108 463 622 ;
|
||||
C 94 ; WX 600 ; N asciicircum ; B 175 354 587 622 ;
|
||||
C 95 ; WX 600 ; N underscore ; B -27 -125 584 -75 ;
|
||||
C 145 ; WX 600 ; N quoteleft ; B 343 328 457 562 ;
|
||||
C 97 ; WX 600 ; N a ; B 76 -15 569 441 ;
|
||||
C 98 ; WX 600 ; N b ; B 29 -15 625 629 ;
|
||||
C 99 ; WX 600 ; N c ; B 106 -15 608 441 ;
|
||||
C 100 ; WX 600 ; N d ; B 85 -15 640 629 ;
|
||||
C 101 ; WX 600 ; N e ; B 106 -15 598 441 ;
|
||||
C 102 ; WX 600 ; N f ; B 114 0 662 629 ; L i fi ; L l fl ;
|
||||
C 103 ; WX 600 ; N g ; B 61 -157 657 441 ;
|
||||
C 104 ; WX 600 ; N h ; B 33 0 592 629 ;
|
||||
C 105 ; WX 600 ; N i ; B 95 0 515 657 ;
|
||||
C 106 ; WX 600 ; N j ; B 52 -157 550 657 ;
|
||||
C 107 ; WX 600 ; N k ; B 58 0 633 629 ;
|
||||
C 108 ; WX 600 ; N l ; B 95 0 515 629 ;
|
||||
C 109 ; WX 600 ; N m ; B -5 0 615 441 ;
|
||||
C 110 ; WX 600 ; N n ; B 26 0 585 441 ;
|
||||
C 111 ; WX 600 ; N o ; B 102 -15 588 441 ;
|
||||
C 112 ; WX 600 ; N p ; B -24 -157 605 441 ;
|
||||
C 113 ; WX 600 ; N q ; B 85 -157 682 441 ;
|
||||
C 114 ; WX 600 ; N r ; B 60 0 636 441 ;
|
||||
C 115 ; WX 600 ; N s ; B 78 -15 584 441 ;
|
||||
C 116 ; WX 600 ; N t ; B 167 -15 561 561 ;
|
||||
C 117 ; WX 600 ; N u ; B 101 -15 572 426 ;
|
||||
C 118 ; WX 600 ; N v ; B 90 -10 681 426 ;
|
||||
C 119 ; WX 600 ; N w ; B 76 -10 695 426 ;
|
||||
C 120 ; WX 600 ; N x ; B 20 0 655 426 ;
|
||||
C 121 ; WX 600 ; N y ; B -4 -157 683 426 ;
|
||||
C 122 ; WX 600 ; N z ; B 99 0 593 426 ;
|
||||
C 123 ; WX 600 ; N braceleft ; B 233 -108 569 622 ;
|
||||
C 124 ; WX 600 ; N bar ; B 222 -250 485 750 ;
|
||||
C 125 ; WX 600 ; N braceright ; B 140 -108 477 622 ;
|
||||
C 126 ; WX 600 ; N asciitilde ; B 116 197 600 320 ;
|
||||
C 161 ; WX 600 ; N exclamdown ; B 225 -157 445 430 ;
|
||||
C 162 ; WX 600 ; N cent ; B 151 -49 588 614 ;
|
||||
C 163 ; WX 600 ; N sterling ; B 124 -21 621 611 ;
|
||||
C -1 ; WX 600 ; N fraction ; B 84 -57 646 665 ;
|
||||
C 165 ; WX 600 ; N yen ; B 120 0 693 562 ;
|
||||
C 131 ; WX 600 ; N florin ; B -26 -143 671 622 ;
|
||||
C 167 ; WX 600 ; N section ; B 104 -78 590 580 ;
|
||||
C 164 ; WX 600 ; N currency ; B 94 58 628 506 ;
|
||||
C 39 ; WX 600 ; N quotesingle ; B 345 328 460 562 ;
|
||||
C 147 ; WX 600 ; N quotedblleft ; B 262 328 541 562 ;
|
||||
C 171 ; WX 600 ; N guillemotleft ; B 92 70 652 446 ;
|
||||
C 139 ; WX 600 ; N guilsinglleft ; B 204 70 540 446 ;
|
||||
C 155 ; WX 600 ; N guilsinglright ; B 170 70 506 446 ;
|
||||
C -1 ; WX 600 ; N fi ; B 3 0 619 629 ;
|
||||
C -1 ; WX 600 ; N fl ; B 3 0 619 629 ;
|
||||
C 150 ; WX 600 ; N endash ; B 124 231 586 285 ;
|
||||
C 134 ; WX 600 ; N dagger ; B 217 -78 546 580 ;
|
||||
C 135 ; WX 600 ; N daggerdbl ; B 163 -78 546 580 ;
|
||||
C 183 ; WX 600 ; N periodcentered ; B 275 189 434 327 ;
|
||||
C 182 ; WX 600 ; N paragraph ; B 100 -78 630 562 ;
|
||||
C 149 ; WX 600 ; N bullet ; B 224 130 485 383 ;
|
||||
C 130 ; WX 600 ; N quotesinglbase ; B 185 -134 397 100 ;
|
||||
C 132 ; WX 600 ; N quotedblbase ; B 115 -134 478 100 ;
|
||||
C 148 ; WX 600 ; N quotedblright ; B 213 328 576 562 ;
|
||||
C 187 ; WX 600 ; N guillemotright ; B 58 70 618 446 ;
|
||||
C 133 ; WX 600 ; N ellipsis ; B 46 -15 575 111 ;
|
||||
C 137 ; WX 600 ; N perthousand ; B 59 -15 627 622 ;
|
||||
C 191 ; WX 600 ; N questiondown ; B 105 -157 466 430 ;
|
||||
C 96 ; WX 600 ; N grave ; B 294 497 484 672 ;
|
||||
C 180 ; WX 600 ; N acute ; B 348 497 612 672 ;
|
||||
C 136 ; WX 600 ; N circumflex ; B 229 477 581 654 ;
|
||||
C 152 ; WX 600 ; N tilde ; B 212 489 629 606 ;
|
||||
C 175 ; WX 600 ; N macron ; B 232 525 600 565 ;
|
||||
C -1 ; WX 600 ; N breve ; B 279 501 576 609 ;
|
||||
C -1 ; WX 600 ; N dotaccent ; B 373 537 478 640 ;
|
||||
C 168 ; WX 600 ; N dieresis ; B 272 537 579 640 ;
|
||||
C -1 ; WX 600 ; N ring ; B 332 463 500 627 ;
|
||||
C 184 ; WX 600 ; N cedilla ; B 197 -151 344 10 ;
|
||||
C -1 ; WX 600 ; N hungarumlaut ; B 239 497 683 672 ;
|
||||
C -1 ; WX 600 ; N ogonek ; B 189 -172 377 4 ;
|
||||
C -1 ; WX 600 ; N caron ; B 262 492 614 669 ;
|
||||
C 151 ; WX 600 ; N emdash ; B 49 231 661 285 ;
|
||||
C 198 ; WX 600 ; N AE ; B 3 0 655 562 ;
|
||||
C 170 ; WX 600 ; N ordfeminine ; B 209 249 512 580 ;
|
||||
C -1 ; WX 600 ; N Lslash ; B 47 0 607 562 ;
|
||||
C 216 ; WX 600 ; N Oslash ; B 94 -80 625 629 ;
|
||||
C 140 ; WX 600 ; N OE ; B 59 0 672 562 ;
|
||||
C 186 ; WX 600 ; N ordmasculine ; B 210 249 535 580 ;
|
||||
C 230 ; WX 600 ; N ae ; B 41 -15 626 441 ;
|
||||
C -1 ; WX 600 ; N dotlessi ; B 95 0 515 426 ;
|
||||
C -1 ; WX 600 ; N lslash ; B 95 0 587 629 ;
|
||||
C 248 ; WX 600 ; N oslash ; B 102 -80 588 506 ;
|
||||
C 156 ; WX 600 ; N oe ; B 54 -15 615 441 ;
|
||||
C 223 ; WX 600 ; N germandbls ; B 48 -15 617 629 ;
|
||||
C 207 ; WX 600 ; N Idieresis ; B 96 0 623 753 ;
|
||||
C 233 ; WX 600 ; N eacute ; B 106 -15 612 672 ;
|
||||
C -1 ; WX 600 ; N abreve ; B 76 -15 576 609 ;
|
||||
C -1 ; WX 600 ; N uhungarumlaut ; B 101 -15 723 672 ;
|
||||
C -1 ; WX 600 ; N ecaron ; B 106 -15 614 669 ;
|
||||
C 159 ; WX 600 ; N Ydieresis ; B 133 0 695 753 ;
|
||||
C 247 ; WX 600 ; N divide ; B 136 48 573 467 ;
|
||||
C 221 ; WX 600 ; N Yacute ; B 133 0 695 805 ;
|
||||
C 194 ; WX 600 ; N Acircumflex ; B 3 0 607 787 ;
|
||||
C 225 ; WX 600 ; N aacute ; B 76 -15 612 672 ;
|
||||
C 219 ; WX 600 ; N Ucircumflex ; B 125 -18 702 787 ;
|
||||
C 253 ; WX 600 ; N yacute ; B -4 -157 683 672 ;
|
||||
C -1 ; WX 600 ; N scommaaccent ; B 78 -250 584 441 ;
|
||||
C 234 ; WX 600 ; N ecircumflex ; B 106 -15 598 654 ;
|
||||
C -1 ; WX 600 ; N Uring ; B 125 -18 702 760 ;
|
||||
C 220 ; WX 600 ; N Udieresis ; B 125 -18 702 753 ;
|
||||
C -1 ; WX 600 ; N aogonek ; B 76 -172 569 441 ;
|
||||
C 218 ; WX 600 ; N Uacute ; B 125 -18 702 805 ;
|
||||
C -1 ; WX 600 ; N uogonek ; B 101 -172 572 426 ;
|
||||
C 203 ; WX 600 ; N Edieresis ; B 53 0 660 753 ;
|
||||
C -1 ; WX 600 ; N Dcroat ; B 43 0 645 562 ;
|
||||
C -1 ; WX 600 ; N commaaccent ; B 145 -250 323 -58 ;
|
||||
C 169 ; WX 600 ; N copyright ; B 53 -18 667 580 ;
|
||||
C -1 ; WX 600 ; N Emacron ; B 53 0 660 698 ;
|
||||
C -1 ; WX 600 ; N ccaron ; B 106 -15 614 669 ;
|
||||
C 229 ; WX 600 ; N aring ; B 76 -15 569 627 ;
|
||||
C -1 ; WX 600 ; N Ncommaaccent ; B 7 -250 712 562 ;
|
||||
C -1 ; WX 600 ; N lacute ; B 95 0 640 805 ;
|
||||
C 224 ; WX 600 ; N agrave ; B 76 -15 569 672 ;
|
||||
C -1 ; WX 600 ; N Tcommaaccent ; B 108 -250 665 562 ;
|
||||
C -1 ; WX 600 ; N Cacute ; B 93 -18 655 805 ;
|
||||
C 227 ; WX 600 ; N atilde ; B 76 -15 629 606 ;
|
||||
C -1 ; WX 600 ; N Edotaccent ; B 53 0 660 753 ;
|
||||
C 154 ; WX 600 ; N scaron ; B 78 -15 614 669 ;
|
||||
C -1 ; WX 600 ; N scedilla ; B 78 -151 584 441 ;
|
||||
C 237 ; WX 600 ; N iacute ; B 95 0 612 672 ;
|
||||
C -1 ; WX 600 ; N lozenge ; B 94 0 519 706 ;
|
||||
C -1 ; WX 600 ; N Rcaron ; B 38 0 642 802 ;
|
||||
C -1 ; WX 600 ; N Gcommaaccent ; B 83 -250 645 580 ;
|
||||
C 251 ; WX 600 ; N ucircumflex ; B 101 -15 572 654 ;
|
||||
C 226 ; WX 600 ; N acircumflex ; B 76 -15 581 654 ;
|
||||
C -1 ; WX 600 ; N Amacron ; B 3 0 607 698 ;
|
||||
C -1 ; WX 600 ; N rcaron ; B 60 0 636 669 ;
|
||||
C 231 ; WX 600 ; N ccedilla ; B 106 -151 614 441 ;
|
||||
C -1 ; WX 600 ; N Zdotaccent ; B 86 0 610 753 ;
|
||||
C 222 ; WX 600 ; N Thorn ; B 79 0 606 562 ;
|
||||
C -1 ; WX 600 ; N Omacron ; B 94 -18 628 698 ;
|
||||
C -1 ; WX 600 ; N Racute ; B 38 0 670 805 ;
|
||||
C -1 ; WX 600 ; N Sacute ; B 76 -20 650 805 ;
|
||||
C -1 ; WX 600 ; N dcaron ; B 85 -15 849 629 ;
|
||||
C -1 ; WX 600 ; N Umacron ; B 125 -18 702 698 ;
|
||||
C -1 ; WX 600 ; N uring ; B 101 -15 572 627 ;
|
||||
C 179 ; WX 600 ; N threesuperior ; B 213 240 501 622 ;
|
||||
C 210 ; WX 600 ; N Ograve ; B 94 -18 625 805 ;
|
||||
C 192 ; WX 600 ; N Agrave ; B 3 0 607 805 ;
|
||||
C -1 ; WX 600 ; N Abreve ; B 3 0 607 732 ;
|
||||
C 215 ; WX 600 ; N multiply ; B 103 43 607 470 ;
|
||||
C 250 ; WX 600 ; N uacute ; B 101 -15 602 672 ;
|
||||
C -1 ; WX 600 ; N Tcaron ; B 108 0 665 802 ;
|
||||
C -1 ; WX 600 ; N partialdiff ; B 45 -38 546 710 ;
|
||||
C 255 ; WX 600 ; N ydieresis ; B -4 -157 683 620 ;
|
||||
C -1 ; WX 600 ; N Nacute ; B 7 -13 712 805 ;
|
||||
C 238 ; WX 600 ; N icircumflex ; B 95 0 551 654 ;
|
||||
C 202 ; WX 600 ; N Ecircumflex ; B 53 0 660 787 ;
|
||||
C 228 ; WX 600 ; N adieresis ; B 76 -15 575 620 ;
|
||||
C 235 ; WX 600 ; N edieresis ; B 106 -15 598 620 ;
|
||||
C -1 ; WX 600 ; N cacute ; B 106 -15 612 672 ;
|
||||
C -1 ; WX 600 ; N nacute ; B 26 0 602 672 ;
|
||||
C -1 ; WX 600 ; N umacron ; B 101 -15 600 565 ;
|
||||
C -1 ; WX 600 ; N Ncaron ; B 7 -13 712 802 ;
|
||||
C 205 ; WX 600 ; N Iacute ; B 96 0 640 805 ;
|
||||
C 177 ; WX 600 ; N plusminus ; B 96 44 594 558 ;
|
||||
C 166 ; WX 600 ; N brokenbar ; B 238 -175 469 675 ;
|
||||
C 174 ; WX 600 ; N registered ; B 53 -18 667 580 ;
|
||||
C -1 ; WX 600 ; N Gbreve ; B 83 -18 645 732 ;
|
||||
C -1 ; WX 600 ; N Idotaccent ; B 96 0 623 753 ;
|
||||
C -1 ; WX 600 ; N summation ; B 15 -10 670 706 ;
|
||||
C 200 ; WX 600 ; N Egrave ; B 53 0 660 805 ;
|
||||
C -1 ; WX 600 ; N racute ; B 60 0 636 672 ;
|
||||
C -1 ; WX 600 ; N omacron ; B 102 -15 600 565 ;
|
||||
C -1 ; WX 600 ; N Zacute ; B 86 0 670 805 ;
|
||||
C 142 ; WX 600 ; N Zcaron ; B 86 0 642 802 ;
|
||||
C -1 ; WX 600 ; N greaterequal ; B 98 0 594 710 ;
|
||||
C 208 ; WX 600 ; N Eth ; B 43 0 645 562 ;
|
||||
C 199 ; WX 600 ; N Ccedilla ; B 93 -151 658 580 ;
|
||||
C -1 ; WX 600 ; N lcommaaccent ; B 95 -250 515 629 ;
|
||||
C -1 ; WX 600 ; N tcaron ; B 167 -15 587 717 ;
|
||||
C -1 ; WX 600 ; N eogonek ; B 106 -172 598 441 ;
|
||||
C -1 ; WX 600 ; N Uogonek ; B 124 -172 702 562 ;
|
||||
C 193 ; WX 600 ; N Aacute ; B 3 0 660 805 ;
|
||||
C 196 ; WX 600 ; N Adieresis ; B 3 0 607 753 ;
|
||||
C 232 ; WX 600 ; N egrave ; B 106 -15 598 672 ;
|
||||
C -1 ; WX 600 ; N zacute ; B 99 0 612 672 ;
|
||||
C -1 ; WX 600 ; N iogonek ; B 95 -172 515 657 ;
|
||||
C 211 ; WX 600 ; N Oacute ; B 94 -18 640 805 ;
|
||||
C 243 ; WX 600 ; N oacute ; B 102 -15 612 672 ;
|
||||
C -1 ; WX 600 ; N amacron ; B 76 -15 600 565 ;
|
||||
C -1 ; WX 600 ; N sacute ; B 78 -15 612 672 ;
|
||||
C 239 ; WX 600 ; N idieresis ; B 95 0 545 620 ;
|
||||
C 212 ; WX 600 ; N Ocircumflex ; B 94 -18 625 787 ;
|
||||
C 217 ; WX 600 ; N Ugrave ; B 125 -18 702 805 ;
|
||||
C -1 ; WX 600 ; N Delta ; B 6 0 598 688 ;
|
||||
C 254 ; WX 600 ; N thorn ; B -24 -157 605 629 ;
|
||||
C 178 ; WX 600 ; N twosuperior ; B 230 249 535 622 ;
|
||||
C 214 ; WX 600 ; N Odieresis ; B 94 -18 625 753 ;
|
||||
C 181 ; WX 600 ; N mu ; B 72 -157 572 426 ;
|
||||
C 236 ; WX 600 ; N igrave ; B 95 0 515 672 ;
|
||||
C -1 ; WX 600 ; N ohungarumlaut ; B 102 -15 723 672 ;
|
||||
C -1 ; WX 600 ; N Eogonek ; B 53 -172 660 562 ;
|
||||
C -1 ; WX 600 ; N dcroat ; B 85 -15 704 629 ;
|
||||
C 190 ; WX 600 ; N threequarters ; B 73 -56 659 666 ;
|
||||
C -1 ; WX 600 ; N Scedilla ; B 76 -151 650 580 ;
|
||||
C -1 ; WX 600 ; N lcaron ; B 95 0 667 629 ;
|
||||
C -1 ; WX 600 ; N Kcommaaccent ; B 38 -250 671 562 ;
|
||||
C -1 ; WX 600 ; N Lacute ; B 47 0 607 805 ;
|
||||
C 153 ; WX 600 ; N trademark ; B 75 263 742 562 ;
|
||||
C -1 ; WX 600 ; N edotaccent ; B 106 -15 598 620 ;
|
||||
C 204 ; WX 600 ; N Igrave ; B 96 0 623 805 ;
|
||||
C -1 ; WX 600 ; N Imacron ; B 96 0 628 698 ;
|
||||
C -1 ; WX 600 ; N Lcaron ; B 47 0 632 562 ;
|
||||
C 189 ; WX 600 ; N onehalf ; B 65 -57 669 665 ;
|
||||
C -1 ; WX 600 ; N lessequal ; B 98 0 645 710 ;
|
||||
C 244 ; WX 600 ; N ocircumflex ; B 102 -15 588 654 ;
|
||||
C 241 ; WX 600 ; N ntilde ; B 26 0 629 606 ;
|
||||
C -1 ; WX 600 ; N Uhungarumlaut ; B 125 -18 761 805 ;
|
||||
C 201 ; WX 600 ; N Eacute ; B 53 0 670 805 ;
|
||||
C -1 ; WX 600 ; N emacron ; B 106 -15 600 565 ;
|
||||
C -1 ; WX 600 ; N gbreve ; B 61 -157 657 609 ;
|
||||
C 188 ; WX 600 ; N onequarter ; B 65 -57 674 665 ;
|
||||
C 138 ; WX 600 ; N Scaron ; B 76 -20 672 802 ;
|
||||
C -1 ; WX 600 ; N Scommaaccent ; B 76 -250 650 580 ;
|
||||
C -1 ; WX 600 ; N Ohungarumlaut ; B 94 -18 751 805 ;
|
||||
C 176 ; WX 600 ; N degree ; B 214 269 576 622 ;
|
||||
C 242 ; WX 600 ; N ograve ; B 102 -15 588 672 ;
|
||||
C -1 ; WX 600 ; N Ccaron ; B 93 -18 672 802 ;
|
||||
C 249 ; WX 600 ; N ugrave ; B 101 -15 572 672 ;
|
||||
C -1 ; WX 600 ; N radical ; B 85 -15 765 792 ;
|
||||
C -1 ; WX 600 ; N Dcaron ; B 43 0 645 802 ;
|
||||
C -1 ; WX 600 ; N rcommaaccent ; B 60 -250 636 441 ;
|
||||
C 209 ; WX 600 ; N Ntilde ; B 7 -13 712 729 ;
|
||||
C 245 ; WX 600 ; N otilde ; B 102 -15 629 606 ;
|
||||
C -1 ; WX 600 ; N Rcommaaccent ; B 38 -250 598 562 ;
|
||||
C -1 ; WX 600 ; N Lcommaaccent ; B 47 -250 607 562 ;
|
||||
C 195 ; WX 600 ; N Atilde ; B 3 0 655 729 ;
|
||||
C -1 ; WX 600 ; N Aogonek ; B 3 -172 607 562 ;
|
||||
C 197 ; WX 600 ; N Aring ; B 3 0 607 750 ;
|
||||
C 213 ; WX 600 ; N Otilde ; B 94 -18 655 729 ;
|
||||
C -1 ; WX 600 ; N zdotaccent ; B 99 0 593 620 ;
|
||||
C -1 ; WX 600 ; N Ecaron ; B 53 0 660 802 ;
|
||||
C -1 ; WX 600 ; N Iogonek ; B 96 -172 623 562 ;
|
||||
C -1 ; WX 600 ; N kcommaaccent ; B 58 -250 633 629 ;
|
||||
C -1 ; WX 600 ; N minus ; B 129 232 580 283 ;
|
||||
C 206 ; WX 600 ; N Icircumflex ; B 96 0 623 787 ;
|
||||
C -1 ; WX 600 ; N ncaron ; B 26 0 614 669 ;
|
||||
C -1 ; WX 600 ; N tcommaaccent ; B 165 -250 561 561 ;
|
||||
C 172 ; WX 600 ; N logicalnot ; B 155 108 591 369 ;
|
||||
C 246 ; WX 600 ; N odieresis ; B 102 -15 588 620 ;
|
||||
C 252 ; WX 600 ; N udieresis ; B 101 -15 575 620 ;
|
||||
C -1 ; WX 600 ; N notequal ; B 43 -16 621 529 ;
|
||||
C -1 ; WX 600 ; N gcommaaccent ; B 61 -157 657 708 ;
|
||||
C 240 ; WX 600 ; N eth ; B 102 -15 639 629 ;
|
||||
C 158 ; WX 600 ; N zcaron ; B 99 0 624 669 ;
|
||||
C -1 ; WX 600 ; N ncommaaccent ; B 26 -250 585 441 ;
|
||||
C 185 ; WX 600 ; N onesuperior ; B 231 249 491 622 ;
|
||||
C -1 ; WX 600 ; N imacron ; B 95 0 543 565 ;
|
||||
C 128 ; WX 600 ; N Euro ; B 0 0 0 0 ;
|
||||
EndCharMetrics
|
||||
EndFontMetrics
|
|
@ -0,0 +1,344 @@
|
|||
StartFontMetrics 4.1
|
||||
Comment Copyright (c) 1989, 1990, 1991, 1992, 1993, 1997 Adobe Systems Incorporated. All Rights Reserved.
|
||||
Comment Creation Date: Thu May 1 17:27:09 1997
|
||||
Comment UniqueID 43050
|
||||
Comment VMusage 39754 50779
|
||||
FontName Courier
|
||||
FullName Courier
|
||||
FamilyName Courier
|
||||
Weight Medium
|
||||
ItalicAngle 0
|
||||
IsFixedPitch true
|
||||
CharacterSet ExtendedRoman
|
||||
FontBBox -23 -250 715 805
|
||||
UnderlinePosition -100
|
||||
UnderlineThickness 50
|
||||
Version 003.000
|
||||
Notice Copyright (c) 1989, 1990, 1991, 1992, 1993, 1997 Adobe Systems Incorporated. All Rights Reserved.
|
||||
EncodingScheme WinAnsiEncoding
|
||||
CapHeight 562
|
||||
XHeight 426
|
||||
Ascender 629
|
||||
Descender -157
|
||||
StdHW 51
|
||||
StdVW 51
|
||||
StartCharMetrics 317
|
||||
C 32 ; WX 600 ; N space ; B 0 0 0 0 ;
|
||||
C 160 ; WX 600 ; N space ; B 0 0 0 0 ;
|
||||
C 33 ; WX 600 ; N exclam ; B 236 -15 364 572 ;
|
||||
C 34 ; WX 600 ; N quotedbl ; B 187 328 413 562 ;
|
||||
C 35 ; WX 600 ; N numbersign ; B 93 -32 507 639 ;
|
||||
C 36 ; WX 600 ; N dollar ; B 105 -126 496 662 ;
|
||||
C 37 ; WX 600 ; N percent ; B 81 -15 518 622 ;
|
||||
C 38 ; WX 600 ; N ampersand ; B 63 -15 538 543 ;
|
||||
C 146 ; WX 600 ; N quoteright ; B 213 328 376 562 ;
|
||||
C 40 ; WX 600 ; N parenleft ; B 269 -108 440 622 ;
|
||||
C 41 ; WX 600 ; N parenright ; B 160 -108 331 622 ;
|
||||
C 42 ; WX 600 ; N asterisk ; B 116 257 484 607 ;
|
||||
C 43 ; WX 600 ; N plus ; B 80 44 520 470 ;
|
||||
C 44 ; WX 600 ; N comma ; B 181 -112 344 122 ;
|
||||
C 45 ; WX 600 ; N hyphen ; B 103 231 497 285 ;
|
||||
C 173 ; WX 600 ; N hyphen ; B 103 231 497 285 ;
|
||||
C 46 ; WX 600 ; N period ; B 229 -15 371 109 ;
|
||||
C 47 ; WX 600 ; N slash ; B 125 -80 475 629 ;
|
||||
C 48 ; WX 600 ; N zero ; B 106 -15 494 622 ;
|
||||
C 49 ; WX 600 ; N one ; B 96 0 505 622 ;
|
||||
C 50 ; WX 600 ; N two ; B 70 0 471 622 ;
|
||||
C 51 ; WX 600 ; N three ; B 75 -15 466 622 ;
|
||||
C 52 ; WX 600 ; N four ; B 78 0 500 622 ;
|
||||
C 53 ; WX 600 ; N five ; B 92 -15 497 607 ;
|
||||
C 54 ; WX 600 ; N six ; B 111 -15 497 622 ;
|
||||
C 55 ; WX 600 ; N seven ; B 82 0 483 607 ;
|
||||
C 56 ; WX 600 ; N eight ; B 102 -15 498 622 ;
|
||||
C 57 ; WX 600 ; N nine ; B 96 -15 489 622 ;
|
||||
C 58 ; WX 600 ; N colon ; B 229 -15 371 385 ;
|
||||
C 59 ; WX 600 ; N semicolon ; B 181 -112 371 385 ;
|
||||
C 60 ; WX 600 ; N less ; B 41 42 519 472 ;
|
||||
C 61 ; WX 600 ; N equal ; B 80 138 520 376 ;
|
||||
C 62 ; WX 600 ; N greater ; B 66 42 544 472 ;
|
||||
C 63 ; WX 600 ; N question ; B 129 -15 492 572 ;
|
||||
C 64 ; WX 600 ; N at ; B 77 -15 533 622 ;
|
||||
C 65 ; WX 600 ; N A ; B 3 0 597 562 ;
|
||||
C 66 ; WX 600 ; N B ; B 43 0 559 562 ;
|
||||
C 67 ; WX 600 ; N C ; B 41 -18 540 580 ;
|
||||
C 68 ; WX 600 ; N D ; B 43 0 574 562 ;
|
||||
C 69 ; WX 600 ; N E ; B 53 0 550 562 ;
|
||||
C 70 ; WX 600 ; N F ; B 53 0 545 562 ;
|
||||
C 71 ; WX 600 ; N G ; B 31 -18 575 580 ;
|
||||
C 72 ; WX 600 ; N H ; B 32 0 568 562 ;
|
||||
C 73 ; WX 600 ; N I ; B 96 0 504 562 ;
|
||||
C 74 ; WX 600 ; N J ; B 34 -18 566 562 ;
|
||||
C 75 ; WX 600 ; N K ; B 38 0 582 562 ;
|
||||
C 76 ; WX 600 ; N L ; B 47 0 554 562 ;
|
||||
C 77 ; WX 600 ; N M ; B 4 0 596 562 ;
|
||||
C 78 ; WX 600 ; N N ; B 7 -13 593 562 ;
|
||||
C 79 ; WX 600 ; N O ; B 43 -18 557 580 ;
|
||||
C 80 ; WX 600 ; N P ; B 79 0 558 562 ;
|
||||
C 81 ; WX 600 ; N Q ; B 43 -138 557 580 ;
|
||||
C 82 ; WX 600 ; N R ; B 38 0 588 562 ;
|
||||
C 83 ; WX 600 ; N S ; B 72 -20 529 580 ;
|
||||
C 84 ; WX 600 ; N T ; B 38 0 563 562 ;
|
||||
C 85 ; WX 600 ; N U ; B 17 -18 583 562 ;
|
||||
C 86 ; WX 600 ; N V ; B -4 -13 604 562 ;
|
||||
C 87 ; WX 600 ; N W ; B -3 -13 603 562 ;
|
||||
C 88 ; WX 600 ; N X ; B 23 0 577 562 ;
|
||||
C 89 ; WX 600 ; N Y ; B 24 0 576 562 ;
|
||||
C 90 ; WX 600 ; N Z ; B 86 0 514 562 ;
|
||||
C 91 ; WX 600 ; N bracketleft ; B 269 -108 442 622 ;
|
||||
C 92 ; WX 600 ; N backslash ; B 118 -80 482 629 ;
|
||||
C 93 ; WX 600 ; N bracketright ; B 158 -108 331 622 ;
|
||||
C 94 ; WX 600 ; N asciicircum ; B 94 354 506 622 ;
|
||||
C 95 ; WX 600 ; N underscore ; B 0 -125 600 -75 ;
|
||||
C 145 ; WX 600 ; N quoteleft ; B 224 328 387 562 ;
|
||||
C 97 ; WX 600 ; N a ; B 53 -15 559 441 ;
|
||||
C 98 ; WX 600 ; N b ; B 14 -15 575 629 ;
|
||||
C 99 ; WX 600 ; N c ; B 66 -15 529 441 ;
|
||||
C 100 ; WX 600 ; N d ; B 45 -15 591 629 ;
|
||||
C 101 ; WX 600 ; N e ; B 66 -15 548 441 ;
|
||||
C 102 ; WX 600 ; N f ; B 114 0 531 629 ; L i fi ; L l fl ;
|
||||
C 103 ; WX 600 ; N g ; B 45 -157 566 441 ;
|
||||
C 104 ; WX 600 ; N h ; B 18 0 582 629 ;
|
||||
C 105 ; WX 600 ; N i ; B 95 0 505 657 ;
|
||||
C 106 ; WX 600 ; N j ; B 82 -157 410 657 ;
|
||||
C 107 ; WX 600 ; N k ; B 43 0 580 629 ;
|
||||
C 108 ; WX 600 ; N l ; B 95 0 505 629 ;
|
||||
C 109 ; WX 600 ; N m ; B -5 0 605 441 ;
|
||||
C 110 ; WX 600 ; N n ; B 26 0 575 441 ;
|
||||
C 111 ; WX 600 ; N o ; B 62 -15 538 441 ;
|
||||
C 112 ; WX 600 ; N p ; B 9 -157 555 441 ;
|
||||
C 113 ; WX 600 ; N q ; B 45 -157 591 441 ;
|
||||
C 114 ; WX 600 ; N r ; B 60 0 559 441 ;
|
||||
C 115 ; WX 600 ; N s ; B 80 -15 513 441 ;
|
||||
C 116 ; WX 600 ; N t ; B 87 -15 530 561 ;
|
||||
C 117 ; WX 600 ; N u ; B 21 -15 562 426 ;
|
||||
C 118 ; WX 600 ; N v ; B 10 -10 590 426 ;
|
||||
C 119 ; WX 600 ; N w ; B -4 -10 604 426 ;
|
||||
C 120 ; WX 600 ; N x ; B 20 0 580 426 ;
|
||||
C 121 ; WX 600 ; N y ; B 7 -157 592 426 ;
|
||||
C 122 ; WX 600 ; N z ; B 99 0 502 426 ;
|
||||
C 123 ; WX 600 ; N braceleft ; B 182 -108 437 622 ;
|
||||
C 124 ; WX 600 ; N bar ; B 275 -250 326 750 ;
|
||||
C 125 ; WX 600 ; N braceright ; B 163 -108 418 622 ;
|
||||
C 126 ; WX 600 ; N asciitilde ; B 63 197 540 320 ;
|
||||
C 161 ; WX 600 ; N exclamdown ; B 236 -157 364 430 ;
|
||||
C 162 ; WX 600 ; N cent ; B 96 -49 500 614 ;
|
||||
C 163 ; WX 600 ; N sterling ; B 84 -21 521 611 ;
|
||||
C -1 ; WX 600 ; N fraction ; B 92 -57 509 665 ;
|
||||
C 165 ; WX 600 ; N yen ; B 26 0 574 562 ;
|
||||
C 131 ; WX 600 ; N florin ; B 4 -143 539 622 ;
|
||||
C 167 ; WX 600 ; N section ; B 113 -78 488 580 ;
|
||||
C 164 ; WX 600 ; N currency ; B 73 58 527 506 ;
|
||||
C 39 ; WX 600 ; N quotesingle ; B 259 328 341 562 ;
|
||||
C 147 ; WX 600 ; N quotedblleft ; B 143 328 471 562 ;
|
||||
C 171 ; WX 600 ; N guillemotleft ; B 37 70 563 446 ;
|
||||
C 139 ; WX 600 ; N guilsinglleft ; B 149 70 451 446 ;
|
||||
C 155 ; WX 600 ; N guilsinglright ; B 149 70 451 446 ;
|
||||
C -1 ; WX 600 ; N fi ; B 3 0 597 629 ;
|
||||
C -1 ; WX 600 ; N fl ; B 3 0 597 629 ;
|
||||
C 150 ; WX 600 ; N endash ; B 75 231 525 285 ;
|
||||
C 134 ; WX 600 ; N dagger ; B 141 -78 459 580 ;
|
||||
C 135 ; WX 600 ; N daggerdbl ; B 141 -78 459 580 ;
|
||||
C 183 ; WX 600 ; N periodcentered ; B 222 189 378 327 ;
|
||||
C 182 ; WX 600 ; N paragraph ; B 50 -78 511 562 ;
|
||||
C 149 ; WX 600 ; N bullet ; B 172 130 428 383 ;
|
||||
C 130 ; WX 600 ; N quotesinglbase ; B 213 -134 376 100 ;
|
||||
C 132 ; WX 600 ; N quotedblbase ; B 143 -134 457 100 ;
|
||||
C 148 ; WX 600 ; N quotedblright ; B 143 328 457 562 ;
|
||||
C 187 ; WX 600 ; N guillemotright ; B 37 70 563 446 ;
|
||||
C 133 ; WX 600 ; N ellipsis ; B 37 -15 563 111 ;
|
||||
C 137 ; WX 600 ; N perthousand ; B 3 -15 600 622 ;
|
||||
C 191 ; WX 600 ; N questiondown ; B 108 -157 471 430 ;
|
||||
C 96 ; WX 600 ; N grave ; B 151 497 378 672 ;
|
||||
C 180 ; WX 600 ; N acute ; B 242 497 469 672 ;
|
||||
C 136 ; WX 600 ; N circumflex ; B 124 477 476 654 ;
|
||||
C 152 ; WX 600 ; N tilde ; B 105 489 503 606 ;
|
||||
C 175 ; WX 600 ; N macron ; B 120 525 480 565 ;
|
||||
C -1 ; WX 600 ; N breve ; B 153 501 447 609 ;
|
||||
C -1 ; WX 600 ; N dotaccent ; B 249 537 352 640 ;
|
||||
C 168 ; WX 600 ; N dieresis ; B 148 537 453 640 ;
|
||||
C -1 ; WX 600 ; N ring ; B 218 463 382 627 ;
|
||||
C 184 ; WX 600 ; N cedilla ; B 224 -151 362 10 ;
|
||||
C -1 ; WX 600 ; N hungarumlaut ; B 133 497 540 672 ;
|
||||
C -1 ; WX 600 ; N ogonek ; B 211 -172 407 4 ;
|
||||
C -1 ; WX 600 ; N caron ; B 124 492 476 669 ;
|
||||
C 151 ; WX 600 ; N emdash ; B 0 231 600 285 ;
|
||||
C 198 ; WX 600 ; N AE ; B 3 0 550 562 ;
|
||||
C 170 ; WX 600 ; N ordfeminine ; B 156 249 442 580 ;
|
||||
C -1 ; WX 600 ; N Lslash ; B 47 0 554 562 ;
|
||||
C 216 ; WX 600 ; N Oslash ; B 43 -80 557 629 ;
|
||||
C 140 ; WX 600 ; N OE ; B 7 0 567 562 ;
|
||||
C 186 ; WX 600 ; N ordmasculine ; B 157 249 443 580 ;
|
||||
C 230 ; WX 600 ; N ae ; B 19 -15 570 441 ;
|
||||
C -1 ; WX 600 ; N dotlessi ; B 95 0 505 426 ;
|
||||
C -1 ; WX 600 ; N lslash ; B 95 0 505 629 ;
|
||||
C 248 ; WX 600 ; N oslash ; B 62 -80 538 506 ;
|
||||
C 156 ; WX 600 ; N oe ; B 19 -15 559 441 ;
|
||||
C 223 ; WX 600 ; N germandbls ; B 48 -15 588 629 ;
|
||||
C 207 ; WX 600 ; N Idieresis ; B 96 0 504 753 ;
|
||||
C 233 ; WX 600 ; N eacute ; B 66 -15 548 672 ;
|
||||
C -1 ; WX 600 ; N abreve ; B 53 -15 559 609 ;
|
||||
C -1 ; WX 600 ; N uhungarumlaut ; B 21 -15 580 672 ;
|
||||
C -1 ; WX 600 ; N ecaron ; B 66 -15 548 669 ;
|
||||
C 159 ; WX 600 ; N Ydieresis ; B 24 0 576 753 ;
|
||||
C 247 ; WX 600 ; N divide ; B 87 48 513 467 ;
|
||||
C 221 ; WX 600 ; N Yacute ; B 24 0 576 805 ;
|
||||
C 194 ; WX 600 ; N Acircumflex ; B 3 0 597 787 ;
|
||||
C 225 ; WX 600 ; N aacute ; B 53 -15 559 672 ;
|
||||
C 219 ; WX 600 ; N Ucircumflex ; B 17 -18 583 787 ;
|
||||
C 253 ; WX 600 ; N yacute ; B 7 -157 592 672 ;
|
||||
C -1 ; WX 600 ; N scommaaccent ; B 80 -250 513 441 ;
|
||||
C 234 ; WX 600 ; N ecircumflex ; B 66 -15 548 654 ;
|
||||
C -1 ; WX 600 ; N Uring ; B 17 -18 583 760 ;
|
||||
C 220 ; WX 600 ; N Udieresis ; B 17 -18 583 753 ;
|
||||
C -1 ; WX 600 ; N aogonek ; B 53 -172 587 441 ;
|
||||
C 218 ; WX 600 ; N Uacute ; B 17 -18 583 805 ;
|
||||
C -1 ; WX 600 ; N uogonek ; B 21 -172 590 426 ;
|
||||
C 203 ; WX 600 ; N Edieresis ; B 53 0 550 753 ;
|
||||
C -1 ; WX 600 ; N Dcroat ; B 30 0 574 562 ;
|
||||
C -1 ; WX 600 ; N commaaccent ; B 198 -250 335 -58 ;
|
||||
C 169 ; WX 600 ; N copyright ; B 0 -18 600 580 ;
|
||||
C -1 ; WX 600 ; N Emacron ; B 53 0 550 698 ;
|
||||
C -1 ; WX 600 ; N ccaron ; B 66 -15 529 669 ;
|
||||
C 229 ; WX 600 ; N aring ; B 53 -15 559 627 ;
|
||||
C -1 ; WX 600 ; N Ncommaaccent ; B 7 -250 593 562 ;
|
||||
C -1 ; WX 600 ; N lacute ; B 95 0 505 805 ;
|
||||
C 224 ; WX 600 ; N agrave ; B 53 -15 559 672 ;
|
||||
C -1 ; WX 600 ; N Tcommaaccent ; B 38 -250 563 562 ;
|
||||
C -1 ; WX 600 ; N Cacute ; B 41 -18 540 805 ;
|
||||
C 227 ; WX 600 ; N atilde ; B 53 -15 559 606 ;
|
||||
C -1 ; WX 600 ; N Edotaccent ; B 53 0 550 753 ;
|
||||
C 154 ; WX 600 ; N scaron ; B 80 -15 513 669 ;
|
||||
C -1 ; WX 600 ; N scedilla ; B 80 -151 513 441 ;
|
||||
C 237 ; WX 600 ; N iacute ; B 95 0 505 672 ;
|
||||
C -1 ; WX 600 ; N lozenge ; B 18 0 443 706 ;
|
||||
C -1 ; WX 600 ; N Rcaron ; B 38 0 588 802 ;
|
||||
C -1 ; WX 600 ; N Gcommaaccent ; B 31 -250 575 580 ;
|
||||
C 251 ; WX 600 ; N ucircumflex ; B 21 -15 562 654 ;
|
||||
C 226 ; WX 600 ; N acircumflex ; B 53 -15 559 654 ;
|
||||
C -1 ; WX 600 ; N Amacron ; B 3 0 597 698 ;
|
||||
C -1 ; WX 600 ; N rcaron ; B 60 0 559 669 ;
|
||||
C 231 ; WX 600 ; N ccedilla ; B 66 -151 529 441 ;
|
||||
C -1 ; WX 600 ; N Zdotaccent ; B 86 0 514 753 ;
|
||||
C 222 ; WX 600 ; N Thorn ; B 79 0 538 562 ;
|
||||
C -1 ; WX 600 ; N Omacron ; B 43 -18 557 698 ;
|
||||
C -1 ; WX 600 ; N Racute ; B 38 0 588 805 ;
|
||||
C -1 ; WX 600 ; N Sacute ; B 72 -20 529 805 ;
|
||||
C -1 ; WX 600 ; N dcaron ; B 45 -15 715 629 ;
|
||||
C -1 ; WX 600 ; N Umacron ; B 17 -18 583 698 ;
|
||||
C -1 ; WX 600 ; N uring ; B 21 -15 562 627 ;
|
||||
C 179 ; WX 600 ; N threesuperior ; B 155 240 406 622 ;
|
||||
C 210 ; WX 600 ; N Ograve ; B 43 -18 557 805 ;
|
||||
C 192 ; WX 600 ; N Agrave ; B 3 0 597 805 ;
|
||||
C -1 ; WX 600 ; N Abreve ; B 3 0 597 732 ;
|
||||
C 215 ; WX 600 ; N multiply ; B 87 43 515 470 ;
|
||||
C 250 ; WX 600 ; N uacute ; B 21 -15 562 672 ;
|
||||
C -1 ; WX 600 ; N Tcaron ; B 38 0 563 802 ;
|
||||
C -1 ; WX 600 ; N partialdiff ; B 17 -38 459 710 ;
|
||||
C 255 ; WX 600 ; N ydieresis ; B 7 -157 592 620 ;
|
||||
C -1 ; WX 600 ; N Nacute ; B 7 -13 593 805 ;
|
||||
C 238 ; WX 600 ; N icircumflex ; B 94 0 505 654 ;
|
||||
C 202 ; WX 600 ; N Ecircumflex ; B 53 0 550 787 ;
|
||||
C 228 ; WX 600 ; N adieresis ; B 53 -15 559 620 ;
|
||||
C 235 ; WX 600 ; N edieresis ; B 66 -15 548 620 ;
|
||||
C -1 ; WX 600 ; N cacute ; B 66 -15 529 672 ;
|
||||
C -1 ; WX 600 ; N nacute ; B 26 0 575 672 ;
|
||||
C -1 ; WX 600 ; N umacron ; B 21 -15 562 565 ;
|
||||
C -1 ; WX 600 ; N Ncaron ; B 7 -13 593 802 ;
|
||||
C 205 ; WX 600 ; N Iacute ; B 96 0 504 805 ;
|
||||
C 177 ; WX 600 ; N plusminus ; B 87 44 513 558 ;
|
||||
C 166 ; WX 600 ; N brokenbar ; B 275 -175 326 675 ;
|
||||
C 174 ; WX 600 ; N registered ; B 0 -18 600 580 ;
|
||||
C -1 ; WX 600 ; N Gbreve ; B 31 -18 575 732 ;
|
||||
C -1 ; WX 600 ; N Idotaccent ; B 96 0 504 753 ;
|
||||
C -1 ; WX 600 ; N summation ; B 15 -10 585 706 ;
|
||||
C 200 ; WX 600 ; N Egrave ; B 53 0 550 805 ;
|
||||
C -1 ; WX 600 ; N racute ; B 60 0 559 672 ;
|
||||
C -1 ; WX 600 ; N omacron ; B 62 -15 538 565 ;
|
||||
C -1 ; WX 600 ; N Zacute ; B 86 0 514 805 ;
|
||||
C 142 ; WX 600 ; N Zcaron ; B 86 0 514 802 ;
|
||||
C -1 ; WX 600 ; N greaterequal ; B 98 0 502 710 ;
|
||||
C 208 ; WX 600 ; N Eth ; B 30 0 574 562 ;
|
||||
C 199 ; WX 600 ; N Ccedilla ; B 41 -151 540 580 ;
|
||||
C -1 ; WX 600 ; N lcommaaccent ; B 95 -250 505 629 ;
|
||||
C -1 ; WX 600 ; N tcaron ; B 87 -15 530 717 ;
|
||||
C -1 ; WX 600 ; N eogonek ; B 66 -172 548 441 ;
|
||||
C -1 ; WX 600 ; N Uogonek ; B 17 -172 583 562 ;
|
||||
C 193 ; WX 600 ; N Aacute ; B 3 0 597 805 ;
|
||||
C 196 ; WX 600 ; N Adieresis ; B 3 0 597 753 ;
|
||||
C 232 ; WX 600 ; N egrave ; B 66 -15 548 672 ;
|
||||
C -1 ; WX 600 ; N zacute ; B 99 0 502 672 ;
|
||||
C -1 ; WX 600 ; N iogonek ; B 95 -172 505 657 ;
|
||||
C 211 ; WX 600 ; N Oacute ; B 43 -18 557 805 ;
|
||||
C 243 ; WX 600 ; N oacute ; B 62 -15 538 672 ;
|
||||
C -1 ; WX 600 ; N amacron ; B 53 -15 559 565 ;
|
||||
C -1 ; WX 600 ; N sacute ; B 80 -15 513 672 ;
|
||||
C 239 ; WX 600 ; N idieresis ; B 95 0 505 620 ;
|
||||
C 212 ; WX 600 ; N Ocircumflex ; B 43 -18 557 787 ;
|
||||
C 217 ; WX 600 ; N Ugrave ; B 17 -18 583 805 ;
|
||||
C -1 ; WX 600 ; N Delta ; B 6 0 598 688 ;
|
||||
C 254 ; WX 600 ; N thorn ; B -6 -157 555 629 ;
|
||||
C 178 ; WX 600 ; N twosuperior ; B 177 249 424 622 ;
|
||||
C 214 ; WX 600 ; N Odieresis ; B 43 -18 557 753 ;
|
||||
C 181 ; WX 600 ; N mu ; B 21 -157 562 426 ;
|
||||
C 236 ; WX 600 ; N igrave ; B 95 0 505 672 ;
|
||||
C -1 ; WX 600 ; N ohungarumlaut ; B 62 -15 580 672 ;
|
||||
C -1 ; WX 600 ; N Eogonek ; B 53 -172 561 562 ;
|
||||
C -1 ; WX 600 ; N dcroat ; B 45 -15 591 629 ;
|
||||
C 190 ; WX 600 ; N threequarters ; B 8 -56 593 666 ;
|
||||
C -1 ; WX 600 ; N Scedilla ; B 72 -151 529 580 ;
|
||||
C -1 ; WX 600 ; N lcaron ; B 95 0 533 629 ;
|
||||
C -1 ; WX 600 ; N Kcommaaccent ; B 38 -250 582 562 ;
|
||||
C -1 ; WX 600 ; N Lacute ; B 47 0 554 805 ;
|
||||
C 153 ; WX 600 ; N trademark ; B -23 263 623 562 ;
|
||||
C -1 ; WX 600 ; N edotaccent ; B 66 -15 548 620 ;
|
||||
C 204 ; WX 600 ; N Igrave ; B 96 0 504 805 ;
|
||||
C -1 ; WX 600 ; N Imacron ; B 96 0 504 698 ;
|
||||
C -1 ; WX 600 ; N Lcaron ; B 47 0 554 562 ;
|
||||
C 189 ; WX 600 ; N onehalf ; B 0 -57 611 665 ;
|
||||
C -1 ; WX 600 ; N lessequal ; B 98 0 502 710 ;
|
||||
C 244 ; WX 600 ; N ocircumflex ; B 62 -15 538 654 ;
|
||||
C 241 ; WX 600 ; N ntilde ; B 26 0 575 606 ;
|
||||
C -1 ; WX 600 ; N Uhungarumlaut ; B 17 -18 590 805 ;
|
||||
C 201 ; WX 600 ; N Eacute ; B 53 0 550 805 ;
|
||||
C -1 ; WX 600 ; N emacron ; B 66 -15 548 565 ;
|
||||
C -1 ; WX 600 ; N gbreve ; B 45 -157 566 609 ;
|
||||
C 188 ; WX 600 ; N onequarter ; B 0 -57 600 665 ;
|
||||
C 138 ; WX 600 ; N Scaron ; B 72 -20 529 802 ;
|
||||
C -1 ; WX 600 ; N Scommaaccent ; B 72 -250 529 580 ;
|
||||
C -1 ; WX 600 ; N Ohungarumlaut ; B 43 -18 580 805 ;
|
||||
C 176 ; WX 600 ; N degree ; B 123 269 477 622 ;
|
||||
C 242 ; WX 600 ; N ograve ; B 62 -15 538 672 ;
|
||||
C -1 ; WX 600 ; N Ccaron ; B 41 -18 540 802 ;
|
||||
C 249 ; WX 600 ; N ugrave ; B 21 -15 562 672 ;
|
||||
C -1 ; WX 600 ; N radical ; B 3 -15 597 792 ;
|
||||
C -1 ; WX 600 ; N Dcaron ; B 43 0 574 802 ;
|
||||
C -1 ; WX 600 ; N rcommaaccent ; B 60 -250 559 441 ;
|
||||
C 209 ; WX 600 ; N Ntilde ; B 7 -13 593 729 ;
|
||||
C 245 ; WX 600 ; N otilde ; B 62 -15 538 606 ;
|
||||
C -1 ; WX 600 ; N Rcommaaccent ; B 38 -250 588 562 ;
|
||||
C -1 ; WX 600 ; N Lcommaaccent ; B 47 -250 554 562 ;
|
||||
C 195 ; WX 600 ; N Atilde ; B 3 0 597 729 ;
|
||||
C -1 ; WX 600 ; N Aogonek ; B 3 -172 608 562 ;
|
||||
C 197 ; WX 600 ; N Aring ; B 3 0 597 750 ;
|
||||
C 213 ; WX 600 ; N Otilde ; B 43 -18 557 729 ;
|
||||
C -1 ; WX 600 ; N zdotaccent ; B 99 0 502 620 ;
|
||||
C -1 ; WX 600 ; N Ecaron ; B 53 0 550 802 ;
|
||||
C -1 ; WX 600 ; N Iogonek ; B 96 -172 504 562 ;
|
||||
C -1 ; WX 600 ; N kcommaaccent ; B 43 -250 580 629 ;
|
||||
C -1 ; WX 600 ; N minus ; B 80 232 520 283 ;
|
||||
C 206 ; WX 600 ; N Icircumflex ; B 96 0 504 787 ;
|
||||
C -1 ; WX 600 ; N ncaron ; B 26 0 575 669 ;
|
||||
C -1 ; WX 600 ; N tcommaaccent ; B 87 -250 530 561 ;
|
||||
C 172 ; WX 600 ; N logicalnot ; B 87 108 513 369 ;
|
||||
C 246 ; WX 600 ; N odieresis ; B 62 -15 538 620 ;
|
||||
C 252 ; WX 600 ; N udieresis ; B 21 -15 562 620 ;
|
||||
C -1 ; WX 600 ; N notequal ; B 15 -16 540 529 ;
|
||||
C -1 ; WX 600 ; N gcommaaccent ; B 45 -157 566 708 ;
|
||||
C 240 ; WX 600 ; N eth ; B 62 -15 538 629 ;
|
||||
C 158 ; WX 600 ; N zcaron ; B 99 0 502 669 ;
|
||||
C -1 ; WX 600 ; N ncommaaccent ; B 26 -250 575 441 ;
|
||||
C 185 ; WX 600 ; N onesuperior ; B 172 249 428 622 ;
|
||||
C -1 ; WX 600 ; N imacron ; B 95 0 505 565 ;
|
||||
C 128 ; WX 600 ; N Euro ; B 0 0 0 0 ;
|
||||
EndCharMetrics
|
||||
EndFontMetrics
|
Binary file not shown.
File diff suppressed because it is too large
Load Diff
Binary file not shown.
File diff suppressed because it is too large
Load Diff
Binary file not shown.
File diff suppressed because it is too large
Load Diff
Binary file not shown.
File diff suppressed because it is too large
Load Diff
Binary file not shown.
File diff suppressed because it is too large
Load Diff
Binary file not shown.
File diff suppressed because it is too large
Load Diff
Binary file not shown.
File diff suppressed because it is too large
Load Diff
Binary file not shown.
File diff suppressed because it is too large
Load Diff
Binary file not shown.
File diff suppressed because it is too large
Load Diff
Binary file not shown.
File diff suppressed because it is too large
Load Diff
Binary file not shown.
File diff suppressed because it is too large
Load Diff
Binary file not shown.
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
|
@ -0,0 +1,213 @@
|
|||
StartFontMetrics 4.1
|
||||
Comment Copyright (c) 1985, 1987, 1989, 1990, 1997 Adobe Systems Incorporated. All rights reserved.
|
||||
Comment Creation Date: Thu May 1 15:12:25 1997
|
||||
Comment UniqueID 43064
|
||||
Comment VMusage 30820 39997
|
||||
FontName Symbol
|
||||
FullName Symbol
|
||||
FamilyName Symbol
|
||||
Weight Medium
|
||||
ItalicAngle 0
|
||||
IsFixedPitch false
|
||||
CharacterSet Special
|
||||
FontBBox -180 -293 1090 1010
|
||||
UnderlinePosition -100
|
||||
UnderlineThickness 50
|
||||
Version 001.008
|
||||
Notice Copyright (c) 1985, 1987, 1989, 1990, 1997 Adobe Systems Incorporated. All rights reserved.
|
||||
EncodingScheme FontSpecific
|
||||
StdHW 92
|
||||
StdVW 85
|
||||
StartCharMetrics 190
|
||||
C 32 ; WX 250 ; N space ; B 0 0 0 0 ;
|
||||
C 33 ; WX 333 ; N exclam ; B 128 -17 240 672 ;
|
||||
C 34 ; WX 713 ; N universal ; B 31 0 681 705 ;
|
||||
C 35 ; WX 500 ; N numbersign ; B 20 -16 481 673 ;
|
||||
C 36 ; WX 549 ; N existential ; B 25 0 478 707 ;
|
||||
C 37 ; WX 833 ; N percent ; B 63 -36 771 655 ;
|
||||
C 38 ; WX 778 ; N ampersand ; B 41 -18 750 661 ;
|
||||
C 39 ; WX 439 ; N suchthat ; B 48 -17 414 500 ;
|
||||
C 40 ; WX 333 ; N parenleft ; B 53 -191 300 673 ;
|
||||
C 41 ; WX 333 ; N parenright ; B 30 -191 277 673 ;
|
||||
C 42 ; WX 500 ; N asteriskmath ; B 65 134 427 551 ;
|
||||
C 43 ; WX 549 ; N plus ; B 10 0 539 533 ;
|
||||
C 44 ; WX 250 ; N comma ; B 56 -152 194 104 ;
|
||||
C 45 ; WX 549 ; N minus ; B 11 233 535 288 ;
|
||||
C 46 ; WX 250 ; N period ; B 69 -17 181 95 ;
|
||||
C 47 ; WX 278 ; N slash ; B 0 -18 254 646 ;
|
||||
C 48 ; WX 500 ; N zero ; B 24 -14 476 685 ;
|
||||
C 49 ; WX 500 ; N one ; B 117 0 390 673 ;
|
||||
C 50 ; WX 500 ; N two ; B 25 0 475 685 ;
|
||||
C 51 ; WX 500 ; N three ; B 43 -14 435 685 ;
|
||||
C 52 ; WX 500 ; N four ; B 15 0 469 685 ;
|
||||
C 53 ; WX 500 ; N five ; B 32 -14 445 690 ;
|
||||
C 54 ; WX 500 ; N six ; B 34 -14 468 685 ;
|
||||
C 55 ; WX 500 ; N seven ; B 24 -16 448 673 ;
|
||||
C 56 ; WX 500 ; N eight ; B 56 -14 445 685 ;
|
||||
C 57 ; WX 500 ; N nine ; B 30 -18 459 685 ;
|
||||
C 58 ; WX 278 ; N colon ; B 81 -17 193 460 ;
|
||||
C 59 ; WX 278 ; N semicolon ; B 83 -152 221 460 ;
|
||||
C 60 ; WX 549 ; N less ; B 26 0 523 522 ;
|
||||
C 61 ; WX 549 ; N equal ; B 11 141 537 390 ;
|
||||
C 62 ; WX 549 ; N greater ; B 26 0 523 522 ;
|
||||
C 63 ; WX 444 ; N question ; B 70 -17 412 686 ;
|
||||
C 64 ; WX 549 ; N congruent ; B 11 0 537 475 ;
|
||||
C 65 ; WX 722 ; N Alpha ; B 4 0 684 673 ;
|
||||
C 66 ; WX 667 ; N Beta ; B 29 0 592 673 ;
|
||||
C 67 ; WX 722 ; N Chi ; B -9 0 704 673 ;
|
||||
C 68 ; WX 612 ; N Delta ; B 6 0 608 688 ;
|
||||
C 69 ; WX 611 ; N Epsilon ; B 32 0 617 673 ;
|
||||
C 70 ; WX 763 ; N Phi ; B 26 0 741 673 ;
|
||||
C 71 ; WX 603 ; N Gamma ; B 24 0 609 673 ;
|
||||
C 72 ; WX 722 ; N Eta ; B 39 0 729 673 ;
|
||||
C 73 ; WX 333 ; N Iota ; B 32 0 316 673 ;
|
||||
C 74 ; WX 631 ; N theta1 ; B 18 -18 623 689 ;
|
||||
C 75 ; WX 722 ; N Kappa ; B 35 0 722 673 ;
|
||||
C 76 ; WX 686 ; N Lambda ; B 6 0 680 688 ;
|
||||
C 77 ; WX 889 ; N Mu ; B 28 0 887 673 ;
|
||||
C 78 ; WX 722 ; N Nu ; B 29 -8 720 673 ;
|
||||
C 79 ; WX 722 ; N Omicron ; B 41 -17 715 685 ;
|
||||
C 80 ; WX 768 ; N Pi ; B 25 0 745 673 ;
|
||||
C 81 ; WX 741 ; N Theta ; B 41 -17 715 685 ;
|
||||
C 82 ; WX 556 ; N Rho ; B 28 0 563 673 ;
|
||||
C 83 ; WX 592 ; N Sigma ; B 5 0 589 673 ;
|
||||
C 84 ; WX 611 ; N Tau ; B 33 0 607 673 ;
|
||||
C 85 ; WX 690 ; N Upsilon ; B -8 0 694 673 ;
|
||||
C 86 ; WX 439 ; N sigma1 ; B 40 -233 436 500 ;
|
||||
C 87 ; WX 768 ; N Omega ; B 34 0 736 688 ;
|
||||
C 88 ; WX 645 ; N Xi ; B 40 0 599 673 ;
|
||||
C 89 ; WX 795 ; N Psi ; B 15 0 781 684 ;
|
||||
C 90 ; WX 611 ; N Zeta ; B 44 0 636 673 ;
|
||||
C 91 ; WX 333 ; N bracketleft ; B 86 -155 299 674 ;
|
||||
C 92 ; WX 863 ; N therefore ; B 163 0 701 487 ;
|
||||
C 93 ; WX 333 ; N bracketright ; B 33 -155 246 674 ;
|
||||
C 94 ; WX 658 ; N perpendicular ; B 15 0 652 674 ;
|
||||
C 95 ; WX 500 ; N underscore ; B -2 -125 502 -75 ;
|
||||
C 96 ; WX 500 ; N radicalex ; B 480 881 1090 917 ;
|
||||
C 97 ; WX 631 ; N alpha ; B 41 -18 622 500 ;
|
||||
C 98 ; WX 549 ; N beta ; B 61 -223 515 741 ;
|
||||
C 99 ; WX 549 ; N chi ; B 12 -231 522 499 ;
|
||||
C 100 ; WX 494 ; N delta ; B 40 -19 481 740 ;
|
||||
C 101 ; WX 439 ; N epsilon ; B 22 -19 427 502 ;
|
||||
C 102 ; WX 521 ; N phi ; B 28 -224 492 673 ;
|
||||
C 103 ; WX 411 ; N gamma ; B 5 -225 484 499 ;
|
||||
C 104 ; WX 603 ; N eta ; B 0 -202 527 514 ;
|
||||
C 105 ; WX 329 ; N iota ; B 0 -17 301 503 ;
|
||||
C 106 ; WX 603 ; N phi1 ; B 36 -224 587 499 ;
|
||||
C 107 ; WX 549 ; N kappa ; B 33 0 558 501 ;
|
||||
C 108 ; WX 549 ; N lambda ; B 24 -17 548 739 ;
|
||||
C 109 ; WX 576 ; N mu ; B 33 -223 567 500 ;
|
||||
C 110 ; WX 521 ; N nu ; B -9 -16 475 507 ;
|
||||
C 111 ; WX 549 ; N omicron ; B 35 -19 501 499 ;
|
||||
C 112 ; WX 549 ; N pi ; B 10 -19 530 487 ;
|
||||
C 113 ; WX 521 ; N theta ; B 43 -17 485 690 ;
|
||||
C 114 ; WX 549 ; N rho ; B 50 -230 490 499 ;
|
||||
C 115 ; WX 603 ; N sigma ; B 30 -21 588 500 ;
|
||||
C 116 ; WX 439 ; N tau ; B 10 -19 418 500 ;
|
||||
C 117 ; WX 576 ; N upsilon ; B 7 -18 535 507 ;
|
||||
C 118 ; WX 713 ; N omega1 ; B 12 -18 671 583 ;
|
||||
C 119 ; WX 686 ; N omega ; B 42 -17 684 500 ;
|
||||
C 120 ; WX 493 ; N xi ; B 27 -224 469 766 ;
|
||||
C 121 ; WX 686 ; N psi ; B 12 -228 701 500 ;
|
||||
C 122 ; WX 494 ; N zeta ; B 60 -225 467 756 ;
|
||||
C 123 ; WX 480 ; N braceleft ; B 58 -183 397 673 ;
|
||||
C 124 ; WX 200 ; N bar ; B 65 -293 135 707 ;
|
||||
C 125 ; WX 480 ; N braceright ; B 79 -183 418 673 ;
|
||||
C 126 ; WX 549 ; N similar ; B 17 203 529 307 ;
|
||||
C 160 ; WX 750 ; N Euro ; B 20 -12 714 685 ;
|
||||
C 161 ; WX 620 ; N Upsilon1 ; B -2 0 610 685 ;
|
||||
C 162 ; WX 247 ; N minute ; B 27 459 228 735 ;
|
||||
C 163 ; WX 549 ; N lessequal ; B 29 0 526 639 ;
|
||||
C 164 ; WX 167 ; N fraction ; B -180 -12 340 677 ;
|
||||
C 165 ; WX 713 ; N infinity ; B 26 124 688 404 ;
|
||||
C 166 ; WX 500 ; N florin ; B 2 -193 494 686 ;
|
||||
C 167 ; WX 753 ; N club ; B 86 -26 660 533 ;
|
||||
C 168 ; WX 753 ; N diamond ; B 142 -36 600 550 ;
|
||||
C 169 ; WX 753 ; N heart ; B 117 -33 631 532 ;
|
||||
C 170 ; WX 753 ; N spade ; B 113 -36 629 548 ;
|
||||
C 171 ; WX 1042 ; N arrowboth ; B 24 -15 1024 511 ;
|
||||
C 172 ; WX 987 ; N arrowleft ; B 32 -15 942 511 ;
|
||||
C 173 ; WX 603 ; N arrowup ; B 45 0 571 910 ;
|
||||
C 174 ; WX 987 ; N arrowright ; B 49 -15 959 511 ;
|
||||
C 175 ; WX 603 ; N arrowdown ; B 45 -22 571 888 ;
|
||||
C 176 ; WX 400 ; N degree ; B 50 385 350 685 ;
|
||||
C 177 ; WX 549 ; N plusminus ; B 10 0 539 645 ;
|
||||
C 178 ; WX 411 ; N second ; B 20 459 413 737 ;
|
||||
C 179 ; WX 549 ; N greaterequal ; B 29 0 526 639 ;
|
||||
C 180 ; WX 549 ; N multiply ; B 17 8 533 524 ;
|
||||
C 181 ; WX 713 ; N proportional ; B 27 123 639 404 ;
|
||||
C 182 ; WX 494 ; N partialdiff ; B 26 -20 462 746 ;
|
||||
C 183 ; WX 460 ; N bullet ; B 50 113 410 473 ;
|
||||
C 184 ; WX 549 ; N divide ; B 10 71 536 456 ;
|
||||
C 185 ; WX 549 ; N notequal ; B 15 -25 540 549 ;
|
||||
C 186 ; WX 549 ; N equivalence ; B 14 82 538 443 ;
|
||||
C 187 ; WX 549 ; N approxequal ; B 14 135 527 394 ;
|
||||
C 188 ; WX 1000 ; N ellipsis ; B 111 -17 889 95 ;
|
||||
C 189 ; WX 603 ; N arrowvertex ; B 280 -120 336 1010 ;
|
||||
C 190 ; WX 1000 ; N arrowhorizex ; B -60 220 1050 276 ;
|
||||
C 191 ; WX 658 ; N carriagereturn ; B 15 -16 602 629 ;
|
||||
C 192 ; WX 823 ; N aleph ; B 175 -18 661 658 ;
|
||||
C 193 ; WX 686 ; N Ifraktur ; B 10 -53 578 740 ;
|
||||
C 194 ; WX 795 ; N Rfraktur ; B 26 -15 759 734 ;
|
||||
C 195 ; WX 987 ; N weierstrass ; B 159 -211 870 573 ;
|
||||
C 196 ; WX 768 ; N circlemultiply ; B 43 -17 733 673 ;
|
||||
C 197 ; WX 768 ; N circleplus ; B 43 -15 733 675 ;
|
||||
C 198 ; WX 823 ; N emptyset ; B 39 -24 781 719 ;
|
||||
C 199 ; WX 768 ; N intersection ; B 40 0 732 509 ;
|
||||
C 200 ; WX 768 ; N union ; B 40 -17 732 492 ;
|
||||
C 201 ; WX 713 ; N propersuperset ; B 20 0 673 470 ;
|
||||
C 202 ; WX 713 ; N reflexsuperset ; B 20 -125 673 470 ;
|
||||
C 203 ; WX 713 ; N notsubset ; B 36 -70 690 540 ;
|
||||
C 204 ; WX 713 ; N propersubset ; B 37 0 690 470 ;
|
||||
C 205 ; WX 713 ; N reflexsubset ; B 37 -125 690 470 ;
|
||||
C 206 ; WX 713 ; N element ; B 45 0 505 468 ;
|
||||
C 207 ; WX 713 ; N notelement ; B 45 -58 505 555 ;
|
||||
C 208 ; WX 768 ; N angle ; B 26 0 738 673 ;
|
||||
C 209 ; WX 713 ; N gradient ; B 36 -19 681 718 ;
|
||||
C 210 ; WX 790 ; N registerserif ; B 50 -17 740 673 ;
|
||||
C 211 ; WX 790 ; N copyrightserif ; B 51 -15 741 675 ;
|
||||
C 212 ; WX 890 ; N trademarkserif ; B 18 293 855 673 ;
|
||||
C 213 ; WX 823 ; N product ; B 25 -101 803 751 ;
|
||||
C 214 ; WX 549 ; N radical ; B 10 -38 515 917 ;
|
||||
C 215 ; WX 250 ; N dotmath ; B 69 210 169 310 ;
|
||||
C 216 ; WX 713 ; N logicalnot ; B 15 0 680 288 ;
|
||||
C 217 ; WX 603 ; N logicaland ; B 23 0 583 454 ;
|
||||
C 218 ; WX 603 ; N logicalor ; B 30 0 578 477 ;
|
||||
C 219 ; WX 1042 ; N arrowdblboth ; B 27 -20 1023 510 ;
|
||||
C 220 ; WX 987 ; N arrowdblleft ; B 30 -15 939 513 ;
|
||||
C 221 ; WX 603 ; N arrowdblup ; B 39 2 567 911 ;
|
||||
C 222 ; WX 987 ; N arrowdblright ; B 45 -20 954 508 ;
|
||||
C 223 ; WX 603 ; N arrowdbldown ; B 44 -19 572 890 ;
|
||||
C 224 ; WX 494 ; N lozenge ; B 18 0 466 745 ;
|
||||
C 225 ; WX 329 ; N angleleft ; B 25 -198 306 746 ;
|
||||
C 226 ; WX 790 ; N registersans ; B 50 -20 740 670 ;
|
||||
C 227 ; WX 790 ; N copyrightsans ; B 49 -15 739 675 ;
|
||||
C 228 ; WX 786 ; N trademarksans ; B 5 293 725 673 ;
|
||||
C 229 ; WX 713 ; N summation ; B 14 -108 695 752 ;
|
||||
C 230 ; WX 384 ; N parenlefttp ; B 24 -293 436 926 ;
|
||||
C 231 ; WX 384 ; N parenleftex ; B 24 -85 108 925 ;
|
||||
C 232 ; WX 384 ; N parenleftbt ; B 24 -293 436 926 ;
|
||||
C 233 ; WX 384 ; N bracketlefttp ; B 0 -80 349 926 ;
|
||||
C 234 ; WX 384 ; N bracketleftex ; B 0 -79 77 925 ;
|
||||
C 235 ; WX 384 ; N bracketleftbt ; B 0 -80 349 926 ;
|
||||
C 236 ; WX 494 ; N bracelefttp ; B 209 -85 445 925 ;
|
||||
C 237 ; WX 494 ; N braceleftmid ; B 20 -85 284 935 ;
|
||||
C 238 ; WX 494 ; N braceleftbt ; B 209 -75 445 935 ;
|
||||
C 239 ; WX 494 ; N braceex ; B 209 -85 284 935 ;
|
||||
C 241 ; WX 329 ; N angleright ; B 21 -198 302 746 ;
|
||||
C 242 ; WX 274 ; N integral ; B 2 -107 291 916 ;
|
||||
C 243 ; WX 686 ; N integraltp ; B 308 -88 675 920 ;
|
||||
C 244 ; WX 686 ; N integralex ; B 308 -88 378 975 ;
|
||||
C 245 ; WX 686 ; N integralbt ; B 11 -87 378 921 ;
|
||||
C 246 ; WX 384 ; N parenrighttp ; B 54 -293 466 926 ;
|
||||
C 247 ; WX 384 ; N parenrightex ; B 382 -85 466 925 ;
|
||||
C 248 ; WX 384 ; N parenrightbt ; B 54 -293 466 926 ;
|
||||
C 249 ; WX 384 ; N bracketrighttp ; B 22 -80 371 926 ;
|
||||
C 250 ; WX 384 ; N bracketrightex ; B 294 -79 371 925 ;
|
||||
C 251 ; WX 384 ; N bracketrightbt ; B 22 -80 371 926 ;
|
||||
C 252 ; WX 494 ; N bracerighttp ; B 48 -85 284 925 ;
|
||||
C 253 ; WX 494 ; N bracerightmid ; B 209 -85 473 935 ;
|
||||
C 254 ; WX 494 ; N bracerightbt ; B 48 -75 284 935 ;
|
||||
C -1 ; WX 790 ; N apple ; B 56 -3 733 808 ;
|
||||
EndCharMetrics
|
||||
EndFontMetrics
|
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
|
@ -0,0 +1,225 @@
|
|||
StartFontMetrics 4.1
|
||||
Comment Copyright (c) 1985, 1987, 1988, 1989, 1997 Adobe Systems Incorporated. All Rights Reserved.
|
||||
Comment Creation Date: Thu May 1 15:14:13 1997
|
||||
Comment UniqueID 43082
|
||||
Comment VMusage 45775 55535
|
||||
FontName ZapfDingbats
|
||||
FullName ITC Zapf Dingbats
|
||||
FamilyName ZapfDingbats
|
||||
Weight Medium
|
||||
ItalicAngle 0
|
||||
IsFixedPitch false
|
||||
CharacterSet Special
|
||||
FontBBox -1 -143 981 820
|
||||
UnderlinePosition -100
|
||||
UnderlineThickness 50
|
||||
Version 002.000
|
||||
Notice Copyright (c) 1985, 1987, 1988, 1989, 1997 Adobe Systems Incorporated. All Rights Reserved.ITC Zapf Dingbats is a registered trademark of International Typeface Corporation.
|
||||
EncodingScheme FontSpecific
|
||||
StdHW 28
|
||||
StdVW 90
|
||||
StartCharMetrics 202
|
||||
C 32 ; WX 278 ; N space ; B 0 0 0 0 ;
|
||||
C 33 ; WX 974 ; N a1 ; B 35 72 939 621 ;
|
||||
C 34 ; WX 961 ; N a2 ; B 35 81 927 611 ;
|
||||
C 35 ; WX 974 ; N a202 ; B 35 72 939 621 ;
|
||||
C 36 ; WX 980 ; N a3 ; B 35 0 945 692 ;
|
||||
C 37 ; WX 719 ; N a4 ; B 34 139 685 566 ;
|
||||
C 38 ; WX 789 ; N a5 ; B 35 -14 755 705 ;
|
||||
C 39 ; WX 790 ; N a119 ; B 35 -14 755 705 ;
|
||||
C 40 ; WX 791 ; N a118 ; B 35 -13 761 705 ;
|
||||
C 41 ; WX 690 ; N a117 ; B 34 138 655 553 ;
|
||||
C 42 ; WX 960 ; N a11 ; B 35 123 925 568 ;
|
||||
C 43 ; WX 939 ; N a12 ; B 35 134 904 559 ;
|
||||
C 44 ; WX 549 ; N a13 ; B 29 -11 516 705 ;
|
||||
C 45 ; WX 855 ; N a14 ; B 34 59 820 632 ;
|
||||
C 46 ; WX 911 ; N a15 ; B 35 50 876 642 ;
|
||||
C 47 ; WX 933 ; N a16 ; B 35 139 899 550 ;
|
||||
C 48 ; WX 911 ; N a105 ; B 35 50 876 642 ;
|
||||
C 49 ; WX 945 ; N a17 ; B 35 139 909 553 ;
|
||||
C 50 ; WX 974 ; N a18 ; B 35 104 938 587 ;
|
||||
C 51 ; WX 755 ; N a19 ; B 34 -13 721 705 ;
|
||||
C 52 ; WX 846 ; N a20 ; B 36 -14 811 705 ;
|
||||
C 53 ; WX 762 ; N a21 ; B 35 0 727 692 ;
|
||||
C 54 ; WX 761 ; N a22 ; B 35 0 727 692 ;
|
||||
C 55 ; WX 571 ; N a23 ; B -1 -68 571 661 ;
|
||||
C 56 ; WX 677 ; N a24 ; B 36 -13 642 705 ;
|
||||
C 57 ; WX 763 ; N a25 ; B 35 0 728 692 ;
|
||||
C 58 ; WX 760 ; N a26 ; B 35 0 726 692 ;
|
||||
C 59 ; WX 759 ; N a27 ; B 35 0 725 692 ;
|
||||
C 60 ; WX 754 ; N a28 ; B 35 0 720 692 ;
|
||||
C 61 ; WX 494 ; N a6 ; B 35 0 460 692 ;
|
||||
C 62 ; WX 552 ; N a7 ; B 35 0 517 692 ;
|
||||
C 63 ; WX 537 ; N a8 ; B 35 0 503 692 ;
|
||||
C 64 ; WX 577 ; N a9 ; B 35 96 542 596 ;
|
||||
C 65 ; WX 692 ; N a10 ; B 35 -14 657 705 ;
|
||||
C 66 ; WX 786 ; N a29 ; B 35 -14 751 705 ;
|
||||
C 67 ; WX 788 ; N a30 ; B 35 -14 752 705 ;
|
||||
C 68 ; WX 788 ; N a31 ; B 35 -14 753 705 ;
|
||||
C 69 ; WX 790 ; N a32 ; B 35 -14 756 705 ;
|
||||
C 70 ; WX 793 ; N a33 ; B 35 -13 759 705 ;
|
||||
C 71 ; WX 794 ; N a34 ; B 35 -13 759 705 ;
|
||||
C 72 ; WX 816 ; N a35 ; B 35 -14 782 705 ;
|
||||
C 73 ; WX 823 ; N a36 ; B 35 -14 787 705 ;
|
||||
C 74 ; WX 789 ; N a37 ; B 35 -14 754 705 ;
|
||||
C 75 ; WX 841 ; N a38 ; B 35 -14 807 705 ;
|
||||
C 76 ; WX 823 ; N a39 ; B 35 -14 789 705 ;
|
||||
C 77 ; WX 833 ; N a40 ; B 35 -14 798 705 ;
|
||||
C 78 ; WX 816 ; N a41 ; B 35 -13 782 705 ;
|
||||
C 79 ; WX 831 ; N a42 ; B 35 -14 796 705 ;
|
||||
C 80 ; WX 923 ; N a43 ; B 35 -14 888 705 ;
|
||||
C 81 ; WX 744 ; N a44 ; B 35 0 710 692 ;
|
||||
C 82 ; WX 723 ; N a45 ; B 35 0 688 692 ;
|
||||
C 83 ; WX 749 ; N a46 ; B 35 0 714 692 ;
|
||||
C 84 ; WX 790 ; N a47 ; B 34 -14 756 705 ;
|
||||
C 85 ; WX 792 ; N a48 ; B 35 -14 758 705 ;
|
||||
C 86 ; WX 695 ; N a49 ; B 35 -14 661 706 ;
|
||||
C 87 ; WX 776 ; N a50 ; B 35 -6 741 699 ;
|
||||
C 88 ; WX 768 ; N a51 ; B 35 -7 734 699 ;
|
||||
C 89 ; WX 792 ; N a52 ; B 35 -14 757 705 ;
|
||||
C 90 ; WX 759 ; N a53 ; B 35 0 725 692 ;
|
||||
C 91 ; WX 707 ; N a54 ; B 35 -13 672 704 ;
|
||||
C 92 ; WX 708 ; N a55 ; B 35 -14 672 705 ;
|
||||
C 93 ; WX 682 ; N a56 ; B 35 -14 647 705 ;
|
||||
C 94 ; WX 701 ; N a57 ; B 35 -14 666 705 ;
|
||||
C 95 ; WX 826 ; N a58 ; B 35 -14 791 705 ;
|
||||
C 96 ; WX 815 ; N a59 ; B 35 -14 780 705 ;
|
||||
C 97 ; WX 789 ; N a60 ; B 35 -14 754 705 ;
|
||||
C 98 ; WX 789 ; N a61 ; B 35 -14 754 705 ;
|
||||
C 99 ; WX 707 ; N a62 ; B 34 -14 673 705 ;
|
||||
C 100 ; WX 687 ; N a63 ; B 36 0 651 692 ;
|
||||
C 101 ; WX 696 ; N a64 ; B 35 0 661 691 ;
|
||||
C 102 ; WX 689 ; N a65 ; B 35 0 655 692 ;
|
||||
C 103 ; WX 786 ; N a66 ; B 34 -14 751 705 ;
|
||||
C 104 ; WX 787 ; N a67 ; B 35 -14 752 705 ;
|
||||
C 105 ; WX 713 ; N a68 ; B 35 -14 678 705 ;
|
||||
C 106 ; WX 791 ; N a69 ; B 35 -14 756 705 ;
|
||||
C 107 ; WX 785 ; N a70 ; B 36 -14 751 705 ;
|
||||
C 108 ; WX 791 ; N a71 ; B 35 -14 757 705 ;
|
||||
C 109 ; WX 873 ; N a72 ; B 35 -14 838 705 ;
|
||||
C 110 ; WX 761 ; N a73 ; B 35 0 726 692 ;
|
||||
C 111 ; WX 762 ; N a74 ; B 35 0 727 692 ;
|
||||
C 112 ; WX 762 ; N a203 ; B 35 0 727 692 ;
|
||||
C 113 ; WX 759 ; N a75 ; B 35 0 725 692 ;
|
||||
C 114 ; WX 759 ; N a204 ; B 35 0 725 692 ;
|
||||
C 115 ; WX 892 ; N a76 ; B 35 0 858 705 ;
|
||||
C 116 ; WX 892 ; N a77 ; B 35 -14 858 692 ;
|
||||
C 117 ; WX 788 ; N a78 ; B 35 -14 754 705 ;
|
||||
C 118 ; WX 784 ; N a79 ; B 35 -14 749 705 ;
|
||||
C 119 ; WX 438 ; N a81 ; B 35 -14 403 705 ;
|
||||
C 120 ; WX 138 ; N a82 ; B 35 0 104 692 ;
|
||||
C 121 ; WX 277 ; N a83 ; B 35 0 242 692 ;
|
||||
C 122 ; WX 415 ; N a84 ; B 35 0 380 692 ;
|
||||
C 123 ; WX 392 ; N a97 ; B 35 263 357 705 ;
|
||||
C 124 ; WX 392 ; N a98 ; B 34 263 357 705 ;
|
||||
C 125 ; WX 668 ; N a99 ; B 35 263 633 705 ;
|
||||
C 126 ; WX 668 ; N a100 ; B 36 263 634 705 ;
|
||||
C 128 ; WX 390 ; N a89 ; B 35 -14 356 705 ;
|
||||
C 129 ; WX 390 ; N a90 ; B 35 -14 355 705 ;
|
||||
C 130 ; WX 317 ; N a93 ; B 35 0 283 692 ;
|
||||
C 131 ; WX 317 ; N a94 ; B 35 0 283 692 ;
|
||||
C 132 ; WX 276 ; N a91 ; B 35 0 242 692 ;
|
||||
C 133 ; WX 276 ; N a92 ; B 35 0 242 692 ;
|
||||
C 134 ; WX 509 ; N a205 ; B 35 0 475 692 ;
|
||||
C 135 ; WX 509 ; N a85 ; B 35 0 475 692 ;
|
||||
C 136 ; WX 410 ; N a206 ; B 35 0 375 692 ;
|
||||
C 137 ; WX 410 ; N a86 ; B 35 0 375 692 ;
|
||||
C 138 ; WX 234 ; N a87 ; B 35 -14 199 705 ;
|
||||
C 139 ; WX 234 ; N a88 ; B 35 -14 199 705 ;
|
||||
C 140 ; WX 334 ; N a95 ; B 35 0 299 692 ;
|
||||
C 141 ; WX 334 ; N a96 ; B 35 0 299 692 ;
|
||||
C 161 ; WX 732 ; N a101 ; B 35 -143 697 806 ;
|
||||
C 162 ; WX 544 ; N a102 ; B 56 -14 488 706 ;
|
||||
C 163 ; WX 544 ; N a103 ; B 34 -14 508 705 ;
|
||||
C 164 ; WX 910 ; N a104 ; B 35 40 875 651 ;
|
||||
C 165 ; WX 667 ; N a106 ; B 35 -14 633 705 ;
|
||||
C 166 ; WX 760 ; N a107 ; B 35 -14 726 705 ;
|
||||
C 167 ; WX 760 ; N a108 ; B 0 121 758 569 ;
|
||||
C 168 ; WX 776 ; N a112 ; B 35 0 741 705 ;
|
||||
C 169 ; WX 595 ; N a111 ; B 34 -14 560 705 ;
|
||||
C 170 ; WX 694 ; N a110 ; B 35 -14 659 705 ;
|
||||
C 171 ; WX 626 ; N a109 ; B 34 0 591 705 ;
|
||||
C 172 ; WX 788 ; N a120 ; B 35 -14 754 705 ;
|
||||
C 173 ; WX 788 ; N a121 ; B 35 -14 754 705 ;
|
||||
C 174 ; WX 788 ; N a122 ; B 35 -14 754 705 ;
|
||||
C 175 ; WX 788 ; N a123 ; B 35 -14 754 705 ;
|
||||
C 176 ; WX 788 ; N a124 ; B 35 -14 754 705 ;
|
||||
C 177 ; WX 788 ; N a125 ; B 35 -14 754 705 ;
|
||||
C 178 ; WX 788 ; N a126 ; B 35 -14 754 705 ;
|
||||
C 179 ; WX 788 ; N a127 ; B 35 -14 754 705 ;
|
||||
C 180 ; WX 788 ; N a128 ; B 35 -14 754 705 ;
|
||||
C 181 ; WX 788 ; N a129 ; B 35 -14 754 705 ;
|
||||
C 182 ; WX 788 ; N a130 ; B 35 -14 754 705 ;
|
||||
C 183 ; WX 788 ; N a131 ; B 35 -14 754 705 ;
|
||||
C 184 ; WX 788 ; N a132 ; B 35 -14 754 705 ;
|
||||
C 185 ; WX 788 ; N a133 ; B 35 -14 754 705 ;
|
||||
C 186 ; WX 788 ; N a134 ; B 35 -14 754 705 ;
|
||||
C 187 ; WX 788 ; N a135 ; B 35 -14 754 705 ;
|
||||
C 188 ; WX 788 ; N a136 ; B 35 -14 754 705 ;
|
||||
C 189 ; WX 788 ; N a137 ; B 35 -14 754 705 ;
|
||||
C 190 ; WX 788 ; N a138 ; B 35 -14 754 705 ;
|
||||
C 191 ; WX 788 ; N a139 ; B 35 -14 754 705 ;
|
||||
C 192 ; WX 788 ; N a140 ; B 35 -14 754 705 ;
|
||||
C 193 ; WX 788 ; N a141 ; B 35 -14 754 705 ;
|
||||
C 194 ; WX 788 ; N a142 ; B 35 -14 754 705 ;
|
||||
C 195 ; WX 788 ; N a143 ; B 35 -14 754 705 ;
|
||||
C 196 ; WX 788 ; N a144 ; B 35 -14 754 705 ;
|
||||
C 197 ; WX 788 ; N a145 ; B 35 -14 754 705 ;
|
||||
C 198 ; WX 788 ; N a146 ; B 35 -14 754 705 ;
|
||||
C 199 ; WX 788 ; N a147 ; B 35 -14 754 705 ;
|
||||
C 200 ; WX 788 ; N a148 ; B 35 -14 754 705 ;
|
||||
C 201 ; WX 788 ; N a149 ; B 35 -14 754 705 ;
|
||||
C 202 ; WX 788 ; N a150 ; B 35 -14 754 705 ;
|
||||
C 203 ; WX 788 ; N a151 ; B 35 -14 754 705 ;
|
||||
C 204 ; WX 788 ; N a152 ; B 35 -14 754 705 ;
|
||||
C 205 ; WX 788 ; N a153 ; B 35 -14 754 705 ;
|
||||
C 206 ; WX 788 ; N a154 ; B 35 -14 754 705 ;
|
||||
C 207 ; WX 788 ; N a155 ; B 35 -14 754 705 ;
|
||||
C 208 ; WX 788 ; N a156 ; B 35 -14 754 705 ;
|
||||
C 209 ; WX 788 ; N a157 ; B 35 -14 754 705 ;
|
||||
C 210 ; WX 788 ; N a158 ; B 35 -14 754 705 ;
|
||||
C 211 ; WX 788 ; N a159 ; B 35 -14 754 705 ;
|
||||
C 212 ; WX 894 ; N a160 ; B 35 58 860 634 ;
|
||||
C 213 ; WX 838 ; N a161 ; B 35 152 803 540 ;
|
||||
C 214 ; WX 1016 ; N a163 ; B 34 152 981 540 ;
|
||||
C 215 ; WX 458 ; N a164 ; B 35 -127 422 820 ;
|
||||
C 216 ; WX 748 ; N a196 ; B 35 94 698 597 ;
|
||||
C 217 ; WX 924 ; N a165 ; B 35 140 890 552 ;
|
||||
C 218 ; WX 748 ; N a192 ; B 35 94 698 597 ;
|
||||
C 219 ; WX 918 ; N a166 ; B 35 166 884 526 ;
|
||||
C 220 ; WX 927 ; N a167 ; B 35 32 892 660 ;
|
||||
C 221 ; WX 928 ; N a168 ; B 35 129 891 562 ;
|
||||
C 222 ; WX 928 ; N a169 ; B 35 128 893 563 ;
|
||||
C 223 ; WX 834 ; N a170 ; B 35 155 799 537 ;
|
||||
C 224 ; WX 873 ; N a171 ; B 35 93 838 599 ;
|
||||
C 225 ; WX 828 ; N a172 ; B 35 104 791 588 ;
|
||||
C 226 ; WX 924 ; N a173 ; B 35 98 889 594 ;
|
||||
C 227 ; WX 924 ; N a162 ; B 35 98 889 594 ;
|
||||
C 228 ; WX 917 ; N a174 ; B 35 0 882 692 ;
|
||||
C 229 ; WX 930 ; N a175 ; B 35 84 896 608 ;
|
||||
C 230 ; WX 931 ; N a176 ; B 35 84 896 608 ;
|
||||
C 231 ; WX 463 ; N a177 ; B 35 -99 429 791 ;
|
||||
C 232 ; WX 883 ; N a178 ; B 35 71 848 623 ;
|
||||
C 233 ; WX 836 ; N a179 ; B 35 44 802 648 ;
|
||||
C 234 ; WX 836 ; N a193 ; B 35 44 802 648 ;
|
||||
C 235 ; WX 867 ; N a180 ; B 35 101 832 591 ;
|
||||
C 236 ; WX 867 ; N a199 ; B 35 101 832 591 ;
|
||||
C 237 ; WX 696 ; N a181 ; B 35 44 661 648 ;
|
||||
C 238 ; WX 696 ; N a200 ; B 35 44 661 648 ;
|
||||
C 239 ; WX 874 ; N a182 ; B 35 77 840 619 ;
|
||||
C 241 ; WX 874 ; N a201 ; B 35 73 840 615 ;
|
||||
C 242 ; WX 760 ; N a183 ; B 35 0 725 692 ;
|
||||
C 243 ; WX 946 ; N a184 ; B 35 160 911 533 ;
|
||||
C 244 ; WX 771 ; N a197 ; B 34 37 736 655 ;
|
||||
C 245 ; WX 865 ; N a185 ; B 35 207 830 481 ;
|
||||
C 246 ; WX 771 ; N a194 ; B 34 37 736 655 ;
|
||||
C 247 ; WX 888 ; N a198 ; B 34 -19 853 712 ;
|
||||
C 248 ; WX 967 ; N a186 ; B 35 124 932 568 ;
|
||||
C 249 ; WX 888 ; N a195 ; B 34 -19 853 712 ;
|
||||
C 250 ; WX 831 ; N a187 ; B 35 113 796 579 ;
|
||||
C 251 ; WX 873 ; N a188 ; B 36 118 838 578 ;
|
||||
C 252 ; WX 927 ; N a189 ; B 35 150 891 542 ;
|
||||
C 253 ; WX 970 ; N a190 ; B 35 76 931 616 ;
|
||||
C 254 ; WX 918 ; N a191 ; B 34 99 884 593 ;
|
||||
EndCharMetrics
|
||||
EndFontMetrics
|
|
@ -0,0 +1,80 @@
|
|||
{
|
||||
"sans-serif": {
|
||||
"normal": "Helvetica",
|
||||
"bold": "Helvetica-Bold",
|
||||
"italic": "Helvetica-Oblique",
|
||||
"bold_italic": "Helvetica-BoldOblique"
|
||||
},
|
||||
"times": {
|
||||
"normal": "Times-Roman",
|
||||
"bold": "Times-Bold",
|
||||
"italic": "Times-Italic",
|
||||
"bold_italic": "Times-BoldItalic"
|
||||
},
|
||||
"times-roman": {
|
||||
"normal": "Times-Roman",
|
||||
"bold": "Times-Bold",
|
||||
"italic": "Times-Italic",
|
||||
"bold_italic": "Times-BoldItalic"
|
||||
},
|
||||
"courier": {
|
||||
"normal": "Courier",
|
||||
"bold": "Courier-Bold",
|
||||
"italic": "Courier-Oblique",
|
||||
"bold_italic": "Courier-BoldOblique"
|
||||
},
|
||||
"helvetica": {
|
||||
"normal": "Helvetica",
|
||||
"bold": "Helvetica-Bold",
|
||||
"italic": "Helvetica-Oblique",
|
||||
"bold_italic": "Helvetica-BoldOblique"
|
||||
},
|
||||
"zapfdingbats": {
|
||||
"normal": "ZapfDingbats",
|
||||
"bold": "ZapfDingbats",
|
||||
"italic": "ZapfDingbats",
|
||||
"bold_italic": "ZapfDingbats"
|
||||
},
|
||||
"symbol": {
|
||||
"normal": "Symbol",
|
||||
"bold": "Symbol",
|
||||
"italic": "Symbol",
|
||||
"bold_italic": "Symbol"
|
||||
},
|
||||
"serif": {
|
||||
"normal": "Times-Roman",
|
||||
"bold": "Times-Bold",
|
||||
"italic": "Times-Italic",
|
||||
"bold_italic": "Times-BoldItalic"
|
||||
},
|
||||
"monospace": {
|
||||
"normal": "Courier",
|
||||
"bold": "Courier-Bold",
|
||||
"italic": "Courier-Oblique",
|
||||
"bold_italic": "Courier-BoldOblique"
|
||||
},
|
||||
"fixed": {
|
||||
"normal": "Courier",
|
||||
"bold": "Courier-Bold",
|
||||
"italic": "Courier-Oblique",
|
||||
"bold_italic": "Courier-BoldOblique"
|
||||
},
|
||||
"dejavu sans": {
|
||||
"bold": "DejaVuSans-Bold",
|
||||
"bold_italic": "DejaVuSans-BoldOblique",
|
||||
"italic": "DejaVuSans-Oblique",
|
||||
"normal": "DejaVuSans"
|
||||
},
|
||||
"dejavu sans mono": {
|
||||
"bold": "DejaVuSansMono-Bold",
|
||||
"bold_italic": "DejaVuSansMono-BoldOblique",
|
||||
"italic": "DejaVuSansMono-Oblique",
|
||||
"normal": "DejaVuSansMono"
|
||||
},
|
||||
"dejavu serif": {
|
||||
"bold": "DejaVuSerif-Bold",
|
||||
"bold_italic": "DejaVuSerif-BoldItalic",
|
||||
"italic": "DejaVuSerif-Italic",
|
||||
"normal": "DejaVuSerif"
|
||||
}
|
||||
}
|
|
@ -0,0 +1,17 @@
|
|||
<html>
|
||||
<head>
|
||||
<meta http-equiv="content-type" content="text/html;charset=iso-8859-1">
|
||||
<meta name="generator" content="Adobe GoLive 4">
|
||||
<title>Core 14 AFM Files - ReadMe</title>
|
||||
</head>
|
||||
<body bgcolor="white">
|
||||
<font color="white">or</font>
|
||||
<table border="0" cellpadding="0" cellspacing="2">
|
||||
<tr>
|
||||
<td width="40"></td>
|
||||
<td width="300">This file and the 14 PostScript(R) AFM files it accompanies may be used, copied, and distributed for any purpose and without charge, with or without modification, provided that all copyright notices are retained; that the AFM files are not distributed without this file; that all modifications to this file or any of the AFM files are prominently noted in the modified file(s); and that this paragraph is not modified. Adobe Systems has no responsibility or obligation to support the use of the AFM files. <font color="white">Col</font></td>
|
||||
</tr>
|
||||
</table>
|
||||
<p>Source <a href="http://www.adobe.com/devnet/font/#pcfi">http://www.adobe.com/devnet/font/#pcfi</a></p>
|
||||
</body>
|
||||
</html>
|
Binary file not shown.
After Width: | Height: | Size: 618 B |
|
@ -0,0 +1,8 @@
|
|||
<?xml version="1.0"?>
|
||||
<svg width="64" height="64" xmlns="http://www.w3.org/2000/svg">
|
||||
<g>
|
||||
<rect stroke="#666666" id="svg_1" height="60.499994" width="60.166667" y="1.666669" x="1.999998" stroke-width="1.5" fill="none"/>
|
||||
<line stroke-linecap="butt" stroke-linejoin="miter" id="svg_3" y2="59.333253" x2="59.749916" y1="4.333415" x1="4.250079" stroke-width="1.5" stroke="#999999" fill="none"/>
|
||||
<line stroke-linecap="butt" stroke-linejoin="miter" id="svg_4" y2="59.999665" x2="4.062838" y1="3.750342" x1="60.062164" stroke-width="1.5" stroke="#999999" fill="none"/>
|
||||
</g>
|
||||
</svg>
|
After Width: | Height: | Size: 581 B |
|
@ -0,0 +1,518 @@
|
|||
/**
|
||||
* dompdf default stylesheet.
|
||||
*
|
||||
* @package dompdf
|
||||
* @link https://github.com/dompdf/dompdf
|
||||
* @license http://www.gnu.org/copyleft/lesser.html GNU Lesser General Public License
|
||||
*
|
||||
* Portions from Mozilla
|
||||
* @link https://dxr.mozilla.org/mozilla-central/source/layout/style/res/html.css
|
||||
* @license http://mozilla.org/MPL/2.0/ Mozilla Public License, v. 2.0
|
||||
*
|
||||
* Portions from W3C
|
||||
* @link https://www.w3.org/TR/css-ui-3/#default-style-sheet
|
||||
*
|
||||
*/
|
||||
|
||||
@page {
|
||||
margin: 1.2cm;
|
||||
}
|
||||
|
||||
html {
|
||||
display: -dompdf-page !important;
|
||||
counter-reset: page;
|
||||
}
|
||||
|
||||
/* blocks */
|
||||
|
||||
article,
|
||||
aside,
|
||||
details,
|
||||
div,
|
||||
dt,
|
||||
figcaption,
|
||||
footer,
|
||||
form,
|
||||
header,
|
||||
hgroup,
|
||||
main,
|
||||
nav,
|
||||
noscript,
|
||||
section,
|
||||
summary {
|
||||
display: block;
|
||||
}
|
||||
|
||||
body {
|
||||
page-break-before: avoid;
|
||||
display: block !important;
|
||||
counter-increment: page;
|
||||
}
|
||||
|
||||
p, dl, multicol {
|
||||
display: block;
|
||||
margin: 1em 0;
|
||||
}
|
||||
|
||||
dd {
|
||||
display: block;
|
||||
margin-left: 40px;
|
||||
}
|
||||
|
||||
blockquote, figure {
|
||||
display: block;
|
||||
margin: 1em 40px;
|
||||
}
|
||||
|
||||
address {
|
||||
display: block;
|
||||
font-style: italic;
|
||||
}
|
||||
|
||||
center {
|
||||
display: block;
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
blockquote[type=cite] {
|
||||
display: block;
|
||||
margin: 1em 0;
|
||||
padding-left: 1em;
|
||||
border-left: solid;
|
||||
border-color: blue;
|
||||
border-width: thin;
|
||||
}
|
||||
|
||||
h1, h2, h3, h4, h5, h6 {
|
||||
display: block;
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
h1 {
|
||||
font-size: 2em;
|
||||
margin: .67em 0;
|
||||
}
|
||||
|
||||
h2 {
|
||||
font-size: 1.5em;
|
||||
margin: .83em 0;
|
||||
}
|
||||
|
||||
h3 {
|
||||
font-size: 1.17em;
|
||||
margin: 1em 0;
|
||||
}
|
||||
|
||||
h4 {
|
||||
margin: 1.33em 0;
|
||||
}
|
||||
|
||||
h5 {
|
||||
font-size: 0.83em;
|
||||
margin: 1.67em 0;
|
||||
}
|
||||
|
||||
h6 {
|
||||
font-size: 0.67em;
|
||||
margin: 2.33em 0;
|
||||
}
|
||||
|
||||
listing {
|
||||
display: block;
|
||||
font-family: fixed;
|
||||
font-size: medium;
|
||||
white-space: pre;
|
||||
margin: 1em 0;
|
||||
}
|
||||
|
||||
plaintext, pre, xmp {
|
||||
display: block;
|
||||
font-family: fixed;
|
||||
white-space: pre;
|
||||
margin: 1em 0;
|
||||
}
|
||||
|
||||
/* tables */
|
||||
|
||||
table {
|
||||
display: table;
|
||||
border-spacing: 2px;
|
||||
border-collapse: separate;
|
||||
margin-top: 0;
|
||||
margin-bottom: 0;
|
||||
text-indent: 0;
|
||||
text-align: left; /* quirk */
|
||||
}
|
||||
|
||||
table[border] {
|
||||
border: outset gray;
|
||||
}
|
||||
|
||||
table[border] td,
|
||||
table[border] th {
|
||||
border: 1px inset gray;
|
||||
}
|
||||
|
||||
table[border="0"] td,
|
||||
table[border="0"] th {
|
||||
border-width: 0;
|
||||
}
|
||||
|
||||
/* make sure backgrounds are inherited in tables -- see bug 4510 */
|
||||
td, th, tr {
|
||||
background: inherit;
|
||||
}
|
||||
|
||||
/* caption inherits from table not table-outer */
|
||||
caption {
|
||||
display: table-caption;
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
tr {
|
||||
display: table-row;
|
||||
vertical-align: inherit;
|
||||
}
|
||||
|
||||
col {
|
||||
display: table-column;
|
||||
}
|
||||
|
||||
colgroup {
|
||||
display: table-column-group;
|
||||
}
|
||||
|
||||
tbody {
|
||||
display: table-row-group;
|
||||
vertical-align: middle;
|
||||
}
|
||||
|
||||
thead {
|
||||
display: table-header-group;
|
||||
vertical-align: middle;
|
||||
}
|
||||
|
||||
tfoot {
|
||||
display: table-footer-group;
|
||||
vertical-align: middle;
|
||||
}
|
||||
|
||||
/* To simulate tbody auto-insertion */
|
||||
table > tr {
|
||||
vertical-align: middle;
|
||||
}
|
||||
|
||||
td {
|
||||
display: table-cell;
|
||||
vertical-align: inherit;
|
||||
text-align: inherit;
|
||||
padding: 1px;
|
||||
}
|
||||
|
||||
th {
|
||||
display: table-cell;
|
||||
vertical-align: inherit;
|
||||
text-align: center;
|
||||
font-weight: bold;
|
||||
padding: 1px;
|
||||
}
|
||||
|
||||
/* inlines */
|
||||
|
||||
q::before {
|
||||
content: open-quote;
|
||||
}
|
||||
|
||||
q::after {
|
||||
content: close-quote;
|
||||
}
|
||||
|
||||
:link {
|
||||
color: #00c;
|
||||
text-decoration: underline;
|
||||
}
|
||||
|
||||
b, strong {
|
||||
font-weight: bolder;
|
||||
}
|
||||
|
||||
i, cite, em, var, dfn {
|
||||
font-style: italic;
|
||||
}
|
||||
|
||||
tt, code, kbd, samp {
|
||||
font-family: fixed;
|
||||
}
|
||||
|
||||
u, ins {
|
||||
text-decoration: underline;
|
||||
}
|
||||
|
||||
s, strike, del {
|
||||
text-decoration: line-through;
|
||||
}
|
||||
|
||||
big {
|
||||
font-size: larger;
|
||||
}
|
||||
|
||||
small {
|
||||
font-size: smaller;
|
||||
}
|
||||
|
||||
sub {
|
||||
vertical-align: sub;
|
||||
font-size: smaller;
|
||||
line-height: normal;
|
||||
}
|
||||
|
||||
sup {
|
||||
vertical-align: super;
|
||||
font-size: smaller;
|
||||
line-height: normal;
|
||||
}
|
||||
|
||||
nobr {
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
mark {
|
||||
background: yellow;
|
||||
color: black;
|
||||
}
|
||||
|
||||
/* titles */
|
||||
|
||||
abbr[title], acronym[title] {
|
||||
text-decoration: dotted underline;
|
||||
}
|
||||
|
||||
/* lists */
|
||||
|
||||
ul, menu, dir {
|
||||
display: block;
|
||||
list-style-type: disc;
|
||||
margin: 1em 0;
|
||||
padding-left: 40px;
|
||||
}
|
||||
|
||||
ol {
|
||||
display: block;
|
||||
list-style-type: decimal;
|
||||
margin: 1em 0;
|
||||
padding-left: 40px;
|
||||
}
|
||||
|
||||
li {
|
||||
display: list-item;
|
||||
}
|
||||
|
||||
/*li::before {
|
||||
display: -dompdf-list-bullet !important;
|
||||
content: counter(-dompdf-default-counter) ". ";
|
||||
padding-right: 0.5em;
|
||||
}*/
|
||||
|
||||
/* nested lists have no top/bottom margins */
|
||||
:matches(ul, ol, dir, menu, dl) ul,
|
||||
:matches(ul, ol, dir, menu, dl) ol,
|
||||
:matches(ul, ol, dir, menu, dl) dir,
|
||||
:matches(ul, ol, dir, menu, dl) menu,
|
||||
:matches(ul, ol, dir, menu, dl) dl {
|
||||
margin-top: 0;
|
||||
margin-bottom: 0;
|
||||
}
|
||||
|
||||
/* 2 deep unordered lists use a circle */
|
||||
:matches(ul, ol, dir, menu) ul,
|
||||
:matches(ul, ol, dir, menu) ul,
|
||||
:matches(ul, ol, dir, menu) ul,
|
||||
:matches(ul, ol, dir, menu) ul {
|
||||
list-style-type: circle;
|
||||
}
|
||||
|
||||
/* 3 deep (or more) unordered lists use a square */
|
||||
:matches(ul, ol, dir, menu) :matches(ul, ol, dir, menu) ul,
|
||||
:matches(ul, ol, dir, menu) :matches(ul, ol, dir, menu) menu,
|
||||
:matches(ul, ol, dir, menu) :matches(ul, ol, dir, menu) dir {
|
||||
list-style-type: square;
|
||||
}
|
||||
|
||||
/* forms */
|
||||
/* From https://www.w3.org/TR/css-ui-3/#default-style-sheet */
|
||||
form {
|
||||
display: block;
|
||||
}
|
||||
|
||||
input, button, select {
|
||||
display: inline-block;
|
||||
font-family: sans-serif;
|
||||
}
|
||||
|
||||
input[type=text],
|
||||
input[type=password],
|
||||
select {
|
||||
width: 12em;
|
||||
}
|
||||
|
||||
input[type=text],
|
||||
input[type=password],
|
||||
input[type=button],
|
||||
input[type=submit],
|
||||
input[type=reset],
|
||||
input[type=file],
|
||||
button,
|
||||
textarea,
|
||||
select {
|
||||
background: #FFF;
|
||||
border: 1px solid #999;
|
||||
padding: 2px;
|
||||
margin: 2px;
|
||||
}
|
||||
|
||||
input[type=button],
|
||||
input[type=submit],
|
||||
input[type=reset],
|
||||
input[type=file],
|
||||
button {
|
||||
background: #CCC;
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
input[type=file] {
|
||||
width: 8em;
|
||||
}
|
||||
|
||||
input[type=text]::before,
|
||||
input[type=button]::before,
|
||||
input[type=submit]::before,
|
||||
input[type=reset]::before {
|
||||
content: attr(value);
|
||||
}
|
||||
|
||||
input[type=file]::before {
|
||||
content: "Choose a file";
|
||||
}
|
||||
|
||||
input[type=password][value]::before {
|
||||
font-family: "DejaVu Sans" !important;
|
||||
content: "\2022\2022\2022\2022\2022\2022\2022\2022";
|
||||
line-height: 1em;
|
||||
}
|
||||
|
||||
input[type=checkbox],
|
||||
input[type=radio],
|
||||
select::after {
|
||||
font-family: "DejaVu Sans" !important;
|
||||
font-size: 18px;
|
||||
line-height: 1;
|
||||
}
|
||||
|
||||
input[type=checkbox]::before {
|
||||
content: "\2610";
|
||||
}
|
||||
|
||||
input[type=checkbox][checked]::before {
|
||||
content: "\2611";
|
||||
}
|
||||
|
||||
input[type=radio]::before {
|
||||
content: "\25CB";
|
||||
}
|
||||
|
||||
input[type=radio][checked]::before {
|
||||
content: "\25C9";
|
||||
}
|
||||
|
||||
textarea {
|
||||
display: block;
|
||||
height: 3em;
|
||||
overflow: hidden;
|
||||
font-family: monospace;
|
||||
white-space: pre-wrap;
|
||||
word-wrap: break-word;
|
||||
}
|
||||
|
||||
select {
|
||||
position: relative!important;
|
||||
overflow: hidden!important;
|
||||
}
|
||||
|
||||
select::after {
|
||||
position: absolute;
|
||||
right: 0;
|
||||
top: 0;
|
||||
height: 5em;
|
||||
width: 1.4em;
|
||||
text-align: center;
|
||||
background: #CCC;
|
||||
content: "\25BE";
|
||||
}
|
||||
|
||||
select option {
|
||||
display: none;
|
||||
}
|
||||
|
||||
select option[selected] {
|
||||
display: inline;
|
||||
}
|
||||
|
||||
fieldset {
|
||||
display: block;
|
||||
margin: 0.6em 2px 2px;
|
||||
padding: 0.75em;
|
||||
border: 1pt groove #666;
|
||||
position: relative;
|
||||
}
|
||||
|
||||
fieldset > legend {
|
||||
position: absolute;
|
||||
top: -0.6em;
|
||||
left: 0.75em;
|
||||
padding: 0 0.3em;
|
||||
background: white;
|
||||
}
|
||||
|
||||
legend {
|
||||
display: inline-block;
|
||||
}
|
||||
|
||||
/* leafs */
|
||||
|
||||
hr {
|
||||
display: block;
|
||||
height: 0;
|
||||
border: 1px inset;
|
||||
margin: 0.5em auto 0.5em auto;
|
||||
}
|
||||
|
||||
hr[size="1"] {
|
||||
border-style: solid none none none;
|
||||
}
|
||||
|
||||
iframe {
|
||||
border: 2px inset;
|
||||
}
|
||||
|
||||
noframes {
|
||||
display: block;
|
||||
}
|
||||
|
||||
br {
|
||||
display: -dompdf-br;
|
||||
}
|
||||
|
||||
img, img_generated {
|
||||
display: -dompdf-image !important;
|
||||
}
|
||||
|
||||
dompdf_generated {
|
||||
display: inline;
|
||||
}
|
||||
|
||||
/* hidden elements */
|
||||
area, base, basefont, head, meta, script, style, title,
|
||||
noembed, param {
|
||||
display: none;
|
||||
-dompdf-keep: yes;
|
||||
}
|
|
@ -0,0 +1,944 @@
|
|||
<?php
|
||||
/**
|
||||
* @package dompdf
|
||||
* @link https://github.com/dompdf/dompdf
|
||||
* @license http://www.gnu.org/copyleft/lesser.html GNU Lesser General Public License
|
||||
*/
|
||||
|
||||
// FIXME: Need to sanity check inputs to this class
|
||||
namespace Dompdf\Adapter;
|
||||
|
||||
use Dompdf\Canvas;
|
||||
use Dompdf\Dompdf;
|
||||
use Dompdf\Exception;
|
||||
use Dompdf\FontMetrics;
|
||||
use Dompdf\Helpers;
|
||||
use Dompdf\Image\Cache;
|
||||
use FontLib\Exception\FontNotFoundException;
|
||||
|
||||
/**
|
||||
* PDF rendering interface
|
||||
*
|
||||
* Dompdf\Adapter\CPDF provides a simple stateless interface to the stateful one
|
||||
* provided by the Cpdf class.
|
||||
*
|
||||
* Unless otherwise mentioned, all dimensions are in points (1/72 in). The
|
||||
* coordinate origin is in the top left corner, and y values increase
|
||||
* downwards.
|
||||
*
|
||||
* See {@link http://www.ros.co.nz/pdf/} for more complete documentation
|
||||
* on the underlying {@link Cpdf} class.
|
||||
*
|
||||
* @package dompdf
|
||||
*/
|
||||
class CPDF implements Canvas
|
||||
{
|
||||
|
||||
/**
|
||||
* Dimensions of paper sizes in points
|
||||
*
|
||||
* @var array
|
||||
*/
|
||||
static $PAPER_SIZES = [
|
||||
"4a0" => [0.0, 0.0, 4767.87, 6740.79],
|
||||
"2a0" => [0.0, 0.0, 3370.39, 4767.87],
|
||||
"a0" => [0.0, 0.0, 2383.94, 3370.39],
|
||||
"a1" => [0.0, 0.0, 1683.78, 2383.94],
|
||||
"a2" => [0.0, 0.0, 1190.55, 1683.78],
|
||||
"a3" => [0.0, 0.0, 841.89, 1190.55],
|
||||
"a4" => [0.0, 0.0, 595.28, 841.89],
|
||||
"a5" => [0.0, 0.0, 419.53, 595.28],
|
||||
"a6" => [0.0, 0.0, 297.64, 419.53],
|
||||
"a7" => [0.0, 0.0, 209.76, 297.64],
|
||||
"a8" => [0.0, 0.0, 147.40, 209.76],
|
||||
"a9" => [0.0, 0.0, 104.88, 147.40],
|
||||
"a10" => [0.0, 0.0, 73.70, 104.88],
|
||||
"b0" => [0.0, 0.0, 2834.65, 4008.19],
|
||||
"b1" => [0.0, 0.0, 2004.09, 2834.65],
|
||||
"b2" => [0.0, 0.0, 1417.32, 2004.09],
|
||||
"b3" => [0.0, 0.0, 1000.63, 1417.32],
|
||||
"b4" => [0.0, 0.0, 708.66, 1000.63],
|
||||
"b5" => [0.0, 0.0, 498.90, 708.66],
|
||||
"b6" => [0.0, 0.0, 354.33, 498.90],
|
||||
"b7" => [0.0, 0.0, 249.45, 354.33],
|
||||
"b8" => [0.0, 0.0, 175.75, 249.45],
|
||||
"b9" => [0.0, 0.0, 124.72, 175.75],
|
||||
"b10" => [0.0, 0.0, 87.87, 124.72],
|
||||
"c0" => [0.0, 0.0, 2599.37, 3676.54],
|
||||
"c1" => [0.0, 0.0, 1836.85, 2599.37],
|
||||
"c2" => [0.0, 0.0, 1298.27, 1836.85],
|
||||
"c3" => [0.0, 0.0, 918.43, 1298.27],
|
||||
"c4" => [0.0, 0.0, 649.13, 918.43],
|
||||
"c5" => [0.0, 0.0, 459.21, 649.13],
|
||||
"c6" => [0.0, 0.0, 323.15, 459.21],
|
||||
"c7" => [0.0, 0.0, 229.61, 323.15],
|
||||
"c8" => [0.0, 0.0, 161.57, 229.61],
|
||||
"c9" => [0.0, 0.0, 113.39, 161.57],
|
||||
"c10" => [0.0, 0.0, 79.37, 113.39],
|
||||
"ra0" => [0.0, 0.0, 2437.80, 3458.27],
|
||||
"ra1" => [0.0, 0.0, 1729.13, 2437.80],
|
||||
"ra2" => [0.0, 0.0, 1218.90, 1729.13],
|
||||
"ra3" => [0.0, 0.0, 864.57, 1218.90],
|
||||
"ra4" => [0.0, 0.0, 609.45, 864.57],
|
||||
"sra0" => [0.0, 0.0, 2551.18, 3628.35],
|
||||
"sra1" => [0.0, 0.0, 1814.17, 2551.18],
|
||||
"sra2" => [0.0, 0.0, 1275.59, 1814.17],
|
||||
"sra3" => [0.0, 0.0, 907.09, 1275.59],
|
||||
"sra4" => [0.0, 0.0, 637.80, 907.09],
|
||||
"letter" => [0.0, 0.0, 612.00, 792.00],
|
||||
"half-letter" => [0.0, 0.0, 396.00, 612.00],
|
||||
"legal" => [0.0, 0.0, 612.00, 1008.00],
|
||||
"ledger" => [0.0, 0.0, 1224.00, 792.00],
|
||||
"tabloid" => [0.0, 0.0, 792.00, 1224.00],
|
||||
"executive" => [0.0, 0.0, 521.86, 756.00],
|
||||
"folio" => [0.0, 0.0, 612.00, 936.00],
|
||||
"commercial #10 envelope" => [0.0, 0.0, 684.00, 297.00],
|
||||
"catalog #10 1/2 envelope" => [0.0, 0.0, 648.00, 864.00],
|
||||
"8.5x11" => [0.0, 0.0, 612.00, 792.00],
|
||||
"8.5x14" => [0.0, 0.0, 612.00, 1008.00],
|
||||
"11x17" => [0.0, 0.0, 792.00, 1224.00],
|
||||
];
|
||||
|
||||
/**
|
||||
* The Dompdf object
|
||||
*
|
||||
* @var Dompdf
|
||||
*/
|
||||
protected $_dompdf;
|
||||
|
||||
/**
|
||||
* Instance of Cpdf class
|
||||
*
|
||||
* @var \Dompdf\Cpdf
|
||||
*/
|
||||
protected $_pdf;
|
||||
|
||||
/**
|
||||
* PDF width, in points
|
||||
*
|
||||
* @var float
|
||||
*/
|
||||
protected $_width;
|
||||
|
||||
/**
|
||||
* PDF height, in points
|
||||
*
|
||||
* @var float
|
||||
*/
|
||||
protected $_height;
|
||||
|
||||
/**
|
||||
* Current page number
|
||||
*
|
||||
* @var int
|
||||
*/
|
||||
protected $_page_number;
|
||||
|
||||
/**
|
||||
* Total number of pages
|
||||
*
|
||||
* @var int
|
||||
*/
|
||||
protected $_page_count;
|
||||
|
||||
/**
|
||||
* Array of pages for accessing after rendering is initially complete
|
||||
*
|
||||
* @var array
|
||||
*/
|
||||
protected $_pages;
|
||||
|
||||
/**
|
||||
* Currently-applied opacity level (0 - 1)
|
||||
*
|
||||
* @var float
|
||||
*/
|
||||
protected $_current_opacity = 1;
|
||||
|
||||
public function __construct($paper = "letter", string $orientation = "portrait", ?Dompdf $dompdf = null)
|
||||
{
|
||||
if (is_array($paper)) {
|
||||
$size = array_map("floatval", $paper);
|
||||
} else {
|
||||
$paper = strtolower($paper);
|
||||
$size = self::$PAPER_SIZES[$paper] ?? self::$PAPER_SIZES["letter"];
|
||||
}
|
||||
|
||||
if (strtolower($orientation) === "landscape") {
|
||||
[$size[2], $size[3]] = [$size[3], $size[2]];
|
||||
}
|
||||
|
||||
if ($dompdf === null) {
|
||||
$this->_dompdf = new Dompdf();
|
||||
} else {
|
||||
$this->_dompdf = $dompdf;
|
||||
}
|
||||
|
||||
$this->_pdf = new \Dompdf\Cpdf(
|
||||
$size,
|
||||
true,
|
||||
$this->_dompdf->getOptions()->getFontCache(),
|
||||
$this->_dompdf->getOptions()->getTempDir()
|
||||
);
|
||||
|
||||
$this->_pdf->addInfo("Producer", sprintf("%s + CPDF", $this->_dompdf->version));
|
||||
$time = substr_replace(date('YmdHisO'), '\'', -2, 0) . '\'';
|
||||
$this->_pdf->addInfo("CreationDate", "D:$time");
|
||||
$this->_pdf->addInfo("ModDate", "D:$time");
|
||||
|
||||
$this->_width = $size[2] - $size[0];
|
||||
$this->_height = $size[3] - $size[1];
|
||||
|
||||
$this->_page_number = $this->_page_count = 1;
|
||||
|
||||
$this->_pages = [$this->_pdf->getFirstPageId()];
|
||||
}
|
||||
|
||||
public function get_dompdf()
|
||||
{
|
||||
return $this->_dompdf;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the Cpdf instance
|
||||
*
|
||||
* @return \Dompdf\Cpdf
|
||||
*/
|
||||
public function get_cpdf()
|
||||
{
|
||||
return $this->_pdf;
|
||||
}
|
||||
|
||||
public function add_info(string $label, string $value): void
|
||||
{
|
||||
$this->_pdf->addInfo($label, $value);
|
||||
}
|
||||
|
||||
/**
|
||||
* Opens a new 'object'
|
||||
*
|
||||
* While an object is open, all drawing actions are recorded in the object,
|
||||
* as opposed to being drawn on the current page. Objects can be added
|
||||
* later to a specific page or to several pages.
|
||||
*
|
||||
* The return value is an integer ID for the new object.
|
||||
*
|
||||
* @see CPDF::close_object()
|
||||
* @see CPDF::add_object()
|
||||
*
|
||||
* @return int
|
||||
*/
|
||||
public function open_object()
|
||||
{
|
||||
$ret = $this->_pdf->openObject();
|
||||
$this->_pdf->saveState();
|
||||
return $ret;
|
||||
}
|
||||
|
||||
/**
|
||||
* Reopens an existing 'object'
|
||||
*
|
||||
* @see CPDF::open_object()
|
||||
* @param int $object the ID of a previously opened object
|
||||
*/
|
||||
public function reopen_object($object)
|
||||
{
|
||||
$this->_pdf->reopenObject($object);
|
||||
$this->_pdf->saveState();
|
||||
}
|
||||
|
||||
/**
|
||||
* Closes the current 'object'
|
||||
*
|
||||
* @see CPDF::open_object()
|
||||
*/
|
||||
public function close_object()
|
||||
{
|
||||
$this->_pdf->restoreState();
|
||||
$this->_pdf->closeObject();
|
||||
}
|
||||
|
||||
/**
|
||||
* Adds a specified 'object' to the document
|
||||
*
|
||||
* $object int specifying an object created with {@link
|
||||
* CPDF::open_object()}. $where can be one of:
|
||||
* - 'add' add to current page only
|
||||
* - 'all' add to every page from the current one onwards
|
||||
* - 'odd' add to all odd numbered pages from now on
|
||||
* - 'even' add to all even numbered pages from now on
|
||||
* - 'next' add the object to the next page only
|
||||
* - 'nextodd' add to all odd numbered pages from the next one
|
||||
* - 'nexteven' add to all even numbered pages from the next one
|
||||
*
|
||||
* @see Cpdf::addObject()
|
||||
*
|
||||
* @param int $object
|
||||
* @param string $where
|
||||
*/
|
||||
public function add_object($object, $where = 'all')
|
||||
{
|
||||
$this->_pdf->addObject($object, $where);
|
||||
}
|
||||
|
||||
/**
|
||||
* Stops the specified 'object' from appearing in the document.
|
||||
*
|
||||
* The object will stop being displayed on the page following the current
|
||||
* one.
|
||||
*
|
||||
* @param int $object
|
||||
*/
|
||||
public function stop_object($object)
|
||||
{
|
||||
$this->_pdf->stopObject($object);
|
||||
}
|
||||
|
||||
/**
|
||||
* Serialize the pdf object's current state for retrieval later
|
||||
*/
|
||||
public function serialize_object($id)
|
||||
{
|
||||
return $this->_pdf->serializeObject($id);
|
||||
}
|
||||
|
||||
public function reopen_serialized_object($obj)
|
||||
{
|
||||
return $this->_pdf->restoreSerializedObject($obj);
|
||||
}
|
||||
|
||||
//........................................................................
|
||||
|
||||
public function get_width()
|
||||
{
|
||||
return $this->_width;
|
||||
}
|
||||
|
||||
public function get_height()
|
||||
{
|
||||
return $this->_height;
|
||||
}
|
||||
|
||||
public function get_page_number()
|
||||
{
|
||||
return $this->_page_number;
|
||||
}
|
||||
|
||||
public function get_page_count()
|
||||
{
|
||||
return $this->_page_count;
|
||||
}
|
||||
|
||||
/**
|
||||
* Sets the current page number
|
||||
*
|
||||
* @param int $num
|
||||
*/
|
||||
public function set_page_number($num)
|
||||
{
|
||||
$this->_page_number = $num;
|
||||
}
|
||||
|
||||
public function set_page_count($count)
|
||||
{
|
||||
$this->_page_count = $count;
|
||||
}
|
||||
|
||||
/**
|
||||
* Sets the stroke color
|
||||
*
|
||||
* See {@link Style::set_color()} for the format of the color array.
|
||||
*
|
||||
* @param array $color
|
||||
*/
|
||||
protected function _set_stroke_color($color)
|
||||
{
|
||||
$this->_pdf->setStrokeColor($color);
|
||||
$alpha = isset($color["alpha"]) ? $color["alpha"] : 1;
|
||||
$alpha *= $this->_current_opacity;
|
||||
$this->_set_line_transparency("Normal", $alpha);
|
||||
}
|
||||
|
||||
/**
|
||||
* Sets the fill colour
|
||||
*
|
||||
* See {@link Style::set_color()} for the format of the colour array.
|
||||
*
|
||||
* @param array $color
|
||||
*/
|
||||
protected function _set_fill_color($color)
|
||||
{
|
||||
$this->_pdf->setColor($color);
|
||||
$alpha = isset($color["alpha"]) ? $color["alpha"] : 1;
|
||||
$alpha *= $this->_current_opacity;
|
||||
$this->_set_fill_transparency("Normal", $alpha);
|
||||
}
|
||||
|
||||
/**
|
||||
* Sets line transparency
|
||||
* @see Cpdf::setLineTransparency()
|
||||
*
|
||||
* Valid blend modes are (case-sensitive):
|
||||
*
|
||||
* Normal, Multiply, Screen, Overlay, Darken, Lighten,
|
||||
* ColorDodge, ColorBurn, HardLight, SoftLight, Difference,
|
||||
* Exclusion
|
||||
*
|
||||
* @param string $mode the blending mode to use
|
||||
* @param float $opacity 0.0 fully transparent, 1.0 fully opaque
|
||||
*/
|
||||
protected function _set_line_transparency($mode, $opacity)
|
||||
{
|
||||
$this->_pdf->setLineTransparency($mode, $opacity);
|
||||
}
|
||||
|
||||
/**
|
||||
* Sets fill transparency
|
||||
* @see Cpdf::setFillTransparency()
|
||||
*
|
||||
* Valid blend modes are (case-sensitive):
|
||||
*
|
||||
* Normal, Multiply, Screen, Overlay, Darken, Lighten,
|
||||
* ColorDogde, ColorBurn, HardLight, SoftLight, Difference,
|
||||
* Exclusion
|
||||
*
|
||||
* @param string $mode the blending mode to use
|
||||
* @param float $opacity 0.0 fully transparent, 1.0 fully opaque
|
||||
*/
|
||||
protected function _set_fill_transparency($mode, $opacity)
|
||||
{
|
||||
$this->_pdf->setFillTransparency($mode, $opacity);
|
||||
}
|
||||
|
||||
/**
|
||||
* Sets the line style
|
||||
*
|
||||
* @see Cpdf::setLineStyle()
|
||||
*
|
||||
* @param float $width
|
||||
* @param string $cap
|
||||
* @param string $join
|
||||
* @param array $dash
|
||||
*/
|
||||
protected function _set_line_style($width, $cap, $join, $dash)
|
||||
{
|
||||
$this->_pdf->setLineStyle($width, $cap, $join, $dash);
|
||||
}
|
||||
|
||||
public function set_opacity(float $opacity, string $mode = "Normal"): void
|
||||
{
|
||||
$this->_set_line_transparency($mode, $opacity);
|
||||
$this->_set_fill_transparency($mode, $opacity);
|
||||
$this->_current_opacity = $opacity;
|
||||
}
|
||||
|
||||
public function set_default_view($view, $options = [])
|
||||
{
|
||||
array_unshift($options, $view);
|
||||
call_user_func_array([$this->_pdf, "openHere"], $options);
|
||||
}
|
||||
|
||||
/**
|
||||
* Remaps y coords from 4th to 1st quadrant
|
||||
*
|
||||
* @param float $y
|
||||
* @return float
|
||||
*/
|
||||
protected function y($y)
|
||||
{
|
||||
return $this->_height - $y;
|
||||
}
|
||||
|
||||
public function line($x1, $y1, $x2, $y2, $color, $width, $style = [], $cap = "butt")
|
||||
{
|
||||
$this->_set_stroke_color($color);
|
||||
$this->_set_line_style($width, $cap, "", $style);
|
||||
|
||||
$this->_pdf->line($x1, $this->y($y1),
|
||||
$x2, $this->y($y2));
|
||||
$this->_set_line_transparency("Normal", $this->_current_opacity);
|
||||
}
|
||||
|
||||
public function arc($x, $y, $r1, $r2, $astart, $aend, $color, $width, $style = [], $cap = "butt")
|
||||
{
|
||||
$this->_set_stroke_color($color);
|
||||
$this->_set_line_style($width, $cap, "", $style);
|
||||
|
||||
$this->_pdf->ellipse($x, $this->y($y), $r1, $r2, 0, 8, $astart, $aend, false, false, true, false);
|
||||
$this->_set_line_transparency("Normal", $this->_current_opacity);
|
||||
}
|
||||
|
||||
public function rectangle($x1, $y1, $w, $h, $color, $width, $style = [], $cap = "butt")
|
||||
{
|
||||
$this->_set_stroke_color($color);
|
||||
$this->_set_line_style($width, $cap, "", $style);
|
||||
$this->_pdf->rectangle($x1, $this->y($y1) - $h, $w, $h);
|
||||
$this->_set_line_transparency("Normal", $this->_current_opacity);
|
||||
}
|
||||
|
||||
public function filled_rectangle($x1, $y1, $w, $h, $color)
|
||||
{
|
||||
$this->_set_fill_color($color);
|
||||
$this->_pdf->filledRectangle($x1, $this->y($y1) - $h, $w, $h);
|
||||
$this->_set_fill_transparency("Normal", $this->_current_opacity);
|
||||
}
|
||||
|
||||
public function clipping_rectangle($x1, $y1, $w, $h)
|
||||
{
|
||||
$this->_pdf->clippingRectangle($x1, $this->y($y1) - $h, $w, $h);
|
||||
}
|
||||
|
||||
public function clipping_roundrectangle($x1, $y1, $w, $h, $rTL, $rTR, $rBR, $rBL)
|
||||
{
|
||||
$this->_pdf->clippingRectangleRounded($x1, $this->y($y1) - $h, $w, $h, $rTL, $rTR, $rBR, $rBL);
|
||||
}
|
||||
|
||||
public function clipping_polygon(array $points): void
|
||||
{
|
||||
// Adjust y values
|
||||
for ($i = 1; $i < count($points); $i += 2) {
|
||||
$points[$i] = $this->y($points[$i]);
|
||||
}
|
||||
|
||||
$this->_pdf->clippingPolygon($points);
|
||||
}
|
||||
|
||||
public function clipping_end()
|
||||
{
|
||||
$this->_pdf->clippingEnd();
|
||||
}
|
||||
|
||||
public function save()
|
||||
{
|
||||
$this->_pdf->saveState();
|
||||
}
|
||||
|
||||
public function restore()
|
||||
{
|
||||
$this->_pdf->restoreState();
|
||||
}
|
||||
|
||||
public function rotate($angle, $x, $y)
|
||||
{
|
||||
$this->_pdf->rotate($angle, $x, $y);
|
||||
}
|
||||
|
||||
public function skew($angle_x, $angle_y, $x, $y)
|
||||
{
|
||||
$this->_pdf->skew($angle_x, $angle_y, $x, $y);
|
||||
}
|
||||
|
||||
public function scale($s_x, $s_y, $x, $y)
|
||||
{
|
||||
$this->_pdf->scale($s_x, $s_y, $x, $y);
|
||||
}
|
||||
|
||||
public function translate($t_x, $t_y)
|
||||
{
|
||||
$this->_pdf->translate($t_x, $t_y);
|
||||
}
|
||||
|
||||
public function transform($a, $b, $c, $d, $e, $f)
|
||||
{
|
||||
$this->_pdf->transform([$a, $b, $c, $d, $e, $f]);
|
||||
}
|
||||
|
||||
public function polygon($points, $color, $width = null, $style = [], $fill = false)
|
||||
{
|
||||
$this->_set_fill_color($color);
|
||||
$this->_set_stroke_color($color);
|
||||
|
||||
if (!$fill && isset($width)) {
|
||||
$this->_set_line_style($width, "square", "miter", $style);
|
||||
}
|
||||
|
||||
// Adjust y values
|
||||
for ($i = 1; $i < count($points); $i += 2) {
|
||||
$points[$i] = $this->y($points[$i]);
|
||||
}
|
||||
|
||||
$this->_pdf->polygon($points, $fill);
|
||||
|
||||
$this->_set_fill_transparency("Normal", $this->_current_opacity);
|
||||
$this->_set_line_transparency("Normal", $this->_current_opacity);
|
||||
}
|
||||
|
||||
public function circle($x, $y, $r, $color, $width = null, $style = [], $fill = false)
|
||||
{
|
||||
$this->_set_fill_color($color);
|
||||
$this->_set_stroke_color($color);
|
||||
|
||||
if (!$fill && isset($width)) {
|
||||
$this->_set_line_style($width, "round", "round", $style);
|
||||
}
|
||||
|
||||
$this->_pdf->ellipse($x, $this->y($y), $r, 0, 0, 8, 0, 360, 1, $fill);
|
||||
|
||||
$this->_set_fill_transparency("Normal", $this->_current_opacity);
|
||||
$this->_set_line_transparency("Normal", $this->_current_opacity);
|
||||
}
|
||||
|
||||
/**
|
||||
* Convert image to a PNG image
|
||||
*
|
||||
* @param string $image_url
|
||||
* @param string $type
|
||||
*
|
||||
* @return string|null The url of the newly converted image
|
||||
*/
|
||||
protected function _convert_to_png($image_url, $type)
|
||||
{
|
||||
$filename = Cache::getTempImage($image_url);
|
||||
|
||||
if ($filename !== null && file_exists($filename)) {
|
||||
return $filename;
|
||||
}
|
||||
|
||||
$func_name = "imagecreatefrom$type";
|
||||
|
||||
set_error_handler([Helpers::class, "record_warnings"]);
|
||||
|
||||
if (!function_exists($func_name)) {
|
||||
if (!method_exists(Helpers::class, $func_name)) {
|
||||
throw new Exception("Function $func_name() not found. Cannot convert $type image: $image_url. Please install the image PHP extension.");
|
||||
}
|
||||
$func_name = [Helpers::class, $func_name];
|
||||
}
|
||||
|
||||
try {
|
||||
$im = call_user_func($func_name, $image_url);
|
||||
|
||||
if ($im) {
|
||||
imageinterlace($im, false);
|
||||
|
||||
$tmp_dir = $this->_dompdf->getOptions()->getTempDir();
|
||||
$tmp_name = @tempnam($tmp_dir, "{$type}_dompdf_img_");
|
||||
@unlink($tmp_name);
|
||||
$filename = "$tmp_name.png";
|
||||
|
||||
imagepng($im, $filename);
|
||||
imagedestroy($im);
|
||||
} else {
|
||||
$filename = null;
|
||||
}
|
||||
} finally {
|
||||
restore_error_handler();
|
||||
}
|
||||
|
||||
if ($filename !== null) {
|
||||
Cache::addTempImage($image_url, $filename);
|
||||
}
|
||||
|
||||
return $filename;
|
||||
}
|
||||
|
||||
public function image($img, $x, $y, $w, $h, $resolution = "normal")
|
||||
{
|
||||
[$width, $height, $type] = Helpers::dompdf_getimagesize($img, $this->get_dompdf()->getHttpContext());
|
||||
|
||||
$debug_png = $this->_dompdf->getOptions()->getDebugPng();
|
||||
|
||||
if ($debug_png) {
|
||||
print "[image:$img|$width|$height|$type]";
|
||||
}
|
||||
|
||||
switch ($type) {
|
||||
case "jpeg":
|
||||
if ($debug_png) {
|
||||
print '!!!jpg!!!';
|
||||
}
|
||||
$this->_pdf->addJpegFromFile($img, $x, $this->y($y) - $h, $w, $h);
|
||||
break;
|
||||
|
||||
case "webp":
|
||||
/** @noinspection PhpMissingBreakStatementInspection */
|
||||
case "gif":
|
||||
/** @noinspection PhpMissingBreakStatementInspection */
|
||||
case "bmp":
|
||||
if ($debug_png) print "!!!{$type}!!!";
|
||||
$img = $this->_convert_to_png($img, $type);
|
||||
if ($img === null) {
|
||||
if ($debug_png) print '!!!conversion to PDF failed!!!';
|
||||
$this->image(Cache::$broken_image, $x, $y, $w, $h, $resolution);
|
||||
break;
|
||||
}
|
||||
|
||||
case "png":
|
||||
if ($debug_png) print '!!!png!!!';
|
||||
|
||||
$this->_pdf->addPngFromFile($img, $x, $this->y($y) - $h, $w, $h);
|
||||
break;
|
||||
|
||||
case "svg":
|
||||
if ($debug_png) print '!!!SVG!!!';
|
||||
|
||||
$this->_pdf->addSvgFromFile($img, $x, $this->y($y) - $h, $w, $h);
|
||||
break;
|
||||
|
||||
default:
|
||||
if ($debug_png) print '!!!unknown!!!';
|
||||
}
|
||||
}
|
||||
|
||||
public function select($x, $y, $w, $h, $font, $size, $color = [0, 0, 0], $opts = [])
|
||||
{
|
||||
$pdf = $this->_pdf;
|
||||
|
||||
$font .= ".afm";
|
||||
$pdf->selectFont($font);
|
||||
|
||||
if (!isset($pdf->acroFormId)) {
|
||||
$pdf->addForm();
|
||||
}
|
||||
|
||||
$ft = \Dompdf\Cpdf::ACROFORM_FIELD_CHOICE;
|
||||
$ff = \Dompdf\Cpdf::ACROFORM_FIELD_CHOICE_COMBO;
|
||||
|
||||
$id = $pdf->addFormField($ft, rand(), $x, $this->y($y) - $h, $x + $w, $this->y($y), $ff, $size, $color);
|
||||
$pdf->setFormFieldOpt($id, $opts);
|
||||
}
|
||||
|
||||
public function textarea($x, $y, $w, $h, $font, $size, $color = [0, 0, 0])
|
||||
{
|
||||
$pdf = $this->_pdf;
|
||||
|
||||
$font .= ".afm";
|
||||
$pdf->selectFont($font);
|
||||
|
||||
if (!isset($pdf->acroFormId)) {
|
||||
$pdf->addForm();
|
||||
}
|
||||
|
||||
$ft = \Dompdf\Cpdf::ACROFORM_FIELD_TEXT;
|
||||
$ff = \Dompdf\Cpdf::ACROFORM_FIELD_TEXT_MULTILINE;
|
||||
|
||||
$pdf->addFormField($ft, rand(), $x, $this->y($y) - $h, $x + $w, $this->y($y), $ff, $size, $color);
|
||||
}
|
||||
|
||||
public function input($x, $y, $w, $h, $type, $font, $size, $color = [0, 0, 0])
|
||||
{
|
||||
$pdf = $this->_pdf;
|
||||
|
||||
$font .= ".afm";
|
||||
$pdf->selectFont($font);
|
||||
|
||||
if (!isset($pdf->acroFormId)) {
|
||||
$pdf->addForm();
|
||||
}
|
||||
|
||||
$ft = \Dompdf\Cpdf::ACROFORM_FIELD_TEXT;
|
||||
$ff = 0;
|
||||
|
||||
switch ($type) {
|
||||
case 'text':
|
||||
$ft = \Dompdf\Cpdf::ACROFORM_FIELD_TEXT;
|
||||
break;
|
||||
case 'password':
|
||||
$ft = \Dompdf\Cpdf::ACROFORM_FIELD_TEXT;
|
||||
$ff = \Dompdf\Cpdf::ACROFORM_FIELD_TEXT_PASSWORD;
|
||||
break;
|
||||
case 'submit':
|
||||
$ft = \Dompdf\Cpdf::ACROFORM_FIELD_BUTTON;
|
||||
break;
|
||||
}
|
||||
|
||||
$pdf->addFormField($ft, rand(), $x, $this->y($y) - $h, $x + $w, $this->y($y), $ff, $size, $color);
|
||||
}
|
||||
|
||||
public function text($x, $y, $text, $font, $size, $color = [0, 0, 0], $word_space = 0.0, $char_space = 0.0, $angle = 0.0)
|
||||
{
|
||||
$pdf = $this->_pdf;
|
||||
|
||||
$this->_set_fill_color($color);
|
||||
|
||||
$is_font_subsetting = $this->_dompdf->getOptions()->getIsFontSubsettingEnabled();
|
||||
$pdf->selectFont($font . '.afm', '', true, $is_font_subsetting);
|
||||
|
||||
$pdf->addText($x, $this->y($y) - $pdf->getFontHeight($size), $size, $text, $angle, $word_space, $char_space);
|
||||
|
||||
$this->_set_fill_transparency("Normal", $this->_current_opacity);
|
||||
}
|
||||
|
||||
public function javascript($code)
|
||||
{
|
||||
$this->_pdf->addJavascript($code);
|
||||
}
|
||||
|
||||
//........................................................................
|
||||
|
||||
public function add_named_dest($anchorname)
|
||||
{
|
||||
$this->_pdf->addDestination($anchorname, "Fit");
|
||||
}
|
||||
|
||||
public function add_link($url, $x, $y, $width, $height)
|
||||
{
|
||||
$y = $this->y($y) - $height;
|
||||
|
||||
if (strpos($url, '#') === 0) {
|
||||
// Local link
|
||||
$name = substr($url, 1);
|
||||
if ($name) {
|
||||
$this->_pdf->addInternalLink($name, $x, $y, $x + $width, $y + $height);
|
||||
}
|
||||
} else {
|
||||
$this->_pdf->addLink($url, $x, $y, $x + $width, $y + $height);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* @throws FontNotFoundException
|
||||
*/
|
||||
public function get_text_width($text, $font, $size, $word_spacing = 0.0, $char_spacing = 0.0)
|
||||
{
|
||||
$this->_pdf->selectFont($font, '', true, $this->_dompdf->getOptions()->getIsFontSubsettingEnabled());
|
||||
return $this->_pdf->getTextWidth($size, $text, $word_spacing, $char_spacing);
|
||||
}
|
||||
|
||||
/**
|
||||
* @throws FontNotFoundException
|
||||
*/
|
||||
public function get_font_height($font, $size)
|
||||
{
|
||||
$options = $this->_dompdf->getOptions();
|
||||
$this->_pdf->selectFont($font, '', true, $options->getIsFontSubsettingEnabled());
|
||||
|
||||
return $this->_pdf->getFontHeight($size) * $options->getFontHeightRatio();
|
||||
}
|
||||
|
||||
/*function get_font_x_height($font, $size) {
|
||||
$this->_pdf->selectFont($font);
|
||||
$ratio = $this->_dompdf->getOptions()->getFontHeightRatio();
|
||||
return $this->_pdf->getFontXHeight($size) * $ratio;
|
||||
}*/
|
||||
|
||||
/**
|
||||
* @throws FontNotFoundException
|
||||
*/
|
||||
public function get_font_baseline($font, $size)
|
||||
{
|
||||
$ratio = $this->_dompdf->getOptions()->getFontHeightRatio();
|
||||
return $this->get_font_height($font, $size) / $ratio;
|
||||
}
|
||||
|
||||
/**
|
||||
* Processes a callback or script on every page.
|
||||
*
|
||||
* The callback function receives the four parameters `int $pageNumber`,
|
||||
* `int $pageCount`, `Canvas $canvas`, and `FontMetrics $fontMetrics`, in
|
||||
* that order. If a script is passed as string, the variables `$PAGE_NUM`,
|
||||
* `$PAGE_COUNT`, `$pdf`, and `$fontMetrics` are available instead. Passing
|
||||
* a script as string is deprecated and will be removed in a future version.
|
||||
*
|
||||
* This function can be used to add page numbers to all pages after the
|
||||
* first one, for example.
|
||||
*
|
||||
* @param callable|string $callback The callback function or PHP script to process on every page
|
||||
*/
|
||||
public function page_script($callback): void
|
||||
{
|
||||
if (is_string($callback)) {
|
||||
$this->processPageScript(function (
|
||||
int $PAGE_NUM,
|
||||
int $PAGE_COUNT,
|
||||
self $pdf,
|
||||
FontMetrics $fontMetrics
|
||||
) use ($callback) {
|
||||
eval($callback);
|
||||
});
|
||||
return;
|
||||
}
|
||||
|
||||
$this->processPageScript($callback);
|
||||
}
|
||||
|
||||
public function page_text($x, $y, $text, $font, $size, $color = [0, 0, 0], $word_space = 0.0, $char_space = 0.0, $angle = 0.0)
|
||||
{
|
||||
$this->processPageScript(function (int $pageNumber, int $pageCount) use ($x, $y, $text, $font, $size, $color, $word_space, $char_space, $angle) {
|
||||
$text = str_replace(
|
||||
["{PAGE_NUM}", "{PAGE_COUNT}"],
|
||||
[$pageNumber, $pageCount],
|
||||
$text
|
||||
);
|
||||
$this->text($x, $y, $text, $font, $size, $color, $word_space, $char_space, $angle);
|
||||
});
|
||||
}
|
||||
|
||||
public function page_line($x1, $y1, $x2, $y2, $color, $width, $style = [])
|
||||
{
|
||||
$this->processPageScript(function () use ($x1, $y1, $x2, $y2, $color, $width, $style) {
|
||||
$this->line($x1, $y1, $x2, $y2, $color, $width, $style);
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* @return int
|
||||
*/
|
||||
public function new_page()
|
||||
{
|
||||
$this->_page_number++;
|
||||
$this->_page_count++;
|
||||
|
||||
$ret = $this->_pdf->newPage();
|
||||
$this->_pages[] = $ret;
|
||||
return $ret;
|
||||
}
|
||||
|
||||
protected function processPageScript(callable $callback): void
|
||||
{
|
||||
$pageNumber = 1;
|
||||
|
||||
foreach ($this->_pages as $pid) {
|
||||
$this->reopen_object($pid);
|
||||
|
||||
$fontMetrics = $this->_dompdf->getFontMetrics();
|
||||
$callback($pageNumber, $this->_page_count, $this, $fontMetrics);
|
||||
|
||||
$this->close_object();
|
||||
$pageNumber++;
|
||||
}
|
||||
}
|
||||
|
||||
public function stream($filename = "document.pdf", $options = [])
|
||||
{
|
||||
if (headers_sent()) {
|
||||
die("Unable to stream pdf: headers already sent");
|
||||
}
|
||||
|
||||
if (!isset($options["compress"])) $options["compress"] = true;
|
||||
if (!isset($options["Attachment"])) $options["Attachment"] = true;
|
||||
|
||||
$debug = !$options['compress'];
|
||||
$tmp = ltrim($this->_pdf->output($debug));
|
||||
|
||||
header("Cache-Control: private");
|
||||
header("Content-Type: application/pdf");
|
||||
header("Content-Length: " . mb_strlen($tmp, "8bit"));
|
||||
|
||||
$filename = str_replace(["\n", "'"], "", basename($filename, ".pdf")) . ".pdf";
|
||||
$attachment = $options["Attachment"] ? "attachment" : "inline";
|
||||
header(Helpers::buildContentDispositionHeader($attachment, $filename));
|
||||
|
||||
echo $tmp;
|
||||
flush();
|
||||
}
|
||||
|
||||
public function output($options = [])
|
||||
{
|
||||
if (!isset($options["compress"])) $options["compress"] = true;
|
||||
|
||||
$debug = !$options['compress'];
|
||||
|
||||
return $this->_pdf->output($debug);
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns logging messages generated by the Cpdf class
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
public function get_messages()
|
||||
{
|
||||
return $this->_pdf->messages;
|
||||
}
|
||||
}
|
|
@ -0,0 +1,929 @@
|
|||
<?php
|
||||
/**
|
||||
* @package dompdf
|
||||
* @link https://github.com/dompdf/dompdf
|
||||
* @license http://www.gnu.org/copyleft/lesser.html GNU Lesser General Public License
|
||||
*/
|
||||
namespace Dompdf\Adapter;
|
||||
|
||||
use Dompdf\Canvas;
|
||||
use Dompdf\Dompdf;
|
||||
use Dompdf\Helpers;
|
||||
use Dompdf\Image\Cache;
|
||||
|
||||
/**
|
||||
* Image rendering interface
|
||||
*
|
||||
* Renders to an image format supported by GD (jpeg, gif, png, xpm).
|
||||
* Not super-useful day-to-day but handy nonetheless
|
||||
*
|
||||
* @package dompdf
|
||||
*/
|
||||
class GD implements Canvas
|
||||
{
|
||||
/**
|
||||
* @var Dompdf
|
||||
*/
|
||||
protected $_dompdf;
|
||||
|
||||
/**
|
||||
* Resource handle for the image
|
||||
*
|
||||
* @var \GdImage|resource
|
||||
*/
|
||||
protected $_img;
|
||||
|
||||
/**
|
||||
* Resource handle for the image
|
||||
*
|
||||
* @var \GdImage[]|resource[]
|
||||
*/
|
||||
protected $_imgs;
|
||||
|
||||
/**
|
||||
* Apparent canvas width in pixels
|
||||
*
|
||||
* @var int
|
||||
*/
|
||||
protected $_width;
|
||||
|
||||
/**
|
||||
* Apparent canvas height in pixels
|
||||
*
|
||||
* @var int
|
||||
*/
|
||||
protected $_height;
|
||||
|
||||
/**
|
||||
* Actual image width in pixels
|
||||
*
|
||||
* @var int
|
||||
*/
|
||||
protected $_actual_width;
|
||||
|
||||
/**
|
||||
* Actual image height in pixels
|
||||
*
|
||||
* @var int
|
||||
*/
|
||||
protected $_actual_height;
|
||||
|
||||
/**
|
||||
* Current page number
|
||||
*
|
||||
* @var int
|
||||
*/
|
||||
protected $_page_number;
|
||||
|
||||
/**
|
||||
* Total number of pages
|
||||
*
|
||||
* @var int
|
||||
*/
|
||||
protected $_page_count;
|
||||
|
||||
/**
|
||||
* Image antialias factor
|
||||
*
|
||||
* @var float
|
||||
*/
|
||||
protected $_aa_factor;
|
||||
|
||||
/**
|
||||
* Allocated colors
|
||||
*
|
||||
* @var array
|
||||
*/
|
||||
protected $_colors;
|
||||
|
||||
/**
|
||||
* Background color
|
||||
*
|
||||
* @var int
|
||||
*/
|
||||
protected $_bg_color;
|
||||
|
||||
/**
|
||||
* Background color array
|
||||
*
|
||||
* @var array
|
||||
*/
|
||||
protected $_bg_color_array;
|
||||
|
||||
/**
|
||||
* Actual DPI
|
||||
*
|
||||
* @var int
|
||||
*/
|
||||
protected $dpi;
|
||||
|
||||
/**
|
||||
* Amount to scale font sizes
|
||||
*
|
||||
* Font sizes are 72 DPI, GD internally uses 96. Scale them proportionally.
|
||||
* 72 / 96 = 0.75.
|
||||
*
|
||||
* @var float
|
||||
*/
|
||||
const FONT_SCALE = 0.75;
|
||||
|
||||
/**
|
||||
* @param string|float[] $paper The paper size to use as either a standard paper size (see {@link CPDF::$PAPER_SIZES}) or
|
||||
* an array of the form `[x1, y1, x2, y2]` (typically `[0, 0, width, height]`).
|
||||
* @param string $orientation The paper orientation, either `portrait` or `landscape`.
|
||||
* @param Dompdf|null $dompdf The Dompdf instance.
|
||||
* @param float $aa_factor Anti-aliasing factor, 1 for no AA
|
||||
* @param array $bg_color Image background color: array(r,g,b,a), 0 <= r,g,b,a <= 1
|
||||
*/
|
||||
public function __construct($paper = "letter", string $orientation = "portrait", ?Dompdf $dompdf = null, float $aa_factor = 1.0, array $bg_color = [1, 1, 1, 0])
|
||||
{
|
||||
if (is_array($paper)) {
|
||||
$size = array_map("floatval", $paper);
|
||||
} else {
|
||||
$paper = strtolower($paper);
|
||||
$size = CPDF::$PAPER_SIZES[$paper] ?? CPDF::$PAPER_SIZES["letter"];
|
||||
}
|
||||
|
||||
if (strtolower($orientation) === "landscape") {
|
||||
[$size[2], $size[3]] = [$size[3], $size[2]];
|
||||
}
|
||||
|
||||
if ($dompdf === null) {
|
||||
$this->_dompdf = new Dompdf();
|
||||
} else {
|
||||
$this->_dompdf = $dompdf;
|
||||
}
|
||||
|
||||
$this->dpi = $this->get_dompdf()->getOptions()->getDpi();
|
||||
|
||||
if ($aa_factor < 1) {
|
||||
$aa_factor = 1;
|
||||
}
|
||||
|
||||
$this->_aa_factor = $aa_factor;
|
||||
|
||||
$size[2] *= $aa_factor;
|
||||
$size[3] *= $aa_factor;
|
||||
|
||||
$this->_width = $size[2] - $size[0];
|
||||
$this->_height = $size[3] - $size[1];
|
||||
|
||||
$this->_actual_width = $this->_upscale($this->_width);
|
||||
$this->_actual_height = $this->_upscale($this->_height);
|
||||
|
||||
$this->_page_number = $this->_page_count = 0;
|
||||
|
||||
if (is_null($bg_color) || !is_array($bg_color)) {
|
||||
// Pure white bg
|
||||
$bg_color = [1, 1, 1, 0];
|
||||
}
|
||||
|
||||
$this->_bg_color_array = $bg_color;
|
||||
|
||||
$this->new_page();
|
||||
}
|
||||
|
||||
public function get_dompdf()
|
||||
{
|
||||
return $this->_dompdf;
|
||||
}
|
||||
|
||||
/**
|
||||
* Return the GD image resource
|
||||
*
|
||||
* @return \GdImage|resource
|
||||
*/
|
||||
public function get_image()
|
||||
{
|
||||
return $this->_img;
|
||||
}
|
||||
|
||||
/**
|
||||
* Return the image's width in pixels
|
||||
*
|
||||
* @return int
|
||||
*/
|
||||
public function get_width()
|
||||
{
|
||||
return round($this->_width / $this->_aa_factor);
|
||||
}
|
||||
|
||||
/**
|
||||
* Return the image's height in pixels
|
||||
*
|
||||
* @return int
|
||||
*/
|
||||
public function get_height()
|
||||
{
|
||||
return round($this->_height / $this->_aa_factor);
|
||||
}
|
||||
|
||||
public function get_page_number()
|
||||
{
|
||||
return $this->_page_number;
|
||||
}
|
||||
|
||||
public function get_page_count()
|
||||
{
|
||||
return $this->_page_count;
|
||||
}
|
||||
|
||||
/**
|
||||
* Sets the current page number
|
||||
*
|
||||
* @param int $num
|
||||
*/
|
||||
public function set_page_number($num)
|
||||
{
|
||||
$this->_page_number = $num;
|
||||
}
|
||||
|
||||
public function set_page_count($count)
|
||||
{
|
||||
$this->_page_count = $count;
|
||||
}
|
||||
|
||||
public function set_opacity(float $opacity, string $mode = "Normal"): void
|
||||
{
|
||||
// FIXME
|
||||
}
|
||||
|
||||
/**
|
||||
* Allocate a new color. Allocate with GD as needed and store
|
||||
* previously allocated colors in $this->_colors.
|
||||
*
|
||||
* @param array $color The new current color
|
||||
* @return int The allocated color
|
||||
*/
|
||||
protected function _allocate_color($color)
|
||||
{
|
||||
$a = isset($color["alpha"]) ? $color["alpha"] : 1;
|
||||
|
||||
if (isset($color["c"])) {
|
||||
$color = Helpers::cmyk_to_rgb($color);
|
||||
}
|
||||
|
||||
list($r, $g, $b) = $color;
|
||||
|
||||
$r = round($r * 255);
|
||||
$g = round($g * 255);
|
||||
$b = round($b * 255);
|
||||
$a = round(127 - ($a * 127));
|
||||
|
||||
// Clip values
|
||||
$r = $r > 255 ? 255 : $r;
|
||||
$g = $g > 255 ? 255 : $g;
|
||||
$b = $b > 255 ? 255 : $b;
|
||||
$a = $a > 127 ? 127 : $a;
|
||||
|
||||
$r = $r < 0 ? 0 : $r;
|
||||
$g = $g < 0 ? 0 : $g;
|
||||
$b = $b < 0 ? 0 : $b;
|
||||
$a = $a < 0 ? 0 : $a;
|
||||
|
||||
$key = sprintf("#%02X%02X%02X%02X", $r, $g, $b, $a);
|
||||
|
||||
if (isset($this->_colors[$key])) {
|
||||
return $this->_colors[$key];
|
||||
}
|
||||
|
||||
if ($a != 0) {
|
||||
$this->_colors[$key] = imagecolorallocatealpha($this->get_image(), $r, $g, $b, $a);
|
||||
} else {
|
||||
$this->_colors[$key] = imagecolorallocate($this->get_image(), $r, $g, $b);
|
||||
}
|
||||
|
||||
return $this->_colors[$key];
|
||||
}
|
||||
|
||||
/**
|
||||
* Scales value up to the current canvas DPI from 72 DPI
|
||||
*
|
||||
* @param float $length
|
||||
* @return int
|
||||
*/
|
||||
protected function _upscale($length)
|
||||
{
|
||||
return round(($length * $this->dpi) / 72 * $this->_aa_factor);
|
||||
}
|
||||
|
||||
/**
|
||||
* Scales value down from the current canvas DPI to 72 DPI
|
||||
*
|
||||
* @param float $length
|
||||
* @return float
|
||||
*/
|
||||
protected function _downscale($length)
|
||||
{
|
||||
return round(($length / $this->dpi * 72) / $this->_aa_factor);
|
||||
}
|
||||
|
||||
protected function convertStyle(array $style, int $color, int $width): array
|
||||
{
|
||||
$gdStyle = [];
|
||||
|
||||
if (count($style) === 1) {
|
||||
$style[] = $style[0];
|
||||
}
|
||||
|
||||
foreach ($style as $index => $s) {
|
||||
$d = $this->_upscale($s);
|
||||
|
||||
for ($i = 0; $i < $d; $i++) {
|
||||
for ($j = 0; $j < $width; $j++) {
|
||||
$gdStyle[] = $index % 2 === 0
|
||||
? $color
|
||||
: IMG_COLOR_TRANSPARENT;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return $gdStyle;
|
||||
}
|
||||
|
||||
public function line($x1, $y1, $x2, $y2, $color, $width, $style = [], $cap = "butt")
|
||||
{
|
||||
// Account for the fact that round and square caps are expected to
|
||||
// extend outwards
|
||||
if ($cap === "round" || $cap === "square") {
|
||||
// Shift line by half width
|
||||
$w = $width / 2;
|
||||
$a = $x2 - $x1;
|
||||
$b = $y2 - $y1;
|
||||
$c = sqrt($a ** 2 + $b ** 2);
|
||||
$dx = $a * $w / $c;
|
||||
$dy = $b * $w / $c;
|
||||
|
||||
$x1 -= $dx;
|
||||
$x2 -= $dx;
|
||||
$y1 -= $dy;
|
||||
$y2 -= $dy;
|
||||
|
||||
// Adapt dash pattern
|
||||
if (is_array($style)) {
|
||||
foreach ($style as $index => &$s) {
|
||||
$s = $index % 2 === 0 ? $s + $width : $s - $width;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// Scale by the AA factor and DPI
|
||||
$x1 = $this->_upscale($x1);
|
||||
$y1 = $this->_upscale($y1);
|
||||
$x2 = $this->_upscale($x2);
|
||||
$y2 = $this->_upscale($y2);
|
||||
$width = $this->_upscale($width);
|
||||
|
||||
$c = $this->_allocate_color($color);
|
||||
|
||||
// Convert the style array if required
|
||||
if (is_array($style) && count($style) > 0) {
|
||||
$gd_style = $this->convertStyle($style, $c, $width);
|
||||
|
||||
if (!empty($gd_style)) {
|
||||
imagesetstyle($this->get_image(), $gd_style);
|
||||
$c = IMG_COLOR_STYLED;
|
||||
}
|
||||
}
|
||||
|
||||
imagesetthickness($this->get_image(), $width);
|
||||
|
||||
imageline($this->get_image(), $x1, $y1, $x2, $y2, $c);
|
||||
}
|
||||
|
||||
public function arc($x, $y, $r1, $r2, $astart, $aend, $color, $width, $style = [], $cap = "butt")
|
||||
{
|
||||
// Account for the fact that round and square caps are expected to
|
||||
// extend outwards
|
||||
if ($cap === "round" || $cap === "square") {
|
||||
// Adapt dash pattern
|
||||
if (is_array($style)) {
|
||||
foreach ($style as $index => &$s) {
|
||||
$s = $index % 2 === 0 ? $s + $width : $s - $width;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// Scale by the AA factor and DPI
|
||||
$x = $this->_upscale($x);
|
||||
$y = $this->_upscale($y);
|
||||
$w = $this->_upscale($r1 * 2);
|
||||
$h = $this->_upscale($r2 * 2);
|
||||
$width = $this->_upscale($width);
|
||||
|
||||
// Adapt angles as imagearc counts clockwise
|
||||
$start = 360 - $aend;
|
||||
$end = 360 - $astart;
|
||||
|
||||
$c = $this->_allocate_color($color);
|
||||
|
||||
// Convert the style array if required
|
||||
if (is_array($style) && count($style) > 0) {
|
||||
$gd_style = $this->convertStyle($style, $c, $width);
|
||||
|
||||
if (!empty($gd_style)) {
|
||||
imagesetstyle($this->get_image(), $gd_style);
|
||||
$c = IMG_COLOR_STYLED;
|
||||
}
|
||||
}
|
||||
|
||||
imagesetthickness($this->get_image(), $width);
|
||||
|
||||
imagearc($this->get_image(), $x, $y, $w, $h, $start, $end, $c);
|
||||
}
|
||||
|
||||
public function rectangle($x1, $y1, $w, $h, $color, $width, $style = [], $cap = "butt")
|
||||
{
|
||||
// Account for the fact that round and square caps are expected to
|
||||
// extend outwards
|
||||
if ($cap === "round" || $cap === "square") {
|
||||
// Adapt dash pattern
|
||||
if (is_array($style)) {
|
||||
foreach ($style as $index => &$s) {
|
||||
$s = $index % 2 === 0 ? $s + $width : $s - $width;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// Scale by the AA factor and DPI
|
||||
$x1 = $this->_upscale($x1);
|
||||
$y1 = $this->_upscale($y1);
|
||||
$w = $this->_upscale($w);
|
||||
$h = $this->_upscale($h);
|
||||
$width = $this->_upscale($width);
|
||||
|
||||
$c = $this->_allocate_color($color);
|
||||
|
||||
// Convert the style array if required
|
||||
if (is_array($style) && count($style) > 0) {
|
||||
$gd_style = $this->convertStyle($style, $c, $width);
|
||||
|
||||
if (!empty($gd_style)) {
|
||||
imagesetstyle($this->get_image(), $gd_style);
|
||||
$c = IMG_COLOR_STYLED;
|
||||
}
|
||||
}
|
||||
|
||||
imagesetthickness($this->get_image(), $width);
|
||||
|
||||
if ($c === IMG_COLOR_STYLED) {
|
||||
imagepolygon($this->get_image(), [
|
||||
$x1, $y1,
|
||||
$x1 + $w, $y1,
|
||||
$x1 + $w, $y1 + $h,
|
||||
$x1, $y1 + $h
|
||||
], $c);
|
||||
} else {
|
||||
imagerectangle($this->get_image(), $x1, $y1, $x1 + $w, $y1 + $h, $c);
|
||||
}
|
||||
}
|
||||
|
||||
public function filled_rectangle($x1, $y1, $w, $h, $color)
|
||||
{
|
||||
// Scale by the AA factor and DPI
|
||||
$x1 = $this->_upscale($x1);
|
||||
$y1 = $this->_upscale($y1);
|
||||
$w = $this->_upscale($w);
|
||||
$h = $this->_upscale($h);
|
||||
|
||||
$c = $this->_allocate_color($color);
|
||||
|
||||
imagefilledrectangle($this->get_image(), $x1, $y1, $x1 + $w, $y1 + $h, $c);
|
||||
}
|
||||
|
||||
public function clipping_rectangle($x1, $y1, $w, $h)
|
||||
{
|
||||
// @todo
|
||||
}
|
||||
|
||||
public function clipping_roundrectangle($x1, $y1, $w, $h, $rTL, $rTR, $rBR, $rBL)
|
||||
{
|
||||
// @todo
|
||||
}
|
||||
|
||||
public function clipping_polygon(array $points): void
|
||||
{
|
||||
// @todo
|
||||
}
|
||||
|
||||
public function clipping_end()
|
||||
{
|
||||
// @todo
|
||||
}
|
||||
|
||||
public function save()
|
||||
{
|
||||
$this->get_dompdf()->getOptions()->setDpi(72);
|
||||
}
|
||||
|
||||
public function restore()
|
||||
{
|
||||
$this->get_dompdf()->getOptions()->setDpi($this->dpi);
|
||||
}
|
||||
|
||||
public function rotate($angle, $x, $y)
|
||||
{
|
||||
// @todo
|
||||
}
|
||||
|
||||
public function skew($angle_x, $angle_y, $x, $y)
|
||||
{
|
||||
// @todo
|
||||
}
|
||||
|
||||
public function scale($s_x, $s_y, $x, $y)
|
||||
{
|
||||
// @todo
|
||||
}
|
||||
|
||||
public function translate($t_x, $t_y)
|
||||
{
|
||||
// @todo
|
||||
}
|
||||
|
||||
public function transform($a, $b, $c, $d, $e, $f)
|
||||
{
|
||||
// @todo
|
||||
}
|
||||
|
||||
public function polygon($points, $color, $width = null, $style = [], $fill = false)
|
||||
{
|
||||
// Scale each point by the AA factor and DPI
|
||||
foreach (array_keys($points) as $i) {
|
||||
$points[$i] = $this->_upscale($points[$i]);
|
||||
}
|
||||
|
||||
$width = isset($width) ? $this->_upscale($width) : null;
|
||||
|
||||
$c = $this->_allocate_color($color);
|
||||
|
||||
// Convert the style array if required
|
||||
if (is_array($style) && count($style) > 0 && isset($width) && !$fill) {
|
||||
$gd_style = $this->convertStyle($style, $c, $width);
|
||||
|
||||
if (!empty($gd_style)) {
|
||||
imagesetstyle($this->get_image(), $gd_style);
|
||||
$c = IMG_COLOR_STYLED;
|
||||
}
|
||||
}
|
||||
|
||||
imagesetthickness($this->get_image(), isset($width) ? $width : 0);
|
||||
|
||||
if ($fill) {
|
||||
imagefilledpolygon($this->get_image(), $points, $c);
|
||||
} else {
|
||||
imagepolygon($this->get_image(), $points, $c);
|
||||
}
|
||||
}
|
||||
|
||||
public function circle($x, $y, $r, $color, $width = null, $style = [], $fill = false)
|
||||
{
|
||||
// Scale by the AA factor and DPI
|
||||
$x = $this->_upscale($x);
|
||||
$y = $this->_upscale($y);
|
||||
$d = $this->_upscale(2 * $r);
|
||||
$width = isset($width) ? $this->_upscale($width) : null;
|
||||
|
||||
$c = $this->_allocate_color($color);
|
||||
|
||||
// Convert the style array if required
|
||||
if (is_array($style) && count($style) > 0 && isset($width) && !$fill) {
|
||||
$gd_style = $this->convertStyle($style, $c, $width);
|
||||
|
||||
if (!empty($gd_style)) {
|
||||
imagesetstyle($this->get_image(), $gd_style);
|
||||
$c = IMG_COLOR_STYLED;
|
||||
}
|
||||
}
|
||||
|
||||
imagesetthickness($this->get_image(), isset($width) ? $width : 0);
|
||||
|
||||
if ($fill) {
|
||||
imagefilledellipse($this->get_image(), $x, $y, $d, $d, $c);
|
||||
} else {
|
||||
imageellipse($this->get_image(), $x, $y, $d, $d, $c);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* @throws \Exception
|
||||
*/
|
||||
public function image($img, $x, $y, $w, $h, $resolution = "normal")
|
||||
{
|
||||
$img_type = Cache::detect_type($img, $this->get_dompdf()->getHttpContext());
|
||||
|
||||
if (!$img_type) {
|
||||
return;
|
||||
}
|
||||
|
||||
$func_name = "imagecreatefrom$img_type";
|
||||
if (!function_exists($func_name)) {
|
||||
if (!method_exists(Helpers::class, $func_name)) {
|
||||
throw new \Exception("Function $func_name() not found. Cannot convert $img_type image: $img. Please install the image PHP extension.");
|
||||
}
|
||||
$func_name = [Helpers::class, $func_name];
|
||||
}
|
||||
$src = @call_user_func($func_name, $img);
|
||||
|
||||
if (!$src) {
|
||||
return; // Probably should add to $_dompdf_errors or whatever here
|
||||
}
|
||||
|
||||
// Scale by the AA factor and DPI
|
||||
$x = $this->_upscale($x);
|
||||
$y = $this->_upscale($y);
|
||||
|
||||
$w = $this->_upscale($w);
|
||||
$h = $this->_upscale($h);
|
||||
|
||||
$img_w = imagesx($src);
|
||||
$img_h = imagesy($src);
|
||||
|
||||
imagecopyresampled($this->get_image(), $src, $x, $y, 0, 0, $w, $h, $img_w, $img_h);
|
||||
}
|
||||
|
||||
public function text($x, $y, $text, $font, $size, $color = [0, 0, 0], $word_spacing = 0.0, $char_spacing = 0.0, $angle = 0.0)
|
||||
{
|
||||
// Scale by the AA factor and DPI
|
||||
$x = $this->_upscale($x);
|
||||
$y = $this->_upscale($y);
|
||||
$size = $this->_upscale($size) * self::FONT_SCALE;
|
||||
|
||||
$h = round($this->get_font_height_actual($font, $size));
|
||||
$c = $this->_allocate_color($color);
|
||||
|
||||
// imagettftext() converts numeric entities to their respective
|
||||
// character. Preserve any originally double encoded entities to be
|
||||
// represented as is.
|
||||
// eg: &#160; will render   rather than its character.
|
||||
$text = preg_replace('/&(#(?:x[a-fA-F0-9]+|[0-9]+);)/', '&\1', $text);
|
||||
|
||||
$text = mb_encode_numericentity($text, [0x0080, 0xff, 0, 0xff], 'UTF-8');
|
||||
|
||||
$font = $this->get_ttf_file($font);
|
||||
|
||||
// FIXME: word spacing
|
||||
imagettftext($this->get_image(), $size, $angle, $x, $y + $h, $c, $font, $text);
|
||||
}
|
||||
|
||||
public function javascript($code)
|
||||
{
|
||||
// Not implemented
|
||||
}
|
||||
|
||||
public function add_named_dest($anchorname)
|
||||
{
|
||||
// Not implemented
|
||||
}
|
||||
|
||||
public function add_link($url, $x, $y, $width, $height)
|
||||
{
|
||||
// Not implemented
|
||||
}
|
||||
|
||||
public function add_info(string $label, string $value): void
|
||||
{
|
||||
// N/A
|
||||
}
|
||||
|
||||
public function set_default_view($view, $options = [])
|
||||
{
|
||||
// N/A
|
||||
}
|
||||
|
||||
public function get_text_width($text, $font, $size, $word_spacing = 0.0, $char_spacing = 0.0)
|
||||
{
|
||||
$font = $this->get_ttf_file($font);
|
||||
$size = $this->_upscale($size) * self::FONT_SCALE;
|
||||
|
||||
// imagettfbbox() converts numeric entities to their respective
|
||||
// character. Preserve any originally double encoded entities to be
|
||||
// represented as is.
|
||||
// eg: &#160; will render   rather than its character.
|
||||
$text = preg_replace('/&(#(?:x[a-fA-F0-9]+|[0-9]+);)/', '&\1', $text);
|
||||
|
||||
$text = mb_encode_numericentity($text, [0x0080, 0xffff, 0, 0xffff], 'UTF-8');
|
||||
|
||||
// FIXME: word spacing
|
||||
list($x1, , $x2) = imagettfbbox($size, 0, $font, $text);
|
||||
|
||||
// Add additional 1pt to prevent text overflow issues
|
||||
return $this->_downscale($x2 - $x1) + 1;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param string|null $font
|
||||
* @return string
|
||||
*/
|
||||
public function get_ttf_file($font)
|
||||
{
|
||||
if ($font === null) {
|
||||
$font = "";
|
||||
}
|
||||
|
||||
if ( stripos($font, ".ttf") === false ) {
|
||||
$font .= ".ttf";
|
||||
}
|
||||
|
||||
if (!file_exists($font)) {
|
||||
$font_metrics = $this->_dompdf->getFontMetrics();
|
||||
$font = $font_metrics->getFont($this->_dompdf->getOptions()->getDefaultFont()) . ".ttf";
|
||||
if (!file_exists($font)) {
|
||||
if (strpos($font, "mono")) {
|
||||
$font = $font_metrics->getFont("DejaVu Mono") . ".ttf";
|
||||
} elseif (strpos($font, "sans") !== false) {
|
||||
$font = $font_metrics->getFont("DejaVu Sans") . ".ttf";
|
||||
} elseif (strpos($font, "serif")) {
|
||||
$font = $font_metrics->getFont("DejaVu Serif") . ".ttf";
|
||||
} else {
|
||||
$font = $font_metrics->getFont("DejaVu Sans") . ".ttf";
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return $font;
|
||||
}
|
||||
|
||||
public function get_font_height($font, $size)
|
||||
{
|
||||
$size = $this->_upscale($size) * self::FONT_SCALE;
|
||||
|
||||
$height = $this->get_font_height_actual($font, $size);
|
||||
|
||||
return $this->_downscale($height);
|
||||
}
|
||||
|
||||
/**
|
||||
* @param string $font
|
||||
* @param float $size
|
||||
*
|
||||
* @return float
|
||||
*/
|
||||
protected function get_font_height_actual($font, $size)
|
||||
{
|
||||
$font = $this->get_ttf_file($font);
|
||||
$ratio = $this->_dompdf->getOptions()->getFontHeightRatio();
|
||||
|
||||
// FIXME: word spacing
|
||||
list(, $y2, , , , $y1) = imagettfbbox($size, 0, $font, "MXjpqytfhl"); // Test string with ascenders, descenders and caps
|
||||
return ($y2 - $y1) * $ratio;
|
||||
}
|
||||
|
||||
public function get_font_baseline($font, $size)
|
||||
{
|
||||
$ratio = $this->_dompdf->getOptions()->getFontHeightRatio();
|
||||
return $this->get_font_height($font, $size) / $ratio;
|
||||
}
|
||||
|
||||
public function new_page()
|
||||
{
|
||||
$this->_page_number++;
|
||||
$this->_page_count++;
|
||||
|
||||
$this->_img = imagecreatetruecolor($this->_actual_width, $this->_actual_height);
|
||||
|
||||
$this->_bg_color = $this->_allocate_color($this->_bg_color_array);
|
||||
imagealphablending($this->_img, true);
|
||||
imagesavealpha($this->_img, true);
|
||||
imagefill($this->_img, 0, 0, $this->_bg_color);
|
||||
|
||||
$this->_imgs[] = $this->_img;
|
||||
}
|
||||
|
||||
public function open_object()
|
||||
{
|
||||
// N/A
|
||||
}
|
||||
|
||||
public function close_object()
|
||||
{
|
||||
// N/A
|
||||
}
|
||||
|
||||
public function add_object()
|
||||
{
|
||||
// N/A
|
||||
}
|
||||
|
||||
public function page_script($callback): void
|
||||
{
|
||||
// N/A
|
||||
}
|
||||
|
||||
public function page_text($x, $y, $text, $font, $size, $color = [0, 0, 0], $word_space = 0.0, $char_space = 0.0, $angle = 0.0)
|
||||
{
|
||||
// N/A
|
||||
}
|
||||
|
||||
public function page_line($x1, $y1, $x2, $y2, $color, $width, $style = [])
|
||||
{
|
||||
// N/A
|
||||
}
|
||||
|
||||
/**
|
||||
* Streams the image to the client.
|
||||
*
|
||||
* @param string $filename The filename to present to the client.
|
||||
* @param array $options Associative array: 'type' => jpeg|jpg|png; 'quality' => 0 - 100 (JPEG only);
|
||||
* 'page' => Number of the page to output (defaults to the first); 'Attachment': 1 or 0 (default 1).
|
||||
*/
|
||||
public function stream($filename, $options = [])
|
||||
{
|
||||
if (headers_sent()) {
|
||||
die("Unable to stream image: headers already sent");
|
||||
}
|
||||
|
||||
if (!isset($options["type"])) $options["type"] = "png";
|
||||
if (!isset($options["Attachment"])) $options["Attachment"] = true;
|
||||
$type = strtolower($options["type"]);
|
||||
|
||||
switch ($type) {
|
||||
case "jpg":
|
||||
case "jpeg":
|
||||
$contentType = "image/jpeg";
|
||||
$extension = ".jpg";
|
||||
break;
|
||||
case "png":
|
||||
default:
|
||||
$contentType = "image/png";
|
||||
$extension = ".png";
|
||||
break;
|
||||
}
|
||||
|
||||
header("Cache-Control: private");
|
||||
header("Content-Type: $contentType");
|
||||
|
||||
$filename = str_replace(["\n", "'"], "", basename($filename, ".$type")) . $extension;
|
||||
$attachment = $options["Attachment"] ? "attachment" : "inline";
|
||||
header(Helpers::buildContentDispositionHeader($attachment, $filename));
|
||||
|
||||
$this->_output($options);
|
||||
flush();
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the image as a string.
|
||||
*
|
||||
* @param array $options Associative array: 'type' => jpeg|jpg|png; 'quality' => 0 - 100 (JPEG only);
|
||||
* 'page' => Number of the page to output (defaults to the first).
|
||||
* @return string
|
||||
*/
|
||||
public function output($options = [])
|
||||
{
|
||||
ob_start();
|
||||
|
||||
$this->_output($options);
|
||||
|
||||
return ob_get_clean();
|
||||
}
|
||||
|
||||
/**
|
||||
* Outputs the image stream directly.
|
||||
*
|
||||
* @param array $options Associative array: 'type' => jpeg|jpg|png; 'quality' => 0 - 100 (JPEG only);
|
||||
* 'page' => Number of the page to output (defaults to the first).
|
||||
*/
|
||||
protected function _output($options = [])
|
||||
{
|
||||
if (!isset($options["type"])) $options["type"] = "png";
|
||||
if (!isset($options["page"])) $options["page"] = 1;
|
||||
$type = strtolower($options["type"]);
|
||||
|
||||
if (isset($this->_imgs[$options["page"] - 1])) {
|
||||
$img = $this->_imgs[$options["page"] - 1];
|
||||
} else {
|
||||
$img = $this->_imgs[0];
|
||||
}
|
||||
|
||||
// Perform any antialiasing
|
||||
if ($this->_aa_factor != 1) {
|
||||
$dst_w = round($this->_actual_width / $this->_aa_factor);
|
||||
$dst_h = round($this->_actual_height / $this->_aa_factor);
|
||||
$dst = imagecreatetruecolor($dst_w, $dst_h);
|
||||
imagecopyresampled($dst, $img, 0, 0, 0, 0,
|
||||
$dst_w, $dst_h,
|
||||
$this->_actual_width, $this->_actual_height);
|
||||
} else {
|
||||
$dst = $img;
|
||||
}
|
||||
|
||||
switch ($type) {
|
||||
case "jpg":
|
||||
case "jpeg":
|
||||
if (!isset($options["quality"])) {
|
||||
$options["quality"] = 75;
|
||||
}
|
||||
|
||||
imagejpeg($dst, null, $options["quality"]);
|
||||
break;
|
||||
case "png":
|
||||
default:
|
||||
imagepng($dst);
|
||||
break;
|
||||
}
|
||||
|
||||
if ($this->_aa_factor != 1) {
|
||||
imagedestroy($dst);
|
||||
}
|
||||
}
|
||||
}
|
File diff suppressed because it is too large
Load Diff
|
@ -0,0 +1,477 @@
|
|||
<?php
|
||||
/**
|
||||
* @package dompdf
|
||||
* @link https://github.com/dompdf/dompdf
|
||||
* @license http://www.gnu.org/copyleft/lesser.html GNU Lesser General Public License
|
||||
*/
|
||||
namespace Dompdf;
|
||||
|
||||
/**
|
||||
* Main rendering interface
|
||||
*
|
||||
* Currently {@link Dompdf\Adapter\CPDF}, {@link Dompdf\Adapter\PDFLib}, and {@link Dompdf\Adapter\GD}
|
||||
* implement this interface.
|
||||
*
|
||||
* Implementations should measure x and y increasing to the left and down,
|
||||
* respectively, with the origin in the top left corner. Implementations
|
||||
* are free to use a unit other than points for length, but I can't
|
||||
* guarantee that the results will look any good.
|
||||
*
|
||||
* @package dompdf
|
||||
*/
|
||||
interface Canvas
|
||||
{
|
||||
/**
|
||||
* @param string|float[] $paper The paper size to use as either a standard paper size (see {@link Dompdf\Adapter\CPDF::$PAPER_SIZES})
|
||||
* or an array of the form `[x1, y1, x2, y2]` (typically `[0, 0, width, height]`).
|
||||
* @param string $orientation The paper orientation, either `portrait` or `landscape`.
|
||||
* @param Dompdf|null $dompdf The Dompdf instance.
|
||||
*/
|
||||
public function __construct($paper = "letter", string $orientation = "portrait", ?Dompdf $dompdf = null);
|
||||
|
||||
/**
|
||||
* @return Dompdf
|
||||
*/
|
||||
function get_dompdf();
|
||||
|
||||
/**
|
||||
* Returns the current page number
|
||||
*
|
||||
* @return int
|
||||
*/
|
||||
function get_page_number();
|
||||
|
||||
/**
|
||||
* Returns the total number of pages in the document
|
||||
*
|
||||
* @return int
|
||||
*/
|
||||
function get_page_count();
|
||||
|
||||
/**
|
||||
* Sets the total number of pages
|
||||
*
|
||||
* @param int $count
|
||||
*/
|
||||
function set_page_count($count);
|
||||
|
||||
/**
|
||||
* Draws a line from x1,y1 to x2,y2
|
||||
*
|
||||
* See {@link Cpdf::setLineStyle()} for a description of the format of the
|
||||
* $style and $cap parameters (aka dash and cap).
|
||||
*
|
||||
* @param float $x1
|
||||
* @param float $y1
|
||||
* @param float $x2
|
||||
* @param float $y2
|
||||
* @param array $color Color array in the format `[r, g, b, "alpha" => alpha]`
|
||||
* where r, g, b, and alpha are float values between 0 and 1
|
||||
* @param float $width
|
||||
* @param array $style
|
||||
* @param string $cap `butt`, `round`, or `square`
|
||||
*/
|
||||
function line($x1, $y1, $x2, $y2, $color, $width, $style = [], $cap = "butt");
|
||||
|
||||
/**
|
||||
* Draws an arc
|
||||
*
|
||||
* See {@link Cpdf::setLineStyle()} for a description of the format of the
|
||||
* $style and $cap parameters (aka dash and cap).
|
||||
*
|
||||
* @param float $x X coordinate of the arc
|
||||
* @param float $y Y coordinate of the arc
|
||||
* @param float $r1 Radius 1
|
||||
* @param float $r2 Radius 2
|
||||
* @param float $astart Start angle in degrees
|
||||
* @param float $aend End angle in degrees
|
||||
* @param array $color Color array in the format `[r, g, b, "alpha" => alpha]`
|
||||
* where r, g, b, and alpha are float values between 0 and 1
|
||||
* @param float $width
|
||||
* @param array $style
|
||||
* @param string $cap `butt`, `round`, or `square`
|
||||
*/
|
||||
function arc($x, $y, $r1, $r2, $astart, $aend, $color, $width, $style = [], $cap = "butt");
|
||||
|
||||
/**
|
||||
* Draws a rectangle at x1,y1 with width w and height h
|
||||
*
|
||||
* See {@link Cpdf::setLineStyle()} for a description of the format of the
|
||||
* $style and $cap parameters (aka dash and cap).
|
||||
*
|
||||
* @param float $x1
|
||||
* @param float $y1
|
||||
* @param float $w
|
||||
* @param float $h
|
||||
* @param array $color Color array in the format `[r, g, b, "alpha" => alpha]`
|
||||
* where r, g, b, and alpha are float values between 0 and 1
|
||||
* @param float $width
|
||||
* @param array $style
|
||||
* @param string $cap `butt`, `round`, or `square`
|
||||
*/
|
||||
function rectangle($x1, $y1, $w, $h, $color, $width, $style = [], $cap = "butt");
|
||||
|
||||
/**
|
||||
* Draws a filled rectangle at x1,y1 with width w and height h
|
||||
*
|
||||
* @param float $x1
|
||||
* @param float $y1
|
||||
* @param float $w
|
||||
* @param float $h
|
||||
* @param array $color Color array in the format `[r, g, b, "alpha" => alpha]`
|
||||
* where r, g, b, and alpha are float values between 0 and 1
|
||||
*/
|
||||
function filled_rectangle($x1, $y1, $w, $h, $color);
|
||||
|
||||
/**
|
||||
* Starts a clipping rectangle at x1,y1 with width w and height h
|
||||
*
|
||||
* @param float $x1
|
||||
* @param float $y1
|
||||
* @param float $w
|
||||
* @param float $h
|
||||
*/
|
||||
function clipping_rectangle($x1, $y1, $w, $h);
|
||||
|
||||
/**
|
||||
* Starts a rounded clipping rectangle at x1,y1 with width w and height h
|
||||
*
|
||||
* @param float $x1
|
||||
* @param float $y1
|
||||
* @param float $w
|
||||
* @param float $h
|
||||
* @param float $tl
|
||||
* @param float $tr
|
||||
* @param float $br
|
||||
* @param float $bl
|
||||
*/
|
||||
function clipping_roundrectangle($x1, $y1, $w, $h, $tl, $tr, $br, $bl);
|
||||
|
||||
/**
|
||||
* Starts a clipping polygon
|
||||
*
|
||||
* @param float[] $points
|
||||
*/
|
||||
public function clipping_polygon(array $points): void;
|
||||
|
||||
/**
|
||||
* Ends the last clipping shape
|
||||
*/
|
||||
function clipping_end();
|
||||
|
||||
/**
|
||||
* Processes a callback on every page.
|
||||
*
|
||||
* The callback function receives the four parameters `int $pageNumber`,
|
||||
* `int $pageCount`, `Canvas $canvas`, and `FontMetrics $fontMetrics`, in
|
||||
* that order.
|
||||
*
|
||||
* This function can be used to add page numbers to all pages after the
|
||||
* first one, for example.
|
||||
*
|
||||
* @param callable $callback The callback function to process on every page
|
||||
*/
|
||||
public function page_script($callback): void;
|
||||
|
||||
/**
|
||||
* Writes text at the specified x and y coordinates on every page.
|
||||
*
|
||||
* The strings '{PAGE_NUM}' and '{PAGE_COUNT}' are automatically replaced
|
||||
* with their current values.
|
||||
*
|
||||
* @param float $x
|
||||
* @param float $y
|
||||
* @param string $text The text to write
|
||||
* @param string $font The font file to use
|
||||
* @param float $size The font size, in points
|
||||
* @param array $color Color array in the format `[r, g, b, "alpha" => alpha]`
|
||||
* where r, g, b, and alpha are float values between 0 and 1
|
||||
* @param float $word_space Word spacing adjustment
|
||||
* @param float $char_space Char spacing adjustment
|
||||
* @param float $angle Angle to write the text at, measured clockwise starting from the x-axis
|
||||
*/
|
||||
public function page_text($x, $y, $text, $font, $size, $color = [0, 0, 0], $word_space = 0.0, $char_space = 0.0, $angle = 0.0);
|
||||
|
||||
/**
|
||||
* Draws a line at the specified coordinates on every page.
|
||||
*
|
||||
* @param float $x1
|
||||
* @param float $y1
|
||||
* @param float $x2
|
||||
* @param float $y2
|
||||
* @param array $color Color array in the format `[r, g, b, "alpha" => alpha]`
|
||||
* where r, g, b, and alpha are float values between 0 and 1
|
||||
* @param float $width
|
||||
* @param array $style
|
||||
*/
|
||||
public function page_line($x1, $y1, $x2, $y2, $color, $width, $style = []);
|
||||
|
||||
/**
|
||||
* Save current state
|
||||
*/
|
||||
function save();
|
||||
|
||||
/**
|
||||
* Restore last state
|
||||
*/
|
||||
function restore();
|
||||
|
||||
/**
|
||||
* Rotate
|
||||
*
|
||||
* @param float $angle angle in degrees for counter-clockwise rotation
|
||||
* @param float $x Origin abscissa
|
||||
* @param float $y Origin ordinate
|
||||
*/
|
||||
function rotate($angle, $x, $y);
|
||||
|
||||
/**
|
||||
* Skew
|
||||
*
|
||||
* @param float $angle_x
|
||||
* @param float $angle_y
|
||||
* @param float $x Origin abscissa
|
||||
* @param float $y Origin ordinate
|
||||
*/
|
||||
function skew($angle_x, $angle_y, $x, $y);
|
||||
|
||||
/**
|
||||
* Scale
|
||||
*
|
||||
* @param float $s_x scaling factor for width as percent
|
||||
* @param float $s_y scaling factor for height as percent
|
||||
* @param float $x Origin abscissa
|
||||
* @param float $y Origin ordinate
|
||||
*/
|
||||
function scale($s_x, $s_y, $x, $y);
|
||||
|
||||
/**
|
||||
* Translate
|
||||
*
|
||||
* @param float $t_x movement to the right
|
||||
* @param float $t_y movement to the bottom
|
||||
*/
|
||||
function translate($t_x, $t_y);
|
||||
|
||||
/**
|
||||
* Transform
|
||||
*
|
||||
* @param float $a
|
||||
* @param float $b
|
||||
* @param float $c
|
||||
* @param float $d
|
||||
* @param float $e
|
||||
* @param float $f
|
||||
*/
|
||||
function transform($a, $b, $c, $d, $e, $f);
|
||||
|
||||
/**
|
||||
* Draws a polygon
|
||||
*
|
||||
* The polygon is formed by joining all the points stored in the $points
|
||||
* array. $points has the following structure:
|
||||
* ```
|
||||
* array(0 => x1,
|
||||
* 1 => y1,
|
||||
* 2 => x2,
|
||||
* 3 => y2,
|
||||
* ...
|
||||
* );
|
||||
* ```
|
||||
*
|
||||
* See {@link Cpdf::setLineStyle()} for a description of the format of the
|
||||
* $style parameter (aka dash).
|
||||
*
|
||||
* @param array $points
|
||||
* @param array $color Color array in the format `[r, g, b, "alpha" => alpha]`
|
||||
* where r, g, b, and alpha are float values between 0 and 1
|
||||
* @param float $width
|
||||
* @param array $style
|
||||
* @param bool $fill Fills the polygon if true
|
||||
*/
|
||||
function polygon($points, $color, $width = null, $style = [], $fill = false);
|
||||
|
||||
/**
|
||||
* Draws a circle at $x,$y with radius $r
|
||||
*
|
||||
* See {@link Cpdf::setLineStyle()} for a description of the format of the
|
||||
* $style parameter (aka dash).
|
||||
*
|
||||
* @param float $x
|
||||
* @param float $y
|
||||
* @param float $r
|
||||
* @param array $color Color array in the format `[r, g, b, "alpha" => alpha]`
|
||||
* where r, g, b, and alpha are float values between 0 and 1
|
||||
* @param float $width
|
||||
* @param array $style
|
||||
* @param bool $fill Fills the circle if true
|
||||
*/
|
||||
function circle($x, $y, $r, $color, $width = null, $style = [], $fill = false);
|
||||
|
||||
/**
|
||||
* Add an image to the pdf.
|
||||
*
|
||||
* The image is placed at the specified x and y coordinates with the
|
||||
* given width and height.
|
||||
*
|
||||
* @param string $img The path to the image
|
||||
* @param float $x X position
|
||||
* @param float $y Y position
|
||||
* @param float $w Width
|
||||
* @param float $h Height
|
||||
* @param string $resolution The resolution of the image
|
||||
*/
|
||||
function image($img, $x, $y, $w, $h, $resolution = "normal");
|
||||
|
||||
/**
|
||||
* Writes text at the specified x and y coordinates
|
||||
*
|
||||
* @param float $x
|
||||
* @param float $y
|
||||
* @param string $text The text to write
|
||||
* @param string $font The font file to use
|
||||
* @param float $size The font size, in points
|
||||
* @param array $color Color array in the format `[r, g, b, "alpha" => alpha]`
|
||||
* where r, g, b, and alpha are float values between 0 and 1
|
||||
* @param float $word_space Word spacing adjustment
|
||||
* @param float $char_space Char spacing adjustment
|
||||
* @param float $angle Angle to write the text at, measured clockwise starting from the x-axis
|
||||
*/
|
||||
function text($x, $y, $text, $font, $size, $color = [0, 0, 0], $word_space = 0.0, $char_space = 0.0, $angle = 0.0);
|
||||
|
||||
/**
|
||||
* Add a named destination (similar to <a name="foo">...</a> in html)
|
||||
*
|
||||
* @param string $anchorname The name of the named destination
|
||||
*/
|
||||
function add_named_dest($anchorname);
|
||||
|
||||
/**
|
||||
* Add a link to the pdf
|
||||
*
|
||||
* @param string $url The url to link to
|
||||
* @param float $x The x position of the link
|
||||
* @param float $y The y position of the link
|
||||
* @param float $width The width of the link
|
||||
* @param float $height The height of the link
|
||||
*/
|
||||
function add_link($url, $x, $y, $width, $height);
|
||||
|
||||
/**
|
||||
* Add meta information to the PDF.
|
||||
*
|
||||
* @param string $label Label of the value (Creator, Producer, etc.)
|
||||
* @param string $value The text to set
|
||||
*/
|
||||
public function add_info(string $label, string $value): void;
|
||||
|
||||
/**
|
||||
* Calculates text size, in points
|
||||
*
|
||||
* @param string $text The text to be sized
|
||||
* @param string $font The font file to use
|
||||
* @param float $size The font size, in points
|
||||
* @param float $word_spacing Word spacing, if any
|
||||
* @param float $char_spacing Char spacing, if any
|
||||
*
|
||||
* @return float
|
||||
*/
|
||||
function get_text_width($text, $font, $size, $word_spacing = 0.0, $char_spacing = 0.0);
|
||||
|
||||
/**
|
||||
* Calculates font height, in points
|
||||
*
|
||||
* @param string $font The font file to use
|
||||
* @param float $size The font size, in points
|
||||
*
|
||||
* @return float
|
||||
*/
|
||||
function get_font_height($font, $size);
|
||||
|
||||
/**
|
||||
* Returns the font x-height, in points
|
||||
*
|
||||
* @param string $font The font file to use
|
||||
* @param float $size The font size, in points
|
||||
*
|
||||
* @return float
|
||||
*/
|
||||
//function get_font_x_height($font, $size);
|
||||
|
||||
/**
|
||||
* Calculates font baseline, in points
|
||||
*
|
||||
* @param string $font The font file to use
|
||||
* @param float $size The font size, in points
|
||||
*
|
||||
* @return float
|
||||
*/
|
||||
function get_font_baseline($font, $size);
|
||||
|
||||
/**
|
||||
* Returns the PDF's width in points
|
||||
*
|
||||
* @return float
|
||||
*/
|
||||
function get_width();
|
||||
|
||||
/**
|
||||
* Returns the PDF's height in points
|
||||
*
|
||||
* @return float
|
||||
*/
|
||||
function get_height();
|
||||
|
||||
/**
|
||||
* Sets the opacity
|
||||
*
|
||||
* @param float $opacity
|
||||
* @param string $mode
|
||||
*/
|
||||
public function set_opacity(float $opacity, string $mode = "Normal"): void;
|
||||
|
||||
/**
|
||||
* Sets the default view
|
||||
*
|
||||
* @param string $view
|
||||
* 'XYZ' left, top, zoom
|
||||
* 'Fit'
|
||||
* 'FitH' top
|
||||
* 'FitV' left
|
||||
* 'FitR' left,bottom,right
|
||||
* 'FitB'
|
||||
* 'FitBH' top
|
||||
* 'FitBV' left
|
||||
* @param array $options
|
||||
*/
|
||||
function set_default_view($view, $options = []);
|
||||
|
||||
/**
|
||||
* @param string $code
|
||||
*/
|
||||
function javascript($code);
|
||||
|
||||
/**
|
||||
* Starts a new page
|
||||
*
|
||||
* Subsequent drawing operations will appear on the new page.
|
||||
*/
|
||||
function new_page();
|
||||
|
||||
/**
|
||||
* Streams the PDF to the client.
|
||||
*
|
||||
* @param string $filename The filename to present to the client.
|
||||
* @param array $options Associative array: 'compress' => 1 or 0 (default 1); 'Attachment' => 1 or 0 (default 1).
|
||||
*/
|
||||
function stream($filename, $options = []);
|
||||
|
||||
/**
|
||||
* Returns the PDF as a string.
|
||||
*
|
||||
* @param array $options Associative array: 'compress' => 1 or 0 (default 1).
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
function output($options = []);
|
||||
}
|
|
@ -0,0 +1,58 @@
|
|||
<?php
|
||||
/**
|
||||
* @package dompdf
|
||||
* @link https://github.com/dompdf/dompdf
|
||||
* @license http://www.gnu.org/copyleft/lesser.html GNU Lesser General Public License
|
||||
*/
|
||||
namespace Dompdf;
|
||||
|
||||
/**
|
||||
* Create canvas instances
|
||||
*
|
||||
* The canvas factory creates canvas instances based on the
|
||||
* availability of rendering backends and config options.
|
||||
*
|
||||
* @package dompdf
|
||||
*/
|
||||
class CanvasFactory
|
||||
{
|
||||
/**
|
||||
* Constructor is private: this is a static class
|
||||
*/
|
||||
private function __construct()
|
||||
{
|
||||
}
|
||||
|
||||
/**
|
||||
* @param Dompdf $dompdf
|
||||
* @param string|float[] $paper
|
||||
* @param string $orientation
|
||||
* @param string|null $class
|
||||
*
|
||||
* @return Canvas
|
||||
*/
|
||||
static function get_instance(Dompdf $dompdf, $paper, string $orientation, ?string $class = null)
|
||||
{
|
||||
$backend = strtolower($dompdf->getOptions()->getPdfBackend());
|
||||
|
||||
if (isset($class) && class_exists($class, false)) {
|
||||
$class .= "_Adapter";
|
||||
} else {
|
||||
if (($backend === "auto" || $backend === "pdflib") &&
|
||||
class_exists("PDFLib", false)
|
||||
) {
|
||||
$class = "Dompdf\\Adapter\\PDFLib";
|
||||
}
|
||||
|
||||
else {
|
||||
if ($backend === "gd" && extension_loaded('gd')) {
|
||||
$class = "Dompdf\\Adapter\\GD";
|
||||
} else {
|
||||
$class = "Dompdf\\Adapter\\CPDF";
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return new $class($paper, $orientation, $dompdf);
|
||||
}
|
||||
}
|
|
@ -0,0 +1,999 @@
|
|||
<?php
|
||||
/**
|
||||
* @package dompdf
|
||||
* @link https://github.com/dompdf/dompdf
|
||||
* @license http://www.gnu.org/copyleft/lesser.html GNU Lesser General Public License
|
||||
*/
|
||||
namespace Dompdf;
|
||||
|
||||
use Dompdf\FrameDecorator\AbstractFrameDecorator;
|
||||
use Dompdf\FrameDecorator\Table as TableFrameDecorator;
|
||||
use Dompdf\FrameDecorator\TableCell as TableCellFrameDecorator;
|
||||
|
||||
/**
|
||||
* Maps table cells to the table grid.
|
||||
*
|
||||
* This class resolves borders in tables with collapsed borders and helps
|
||||
* place row & column spanned table cells.
|
||||
*
|
||||
* @package dompdf
|
||||
*/
|
||||
class Cellmap
|
||||
{
|
||||
/**
|
||||
* Border style weight lookup for collapsed border resolution.
|
||||
*/
|
||||
protected const BORDER_STYLE_SCORE = [
|
||||
"double" => 8,
|
||||
"solid" => 7,
|
||||
"dashed" => 6,
|
||||
"dotted" => 5,
|
||||
"ridge" => 4,
|
||||
"outset" => 3,
|
||||
"groove" => 2,
|
||||
"inset" => 1,
|
||||
"none" => 0
|
||||
];
|
||||
|
||||
/**
|
||||
* The table object this cellmap is attached to.
|
||||
*
|
||||
* @var TableFrameDecorator
|
||||
*/
|
||||
protected $_table;
|
||||
|
||||
/**
|
||||
* The total number of rows in the table
|
||||
*
|
||||
* @var int
|
||||
*/
|
||||
protected $_num_rows;
|
||||
|
||||
/**
|
||||
* The total number of columns in the table
|
||||
*
|
||||
* @var int
|
||||
*/
|
||||
protected $_num_cols;
|
||||
|
||||
/**
|
||||
* 2D array mapping <row,column> to frames
|
||||
*
|
||||
* @var Frame[][]
|
||||
*/
|
||||
protected $_cells;
|
||||
|
||||
/**
|
||||
* 1D array of column dimensions
|
||||
*
|
||||
* @var array
|
||||
*/
|
||||
protected $_columns;
|
||||
|
||||
/**
|
||||
* 1D array of row dimensions
|
||||
*
|
||||
* @var array
|
||||
*/
|
||||
protected $_rows;
|
||||
|
||||
/**
|
||||
* 2D array of border specs
|
||||
*
|
||||
* @var array
|
||||
*/
|
||||
protected $_borders;
|
||||
|
||||
/**
|
||||
* 1D Array mapping frames to (multiple) <row, col> pairs, keyed on frame_id.
|
||||
*
|
||||
* @var array[]
|
||||
*/
|
||||
protected $_frames;
|
||||
|
||||
/**
|
||||
* Current column when adding cells, 0-based
|
||||
*
|
||||
* @var int
|
||||
*/
|
||||
private $__col;
|
||||
|
||||
/**
|
||||
* Current row when adding cells, 0-based
|
||||
*
|
||||
* @var int
|
||||
*/
|
||||
private $__row;
|
||||
|
||||
/**
|
||||
* Tells whether the columns' width can be modified
|
||||
*
|
||||
* @var bool
|
||||
*/
|
||||
private $_columns_locked = false;
|
||||
|
||||
/**
|
||||
* Tells whether the table has table-layout:fixed
|
||||
*
|
||||
* @var bool
|
||||
*/
|
||||
private $_fixed_layout = false;
|
||||
|
||||
/**
|
||||
* @param TableFrameDecorator $table
|
||||
*/
|
||||
public function __construct(TableFrameDecorator $table)
|
||||
{
|
||||
$this->_table = $table;
|
||||
$this->reset();
|
||||
}
|
||||
|
||||
public function reset(): void
|
||||
{
|
||||
$this->_num_rows = 0;
|
||||
$this->_num_cols = 0;
|
||||
|
||||
$this->_cells = [];
|
||||
$this->_frames = [];
|
||||
|
||||
if (!$this->_columns_locked) {
|
||||
$this->_columns = [];
|
||||
}
|
||||
|
||||
$this->_rows = [];
|
||||
|
||||
$this->_borders = [];
|
||||
|
||||
$this->__col = $this->__row = 0;
|
||||
}
|
||||
|
||||
public function lock_columns(): void
|
||||
{
|
||||
$this->_columns_locked = true;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return bool
|
||||
*/
|
||||
public function is_columns_locked()
|
||||
{
|
||||
return $this->_columns_locked;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param bool $fixed
|
||||
*/
|
||||
public function set_layout_fixed(bool $fixed)
|
||||
{
|
||||
$this->_fixed_layout = $fixed;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return bool
|
||||
*/
|
||||
public function is_layout_fixed()
|
||||
{
|
||||
return $this->_fixed_layout;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return int
|
||||
*/
|
||||
public function get_num_rows()
|
||||
{
|
||||
return $this->_num_rows;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return int
|
||||
*/
|
||||
public function get_num_cols()
|
||||
{
|
||||
return $this->_num_cols;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return array
|
||||
*/
|
||||
public function &get_columns()
|
||||
{
|
||||
return $this->_columns;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param $columns
|
||||
*/
|
||||
public function set_columns($columns)
|
||||
{
|
||||
$this->_columns = $columns;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param int $i
|
||||
*
|
||||
* @return mixed
|
||||
*/
|
||||
public function &get_column($i)
|
||||
{
|
||||
if (!isset($this->_columns[$i])) {
|
||||
$this->_columns[$i] = [
|
||||
"x" => 0,
|
||||
"min-width" => 0,
|
||||
"max-width" => 0,
|
||||
"used-width" => null,
|
||||
"absolute" => 0,
|
||||
"percent" => 0,
|
||||
"auto" => true,
|
||||
];
|
||||
}
|
||||
|
||||
return $this->_columns[$i];
|
||||
}
|
||||
|
||||
/**
|
||||
* @return array
|
||||
*/
|
||||
public function &get_rows()
|
||||
{
|
||||
return $this->_rows;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param int $j
|
||||
*
|
||||
* @return mixed
|
||||
*/
|
||||
public function &get_row($j)
|
||||
{
|
||||
if (!isset($this->_rows[$j])) {
|
||||
$this->_rows[$j] = [
|
||||
"y" => 0,
|
||||
"first-column" => 0,
|
||||
"height" => null,
|
||||
];
|
||||
}
|
||||
|
||||
return $this->_rows[$j];
|
||||
}
|
||||
|
||||
/**
|
||||
* @param int $i
|
||||
* @param int $j
|
||||
* @param mixed $h_v
|
||||
* @param null|mixed $prop
|
||||
*
|
||||
* @return mixed
|
||||
*/
|
||||
public function get_border($i, $j, $h_v, $prop = null)
|
||||
{
|
||||
if (!isset($this->_borders[$i][$j][$h_v])) {
|
||||
$this->_borders[$i][$j][$h_v] = [
|
||||
"width" => 0,
|
||||
"style" => "solid",
|
||||
"color" => "black",
|
||||
];
|
||||
}
|
||||
|
||||
if (isset($prop)) {
|
||||
return $this->_borders[$i][$j][$h_v][$prop];
|
||||
}
|
||||
|
||||
return $this->_borders[$i][$j][$h_v];
|
||||
}
|
||||
|
||||
/**
|
||||
* @param int $i
|
||||
* @param int $j
|
||||
*
|
||||
* @return array
|
||||
*/
|
||||
public function get_border_properties($i, $j)
|
||||
{
|
||||
return [
|
||||
"top" => $this->get_border($i, $j, "horizontal"),
|
||||
"right" => $this->get_border($i, $j + 1, "vertical"),
|
||||
"bottom" => $this->get_border($i + 1, $j, "horizontal"),
|
||||
"left" => $this->get_border($i, $j, "vertical"),
|
||||
];
|
||||
}
|
||||
|
||||
/**
|
||||
* @param Frame $frame
|
||||
*
|
||||
* @return array|null
|
||||
*/
|
||||
public function get_spanned_cells(Frame $frame)
|
||||
{
|
||||
$key = $frame->get_id();
|
||||
|
||||
if (isset($this->_frames[$key])) {
|
||||
return $this->_frames[$key];
|
||||
}
|
||||
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param Frame $frame
|
||||
*
|
||||
* @return bool
|
||||
*/
|
||||
public function frame_exists_in_cellmap(Frame $frame)
|
||||
{
|
||||
$key = $frame->get_id();
|
||||
|
||||
return isset($this->_frames[$key]);
|
||||
}
|
||||
|
||||
/**
|
||||
* @param Frame $frame
|
||||
*
|
||||
* @return array
|
||||
* @throws Exception
|
||||
*/
|
||||
public function get_frame_position(Frame $frame)
|
||||
{
|
||||
global $_dompdf_warnings;
|
||||
|
||||
$key = $frame->get_id();
|
||||
|
||||
if (!isset($this->_frames[$key])) {
|
||||
throw new Exception("Frame not found in cellmap");
|
||||
}
|
||||
|
||||
// Positions are stored relative to the table position
|
||||
[$table_x, $table_y] = $this->_table->get_position();
|
||||
$col = $this->_frames[$key]["columns"][0];
|
||||
$row = $this->_frames[$key]["rows"][0];
|
||||
|
||||
if (!isset($this->_columns[$col])) {
|
||||
$_dompdf_warnings[] = "Frame not found in columns array. Check your table layout for missing or extra TDs.";
|
||||
$x = $table_x;
|
||||
} else {
|
||||
$x = $table_x + $this->_columns[$col]["x"];
|
||||
}
|
||||
|
||||
if (!isset($this->_rows[$row])) {
|
||||
$_dompdf_warnings[] = "Frame not found in row array. Check your table layout for missing or extra TDs.";
|
||||
$y = $table_y;
|
||||
} else {
|
||||
$y = $table_y + $this->_rows[$row]["y"];
|
||||
}
|
||||
|
||||
return [$x, $y, "x" => $x, "y" => $y];
|
||||
}
|
||||
|
||||
/**
|
||||
* @param Frame $frame
|
||||
*
|
||||
* @return int
|
||||
* @throws Exception
|
||||
*/
|
||||
public function get_frame_width(Frame $frame)
|
||||
{
|
||||
$key = $frame->get_id();
|
||||
|
||||
if (!isset($this->_frames[$key])) {
|
||||
throw new Exception("Frame not found in cellmap");
|
||||
}
|
||||
|
||||
$cols = $this->_frames[$key]["columns"];
|
||||
$w = 0;
|
||||
foreach ($cols as $i) {
|
||||
$w += $this->_columns[$i]["used-width"];
|
||||
}
|
||||
|
||||
return $w;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param Frame $frame
|
||||
*
|
||||
* @return int
|
||||
* @throws Exception
|
||||
* @throws Exception
|
||||
*/
|
||||
public function get_frame_height(Frame $frame)
|
||||
{
|
||||
$key = $frame->get_id();
|
||||
|
||||
if (!isset($this->_frames[$key])) {
|
||||
throw new Exception("Frame not found in cellmap");
|
||||
}
|
||||
|
||||
$rows = $this->_frames[$key]["rows"];
|
||||
$h = 0;
|
||||
foreach ($rows as $i) {
|
||||
if (!isset($this->_rows[$i])) {
|
||||
throw new Exception("The row #$i could not be found, please file an issue in the tracker with the HTML code");
|
||||
}
|
||||
|
||||
$h += $this->_rows[$i]["height"];
|
||||
}
|
||||
|
||||
return $h;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param int $j
|
||||
* @param mixed $width
|
||||
*/
|
||||
public function set_column_width($j, $width)
|
||||
{
|
||||
if ($this->_columns_locked) {
|
||||
return;
|
||||
}
|
||||
|
||||
$col =& $this->get_column($j);
|
||||
$col["used-width"] = $width;
|
||||
$next_col =& $this->get_column($j + 1);
|
||||
$next_col["x"] = $col["x"] + $width;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param int $i
|
||||
* @param long $height
|
||||
*/
|
||||
public function set_row_height($i, $height)
|
||||
{
|
||||
$row =& $this->get_row($i);
|
||||
if ($height > $row["height"]) {
|
||||
$row["height"] = $height;
|
||||
}
|
||||
$next_row =& $this->get_row($i + 1);
|
||||
$next_row["y"] = $row["y"] + $row["height"];
|
||||
}
|
||||
|
||||
/**
|
||||
* https://www.w3.org/TR/CSS21/tables.html#border-conflict-resolution
|
||||
*
|
||||
* @param int $i
|
||||
* @param int $j
|
||||
* @param string $h_v `horizontal` or `vertical`
|
||||
* @param array $border_spec
|
||||
*/
|
||||
protected function resolve_border(int $i, int $j, string $h_v, array $border_spec): void
|
||||
{
|
||||
if (!isset($this->_borders[$i][$j][$h_v])) {
|
||||
$this->_borders[$i][$j][$h_v] = $border_spec;
|
||||
return;
|
||||
}
|
||||
|
||||
$border = $this->_borders[$i][$j][$h_v];
|
||||
|
||||
$n_width = $border_spec["width"];
|
||||
$n_style = $border_spec["style"];
|
||||
$o_width = $border["width"];
|
||||
$o_style = $border["style"];
|
||||
|
||||
if ($o_style === "hidden") {
|
||||
return;
|
||||
}
|
||||
|
||||
// A style of `none` has lowest priority independent of its specified
|
||||
// width here, as its resolved width is always 0
|
||||
if ($n_style === "hidden" || $n_width > $o_width
|
||||
|| ($o_width == $n_width
|
||||
&& isset(self::BORDER_STYLE_SCORE[$n_style])
|
||||
&& isset(self::BORDER_STYLE_SCORE[$o_style])
|
||||
&& self::BORDER_STYLE_SCORE[$n_style] > self::BORDER_STYLE_SCORE[$o_style])
|
||||
) {
|
||||
$this->_borders[$i][$j][$h_v] = $border_spec;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the resolved border properties for the given frame.
|
||||
*
|
||||
* @param AbstractFrameDecorator $frame
|
||||
*
|
||||
* @return array[]
|
||||
*/
|
||||
protected function get_resolved_border(AbstractFrameDecorator $frame): array
|
||||
{
|
||||
$key = $frame->get_id();
|
||||
$columns = $this->_frames[$key]["columns"];
|
||||
$rows = $this->_frames[$key]["rows"];
|
||||
|
||||
$first_col = $columns[0];
|
||||
$last_col = $columns[count($columns) - 1];
|
||||
$first_row = $rows[0];
|
||||
$last_row = $rows[count($rows) - 1];
|
||||
|
||||
$max_top = null;
|
||||
$max_bottom = null;
|
||||
$max_left = null;
|
||||
$max_right = null;
|
||||
|
||||
foreach ($columns as $col) {
|
||||
$top = $this->_borders[$first_row][$col]["horizontal"];
|
||||
$bottom = $this->_borders[$last_row + 1][$col]["horizontal"];
|
||||
|
||||
if ($max_top === null || $top["width"] > $max_top["width"]) {
|
||||
$max_top = $top;
|
||||
}
|
||||
if ($max_bottom === null || $bottom["width"] > $max_bottom["width"]) {
|
||||
$max_bottom = $bottom;
|
||||
}
|
||||
}
|
||||
|
||||
foreach ($rows as $row) {
|
||||
$left = $this->_borders[$row][$first_col]["vertical"];
|
||||
$right = $this->_borders[$row][$last_col + 1]["vertical"];
|
||||
|
||||
if ($max_left === null || $left["width"] > $max_left["width"]) {
|
||||
$max_left = $left;
|
||||
}
|
||||
if ($max_right === null || $right["width"] > $max_right["width"]) {
|
||||
$max_right = $right;
|
||||
}
|
||||
}
|
||||
|
||||
return [$max_top, $max_right, $max_bottom, $max_left];
|
||||
}
|
||||
|
||||
/**
|
||||
* @param AbstractFrameDecorator $frame
|
||||
*/
|
||||
public function add_frame(Frame $frame): void
|
||||
{
|
||||
$style = $frame->get_style();
|
||||
$display = $style->display;
|
||||
|
||||
$collapse = $this->_table->get_style()->border_collapse === "collapse";
|
||||
|
||||
// Recursively add the frames within the table, its row groups and rows
|
||||
if ($frame === $this->_table
|
||||
|| $display === "table-row"
|
||||
|| in_array($display, TableFrameDecorator::ROW_GROUPS, true)
|
||||
) {
|
||||
$start_row = $this->__row;
|
||||
|
||||
foreach ($frame->get_children() as $child) {
|
||||
$this->add_frame($child);
|
||||
}
|
||||
|
||||
if ($display === "table-row") {
|
||||
$this->add_row();
|
||||
}
|
||||
|
||||
$num_rows = $this->__row - $start_row - 1;
|
||||
$key = $frame->get_id();
|
||||
|
||||
// Row groups always span across the entire table
|
||||
$this->_frames[$key]["columns"] = range(0, max(0, $this->_num_cols - 1));
|
||||
$this->_frames[$key]["rows"] = range($start_row, max(0, $this->__row - 1));
|
||||
$this->_frames[$key]["frame"] = $frame;
|
||||
|
||||
if ($collapse) {
|
||||
$bp = $style->get_border_properties();
|
||||
|
||||
// Resolve vertical borders
|
||||
for ($i = 0; $i < $num_rows + 1; $i++) {
|
||||
$this->resolve_border($start_row + $i, 0, "vertical", $bp["left"]);
|
||||
$this->resolve_border($start_row + $i, $this->_num_cols, "vertical", $bp["right"]);
|
||||
}
|
||||
|
||||
// Resolve horizontal borders
|
||||
for ($j = 0; $j < $this->_num_cols; $j++) {
|
||||
$this->resolve_border($start_row, $j, "horizontal", $bp["top"]);
|
||||
$this->resolve_border($this->__row, $j, "horizontal", $bp["bottom"]);
|
||||
}
|
||||
|
||||
if ($frame === $this->_table) {
|
||||
// Clear borders because the cells are now using them. The
|
||||
// border width still needs to be set to half the resolved
|
||||
// width so that the table is positioned properly
|
||||
[$top, $right, $bottom, $left] = $this->get_resolved_border($frame);
|
||||
|
||||
$style->set_used("border_top_width", $top["width"] / 2);
|
||||
$style->set_used("border_right_width", $right["width"] / 2);
|
||||
$style->set_used("border_bottom_width", $bottom["width"] / 2);
|
||||
$style->set_used("border_left_width", $left["width"] / 2);
|
||||
$style->set_used("border_style", "none");
|
||||
} else {
|
||||
// Clear borders for rows and row groups
|
||||
$style->set_used("border_width", 0);
|
||||
$style->set_used("border_style", "none");
|
||||
}
|
||||
}
|
||||
|
||||
if ($frame === $this->_table) {
|
||||
// Apply resolved borders to table cells and calculate column
|
||||
// widths after all frames have been added
|
||||
$this->calculate_column_widths();
|
||||
}
|
||||
return;
|
||||
}
|
||||
|
||||
// Add the frame to the cellmap
|
||||
$key = $frame->get_id();
|
||||
$node = $frame->get_node();
|
||||
$bp = $style->get_border_properties();
|
||||
|
||||
// Determine where this cell is going
|
||||
$colspan = max((int) $node->getAttribute("colspan"), 1);
|
||||
$rowspan = max((int) $node->getAttribute("rowspan"), 1);
|
||||
|
||||
// Find the next available column (fix by Ciro Mondueri)
|
||||
$ac = $this->__col;
|
||||
while (isset($this->_cells[$this->__row][$ac])) {
|
||||
$ac++;
|
||||
}
|
||||
|
||||
$this->__col = $ac;
|
||||
|
||||
// Rows:
|
||||
for ($i = 0; $i < $rowspan; $i++) {
|
||||
$row = $this->__row + $i;
|
||||
|
||||
$this->_frames[$key]["rows"][] = $row;
|
||||
|
||||
for ($j = 0; $j < $colspan; $j++) {
|
||||
$this->_cells[$row][$this->__col + $j] = $frame;
|
||||
}
|
||||
|
||||
if ($collapse) {
|
||||
// Resolve vertical borders
|
||||
$this->resolve_border($row, $this->__col, "vertical", $bp["left"]);
|
||||
$this->resolve_border($row, $this->__col + $colspan, "vertical", $bp["right"]);
|
||||
}
|
||||
}
|
||||
|
||||
// Columns:
|
||||
for ($j = 0; $j < $colspan; $j++) {
|
||||
$col = $this->__col + $j;
|
||||
$this->_frames[$key]["columns"][] = $col;
|
||||
|
||||
if ($collapse) {
|
||||
// Resolve horizontal borders
|
||||
$this->resolve_border($this->__row, $col, "horizontal", $bp["top"]);
|
||||
$this->resolve_border($this->__row + $rowspan, $col, "horizontal", $bp["bottom"]);
|
||||
}
|
||||
}
|
||||
|
||||
$this->_frames[$key]["frame"] = $frame;
|
||||
|
||||
$this->__col += $colspan;
|
||||
if ($this->__col > $this->_num_cols) {
|
||||
$this->_num_cols = $this->__col;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Apply resolved borders to table cells and calculate column widths.
|
||||
*/
|
||||
protected function calculate_column_widths(): void
|
||||
{
|
||||
$table = $this->_table;
|
||||
$table_style = $table->get_style();
|
||||
$collapse = $table_style->border_collapse === "collapse";
|
||||
|
||||
if ($collapse) {
|
||||
$v_spacing = 0;
|
||||
$h_spacing = 0;
|
||||
} else {
|
||||
// The additional 1/2 width gets added to the table proper
|
||||
[$h, $v] = $table_style->border_spacing;
|
||||
$v_spacing = $v / 2;
|
||||
$h_spacing = $h / 2;
|
||||
}
|
||||
|
||||
foreach ($this->_frames as $frame_info) {
|
||||
/** @var TableCellFrameDecorator */
|
||||
$frame = $frame_info["frame"];
|
||||
$style = $frame->get_style();
|
||||
$display = $style->display;
|
||||
|
||||
if ($display !== "table-cell") {
|
||||
continue;
|
||||
}
|
||||
|
||||
if ($collapse) {
|
||||
// Set the resolved border at half width
|
||||
[$top, $right, $bottom, $left] = $this->get_resolved_border($frame);
|
||||
|
||||
$style->set_used("border_top_width", $top["width"] / 2);
|
||||
$style->set_used("border_top_style", $top["style"]);
|
||||
$style->set_used("border_top_color", $top["color"]);
|
||||
$style->set_used("border_right_width", $right["width"] / 2);
|
||||
$style->set_used("border_right_style", $right["style"]);
|
||||
$style->set_used("border_right_color", $right["color"]);
|
||||
$style->set_used("border_bottom_width", $bottom["width"] / 2);
|
||||
$style->set_used("border_bottom_style", $bottom["style"]);
|
||||
$style->set_used("border_bottom_color", $bottom["color"]);
|
||||
$style->set_used("border_left_width", $left["width"] / 2);
|
||||
$style->set_used("border_left_style", $left["style"]);
|
||||
$style->set_used("border_left_color", $left["color"]);
|
||||
$style->set_used("margin", 0);
|
||||
} else {
|
||||
// Border spacing is effectively a margin between cells
|
||||
$style->set_used("margin_top", $v_spacing);
|
||||
$style->set_used("margin_bottom", $v_spacing);
|
||||
$style->set_used("margin_left", $h_spacing);
|
||||
$style->set_used("margin_right", $h_spacing);
|
||||
}
|
||||
|
||||
if ($this->_columns_locked) {
|
||||
continue;
|
||||
}
|
||||
|
||||
$node = $frame->get_node();
|
||||
$colspan = max((int) $node->getAttribute("colspan"), 1);
|
||||
$first_col = $frame_info["columns"][0];
|
||||
|
||||
// Resolve the frame's width
|
||||
if ($this->_fixed_layout) {
|
||||
list($frame_min, $frame_max) = [0, 10e-10];
|
||||
} else {
|
||||
list($frame_min, $frame_max) = $frame->get_min_max_width();
|
||||
}
|
||||
|
||||
$width = $style->width;
|
||||
|
||||
$val = null;
|
||||
if (Helpers::is_percent($width) && $colspan === 1) {
|
||||
$var = "percent";
|
||||
$val = (float)rtrim($width, "% ");
|
||||
} elseif ($width !== "auto" && $colspan === 1) {
|
||||
$var = "absolute";
|
||||
$val = $frame_min;
|
||||
}
|
||||
|
||||
$min = 0;
|
||||
$max = 0;
|
||||
for ($cs = 0; $cs < $colspan; $cs++) {
|
||||
|
||||
// Resolve the frame's width(s) with other cells
|
||||
$col =& $this->get_column($first_col + $cs);
|
||||
|
||||
// Note: $var is either 'percent' or 'absolute'. We compare the
|
||||
// requested percentage or absolute values with the existing widths
|
||||
// and adjust accordingly.
|
||||
if (isset($var) && $val > $col[$var]) {
|
||||
$col[$var] = $val;
|
||||
$col["auto"] = false;
|
||||
}
|
||||
|
||||
$min += $col["min-width"];
|
||||
$max += $col["max-width"];
|
||||
}
|
||||
|
||||
if ($frame_min > $min && $colspan === 1) {
|
||||
// The frame needs more space. Expand each sub-column
|
||||
// FIXME try to avoid putting this dummy value when table-layout:fixed
|
||||
$inc = ($this->is_layout_fixed() ? 10e-10 : ($frame_min - $min));
|
||||
for ($c = 0; $c < $colspan; $c++) {
|
||||
$col =& $this->get_column($first_col + $c);
|
||||
$col["min-width"] += $inc;
|
||||
}
|
||||
}
|
||||
|
||||
if ($frame_max > $max) {
|
||||
// FIXME try to avoid putting this dummy value when table-layout:fixed
|
||||
$inc = ($this->is_layout_fixed() ? 10e-10 : ($frame_max - $max) / $colspan);
|
||||
for ($c = 0; $c < $colspan; $c++) {
|
||||
$col =& $this->get_column($first_col + $c);
|
||||
$col["max-width"] += $inc;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// Adjust absolute columns so that the absolute (and max) width is the
|
||||
// largest minimum width of all cells. This accounts for cells without
|
||||
// absolute width within an absolute column
|
||||
foreach ($this->_columns as &$col) {
|
||||
if ($col["absolute"] > 0) {
|
||||
$col["absolute"] = $col["min-width"];
|
||||
$col["max-width"] = $col["min-width"];
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
protected function add_row(): void
|
||||
{
|
||||
$this->__row++;
|
||||
$this->_num_rows++;
|
||||
|
||||
// Find the next available column
|
||||
$i = 0;
|
||||
while (isset($this->_cells[$this->__row][$i])) {
|
||||
$i++;
|
||||
}
|
||||
|
||||
$this->__col = $i;
|
||||
}
|
||||
|
||||
/**
|
||||
* Remove a row from the cellmap.
|
||||
*
|
||||
* @param Frame
|
||||
*/
|
||||
public function remove_row(Frame $row)
|
||||
{
|
||||
$key = $row->get_id();
|
||||
if (!isset($this->_frames[$key])) {
|
||||
return; // Presumably this row has already been removed
|
||||
}
|
||||
|
||||
$this->__row = $this->_num_rows--;
|
||||
|
||||
$rows = $this->_frames[$key]["rows"];
|
||||
$columns = $this->_frames[$key]["columns"];
|
||||
|
||||
// Remove all frames from this row
|
||||
foreach ($rows as $r) {
|
||||
foreach ($columns as $c) {
|
||||
if (isset($this->_cells[$r][$c])) {
|
||||
$id = $this->_cells[$r][$c]->get_id();
|
||||
|
||||
$this->_cells[$r][$c] = null;
|
||||
unset($this->_cells[$r][$c]);
|
||||
|
||||
// has multiple rows?
|
||||
if (isset($this->_frames[$id]) && count($this->_frames[$id]["rows"]) > 1) {
|
||||
// remove just the desired row, but leave the frame
|
||||
if (($row_key = array_search($r, $this->_frames[$id]["rows"])) !== false) {
|
||||
unset($this->_frames[$id]["rows"][$row_key]);
|
||||
}
|
||||
continue;
|
||||
}
|
||||
|
||||
$this->_frames[$id] = null;
|
||||
unset($this->_frames[$id]);
|
||||
}
|
||||
}
|
||||
|
||||
$this->_rows[$r] = null;
|
||||
unset($this->_rows[$r]);
|
||||
}
|
||||
|
||||
$this->_frames[$key] = null;
|
||||
unset($this->_frames[$key]);
|
||||
}
|
||||
|
||||
/**
|
||||
* Remove a row group from the cellmap.
|
||||
*
|
||||
* @param Frame $group The group to remove
|
||||
*/
|
||||
public function remove_row_group(Frame $group)
|
||||
{
|
||||
$key = $group->get_id();
|
||||
if (!isset($this->_frames[$key])) {
|
||||
return; // Presumably this row has already been removed
|
||||
}
|
||||
|
||||
$iter = $group->get_first_child();
|
||||
while ($iter) {
|
||||
$this->remove_row($iter);
|
||||
$iter = $iter->get_next_sibling();
|
||||
}
|
||||
|
||||
$this->_frames[$key] = null;
|
||||
unset($this->_frames[$key]);
|
||||
}
|
||||
|
||||
/**
|
||||
* Update a row group after rows have been removed
|
||||
*
|
||||
* @param Frame $group The group to update
|
||||
* @param Frame $last_row The last row in the row group
|
||||
*/
|
||||
public function update_row_group(Frame $group, Frame $last_row)
|
||||
{
|
||||
$g_key = $group->get_id();
|
||||
|
||||
$first_index = $this->_frames[$g_key]["rows"][0];
|
||||
$last_index = $first_index;
|
||||
$row = $last_row;
|
||||
while ($row = $row->get_prev_sibling()) {
|
||||
$last_index++;
|
||||
}
|
||||
|
||||
$this->_frames[$g_key]["rows"] = range($first_index, $last_index);
|
||||
}
|
||||
|
||||
public function assign_x_positions(): void
|
||||
{
|
||||
// Pre-condition: widths must be resolved and assigned to columns and
|
||||
// column[0]["x"] must be set.
|
||||
|
||||
if ($this->_columns_locked) {
|
||||
return;
|
||||
}
|
||||
|
||||
$x = $this->_columns[0]["x"];
|
||||
foreach (array_keys($this->_columns) as $j) {
|
||||
$this->_columns[$j]["x"] = $x;
|
||||
$x += $this->_columns[$j]["used-width"];
|
||||
}
|
||||
}
|
||||
|
||||
public function assign_frame_heights(): void
|
||||
{
|
||||
// Pre-condition: widths and heights of each column & row must be
|
||||
// calcluated
|
||||
foreach ($this->_frames as $arr) {
|
||||
$frame = $arr["frame"];
|
||||
|
||||
$h = 0.0;
|
||||
foreach ($arr["rows"] as $row) {
|
||||
if (!isset($this->_rows[$row])) {
|
||||
// The row has been removed because of a page split, so skip it.
|
||||
continue;
|
||||
}
|
||||
|
||||
$h += $this->_rows[$row]["height"];
|
||||
}
|
||||
|
||||
if ($frame instanceof TableCellFrameDecorator) {
|
||||
$frame->set_cell_height($h);
|
||||
} else {
|
||||
$frame->get_style()->set_used("height", $h);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Re-adjust frame height if the table height is larger than its content
|
||||
*/
|
||||
public function set_frame_heights(float $table_height, float $content_height): void
|
||||
{
|
||||
// Distribute the increased height proportionally amongst each row
|
||||
foreach ($this->_frames as $arr) {
|
||||
$frame = $arr["frame"];
|
||||
|
||||
$h = 0.0;
|
||||
foreach ($arr["rows"] as $row) {
|
||||
if (!isset($this->_rows[$row])) {
|
||||
continue;
|
||||
}
|
||||
|
||||
$h += $this->_rows[$row]["height"];
|
||||
}
|
||||
|
||||
if ($content_height > 0) {
|
||||
$new_height = ($h / $content_height) * $table_height;
|
||||
} else {
|
||||
$new_height = 0.0;
|
||||
}
|
||||
|
||||
if ($frame instanceof TableCellFrameDecorator) {
|
||||
$frame->set_cell_height($new_height);
|
||||
} else {
|
||||
$frame->get_style()->set_used("height", $new_height);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Used for debugging:
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
public function __toString(): string
|
||||
{
|
||||
$str = "";
|
||||
$str .= "Columns:<br/>";
|
||||
$str .= Helpers::pre_r($this->_columns, true);
|
||||
$str .= "Rows:<br/>";
|
||||
$str .= Helpers::pre_r($this->_rows, true);
|
||||
|
||||
$str .= "Frames:<br/>";
|
||||
$arr = [];
|
||||
foreach ($this->_frames as $key => $val) {
|
||||
$arr[$key] = ["columns" => $val["columns"], "rows" => $val["rows"]];
|
||||
}
|
||||
|
||||
$str .= Helpers::pre_r($arr, true);
|
||||
|
||||
if (php_sapi_name() == "cli") {
|
||||
$str = strip_tags(str_replace(["<br/>", "<b>", "</b>"],
|
||||
["\n", chr(27) . "[01;33m", chr(27) . "[0m"],
|
||||
$str));
|
||||
}
|
||||
|
||||
return $str;
|
||||
}
|
||||
}
|
|
@ -0,0 +1,652 @@
|
|||
<?php
|
||||
/**
|
||||
* @package dompdf
|
||||
* @link https://github.com/dompdf/dompdf
|
||||
* @license http://www.gnu.org/copyleft/lesser.html GNU Lesser General Public License
|
||||
*/
|
||||
namespace Dompdf\Css;
|
||||
|
||||
use Dompdf\Frame;
|
||||
use Dompdf\Helpers;
|
||||
|
||||
/**
|
||||
* Translates HTML 4.0 attributes into CSS rules
|
||||
*
|
||||
* @package dompdf
|
||||
*/
|
||||
class AttributeTranslator
|
||||
{
|
||||
static $_style_attr = "_html_style_attribute";
|
||||
|
||||
// Munged data originally from
|
||||
// http://www.w3.org/TR/REC-html40/index/attributes.html
|
||||
// http://www.cs.tut.fi/~jkorpela/html2css.html
|
||||
private static $__ATTRIBUTE_LOOKUP = [
|
||||
//'caption' => array ( 'align' => '', ),
|
||||
'img' => [
|
||||
'align' => [
|
||||
'bottom' => 'vertical-align: baseline;',
|
||||
'middle' => 'vertical-align: middle;',
|
||||
'top' => 'vertical-align: top;',
|
||||
'left' => 'float: left;',
|
||||
'right' => 'float: right;'
|
||||
],
|
||||
'border' => 'border: %0.2Fpx solid;',
|
||||
'height' => '_set_px_height',
|
||||
'hspace' => 'padding-left: %1$0.2Fpx; padding-right: %1$0.2Fpx;',
|
||||
'vspace' => 'padding-top: %1$0.2Fpx; padding-bottom: %1$0.2Fpx;',
|
||||
'width' => '_set_px_width',
|
||||
],
|
||||
'table' => [
|
||||
'align' => [
|
||||
'left' => 'margin-left: 0; margin-right: auto;',
|
||||
'center' => 'margin-left: auto; margin-right: auto;',
|
||||
'right' => 'margin-left: auto; margin-right: 0;'
|
||||
],
|
||||
'bgcolor' => 'background-color: %s;',
|
||||
'border' => '_set_table_border',
|
||||
'cellpadding' => '_set_table_cellpadding', //'border-spacing: %0.2F; border-collapse: separate;',
|
||||
'cellspacing' => '_set_table_cellspacing',
|
||||
'frame' => [
|
||||
'void' => 'border-style: none;',
|
||||
'above' => 'border-top-style: solid;',
|
||||
'below' => 'border-bottom-style: solid;',
|
||||
'hsides' => 'border-left-style: solid; border-right-style: solid;',
|
||||
'vsides' => 'border-top-style: solid; border-bottom-style: solid;',
|
||||
'lhs' => 'border-left-style: solid;',
|
||||
'rhs' => 'border-right-style: solid;',
|
||||
'box' => 'border-style: solid;',
|
||||
'border' => 'border-style: solid;'
|
||||
],
|
||||
'rules' => '_set_table_rules',
|
||||
'width' => 'width: %s;',
|
||||
],
|
||||
'hr' => [
|
||||
'align' => '_set_hr_align', // Need to grab width to set 'left' & 'right' correctly
|
||||
'noshade' => 'border-style: solid;',
|
||||
'size' => '_set_hr_size', //'border-width: %0.2F px;',
|
||||
'width' => 'width: %s;',
|
||||
],
|
||||
'div' => [
|
||||
'align' => 'text-align: %s;',
|
||||
],
|
||||
'h1' => [
|
||||
'align' => 'text-align: %s;',
|
||||
],
|
||||
'h2' => [
|
||||
'align' => 'text-align: %s;',
|
||||
],
|
||||
'h3' => [
|
||||
'align' => 'text-align: %s;',
|
||||
],
|
||||
'h4' => [
|
||||
'align' => 'text-align: %s;',
|
||||
],
|
||||
'h5' => [
|
||||
'align' => 'text-align: %s;',
|
||||
],
|
||||
'h6' => [
|
||||
'align' => 'text-align: %s;',
|
||||
],
|
||||
//TODO: translate more form element attributes
|
||||
'input' => [
|
||||
'size' => '_set_input_width'
|
||||
],
|
||||
'p' => [
|
||||
'align' => 'text-align: %s;',
|
||||
],
|
||||
// 'col' => array(
|
||||
// 'align' => '',
|
||||
// 'valign' => '',
|
||||
// ),
|
||||
// 'colgroup' => array(
|
||||
// 'align' => '',
|
||||
// 'valign' => '',
|
||||
// ),
|
||||
'tbody' => [
|
||||
'align' => '_set_table_row_align',
|
||||
'valign' => '_set_table_row_valign',
|
||||
],
|
||||
'td' => [
|
||||
'align' => 'text-align: %s;',
|
||||
'bgcolor' => '_set_background_color',
|
||||
'height' => 'height: %s;',
|
||||
'nowrap' => 'white-space: nowrap;',
|
||||
'valign' => 'vertical-align: %s;',
|
||||
'width' => 'width: %s;',
|
||||
],
|
||||
'tfoot' => [
|
||||
'align' => '_set_table_row_align',
|
||||
'valign' => '_set_table_row_valign',
|
||||
],
|
||||
'th' => [
|
||||
'align' => 'text-align: %s;',
|
||||
'bgcolor' => '_set_background_color',
|
||||
'height' => 'height: %s;',
|
||||
'nowrap' => 'white-space: nowrap;',
|
||||
'valign' => 'vertical-align: %s;',
|
||||
'width' => 'width: %s;',
|
||||
],
|
||||
'thead' => [
|
||||
'align' => '_set_table_row_align',
|
||||
'valign' => '_set_table_row_valign',
|
||||
],
|
||||
'tr' => [
|
||||
'align' => '_set_table_row_align',
|
||||
'bgcolor' => '_set_table_row_bgcolor',
|
||||
'valign' => '_set_table_row_valign',
|
||||
],
|
||||
'body' => [
|
||||
'background' => 'background-image: url(%s);',
|
||||
'bgcolor' => '_set_background_color',
|
||||
'link' => '_set_body_link',
|
||||
'text' => '_set_color',
|
||||
],
|
||||
'br' => [
|
||||
'clear' => 'clear: %s;',
|
||||
],
|
||||
'basefont' => [
|
||||
'color' => '_set_color',
|
||||
'face' => 'font-family: %s;',
|
||||
'size' => '_set_basefont_size',
|
||||
],
|
||||
'font' => [
|
||||
'color' => '_set_color',
|
||||
'face' => 'font-family: %s;',
|
||||
'size' => '_set_font_size',
|
||||
],
|
||||
'dir' => [
|
||||
'compact' => 'margin: 0.5em 0;',
|
||||
],
|
||||
'dl' => [
|
||||
'compact' => 'margin: 0.5em 0;',
|
||||
],
|
||||
'menu' => [
|
||||
'compact' => 'margin: 0.5em 0;',
|
||||
],
|
||||
'ol' => [
|
||||
'compact' => 'margin: 0.5em 0;',
|
||||
'start' => 'counter-reset: -dompdf-default-counter %d;',
|
||||
'type' => 'list-style-type: %s;',
|
||||
],
|
||||
'ul' => [
|
||||
'compact' => 'margin: 0.5em 0;',
|
||||
'type' => 'list-style-type: %s;',
|
||||
],
|
||||
'li' => [
|
||||
'type' => 'list-style-type: %s;',
|
||||
'value' => 'counter-reset: -dompdf-default-counter %d;',
|
||||
],
|
||||
'pre' => [
|
||||
'width' => 'width: %s;',
|
||||
],
|
||||
];
|
||||
|
||||
protected static $_last_basefont_size = 3;
|
||||
protected static $_font_size_lookup = [
|
||||
// For basefont support
|
||||
-3 => "4pt",
|
||||
-2 => "5pt",
|
||||
-1 => "6pt",
|
||||
0 => "7pt",
|
||||
|
||||
1 => "8pt",
|
||||
2 => "10pt",
|
||||
3 => "12pt",
|
||||
4 => "14pt",
|
||||
5 => "18pt",
|
||||
6 => "24pt",
|
||||
7 => "34pt",
|
||||
|
||||
// For basefont support
|
||||
8 => "48pt",
|
||||
9 => "44pt",
|
||||
10 => "52pt",
|
||||
11 => "60pt",
|
||||
];
|
||||
|
||||
/**
|
||||
* @param Frame $frame
|
||||
*/
|
||||
static function translate_attributes(Frame $frame)
|
||||
{
|
||||
$node = $frame->get_node();
|
||||
$tag = $node->nodeName;
|
||||
|
||||
if (!isset(self::$__ATTRIBUTE_LOOKUP[$tag])) {
|
||||
return;
|
||||
}
|
||||
|
||||
$valid_attrs = self::$__ATTRIBUTE_LOOKUP[$tag];
|
||||
$attrs = $node->attributes;
|
||||
$style = rtrim($node->getAttribute(self::$_style_attr), "; ");
|
||||
if ($style != "") {
|
||||
$style .= ";";
|
||||
}
|
||||
|
||||
foreach ($attrs as $attr => $attr_node) {
|
||||
if (!isset($valid_attrs[$attr])) {
|
||||
continue;
|
||||
}
|
||||
|
||||
$value = $attr_node->value;
|
||||
|
||||
$target = $valid_attrs[$attr];
|
||||
|
||||
// Look up $value in $target, if $target is an array:
|
||||
if (is_array($target)) {
|
||||
if (isset($target[$value])) {
|
||||
$style .= " " . self::_resolve_target($node, $target[$value], $value);
|
||||
}
|
||||
} else {
|
||||
// otherwise use target directly
|
||||
$style .= " " . self::_resolve_target($node, $target, $value);
|
||||
}
|
||||
}
|
||||
|
||||
if (!is_null($style)) {
|
||||
$style = ltrim($style);
|
||||
$node->setAttribute(self::$_style_attr, $style);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* @param \DOMNode $node
|
||||
* @param string $target
|
||||
* @param string $value
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
protected static function _resolve_target(\DOMNode $node, $target, $value)
|
||||
{
|
||||
if ($target[0] === "_") {
|
||||
return self::$target($node, $value);
|
||||
}
|
||||
|
||||
return $value ? sprintf($target, $value) : "";
|
||||
}
|
||||
|
||||
/**
|
||||
* @param \DOMElement $node
|
||||
* @param string $new_style
|
||||
*/
|
||||
static function append_style(\DOMElement $node, $new_style)
|
||||
{
|
||||
$style = rtrim($node->getAttribute(self::$_style_attr), ";");
|
||||
$style .= $new_style;
|
||||
$style = ltrim($style, ";");
|
||||
$node->setAttribute(self::$_style_attr, $style);
|
||||
}
|
||||
|
||||
/**
|
||||
* @param \DOMNode $node
|
||||
*
|
||||
* @return \DOMNodeList|\DOMElement[]
|
||||
*/
|
||||
protected static function get_cell_list(\DOMNode $node)
|
||||
{
|
||||
$xpath = new \DOMXpath($node->ownerDocument);
|
||||
|
||||
switch ($node->nodeName) {
|
||||
default:
|
||||
case "table":
|
||||
$query = "tr/td | thead/tr/td | tbody/tr/td | tfoot/tr/td | tr/th | thead/tr/th | tbody/tr/th | tfoot/tr/th";
|
||||
break;
|
||||
|
||||
case "tbody":
|
||||
case "tfoot":
|
||||
case "thead":
|
||||
$query = "tr/td | tr/th";
|
||||
break;
|
||||
|
||||
case "tr":
|
||||
$query = "td | th";
|
||||
break;
|
||||
}
|
||||
|
||||
return $xpath->query($query, $node);
|
||||
}
|
||||
|
||||
/**
|
||||
* @param string $value
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
protected static function _get_valid_color($value)
|
||||
{
|
||||
if (preg_match('/^#?([0-9A-F]{6})$/i', $value, $matches)) {
|
||||
$value = "#$matches[1]";
|
||||
}
|
||||
|
||||
return $value;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param \DOMElement $node
|
||||
* @param string $value
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
protected static function _set_color(\DOMElement $node, $value)
|
||||
{
|
||||
$value = self::_get_valid_color($value);
|
||||
|
||||
return "color: $value;";
|
||||
}
|
||||
|
||||
/**
|
||||
* @param \DOMElement $node
|
||||
* @param string $value
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
protected static function _set_background_color(\DOMElement $node, $value)
|
||||
{
|
||||
$value = self::_get_valid_color($value);
|
||||
|
||||
return "background-color: $value;";
|
||||
}
|
||||
|
||||
protected static function _set_px_width(\DOMElement $node, string $value): string
|
||||
{
|
||||
$v = trim($value);
|
||||
|
||||
if (Helpers::is_percent($v)) {
|
||||
return sprintf("width: %s;", $v);
|
||||
}
|
||||
|
||||
if (is_numeric(mb_substr($v, 0, 1))) {
|
||||
return sprintf("width: %spx;", (float) $v);
|
||||
}
|
||||
|
||||
return "";
|
||||
}
|
||||
|
||||
protected static function _set_px_height(\DOMElement $node, string $value): string
|
||||
{
|
||||
$v = trim($value);
|
||||
|
||||
if (Helpers::is_percent($v)) {
|
||||
return sprintf("height: %s;", $v);
|
||||
}
|
||||
|
||||
if (is_numeric(mb_substr($v, 0, 1))) {
|
||||
return sprintf("height: %spx;", (float) $v);
|
||||
}
|
||||
|
||||
return "";
|
||||
}
|
||||
|
||||
/**
|
||||
* @param \DOMElement $node
|
||||
* @param string $value
|
||||
*
|
||||
* @return null
|
||||
*/
|
||||
protected static function _set_table_cellpadding(\DOMElement $node, $value)
|
||||
{
|
||||
$cell_list = self::get_cell_list($node);
|
||||
|
||||
foreach ($cell_list as $cell) {
|
||||
self::append_style($cell, "; padding: {$value}px;");
|
||||
}
|
||||
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param \DOMElement $node
|
||||
* @param string $value
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
protected static function _set_table_border(\DOMElement $node, $value)
|
||||
{
|
||||
return "border-width: $value" . "px;";
|
||||
}
|
||||
|
||||
/**
|
||||
* @param \DOMElement $node
|
||||
* @param string $value
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
protected static function _set_table_cellspacing(\DOMElement $node, $value)
|
||||
{
|
||||
$style = rtrim($node->getAttribute(self::$_style_attr), ";");
|
||||
|
||||
if ($value == 0) {
|
||||
$style .= "; border-collapse: collapse;";
|
||||
} else {
|
||||
$style .= "; border-spacing: {$value}px; border-collapse: separate;";
|
||||
}
|
||||
|
||||
return ltrim($style, ";");
|
||||
}
|
||||
|
||||
/**
|
||||
* @param \DOMElement $node
|
||||
* @param string $value
|
||||
*
|
||||
* @return null|string
|
||||
*/
|
||||
protected static function _set_table_rules(\DOMElement $node, $value)
|
||||
{
|
||||
$new_style = "; border-collapse: collapse;";
|
||||
|
||||
switch ($value) {
|
||||
case "none":
|
||||
$new_style .= "border-style: none;";
|
||||
break;
|
||||
|
||||
case "groups":
|
||||
// FIXME: unsupported
|
||||
return null;
|
||||
|
||||
case "rows":
|
||||
$new_style .= "border-style: solid none solid none; border-width: 1px; ";
|
||||
break;
|
||||
|
||||
case "cols":
|
||||
$new_style .= "border-style: none solid none solid; border-width: 1px; ";
|
||||
break;
|
||||
|
||||
case "all":
|
||||
$new_style .= "border-style: solid; border-width: 1px; ";
|
||||
break;
|
||||
|
||||
default:
|
||||
// Invalid value
|
||||
return null;
|
||||
}
|
||||
|
||||
$cell_list = self::get_cell_list($node);
|
||||
|
||||
foreach ($cell_list as $cell) {
|
||||
$style = $cell->getAttribute(self::$_style_attr);
|
||||
$style .= $new_style;
|
||||
$cell->setAttribute(self::$_style_attr, $style);
|
||||
}
|
||||
|
||||
$style = rtrim($node->getAttribute(self::$_style_attr), ";");
|
||||
$style .= "; border-collapse: collapse; ";
|
||||
|
||||
return ltrim($style, "; ");
|
||||
}
|
||||
|
||||
/**
|
||||
* @param \DOMElement $node
|
||||
* @param string $value
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
protected static function _set_hr_size(\DOMElement $node, $value)
|
||||
{
|
||||
$style = rtrim($node->getAttribute(self::$_style_attr), ";");
|
||||
$style .= "; border-width: " . max(0, $value - 2) . "; ";
|
||||
|
||||
return ltrim($style, "; ");
|
||||
}
|
||||
|
||||
/**
|
||||
* @param \DOMElement $node
|
||||
* @param string $value
|
||||
*
|
||||
* @return null|string
|
||||
*/
|
||||
protected static function _set_hr_align(\DOMElement $node, $value)
|
||||
{
|
||||
$style = rtrim($node->getAttribute(self::$_style_attr), ";");
|
||||
$width = $node->getAttribute("width");
|
||||
|
||||
if ($width == "") {
|
||||
$width = "100%";
|
||||
}
|
||||
|
||||
$remainder = 100 - (double)rtrim($width, "% ");
|
||||
|
||||
switch ($value) {
|
||||
case "left":
|
||||
$style .= "; margin-right: $remainder %;";
|
||||
break;
|
||||
|
||||
case "right":
|
||||
$style .= "; margin-left: $remainder %;";
|
||||
break;
|
||||
|
||||
case "center":
|
||||
$style .= "; margin-left: auto; margin-right: auto;";
|
||||
break;
|
||||
|
||||
default:
|
||||
return null;
|
||||
}
|
||||
|
||||
return ltrim($style, "; ");
|
||||
}
|
||||
|
||||
/**
|
||||
* @param \DOMElement $node
|
||||
* @param string $value
|
||||
*
|
||||
* @return null|string
|
||||
*/
|
||||
protected static function _set_input_width(\DOMElement $node, $value)
|
||||
{
|
||||
if (empty($value)) { return null; }
|
||||
|
||||
if ($node->hasAttribute("type") && in_array(strtolower($node->getAttribute("type")), ["text","password"])) {
|
||||
return sprintf("width: %Fem", (((int)$value * .65)+2));
|
||||
} else {
|
||||
return sprintf("width: %upx;", (int)$value);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* @param \DOMElement $node
|
||||
* @param string $value
|
||||
*
|
||||
* @return null
|
||||
*/
|
||||
protected static function _set_table_row_align(\DOMElement $node, $value)
|
||||
{
|
||||
$cell_list = self::get_cell_list($node);
|
||||
|
||||
foreach ($cell_list as $cell) {
|
||||
self::append_style($cell, "; text-align: $value;");
|
||||
}
|
||||
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param \DOMElement $node
|
||||
* @param string $value
|
||||
*
|
||||
* @return null
|
||||
*/
|
||||
protected static function _set_table_row_valign(\DOMElement $node, $value)
|
||||
{
|
||||
$cell_list = self::get_cell_list($node);
|
||||
|
||||
foreach ($cell_list as $cell) {
|
||||
self::append_style($cell, "; vertical-align: $value;");
|
||||
}
|
||||
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param \DOMElement $node
|
||||
* @param string $value
|
||||
*
|
||||
* @return null
|
||||
*/
|
||||
protected static function _set_table_row_bgcolor(\DOMElement $node, $value)
|
||||
{
|
||||
$cell_list = self::get_cell_list($node);
|
||||
$value = self::_get_valid_color($value);
|
||||
|
||||
foreach ($cell_list as $cell) {
|
||||
self::append_style($cell, "; background-color: $value;");
|
||||
}
|
||||
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param \DOMElement $node
|
||||
* @param string $value
|
||||
*
|
||||
* @return null
|
||||
*/
|
||||
protected static function _set_body_link(\DOMElement $node, $value)
|
||||
{
|
||||
$a_list = $node->getElementsByTagName("a");
|
||||
$value = self::_get_valid_color($value);
|
||||
|
||||
foreach ($a_list as $a) {
|
||||
self::append_style($a, "; color: $value;");
|
||||
}
|
||||
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param \DOMElement $node
|
||||
* @param string $value
|
||||
*
|
||||
* @return null
|
||||
*/
|
||||
protected static function _set_basefont_size(\DOMElement $node, $value)
|
||||
{
|
||||
// FIXME: ? we don't actually set the font size of anything here, just
|
||||
// the base size for later modification by <font> tags.
|
||||
self::$_last_basefont_size = $value;
|
||||
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param \DOMElement $node
|
||||
* @param string $value
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
protected static function _set_font_size(\DOMElement $node, $value)
|
||||
{
|
||||
$style = $node->getAttribute(self::$_style_attr);
|
||||
|
||||
if ($value[0] === "-" || $value[0] === "+") {
|
||||
$value = self::$_last_basefont_size + (int)$value;
|
||||
}
|
||||
|
||||
if (isset(self::$_font_size_lookup[$value])) {
|
||||
$style .= "; font-size: " . self::$_font_size_lookup[$value] . ";";
|
||||
} else {
|
||||
$style .= "; font-size: $value;";
|
||||
}
|
||||
|
||||
return ltrim($style, "; ");
|
||||
}
|
||||
}
|
|
@ -0,0 +1,339 @@
|
|||
<?php
|
||||
|
||||
/**
|
||||
* @package dompdf
|
||||
* @link https://github.com/dompdf/dompdf
|
||||
* @license http://www.gnu.org/copyleft/lesser.html GNU Lesser General Public License
|
||||
*/
|
||||
namespace Dompdf\Css;
|
||||
|
||||
use Dompdf\Helpers;
|
||||
|
||||
class Color
|
||||
{
|
||||
static $cssColorNames = [
|
||||
"aliceblue" => "F0F8FF",
|
||||
"antiquewhite" => "FAEBD7",
|
||||
"aqua" => "00FFFF",
|
||||
"aquamarine" => "7FFFD4",
|
||||
"azure" => "F0FFFF",
|
||||
"beige" => "F5F5DC",
|
||||
"bisque" => "FFE4C4",
|
||||
"black" => "000000",
|
||||
"blanchedalmond" => "FFEBCD",
|
||||
"blue" => "0000FF",
|
||||
"blueviolet" => "8A2BE2",
|
||||
"brown" => "A52A2A",
|
||||
"burlywood" => "DEB887",
|
||||
"cadetblue" => "5F9EA0",
|
||||
"chartreuse" => "7FFF00",
|
||||
"chocolate" => "D2691E",
|
||||
"coral" => "FF7F50",
|
||||
"cornflowerblue" => "6495ED",
|
||||
"cornsilk" => "FFF8DC",
|
||||
"crimson" => "DC143C",
|
||||
"cyan" => "00FFFF",
|
||||
"darkblue" => "00008B",
|
||||
"darkcyan" => "008B8B",
|
||||
"darkgoldenrod" => "B8860B",
|
||||
"darkgray" => "A9A9A9",
|
||||
"darkgreen" => "006400",
|
||||
"darkgrey" => "A9A9A9",
|
||||
"darkkhaki" => "BDB76B",
|
||||
"darkmagenta" => "8B008B",
|
||||
"darkolivegreen" => "556B2F",
|
||||
"darkorange" => "FF8C00",
|
||||
"darkorchid" => "9932CC",
|
||||
"darkred" => "8B0000",
|
||||
"darksalmon" => "E9967A",
|
||||
"darkseagreen" => "8FBC8F",
|
||||
"darkslateblue" => "483D8B",
|
||||
"darkslategray" => "2F4F4F",
|
||||
"darkslategrey" => "2F4F4F",
|
||||
"darkturquoise" => "00CED1",
|
||||
"darkviolet" => "9400D3",
|
||||
"deeppink" => "FF1493",
|
||||
"deepskyblue" => "00BFFF",
|
||||
"dimgray" => "696969",
|
||||
"dimgrey" => "696969",
|
||||
"dodgerblue" => "1E90FF",
|
||||
"firebrick" => "B22222",
|
||||
"floralwhite" => "FFFAF0",
|
||||
"forestgreen" => "228B22",
|
||||
"fuchsia" => "FF00FF",
|
||||
"gainsboro" => "DCDCDC",
|
||||
"ghostwhite" => "F8F8FF",
|
||||
"gold" => "FFD700",
|
||||
"goldenrod" => "DAA520",
|
||||
"gray" => "808080",
|
||||
"green" => "008000",
|
||||
"greenyellow" => "ADFF2F",
|
||||
"grey" => "808080",
|
||||
"honeydew" => "F0FFF0",
|
||||
"hotpink" => "FF69B4",
|
||||
"indianred" => "CD5C5C",
|
||||
"indigo" => "4B0082",
|
||||
"ivory" => "FFFFF0",
|
||||
"khaki" => "F0E68C",
|
||||
"lavender" => "E6E6FA",
|
||||
"lavenderblush" => "FFF0F5",
|
||||
"lawngreen" => "7CFC00",
|
||||
"lemonchiffon" => "FFFACD",
|
||||
"lightblue" => "ADD8E6",
|
||||
"lightcoral" => "F08080",
|
||||
"lightcyan" => "E0FFFF",
|
||||
"lightgoldenrodyellow" => "FAFAD2",
|
||||
"lightgray" => "D3D3D3",
|
||||
"lightgreen" => "90EE90",
|
||||
"lightgrey" => "D3D3D3",
|
||||
"lightpink" => "FFB6C1",
|
||||
"lightsalmon" => "FFA07A",
|
||||
"lightseagreen" => "20B2AA",
|
||||
"lightskyblue" => "87CEFA",
|
||||
"lightslategray" => "778899",
|
||||
"lightslategrey" => "778899",
|
||||
"lightsteelblue" => "B0C4DE",
|
||||
"lightyellow" => "FFFFE0",
|
||||
"lime" => "00FF00",
|
||||
"limegreen" => "32CD32",
|
||||
"linen" => "FAF0E6",
|
||||
"magenta" => "FF00FF",
|
||||
"maroon" => "800000",
|
||||
"mediumaquamarine" => "66CDAA",
|
||||
"mediumblue" => "0000CD",
|
||||
"mediumorchid" => "BA55D3",
|
||||
"mediumpurple" => "9370DB",
|
||||
"mediumseagreen" => "3CB371",
|
||||
"mediumslateblue" => "7B68EE",
|
||||
"mediumspringgreen" => "00FA9A",
|
||||
"mediumturquoise" => "48D1CC",
|
||||
"mediumvioletred" => "C71585",
|
||||
"midnightblue" => "191970",
|
||||
"mintcream" => "F5FFFA",
|
||||
"mistyrose" => "FFE4E1",
|
||||
"moccasin" => "FFE4B5",
|
||||
"navajowhite" => "FFDEAD",
|
||||
"navy" => "000080",
|
||||
"oldlace" => "FDF5E6",
|
||||
"olive" => "808000",
|
||||
"olivedrab" => "6B8E23",
|
||||
"orange" => "FFA500",
|
||||
"orangered" => "FF4500",
|
||||
"orchid" => "DA70D6",
|
||||
"palegoldenrod" => "EEE8AA",
|
||||
"palegreen" => "98FB98",
|
||||
"paleturquoise" => "AFEEEE",
|
||||
"palevioletred" => "DB7093",
|
||||
"papayawhip" => "FFEFD5",
|
||||
"peachpuff" => "FFDAB9",
|
||||
"peru" => "CD853F",
|
||||
"pink" => "FFC0CB",
|
||||
"plum" => "DDA0DD",
|
||||
"powderblue" => "B0E0E6",
|
||||
"purple" => "800080",
|
||||
"red" => "FF0000",
|
||||
"rosybrown" => "BC8F8F",
|
||||
"royalblue" => "4169E1",
|
||||
"saddlebrown" => "8B4513",
|
||||
"salmon" => "FA8072",
|
||||
"sandybrown" => "F4A460",
|
||||
"seagreen" => "2E8B57",
|
||||
"seashell" => "FFF5EE",
|
||||
"sienna" => "A0522D",
|
||||
"silver" => "C0C0C0",
|
||||
"skyblue" => "87CEEB",
|
||||
"slateblue" => "6A5ACD",
|
||||
"slategray" => "708090",
|
||||
"slategrey" => "708090",
|
||||
"snow" => "FFFAFA",
|
||||
"springgreen" => "00FF7F",
|
||||
"steelblue" => "4682B4",
|
||||
"tan" => "D2B48C",
|
||||
"teal" => "008080",
|
||||
"thistle" => "D8BFD8",
|
||||
"tomato" => "FF6347",
|
||||
"turquoise" => "40E0D0",
|
||||
"violet" => "EE82EE",
|
||||
"wheat" => "F5DEB3",
|
||||
"white" => "FFFFFF",
|
||||
"whitesmoke" => "F5F5F5",
|
||||
"yellow" => "FFFF00",
|
||||
"yellowgreen" => "9ACD32",
|
||||
];
|
||||
|
||||
/**
|
||||
* @param array|string|null $color
|
||||
* @return array|string|null
|
||||
*/
|
||||
static function parse($color)
|
||||
{
|
||||
if ($color === null) {
|
||||
return null;
|
||||
}
|
||||
|
||||
if (is_array($color)) {
|
||||
// Assume the array has the right format...
|
||||
// FIXME: should/could verify this.
|
||||
return $color;
|
||||
}
|
||||
|
||||
static $cache = [];
|
||||
|
||||
$color = strtolower($color);
|
||||
|
||||
if (isset($cache[$color])) {
|
||||
return $cache[$color];
|
||||
}
|
||||
|
||||
if ($color === "transparent") {
|
||||
return $cache[$color] = $color;
|
||||
}
|
||||
|
||||
if (isset(self::$cssColorNames[$color])) {
|
||||
return $cache[$color] = self::getArray(self::$cssColorNames[$color]);
|
||||
}
|
||||
|
||||
// https://www.w3.org/TR/css-color-4/#hex-notation
|
||||
if (mb_substr($color, 0, 1) === "#") {
|
||||
$length = mb_strlen($color);
|
||||
$alpha = 1.0;
|
||||
|
||||
// #rgb format
|
||||
if ($length === 4) {
|
||||
return $cache[$color] = self::getArray($color[1] . $color[1] . $color[2] . $color[2] . $color[3] . $color[3]);
|
||||
}
|
||||
|
||||
// #rgba format
|
||||
if ($length === 5) {
|
||||
if (ctype_xdigit($color[4])) {
|
||||
$alpha = round(hexdec($color[4] . $color[4])/255, 2);
|
||||
}
|
||||
return $cache[$color] = self::getArray($color[1] . $color[1] . $color[2] . $color[2] . $color[3] . $color[3], $alpha);
|
||||
}
|
||||
|
||||
// #rrggbb format
|
||||
if ($length === 7) {
|
||||
return $cache[$color] = self::getArray(mb_substr($color, 1, 6));
|
||||
}
|
||||
|
||||
// #rrggbbaa format
|
||||
if ($length === 9) {
|
||||
if (ctype_xdigit(mb_substr($color, 7, 2))) {
|
||||
$alpha = round(hexdec(mb_substr($color, 7, 2))/255, 2);
|
||||
}
|
||||
return $cache[$color] = self::getArray(mb_substr($color, 1, 6), $alpha);
|
||||
}
|
||||
|
||||
return null;
|
||||
}
|
||||
|
||||
// rgb( r g b [/α] ) / rgb( r,g,b[,α] ) format and alias rgba()
|
||||
// https://www.w3.org/TR/css-color-4/#rgb-functions
|
||||
if (mb_substr($color, 0, 4) === "rgb(" || mb_substr($color, 0, 5) === "rgba(") {
|
||||
$i = mb_strpos($color, "(");
|
||||
$j = mb_strpos($color, ")");
|
||||
|
||||
// Bad color value
|
||||
if ($i === false || $j === false) {
|
||||
return null;
|
||||
}
|
||||
|
||||
$value_decl = trim(mb_substr($color, $i + 1, $j - $i - 1));
|
||||
|
||||
if (mb_strpos($value_decl, ",") === false) {
|
||||
// Space-separated values syntax `r g b` or `r g b / α`
|
||||
$parts = preg_split("/\s*\/\s*/", $value_decl);
|
||||
$triplet = preg_split("/\s+/", $parts[0]);
|
||||
$alpha = $parts[1] ?? 1.0;
|
||||
} else {
|
||||
// Comma-separated values syntax `r, g, b` or `r, g, b, α`
|
||||
$parts = preg_split("/\s*,\s*/", $value_decl);
|
||||
$triplet = array_slice($parts, 0, 3);
|
||||
$alpha = $parts[3] ?? 1.0;
|
||||
}
|
||||
|
||||
if (count($triplet) !== 3) {
|
||||
return null;
|
||||
}
|
||||
|
||||
// Parse alpha value
|
||||
if (Helpers::is_percent($alpha)) {
|
||||
$alpha = (float) $alpha / 100;
|
||||
} else {
|
||||
$alpha = (float) $alpha;
|
||||
}
|
||||
|
||||
$alpha = max(0.0, min($alpha, 1.0));
|
||||
|
||||
foreach ($triplet as &$c) {
|
||||
if (Helpers::is_percent($c)) {
|
||||
$c = round((float) $c * 2.55);
|
||||
}
|
||||
}
|
||||
|
||||
return $cache[$color] = self::getArray(vsprintf("%02X%02X%02X", $triplet), $alpha);
|
||||
}
|
||||
|
||||
// cmyk( c,m,y,k ) format
|
||||
// http://www.w3.org/TR/css3-gcpm/#cmyk-colors
|
||||
if (mb_substr($color, 0, 5) === "cmyk(") {
|
||||
$i = mb_strpos($color, "(");
|
||||
$j = mb_strpos($color, ")");
|
||||
|
||||
// Bad color value
|
||||
if ($i === false || $j === false) {
|
||||
return null;
|
||||
}
|
||||
|
||||
$values = explode(",", mb_substr($color, $i + 1, $j - $i - 1));
|
||||
|
||||
if (count($values) != 4) {
|
||||
return null;
|
||||
}
|
||||
|
||||
$values = array_map(function ($c) {
|
||||
return min(1.0, max(0.0, floatval(trim($c))));
|
||||
}, $values);
|
||||
|
||||
return $cache[$color] = self::getArray($values);
|
||||
}
|
||||
|
||||
// Invalid or unsupported color format
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param array|string $color
|
||||
* @param float $alpha
|
||||
* @return array
|
||||
*/
|
||||
static function getArray($color, $alpha = 1.0)
|
||||
{
|
||||
$c = [null, null, null, null, "alpha" => $alpha, "hex" => null];
|
||||
|
||||
if (is_array($color)) {
|
||||
$c = $color;
|
||||
$c["c"] = $c[0];
|
||||
$c["m"] = $c[1];
|
||||
$c["y"] = $c[2];
|
||||
$c["k"] = $c[3];
|
||||
$c["alpha"] = $alpha;
|
||||
$c["hex"] = "cmyk($c[0],$c[1],$c[2],$c[3])";
|
||||
} else {
|
||||
if (ctype_xdigit($color) === false || mb_strlen($color) !== 6) {
|
||||
// invalid color value ... expected 6-character hex
|
||||
return $c;
|
||||
}
|
||||
$c[0] = hexdec(mb_substr($color, 0, 2)) / 0xff;
|
||||
$c[1] = hexdec(mb_substr($color, 2, 2)) / 0xff;
|
||||
$c[2] = hexdec(mb_substr($color, 4, 2)) / 0xff;
|
||||
$c["r"] = $c[0];
|
||||
$c["g"] = $c[1];
|
||||
$c["b"] = $c[2];
|
||||
$c["alpha"] = $alpha;
|
||||
$c["hex"] = sprintf("#%s%02X", $color, round($alpha * 255));
|
||||
}
|
||||
|
||||
return $c;
|
||||
}
|
||||
}
|
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
|
@ -0,0 +1,27 @@
|
|||
<?php
|
||||
/**
|
||||
* @package dompdf
|
||||
* @link https://github.com/dompdf/dompdf
|
||||
* @license http://www.gnu.org/copyleft/lesser.html GNU Lesser General Public License
|
||||
*/
|
||||
namespace Dompdf;
|
||||
|
||||
/**
|
||||
* Standard exception thrown by DOMPDF classes
|
||||
*
|
||||
* @package dompdf
|
||||
*/
|
||||
class Exception extends \Exception
|
||||
{
|
||||
|
||||
/**
|
||||
* Class constructor
|
||||
*
|
||||
* @param string $message Error message
|
||||
* @param int $code Error code
|
||||
*/
|
||||
public function __construct($message = null, $code = 0)
|
||||
{
|
||||
parent::__construct($message, $code);
|
||||
}
|
||||
}
|
|
@ -0,0 +1,30 @@
|
|||
<?php
|
||||
/**
|
||||
* @package dompdf
|
||||
* @link https://github.com/dompdf/dompdf
|
||||
* @license http://www.gnu.org/copyleft/lesser.html GNU Lesser General Public License
|
||||
*/
|
||||
namespace Dompdf\Exception;
|
||||
|
||||
use Dompdf\Exception;
|
||||
|
||||
/**
|
||||
* Image exception thrown by DOMPDF
|
||||
*
|
||||
* @package dompdf
|
||||
*/
|
||||
class ImageException extends Exception
|
||||
{
|
||||
|
||||
/**
|
||||
* Class constructor
|
||||
*
|
||||
* @param string $message Error message
|
||||
* @param int $code Error code
|
||||
*/
|
||||
function __construct($message = null, $code = 0)
|
||||
{
|
||||
parent::__construct($message, $code);
|
||||
}
|
||||
|
||||
}
|
|
@ -0,0 +1,635 @@
|
|||
<?php
|
||||
/**
|
||||
* @package dompdf
|
||||
* @link https://github.com/dompdf/dompdf
|
||||
* @license http://www.gnu.org/copyleft/lesser.html GNU Lesser General Public License
|
||||
*/
|
||||
namespace Dompdf;
|
||||
|
||||
use FontLib\Font;
|
||||
|
||||
/**
|
||||
* The font metrics class
|
||||
*
|
||||
* This class provides information about fonts and text. It can resolve
|
||||
* font names into actual installed font files, as well as determine the
|
||||
* size of text in a particular font and size.
|
||||
*
|
||||
* @static
|
||||
* @package dompdf
|
||||
*/
|
||||
class FontMetrics
|
||||
{
|
||||
/**
|
||||
* Name of the user font families file
|
||||
*
|
||||
* This file must be writable by the webserver process only to update it
|
||||
* with save_font_families() after adding the .afm file references of a new font family
|
||||
* with FontMetrics::saveFontFamilies().
|
||||
* This is typically done only from command line with load_font.php on converting
|
||||
* ttf fonts to ufm with php-font-lib.
|
||||
*/
|
||||
const USER_FONTS_FILE = "installed-fonts.json";
|
||||
|
||||
|
||||
/**
|
||||
* Underlying {@link Canvas} object to perform text size calculations
|
||||
*
|
||||
* @var Canvas
|
||||
*/
|
||||
protected $canvas;
|
||||
|
||||
/**
|
||||
* Array of bundled font family names to variants
|
||||
*
|
||||
* @var array
|
||||
*/
|
||||
protected $bundledFonts = [];
|
||||
|
||||
/**
|
||||
* Array of user defined font family names to variants
|
||||
*
|
||||
* @var array
|
||||
*/
|
||||
protected $userFonts = [];
|
||||
|
||||
/**
|
||||
* combined list of all font families with absolute paths
|
||||
*
|
||||
* @var array
|
||||
*/
|
||||
protected $fontFamilies;
|
||||
|
||||
/**
|
||||
* @var Options
|
||||
*/
|
||||
private $options;
|
||||
|
||||
/**
|
||||
* Class initialization
|
||||
*/
|
||||
public function __construct(Canvas $canvas, Options $options)
|
||||
{
|
||||
$this->setCanvas($canvas);
|
||||
$this->setOptions($options);
|
||||
$this->loadFontFamilies();
|
||||
}
|
||||
|
||||
/**
|
||||
* @deprecated
|
||||
*/
|
||||
public function save_font_families()
|
||||
{
|
||||
$this->saveFontFamilies();
|
||||
}
|
||||
|
||||
/**
|
||||
* Saves the stored font family cache
|
||||
*
|
||||
* The name and location of the cache file are determined by {@link
|
||||
* FontMetrics::USER_FONTS_FILE}. This file should be writable by the
|
||||
* webserver process.
|
||||
*
|
||||
* @see FontMetrics::loadFontFamilies()
|
||||
*/
|
||||
public function saveFontFamilies()
|
||||
{
|
||||
file_put_contents($this->getUserFontsFilePath(), json_encode($this->userFonts, JSON_PRETTY_PRINT));
|
||||
}
|
||||
|
||||
/**
|
||||
* @deprecated
|
||||
*/
|
||||
public function load_font_families()
|
||||
{
|
||||
$this->loadFontFamilies();
|
||||
}
|
||||
|
||||
/**
|
||||
* Loads the stored font family cache
|
||||
*
|
||||
* @see FontMetrics::saveFontFamilies()
|
||||
*/
|
||||
public function loadFontFamilies()
|
||||
{
|
||||
$file = $this->options->getRootDir() . "/lib/fonts/installed-fonts.dist.json";
|
||||
$this->bundledFonts = json_decode(file_get_contents($file), true);
|
||||
|
||||
if (is_readable($this->getUserFontsFilePath())) {
|
||||
$this->userFonts = json_decode(file_get_contents($this->getUserFontsFilePath()), true);
|
||||
} else {
|
||||
$this->loadFontFamiliesLegacy();
|
||||
}
|
||||
}
|
||||
|
||||
private function loadFontFamiliesLegacy()
|
||||
{
|
||||
$legacyCacheFile = $this->options->getFontDir() . '/dompdf_font_family_cache.php';
|
||||
if (is_readable($legacyCacheFile)) {
|
||||
$fontDir = $this->options->getFontDir();
|
||||
$rootDir = $this->options->getRootDir();
|
||||
|
||||
if (!defined("DOMPDF_DIR")) { define("DOMPDF_DIR", $rootDir); }
|
||||
if (!defined("DOMPDF_FONT_DIR")) { define("DOMPDF_FONT_DIR", $fontDir); }
|
||||
|
||||
$cacheDataClosure = require $legacyCacheFile;
|
||||
$cacheData = is_array($cacheDataClosure) ? $cacheDataClosure : $cacheDataClosure($fontDir, $rootDir);
|
||||
if (is_array($cacheData)) {
|
||||
foreach ($cacheData as $family => $variants) {
|
||||
if (!isset($this->bundledFonts[$family]) && is_array($variants)) {
|
||||
foreach ($variants as $variant => $variantPath) {
|
||||
$variantName = basename($variantPath);
|
||||
$variantDir = dirname($variantPath);
|
||||
if ($variantDir == $fontDir) {
|
||||
$this->userFonts[$family][$variant] = $variantName;
|
||||
} else {
|
||||
$this->userFonts[$family][$variant] = $variantPath;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
$this->saveFontFamilies();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* @param array $style
|
||||
* @param string $remote_file
|
||||
* @param resource $context
|
||||
* @return bool
|
||||
* @deprecated
|
||||
*/
|
||||
public function register_font($style, $remote_file, $context = null)
|
||||
{
|
||||
return $this->registerFont($style, $remote_file);
|
||||
}
|
||||
|
||||
/**
|
||||
* @param array $style
|
||||
* @param string $remoteFile
|
||||
* @param resource $context
|
||||
* @return bool
|
||||
*/
|
||||
public function registerFont($style, $remoteFile, $context = null)
|
||||
{
|
||||
$fontname = mb_strtolower($style["family"]);
|
||||
$families = $this->getFontFamilies();
|
||||
|
||||
$entry = [];
|
||||
if (isset($families[$fontname])) {
|
||||
$entry = $families[$fontname];
|
||||
}
|
||||
|
||||
$styleString = $this->getType("{$style['weight']} {$style['style']}");
|
||||
|
||||
$remoteHash = md5($remoteFile);
|
||||
|
||||
$prefix = $fontname . "_" . $styleString;
|
||||
$prefix = trim($prefix, "-");
|
||||
if (function_exists('iconv')) {
|
||||
$prefix = @iconv('utf-8', 'us-ascii//TRANSLIT', $prefix);
|
||||
}
|
||||
$prefix_encoding = mb_detect_encoding($prefix, mb_detect_order(), true);
|
||||
$substchar = mb_substitute_character();
|
||||
mb_substitute_character(0x005F);
|
||||
$prefix = mb_convert_encoding($prefix, "ISO-8859-1", $prefix_encoding);
|
||||
mb_substitute_character($substchar);
|
||||
$prefix = preg_replace("[\W]", "_", $prefix);
|
||||
$prefix = preg_replace("/[^-_\w]+/", "", $prefix);
|
||||
|
||||
$localFile = $prefix . "_" . $remoteHash;
|
||||
$localFilePath = $this->getOptions()->getFontDir() . "/" . $localFile;
|
||||
|
||||
if (isset($entry[$styleString]) && $localFilePath == $entry[$styleString]) {
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
$entry[$styleString] = $localFile;
|
||||
|
||||
// Download the remote file
|
||||
[$protocol] = Helpers::explode_url($remoteFile);
|
||||
$allowed_protocols = $this->options->getAllowedProtocols();
|
||||
if (!array_key_exists($protocol, $allowed_protocols)) {
|
||||
Helpers::record_warnings(E_USER_WARNING, "Permission denied on $remoteFile. The communication protocol is not supported.", __FILE__, __LINE__);
|
||||
return false;
|
||||
}
|
||||
|
||||
foreach ($allowed_protocols[$protocol]["rules"] as $rule) {
|
||||
[$result, $message] = $rule($remoteFile);
|
||||
if ($result !== true) {
|
||||
Helpers::record_warnings(E_USER_WARNING, "Error loading $remoteFile: $message", __FILE__, __LINE__);
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
list($remoteFileContent, $http_response_header) = @Helpers::getFileContent($remoteFile, $context);
|
||||
if ($remoteFileContent === null) {
|
||||
return false;
|
||||
}
|
||||
|
||||
$localTempFile = @tempnam($this->options->get("tempDir"), "dompdf-font-");
|
||||
file_put_contents($localTempFile, $remoteFileContent);
|
||||
|
||||
$font = Font::load($localTempFile);
|
||||
|
||||
if (!$font) {
|
||||
unlink($localTempFile);
|
||||
return false;
|
||||
}
|
||||
|
||||
$font->parse();
|
||||
$font->saveAdobeFontMetrics("$localFilePath.ufm");
|
||||
$font->close();
|
||||
|
||||
unlink($localTempFile);
|
||||
|
||||
if ( !file_exists("$localFilePath.ufm") ) {
|
||||
return false;
|
||||
}
|
||||
|
||||
$fontExtension = ".ttf";
|
||||
switch ($font->getFontType()) {
|
||||
case "TrueType":
|
||||
default:
|
||||
$fontExtension = ".ttf";
|
||||
break;
|
||||
}
|
||||
|
||||
// Save the changes
|
||||
file_put_contents($localFilePath.$fontExtension, $remoteFileContent);
|
||||
|
||||
if ( !file_exists($localFilePath.$fontExtension) ) {
|
||||
unlink("$localFilePath.ufm");
|
||||
return false;
|
||||
}
|
||||
|
||||
$this->setFontFamily($fontname, $entry);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param $text
|
||||
* @param $font
|
||||
* @param $size
|
||||
* @param float $word_spacing
|
||||
* @param float $char_spacing
|
||||
* @return float
|
||||
* @deprecated
|
||||
*/
|
||||
public function get_text_width($text, $font, $size, $word_spacing = 0.0, $char_spacing = 0.0)
|
||||
{
|
||||
//return self::$_pdf->get_text_width($text, $font, $size, $word_spacing, $char_spacing);
|
||||
return $this->getTextWidth($text, $font, $size, $word_spacing, $char_spacing);
|
||||
}
|
||||
|
||||
/**
|
||||
* Calculates text size, in points
|
||||
*
|
||||
* @param string $text The text to be sized
|
||||
* @param string $font The font file to use
|
||||
* @param float $size The font size, in points
|
||||
* @param float $wordSpacing Word spacing, if any
|
||||
* @param float $charSpacing Char spacing, if any
|
||||
*
|
||||
* @return float
|
||||
*/
|
||||
public function getTextWidth(string $text, $font, float $size, float $wordSpacing = 0.0, float $charSpacing = 0.0): float
|
||||
{
|
||||
// @todo Make sure this cache is efficient before enabling it
|
||||
static $cache = [];
|
||||
|
||||
if ($text === "") {
|
||||
return 0;
|
||||
}
|
||||
|
||||
// Don't cache long strings
|
||||
$useCache = !isset($text[50]); // Faster than strlen
|
||||
|
||||
// Text-size calculations depend on the canvas used. Make sure to not
|
||||
// return wrong values when switching canvas backends
|
||||
$canvasClass = get_class($this->canvas);
|
||||
$key = "$canvasClass/$font/$size/$wordSpacing/$charSpacing";
|
||||
|
||||
if ($useCache && isset($cache[$key][$text])) {
|
||||
return $cache[$key][$text];
|
||||
}
|
||||
|
||||
$width = $this->canvas->get_text_width($text, $font, $size, $wordSpacing, $charSpacing);
|
||||
|
||||
if ($useCache) {
|
||||
$cache[$key][$text] = $width;
|
||||
}
|
||||
|
||||
return $width;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param $font
|
||||
* @param $size
|
||||
* @return float
|
||||
* @deprecated
|
||||
*/
|
||||
public function get_font_height($font, $size)
|
||||
{
|
||||
return $this->getFontHeight($font, $size);
|
||||
}
|
||||
|
||||
/**
|
||||
* Calculates font height, in points
|
||||
*
|
||||
* @param string $font The font file to use
|
||||
* @param float $size The font size, in points
|
||||
*
|
||||
* @return float
|
||||
*/
|
||||
public function getFontHeight($font, float $size): float
|
||||
{
|
||||
return $this->canvas->get_font_height($font, $size);
|
||||
}
|
||||
|
||||
/**
|
||||
* Calculates font baseline, in points
|
||||
*
|
||||
* @param string $font The font file to use
|
||||
* @param float $size The font size, in points
|
||||
*
|
||||
* @return float
|
||||
*/
|
||||
public function getFontBaseline($font, float $size): float
|
||||
{
|
||||
return $this->canvas->get_font_baseline($font, $size);
|
||||
}
|
||||
|
||||
/**
|
||||
* @param $family_raw
|
||||
* @param string $subtype_raw
|
||||
* @return string
|
||||
* @deprecated
|
||||
*/
|
||||
public function get_font($family_raw, $subtype_raw = "normal")
|
||||
{
|
||||
return $this->getFont($family_raw, $subtype_raw);
|
||||
}
|
||||
|
||||
/**
|
||||
* Resolves a font family & subtype into an actual font file
|
||||
* Subtype can be one of 'normal', 'bold', 'italic' or 'bold_italic'. If
|
||||
* the particular font family has no suitable font file, the default font
|
||||
* ({@link Options::defaultFont}) is used. The font file returned
|
||||
* is the absolute pathname to the font file on the system.
|
||||
*
|
||||
* @param string|null $familyRaw
|
||||
* @param string $subtypeRaw
|
||||
*
|
||||
* @return string|null
|
||||
*/
|
||||
public function getFont($familyRaw, $subtypeRaw = "normal")
|
||||
{
|
||||
static $cache = [];
|
||||
|
||||
if (isset($cache[$familyRaw][$subtypeRaw])) {
|
||||
return $cache[$familyRaw][$subtypeRaw];
|
||||
}
|
||||
|
||||
/* Allow calling for various fonts in search path. Therefore not immediately
|
||||
* return replacement on non match.
|
||||
* Only when called with NULL try replacement.
|
||||
* When this is also missing there is really trouble.
|
||||
* If only the subtype fails, nevertheless return failure.
|
||||
* Only on checking the fallback font, check various subtypes on same font.
|
||||
*/
|
||||
|
||||
$subtype = strtolower($subtypeRaw);
|
||||
|
||||
$families = $this->getFontFamilies();
|
||||
if ($familyRaw) {
|
||||
$family = str_replace(["'", '"'], "", strtolower($familyRaw));
|
||||
|
||||
if (isset($families[$family][$subtype])) {
|
||||
return $cache[$familyRaw][$subtypeRaw] = $families[$family][$subtype];
|
||||
}
|
||||
|
||||
return null;
|
||||
}
|
||||
|
||||
$fallback_families = [strtolower($this->options->getDefaultFont()), "serif"];
|
||||
foreach ($fallback_families as $family) {
|
||||
if (isset($families[$family][$subtype])) {
|
||||
return $cache[$familyRaw][$subtypeRaw] = $families[$family][$subtype];
|
||||
}
|
||||
|
||||
if (!isset($families[$family])) {
|
||||
continue;
|
||||
}
|
||||
|
||||
$family = $families[$family];
|
||||
|
||||
foreach ($family as $sub => $font) {
|
||||
if (strpos($subtype, $sub) !== false) {
|
||||
return $cache[$familyRaw][$subtypeRaw] = $font;
|
||||
}
|
||||
}
|
||||
|
||||
if ($subtype !== "normal") {
|
||||
foreach ($family as $sub => $font) {
|
||||
if ($sub !== "normal") {
|
||||
return $cache[$familyRaw][$subtypeRaw] = $font;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
$subtype = "normal";
|
||||
|
||||
if (isset($family[$subtype])) {
|
||||
return $cache[$familyRaw][$subtypeRaw] = $family[$subtype];
|
||||
}
|
||||
}
|
||||
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param $family
|
||||
* @return null|string
|
||||
* @deprecated
|
||||
*/
|
||||
public function get_family($family)
|
||||
{
|
||||
return $this->getFamily($family);
|
||||
}
|
||||
|
||||
/**
|
||||
* @param string $family
|
||||
* @return null|string
|
||||
*/
|
||||
public function getFamily($family)
|
||||
{
|
||||
$family = str_replace(["'", '"'], "", mb_strtolower($family));
|
||||
$families = $this->getFontFamilies();
|
||||
|
||||
if (isset($families[$family])) {
|
||||
return $families[$family];
|
||||
}
|
||||
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param $type
|
||||
* @return string
|
||||
* @deprecated
|
||||
*/
|
||||
public function get_type($type)
|
||||
{
|
||||
return $this->getType($type);
|
||||
}
|
||||
|
||||
/**
|
||||
* @param string $type
|
||||
* @return string
|
||||
*/
|
||||
public function getType($type)
|
||||
{
|
||||
if (preg_match('/bold/i', $type)) {
|
||||
$weight = 700;
|
||||
} elseif (preg_match('/([1-9]00)/', $type, $match)) {
|
||||
$weight = (int)$match[0];
|
||||
} else {
|
||||
$weight = 400;
|
||||
}
|
||||
$weight = $weight === 400 ? 'normal' : $weight;
|
||||
$weight = $weight === 700 ? 'bold' : $weight;
|
||||
|
||||
$style = preg_match('/italic|oblique/i', $type) ? 'italic' : null;
|
||||
|
||||
if ($weight === 'normal' && $style !== null) {
|
||||
return $style;
|
||||
}
|
||||
|
||||
return $style === null
|
||||
? $weight
|
||||
: $weight.'_'.$style;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return array
|
||||
* @deprecated
|
||||
*/
|
||||
public function get_font_families()
|
||||
{
|
||||
return $this->getFontFamilies();
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the current font lookup table
|
||||
*
|
||||
* @return array
|
||||
*/
|
||||
public function getFontFamilies()
|
||||
{
|
||||
if (!isset($this->fontFamilies)) {
|
||||
$this->setFontFamilies();
|
||||
}
|
||||
return $this->fontFamilies;
|
||||
}
|
||||
|
||||
/**
|
||||
* Convert loaded fonts to font lookup table
|
||||
*
|
||||
* @return array
|
||||
*/
|
||||
public function setFontFamilies()
|
||||
{
|
||||
$fontFamilies = [];
|
||||
if (isset($this->bundledFonts) && is_array($this->bundledFonts)) {
|
||||
foreach ($this->bundledFonts as $family => $variants) {
|
||||
if (!isset($fontFamilies[$family])) {
|
||||
$fontFamilies[$family] = array_map(function ($variant) {
|
||||
return $this->getOptions()->getRootDir() . '/lib/fonts/' . $variant;
|
||||
}, $variants);
|
||||
}
|
||||
}
|
||||
}
|
||||
if (isset($this->userFonts) && is_array($this->userFonts)) {
|
||||
foreach ($this->userFonts as $family => $variants) {
|
||||
$fontFamilies[$family] = array_map(function ($variant) {
|
||||
$variantName = basename($variant);
|
||||
if ($variantName === $variant) {
|
||||
return $this->getOptions()->getFontDir() . '/' . $variant;
|
||||
}
|
||||
return $variant;
|
||||
}, $variants);
|
||||
}
|
||||
}
|
||||
$this->fontFamilies = $fontFamilies;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param string $fontname
|
||||
* @param mixed $entry
|
||||
* @deprecated
|
||||
*/
|
||||
public function set_font_family($fontname, $entry)
|
||||
{
|
||||
$this->setFontFamily($fontname, $entry);
|
||||
}
|
||||
|
||||
/**
|
||||
* @param string $fontname
|
||||
* @param mixed $entry
|
||||
*/
|
||||
public function setFontFamily($fontname, $entry)
|
||||
{
|
||||
$this->userFonts[mb_strtolower($fontname)] = $entry;
|
||||
$this->saveFontFamilies();
|
||||
unset($this->fontFamilies);
|
||||
}
|
||||
|
||||
/**
|
||||
* @return string
|
||||
*/
|
||||
public function getUserFontsFilePath()
|
||||
{
|
||||
return $this->options->getFontDir() . '/' . self::USER_FONTS_FILE;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param Options $options
|
||||
* @return $this
|
||||
*/
|
||||
public function setOptions(Options $options)
|
||||
{
|
||||
$this->options = $options;
|
||||
unset($this->fontFamilies);
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return Options
|
||||
*/
|
||||
public function getOptions()
|
||||
{
|
||||
return $this->options;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param Canvas $canvas
|
||||
* @return $this
|
||||
*/
|
||||
public function setCanvas(Canvas $canvas)
|
||||
{
|
||||
$this->canvas = $canvas;
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return Canvas
|
||||
*/
|
||||
public function getCanvas()
|
||||
{
|
||||
return $this->canvas;
|
||||
}
|
||||
}
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue