Struct streampager::pager::Pager [−][src]
The main pager state.
Implementations
impl Pager
[src]
pub fn new_using_system_terminal() -> Result<Self>
[src]
Build a Pager
using the system terminal.
pub fn new_using_stdio() -> Result<Self>
[src]
Build a Pager
using the system stdio.
pub fn new_with_input_output(
input: &impl AsRawFd,
output: &impl AsRawFd
) -> Result<Self>
[src]
input: &impl AsRawFd,
output: &impl AsRawFd
) -> Result<Self>
Build a Pager
using the specified terminal input and output.
pub fn add_stream(
&mut self,
stream: impl Read + Send + 'static,
title: &str
) -> Result<FileIndex>
[src]
&mut self,
stream: impl Read + Send + 'static,
title: &str
) -> Result<FileIndex>
Add a stream to be paged.
pub fn add_error_stream(
&mut self,
stream: impl Read + Send + 'static,
title: &str
) -> Result<FileIndex>
[src]
&mut self,
stream: impl Read + Send + 'static,
title: &str
) -> Result<FileIndex>
Attach an error stream to the previously added output stream.
pub fn add_file(&mut self, filename: &OsStr) -> Result<FileIndex>
[src]
Attach a file from disk.
pub fn add_controlled_file(
&mut self,
controller: &Controller
) -> Result<FileIndex>
[src]
&mut self,
controller: &Controller
) -> Result<FileIndex>
Attach a controlled file.
pub fn add_subprocess<I, S>(
&mut self,
command: &OsStr,
args: I,
title: &str
) -> Result<(FileIndex, FileIndex)> where
I: IntoIterator<Item = S>,
S: AsRef<OsStr>,
[src]
&mut self,
command: &OsStr,
args: I,
title: &str
) -> Result<(FileIndex, FileIndex)> where
I: IntoIterator<Item = S>,
S: AsRef<OsStr>,
Attach the output and error streams from a subprocess.
Returns the file index for each stream.
pub fn set_progress_stream(&mut self, stream: impl Read + Send + 'static)
[src]
Set the progress stream.
pub fn set_interface_mode(&mut self, value: impl Into<InterfaceMode>)
[src]
Set when to use full screen mode. See InterfaceMode
for details.
pub fn set_scroll_past_eof(&mut self, value: bool)
[src]
Set whether scrolling can past end of file.
pub fn set_read_ahead_lines(&mut self, lines: usize)
[src]
Set how many lines to read ahead.
pub fn set_wrapping_mode(&mut self, value: impl Into<WrappingMode>)
[src]
Set default wrapping mode. See WrappingMode
for details.
pub fn set_keymap_name(&mut self, keymap: impl Into<String>)
[src]
Set keymap name.
pub fn set_keymap(&mut self, keymap: Keymap)
[src]
Set keymap.
pub fn action_sender(&self) -> ActionSender
[src]
Create an action sender which can be used to send Action
s to this pager.
pub fn run(self) -> Result<()>
[src]
Run Stream Pager.
Auto Trait Implementations
impl !RefUnwindSafe for Pager
impl Send for Pager
impl !Sync for Pager
impl Unpin for Pager
impl !UnwindSafe for Pager
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
pub fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
V: MultiLane<T>,