#[repr(transparent)]pub struct Document { /* private fields */ }
Expand description
Properties
author
The author of the document
Readable | Writeable
creation-date
The date the document was created as seconds since the Epoch, or -1
Readable | Writeable
creation-datetime
The [glib::DateTime
][crate::glib::DateTime] the document was created.
Readable | Writeable
creator
The creator of the document. See also Document::creator()
Readable | Writeable
format
The PDF version as string. See also Document::pdf_version_string()
Readable
format-major
The PDF major version number. See also Document::pdf_version()
Readable
format-minor
The PDF minor version number. See also Document::pdf_version()
Readable
keywords
The keywords associated to the document
Readable | Writeable
linearized
Whether document is linearized. See also Document::is_linearized()
Readable
metadata
Document metadata in XML format, or None
Readable
mod-date
The date the document was most recently modified as seconds since the Epoch, or -1
Readable | Writeable
mod-datetime
The [glib::DateTime
][crate::glib::DateTime] the document was most recently modified.
Readable | Writeable
page-layout
The page layout that should be used when the document is opened
Readable
page-mode
The mode that should be used when the document is opened
Readable
permissions
Flags specifying which operations are permitted when the document is opened
Readable
print-duplex
Readable
print-n-copies
Suggested number of copies to be printed for this document
Readable
print-scaling
Readable
producer
The producer of the document. See also Document::producer()
Readable | Writeable
subject
The subject of the document
Readable | Writeable
subtype
Document PDF subtype type
Readable
subtype-conformance
Document PDF subtype conformance
Readable
subtype-part
Document PDF subtype part
Readable
subtype-string
Document PDF subtype. See also Document::pdf_subtype_string()
Readable
title
The document’s title or None
Readable | Writeable
viewer-preferences
Readable
Implementations§
source§impl Document
impl Document
sourcepub fn from_bytes(
bytes: &Bytes,
password: Option<&str>
) -> Result<Document, Error>
pub fn from_bytes( bytes: &Bytes, password: Option<&str> ) -> Result<Document, Error>
Creates a new Document
from bytes
. The returned document
will hold a reference to bytes
.
On error, None
is returned, with error
set. Possible errors include
those in the POPPLER_ERROR
and G_FILE_ERROR
domains.
bytes
a [glib::Bytes
][crate::glib::Bytes]
password
password to unlock the file with, or None
Returns
sourcepub fn from_data(data: &[u8], password: Option<&str>) -> Result<Document, Error>
👎Deprecated: Since 0.82
pub fn from_data(data: &[u8], password: Option<&str>) -> Result<Document, Error>
Creates a new Document
. If None
is returned, then error
will be
set. Possible errors include those in the POPPLER_ERROR
and G_FILE_ERROR
domains.
Note that data
is not copied nor is a new reference to it created.
It must remain valid and cannot be destroyed as long as the returned
document exists.
Deprecated since 0.82
This requires directly managing length
and data
.
Use from_bytes()
instead.
data
the pdf data
password
password to unlock the file with, or None
Returns
sourcepub fn from_fd(fd: i32, password: Option<&str>) -> Result<Document, Error>
pub fn from_fd(fd: i32, password: Option<&str>) -> Result<Document, Error>
Creates a new Document
reading the PDF contents from the file
descriptor fd
. fd
must refer to a regular file, or STDIN, and be open
for reading.
Possible errors include those in the POPPLER_ERROR
and G_FILE_ERROR
domains.
Note that this function takes ownership of fd
; you must not operate on it
again, nor close it.
fd
a valid file descriptor
password
password to unlock the file with, or None
Returns
sourcepub fn from_gfile(
file: &impl IsA<File>,
password: Option<&str>,
cancellable: Option<&impl IsA<Cancellable>>
) -> Result<Document, Error>
pub fn from_gfile( file: &impl IsA<File>, password: Option<&str>, cancellable: Option<&impl IsA<Cancellable>> ) -> Result<Document, Error>
Creates a new Document
reading the PDF contents from file
.
Possible errors include those in the POPPLER_ERROR
and G_FILE_ERROR
domains.
file
a [gio::File
][crate::gio::File] to load
password
password to unlock the file with, or None
cancellable
a [gio::Cancellable
][crate::gio::Cancellable], or None
Returns
sourcepub fn from_stream(
stream: &impl IsA<InputStream>,
length: i64,
password: Option<&str>,
cancellable: Option<&impl IsA<Cancellable>>
) -> Result<Document, Error>
pub fn from_stream( stream: &impl IsA<InputStream>, length: i64, password: Option<&str>, cancellable: Option<&impl IsA<Cancellable>> ) -> Result<Document, Error>
Creates a new Document
reading the PDF contents from stream
.
Note that the given [gio::InputStream
][crate::gio::InputStream] must be seekable or G_IO_ERROR_NOT_SUPPORTED
will be returned.
Possible errors include those in the POPPLER_ERROR
, G_FILE_ERROR
and G_IO_ERROR
domains.
stream
a [gio::InputStream
][crate::gio::InputStream] to read from
length
the stream length, or -1 if not known
password
password to unlock the file with, or None
cancellable
a [gio::Cancellable
][crate::gio::Cancellable], or None
Returns
sourcepub fn builder() -> DocumentBuilder
pub fn builder() -> DocumentBuilder
Creates a new builder-pattern struct instance to construct Document
objects.
This method returns an instance of DocumentBuilder
which can be used to create Document
objects.
sourcepub fn find_dest(&self, link_name: &str) -> Option<Dest>
pub fn find_dest(&self, link_name: &str) -> Option<Dest>
Creates a Dest
for the named destination link_name
in self
.
Note that named destinations are bytestrings, not string. That means that
unless link_name
was returned by a poppler function (e.g. is
PopplerDest.named_dest
), it needs to be converted to string
using [named_dest_from_bytestring()
][crate::named_dest_from_bytestring()] before being passed to this
function.
The returned value must be freed with poppler_dest_free()
.
link_name
a named destination
Returns
a new Dest
destination, or None
if
link_name
is not a destination.
sourcepub fn attachments(&self) -> Vec<Attachment>
pub fn attachments(&self) -> Vec<Attachment>
Returns a GList
containing Attachment
s. These attachments
are unowned, and must be unreffed, and the list must be freed with
g_list_free()
.
Returns
a list of available attachments.
sourcepub fn creation_date(&self) -> c_long
pub fn creation_date(&self) -> c_long
Returns the date the document was created as seconds since the Epoch
Returns
the date the document was created, or -1
sourcepub fn creation_date_time(&self) -> Option<DateTime>
pub fn creation_date_time(&self) -> Option<DateTime>
sourcepub fn form_field(&self, id: i32) -> Option<FormField>
pub fn form_field(&self, id: i32) -> Option<FormField>
sourcepub fn id(&self) -> Option<(GString, GString)>
pub fn id(&self) -> Option<(GString, GString)>
Returns the PDF file identifier represented as two byte string arrays of size 32.
permanent_id
is the permanent identifier that is built based on the file
contents at the time it was originally created, so that this identifer
never changes. update_id
is the update identifier that is built based on
the file contents at the time it was last updated.
Note that returned strings are not null-terminated, they have a fixed size of 32 bytes.
Returns
true
if the self
contains an id, false
otherwise
permanent_id
location to store an allocated string, use g_free()
to free the returned string
update_id
location to store an allocated string, use g_free()
to free the returned string
sourcepub fn modification_date(&self) -> c_long
pub fn modification_date(&self) -> c_long
Returns the date the document was most recently modified as seconds since the Epoch
Returns
the date the document was most recently modified, or -1
sourcepub fn modification_date_time(&self) -> Option<DateTime>
pub fn modification_date_time(&self) -> Option<DateTime>
sourcepub fn n_attachments(&self) -> u32
pub fn n_attachments(&self) -> u32
Returns the number of attachments in a loaded document.
See also attachments()
Returns
Number of attachments
sourcepub fn n_signatures(&self) -> i32
pub fn n_signatures(&self) -> i32
Returns how many digital signatures self
contains.
PDF digital signatures ensure that the content hash not been altered since last edit and
that it was produced by someone the user can trust
Returns
The number of signatures found in the document
sourcepub fn page_by_label(&self, label: &str) -> Option<Page>
pub fn page_by_label(&self, label: &str) -> Option<Page>
Returns the Page
reference by label
. This object is owned by the
caller. label
is a human-readable string representation of the page number,
and can be document specific. Typically, it is a value such as “iii” or “3”.
By default, “1” refers to the first page.
label
a page label
Returns
The Page
referenced by label
sourcepub fn page_layout(&self) -> PageLayout
pub fn page_layout(&self) -> PageLayout
Returns the page layout that should be used when the document is opened
Returns
a PageLayout
that should be used when the document is opened
sourcepub fn pdf_conformance(&self) -> PDFConformance
pub fn pdf_conformance(&self) -> PDFConformance
Returns the conformance level of the self
as PDFConformance
.
Returns
the document’s subtype conformance level
sourcepub fn pdf_part(&self) -> PDFPart
pub fn pdf_part(&self) -> PDFPart
Returns the part of the conforming standard that the self
adheres to
as a PDFSubtype
.
Returns
the document’s subtype part
sourcepub fn pdf_subtype(&self) -> PDFSubtype
pub fn pdf_subtype(&self) -> PDFSubtype
sourcepub fn pdf_subtype_string(&self) -> Option<GString>
pub fn pdf_subtype_string(&self) -> Option<GString>
sourcepub fn pdf_version(&self) -> (u32, u32)
pub fn pdf_version(&self) -> (u32, u32)
Updates values referenced by major_version
& minor_version
with the
major and minor PDF versions of self
.
Returns
major_version
return location for the PDF major version number
minor_version
return location for the PDF minor version number
sourcepub fn pdf_version_string(&self) -> Option<GString>
pub fn pdf_version_string(&self) -> Option<GString>
sourcepub fn permissions(&self) -> Permissions
pub fn permissions(&self) -> Permissions
Returns the flags specifying which operations are permitted when the document is opened.
Returns
a set of flags from Permissions
enumeration
sourcepub fn print_duplex(&self) -> PrintDuplex
pub fn print_duplex(&self) -> PrintDuplex
Returns the duplex mode value suggested for printing by author of the document. Value POPPLER_PRINT_DUPLEX_NONE means that the document does not specify this preference.
Returns
a PrintDuplex
that should be used when document is printed
sourcepub fn print_n_copies(&self) -> i32
pub fn print_n_copies(&self) -> i32
Returns the suggested number of copies to be printed. This preference should be applied only if returned value is greater than 1 since value 1 usually means that the document does not specify it.
Returns
Number of copies
sourcepub fn print_scaling(&self) -> PrintScaling
pub fn print_scaling(&self) -> PrintScaling
Returns the print scaling value suggested by author of the document.
Returns
a PrintScaling
that should be used when document is printed
sourcepub fn signature_fields(&self) -> Vec<FormField>
pub fn signature_fields(&self) -> Vec<FormField>
sourcepub fn has_attachments(&self) -> bool
pub fn has_attachments(&self) -> bool
sourcepub fn has_javascript(&self) -> bool
pub fn has_javascript(&self) -> bool
Returns whether self
has any javascript in it.
sourcepub fn is_linearized(&self) -> bool
pub fn is_linearized(&self) -> bool
sourcepub fn reset_form(&self, fields: &[&str], exclude_fields: bool)
pub fn reset_form(&self, fields: &[&str], exclude_fields: bool)
Resets the form fields specified by fields if exclude_fields is FALSE. Resets all others if exclude_fields is TRUE. All form fields are reset regardless of the exclude_fields flag if fields is empty.
fields
list of fields to reset
exclude_fields
whether to reset all fields except those in fields
pub fn save_a_copy(&self, uri: &str) -> Result<(), Error>
sourcepub fn save_to_fd(&self, fd: i32, include_changes: bool) -> Result<(), Error>
pub fn save_to_fd(&self, fd: i32, include_changes: bool) -> Result<(), Error>
Saves self
. Any change made in the document such as
form fields filled, annotations added or modified
will be saved if include_changes
is true
, or discarded i
include_changes
is false
.
Note that this function takes ownership of fd
; you must not operate on it
again, nor close it.
If error
is set, false
will be returned. Possible errors
include those in the G_FILE_ERROR
domain.
fd
a valid file descriptor open for writing
include_changes
whether to include user changes (e.g. form fills)
Returns
true
, if the document was successfully saved
sourcepub fn set_creation_date(&self, creation_date: c_long)
pub fn set_creation_date(&self, creation_date: c_long)
Sets the document’s creation date. If creation_date
is -1, CreationDate
entry is removed from the document’s Info dictionary.
creation_date
A new creation date
sourcepub fn set_creation_date_time(&self, creation_datetime: Option<&DateTime>)
pub fn set_creation_date_time(&self, creation_datetime: Option<&DateTime>)
Sets the document’s creation date. If creation_datetime
is None
,
CreationDate entry is removed from the document’s Info dictionary.
creation_datetime
A new creation [glib::DateTime
][crate::glib::DateTime]
sourcepub fn set_creator(&self, creator: &str)
pub fn set_creator(&self, creator: &str)
sourcepub fn set_keywords(&self, keywords: &str)
pub fn set_keywords(&self, keywords: &str)
sourcepub fn set_modification_date(&self, modification_date: c_long)
pub fn set_modification_date(&self, modification_date: c_long)
Sets the document’s modification date. If modification_date
is -1, ModDate
entry is removed from the document’s Info dictionary.
modification_date
A new modification date
sourcepub fn set_modification_date_time(
&self,
modification_datetime: Option<&DateTime>
)
pub fn set_modification_date_time( &self, modification_datetime: Option<&DateTime> )
Sets the document’s modification date. If modification_datetime
is None
,
ModDate entry is removed from the document’s Info dictionary.
modification_datetime
A new modification [glib::DateTime
][crate::glib::DateTime]
sourcepub fn set_producer(&self, producer: &str)
pub fn set_producer(&self, producer: &str)
sourcepub fn set_subject(&self, subject: &str)
pub fn set_subject(&self, subject: &str)
sourcepub fn creation_datetime(&self) -> Option<DateTime>
pub fn creation_datetime(&self) -> Option<DateTime>
The [glib::DateTime
][crate::glib::DateTime] the document was created.
sourcepub fn set_creation_datetime(&self, creation_datetime: Option<&DateTime>)
pub fn set_creation_datetime(&self, creation_datetime: Option<&DateTime>)
The [glib::DateTime
][crate::glib::DateTime] the document was created.
sourcepub fn format(&self) -> Option<GString>
pub fn format(&self) -> Option<GString>
The PDF version as string. See also pdf_version_string()
sourcepub fn format_major(&self) -> u32
pub fn format_major(&self) -> u32
The PDF major version number. See also pdf_version()
sourcepub fn format_minor(&self) -> u32
pub fn format_minor(&self) -> u32
The PDF minor version number. See also pdf_version()
sourcepub fn mod_date(&self) -> i32
👎Deprecated: Since 20.9
pub fn mod_date(&self) -> i32
The date the document was most recently modified as seconds since the Epoch, or -1
Deprecated since 20.9
This will overflow in 2038. Use mod-datetime instead.
sourcepub fn set_mod_date(&self, mod_date: i32)
👎Deprecated: Since 20.9
pub fn set_mod_date(&self, mod_date: i32)
The date the document was most recently modified as seconds since the Epoch, or -1
Deprecated since 20.9
This will overflow in 2038. Use mod-datetime instead.
sourcepub fn mod_datetime(&self) -> Option<DateTime>
pub fn mod_datetime(&self) -> Option<DateTime>
The [glib::DateTime
][crate::glib::DateTime] the document was most recently modified.
sourcepub fn set_mod_datetime(&self, mod_datetime: Option<&DateTime>)
pub fn set_mod_datetime(&self, mod_datetime: Option<&DateTime>)
The [glib::DateTime
][crate::glib::DateTime] the document was most recently modified.
sourcepub fn subtype(&self) -> PDFSubtype
pub fn subtype(&self) -> PDFSubtype
Document PDF subtype type
sourcepub fn subtype_conformance(&self) -> PDFConformance
pub fn subtype_conformance(&self) -> PDFConformance
Document PDF subtype conformance
sourcepub fn subtype_part(&self) -> PDFPart
pub fn subtype_part(&self) -> PDFPart
Document PDF subtype part
sourcepub fn subtype_string(&self) -> Option<GString>
pub fn subtype_string(&self) -> Option<GString>
Document PDF subtype. See also pdf_subtype_string()
pub fn viewer_preferences(&self) -> ViewerPreferences
pub fn connect_creation_date_notify<F: Fn(&Self) + 'static>( &self, f: F ) -> SignalHandlerId
pub fn connect_creation_datetime_notify<F: Fn(&Self) + 'static>( &self, f: F ) -> SignalHandlerId
pub fn connect_creator_notify<F: Fn(&Self) + 'static>( &self, f: F ) -> SignalHandlerId
pub fn connect_format_notify<F: Fn(&Self) + 'static>( &self, f: F ) -> SignalHandlerId
pub fn connect_format_major_notify<F: Fn(&Self) + 'static>( &self, f: F ) -> SignalHandlerId
pub fn connect_format_minor_notify<F: Fn(&Self) + 'static>( &self, f: F ) -> SignalHandlerId
pub fn connect_keywords_notify<F: Fn(&Self) + 'static>( &self, f: F ) -> SignalHandlerId
pub fn connect_linearized_notify<F: Fn(&Self) + 'static>( &self, f: F ) -> SignalHandlerId
pub fn connect_metadata_notify<F: Fn(&Self) + 'static>( &self, f: F ) -> SignalHandlerId
pub fn connect_mod_date_notify<F: Fn(&Self) + 'static>( &self, f: F ) -> SignalHandlerId
pub fn connect_mod_datetime_notify<F: Fn(&Self) + 'static>( &self, f: F ) -> SignalHandlerId
pub fn connect_page_layout_notify<F: Fn(&Self) + 'static>( &self, f: F ) -> SignalHandlerId
pub fn connect_page_mode_notify<F: Fn(&Self) + 'static>( &self, f: F ) -> SignalHandlerId
pub fn connect_permissions_notify<F: Fn(&Self) + 'static>( &self, f: F ) -> SignalHandlerId
pub fn connect_print_duplex_notify<F: Fn(&Self) + 'static>( &self, f: F ) -> SignalHandlerId
pub fn connect_print_n_copies_notify<F: Fn(&Self) + 'static>( &self, f: F ) -> SignalHandlerId
pub fn connect_print_scaling_notify<F: Fn(&Self) + 'static>( &self, f: F ) -> SignalHandlerId
pub fn connect_producer_notify<F: Fn(&Self) + 'static>( &self, f: F ) -> SignalHandlerId
pub fn connect_subject_notify<F: Fn(&Self) + 'static>( &self, f: F ) -> SignalHandlerId
pub fn connect_subtype_notify<F: Fn(&Self) + 'static>( &self, f: F ) -> SignalHandlerId
pub fn connect_subtype_conformance_notify<F: Fn(&Self) + 'static>( &self, f: F ) -> SignalHandlerId
pub fn connect_subtype_part_notify<F: Fn(&Self) + 'static>( &self, f: F ) -> SignalHandlerId
pub fn connect_subtype_string_notify<F: Fn(&Self) + 'static>( &self, f: F ) -> SignalHandlerId
pub fn connect_title_notify<F: Fn(&Self) + 'static>( &self, f: F ) -> SignalHandlerId
pub fn connect_viewer_preferences_notify<F: Fn(&Self) + 'static>( &self, f: F ) -> SignalHandlerId
Trait Implementations§
source§impl HasParamSpec for Document
impl HasParamSpec for Document
source§impl Ord for Document
impl Ord for Document
source§impl<OT: ObjectType> PartialEq<OT> for Document
impl<OT: ObjectType> PartialEq<OT> for Document
source§impl<OT: ObjectType> PartialOrd<OT> for Document
impl<OT: ObjectType> PartialOrd<OT> for Document
1.0.0 · source§fn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
self
and other
) and is used by the <=
operator. Read moresource§impl StaticType for Document
impl StaticType for Document
source§fn static_type() -> Type
fn static_type() -> Type
Self
.impl Eq for Document
Auto Trait Implementations§
impl RefUnwindSafe for Document
impl !Send for Document
impl !Sync for Document
impl Unpin for Document
impl UnwindSafe for Document
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
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>,
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>,
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>,
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>,
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,
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,
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,
T
unconditionally. Read moresource§unsafe fn unsafe_cast_ref<T>(&self) -> &Twhere
T: ObjectType,
unsafe fn unsafe_cast_ref<T>(&self) -> &Twhere T: ObjectType,
&T
unconditionally. Read moresource§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<T> IntoClosureReturnValue for Twhere
T: Into<Value>,
impl<T> IntoClosureReturnValue for Twhere T: Into<Value>,
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>)where T: ObjectSubclass, <U as ParentClassIs>::Parent: IsSubclassable<T>,
fn parent_instance_init<T>(instance: &mut InitializingObject<T>)where T: ObjectSubclass, <U as ParentClassIs>::Parent: IsSubclassable<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,
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>
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,
T
. Read moresource§fn interface<U>(&self) -> Option<InterfaceRef<'_, U>>where
U: IsInterface,
fn interface<U>(&self) -> Option<InterfaceRef<'_, U>>where U: IsInterface,
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)])
source§fn set_properties_from_value(&self, property_values: &[(&str, Value)])
fn set_properties_from_value(&self, property_values: &[(&str, Value)])
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,
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
property_name
of the object. Read moresource§fn property_type(&self, property_name: &str) -> Option<Type>
fn property_type(&self, property_name: &str) -> Option<Type>
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>
ParamSpec
of the property property_name
of this object.source§fn list_properties(&self) -> PtrSlice<ParamSpec>
fn list_properties(&self) -> PtrSlice<ParamSpec>
ParamSpec
of the properties of this object.source§fn freeze_notify(&self) -> PropertyNotificationFreezeGuard
fn freeze_notify(&self) -> PropertyNotificationFreezeGuard
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,
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,
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,
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,
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,
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,
key
. Read moresource§fn block_signal(&self, handler_id: &SignalHandlerId)
fn block_signal(&self, handler_id: &SignalHandlerId)
source§fn unblock_signal(&self, handler_id: &SignalHandlerId)
fn unblock_signal(&self, handler_id: &SignalHandlerId)
source§fn stop_signal_emission(&self, signal_id: SignalId, detail: Option<Quark>)
fn stop_signal_emission(&self, signal_id: SignalId, detail: Option<Quark>)
source§fn stop_signal_emission_by_name(&self, signal_name: &str)
fn stop_signal_emission_by_name(&self, signal_name: &str)
source§fn connect<F>(
&self,
signal_name: &str,
after: bool,
callback: F
) -> SignalHandlerIdwhere
F: Fn(&[Value]) -> Option<Value> + Send + Sync + 'static,
fn connect<F>( &self, signal_name: &str, after: bool, callback: F ) -> SignalHandlerIdwhere F: Fn(&[Value]) -> Option<Value> + Send + Sync + 'static,
signal_name
on this object. Read moresource§fn connect_id<F>(
&self,
signal_id: SignalId,
details: Option<Quark>,
after: bool,
callback: F
) -> SignalHandlerIdwhere
F: Fn(&[Value]) -> Option<Value> + Send + Sync + 'static,
fn connect_id<F>( &self, signal_id: SignalId, details: Option<Quark>, after: bool, callback: F ) -> SignalHandlerIdwhere F: Fn(&[Value]) -> Option<Value> + Send + Sync + 'static,
signal_id
on this object. Read moresource§fn connect_local<F>(
&self,
signal_name: &str,
after: bool,
callback: F
) -> SignalHandlerIdwhere
F: Fn(&[Value]) -> Option<Value> + 'static,
fn connect_local<F>( &self, signal_name: &str, after: bool, callback: F ) -> SignalHandlerIdwhere F: Fn(&[Value]) -> Option<Value> + 'static,
signal_name
on this object. Read moresource§fn connect_local_id<F>(
&self,
signal_id: SignalId,
details: Option<Quark>,
after: bool,
callback: F
) -> SignalHandlerIdwhere
F: Fn(&[Value]) -> Option<Value> + 'static,
fn connect_local_id<F>( &self, signal_id: SignalId, details: Option<Quark>, after: bool, callback: F ) -> SignalHandlerIdwhere F: Fn(&[Value]) -> Option<Value> + 'static,
signal_id
on this object. Read moresource§unsafe fn connect_unsafe<F>(
&self,
signal_name: &str,
after: bool,
callback: F
) -> SignalHandlerIdwhere
F: Fn(&[Value]) -> Option<Value>,
unsafe fn connect_unsafe<F>( &self, signal_name: &str, after: bool, callback: F ) -> SignalHandlerIdwhere F: Fn(&[Value]) -> Option<Value>,
signal_name
on this object. Read moresource§unsafe fn connect_unsafe_id<F>(
&self,
signal_id: SignalId,
details: Option<Quark>,
after: bool,
callback: F
) -> SignalHandlerIdwhere
F: Fn(&[Value]) -> Option<Value>,
unsafe fn connect_unsafe_id<F>( &self, signal_id: SignalId, details: Option<Quark>, after: bool, callback: F ) -> SignalHandlerIdwhere F: Fn(&[Value]) -> Option<Value>,
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
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
signal_id
on this object. Read moresource§fn watch_closure(&self, closure: &impl AsRef<Closure>)
fn watch_closure(&self, closure: &impl AsRef<Closure>)
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,
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>
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,
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>
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,
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>
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,
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>
source§fn disconnect(&self, handler_id: SignalHandlerId)
fn disconnect(&self, handler_id: SignalHandlerId)
source§fn connect_notify<F>(&self, name: Option<&str>, f: F) -> SignalHandlerIdwhere
F: Fn(&T, &ParamSpec) + Send + Sync + 'static,
fn connect_notify<F>(&self, name: Option<&str>, f: F) -> SignalHandlerIdwhere F: Fn(&T, &ParamSpec) + Send + Sync + 'static,
notify
signal of the object. Read moresource§fn connect_notify_local<F>(&self, name: Option<&str>, f: F) -> SignalHandlerIdwhere
F: Fn(&T, &ParamSpec) + 'static,
fn connect_notify_local<F>(&self, name: Option<&str>, f: F) -> SignalHandlerIdwhere F: Fn(&T, &ParamSpec) + 'static,
notify
signal of the object. Read moresource§unsafe fn connect_notify_unsafe<F>(
&self,
name: Option<&str>,
f: F
) -> SignalHandlerIdwhere
F: Fn(&T, &ParamSpec),
unsafe fn connect_notify_unsafe<F>( &self, name: Option<&str>, f: F ) -> SignalHandlerIdwhere F: Fn(&T, &ParamSpec),
notify
signal of the object. Read more