classes-Com-Tecnick-Pdf-Graph-Base

It appears that you are using AdBlocking software. The cost of running this website is covered by advertisements. If you like it please feel free to a small amount of money to secure the future of this website.

Base

Com\Tecnick\Pdf\Graph\Base

Tags
since
2011-05-23
category

Library

author

Nicola Asuni info@tecnick.com

copyright

2011-2016 Nicola Asuni - Tecnick.com LTD

license

http://www.gnu.org/copyleft/lesser.html GNU-LGPL v3 (see LICENSE.TXT)

link
https://github.com/tecnickcom/tc-lib-pdf-graph

Table of Contents

MPI  = 3.141592653589793
Pi constant We use this instead of M_PI because HHVM has a different value.
$col  : Pdf
Color object
$enc  : Encrypt
Encrypt object
$kunit  : float
Unit of measure conversion ratio
$pageh  : float
Current page height
$pagew  : float
Current page width
$pdfa  : bool
True if we are in PDF/A mode.
$pon  : int
Current PDF object number
__construct()  : mixed
Initialize
getObjectNumber()  : int
Returns current PDF object number
getOutExtGState()  : string
Get the PDF output string for ExtGState
getOutExtGStateResources()  : string
Get the PDF output string for ExtGState Resource Dictionary
getOutGradientResources()  : string
Get the PDF output string for Gradients Resource Dictionary
getOutGradientShaders()  : string
Get the PDF output string for gradient shaders
init()  : mixed
Initialize objects
setKUnit()  : mixed
Set unit of measure conversion ratio.
setPageHeight()  : mixed
Set page height
setPageWidth()  : mixed
Set page width
getOutGradientCols()  : string
Get the PDF output string for gradient colors and transparency
getOutPatternObj()  : string
Get the PDF output string for the pattern and shading object

Constants

MPI

Pi constant We use this instead of M_PI because HHVM has a different value.

public float MPI = 3.141592653589793

Properties

$col

Color object

protected Pdf $col

$enc

Encrypt object

protected Encrypt $enc

$kunit

Unit of measure conversion ratio

protected float $kunit = 1.0

$pageh

Current page height

protected float $pageh = 0

$pagew

Current page width

protected float $pagew = 0

$pdfa

True if we are in PDF/A mode.

protected bool $pdfa = false

$pon

Current PDF object number

protected int $pon

Methods

__construct()

Initialize

public __construct(float $kunit, float $pagew, float $pageh, Pdf $color, Encrypt $enc[, bool $pdfa = false ]) : mixed
Parameters
$kunit : float

Unit of measure conversion ratio.

$pagew : float

Page width.

$pageh : float

Page height.

$color : Pdf

Color object.

$enc : Encrypt
$pdfa : bool = false

True if we are in PDF/A mode.

Return values
mixed

getObjectNumber()

Returns current PDF object number

public getObjectNumber() : int
Return values
int

getOutExtGState()

Get the PDF output string for ExtGState

public getOutExtGState(int $pon) : string
Parameters
$pon : int

Current PDF Object Number

Return values
string

PDF command

getOutExtGStateResources()

Get the PDF output string for ExtGState Resource Dictionary

public getOutExtGStateResources() : string
Return values
string

PDF command

getOutGradientResources()

Get the PDF output string for Gradients Resource Dictionary

public getOutGradientResources() : string
Return values
string

PDF command

getOutGradientShaders()

Get the PDF output string for gradient shaders

public getOutGradientShaders(int $pon) : string
Parameters
$pon : int

Current PDF Object Number

Return values
string

PDF command

init()

Initialize objects

public abstract init() : mixed
Return values
mixed

setKUnit()

Set unit of measure conversion ratio.

public setKUnit(float $kunit) : mixed
Parameters
$kunit : float

Unit of measure conversion ratio.

Return values
mixed

setPageHeight()

Set page height

public setPageHeight(float $pageh) : mixed
Parameters
$pageh : float

Page height

Return values
mixed

setPageWidth()

Set page width

public setPageWidth(float $pagew) : mixed
Parameters
$pagew : float

Page width

Return values
mixed

getOutGradientCols()

Get the PDF output string for gradient colors and transparency

protected getOutGradientCols(array<string|int, mixed> $grad, string $type) : string
Parameters
$grad : array<string|int, mixed>

Array of gradient colors

$type : string

Type of output: 'color' or 'opacity'

Return values
string

PDF command

getOutPatternObj()

Get the PDF output string for the pattern and shading object

protected getOutPatternObj(array<string|int, mixed> $grad, int $objref) : string
Parameters
$grad : array<string|int, mixed>

Array of gradient colors

$objref : int

Refrence object number

Return values
string

PDF command

 

© 2004-2021 – Nicola Asuni - Tecnick.com - All rights reserved.
about - disclaimer - privacy