|
| Watermark (const PDFDoc &document, const wchar_t *text, const WatermarkTextProperties &properties, const WatermarkSettings &settings) |
| Constructor, from specified text content. More...
|
|
| Watermark (const foxit::pdf::PDFDoc &document, const foxit::common::Bitmap &bitmap, const foxit::pdf::WatermarkSettings &settings) |
| Constructor, from a specified bitmap. More...
|
|
| Watermark (const foxit::pdf::PDFDoc &document, const foxit::common::Image &image, int frame_index, const foxit::pdf::WatermarkSettings &settings) |
| Constructor, from a specified image. More...
|
|
| Watermark (const foxit::pdf::PDFDoc &document, const foxit::pdf::PDFPage &page, const foxit::pdf::WatermarkSettings &settings) |
| Constructor, from a specified page. More...
|
|
| Watermark (const Watermark &other) |
| Constructor, with another Watermark object. More...
|
|
| ~Watermark () |
| Destructor.
|
|
float | GetHeight () const |
| Get the original height of current watermark. More...
|
|
float | GetWidth () const |
| Get the original width of current watermark. More...
|
|
bool | InsertToPage (PDFPage page) |
| Insert current watermark into a PDF page. More...
|
|
bool | IsEmpty () const |
| Check whether current object is empty or not. More...
|
|
bool | operator!= (const Watermark &other) const |
| Not equal operator. More...
|
|
Watermark & | operator= (const Watermark &other) |
| Assign operator. More...
|
|
bool | operator== (const Watermark &other) const |
| Equal operator. More...
|
|
FS_HANDLE | Handle () const |
| Get the handle of current object. More...
|
|
This class is mainly used to construct a watermark with specified parameters, and then insert it to PDF page. The watermark object can be constructed from text, bitmap or image, and PDF page.
bool foxit::pdf::Watermark::InsertToPage |
( |
PDFPage |
page | ) |
|
Insert current watermark into a PDF page.
If current watermark is treated as page content (which is specified by WatermarkSettings::flags when current watermark is constructed), Foxit PDF SDK will generate content for the input PDF page by default after the watermark is inserted successfully. In this case , if user wants to render the PDF page correctly after this function has been called successfully, user is recommended to call function pdf::PDFPage::StartParse with parameter is_reparse true before rendering; otherwise, the page content may not be rendered as expected.
- Parameters
-
[in] | page | A PDF page, to which current watermark would be inserted. This page should belong to the same document as current watermark belongs to. And the page should have been already parsed. |
- Returns
- true means success, while false means failure.