pub struct Buffer { /* private fields */ }
Expand description
GLib type: GObject with reference counted clone semantics.
Implementations§
Source§impl Buffer
impl Buffer
pub const NONE: Option<&'static Buffer> = None
pub fn new(table: Option<&TextTagTable>) -> Buffer
pub fn with_language(language: &Language) -> Buffer
Sourcepub fn builder() -> BufferBuilder
pub fn builder() -> BufferBuilder
Creates a new builder-pattern struct instance to construct Buffer
objects.
This method returns an instance of BufferBuilder
which can be used to create Buffer
objects.
Trait Implementations§
Source§impl HasParamSpec for Buffer
impl HasParamSpec for Buffer
Source§impl<T: BufferImpl> IsSubclassable<T> for Buffer
impl<T: BufferImpl> IsSubclassable<T> for Buffer
Source§fn class_init(class: &mut Class<Self>)
fn class_init(class: &mut Class<Self>)
Override the virtual methods of this class for the given subclass and do other class
initialization. Read more
Source§fn instance_init(instance: &mut InitializingObject<T>)
fn instance_init(instance: &mut InitializingObject<T>)
Instance specific initialization. Read more
Source§impl Ord for Buffer
impl Ord for Buffer
Source§fn cmp(&self, other: &Self) -> Ordering
fn cmp(&self, other: &Self) -> Ordering
Comparison for two GObjects.
Compares the memory addresses of the provided objects.
1.21.0 · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
Source§impl ParentClassIs for Buffer
impl ParentClassIs for Buffer
type Parent = TextBuffer
Source§impl<OT: ObjectType> PartialEq<OT> for Buffer
impl<OT: ObjectType> PartialEq<OT> for Buffer
Source§impl<OT: ObjectType> PartialOrd<OT> for Buffer
impl<OT: ObjectType> PartialOrd<OT> for Buffer
Source§impl StaticType for Buffer
impl StaticType for Buffer
Source§fn static_type() -> Type
fn static_type() -> Type
Returns the type identifier of
Self
.impl Eq for Buffer
impl IsA<TextBuffer> for Buffer
Auto Trait Implementations§
impl Freeze for Buffer
impl RefUnwindSafe for Buffer
impl !Send for Buffer
impl !Sync for Buffer
impl Unpin for Buffer
impl UnwindSafe for Buffer
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
Source§impl<O> BufferExt for O
impl<O> BufferExt for O
fn change_case( &self, case_type: ChangeCaseType, start: &mut TextIter, end: &mut TextIter, )
fn create_source_mark( &self, name: Option<&str>, category: &str, where_: &TextIter, ) -> Mark
fn ensure_highlight(&self, start: &TextIter, end: &TextIter)
fn context_classes_at_iter(&self, iter: &TextIter) -> Vec<GString>
fn is_highlight_matching_brackets(&self) -> bool
fn is_highlight_syntax(&self) -> bool
fn is_implicit_trailing_newline(&self) -> bool
fn language(&self) -> Option<Language>
fn is_loading(&self) -> bool
Source§fn markup(&self, start: &mut TextIter, end: &mut TextIter) -> GString
fn markup(&self, start: &mut TextIter, end: &mut TextIter) -> GString
Available on crate feature
v5_18
only.fn source_marks_at_iter( &self, iter: &mut TextIter, category: Option<&str>, ) -> Vec<Mark>
fn source_marks_at_line(&self, line: i32, category: Option<&str>) -> Vec<Mark>
fn style_scheme(&self) -> Option<StyleScheme>
fn iter_has_context_class(&self, iter: &TextIter, context_class: &str) -> bool
fn join_lines(&self, start: &mut TextIter, end: &mut TextIter)
fn remove_source_marks( &self, start: &TextIter, end: &TextIter, category: Option<&str>, )
fn set_highlight_matching_brackets(&self, highlight: bool)
fn set_highlight_syntax(&self, highlight: bool)
fn set_implicit_trailing_newline(&self, implicit_trailing_newline: bool)
fn set_language(&self, language: Option<&Language>)
fn set_style_scheme(&self, scheme: Option<&StyleScheme>)
fn sort_lines( &self, start: &mut TextIter, end: &mut TextIter, flags: SortFlags, column: i32, )
fn connect_bracket_matched<F: Fn(&Self, Option<&TextIter>, BracketMatchType) + 'static>( &self, f: F, ) -> SignalHandlerId
fn connect_cursor_moved<F: Fn(&Self) + 'static>(&self, f: F) -> SignalHandlerId
fn connect_highlight_updated<F: Fn(&Self, &TextIter, &TextIter) + 'static>( &self, f: F, ) -> SignalHandlerId
fn connect_source_mark_updated<F: Fn(&Self, &TextMark) + 'static>( &self, f: F, ) -> SignalHandlerId
fn connect_highlight_matching_brackets_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId
fn connect_highlight_syntax_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId
fn connect_implicit_trailing_newline_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId
fn connect_language_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId
Source§fn connect_loading_notify<F: Fn(&Self) + 'static>(
&self,
f: F,
) -> SignalHandlerId
fn connect_loading_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId
Available on crate feature
v5_10
only.fn connect_style_scheme_notify<F: Fn(&Self) + 'static>( &self, f: F, ) -> SignalHandlerId
Source§impl<T> Cast for Twhere
T: ObjectType,
impl<T> Cast for Twhere
T: ObjectType,
Source§fn upcast<T>(self) -> Twhere
T: ObjectType,
Self: IsA<T>,
fn upcast<T>(self) -> Twhere
T: ObjectType,
Self: IsA<T>,
Upcasts an object to a superclass or interface
T
. Read moreSource§fn upcast_ref<T>(&self) -> &Twhere
T: ObjectType,
Self: IsA<T>,
fn upcast_ref<T>(&self) -> &Twhere
T: ObjectType,
Self: IsA<T>,
Upcasts an object to a reference of its superclass or interface
T
. Read moreSource§fn downcast<T>(self) -> Result<T, Self>where
T: ObjectType,
Self: MayDowncastTo<T>,
fn downcast<T>(self) -> Result<T, Self>where
T: ObjectType,
Self: MayDowncastTo<T>,
Tries to downcast to a subclass or interface implementor
T
. Read moreSource§fn downcast_ref<T>(&self) -> Option<&T>where
T: ObjectType,
Self: MayDowncastTo<T>,
fn downcast_ref<T>(&self) -> Option<&T>where
T: ObjectType,
Self: MayDowncastTo<T>,
Tries to downcast to a reference of its subclass or interface implementor
T
. Read moreSource§fn dynamic_cast<T>(self) -> Result<T, Self>where
T: ObjectType,
fn dynamic_cast<T>(self) -> Result<T, Self>where
T: ObjectType,
Tries to cast to an object of type
T
. This handles upcasting, downcasting
and casting between interface and interface implementors. All checks are performed at
runtime, while upcast
will do many checks at compile-time already. downcast
will
perform the same checks at runtime as dynamic_cast
, but will also ensure some amount of
compile-time safety. Read moreSource§fn dynamic_cast_ref<T>(&self) -> Option<&T>where
T: ObjectType,
fn dynamic_cast_ref<T>(&self) -> Option<&T>where
T: ObjectType,
Tries to cast to reference to an object of type
T
. This handles upcasting, downcasting
and casting between interface and interface implementors. All checks are performed at
runtime, while downcast
and upcast
will do many checks at compile-time already. Read moreSource§unsafe fn unsafe_cast<T>(self) -> Twhere
T: ObjectType,
unsafe fn unsafe_cast<T>(self) -> Twhere
T: ObjectType,
Casts to
T
unconditionally. Read moreSource§unsafe fn unsafe_cast_ref<T>(&self) -> &Twhere
T: ObjectType,
unsafe fn unsafe_cast_ref<T>(&self) -> &Twhere
T: ObjectType,
Casts to
&T
unconditionally. Read moreSource§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> FromGlibContainerAsVec<<T as GlibPtrDefault>::GlibType, *const GList> for Twhere
T: GlibPtrDefault + FromGlibPtrNone<<T as GlibPtrDefault>::GlibType> + FromGlibPtrFull<<T as GlibPtrDefault>::GlibType>,
impl<T> FromGlibContainerAsVec<<T as GlibPtrDefault>::GlibType, *const GList> for Twhere
T: GlibPtrDefault + FromGlibPtrNone<<T as GlibPtrDefault>::GlibType> + FromGlibPtrFull<<T as GlibPtrDefault>::GlibType>,
Source§impl<T> FromGlibContainerAsVec<<T as GlibPtrDefault>::GlibType, *const GPtrArray> for Twhere
T: GlibPtrDefault + FromGlibPtrNone<<T as GlibPtrDefault>::GlibType> + FromGlibPtrFull<<T as GlibPtrDefault>::GlibType>,
impl<T> FromGlibContainerAsVec<<T as GlibPtrDefault>::GlibType, *const GPtrArray> for Twhere
T: GlibPtrDefault + FromGlibPtrNone<<T as GlibPtrDefault>::GlibType> + FromGlibPtrFull<<T as GlibPtrDefault>::GlibType>,
Source§impl<T> FromGlibContainerAsVec<<T as GlibPtrDefault>::GlibType, *const GSList> for Twhere
T: GlibPtrDefault + FromGlibPtrNone<<T as GlibPtrDefault>::GlibType> + FromGlibPtrFull<<T as GlibPtrDefault>::GlibType>,
impl<T> FromGlibContainerAsVec<<T as GlibPtrDefault>::GlibType, *const GSList> for Twhere
T: GlibPtrDefault + FromGlibPtrNone<<T as GlibPtrDefault>::GlibType> + FromGlibPtrFull<<T as GlibPtrDefault>::GlibType>,
Source§impl<T> FromGlibContainerAsVec<<T as GlibPtrDefault>::GlibType, *mut GList> for Twhere
T: GlibPtrDefault + FromGlibPtrNone<<T as GlibPtrDefault>::GlibType> + FromGlibPtrFull<<T as GlibPtrDefault>::GlibType>,
impl<T> FromGlibContainerAsVec<<T as GlibPtrDefault>::GlibType, *mut GList> for Twhere
T: GlibPtrDefault + FromGlibPtrNone<<T as GlibPtrDefault>::GlibType> + FromGlibPtrFull<<T as GlibPtrDefault>::GlibType>,
Source§impl<T> FromGlibContainerAsVec<<T as GlibPtrDefault>::GlibType, *mut GPtrArray> for Twhere
T: GlibPtrDefault + FromGlibPtrNone<<T as GlibPtrDefault>::GlibType> + FromGlibPtrFull<<T as GlibPtrDefault>::GlibType>,
impl<T> FromGlibContainerAsVec<<T as GlibPtrDefault>::GlibType, *mut GPtrArray> for Twhere
T: GlibPtrDefault + FromGlibPtrNone<<T as GlibPtrDefault>::GlibType> + FromGlibPtrFull<<T as GlibPtrDefault>::GlibType>,
Source§impl<T> FromGlibContainerAsVec<<T as GlibPtrDefault>::GlibType, *mut GSList> for Twhere
T: GlibPtrDefault + FromGlibPtrNone<<T as GlibPtrDefault>::GlibType> + FromGlibPtrFull<<T as GlibPtrDefault>::GlibType>,
impl<T> FromGlibContainerAsVec<<T as GlibPtrDefault>::GlibType, *mut GSList> for Twhere
T: GlibPtrDefault + FromGlibPtrNone<<T as GlibPtrDefault>::GlibType> + FromGlibPtrFull<<T as GlibPtrDefault>::GlibType>,
Source§impl<T> FromGlibPtrArrayContainerAsVec<<T as GlibPtrDefault>::GlibType, *const GList> for Twhere
T: GlibPtrDefault + FromGlibPtrNone<<T as GlibPtrDefault>::GlibType> + FromGlibPtrFull<<T as GlibPtrDefault>::GlibType>,
impl<T> FromGlibPtrArrayContainerAsVec<<T as GlibPtrDefault>::GlibType, *const GList> for Twhere
T: GlibPtrDefault + FromGlibPtrNone<<T as GlibPtrDefault>::GlibType> + FromGlibPtrFull<<T as GlibPtrDefault>::GlibType>,
Source§impl<T> FromGlibPtrArrayContainerAsVec<<T as GlibPtrDefault>::GlibType, *const GPtrArray> for Twhere
T: GlibPtrDefault + FromGlibPtrNone<<T as GlibPtrDefault>::GlibType> + FromGlibPtrFull<<T as GlibPtrDefault>::GlibType>,
impl<T> FromGlibPtrArrayContainerAsVec<<T as GlibPtrDefault>::GlibType, *const GPtrArray> for Twhere
T: GlibPtrDefault + FromGlibPtrNone<<T as GlibPtrDefault>::GlibType> + FromGlibPtrFull<<T as GlibPtrDefault>::GlibType>,
Source§impl<T> FromGlibPtrArrayContainerAsVec<<T as GlibPtrDefault>::GlibType, *const GSList> for Twhere
T: GlibPtrDefault + FromGlibPtrNone<<T as GlibPtrDefault>::GlibType> + FromGlibPtrFull<<T as GlibPtrDefault>::GlibType>,
impl<T> FromGlibPtrArrayContainerAsVec<<T as GlibPtrDefault>::GlibType, *const GSList> for Twhere
T: GlibPtrDefault + FromGlibPtrNone<<T as GlibPtrDefault>::GlibType> + FromGlibPtrFull<<T as GlibPtrDefault>::GlibType>,
Source§impl<T> FromGlibPtrArrayContainerAsVec<<T as GlibPtrDefault>::GlibType, *mut GList> for Twhere
T: GlibPtrDefault + FromGlibPtrNone<<T as GlibPtrDefault>::GlibType> + FromGlibPtrFull<<T as GlibPtrDefault>::GlibType>,
impl<T> FromGlibPtrArrayContainerAsVec<<T as GlibPtrDefault>::GlibType, *mut GList> for Twhere
T: GlibPtrDefault + FromGlibPtrNone<<T as GlibPtrDefault>::GlibType> + FromGlibPtrFull<<T as GlibPtrDefault>::GlibType>,
Source§impl<T> FromGlibPtrArrayContainerAsVec<<T as GlibPtrDefault>::GlibType, *mut GPtrArray> for Twhere
T: GlibPtrDefault + FromGlibPtrNone<<T as GlibPtrDefault>::GlibType> + FromGlibPtrFull<<T as GlibPtrDefault>::GlibType>,
impl<T> FromGlibPtrArrayContainerAsVec<<T as GlibPtrDefault>::GlibType, *mut GPtrArray> for Twhere
T: GlibPtrDefault + FromGlibPtrNone<<T as GlibPtrDefault>::GlibType> + FromGlibPtrFull<<T as GlibPtrDefault>::GlibType>,
Source§impl<T> FromGlibPtrArrayContainerAsVec<<T as GlibPtrDefault>::GlibType, *mut GSList> for Twhere
T: GlibPtrDefault + FromGlibPtrNone<<T as GlibPtrDefault>::GlibType> + FromGlibPtrFull<<T as GlibPtrDefault>::GlibType>,
impl<T> FromGlibPtrArrayContainerAsVec<<T as GlibPtrDefault>::GlibType, *mut GSList> for Twhere
T: GlibPtrDefault + FromGlibPtrNone<<T as GlibPtrDefault>::GlibType> + FromGlibPtrFull<<T as GlibPtrDefault>::GlibType>,
Source§impl<O> GObjectPropertyExpressionExt for O
impl<O> GObjectPropertyExpressionExt for O
Source§fn property_expression(&self, property_name: &str) -> PropertyExpression
fn property_expression(&self, property_name: &str) -> PropertyExpression
Create an expression looking up an object’s property.
Source§fn property_expression_weak(&self, property_name: &str) -> PropertyExpression
fn property_expression_weak(&self, property_name: &str) -> PropertyExpression
Create an expression looking up an object’s property with a weak
reference.
Source§fn this_expression(property_name: &str) -> PropertyExpression
fn this_expression(property_name: &str) -> PropertyExpression
Create an expression looking up a property in the bound
this
object.Source§impl<T> IntoClosureReturnValue for T
impl<T> IntoClosureReturnValue for T
fn into_closure_return_value(self) -> Option<Value>
Source§impl<U> IsSubclassableExt for Uwhere
U: IsClass + ParentClassIs,
impl<U> IsSubclassableExt for Uwhere
U: IsClass + ParentClassIs,
fn parent_class_init<T>(class: &mut Class<U>)
fn parent_instance_init<T>(instance: &mut InitializingObject<T>)
Source§impl<T> ObjectExt for Twhere
T: ObjectType,
impl<T> ObjectExt for Twhere
T: ObjectType,
Source§fn is<U>(&self) -> boolwhere
U: StaticType,
fn is<U>(&self) -> boolwhere
U: StaticType,
Returns
true
if the object is an instance of (can be cast to) T
.Source§fn object_class(&self) -> &Class<Object>
fn object_class(&self) -> &Class<Object>
Returns the
ObjectClass
of the object. Read moreSource§fn class_of<U>(&self) -> Option<&Class<U>>where
U: IsClass,
fn class_of<U>(&self) -> Option<&Class<U>>where
U: IsClass,
Returns the class of the object in the given type
T
. Read moreSource§fn interface<U>(&self) -> Option<InterfaceRef<'_, U>>where
U: IsInterface,
fn interface<U>(&self) -> Option<InterfaceRef<'_, U>>where
U: IsInterface,
Returns the interface
T
of the object. Read moreSource§fn set_property_from_value(&self, property_name: &str, value: &Value)
fn set_property_from_value(&self, property_name: &str, value: &Value)
Source§fn set_properties(&self, property_values: &[(&str, &dyn ToValue)])
fn set_properties(&self, property_values: &[(&str, &dyn ToValue)])
Sets multiple properties of the object at once. Read more
Source§fn set_properties_from_value(&self, property_values: &[(&str, Value)])
fn set_properties_from_value(&self, property_values: &[(&str, Value)])
Sets multiple properties of the object at once. Read more
Source§fn property<V>(&self, property_name: &str) -> Vwhere
V: for<'b> FromValue<'b> + 'static,
fn property<V>(&self, property_name: &str) -> Vwhere
V: for<'b> FromValue<'b> + 'static,
Gets the property
property_name
of the object and cast it to the type V. Read moreSource§fn property_value(&self, property_name: &str) -> Value
fn property_value(&self, property_name: &str) -> Value
Gets the property
property_name
of the object. Read moreSource§fn has_property(&self, property_name: &str) -> bool
fn has_property(&self, property_name: &str) -> bool
Check if the object has a property
property_name
.Source§fn has_property_with_type(&self, property_name: &str, type_: Type) -> bool
fn has_property_with_type(&self, property_name: &str, type_: Type) -> bool
Check if the object has a property
property_name
of the given type_
.Source§fn property_type(&self, property_name: &str) -> Option<Type>
fn property_type(&self, property_name: &str) -> Option<Type>
Get the type of the property
property_name
of this object. Read moreSource§fn find_property(&self, property_name: &str) -> Option<ParamSpec>
fn find_property(&self, property_name: &str) -> Option<ParamSpec>
Get the
ParamSpec
of the property property_name
of this object.Source§fn list_properties(&self) -> PtrSlice<ParamSpec>
fn list_properties(&self) -> PtrSlice<ParamSpec>
Return all
ParamSpec
of the properties of this object.Source§fn freeze_notify(&self) -> PropertyNotificationFreezeGuard
fn freeze_notify(&self) -> PropertyNotificationFreezeGuard
Freeze all property notifications until the return guard object is dropped. Read more
Source§unsafe fn set_qdata<QD>(&self, key: Quark, value: QD)where
QD: 'static,
unsafe fn set_qdata<QD>(&self, key: Quark, value: QD)where
QD: 'static,
Set arbitrary data on this object with the given
key
. Read moreSource§unsafe fn qdata<QD>(&self, key: Quark) -> Option<NonNull<QD>>where
QD: 'static,
unsafe fn qdata<QD>(&self, key: Quark) -> Option<NonNull<QD>>where
QD: 'static,
Return previously set arbitrary data of this object with the given
key
. Read moreSource§unsafe fn steal_qdata<QD>(&self, key: Quark) -> Option<QD>where
QD: 'static,
unsafe fn steal_qdata<QD>(&self, key: Quark) -> Option<QD>where
QD: 'static,
Retrieve previously set arbitrary data of this object with the given
key
. Read moreSource§unsafe fn set_data<QD>(&self, key: &str, value: QD)where
QD: 'static,
unsafe fn set_data<QD>(&self, key: &str, value: QD)where
QD: 'static,
Set arbitrary data on this object with the given
key
. Read moreSource§unsafe fn data<QD>(&self, key: &str) -> Option<NonNull<QD>>where
QD: 'static,
unsafe fn data<QD>(&self, key: &str) -> Option<NonNull<QD>>where
QD: 'static,
Return previously set arbitrary data of this object with the given
key
. Read moreSource§unsafe fn steal_data<QD>(&self, key: &str) -> Option<QD>where
QD: 'static,
unsafe fn steal_data<QD>(&self, key: &str) -> Option<QD>where
QD: 'static,
Retrieve previously set arbitrary data of this object with the given
key
. Read moreSource§fn block_signal(&self, handler_id: &SignalHandlerId)
fn block_signal(&self, handler_id: &SignalHandlerId)
Block a given signal handler. Read more
Source§fn unblock_signal(&self, handler_id: &SignalHandlerId)
fn unblock_signal(&self, handler_id: &SignalHandlerId)
Unblock a given signal handler.
Source§fn stop_signal_emission(&self, signal_id: SignalId, detail: Option<Quark>)
fn stop_signal_emission(&self, signal_id: SignalId, detail: Option<Quark>)
Stop emission of the currently emitted signal.
Source§fn stop_signal_emission_by_name(&self, signal_name: &str)
fn stop_signal_emission_by_name(&self, signal_name: &str)
Stop emission of the currently emitted signal by the (possibly detailed) signal name.
Source§fn connect<F>(
&self,
signal_name: &str,
after: bool,
callback: F,
) -> SignalHandlerId
fn connect<F>( &self, signal_name: &str, after: bool, callback: F, ) -> SignalHandlerId
Connect to the signal
signal_name
on this object. Read moreSource§fn connect_id<F>(
&self,
signal_id: SignalId,
details: Option<Quark>,
after: bool,
callback: F,
) -> SignalHandlerId
fn connect_id<F>( &self, signal_id: SignalId, details: Option<Quark>, after: bool, callback: F, ) -> SignalHandlerId
Connect to the signal
signal_id
on this object. Read moreSource§fn connect_local<F>(
&self,
signal_name: &str,
after: bool,
callback: F,
) -> SignalHandlerId
fn connect_local<F>( &self, signal_name: &str, after: bool, callback: F, ) -> SignalHandlerId
Connect to the signal
signal_name
on this object. Read moreSource§fn connect_local_id<F>(
&self,
signal_id: SignalId,
details: Option<Quark>,
after: bool,
callback: F,
) -> SignalHandlerId
fn connect_local_id<F>( &self, signal_id: SignalId, details: Option<Quark>, after: bool, callback: F, ) -> SignalHandlerId
Connect to the signal
signal_id
on this object. Read moreSource§unsafe fn connect_unsafe<F>(
&self,
signal_name: &str,
after: bool,
callback: F,
) -> SignalHandlerId
unsafe fn connect_unsafe<F>( &self, signal_name: &str, after: bool, callback: F, ) -> SignalHandlerId
Connect to the signal
signal_name
on this object. Read moreSource§unsafe fn connect_unsafe_id<F>(
&self,
signal_id: SignalId,
details: Option<Quark>,
after: bool,
callback: F,
) -> SignalHandlerId
unsafe fn connect_unsafe_id<F>( &self, signal_id: SignalId, details: Option<Quark>, after: bool, callback: F, ) -> SignalHandlerId
Connect to the signal
signal_id
on this object. Read moreSource§fn connect_closure(
&self,
signal_name: &str,
after: bool,
closure: RustClosure,
) -> SignalHandlerId
fn connect_closure( &self, signal_name: &str, after: bool, closure: RustClosure, ) -> SignalHandlerId
Connect a closure to the signal
signal_name
on this object. Read moreSource§fn connect_closure_id(
&self,
signal_id: SignalId,
details: Option<Quark>,
after: bool,
closure: RustClosure,
) -> SignalHandlerId
fn connect_closure_id( &self, signal_id: SignalId, details: Option<Quark>, after: bool, closure: RustClosure, ) -> SignalHandlerId
Connect a closure to the signal
signal_id
on this object. Read moreSource§fn watch_closure(&self, closure: &impl AsRef<Closure>)
fn watch_closure(&self, closure: &impl AsRef<Closure>)
Limits the lifetime of
closure
to the lifetime of the object. When
the object’s reference count drops to zero, the closure will be
invalidated. An invalidated closure will ignore any calls to
invoke_with_values
, or
invoke
when using Rust closures.Source§fn emit<R>(&self, signal_id: SignalId, args: &[&dyn ToValue]) -> Rwhere
R: TryFromClosureReturnValue,
fn emit<R>(&self, signal_id: SignalId, args: &[&dyn ToValue]) -> Rwhere
R: TryFromClosureReturnValue,
Emit signal by signal id. Read more
Source§fn emit_with_values(&self, signal_id: SignalId, args: &[Value]) -> Option<Value>
fn emit_with_values(&self, signal_id: SignalId, args: &[Value]) -> Option<Value>
Same as
Self::emit
but takes Value
for the arguments.Source§fn emit_by_name<R>(&self, signal_name: &str, args: &[&dyn ToValue]) -> Rwhere
R: TryFromClosureReturnValue,
fn emit_by_name<R>(&self, signal_name: &str, args: &[&dyn ToValue]) -> Rwhere
R: TryFromClosureReturnValue,
Emit signal by its name. Read more
Source§fn emit_by_name_with_values(
&self,
signal_name: &str,
args: &[Value],
) -> Option<Value>
fn emit_by_name_with_values( &self, signal_name: &str, args: &[Value], ) -> Option<Value>
Emit signal by its name. Read more
Source§fn emit_by_name_with_details<R>(
&self,
signal_name: &str,
details: Quark,
args: &[&dyn ToValue],
) -> Rwhere
R: TryFromClosureReturnValue,
fn emit_by_name_with_details<R>(
&self,
signal_name: &str,
details: Quark,
args: &[&dyn ToValue],
) -> Rwhere
R: TryFromClosureReturnValue,
Emit signal by its name with details. Read more
Source§fn emit_by_name_with_details_and_values(
&self,
signal_name: &str,
details: Quark,
args: &[Value],
) -> Option<Value>
fn emit_by_name_with_details_and_values( &self, signal_name: &str, details: Quark, args: &[Value], ) -> Option<Value>
Emit signal by its name with details. Read more
Source§fn emit_with_details<R>(
&self,
signal_id: SignalId,
details: Quark,
args: &[&dyn ToValue],
) -> Rwhere
R: TryFromClosureReturnValue,
fn emit_with_details<R>(
&self,
signal_id: SignalId,
details: Quark,
args: &[&dyn ToValue],
) -> Rwhere
R: TryFromClosureReturnValue,
Emit signal by signal id with details. Read more
Source§fn emit_with_details_and_values(
&self,
signal_id: SignalId,
details: Quark,
args: &[Value],
) -> Option<Value>
fn emit_with_details_and_values( &self, signal_id: SignalId, details: Quark, args: &[Value], ) -> Option<Value>
Emit signal by signal id with details. Read more
Source§fn disconnect(&self, handler_id: SignalHandlerId)
fn disconnect(&self, handler_id: SignalHandlerId)
Disconnect a previously connected signal handler.
Source§fn connect_notify<F>(&self, name: Option<&str>, f: F) -> SignalHandlerId
fn connect_notify<F>(&self, name: Option<&str>, f: F) -> SignalHandlerId
Connect to the
notify
signal of the object. Read moreSource§fn connect_notify_local<F>(&self, name: Option<&str>, f: F) -> SignalHandlerId
fn connect_notify_local<F>(&self, name: Option<&str>, f: F) -> SignalHandlerId
Connect to the
notify
signal of the object. Read moreSource§unsafe fn connect_notify_unsafe<F>(
&self,
name: Option<&str>,
f: F,
) -> SignalHandlerId
unsafe fn connect_notify_unsafe<F>( &self, name: Option<&str>, f: F, ) -> SignalHandlerId
Connect to the
notify
signal of the object. Read moreSource§fn notify(&self, property_name: &str)
fn notify(&self, property_name: &str)
Notify that the given property has changed its value. Read more
Source§fn notify_by_pspec(&self, pspec: &ParamSpec)
fn notify_by_pspec(&self, pspec: &ParamSpec)
Notify that the given property has changed its value. Read more
Source§fn add_weak_ref_notify<F>(&self, f: F) -> WeakRefNotify<T>
fn add_weak_ref_notify<F>(&self, f: F) -> WeakRefNotify<T>
Add a callback to be notified when the Object is disposed.
Source§fn add_weak_ref_notify_local<F>(&self, f: F) -> WeakRefNotify<T>where
F: FnOnce() + 'static,
fn add_weak_ref_notify_local<F>(&self, f: F) -> WeakRefNotify<T>where
F: FnOnce() + 'static,
Add a callback to be notified when the Object is disposed. Read more
Source§fn bind_property<'a, 'f, 't, O>(
&'a self,
source_property: &'a str,
target: &'a O,
target_property: &'a str,
) -> BindingBuilder<'a, 'f, 't>where
O: ObjectType,
fn bind_property<'a, 'f, 't, O>(
&'a self,
source_property: &'a str,
target: &'a O,
target_property: &'a str,
) -> BindingBuilder<'a, 'f, 't>where
O: ObjectType,
Source§unsafe fn run_dispose(&self)
unsafe fn run_dispose(&self)
Runs the dispose mechanism of the object. Read more
Source§impl<T> PropertyGet for Twhere
T: HasParamSpec,
impl<T> PropertyGet for Twhere
T: HasParamSpec,
Source§impl<T> StaticTypeExt for Twhere
T: StaticType,
impl<T> StaticTypeExt for Twhere
T: StaticType,
Source§fn ensure_type()
fn ensure_type()
Ensures that the type has been registered with the type system.
Source§impl<O> TextBufferExt for Owhere
O: IsA<TextBuffer>,
impl<O> TextBufferExt for Owhere
O: IsA<TextBuffer>,
fn add_mark(&self, mark: &impl IsA<TextMark>, where_: &TextIter)
fn add_selection_clipboard(&self, clipboard: &Clipboard)
fn apply_tag(&self, tag: &impl IsA<TextTag>, start: &TextIter, end: &TextIter)
fn apply_tag_by_name(&self, name: &str, start: &TextIter, end: &TextIter)
fn backspace( &self, iter: &mut TextIter, interactive: bool, default_editable: bool, ) -> bool
fn begin_irreversible_action(&self)
fn begin_user_action(&self)
fn copy_clipboard(&self, clipboard: &Clipboard)
fn create_child_anchor(&self, iter: &mut TextIter) -> TextChildAnchor
fn create_mark( &self, mark_name: Option<&str>, where_: &TextIter, left_gravity: bool, ) -> TextMark
fn cut_clipboard(&self, clipboard: &Clipboard, default_editable: bool)
fn delete(&self, start: &mut TextIter, end: &mut TextIter)
fn delete_interactive( &self, start_iter: &mut TextIter, end_iter: &mut TextIter, default_editable: bool, ) -> bool
fn delete_mark(&self, mark: &impl IsA<TextMark>)
fn delete_mark_by_name(&self, name: &str)
fn delete_selection(&self, interactive: bool, default_editable: bool) -> bool
fn end_irreversible_action(&self)
fn end_user_action(&self)
fn bounds(&self) -> (TextIter, TextIter)
fn can_redo(&self) -> bool
fn can_undo(&self) -> bool
fn char_count(&self) -> i32
fn enables_undo(&self) -> bool
fn end_iter(&self) -> TextIter
fn has_selection(&self) -> bool
fn get_insert(&self) -> TextMark
fn iter_at_child_anchor(&self, anchor: &impl IsA<TextChildAnchor>) -> TextIter
fn iter_at_line(&self, line_number: i32) -> Option<TextIter>
fn iter_at_line_index( &self, line_number: i32, byte_index: i32, ) -> Option<TextIter>
fn iter_at_line_offset( &self, line_number: i32, char_offset: i32, ) -> Option<TextIter>
fn iter_at_mark(&self, mark: &impl IsA<TextMark>) -> TextIter
fn iter_at_offset(&self, char_offset: i32) -> TextIter
fn line_count(&self) -> i32
fn mark(&self, name: &str) -> Option<TextMark>
fn max_undo_levels(&self) -> u32
fn is_modified(&self) -> bool
fn selection_bound(&self) -> TextMark
fn selection_bounds(&self) -> Option<(TextIter, TextIter)>
fn selection_content(&self) -> ContentProvider
fn slice( &self, start: &TextIter, end: &TextIter, include_hidden_chars: bool, ) -> GString
fn start_iter(&self) -> TextIter
fn tag_table(&self) -> TextTagTable
fn text( &self, start: &TextIter, end: &TextIter, include_hidden_chars: bool, ) -> GString
fn insert(&self, iter: &mut TextIter, text: &str)
fn insert_at_cursor(&self, text: &str)
fn insert_child_anchor( &self, iter: &mut TextIter, anchor: &impl IsA<TextChildAnchor>, )
fn insert_interactive( &self, iter: &mut TextIter, text: &str, default_editable: bool, ) -> bool
fn insert_interactive_at_cursor( &self, text: &str, default_editable: bool, ) -> bool
fn insert_markup(&self, iter: &mut TextIter, markup: &str)
fn insert_paintable(&self, iter: &mut TextIter, paintable: &impl IsA<Paintable>)
fn insert_range(&self, iter: &mut TextIter, start: &TextIter, end: &TextIter)
fn insert_range_interactive( &self, iter: &mut TextIter, start: &TextIter, end: &TextIter, default_editable: bool, ) -> bool
fn move_mark(&self, mark: &impl IsA<TextMark>, where_: &TextIter)
fn move_mark_by_name(&self, name: &str, where_: &TextIter)
fn paste_clipboard( &self, clipboard: &Clipboard, override_location: Option<&TextIter>, default_editable: bool, )
fn place_cursor(&self, where_: &TextIter)
fn redo(&self)
Source§fn remove_commit_notify(&self, commit_notify_handler: u32)
fn remove_commit_notify(&self, commit_notify_handler: u32)
Available on crate feature
v4_16
only.fn remove_selection_clipboard(&self, clipboard: &Clipboard)
fn remove_tag(&self, tag: &impl IsA<TextTag>, start: &TextIter, end: &TextIter)
fn remove_tag_by_name(&self, name: &str, start: &TextIter, end: &TextIter)
fn select_range(&self, ins: &TextIter, bound: &TextIter)
fn set_enable_undo(&self, enable_undo: bool)
fn set_max_undo_levels(&self, max_undo_levels: u32)
fn set_modified(&self, setting: bool)
fn set_text(&self, text: &str)
fn undo(&self)
fn cursor_position(&self) -> i32
fn connect_apply_tag<F>(&self, f: F) -> SignalHandlerId
fn connect_begin_user_action<F>(&self, f: F) -> SignalHandlerIdwhere
F: Fn(&Self) + 'static,
fn connect_changed<F>(&self, f: F) -> SignalHandlerIdwhere
F: Fn(&Self) + 'static,
fn connect_delete_range<F>(&self, f: F) -> SignalHandlerId
fn connect_end_user_action<F>(&self, f: F) -> SignalHandlerIdwhere
F: Fn(&Self) + 'static,
fn connect_insert_child_anchor<F>(&self, f: F) -> SignalHandlerId
fn connect_insert_paintable<F>(&self, f: F) -> SignalHandlerId
fn connect_mark_deleted<F>(&self, f: F) -> SignalHandlerId
fn connect_mark_set<F>(&self, f: F) -> SignalHandlerId
fn connect_modified_changed<F>(&self, f: F) -> SignalHandlerIdwhere
F: Fn(&Self) + 'static,
fn connect_paste_done<F>(&self, f: F) -> SignalHandlerId
fn connect_redo<F>(&self, f: F) -> SignalHandlerIdwhere
F: Fn(&Self) + 'static,
fn connect_remove_tag<F>(&self, f: F) -> SignalHandlerId
fn connect_undo<F>(&self, f: F) -> SignalHandlerIdwhere
F: Fn(&Self) + 'static,
fn connect_can_redo_notify<F>(&self, f: F) -> SignalHandlerIdwhere
F: Fn(&Self) + 'static,
fn connect_can_undo_notify<F>(&self, f: F) -> SignalHandlerIdwhere
F: Fn(&Self) + 'static,
fn connect_cursor_position_notify<F>(&self, f: F) -> SignalHandlerIdwhere
F: Fn(&Self) + 'static,
fn connect_enable_undo_notify<F>(&self, f: F) -> SignalHandlerIdwhere
F: Fn(&Self) + 'static,
fn connect_has_selection_notify<F>(&self, f: F) -> SignalHandlerIdwhere
F: Fn(&Self) + 'static,
fn connect_text_notify<F>(&self, f: F) -> SignalHandlerIdwhere
F: Fn(&Self) + 'static,
Source§impl<O> TextBufferExtManual for Owhere
O: IsA<TextBuffer>,
impl<O> TextBufferExtManual for Owhere
O: IsA<TextBuffer>,
Source§fn create_tag(
&self,
tag_name: Option<&str>,
properties: &[(&str, &dyn ToValue)],
) -> Option<TextTag>
fn create_tag( &self, tag_name: Option<&str>, properties: &[(&str, &dyn ToValue)], ) -> Option<TextTag>
Panics Read more
fn connect_insert_text<F>(&self, f: F) -> SignalHandlerId
Source§fn add_commit_notify<P>(
&self,
flags: TextBufferNotifyFlags,
commit_notify: P,
) -> u32
fn add_commit_notify<P>( &self, flags: TextBufferNotifyFlags, commit_notify: P, ) -> u32
Available on crate feature
v4_16
only.