pub struct GutterConfig {
pub enabled: bool,
pub width: f32,
pub line_numbers: bool,
pub fold_markers: bool,
}Expand description
Gutter controls for code-oriented editor frames.
Width is logical pixels. Viewport construction treats disabled, zero, or negative width as no gutter and clamps positive width to content width.
§Examples
use ailloli_ui_editor::GutterConfig;
let gutter = GutterConfig::default();
assert_eq!(gutter.width, 48.0);
assert!(gutter.enabled && gutter.line_numbers && gutter.fold_markers);Fields§
§enabled: boolWhether any gutter space is reserved.
width: f32Requested gutter width in logical pixels.
line_numbers: boolWhether line-number items are emitted.
fold_markers: boolWhether fold marker/guide items are emitted.
Trait Implementations§
Source§impl Clone for GutterConfig
impl Clone for GutterConfig
Source§fn clone(&self) -> GutterConfig
fn clone(&self) -> GutterConfig
Returns a copy 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 GutterConfig
impl Debug for GutterConfig
Source§impl Default for GutterConfig
Supplies an enabled 48-logical-pixel gutter with numbers and folds.
impl Default for GutterConfig
Supplies an enabled 48-logical-pixel gutter with numbers and folds.
Source§impl PartialEq for GutterConfig
impl PartialEq for GutterConfig
impl Copy for GutterConfig
impl StructuralPartialEq for GutterConfig
Auto Trait Implementations§
impl Freeze for GutterConfig
impl RefUnwindSafe for GutterConfig
impl Send for GutterConfig
impl Sync for GutterConfig
impl Unpin for GutterConfig
impl UnwindSafe for GutterConfig
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