pub struct PrConfig {Show 25 fields
pub first_page: usize,
pub last_page: usize,
pub columns: usize,
pub across: bool,
pub show_control_chars: bool,
pub double_space: bool,
pub date_format: String,
pub expand_tabs: Option<(char, usize)>,
pub form_feed: bool,
pub header: Option<String>,
pub output_tabs: Option<(char, usize)>,
pub join_lines: bool,
pub page_length: usize,
pub merge: bool,
pub number_lines: Option<(char, usize)>,
pub first_line_number: usize,
pub indent: usize,
pub no_file_warnings: bool,
pub separator: Option<char>,
pub sep_string: Option<String>,
pub omit_header: bool,
pub omit_pagination: bool,
pub show_nonprinting: bool,
pub page_width: usize,
pub truncate_lines: bool,
}Expand description
Configuration for the pr command.
Fields§
§first_page: usizeFirst page to print (1-indexed).
last_page: usizeLast page to print (0 = no limit).
columns: usizeNumber of columns.
across: boolPrint columns across rather than down.
show_control_chars: boolShow control characters in hat notation (^X).
double_space: boolDouble-space output.
date_format: StringDate format string for header.
expand_tabs: Option<(char, usize)>Expand input tabs to spaces (char, width).
form_feed: boolUse form feeds instead of newlines for page breaks.
header: Option<String>Custom header string (replaces filename).
output_tabs: Option<(char, usize)>Replace spaces with tabs in output (char, width).
join_lines: boolJoin lines (do not truncate lines when using columns).
page_length: usizePage length in lines (including header/footer).
merge: boolMerge multiple files side by side.
number_lines: Option<(char, usize)>Number lines: (separator_char, digits).
first_line_number: usizeFirst line number.
indent: usizeIndent (offset) each line by this many spaces.
no_file_warnings: boolSuppress file-not-found warnings.
separator: Option<char>Column separator character.
sep_string: Option<String>Column separator string.
omit_header: boolOmit header and trailer.
omit_pagination: boolOmit header, trailer, and form feeds.
show_nonprinting: boolShow nonprinting characters.
page_width: usizePage width.
truncate_lines: boolTruncate lines to page width (-W).
Trait Implementations§
Auto Trait Implementations§
impl Freeze for PrConfig
impl RefUnwindSafe for PrConfig
impl Send for PrConfig
impl Sync for PrConfig
impl Unpin for PrConfig
impl UnsafeUnpin for PrConfig
impl UnwindSafe for PrConfig
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
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>
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>
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