Documentation

Stream
in package

Pdf page text stream class

Tags
category

Pop

author

Nick Sagona, III dev@nolainteractive.com

copyright

Copyright (c) 2009-2024 NOLA Interactive, LLC. (http://www.nolainteractive.com)

license

http://www.popphp.org/license New BSD License

version
5.2.0

Table of Contents

Properties

$currentX  : int|float|null
Current X
$currentY  : int|float|null
Current Y
$edgeX  : int|null
Edge X boundary
$edgeY  : int|float|null
Edge Y boundary
$orphanIndex  : array<string|int, mixed>
Orphan index
$startX  : int|float|null
Start X
$startY  : int|float|null
Start Y
$streams  : array<string|int, mixed>
Text streams
$styles  : array<string|int, mixed>
Text styles

Methods

__construct()  : mixed
Constructor
addText()  : Stream
Add text to the stream
getColorStream()  : string
Get the partial color stream
getCurrentX()  : int|float|null
Get current X
getCurrentY()  : int|float|null
Get current Y
getEdgeX()  : int|float|null
Get edge X boundary
getEdgeY()  : int|float|null
Get edge Y boundary
getOrphanStream()  : Stream
Resume stream from orphaned index
getStartX()  : int|float|null
Get start X
getStartY()  : int|float|null
Get start Y
getStream()  : string
Get stream
getTextStreams()  : array<string|int, mixed>
Get text stream
hasOrphanIndex()  : bool
Check if the text stream has orphan streams due to the page bottom
hasOrphans()  : bool
Prepare stream
hasTextStreams()  : bool
Has text streams
setCurrentStyle()  : Stream
Set the current style
setCurrentX()  : Stream
Set current X
setCurrentY()  : Stream
Set current Y
setEdgeX()  : Stream
Set edge X boundary
setEdgeY()  : Stream
Set edge Y boundary
setStartX()  : Stream
Set start X
setStartY()  : Stream
Set start Y

Properties

$currentX

Current X

protected int|float|null $currentX = null

$currentY

Current Y

protected int|float|null $currentY = null

$edgeX

Edge X boundary

protected int|null $edgeX = null

$edgeY

Edge Y boundary

protected int|float|null $edgeY = null

$orphanIndex

Orphan index

protected array<string|int, mixed> $orphanIndex = []

$startX

Start X

protected int|float|null $startX = null

$startY

Start Y

protected int|float|null $startY = null

$streams

Text streams

protected array<string|int, mixed> $streams = []

$styles

Text styles

protected array<string|int, mixed> $styles = []

Methods

__construct()

Constructor

public __construct(int $startX, int $startY, int $edgeX[, int|null $edgeY = null ]) : mixed

Instantiate a PDF text stream object.

Parameters
$startX : int
$startY : int
$edgeX : int
$edgeY : int|null = null

addText()

Add text to the stream

public addText(string $string[, int|float|null $y = null ]) : Stream
Parameters
$string : string
$y : int|float|null = null
Return values
Stream

getCurrentX()

Get current X

public getCurrentX() : int|float|null
Return values
int|float|null

getCurrentY()

Get current Y

public getCurrentY() : int|float|null
Return values
int|float|null

getEdgeX()

Get edge X boundary

public getEdgeX() : int|float|null
Return values
int|float|null

getEdgeY()

Get edge Y boundary

public getEdgeY() : int|float|null
Return values
int|float|null

getOrphanStream()

Resume stream from orphaned index

public getOrphanStream() : Stream
Return values
Stream

getStartX()

Get start X

public getStartX() : int|float|null
Return values
int|float|null

getStartY()

Get start Y

public getStartY() : int|float|null
Return values
int|float|null

getStream()

Get stream

public getStream(array<string|int, mixed> $fonts, array<string|int, mixed> $fontReferences) : string
Parameters
$fonts : array<string|int, mixed>
$fontReferences : array<string|int, mixed>
Return values
string

getTextStreams()

Get text stream

public getTextStreams() : array<string|int, mixed>
Return values
array<string|int, mixed>

hasOrphanIndex()

Check if the text stream has orphan streams due to the page bottom

public hasOrphanIndex() : bool
Return values
bool

hasOrphans()

Prepare stream

public hasOrphans(array<string|int, mixed> $fonts) : bool
Parameters
$fonts : array<string|int, mixed>
Return values
bool

hasTextStreams()

Has text streams

public hasTextStreams() : bool
Return values
bool

setCurrentStyle()

Set the current style

public setCurrentStyle(string $font, int $size[, ColorInterface|null $color = null ]) : Stream
Parameters
$font : string
$size : int
$color : ColorInterface|null = null
Return values
Stream

setCurrentX()

Set current X

public setCurrentX(int|float $currentX) : Stream
Parameters
$currentX : int|float
Return values
Stream

setCurrentY()

Set current Y

public setCurrentY(int|float $currentY) : Stream
Parameters
$currentY : int|float
Return values
Stream

setEdgeX()

Set edge X boundary

public setEdgeX(int|float $edgeX) : Stream
Parameters
$edgeX : int|float
Return values
Stream

setEdgeY()

Set edge Y boundary

public setEdgeY(int|float $edgeY) : Stream
Parameters
$edgeY : int|float
Return values
Stream

setStartX()

Set start X

public setStartX(int|float $startX) : Stream
Parameters
$startX : int|float
Return values
Stream

setStartY()

Set start Y

public setStartY(int|float $startY) : Stream
Parameters
$startY : int|float
Return values
Stream

        
On this page

Search results