GXPS.Document¶
- Subclasses:
None
Methods¶
- Inherited:
- Structs:
|
|
|
|
|
|
|
|
Virtual Methods¶
- Inherited:
Properties¶
Name |
Type |
Flags |
Short Description |
|---|---|---|---|
w/co |
The Document Source File |
Signals¶
- Inherited:
Fields¶
- Inherited:
Name |
Type |
Access |
Description |
|---|---|---|---|
parent |
r |
Class Details¶
- class GXPS.Document(**kwargs)¶
- Bases:
- Abstract:
No
- Structure:
The
GXPS.Documentstruct contains only private fields and should not be directly accessed.- get_page(n_page)¶
- Parameters:
n_page (
int) – the index of the page to get- Raises:
- Returns:
a new
GXPS.PageorNoneon error. Free the returned object withGObject.Object.unref().- Return type:
Creates a new
GXPS.Pagerepresenting the page at index n_doc in self document.
- get_page_for_anchor(anchor)¶
- Parameters:
anchor (
str) – the name of an anchor- Returns:
the page index of the given anchor.
- Return type:
Gets the index of the page in self where the given anchor is.
- get_page_size(n_page)¶
- Parameters:
n_page (
int) – the index of a page in self- Returns:
Trueif the page size information is available in self,Falseotherwise.- width:
return location for the width of n_page
- height:
return location for the height of n_page
- Return type:
Gets the typical size of the page at index n_page in self document. This function is useful to get the advisory size of pages in a document without creating
GXPS.Pageobjects. This page size might be different than the actual page size so page dimension might need to be updated once the page is loaded. Advisory page sizes are not always available in self, in which case this function returnsFalse. To get the authoritative size of a page you should useGXPS.Page.get_size() instead.
- get_structure()¶
- Returns:
a new
GXPS.DocumentStructureorNoneif document doesn’t have a structure. Free the returned object withGObject.Object.unref().- Return type:
Creates a new
GXPS.DocumentStructurerepresenting the document structure of self.
Property Details¶
- GXPS.Document.props.source¶
- Name:
source- Type:
- Default Value:
- Flags:
The Document Source File