Frameworks
React Native
Flutter
Version 10
Version 9
Version 8
Version 7
Version 6
Version 5
PDFViewCtrl
has three special color modes: night mode, inverted color mode, and custom color mode. In night mode, colors are adjusted to improve reading at night, in inverted color mode, all colors are inverted, and in custom color mode, you can set a custom color for text and the background color.
Color modes from left to right: normal color mode, inverted color mode, night mode and custom color mode.
To set the color mode:
Color mode | Constant value |
---|---|
Normal color mode | |
Night mode | |
Inverted color mode | |
Custom color mode |
setColorPostProcessMode(_ mode: PTColorPostProcessMode)
.PDFViewCtrl
background color for the best visual result. You can set background color by calling setBackgroundColor(_ r: UInt8, g: UInt8, b: UInt8, a: UInt8)
.For example, set the background color to black for night mode:postprocess_gradient_map
, call setColorPostProcessColors(_ white_color: UIColor!, black_color: UIColor!)
to set the white and black points. For example, for a sepia effect, try:PDFViewCtrl
to redraw the contents:Sample result when using postprocess_gradient_map
and a light/dark brown for the white/black color:Did you find this helpful?
Trial setup questions?
Ask experts on DiscordNeed other help?
Contact SupportPricing or product questions?
Contact Sales