| Package | com.rubenswieringa.book |
| Class | public class Page |
| Inheritance | Page mx.containers.Canvas |
See also
| Property | Defined by | ||
|---|---|---|---|
| book : Book
[read-only]
Book instance with which this Page is associated.
| Page | ||
| explicitHard : Boolean [read-only]
Returns the hard option for this Page only, where the hard property returns true if either this Page or its flipside is hard.
| Page | ||
| explicitTearable : Boolean [read-only]
Returns the tearable option for this Page only, where the tearable property returns true if either this Page or its flipside is tearable.
| Page | ||
| hard : Boolean
Indicates whether or not this Page should be hard (true) or flexible (false).
| Page | ||
| index : int [write-only]
Index of this Page within the pages property of the containing Book instance.
| Page | ||
| liveBitmapping : Boolean
Indicates whether or not this Page plays animation while being flipped.
| Page | ||
| lock : Boolean = false
If true, this Page can not be flipped over.
| Page | ||
| side : int [write-only]
int indicating on which side the Page is displayed (0=left, 1=right).
| Page | ||
| tearable : Boolean
Indicates whether or not this Page should be allowed to be be torn from its Book, false if not.
| Page | ||
| Method | Defined by | ||
|---|---|---|---|
|
Page()
Constructor
| Page | ||
|
clearFoldGradient():void
Erases the gradient on the folding-side of the page.
| Page | ||
|
drawFoldGradient():void
Draws a gradient on the folding-side of the page.
| Page | ||
|
getBitmapData():BitmapData
Draws itself on a BitmapData instance and returns it.
| Page | ||
|
Returns the Page instance that is displayed on the other side of this Page.
| Page | ||
|
hideFoldGradient():void
Hides fold-gradient.
| Page | ||
|
isFirstPage():Boolean
Returns true if this is the first Page in the Book it belongs to, false otherwise.
| Page | ||
|
isLastPage():Boolean
Returns true if this is the last Page in the Book it belongs to, false otherwise.
| Page | ||
|
refreshFoldGradient(includeFlipSide:Boolean = true):void
Erase or draw fold gradient for this Page and the Page on the flipside (if includeFlipSide is true).
| Page | ||
|
showFoldGradient():void
Shows fold-gradient.
| Page | ||
|
tear(fromTop:Boolean = true):void
Tears this Page instance out of its corresponding Book.When called, this method will be executed regardless of the tearable property its value.
| Page | ||
| book | property |
book:Book [read-only]Book instance with which this Page is associated. Can only be set once.
Implementation public function get book():Book
See also
| explicitHard | property |
explicitHard:Boolean [read-only]Returns the hard option for this Page only, where the hard property returns true if either this Page or its flipside is hard. Unless you're modifying this class you will most likely not need to use this property.
The default value is false.
public function get explicitHard():Boolean
See also
| explicitTearable | property |
explicitTearable:Boolean [read-only]Returns the tearable option for this Page only, where the tearable property returns true if either this Page or its flipside is tearable. Unless you're modifying this class you will most likely not need to use this property.
The default value is false.
public function get explicitTearable():Boolean
See also
| hard | property |
hard:Boolean [read-write]Indicates whether or not this Page should be hard (true) or flexible (false). Defaults to false. Returns true if either this Page or the flipside Page has is hard..
The default value is false.
public function get hard():Boolean
public function set hard(value:Boolean):void
See also
| index | property |
index:int [write-only]Index of this Page within the pages property of the containing Book instance.
This property can be used as the source for data binding.
Implementation public function set index(value:int):void
See also
| liveBitmapping | property |
liveBitmapping:Boolean [read-write]Indicates whether or not this Page plays animation while being flipped. Note that enabling liveBitmapping may result in decreased performance.
The default value is false.
public function get liveBitmapping():Boolean
public function set liveBitmapping(value:Boolean):void
See also
| lock | property |
public var lock:Boolean = falseIf true, this Page can not be flipped over.
The default value is false.
| side | property |
side:int [write-only]int indicating on which side the Page is displayed (0=left, 1=right).
This property can be used as the source for data binding.
Implementation public function set side(value:int):void
See also
| tearable | property |
tearable:Boolean [read-write]Indicates whether or not this Page should be allowed to be be torn from its Book, false if not. Defaults to false. Returns true if either this Page or its flipside Page has is tearable, or if the Book associated with this Page has its tearable property set to true. Note that even if a Page has its tearable property set to false, it can still be torn out of its Book with the tear() or tearPage() methods. This property merely indicates whether or not tearing can be achieved by dragging the page-corner manually.
The default value is false.
public function get tearable():Boolean
public function set tearable(value:Boolean):void
See also
| Page | () | constructor |
public function Page()Constructor
| clearFoldGradient | () | method |
public function clearFoldGradient():voidErases the gradient on the folding-side of the page.
| drawFoldGradient | () | method |
public function drawFoldGradient():voidDraws a gradient on the folding-side of the page.
| getBitmapData | () | method |
public function getBitmapData():BitmapDataDraws itself on a BitmapData instance and returns it.
ReturnsBitmapData — BitmapData
|
| getFlipSide | () | method |
public function getFlipSide():PageReturns the Page instance that is displayed on the other side of this Page.
ReturnsPage —
Page
|
| hideFoldGradient | () | method |
public function hideFoldGradient():voidHides fold-gradient.
| isFirstPage | () | method |
public function isFirstPage():BooleanReturns true if this is the first Page in the Book it belongs to, false otherwise.
ReturnsBoolean — Boolean indicating whether or not the Page is the first in line
|
| isLastPage | () | method |
public function isLastPage():BooleanReturns true if this is the last Page in the Book it belongs to, false otherwise.
ReturnsBoolean — Boolean indicating whether or not the Page is the last in line
|
| refreshFoldGradient | () | method |
public function refreshFoldGradient(includeFlipSide:Boolean = true):voidErase or draw fold gradient for this Page and the Page on the flipside (if includeFlipSide is true).
ParametersincludeFlipSide:Boolean (default = true) — Boolean indicating whether or not to draw the fold-gradient for this Page its flipside.
|
| showFoldGradient | () | method |
public function showFoldGradient():voidShows fold-gradient.
| tear | () | method |
public function tear(fromTop:Boolean = true):voidTears this Page instance out of its corresponding Book.When called, this method will be executed regardless of the tearable property its value.
ParametersfromTop:Boolean (default = true) — If true, the Page will be torn out by its upper outer corner, if false by its lower outer corner.
|
— Gets thrown when page is an index-value and out of bounds.
|
See also
| LEFT | constant |
public static const LEFT:uint = 0
| RIGHT | constant |
public static const RIGHT:uint = 1