public class PrintManager
extends java.lang.Object
| Constructor and Description |
|---|
PrintManager() |
| Modifier and Type | Method and Description |
|---|---|
void |
appendPage(PDDocument doc,
PageInfo pageInfo)
Append the page info to the specified pdf document.
|
void |
appendPage(PDDocument doc,
PageInfo pageInfo,
PdfSaveOptions options)
Append the page info to the specified pdf document.
|
void |
draw(PDDocument doc,
PDPage page,
java.util.List<PageInfo> pages,
int rows,
int columns)
Draw the pages in the page collection on a page in a certain direction.
|
void |
draw(PDDocument doc,
PDPage page,
java.util.List<PageInfo> pages,
int rows,
int columns,
Order order)
Draw the pages in the page collection on a page in a certain direction.
|
void |
draw(PDDocument doc,
PDPage page,
java.util.List<PageInfo> pages,
int rows,
int columns,
Order order,
PdfSaveOptions options)
Draw the pages in the page collection on a page in a certain direction.
|
void |
draw(PDDocument doc,
PDPage page,
Point location,
IRange range)
Draw the range data to the specific location in a specified pdf page.
|
void |
draw(PDDocument doc,
PDPage page,
Point location,
IRange range,
PdfSaveOptions options)
Draw the range data to the specific location in a specified pdf page.
|
void |
draw(PDDocument doc,
PDPage page,
Rectangle rect,
IRange range)
Draw the range data to the specific location in a specified pdf page.
|
void |
draw(PDDocument doc,
PDPage page,
Rectangle rect,
IRange range,
PdfSaveOptions options)
Draw the range data to the specific location in a specified pdf page.
|
void |
draw(PDDocument doc,
PDPage page,
Rectangle rect,
PageContentInfo pageContent)
Draw the page info to the specific location in a specified pdf page.
|
void |
draw(PDDocument doc,
PDPage page,
Rectangle rect,
PageContentInfo pageContent,
PdfSaveOptions options)
Draw the page info to the specific location in a specified pdf page.
|
void |
draw(PDDocument doc,
PDPage page,
Rectangle rect,
PageInfo pageInfo)
Draw the page info to the specific location in a specified pdf page.
|
void |
draw(PDDocument doc,
PDPage page,
Rectangle rect,
PageInfo pageInfo,
PdfSaveOptions options)
Draw the page info to the specific location in a specified pdf page.
|
PageContentInfo |
generatePageContentInfo(IRange printArea,
Size availableSize,
int rowStart,
int columnStart,
boolean rowHeaderVisible,
boolean columnHeaderVisible)
Returns a PageContentInfo object.
|
PageContentInfo |
generatePageContentInfo(IRange printArea,
Size availableSize,
int rowStart,
int columnStart,
boolean rowHeaderVisible,
boolean columnHeaderVisible,
double rowHeaderWidth,
int titleRowStart,
int titleRowEnd,
int tailRowStart,
int tailRowEnd,
int titleColumnStart,
int titleColumnEnd,
int tailColumnStart,
int tailColumnEnd,
double zoomFactor,
boolean ignoreRowPageBreaks)
Returns a PageContentInfo object.
|
WorkbookCache |
getCache(IWorkbook workbook) |
WorksheetCache |
getCache(IWorksheet worksheet) |
PageSettings |
getPageSettings(IWorksheet worksheet,
PageType type) |
java.util.List<java.lang.Integer> |
GetPaginationInfo(IWorksheet worksheet,
PaginationOrientation orientation)
Returns an array of row or column indexes which represents the page boundaries for vertical or horizontal paging.
|
java.util.List<java.lang.Integer> |
GetPaginationInfo(IWorksheet worksheet,
PaginationOrientation orientation,
java.util.List<IRange> keepTogetherRanges,
java.util.List<RepeatSetting> repeatSettings)
Returns an array of row or column indexes which represents the page boundaries for vertical or horizontal paging.
|
java.util.List<IRange> |
getPrintAreas(IWorksheet worksheet)
Returns the size in points of the paper.
|
Size |
getSize(IRange range)
Returns the size of the range.
|
Size |
getSize(PageContentInfo contentInfo)
Returns the size of the PageContentInfo.
|
boolean |
hasPrintContent(IRange range)
Returns whether there has content to print.
|
java.util.List<PageInfo> |
paginate(IRange printArea)
Generate pagination information for the range.
|
java.util.List<PageInfo> |
paginate(IWorkbook workbook)
Generate pagination informations for all worksheets in the workbook.
|
java.util.List<PageInfo> |
paginate(IWorksheet worksheet)
Generate pagination information for the worksheet.
|
java.util.List<PageInfo> |
paginate(IWorksheet worksheet,
java.util.List<IRange> keepTogetherRanges,
java.util.List<RepeatSetting> repeatSettings)
Generate pagination information for the worksheet.
|
java.util.List<PageInfo> |
paginate(java.util.List<IWorkbook> workbooks)
Generate pagination informations for all worksheets in all workbooks.
|
void |
savePageInfosToPDF(java.io.OutputStream stream,
java.util.List<PageInfo> pages)
Saves the page datas to the specified pdf file stream.
|
void |
savePageInfosToPDF(java.io.OutputStream stream,
java.util.List<PageInfo> pages,
PdfSaveOptions options)
Saves the page datas to the specified pdf file stream.
|
void |
savePageInfosToPDF(java.lang.String fileName,
java.util.List<PageInfo> pages)
Saves the page datas to the specified pdf file.
|
void |
savePageInfosToPDF(java.lang.String fileName,
java.util.List<PageInfo> pages,
PdfSaveOptions options)
Saves the page datas to the specified pdf file.
|
void |
saveWorkbooksToPDF(java.io.OutputStream stream,
java.util.List<IWorkbook> workbooks)
Saves the datas from different workbooks to the specified pdf file stream.
|
void |
saveWorkbooksToPDF(java.io.OutputStream stream,
java.util.List<IWorkbook> workbooks,
PdfSaveOptions options)
Saves the datas from different workbooks to the specified pdf file stream.
|
void |
saveWorkbooksToPDF(java.lang.String fileName,
java.util.List<IWorkbook> workbooks)
Saves the datas from different workbooks to the specified pdf file.
|
void |
saveWorkbooksToPDF(java.lang.String fileName,
java.util.List<IWorkbook> workbooks,
PdfSaveOptions options)
Saves the datas from different workbooks to the specified pdf file.
|
void |
updatePageNumberAndPageSettings(java.util.List<PageInfo> pages)
Update the page number, page count and page settings of each page.
|
void |
updatePageNumberAndPageSettings(java.util.List<PageInfo> pages,
int firstPageNumber,
int pageCount)
Update the page number, page count and page settings of each page.
|
public final void saveWorkbooksToPDF(java.io.OutputStream stream,
java.util.List<IWorkbook> workbooks)
stream - The specified pdf file.workbooks - The workbook collection.public final void saveWorkbooksToPDF(java.io.OutputStream stream,
java.util.List<IWorkbook> workbooks,
PdfSaveOptions options)
stream - The specified pdf file.workbooks - The workbook collection.options - Options for saving pdf file.public final void saveWorkbooksToPDF(java.lang.String fileName,
java.util.List<IWorkbook> workbooks)
fileName - The specified pdf file.workbooks - The workbook collection.public final void saveWorkbooksToPDF(java.lang.String fileName,
java.util.List<IWorkbook> workbooks,
PdfSaveOptions options)
fileName - The specified pdf file.workbooks - The workbook collection.options - Options for saving pdf file.public final void savePageInfosToPDF(java.io.OutputStream stream,
java.util.List<PageInfo> pages)
stream - The specified pdf file.pages - The page information collection.public final void savePageInfosToPDF(java.io.OutputStream stream,
java.util.List<PageInfo> pages,
PdfSaveOptions options)
stream - The specified pdf file.pages - The page information collection.options - Options for saving pdf file.public final void savePageInfosToPDF(java.lang.String fileName,
java.util.List<PageInfo> pages)
fileName - The specified pdf file.pages - The page information collection.public final void savePageInfosToPDF(java.lang.String fileName,
java.util.List<PageInfo> pages,
PdfSaveOptions options)
fileName - The specified pdf file.pages - The page information collection.options - Options for saving pdf file.public final java.util.List<PageInfo> paginate(java.util.List<IWorkbook> workbooks)
workbooks - The collection of workbooks.public final java.util.List<PageInfo> paginate(IWorkbook workbook)
workbook - The workbook object.public final java.util.List<PageInfo> paginate(IWorksheet worksheet)
worksheet - The worksheet object.public final java.util.List<PageInfo> paginate(IWorksheet worksheet, java.util.List<IRange> keepTogetherRanges, java.util.List<RepeatSetting> repeatSettings)
worksheet - The worksheet object.keepTogetherRanges - The collection of ranges that need to keep together.repeatSettings - The collection of repeat settings for a Range.public final PageContentInfo generatePageContentInfo(IRange printArea, Size availableSize, int rowStart, int columnStart, boolean rowHeaderVisible, boolean columnHeaderVisible)
printArea - The print area.availableSize - The size that excludes the margins.rowStart - The start row index which is used to calculate the RowEnd.columnStart - The start column index which is used to calculate the ColumnEnd.rowHeaderVisible - True if the row header is printed with this page.columnHeaderVisible - True if the column header is printed with this page.public final void updatePageNumberAndPageSettings(java.util.List<PageInfo> pages)
pages - The page collection.public final void updatePageNumberAndPageSettings(java.util.List<PageInfo> pages, int firstPageNumber, int pageCount)
pages - The page collection.firstPageNumber - The page number of the first page.pageCount - The total number of pages.public final void appendPage(PDDocument doc,
PageInfo pageInfo)
doc - The specified GcPdfDocument.pageInfo - The printed page info.public final void appendPage(PDDocument doc,
PageInfo pageInfo,
PdfSaveOptions options)
doc - The specified GcPdfDocument.pageInfo - The printed page info.options - Options for saving pdf file.public final void draw(PDDocument doc,
PDPage page,
java.util.List<PageInfo> pages,
int rows,
int columns)
page - The page in a GcPdfDocument.pages - The page collection.rows - The number of rows that these pages will be divided into.columns - The number of columns that these pages will be divided into.public final void draw(PDDocument doc,
PDPage page,
java.util.List<PageInfo> pages,
int rows,
int columns,
Order order)
page - The page in a GcPdfDocument.pages - The page collection.rows - The number of rows that these pages will be divided into.columns - The number of columns that these pages will be divided into.order - The direction that GcExcel uses to arrange the pages.public final void draw(PDDocument doc,
PDPage page,
java.util.List<PageInfo> pages,
int rows,
int columns,
Order order,
PdfSaveOptions options)
page - The page in a GcPdfDocument.pages - The page collection.rows - The number of rows that these pages will be divided into.columns - The number of columns that these pages will be divided into.order - The direction that GcExcel uses to arrange the pages.options - Options for saving pdf file.public final boolean hasPrintContent(IRange range)
range - The printed range of a page.public final Size getSize(PageContentInfo contentInfo)
contentInfo - The PageContentInfo object.public final Size getSize(IRange range)
range - The range object.public final WorkbookCache getCache(IWorkbook workbook)
public final WorksheetCache getCache(IWorksheet worksheet)
public final java.util.List<PageInfo> paginate(IRange printArea)
printArea - The area will be paginated.public final void draw(PDDocument doc,
PDPage page,
Point location,
IRange range)
page - The page in a GcPdfDocument.location - The location of the range data to be drawn.range - The print data range.public final void draw(PDDocument doc,
PDPage page,
Point location,
IRange range,
PdfSaveOptions options)
page - The page in a GcPdfDocument.location - The location of the range data to be drawn.range - The print data range.options - Options for saving pdf file.public final void draw(PDDocument doc,
PDPage page,
Rectangle rect,
IRange range)
page - The page in a GcPdfDocument.rect - The location and size of the range data to be drawn.range - The print data range.public final void draw(PDDocument doc,
PDPage page,
Rectangle rect,
IRange range,
PdfSaveOptions options)
page - The page in a GcPdfDocument.rect - The location and size of the range data to be drawn.range - The print data range.options - Options for saving pdf file.public final void draw(PDDocument doc,
PDPage page,
Rectangle rect,
PageContentInfo pageContent)
page - The page in a GcPdfDocument.rect - The location and size of the data to be drawn.pageContent - The printed page content info.public final void draw(PDDocument doc,
PDPage page,
Rectangle rect,
PageContentInfo pageContent,
PdfSaveOptions options)
page - The page in a GcPdfDocument.rect - The location and size of the data to be drawn.pageContent - The printed page content info.options - Options for saving pdf file.public final void draw(PDDocument doc,
PDPage page,
Rectangle rect,
PageInfo pageInfo)
page - The page in a GcPdfDocument.rect - The location and size of the data to be drawn.pageInfo - The printed page info.public final void draw(PDDocument doc,
PDPage page,
Rectangle rect,
PageInfo pageInfo,
PdfSaveOptions options)
page - The page in a GcPdfDocument.rect - The location and size of the data to be drawn.pageInfo - The printed page info.options - Options for saving pdf file.public final PageContentInfo generatePageContentInfo(IRange printArea, Size availableSize, int rowStart, int columnStart, boolean rowHeaderVisible, boolean columnHeaderVisible, double rowHeaderWidth, int titleRowStart, int titleRowEnd, int tailRowStart, int tailRowEnd, int titleColumnStart, int titleColumnEnd, int tailColumnStart, int tailColumnEnd, double zoomFactor, boolean ignoreRowPageBreaks)
printArea - The print area.availableSize - The size that excludes the margins.rowStart - The start row index which is used to calculate the RowEnd.columnStart - The start column index which is used to calculate the ColumnEnd.rowHeaderVisible - Weather The row header is printed.columnHeaderVisible - Weather The column header is printed.rowHeaderWidth - The width of the row header.titleRowStart - The start index of the rows which are printed at the top of the page.titleRowEnd - The end index of the rows which are printed at the top of the page.tailRowStart - The start index of the rows which are printed at the bottom of the page.tailRowEnd - The end index of the rows which are printed at the bottom of the page.titleColumnStart - The start index of the columns which are printed at the left of the page.titleColumnEnd - The end index of the columns which are printed at the left of the page.tailColumnStart - The start index of the columns which are printed at the right of the page.tailColumnEnd - The end index of the columns which are printed at the right of the page.zoomFactor - The value that represents a percentage by which GcExcel will scale the worksheet for printing.ignoreRowPageBreaks - Ignore the page breaks.public final java.util.List<IRange> getPrintAreas(IWorksheet worksheet)
worksheet - The worksheet object.public final PageSettings getPageSettings(IWorksheet worksheet, PageType type)
public java.util.List<java.lang.Integer> GetPaginationInfo(IWorksheet worksheet, PaginationOrientation orientation)
worksheet - The worksheet object.orientation - The orientation of pagination.public java.util.List<java.lang.Integer> GetPaginationInfo(IWorksheet worksheet, PaginationOrientation orientation, java.util.List<IRange> keepTogetherRanges, java.util.List<RepeatSetting> repeatSettings)
worksheet - The worksheet object.orientation - The orientation of pagination.keepTogetherRanges - The collection of ranges that need to keep together.repeatSettings - The collection of repeat settings for a Range.