pub struct FrameCellDecorator {
inner: bool,
outer: bool,
cont: bool,
line_style: LineStyle,
num_columns: usize,
num_rows: usize,
last_row: Option<usize>,
}Expand description
A cell decorator that draws frames around table cells.
This decorator draws frames around the cells of a TableLayout. You can configure whether
inner, outer and continuation borders are drawn. A continuation border is a border between a
cell and the page margin that occurs if a cell has to be wrapped to a new page.
Fields§
§inner: bool§outer: bool§cont: bool§line_style: LineStyle§num_columns: usize§num_rows: usize§last_row: Option<usize>Implementations§
Source§impl FrameCellDecorator
impl FrameCellDecorator
Sourcepub fn new(inner: bool, outer: bool, cont: bool) -> FrameCellDecorator
pub fn new(inner: bool, outer: bool, cont: bool) -> FrameCellDecorator
Creates a new frame cell decorator with the given settings for inner, outer and continuation borders.
Sourcepub fn with_line_style(
inner: bool,
outer: bool,
cont: bool,
line_style: impl Into<LineStyle>,
) -> FrameCellDecorator
pub fn with_line_style( inner: bool, outer: bool, cont: bool, line_style: impl Into<LineStyle>, ) -> FrameCellDecorator
Creates a new frame cell decorator with the given border settings, as well as a line style.
fn print_left(&self, column: usize) -> bool
fn print_right(&self, column: usize) -> bool
fn print_top(&self, row: usize) -> bool
fn print_bottom(&self, row: usize, has_more: bool) -> bool
Trait Implementations§
Source§impl CellDecorator for FrameCellDecorator
impl CellDecorator for FrameCellDecorator
Source§impl Clone for FrameCellDecorator
impl Clone for FrameCellDecorator
Source§fn clone(&self) -> FrameCellDecorator
fn clone(&self) -> FrameCellDecorator
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for FrameCellDecorator
impl Debug for FrameCellDecorator
Source§impl Default for FrameCellDecorator
impl Default for FrameCellDecorator
Source§fn default() -> FrameCellDecorator
fn default() -> FrameCellDecorator
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for FrameCellDecorator
impl RefUnwindSafe for FrameCellDecorator
impl Send for FrameCellDecorator
impl Sync for FrameCellDecorator
impl Unpin for FrameCellDecorator
impl UnwindSafe for FrameCellDecorator
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more§impl<T> Pointable for T
impl<T> Pointable for T
§impl<U, T> ToOwnedObj<U> for Twhere
U: FromObjRef<T>,
impl<U, T> ToOwnedObj<U> for Twhere
U: FromObjRef<T>,
§fn to_owned_obj(&self, data: FontData<'_>) -> U
fn to_owned_obj(&self, data: FontData<'_>) -> U
Convert this type into
T, using the provided data to resolve any offsets.