pub struct NullDevice { /* private fields */ }Expand description
A null rendering device that discards all output.
Implementations§
Trait Implementations§
Source§impl OutputDevice for NullDevice
impl OutputDevice for NullDevice
Source§fn fill_path(&mut self, _path: &PsPath, _params: &FillParams)
fn fill_path(&mut self, _path: &PsPath, _params: &FillParams)
Fill a path with the given color.
Source§fn stroke_path(&mut self, _path: &PsPath, _params: &StrokeParams)
fn stroke_path(&mut self, _path: &PsPath, _params: &StrokeParams)
Stroke a path with the given parameters.
Source§fn clip_path(&mut self, _path: &PsPath, _params: &ClipParams)
fn clip_path(&mut self, _path: &PsPath, _params: &ClipParams)
Intersect the current clip region with the given path.
Source§fn erase_page(&mut self)
fn erase_page(&mut self)
Erase the page (fill with white).
Source§fn show_page(&mut self, _output_path: &str) -> Result<(), String>
fn show_page(&mut self, _output_path: &str) -> Result<(), String>
Output the current page (e.g., save PNG) and return Ok/Err.
Source§fn draw_image(&mut self, _sample_data: &[u8], _params: &ImageParams)
fn draw_image(&mut self, _sample_data: &[u8], _params: &ImageParams)
Draw an image from raw sample data.
Source§fn paint_axial_shading(&mut self, _params: &AxialShadingParams)
fn paint_axial_shading(&mut self, _params: &AxialShadingParams)
Paint an axial (linear) gradient shading.
Source§fn paint_radial_shading(&mut self, _params: &RadialShadingParams)
fn paint_radial_shading(&mut self, _params: &RadialShadingParams)
Paint a radial gradient shading.
Source§fn paint_mesh_shading(&mut self, _params: &MeshShadingParams)
fn paint_mesh_shading(&mut self, _params: &MeshShadingParams)
Paint a Gouraud-shaded triangle mesh.
Source§fn paint_patch_shading(&mut self, _params: &PatchShadingParams)
fn paint_patch_shading(&mut self, _params: &PatchShadingParams)
Paint a Coons/tensor-product patch mesh.
Source§fn paint_pattern_fill(&mut self, _params: &PatternFillParams)
fn paint_pattern_fill(&mut self, _params: &PatternFillParams)
Paint a tiled pattern fill.
Source§fn set_trim_box(&mut self, _llx: f64, _lly: f64, _urx: f64, _ury: f64)
fn set_trim_box(&mut self, _llx: f64, _lly: f64, _urx: f64, _ury: f64)
Set the trim box for the next page (PDF points, lower-left origin).
Only meaningful for PDF output; other devices ignore this.
Source§fn replay_and_show(
&mut self,
list: DisplayList,
output_path: &str,
) -> Result<(), String>
fn replay_and_show( &mut self, list: DisplayList, output_path: &str, ) -> Result<(), String>
Replay a display list and write output in one step.
Source§fn finish(&mut self) -> Result<(), String>
fn finish(&mut self) -> Result<(), String>
Wait for any pending background render to complete.
Auto Trait Implementations§
impl Freeze for NullDevice
impl RefUnwindSafe for NullDevice
impl Send for NullDevice
impl Sync for NullDevice
impl Unpin for NullDevice
impl UnsafeUnpin for NullDevice
impl UnwindSafe for NullDevice
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more