start copy from cimac web
This commit is contained in:
@@ -0,0 +1,67 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
|
||||
<html>
|
||||
|
||||
<head>
|
||||
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
|
||||
|
||||
<title>__construct</title>
|
||||
|
||||
<link type="text/css" rel="stylesheet" href="../fpdf.css">
|
||||
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<h1>__construct</h1>
|
||||
|
||||
<code>__construct([<b>string</b> orientation [, <b>string</b> unit [, <b>mixed</b> size]]])</code>
|
||||
|
||||
<h2>Descrizione</h2>
|
||||
|
||||
Si tratta del costruttore della classe. Permette di impostare il formato pagina,
|
||||
|
||||
l'orientamento e l'unità di misura utilizzata in tutti i metodi (eccetto per la
|
||||
|
||||
dimensione dei font).
|
||||
|
||||
<h2>Parametri</h2>
|
||||
|
||||
<dl class="param">
|
||||
|
||||
<dt><code>orientation</code></dt>
|
||||
|
||||
<dd>
|
||||
|
||||
Orientamento pagina di default. Possibili valori sono (case insensitive):
|
||||
|
||||
<ul>
|
||||
|
||||
<li><code>P</code> o <code>Portrait</code></li>
|
||||
|
||||
<li><code>L</code> o <code>Landscape</code></li>
|
||||
|
||||
</ul>
|
||||
|
||||
Il valore di default è <code>P</code>.
|
||||
|
||||
</dd>
|
||||
|
||||
<dt><code>unit</code></dt>
|
||||
|
||||
<dd>
|
||||
|
||||
Unità di misura. Possibili valori sono:
|
||||
|
||||
<ul>
|
||||
|
||||
<li><code>pt</code>: punti</li>
|
||||
|
||||
<li><code>mm</code>: millimetri</li>
|
||||
|
||||
<li><code>cm</code>: centimetri</li>
|
||||
|
||||
<li><code>in</code>: pollici</li>
|
||||
|
||||
</ul>
|
||||
@@ -0,0 +1,64 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
|
||||
<html>
|
||||
|
||||
<head>
|
||||
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
|
||||
|
||||
<title>AcceptPageBreak</title>
|
||||
|
||||
<link type="text/css" rel="stylesheet" href="../fpdf.css">
|
||||
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<h1>AcceptPageBreak</h1>
|
||||
|
||||
<code><b>boolean</b> AcceptPageBreak()</code>
|
||||
|
||||
<h2>Descrizione</h2>
|
||||
|
||||
Quando viene raggiunta la condizione per un'interruzione di pagina, viene chiamato il metodo e,
|
||||
|
||||
a seconda del valore restituito, l'interruzione viene eseguita o meno. L'implementazione di
|
||||
|
||||
default restituisce un valore secondo la modalità selezionata in SetAutoPageBreak().
|
||||
|
||||
<br>
|
||||
|
||||
Questo metodo viene chiamato automaticamente e non dovrebbe venire chiamato direttamente
|
||||
|
||||
dall'applicazione.
|
||||
|
||||
<h2>Esempio</h2>
|
||||
|
||||
Il metodo viene sovrascritto in una classe ereditata allo scopo di ottenere un layout su 3 colonne:
|
||||
|
||||
<div class="doc-source">
|
||||
|
||||
<pre><code>class PDF extends FPDF
|
||||
|
||||
{
|
||||
|
||||
var $col = 0;
|
||||
|
||||
|
||||
|
||||
function SetCol($col)
|
||||
|
||||
{
|
||||
|
||||
// Muove la posizione ad una colonna
|
||||
|
||||
$this->col = $col;
|
||||
|
||||
$x = 10+$col*65;
|
||||
|
||||
$this->SetLeftMargin($x);
|
||||
|
||||
$this->SetX($x);
|
||||
|
||||
}
|
||||
|
||||
@@ -0,0 +1,56 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
|
||||
<html>
|
||||
|
||||
<head>
|
||||
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
|
||||
|
||||
<title>AddFont</title>
|
||||
|
||||
<link type="text/css" rel="stylesheet" href="../fpdf.css">
|
||||
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<h1>AddFont</h1>
|
||||
|
||||
<code>AddFont(<b>string</b> family [, <b>string</b> style [, <b>string</b> file]])</code>
|
||||
|
||||
<h2>Descrizione</h2>
|
||||
|
||||
Importa un font TrueType, OpenType o Type1 e lo rende disponibile. E' necessario generare prima un
|
||||
|
||||
file di definizione di font con la utility MakeFont.
|
||||
|
||||
<br>
|
||||
|
||||
Il file di definizione (e lo stesso file del font quando compreso) deve essere presente nella
|
||||
|
||||
directory delle fonts. Se non può essere trovato, viene generato l'errore "Could not include
|
||||
|
||||
font definition file".
|
||||
|
||||
<h2>Parametri</h2>
|
||||
|
||||
<dl class="param">
|
||||
|
||||
<dt><code>family</code></dt>
|
||||
|
||||
<dd>
|
||||
|
||||
Famiglia del font. Il nome può essere scelto arbitrariamente. Se viene indicato un nome di una famiglia
|
||||
|
||||
standard, verrà sovrascritto il font corrispondente.
|
||||
|
||||
</dd>
|
||||
|
||||
<dt><code>style</code></dt>
|
||||
|
||||
<dd>
|
||||
|
||||
Stile del font. Possibili valori sono (case insensitive):
|
||||
|
||||
<ul>
|
||||
|
||||
@@ -0,0 +1,26 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
|
||||
<html>
|
||||
|
||||
<head>
|
||||
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
|
||||
|
||||
<title>AddLink</title>
|
||||
|
||||
<link type="text/css" rel="stylesheet" href="../fpdf.css">
|
||||
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<h1>AddLink</h1>
|
||||
|
||||
<code><b>int</b> AddLink()</code>
|
||||
|
||||
<h2>Descrizione</h2>
|
||||
|
||||
Crea un nuovo link interno e restituisce il suo identificatore. Un link interno è un'area
|
||||
|
||||
cliccabile che reindirizza verso un'altra posizione all'interno del documento.
|
||||
|
||||
@@ -0,0 +1,64 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
|
||||
<html>
|
||||
|
||||
<head>
|
||||
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
|
||||
|
||||
<title>AddPage</title>
|
||||
|
||||
<link type="text/css" rel="stylesheet" href="../fpdf.css">
|
||||
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<h1>AddPage</h1>
|
||||
|
||||
<code>AddPage([<b>string</b> orientation [, <b>mixed</b> size [, <b>int</b> rotation]]])</code>
|
||||
|
||||
<h2>Descrizione</h2>
|
||||
|
||||
Aggiunge una nuova pagina al documento. Se è già presente una pagina viene chiamato prima il
|
||||
|
||||
metodo Footer() per inserire il piè d ipagina. Quindi viene aggiunta la pagina, la posizione
|
||||
|
||||
corrente viene impostata nell'angolo superiore sinistro, tenendo conto del margine superiore e
|
||||
|
||||
sinistro, quindi viene chiamato Header() per visualizzare l'intestazione.
|
||||
|
||||
<br>
|
||||
|
||||
Il font impostato prima della chiamata viene ripristinato automaticamente. Non c'è bisogno di
|
||||
|
||||
chiamare di nuovo SetFont() se si vuole continuare con lo stesso font. Lo stesso dicasi per
|
||||
|
||||
colori e larghezza di riga.
|
||||
|
||||
<br>
|
||||
|
||||
L'origine del sistema di coordinate è nell'angolo superiore sinistro e l'incremento delle
|
||||
|
||||
ordinate fa muovere verso il basso.
|
||||
|
||||
<h2>Parametri</h2>
|
||||
|
||||
<dl class="param">
|
||||
|
||||
<dt><code>orientation</code></dt>
|
||||
|
||||
<dd>
|
||||
|
||||
Orientamento della pagina. Possibili valori sono (case insensitive):
|
||||
|
||||
<ul>
|
||||
|
||||
<li><code>P</code> o <code>Portrait</code></li>
|
||||
|
||||
<li><code>L</code> o <code>Landscape</code></li>
|
||||
|
||||
</ul>
|
||||
|
||||
Il valore di default è quello passato dal costruttore.
|
||||
|
||||
@@ -0,0 +1,44 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
|
||||
<html>
|
||||
|
||||
<head>
|
||||
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
|
||||
|
||||
<title>AliasNbPages</title>
|
||||
|
||||
<link type="text/css" rel="stylesheet" href="../fpdf.css">
|
||||
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<h1>AliasNbPages</h1>
|
||||
|
||||
<code>AliasNbPages([<b>string</b> alias])</code>
|
||||
|
||||
<h2>Descrizione</h2>
|
||||
|
||||
Definisce un alias per il numero totale di pagine. Sarà sostituito alla chiusura del documento.
|
||||
|
||||
<h2>Parametri</h2>
|
||||
|
||||
<dl class="param">
|
||||
|
||||
<dt><code>alias</code></dt>
|
||||
|
||||
<dd>
|
||||
|
||||
L'alias. Valore di default: <code>{nb}</code>.
|
||||
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
|
||||
<h2>Esempio</h2>
|
||||
|
||||
<div class="doc-source">
|
||||
|
||||
<pre><code>class PDF extends FPDF
|
||||
|
||||
@@ -0,0 +1,105 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
|
||||
<html>
|
||||
|
||||
<head>
|
||||
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
|
||||
|
||||
<title>Cell</title>
|
||||
|
||||
<link type="text/css" rel="stylesheet" href="../fpdf.css">
|
||||
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<h1>Cell</h1>
|
||||
|
||||
<code>Cell(<b>float</b> w [, <b>float</b> h [, <b>string</b> txt [, <b>mixed</b> border [, <b>int</b> ln [, <b>string</b> align [, <b>boolean</b> fill [, <b>mixed</b> link]]]]]]])</code>
|
||||
|
||||
<h2>Descrizione</h2>
|
||||
|
||||
Stampa una cella (area rettangolare) con bordi, colore di sfondo e stringa di caratteri opzionali.
|
||||
|
||||
L'angolo superiore sinistro della cella corrisponde alla posizione corrente. Il testo può essere
|
||||
|
||||
allineato o centrato. Dopo la chiamata, la posizione corrente si sposta a destra o sulla linea
|
||||
|
||||
successiva. E' possibile inserire un link sul testo.
|
||||
|
||||
<br>
|
||||
|
||||
Se l'interruzione di pagina automatica è abilitata e la cella va oltre i limiti, viene inserita una
|
||||
|
||||
interruzione di pagina prima dell'output.
|
||||
|
||||
<h2>Parametri</h2>
|
||||
|
||||
<dl class="param">
|
||||
|
||||
<dt><code>w</code></dt>
|
||||
|
||||
<dd>
|
||||
|
||||
Larghezza della cella. Se <code>0</code>, la cella si estende dalla parte del margine destro.
|
||||
|
||||
</dd>
|
||||
|
||||
<dt><code>h</code></dt>
|
||||
|
||||
<dd>
|
||||
|
||||
Altezza della cella.
|
||||
|
||||
Valore di default: <code>0</code>.
|
||||
|
||||
</dd>
|
||||
|
||||
<dt><code>txt</code></dt>
|
||||
|
||||
<dd>
|
||||
|
||||
Stringa da stampare.
|
||||
|
||||
Valore di default: stringa vuota.
|
||||
|
||||
</dd>
|
||||
|
||||
<dt><code>border</code></dt>
|
||||
|
||||
<dd>
|
||||
|
||||
Indica se bisogna tracciare i bordi attorno alla cella. Il valore può essere sia un numero:
|
||||
|
||||
<ul>
|
||||
|
||||
<li><code>0</code>: nessun bordo</li>
|
||||
|
||||
<li><code>1</code>: cornice</li>
|
||||
|
||||
</ul>
|
||||
|
||||
o una stringa contenente alcuni o tutti i seguenti caratteri (in qualsiasi ordine):
|
||||
|
||||
<ul>
|
||||
|
||||
<li><code>L</code>: sinistro</li>
|
||||
|
||||
<li><code>T</code>: superiore</li>
|
||||
|
||||
<li><code>R</code>: destro</li>
|
||||
|
||||
<li><code>B</code>: inferiore</li>
|
||||
|
||||
</ul>
|
||||
|
||||
Valore di default: <code>0</code>.
|
||||
|
||||
</dd>
|
||||
|
||||
<dt><code>ln</code></dt>
|
||||
|
||||
<dd>
|
||||
|
||||
Indica la posizione corrente dopo la chiamata. Valori possibili sono:
|
||||
@@ -0,0 +1,22 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
|
||||
<html>
|
||||
|
||||
<head>
|
||||
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
|
||||
|
||||
<title>Close</title>
|
||||
|
||||
<link type="text/css" rel="stylesheet" href="../fpdf.css">
|
||||
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<h1>Close</h1>
|
||||
|
||||
<code>Close()</code>
|
||||
|
||||
<h2>Descrizione</h2>
|
||||
|
||||
@@ -0,0 +1,26 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
|
||||
<html>
|
||||
|
||||
<head>
|
||||
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
|
||||
|
||||
<title>Error</title>
|
||||
|
||||
<link type="text/css" rel="stylesheet" href="../fpdf.css">
|
||||
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<h1>Error</h1>
|
||||
|
||||
<code>Error(<b>string</b> msg)</code>
|
||||
|
||||
<h2>Descrizione</h2>
|
||||
|
||||
Questo metodo viene chiamato automaticamente in caso di errore fatale; assieme al messaggio fornito
|
||||
|
||||
viene semplicemente generata un'eccezione.<br>
|
||||
|
||||
@@ -0,0 +1,36 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
|
||||
<html>
|
||||
|
||||
<head>
|
||||
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
|
||||
|
||||
<title>Footer</title>
|
||||
|
||||
<link type="text/css" rel="stylesheet" href="../fpdf.css">
|
||||
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<h1>Footer</h1>
|
||||
|
||||
<code>Footer()</code>
|
||||
|
||||
<h2>Descrizione</h2>
|
||||
|
||||
Questo metodo viene utilizzato per disegnare il piè di pagina. Viene chiamato automaticamente
|
||||
|
||||
da AddPage() e Close() e non dovrebbe venire chiamato direttamente dall'applicazione.
|
||||
|
||||
L'implementazione in FPDF è lasciata vuota, quindi è possibile subclassarla e sovrascrivere
|
||||
|
||||
il metodo se si desidera un processo particolare.
|
||||
|
||||
<h2>Esempio</h2>
|
||||
|
||||
<div class="doc-source">
|
||||
|
||||
<pre><code>class PDF extends FPDF
|
||||
|
||||
@@ -0,0 +1,18 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
|
||||
<html>
|
||||
|
||||
<head>
|
||||
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
|
||||
|
||||
<title>GetPageHeight</title>
|
||||
|
||||
<link type="text/css" rel="stylesheet" href="../fpdf.css">
|
||||
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<h1>GetPageHeight</h1>
|
||||
|
||||
@@ -0,0 +1,18 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
|
||||
<html>
|
||||
|
||||
<head>
|
||||
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
|
||||
|
||||
<title>GetPageWidth</title>
|
||||
|
||||
<link type="text/css" rel="stylesheet" href="../fpdf.css">
|
||||
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<h1>GetPageWidth</h1>
|
||||
|
||||
@@ -0,0 +1,24 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
|
||||
<html>
|
||||
|
||||
<head>
|
||||
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
|
||||
|
||||
<title>GetStringWidth</title>
|
||||
|
||||
<link type="text/css" rel="stylesheet" href="../fpdf.css">
|
||||
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<h1>GetStringWidth</h1>
|
||||
|
||||
<code><b>float</b> GetStringWidth(<b>string</b> s)</code>
|
||||
|
||||
<h2>Descrizione</h2>
|
||||
|
||||
Restituisce la lunghezza di una stringa nell'unità di misura utilizzata. Deve essere
|
||||
|
||||
@@ -0,0 +1,20 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
|
||||
<html>
|
||||
|
||||
<head>
|
||||
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
|
||||
|
||||
<title>GetX</title>
|
||||
|
||||
<link type="text/css" rel="stylesheet" href="../fpdf.css">
|
||||
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<h1>GetX</h1>
|
||||
|
||||
<code><b>float</b> GetX()</code>
|
||||
|
||||
@@ -0,0 +1,20 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
|
||||
<html>
|
||||
|
||||
<head>
|
||||
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
|
||||
|
||||
<title>GetY</title>
|
||||
|
||||
<link type="text/css" rel="stylesheet" href="../fpdf.css">
|
||||
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<h1>GetY</h1>
|
||||
|
||||
<code><b>float</b> GetY()</code>
|
||||
|
||||
@@ -0,0 +1,37 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
|
||||
<html>
|
||||
|
||||
<head>
|
||||
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
|
||||
|
||||
<title>Header</title>
|
||||
|
||||
<link type="text/css" rel="stylesheet" href="../fpdf.css">
|
||||
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<h1>Header</h1>
|
||||
|
||||
<code>Header()</code>
|
||||
|
||||
<h2>Descrizione</h2>
|
||||
|
||||
Questo metodo viene utilizzato per disegnare l'intestazione della pagina. Viene chiamato automaticamente
|
||||
|
||||
da AddPage() e non dovrebbe venire chiamato direttamente dall'applicazione. L'implementazione in FPDF
|
||||
|
||||
è lasciata vuota, quindi bisogna subclassarla e sovrascriverne il metodo se si desidera un processo particolare.
|
||||
|
||||
<h2>Esempio</h2>
|
||||
|
||||
<div class="doc-source">
|
||||
|
||||
<pre><code>class PDF extends FPDF
|
||||
|
||||
{
|
||||
|
||||
function Header()
|
||||
@@ -0,0 +1,101 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
|
||||
<html>
|
||||
|
||||
<head>
|
||||
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
|
||||
|
||||
<title>Image</title>
|
||||
|
||||
<link type="text/css" rel="stylesheet" href="../fpdf.css">
|
||||
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<h1>Image</h1>
|
||||
|
||||
<code>Image(<b>string</b> file [, <b>float</b> x [, <b>float</b> y [, <b>float</b> w [, <b>float</b> h [, <b>string</b> type [, <b>mixed</b> link]]]]]])</code>
|
||||
|
||||
<h2>Descrizione</h2>
|
||||
|
||||
Permette di inserire un immagine nella pagina. Le dimensioni possono essere specificate nei seguenti modi:
|
||||
|
||||
<ul>
|
||||
|
||||
<li>specificando larghezza e altezza (espresse nell'unità di misura scelte o dpi)</li>
|
||||
|
||||
<li>specificando una sola dimensione, l'altra sarà calcolata automaticamente in maniera da mantenere le proporzioni originali</li>
|
||||
|
||||
<li>senza specificare le dimensioni, in questo caso l'immagine sarà inserita a 96 dpi</li>
|
||||
|
||||
</ul>
|
||||
|
||||
I formati inseribili sono JPEG, PNG e GIF. Per il supporto al formato GIF è richiesta l'estensione GD.
|
||||
|
||||
<br>
|
||||
|
||||
<br>
|
||||
|
||||
Per le JPEG, sono consentiti i seguenti colori:
|
||||
|
||||
<ul>
|
||||
|
||||
<li>scala di grigio</li>
|
||||
|
||||
<li>true colors (24 bits)</li>
|
||||
|
||||
<li>CMYK (32 bits)</li>
|
||||
|
||||
</ul>
|
||||
|
||||
Per le PNG, sono consentiti:
|
||||
|
||||
<ul>
|
||||
|
||||
<li>scala di grigio a 8 bits (256 livelli)</li>
|
||||
|
||||
<li>indexed colors</li>
|
||||
|
||||
<li>true colors (24 bits)</li>
|
||||
|
||||
</ul>
|
||||
|
||||
Nel caso di GIF animata, verrà utilizzato solo il primo frame.<br>
|
||||
|
||||
<br>
|
||||
|
||||
La trasparenza è supportata.<br>
|
||||
|
||||
<br>
|
||||
|
||||
Se il formato dell'immagine non viene specificato sarà preso dall'estensione del file.<br>
|
||||
|
||||
<br>
|
||||
|
||||
E' possibile inserire un link sull'immagine.<br>
|
||||
|
||||
<br>
|
||||
|
||||
Osservazione: se un immagine è usata più volte, solo una copia sarà inserita nel file.
|
||||
|
||||
<h2>Parametri</h2>
|
||||
|
||||
<dl class="param">
|
||||
|
||||
<dt><code>file</code></dt>
|
||||
|
||||
<dd>
|
||||
|
||||
Nome del file che contiene l'immagine.
|
||||
|
||||
</dd>
|
||||
|
||||
<dt><code>x</code></dt>
|
||||
|
||||
<dd>
|
||||
|
||||
Ascissa dell'angolo superiore-sinistro. Se non specificata o pari a <code>null</code>, viene utilizzata
|
||||
|
||||
l'ascissa corrente.
|
||||
@@ -0,0 +1,59 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
|
||||
<html>
|
||||
|
||||
<head>
|
||||
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
|
||||
|
||||
<title>Manuale di riferimento di FPDF 1.84</title>
|
||||
|
||||
<link type="text/css" rel="stylesheet" href="../fpdf.css">
|
||||
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<h1>Manuale di riferimento di FPDF 1.84</h1>
|
||||
|
||||
<a href="__construct.htm">__construct</a> - costruttore<br>
|
||||
|
||||
<a href="acceptpagebreak.htm">AcceptPageBreak</a> - ammette o meno l'interruzione di pagina automatico<br>
|
||||
|
||||
<a href="addfont.htm">AddFont</a> - aggiunge un nuovo font<br>
|
||||
|
||||
<a href="addlink.htm">AddLink</a> - crea un link interno<br>
|
||||
|
||||
<a href="addpage.htm">AddPage</a> - aggiunge una nuova pagina<br>
|
||||
|
||||
<a href="aliasnbpages.htm">AliasNbPages</a> - definisce un alias per il numero di pagine<br>
|
||||
|
||||
<a href="cell.htm">Cell</a> - stampa una cella<br>
|
||||
|
||||
<a href="close.htm">Close</a> - chiude il documento<br>
|
||||
|
||||
<a href="error.htm">Error</a> - errore fatale<br>
|
||||
|
||||
<a href="footer.htm">Footer</a> - piè di pagina<br>
|
||||
|
||||
<a href="getpageheight.htm">GetPageHeight</a> - restituisce l'altezza della pagina corrente<br>
|
||||
|
||||
<a href="getpagewidth.htm">GetPageWidth</a> - restituisce la larghezza della pagina corrente<br>
|
||||
|
||||
<a href="getstringwidth.htm">GetStringWidth</a> - calcola la lungheza di una stringa<br>
|
||||
|
||||
<a href="getx.htm">GetX</a> - calcola la posizione corrente di x<br>
|
||||
|
||||
<a href="gety.htm">GetY</a> - calcola la posizione corrente di y<br>
|
||||
|
||||
<a href="header.htm">Header</a> - intestazione della pagina<br>
|
||||
|
||||
<a href="image.htm">Image</a> - disegna un'immagine<br>
|
||||
|
||||
<a href="line.htm">Line</a> - traccia una linea<br>
|
||||
|
||||
<a href="link.htm">Link</a> - inserisce un link<br>
|
||||
|
||||
<a href="ln.htm">Ln</a> - interruzione di linea<br>
|
||||
|
||||
<a href="multicell.htm">MultiCell</a> - stampa del testo con interruzioni di linea<br>
|
||||
@@ -0,0 +1,38 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
|
||||
<html>
|
||||
|
||||
<head>
|
||||
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
|
||||
|
||||
<title>Line</title>
|
||||
|
||||
<link type="text/css" rel="stylesheet" href="../fpdf.css">
|
||||
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<h1>Line</h1>
|
||||
|
||||
<code>Line(<b>float</b> x1, <b>float</b> y1, <b>float</b> x2, <b>float</b> y2)</code>
|
||||
|
||||
<h2>Descrizione</h2>
|
||||
|
||||
Traccia una linea tra due punti.
|
||||
|
||||
<h2>Parametri</h2>
|
||||
|
||||
<dl class="param">
|
||||
|
||||
<dt><code>x1</code></dt>
|
||||
|
||||
<dd>
|
||||
|
||||
Ascissa del primo punto.
|
||||
|
||||
</dd>
|
||||
|
||||
<dt><code>y1</code></dt>
|
||||
|
||||
@@ -0,0 +1,46 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
|
||||
<html>
|
||||
|
||||
<head>
|
||||
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
|
||||
|
||||
<title>Link</title>
|
||||
|
||||
<link type="text/css" rel="stylesheet" href="../fpdf.css">
|
||||
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<h1>Link</h1>
|
||||
|
||||
<code>Link(<b>float</b> x, <b>float</b> y, <b>float</b> w, <b>float</b> h, <b>mixed</b> link)</code>
|
||||
|
||||
<h2>Descrizione</h2>
|
||||
|
||||
Inserisce un link in un'area rettangolare della pagina. I links su immagini o testo generalmente
|
||||
|
||||
vengonogenerally inseriti tramite Cell(), Write() o Image(), ma questo metodo può risultare utile
|
||||
|
||||
nel caso si volesse definire un'area cliccabile all'interno di un'immagine.
|
||||
|
||||
<h2>Parametri</h2>
|
||||
|
||||
<dl class="param">
|
||||
|
||||
<dt><code>x</code></dt>
|
||||
|
||||
<dd>
|
||||
|
||||
Ascissa dell'angolo in alto a sinistra del rettangolo.
|
||||
|
||||
</dd>
|
||||
|
||||
<dt><code>y</code></dt>
|
||||
|
||||
<dd>
|
||||
|
||||
Ordinata dell'angolo in alto a sinistra del rettangolo.
|
||||
|
||||
@@ -0,0 +1,28 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
|
||||
<html>
|
||||
|
||||
<head>
|
||||
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
|
||||
|
||||
<title>Ln</title>
|
||||
|
||||
<link type="text/css" rel="stylesheet" href="../fpdf.css">
|
||||
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<h1>Ln</h1>
|
||||
|
||||
<code>Ln([<b>float</b> h])</code>
|
||||
|
||||
<h2>Descrizione</h2>
|
||||
|
||||
Effettua una interruzione di linea. L'ascissa corrente torna indietro al margine sinistro e l'ordinata
|
||||
|
||||
aumenta del valore passato come parametro.
|
||||
|
||||
<h2>Parametri</h2>
|
||||
|
||||
@@ -0,0 +1,77 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
|
||||
<html>
|
||||
|
||||
<head>
|
||||
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
|
||||
|
||||
<title>MultiCell</title>
|
||||
|
||||
<link type="text/css" rel="stylesheet" href="../fpdf.css">
|
||||
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<h1>MultiCell</h1>
|
||||
|
||||
<code>MultiCell(<b>float</b> w, <b>float</b> h, <b>string</b> txt [, <b>mixed</b> border [, <b>string</b> align [, <b>boolean</b> fill]]])</code>
|
||||
|
||||
<h2>Descrizione</h2>
|
||||
|
||||
Questo metodo permette di stampare del testo con interruzioni di linea. Possono essere automatiche
|
||||
|
||||
(non appena il testo raggiunge il margine destro della cella) o esplicite (tramite il carattere \n).
|
||||
|
||||
Vengono inserite tante celle quante necessarie, una sotto l'altra.
|
||||
|
||||
<br>
|
||||
|
||||
Il testo può essere allineato, centrato o giustificato. E' possibile inserire i bordi e lo sfondo al
|
||||
|
||||
blocco di celle.
|
||||
|
||||
<h2>Parametri</h2>
|
||||
|
||||
<dl class="param">
|
||||
|
||||
<dt><code>w</code></dt>
|
||||
|
||||
<dd>
|
||||
|
||||
Larghezza delle celle. Se <code>0</code>, si estendono dalla parte del margine destro della pagina.
|
||||
|
||||
</dd>
|
||||
|
||||
<dt><code>h</code></dt>
|
||||
|
||||
<dd>
|
||||
|
||||
Altezza delle celle.
|
||||
|
||||
</dd>
|
||||
|
||||
<dt><code>txt</code></dt>
|
||||
|
||||
<dd>
|
||||
|
||||
Stringa da stampare.
|
||||
|
||||
</dd>
|
||||
|
||||
<dt><code>border</code></dt>
|
||||
|
||||
<dd>
|
||||
|
||||
Indica se bisogna disegnare i bordi attorno al blocco di celle. Il valore può essere sia un numero:
|
||||
|
||||
<ul>
|
||||
|
||||
<li><code>0</code>: nessun bordo</li>
|
||||
|
||||
<li><code>1</code>: cornice</li>
|
||||
|
||||
</ul>
|
||||
|
||||
o una stringa contenente alcuni o tutti i seguenti caratteri (in qualsiasi ordine):
|
||||
@@ -0,0 +1,46 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
|
||||
<html>
|
||||
|
||||
<head>
|
||||
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
|
||||
|
||||
<title>Output</title>
|
||||
|
||||
<link type="text/css" rel="stylesheet" href="../fpdf.css">
|
||||
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<h1>Output</h1>
|
||||
|
||||
<code><b>string</b> Output([<b>string</b> dest [, <b>string</b> name [, <b>boolean</b> isUTF8]]])</code>
|
||||
|
||||
<h2>Descrizione</h2>
|
||||
|
||||
Passa il documento a una destinazione: stringa, file locale o browser. Nell'ultimo
|
||||
|
||||
caso, verrà usato il plug-in (se presente), oppure sarà forzata l'apertura di una
|
||||
|
||||
finestra di download ("Salva con nome").<br>
|
||||
|
||||
Se necessario, il metodo richiama prima Close() per chiudere il documento.
|
||||
|
||||
<h2>Parametri</h2>
|
||||
|
||||
<dl class="param">
|
||||
|
||||
<dt><code>dest</code></dt>
|
||||
|
||||
<dd>
|
||||
|
||||
Destinazione dove mandare il documento. Può essere specificato uno dei seguenti valori:
|
||||
|
||||
<ul>
|
||||
|
||||
<li><code>I</code>: manda il 'file inline' al browser. Il plug-in sarà utilizzato se presente.</li>
|
||||
|
||||
<li><code>D</code>: manda al browser e forza il download del file con il nome dato con <code>name</code>.</li>
|
||||
|
||||
@@ -0,0 +1,18 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
|
||||
<html>
|
||||
|
||||
<head>
|
||||
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
|
||||
|
||||
<title>PageNo</title>
|
||||
|
||||
<link type="text/css" rel="stylesheet" href="../fpdf.css">
|
||||
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<h1>PageNo</h1>
|
||||
|
||||
@@ -0,0 +1,48 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
|
||||
<html>
|
||||
|
||||
<head>
|
||||
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
|
||||
|
||||
<title>Rect</title>
|
||||
|
||||
<link type="text/css" rel="stylesheet" href="../fpdf.css">
|
||||
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<h1>Rect</h1>
|
||||
|
||||
<code>Rect(<b>float</b> x, <b>float</b> y, <b>float</b> w, <b>float</b> h [, <b>string</b> style])</code>
|
||||
|
||||
<h2>Descrizione</h2>
|
||||
|
||||
Traccia un rettangolo. Può essere disegnato (solo bordi), riempito (senza bordi) o entrambi.
|
||||
|
||||
<h2>Parametri</h2>
|
||||
|
||||
<dl class="param">
|
||||
|
||||
<dt><code>x</code></dt>
|
||||
|
||||
<dd>
|
||||
|
||||
Ascissa dell'angolo in alto a sinistra.
|
||||
|
||||
</dd>
|
||||
|
||||
<dt><code>y</code></dt>
|
||||
|
||||
<dd>
|
||||
|
||||
Ordinata dell'angolo in alto a sinistra.
|
||||
|
||||
</dd>
|
||||
|
||||
<dt><code>w</code></dt>
|
||||
|
||||
<dd>
|
||||
|
||||
@@ -0,0 +1,33 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
|
||||
<html>
|
||||
|
||||
<head>
|
||||
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
|
||||
|
||||
<title>SetAuthor</title>
|
||||
|
||||
<link type="text/css" rel="stylesheet" href="../fpdf.css">
|
||||
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<h1>SetAuthor</h1>
|
||||
|
||||
<code>SetAuthor(<b>string</b> author [, <b>boolean</b> isUTF8])</code>
|
||||
|
||||
<h2>Descrizione</h2>
|
||||
|
||||
Definisce l'autore del documento.
|
||||
|
||||
<h2>Parametri</h2>
|
||||
|
||||
<dl class="param">
|
||||
|
||||
<dt><code>author</code></dt>
|
||||
|
||||
<dd>
|
||||
|
||||
Il nome dell'autore.
|
||||
@@ -0,0 +1,33 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
|
||||
<html>
|
||||
|
||||
<head>
|
||||
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
|
||||
|
||||
<title>SetAutoPageBreak</title>
|
||||
|
||||
<link type="text/css" rel="stylesheet" href="../fpdf.css">
|
||||
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<h1>SetAutoPageBreak</h1>
|
||||
|
||||
<code>SetAutoPageBreak(<b>boolean</b> auto [, <b>float</b> margin])</code>
|
||||
|
||||
<h2>Descrizione</h2>
|
||||
|
||||
Abilita o disabilita la modalità di interruzione di pagina automatica. Se abilitata, il secondo
|
||||
|
||||
parametro rappresenta la distanza dal fondo della pagina, la quale definisce il limite di
|
||||
|
||||
attivazione. Per default, la modalità è on e il margine è 2 cm.
|
||||
|
||||
<h2>Parametri</h2>
|
||||
|
||||
<dl class="param">
|
||||
|
||||
<dt><code>auto</code></dt>
|
||||
@@ -0,0 +1,30 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
|
||||
<html>
|
||||
|
||||
<head>
|
||||
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
|
||||
|
||||
<title>SetCompression</title>
|
||||
|
||||
<link type="text/css" rel="stylesheet" href="../fpdf.css">
|
||||
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<h1>SetCompression</h1>
|
||||
|
||||
<code>SetCompression(<b>boolean</b> compress)</code>
|
||||
|
||||
<h2>Descrizione</h2>
|
||||
|
||||
Attiva o disattiva la compressione delle pagine. Se attiva, la rappresentazione interna di ogni
|
||||
|
||||
pagina viene compressa, che porta ad un valore di compressione di 2 per il documento risultante.
|
||||
|
||||
<br>
|
||||
|
||||
La compressione è attiva per default.
|
||||
|
||||
@@ -0,0 +1,33 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
|
||||
<html>
|
||||
|
||||
<head>
|
||||
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
|
||||
|
||||
<title>SetCreator</title>
|
||||
|
||||
<link type="text/css" rel="stylesheet" href="../fpdf.css">
|
||||
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<h1>SetCreator</h1>
|
||||
|
||||
<code>SetCreator(<b>string</b> creator [, <b>boolean</b> isUTF8])</code>
|
||||
|
||||
<h2>Descrizione</h2>
|
||||
|
||||
Definisce il creatore del documento. Tipicamente è il nome dell'applicazione che ha generato il PDF.
|
||||
|
||||
<h2>Parametri</h2>
|
||||
|
||||
<dl class="param">
|
||||
|
||||
<dt><code>creator</code></dt>
|
||||
|
||||
<dd>
|
||||
|
||||
Il nome del creatore.
|
||||
@@ -0,0 +1,46 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
|
||||
<html>
|
||||
|
||||
<head>
|
||||
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
|
||||
|
||||
<title>SetDisplayMode</title>
|
||||
|
||||
<link type="text/css" rel="stylesheet" href="../fpdf.css">
|
||||
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<h1>SetDisplayMode</h1>
|
||||
|
||||
<code>SetDisplayMode(<b>mixed</b> zoom [, <b>string</b> layout])</code>
|
||||
|
||||
<h2>Descrizione</h2>
|
||||
|
||||
Definisce la modalità in cui il documento verrà mostrato sul viewer. E' possibile impostare il
|
||||
|
||||
livello dello zoom: le pagine possono essere mostrate interamente sullo schermo, a tutta pagina,
|
||||
|
||||
utilizzare le dimensioni reali, rappresentate in scala con un fattore dello zoom specifico oppure
|
||||
|
||||
utilizzare i valori di default del viewer (come configurato nel menu Preferences di Adobe Reader).
|
||||
|
||||
E' possibile specificare anche il layout di pagina: una per volta, visualizzazione continua, due
|
||||
|
||||
colonne o default del viewer.
|
||||
|
||||
<h2>Parametri</h2>
|
||||
|
||||
<dl class="param">
|
||||
|
||||
<dt><code>zoom</code></dt>
|
||||
|
||||
<dd>
|
||||
|
||||
Lo zoom da usare. Può essere uno dei seguenti valori di stringa:
|
||||
|
||||
<ul>
|
||||
|
||||
@@ -0,0 +1,41 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
|
||||
<html>
|
||||
|
||||
<head>
|
||||
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
|
||||
|
||||
<title>SetDrawColor</title>
|
||||
|
||||
<link type="text/css" rel="stylesheet" href="../fpdf.css">
|
||||
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<h1>SetDrawColor</h1>
|
||||
|
||||
<code>SetDrawColor(<b>int</b> r [, <b>int</b> g, <b>int</b> b])</code>
|
||||
|
||||
<h2>Descrizione</h2>
|
||||
|
||||
Definisce il colore usato per tutte le operazioni di disegno (linee, rettangoli e bordi delle celle).
|
||||
|
||||
Può essere espresso in componenti RGB o scala di grigi. Il metodo può essere chiamato prima che la
|
||||
|
||||
prima pagina sia creata per mantenere il valore di pagina in pagina.
|
||||
|
||||
<h2>Parametri</h2>
|
||||
|
||||
<dl class="param">
|
||||
|
||||
<dt><code>r</code></dt>
|
||||
|
||||
<dd>
|
||||
|
||||
Se <code>g</code> e <code>b</code> sono dati, indica il componente rosso; altrimenti indica il livello di grigio.
|
||||
|
||||
Valori tra 0 e 255.
|
||||
|
||||
</dd>
|
||||
@@ -0,0 +1,40 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
|
||||
<html>
|
||||
|
||||
<head>
|
||||
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
|
||||
|
||||
<title>SetFillColor</title>
|
||||
|
||||
<link type="text/css" rel="stylesheet" href="../fpdf.css">
|
||||
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<h1>SetFillColor</h1>
|
||||
|
||||
<code>SetFillColor(<b>int</b> r [, <b>int</b> g, <b>int</b> b])</code>
|
||||
|
||||
<h2>Descrizione</h2>
|
||||
|
||||
Definisce il colore utilizzato per tutte le operazioni di riempimento (rettangoli riempiti e
|
||||
|
||||
sfondo delle celle). Può essere espresso in componenti RGB o scala di grigi. Il metodo può
|
||||
|
||||
essere chiamato prima che la prima pagina venga creata per mantenere il valore di pagina in pagina.
|
||||
|
||||
<h2>Parametri</h2>
|
||||
|
||||
<dl class="param">
|
||||
|
||||
<dt><code>r</code></dt>
|
||||
|
||||
<dd>
|
||||
|
||||
Se <code>g</code> e <code>b</code> sono dati, indica il componente rosso; altrimenti indica il livello di grigio.
|
||||
|
||||
Valori tra 0 e 255.
|
||||
|
||||
@@ -0,0 +1,92 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
|
||||
<html>
|
||||
|
||||
<head>
|
||||
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
|
||||
|
||||
<title>SetFont</title>
|
||||
|
||||
<link type="text/css" rel="stylesheet" href="../fpdf.css">
|
||||
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<h1>SetFont</h1>
|
||||
|
||||
<code>SetFont(<b>string</b> family [, <b>string</b> style [, <b>float</b> size]])</code>
|
||||
|
||||
<h2>Descrizione</h2>
|
||||
|
||||
Imposta il font utilizzato per stampare stringhe di caratteri. E' obbligatorio chiamare questo
|
||||
|
||||
metodo almeno una volta prima di stampare del testo.
|
||||
|
||||
<br>
|
||||
|
||||
Il font può essere sia uno standard oppure uno aggiunto tramite il metodo AddFont(). I fonts
|
||||
|
||||
Standard utilizzano la codifica Windows cp1252 (Western Europe).
|
||||
|
||||
<br>
|
||||
|
||||
Il metodo può essere chiamato prima della creazione della prima pagina per mantenere il font di
|
||||
|
||||
pagina in pagina.
|
||||
|
||||
<br>
|
||||
|
||||
Se si vuole solo cambiare la dimensione del font, è più semplice chiamare SetFontSize().
|
||||
|
||||
<br>
|
||||
|
||||
<br>
|
||||
|
||||
<strong>Nota:</strong> i files di definizione devono essere accessibili. Vengono ricercati rispettivamente:
|
||||
|
||||
<ul>
|
||||
|
||||
<li>Nella directory definita dalla costante <code>FPDF_FONTPATH</code> (se la costante esiste)</li>
|
||||
|
||||
<li>Nella directory delle fonts che si trova nella stessa directory del file fpdf.php (se la directory esiste)</li>
|
||||
|
||||
<li>In tutte le directories accessibili tramite la direttiva <code>include()</code></li>
|
||||
|
||||
</ul>
|
||||
|
||||
Esempio per il caso in cui venga definita la costante <code>FPDF_FONTPATH</code>:
|
||||
|
||||
<div class="doc-source">
|
||||
|
||||
<pre><code>define('FPDF_FONTPATH','/home/www/font');
|
||||
|
||||
require('fpdf.php');</code></pre>
|
||||
|
||||
</div>
|
||||
|
||||
Se non viene trovato il file corrispondente a quello richiesto, verrà generato l'errore
|
||||
|
||||
"Could not include font definition file".
|
||||
|
||||
<h2>Parametri</h2>
|
||||
|
||||
<dl class="param">
|
||||
|
||||
<dt><code>family</code></dt>
|
||||
|
||||
<dd>
|
||||
|
||||
Famiglia del font. Può essere sia un nome definito da AddFont() o una delle famiglie standard (case
|
||||
|
||||
insensitive):
|
||||
|
||||
<ul>
|
||||
|
||||
<li><code>Courier</code> (fixed-width)</li>
|
||||
|
||||
<li><code>Helvetica</code> o <code>Arial</code> (sinonimi; sans serif)</li>
|
||||
|
||||
<li><code>Times</code> (serif)</li>
|
||||
|
||||
@@ -0,0 +1,25 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
|
||||
<html>
|
||||
|
||||
<head>
|
||||
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
|
||||
|
||||
<title>SetFontSize</title>
|
||||
|
||||
<link type="text/css" rel="stylesheet" href="../fpdf.css">
|
||||
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<h1>SetFontSize</h1>
|
||||
|
||||
<code>SetFontSize(<b>float</b> size)</code>
|
||||
|
||||
<h2>Descrizione</h2>
|
||||
|
||||
Definisce la dimensione del font corrente.
|
||||
|
||||
<h2>Parametri</h2>
|
||||
@@ -0,0 +1,33 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
|
||||
<html>
|
||||
|
||||
<head>
|
||||
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
|
||||
|
||||
<title>SetKeywords</title>
|
||||
|
||||
<link type="text/css" rel="stylesheet" href="../fpdf.css">
|
||||
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<h1>SetKeywords</h1>
|
||||
|
||||
<code>SetKeywords(<b>string</b> keywords [, <b>boolean</b> isUTF8])</code>
|
||||
|
||||
<h2>Descrizione</h2>
|
||||
|
||||
Associa keywords al documento, generalmente nella forma 'keyword1 keyword2 ...'.
|
||||
|
||||
<h2>Parametri</h2>
|
||||
|
||||
<dl class="param">
|
||||
|
||||
<dt><code>keywords</code></dt>
|
||||
|
||||
<dd>
|
||||
|
||||
L'elenco delle keywords.
|
||||
@@ -0,0 +1,30 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
|
||||
<html>
|
||||
|
||||
<head>
|
||||
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
|
||||
|
||||
<title>SetLeftMargin</title>
|
||||
|
||||
<link type="text/css" rel="stylesheet" href="../fpdf.css">
|
||||
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<h1>SetLeftMargin</h1>
|
||||
|
||||
<code>SetLeftMargin(<b>float</b> margin)</code>
|
||||
|
||||
<h2>Descrizione</h2>
|
||||
|
||||
Imposta il margine sinistro. Il metodo può essere chiamato prima della creazione della prima pagina.
|
||||
|
||||
<br>
|
||||
|
||||
Se l'ascissa corrente va fuori del margine, viene riportata nel margine.
|
||||
|
||||
<h2>Parametri</h2>
|
||||
|
||||
@@ -0,0 +1,29 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
|
||||
<html>
|
||||
|
||||
<head>
|
||||
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
|
||||
|
||||
<title>SetLineWidth</title>
|
||||
|
||||
<link type="text/css" rel="stylesheet" href="../fpdf.css">
|
||||
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<h1>SetLineWidth</h1>
|
||||
|
||||
<code>SetLineWidth(<b>float</b> width)</code>
|
||||
|
||||
<h2>Descrizione</h2>
|
||||
|
||||
Definisce lo spessore della linea. Per default, il valore è di 0.2 mm. Il metodo può essere
|
||||
|
||||
chiamato prima della creazione della prima pagina del documento per mantenere il valore di pagina in pagina.
|
||||
|
||||
<h2>Parametri</h2>
|
||||
|
||||
<dl class="param">
|
||||
@@ -0,0 +1,34 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
|
||||
<html>
|
||||
|
||||
<head>
|
||||
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
|
||||
|
||||
<title>SetLink</title>
|
||||
|
||||
<link type="text/css" rel="stylesheet" href="../fpdf.css">
|
||||
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<h1>SetLink</h1>
|
||||
|
||||
<code>SetLink(<b>int</b> link [, <b>float</b> y [, <b>int</b> page]])</code>
|
||||
|
||||
<h2>Descrizione</h2>
|
||||
|
||||
Definisce la pagina e la posizione a cui un link punta.
|
||||
|
||||
<h2>Parametri</h2>
|
||||
|
||||
<dl class="param">
|
||||
|
||||
<dt><code>link</code></dt>
|
||||
|
||||
<dd>
|
||||
|
||||
L'identificatore del link restituito da AddLink().
|
||||
|
||||
@@ -0,0 +1,37 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
|
||||
<html>
|
||||
|
||||
<head>
|
||||
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
|
||||
|
||||
<title>SetMargins</title>
|
||||
|
||||
<link type="text/css" rel="stylesheet" href="../fpdf.css">
|
||||
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<h1>SetMargins</h1>
|
||||
|
||||
<code>SetMargins(<b>float</b> left, <b>float</b> top [, <b>float</b> right])</code>
|
||||
|
||||
<h2>Descrizione</h2>
|
||||
|
||||
Definisce i margini sinistro, superiore e destro. Per default sono 1 cm. Chiamare questo metodo per
|
||||
|
||||
cambiarli.
|
||||
|
||||
<h2>Parametri</h2>
|
||||
|
||||
<dl class="param">
|
||||
|
||||
<dt><code>left</code></dt>
|
||||
|
||||
<dd>
|
||||
|
||||
Margine sinistro.
|
||||
|
||||
</dd>
|
||||
@@ -0,0 +1,28 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
|
||||
<html>
|
||||
|
||||
<head>
|
||||
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
|
||||
|
||||
<title>SetRightMargin</title>
|
||||
|
||||
<link type="text/css" rel="stylesheet" href="../fpdf.css">
|
||||
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<h1>SetRightMargin</h1>
|
||||
|
||||
<code>SetRightMargin(<b>float</b> margin)</code>
|
||||
|
||||
<h2>Descrizione</h2>
|
||||
|
||||
Definisce il margine destro. Il metodo può essere chiamato prima della creazione della prima pagina.
|
||||
|
||||
<h2>Parametri</h2>
|
||||
|
||||
<dl class="param">
|
||||
|
||||
@@ -0,0 +1,33 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
|
||||
<html>
|
||||
|
||||
<head>
|
||||
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
|
||||
|
||||
<title>SetSubject</title>
|
||||
|
||||
<link type="text/css" rel="stylesheet" href="../fpdf.css">
|
||||
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<h1>SetSubject</h1>
|
||||
|
||||
<code>SetSubject(<b>string</b> subject [, <b>boolean</b> isUTF8])</code>
|
||||
|
||||
<h2>Descrizione</h2>
|
||||
|
||||
Definisce il soggetto del documento.
|
||||
|
||||
<h2>Parametri</h2>
|
||||
|
||||
<dl class="param">
|
||||
|
||||
<dt><code>subject</code></dt>
|
||||
|
||||
<dd>
|
||||
|
||||
Il soggetto.
|
||||
@@ -0,0 +1,40 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
|
||||
<html>
|
||||
|
||||
<head>
|
||||
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
|
||||
|
||||
<title>SetTextColor</title>
|
||||
|
||||
<link type="text/css" rel="stylesheet" href="../fpdf.css">
|
||||
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<h1>SetTextColor</h1>
|
||||
|
||||
<code>SetTextColor(<b>int</b> r [, <b>int</b> g, <b>int</b> b])</code>
|
||||
|
||||
<h2>Descrizione</h2>
|
||||
|
||||
Definisce il colore utilizzato per il testo. Può essere espresso in componenti RGB o in scala di grigi.
|
||||
|
||||
Il metodo può essere chiamato prima della creazione della prima pagina per mantenere il valore di
|
||||
|
||||
pagina in pagina.
|
||||
|
||||
<h2>Parametri</h2>
|
||||
|
||||
<dl class="param">
|
||||
|
||||
<dt><code>r</code></dt>
|
||||
|
||||
<dd>
|
||||
|
||||
Se <code>g</code> e <code>b</code> sono dati, indica il componente rosso; altrimenti indica il livello di grigio.
|
||||
|
||||
Valori tra 0 e 255.
|
||||
|
||||
@@ -0,0 +1,33 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
|
||||
<html>
|
||||
|
||||
<head>
|
||||
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
|
||||
|
||||
<title>SetTitle</title>
|
||||
|
||||
<link type="text/css" rel="stylesheet" href="../fpdf.css">
|
||||
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<h1>SetTitle</h1>
|
||||
|
||||
<code>SetTitle(<b>string</b> title [, <b>boolean</b> isUTF8])</code>
|
||||
|
||||
<h2>Descrizione</h2>
|
||||
|
||||
Definisce il titolo del documento.
|
||||
|
||||
<h2>Parametri</h2>
|
||||
|
||||
<dl class="param">
|
||||
|
||||
<dt><code>title</code></dt>
|
||||
|
||||
<dd>
|
||||
|
||||
Il titolo.
|
||||
@@ -0,0 +1,28 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
|
||||
<html>
|
||||
|
||||
<head>
|
||||
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
|
||||
|
||||
<title>SetTopMargin</title>
|
||||
|
||||
<link type="text/css" rel="stylesheet" href="../fpdf.css">
|
||||
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<h1>SetTopMargin</h1>
|
||||
|
||||
<code>SetTopMargin(<b>float</b> margin)</code>
|
||||
|
||||
<h2>Descrizione</h2>
|
||||
|
||||
Definisce il margine superiore. Il metodo può essere chiamato prima della creazione della prima pagina.
|
||||
|
||||
<h2>Parametri</h2>
|
||||
|
||||
<dl class="param">
|
||||
|
||||
@@ -0,0 +1,29 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
|
||||
<html>
|
||||
|
||||
<head>
|
||||
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
|
||||
|
||||
<title>SetX</title>
|
||||
|
||||
<link type="text/css" rel="stylesheet" href="../fpdf.css">
|
||||
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<h1>SetX</h1>
|
||||
|
||||
<code>SetX(<b>float</b> x)</code>
|
||||
|
||||
<h2>Descrizione</h2>
|
||||
|
||||
Definisce l'ascissa della posizione corrente. Se il valore passato è negativo, è relativo alla
|
||||
|
||||
destra della pagina.
|
||||
|
||||
<h2>Parametri</h2>
|
||||
|
||||
<dl class="param">
|
||||
@@ -0,0 +1,31 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
|
||||
<html>
|
||||
|
||||
<head>
|
||||
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
|
||||
|
||||
<title>SetXY</title>
|
||||
|
||||
<link type="text/css" rel="stylesheet" href="../fpdf.css">
|
||||
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<h1>SetXY</h1>
|
||||
|
||||
<code>SetXY(<b>float</b> x, <b>float</b> y)</code>
|
||||
|
||||
<h2>Descrizione</h2>
|
||||
|
||||
Definisce l'ascissa e l'ordinata della posizione corrente. Se i valori passati sono negativi,
|
||||
|
||||
sono relativi rispettivamente alla destra ed al fondo della pagina.
|
||||
|
||||
<h2>Parametri</h2>
|
||||
|
||||
<dl class="param">
|
||||
|
||||
<dt><code>x</code></dt>
|
||||
@@ -0,0 +1,33 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
|
||||
<html>
|
||||
|
||||
<head>
|
||||
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
|
||||
|
||||
<title>SetY</title>
|
||||
|
||||
<link type="text/css" rel="stylesheet" href="../fpdf.css">
|
||||
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<h1>SetY</h1>
|
||||
|
||||
<code>SetY(<b>float</b> y [, <b>boolean</b> resetX])</code>
|
||||
|
||||
<h2>Descrizione</h2>
|
||||
|
||||
Imposta l'ordinata e a scelta sposta l'ascissa corrente al margine sinistro. Se il valore passato
|
||||
|
||||
è negativo, è relativo al fondo della pagina.
|
||||
|
||||
<h2>Parametri</h2>
|
||||
|
||||
<dl class="param">
|
||||
|
||||
<dt><code>y</code></dt>
|
||||
|
||||
<dd>
|
||||
@@ -0,0 +1,40 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
|
||||
<html>
|
||||
|
||||
<head>
|
||||
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
|
||||
|
||||
<title>Text</title>
|
||||
|
||||
<link type="text/css" rel="stylesheet" href="../fpdf.css">
|
||||
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<h1>Text</h1>
|
||||
|
||||
<code>Text(<b>float</b> x, <b>float</b> y, <b>string</b> txt)</code>
|
||||
|
||||
<h2>Descrizione</h2>
|
||||
|
||||
Stampa una stringa di caratteri. L'origine è alla sinistra del primo carattere, sulla baseline.
|
||||
|
||||
Questo metodo permette di posizionare una stringa con precisione sulla pagina, ma di norma è
|
||||
|
||||
più semplice utilizzare Cell(), MultiCell() o Write() che sono i metodi standard per stampare
|
||||
|
||||
del testo.
|
||||
|
||||
<h2>Parametri</h2>
|
||||
|
||||
<dl class="param">
|
||||
|
||||
<dt><code>x</code></dt>
|
||||
|
||||
<dd>
|
||||
|
||||
Ascissa dell'origine.
|
||||
|
||||
@@ -0,0 +1,51 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
|
||||
<html>
|
||||
|
||||
<head>
|
||||
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
|
||||
|
||||
<title>Write</title>
|
||||
|
||||
<link type="text/css" rel="stylesheet" href="../fpdf.css">
|
||||
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<h1>Write</h1>
|
||||
|
||||
<code>Write(<b>float</b> h, <b>string</b> txt [, <b>mixed</b> link])</code>
|
||||
|
||||
<h2>Descrizione</h2>
|
||||
|
||||
Questo metodo stampa del testo dalla posizione corrente. Quando viene raggiunto il margine destro (o viene
|
||||
|
||||
incontrato il carattere \n) viene inserita una interruzione di linea e il testo continua dal margine sinistro.
|
||||
|
||||
All'uscita del metodo, la posizione corrente è lasciata alla fine del testo.
|
||||
|
||||
<br>
|
||||
|
||||
E' possibile inserire un link nel testo.
|
||||
|
||||
<h2>Parametri</h2>
|
||||
|
||||
<dl class="param">
|
||||
|
||||
<dt><code>h</code></dt>
|
||||
|
||||
<dd>
|
||||
|
||||
Altezza della linea.
|
||||
|
||||
</dd>
|
||||
|
||||
<dt><code>txt</code></dt>
|
||||
|
||||
<dd>
|
||||
|
||||
Stringa da stampare.
|
||||
|
||||
</dd>
|
||||
Reference in New Issue
Block a user