Struct rstk::notebook::TkNotebook
source · pub struct TkNotebook {
pub id: String,
}
Expand description
Refers to a notebook widget
Fields§
§id: String
Implementations§
source§impl TkNotebook
impl TkNotebook
sourcepub fn add(&self, widget: &impl TkWidget, title: &str)
pub fn add(&self, widget: &impl TkWidget, title: &str)
TODO: use builder pattern to support images+text
Trait Implementations§
source§impl Clone for TkNotebook
impl Clone for TkNotebook
source§fn clone(&self) -> TkNotebook
fn clone(&self) -> TkNotebook
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 TkNotebook
impl Debug for TkNotebook
source§impl PartialEq for TkNotebook
impl PartialEq for TkNotebook
source§fn eq(&self, other: &TkNotebook) -> bool
fn eq(&self, other: &TkNotebook) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.source§impl TkGridLayout for TkNotebook
impl TkGridLayout for TkNotebook
source§fn grid(&self) -> GridLayout
fn grid(&self) -> GridLayout
Creates a GridLayout instance for placing this widget within its parent.
source§fn grid_configure(&self, option: &str, value: &str)
fn grid_configure(&self, option: &str, value: &str)
source§fn grid_forget(&self)
fn grid_forget(&self)
Removes this widget from layout.
source§impl TkPackLayout for TkNotebook
impl TkPackLayout for TkNotebook
source§fn pack(&self) -> PackLayout
fn pack(&self) -> PackLayout
Creates a PackLayout instance for placing this widget within its parent
source§fn pack_configure(&self, option: &str, value: &str)
fn pack_configure(&self, option: &str, value: &str)
Sets properties for widget layout
source§fn pack_forget(&self)
fn pack_forget(&self)
Removes this widget from layout
source§impl TkWidget for TkNotebook
impl TkWidget for TkNotebook
source§fn bind(&self, pattern: &str, command: impl Fn(TkEvent) + Send + 'static)
fn bind(&self, pattern: &str, command: impl Fn(TkEvent) + Send + 'static)
Binds a command to this widget to call on given event pattern
source§fn cget(&self, option: &str) -> String
fn cget(&self, option: &str) -> String
Retrieve the value of a configuration option
as a string. Read more
source§fn configure(&self, option: &str, value: &str)
fn configure(&self, option: &str, value: &str)
Used to change properties of a widget.
This function can be used to directly configure
the widget using an option-value string pair: Read more
source§fn position_x(&self) -> u64
fn position_x(&self) -> u64
Returns the widget x position in pixels, within its parent.
source§fn position_y(&self) -> u64
fn position_y(&self) -> u64
Returns the widget y position in pixels, within its parent.
source§fn widget_height(&self) -> u64
fn widget_height(&self) -> u64
Returns the widget height in pixels.
source§fn widget_width(&self) -> u64
fn widget_width(&self) -> u64
Returns the widget width in pixels.
source§fn mouse_position(&self) -> (i64, i64)
fn mouse_position(&self) -> (i64, i64)
Returns the position of the mouse on screen of widget as (x,y).
source§fn screen_height(&self) -> u64
fn screen_height(&self) -> u64
Height of screen of widget in pixels.
source§fn screen_height_mm(&self) -> u64
fn screen_height_mm(&self) -> u64
Height of screen of widget in millimetres.
source§fn screen_width(&self) -> u64
fn screen_width(&self) -> u64
Width of screen of widget in pixels.
source§fn screen_width_mm(&self) -> u64
fn screen_width_mm(&self) -> u64
Width of screen of widget in millimetres.
impl StructuralPartialEq for TkNotebook
Auto Trait Implementations§
impl RefUnwindSafe for TkNotebook
impl Send for TkNotebook
impl Sync for TkNotebook
impl Unpin for TkNotebook
impl UnwindSafe for TkNotebook
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