VectorSearchCriteria class
Leave feedback
On this page
Represents criteria allowing filtering by watermark color.
Learn more:
The VectorSearchCriteria type exposes the following members:
| Constructor | Description |
|---|---|
| init | Initializes a new VectorSearchCriteria instance. |
| Method | Description |
|---|---|
| and_ | Combines this SearchCriteria with other criteria using the logical AND operator. (inherited from SearchCriteria) |
| and_search_criteria | (inherited from SearchCriteria) |
| not_ | Negates this SearchCriteria. (inherited from SearchCriteria) |
| or_ | Combines this SearchCriteria with other criteria using the logical OR operator. (inherited from SearchCriteria) |
| or_search_criteria | (inherited from SearchCriteria) |
| Property | Description |
|---|---|
| vector_color_range | The range of colors used to filter vector watermarks by foreground color. |
from groupdocs.watermark import Watermarker
from groupdocs.watermark.search.search_criteria import VectorSearchCriteria, ColorRange
from groupdocs.watermark.watermarks import Color
with Watermarker("./document.pdf") as watermarker:
search_criteria = VectorSearchCriteria()
watermark_color = Color.from_argb(255, 169, 170, 174) # #a9aaae
color_range = ColorRange(watermark_color)
color_range.min_brightness = 0.1
color_range.max_brightness = 0.7
search_criteria.vector_color_range = color_range
possible_watermarks = watermarker.search(search_criteria)
possible_watermarks.clear()
watermarker.save("./output.pdf")
Was this page helpful?
Any additional feedback you'd like to share with us?
Please tell us how we can improve this page.
Thank you for your feedback!
We value your opinion. Your feedback will help us improve our documentation.