Ivan Tcholakov be0cdc8624 Feature #347 - A bug in mPDF library has been fixed, an eregi_replace() function call was missed to be replaced with preg_replace(). 15 lat temu
..
classes 40cb9dc3fa prevent the listing of several directories 15 lat temu
font 40cb9dc3fa prevent the listing of several directories 15 lat temu
includes 40cb9dc3fa prevent the listing of several directories 15 lat temu
makefonts 40cb9dc3fa prevent the listing of several directories 15 lat temu
maps 40cb9dc3fa prevent the listing of several directories 15 lat temu
mpdfi 40cb9dc3fa prevent the listing of several directories 15 lat temu
patterns 40cb9dc3fa prevent the listing of several directories 15 lat temu
progress 40cb9dc3fa prevent the listing of several directories 15 lat temu
unifont 40cb9dc3fa prevent the listing of several directories 15 lat temu
CHANGELOG.txt dd09533c59 The library mPDF v.4.2 (http://mpdf.bpm1.com/) has been imported, "as-is", the core files only, no additional fonts. 15 lat temu
CREDITS.txt dd09533c59 The library mPDF v.4.2 (http://mpdf.bpm1.com/) has been imported, "as-is", the core files only, no additional fonts. 15 lat temu
LICENSE.txt dd09533c59 The library mPDF v.4.2 (http://mpdf.bpm1.com/) has been imported, "as-is", the core files only, no additional fonts. 15 lat temu
README_4_2.txt dd09533c59 The library mPDF v.4.2 (http://mpdf.bpm1.com/) has been imported, "as-is", the core files only, no additional fonts. 15 lat temu
compress.php dd09533c59 The library mPDF v.4.2 (http://mpdf.bpm1.com/) has been imported, "as-is", the core files only, no additional fonts. 15 lat temu
config.php dd09533c59 The library mPDF v.4.2 (http://mpdf.bpm1.com/) has been imported, "as-is", the core files only, no additional fonts. 15 lat temu
config_cp.php dd09533c59 The library mPDF v.4.2 (http://mpdf.bpm1.com/) has been imported, "as-is", the core files only, no additional fonts. 15 lat temu
config_fonts.php dd09533c59 The library mPDF v.4.2 (http://mpdf.bpm1.com/) has been imported, "as-is", the core files only, no additional fonts. 15 lat temu
graph.php 3380cb994f Feature #272 - Adapting the library mPDF 4.2 to the system: Moving some directories for temporary files in the directory ".../chamilo/arcive/" where access for writting is guaranteed. 15 lat temu
index.html 40cb9dc3fa prevent the listing of several directories 15 lat temu
mpdf.css dd09533c59 The library mPDF v.4.2 (http://mpdf.bpm1.com/) has been imported, "as-is", the core files only, no additional fonts. 15 lat temu
mpdf.php be0cdc8624 Feature #347 - A bug in mPDF library has been fixed, an eregi_replace() function call was missed to be replaced with preg_replace(). 15 lat temu

README_4_2.txt

===========================
mPDF v4.2 (27/01/2010)
===========================

Bug fixes
---------
- empty variable (undefined var, false, null, array() etc.) sent to WriteHTML produced error message "Invalid UTF-8"
- CJK in tables when not using CJK (utf-8-s) autosized very small as characters did not word-wrap
- parsing stylesheets: background image not recognised if containbed uppercase characters in file name
- "double" border on table used white between the lines instead of current background colour
- mPDFI: template documents overwriting HTML headers
- $this->shrink_tables_to_fit = 0 or false caused fatal errors
- background color or images not printing correctly when breaking across pages
- background not printed for List inside a block element
- columns starting near end of page with no room for a line triggering column change (resulting in text misplaced) not page break
- table cell not calculating cell height correctly when "orphan" characters (;:,.?! etc.) at end of line
- table breaking page in column 2 when col 1 is rowspan'ned
- margin-collapse at top of page not working if bookmark/annotation/indexentry/toc
- column break triggered by HR triggering a second column break
- an empty 'position:fixed' element with no/auto width or height caused fatal error
- mPDFI: function Overwrite (to change text in existing PDF) - fatal error if using with encrypted file

Bug - not fixed - see below
- WriteHTML('',2) with '2' parameter not recognising 'margin-collapse:collapse' for DIVs or 'line-height' set in default CSS 'BODY'




New or Updated Files
--------------------
mpdf.php
classes/gif.php
classes/indic.php
compress.php
config.php
config_cp.php
config_fonts.php
mpdf.css
includes/sub_core.php
mpdfi/mpdfi.php
unifont/ar_k_001.uni2gn.php
All files in new folder: /progress/*.*

NEW FOLDER /tmp/ required with read/write permissions - used for temporary image files or progress bars

New fonts: zn_hannom_a and unBatang_0613 available as CJK font pack
zn_hannom_a - contains all characters in SJIS, BIG-5, GBK, and HKCSS codepages (Japanes & Chinese)
(except greek and cyrillic characters, and HKCS > U+x20000;)
unbatang_0613 - all characters in UHC codepage (Korean)



Changes to configuration files
==============================
config_cp.php
-------------
Mainly just tidied up, and:
default: $cp = "UTF-8"; $spacing = ""; break; // Don't need to set unifonts - will make all available if omitted/left blank
Default spacing set to '' (i.e. mixed character/word)
spacing=C removed for Vietnamese (?why there) to allow spacing as for any european text
spacing=C added to Thai (should have been there all along)

config.php
----------
$defaultCSS changed to make appearance closer to that of browsers:
img { margin: 0; vertical-align: baseline; }
table { margin: 0; }
textarea { vertical-align: text-bottom; }

(See also notes on line-height)

New Configuration variables in 4.2:
$this->useSubstitutionsMB = false; // Substitute missing characters in UTF-8(multibyte) documents - from core fonts
$this->falseBoldWeight = 5; // Weight for bold text when using an artificial (outline) bold; value 0 (off) - 10 (rec. max)
$this->collapseBlockMargins = true; // Allows top and bottom margins to collapse between block elements
$this->progressBar = false; // Shows progress-bars whilst generating file
$this->normalLineheight = 1.33; // Value used for line-height when CSS specified as 'normal' (default)
// When writing a block element with position:fixed and overflow:auto, mPDF scales it down to fit in the space
// by repeatedly rewriting it and making adjustments. These values give the adjustments used, depending how far out
// the previous guess was. The higher the number, the quicker it will finish, but the less accurate the fit may be.
// FPR1 is for coarse adjustments, and FPR4 for fine adjustments when it is getting closer.
$this->incrementFPR1 = 10;
$this->incrementFPR2 = 20;
$this->incrementFPR3 = 30;
$this->incrementFPR4 = 50;


mpdf.css
--------
Now contains (commented out) lines to return behaviour to pre-4.2 behaviour:
img { margin: 0.83em 0; vertical-align: bottom; }
table { margin: 0.5em; }
textarea { vertical-align: top; }


Font updates:
=============
Indic Tamil numeral for Zero missing - converted to standard zero 0 (in classes/indic.php)
ar_k_001.uni2gn.php - reference to small 'z' missing - now added (works with subsets but not with full font)



WriteHTML($html,2)
==================
WriteHTML($html,2) i.e. with the ,2 did not set BODY CSS - this was unintentional, and has been changed in 4.2
Line-height and margin-collapse were therefore not cascaded through the document; the line-height defaulted to 1.2,
and margin-collapse (which collapses top and bottom margins at the top of pages) was not enabled.

If you used ",2" and want to keep layout:
- Change $this->normalLineheight = 1.2; in config.php
- Change defaultCSS: 'MARGIN-COLLAPSE' => 'none', in config.php

NB also $this->collapseBlockMargins = false; NB This does between block elements

NB You cannot now reset default font during document by redefining vars e.g. $mpdf->default_font = 'xxx'

Now WriteHTML(,2) - does NOT read metatags,