pub trait Column<T> {
// Required methods
fn width(&self) -> u16;
fn render(&self, item: &T) -> (String, Style);
// Provided methods
fn id(&self) -> &'static str { ... }
fn default_name(&self) -> &'static str { ... }
fn name(&self) -> &str { ... }
fn fit_content(&self) -> bool { ... }
}Required Methods§
Provided Methods§
fn id(&self) -> &'static str
fn default_name(&self) -> &'static str
fn name(&self) -> &str
Sourcefn fit_content(&self) -> bool
fn fit_content(&self) -> bool
Opt into compact sizing based on the rendered rows. width() caps data width, including the two-cell prefix; the full header always takes priority. Other columns retain the existing widest-column auto-fill behavior.
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".