|
Gnostice PDFOne
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.gnostice.pdfone.PdfViewerPageDisplaySettings
This class represents default settings that can be set for a
PDF viewer
component before
it loads a document.
The PdfViewer.getPageDisplaySettings()
method
returns an instance of this class. Use the methods of that instance
to read or modify the settings.
To change default settings of a viewer, call the
PdfViewer.setPageDisplaySettings(PdfViewerPageDisplaySettings pageDisplaySettings)
method with the PdfViewerPageDisplaySettings
instance whose settings have been modified.
The new settings will be used when the viewer component loads
another document. Do not expect changes to default settings to
affect viewer display in real time. PdfViewer
class
provides a different set of methods for such purposes.
Constructor Summary | |
PdfViewerPageDisplaySettings()
Zero-argument default constructor. |
Method Summary | |
int |
getDpi()
Returns DPI (dot per inch) set for the viewer component. |
Insets |
getGapsBetweenPages()
Returns current insets (margins or separation) around the pages displayed in the viewer. |
int |
getPageColumnsCustomCount()
Returns maximum number of pages that the viewer component is set to display in a row. |
int |
getPageLayout()
Returns page layout setting for the viewer component. |
int |
getPageView()
Returns how viewer component is set to fit pages within its display area. |
boolean |
isPageLayoutInitAsPerDoc()
Returns whether layout settings of the viewer are set to be as specified in the document that is displayed. |
boolean |
isShowCoverPageDuringSideBySide()
Specifies whether the viewer component is set to display the first page singly. |
boolean |
isShowGapsBetweenPages()
Specifies whether the viewer displays spaces around pages when it displays a document. |
boolean |
isShowPageBordersWhenNoPageGaps()
Returns whether the viewer component needs to draw page borders when it displays no insets around the pages. |
void |
loadSettings(File inputFile)
Loads viewer display settings from a properties file. |
void |
loadSettings(InputStream inputStream)
Loads viewer display settings from a properties file specified by a stream. |
void |
reset()
|
void |
saveSettings(File outputFile)
Saves viewer display settings to a properties file. |
void |
saveSettings(OutputStream outputStream)
Saves viewer display settings to a properties file specified by a stream. |
void |
setDpi(int dpi)
Sets specified DPI for the viewer component. |
void |
setGapsBetweenPages(Insets gapsBetweenPages)
Set insets (margins or separation) that the viewer component needs to use when it displays pages in a document. |
void |
setPageColumnsCustomCount(int pageColumnsCustomCount)
Sets specified maximum number of pages that the viewer component needs display in a row. |
void |
setPageLayout(int pageLayout)
Sets specified page layout setting for the viewer component. |
void |
setPageLayoutInitAsPerDoc(boolean isPageLayoutInitAsPerDoc)
Sets whether layout settings of the viewer need to be set as specified in the document that is displayed. |
void |
setPageView(int pageView)
Sets how viewer component fits pages within its display area. |
void |
setShowCoverPageDuringSideBySide(boolean showCoverPageDuringSideBySide)
Sets whether the viewer component is set to display the first page singly. |
void |
setShowGapsBetweenPages(boolean showGapsBetweenPages)
Makes the viewer component display spaces around page when it displays a document. |
void |
setShowPageBordersWhenNoPageGaps(boolean showPageBordersWhenNoPageGaps)
Sets whether viewer component needs to draw page borders when it displays no insets around the pages. |
void |
showPageDisplaySettingsDialog(boolean isModal)
Displays a modal/non-modal dialog box for allowing the user to specify page display settings. |
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public PdfViewerPageDisplaySettings()
Method Detail |
public void showPageDisplaySettingsDialog(boolean isModal)
isModal
- whether the dialog box is modalpublic void reset()
public void loadSettings(File inputFile) throws PdfException, IOException
inputFile
- pathname of the file
PdfException
- if an illegal argument is supplied.
IOException
- if an I/O error occurs.public void loadSettings(InputStream inputStream) throws IOException, PdfException
inputStream
- stream containing the properties file
PdfException
- if an illegal argument is supplied.
IOException
- if an I/O error occurs.saveSettings(OutputStream)
public void saveSettings(File outputFile) throws IOException, PdfException
outputFile
- pathname of the file
PdfException
- if an illegal argument is supplied.
IOException
- if an I/O error occurs.public void saveSettings(OutputStream outputStream) throws IOException
outputStream
- stream containing the properties file
IOException
- if an I/O error occurs.loadSettings(InputStream)
public int getDpi()
constant
representing the
current DPI of the viewer componentsetDpi(int)
public void setDpi(int dpi) throws PdfException
dpi
- constant
representing the
DPI that needs to be set for the viewer component
PdfException
- if an illegal argument is supplied.getDpi()
public boolean isPageLayoutInitAsPerDoc()
true
if layout settings specified in the
document are set to be used. false
if
viewer defaults are used.setPageLayoutInitAsPerDoc(boolean)
public void setPageLayoutInitAsPerDoc(boolean isPageLayoutInitAsPerDoc)
isPageLayoutInitAsPerDoc
- true
if settings specified in the
document need to be used. false
if
viewer defaults need to be used.isPageLayoutInitAsPerDoc()
public int getPageColumnsCustomCount()
setPageColumnsCustomCount(int)
public void setPageColumnsCustomCount(int pageColumnsCustomCount)
pageColumnsCustomCount
- number of pages in a rowgetPageColumnsCustomCount()
public int getPageLayout()
PdfViewer.LAYOUT_SINGLE_PAGE_CONTINUOUS
.
constant
specifying layout settingsetPageLayout(int)
public void setPageLayout(int pageLayout) throws PdfException
PdfViewer.LAYOUT_SINGLE_PAGE_CONTINUOUS
.
pageLayout
- constant
specifying layout setting
PdfException
- if an illegal argument is supplied.getPageLayout()
public Insets getGapsBetweenPages()
setGapsBetweenPages(Insets)
public void setGapsBetweenPages(Insets gapsBetweenPages)
gapsBetweenPages
- insets that viewer needs to use when displaying
pages from a documentgetGapsBetweenPages()
public boolean isShowGapsBetweenPages()
setShowGapsBetweenPages(boolean)
public void setShowGapsBetweenPages(boolean showGapsBetweenPages)
showGapsBetweenPages
- isShowGapsBetweenPages()
public boolean isShowPageBordersWhenNoPageGaps()
setShowPageBordersWhenNoPageGaps(boolean)
public void setShowPageBordersWhenNoPageGaps(boolean showPageBordersWhenNoPageGaps)
showPageBordersWhenNoPageGaps
- whether viewer component needs to draw page borders
when it displays no insets around the pages.isShowPageBordersWhenNoPageGaps()
public boolean isShowCoverPageDuringSideBySide()
setShowCoverPageDuringSideBySide(boolean)
public void setShowCoverPageDuringSideBySide(boolean showCoverPageDuringSideBySide)
showCoverPageDuringSideBySide
- whether the viewer component is set to display the
first page singly.isShowCoverPageDuringSideBySide()
public int getPageView()
PdfViewer.PAGEVIEW_ACTUAL_SIZE
.
constant
specify
the fit stylesetPageView(int)
public void setPageView(int pageView)
PdfViewer.PAGEVIEW_ACTUAL_SIZE
.
pageView
- constant
specify the fit stylegetPageView()
|
Pro. Ed. v5.0.0 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |