Skip to main content

QImageWriter

Struct QImageWriter 

Source
pub struct QImageWriter { /* private fields */ }
Expand description

C++ class: QImageWriter.

Implementations§

Source§

impl QImageWriter

Source

pub unsafe fn can_write(&self) -> bool

Calls C++ function: bool QImageWriter::canWrite() const.

Source

pub unsafe fn compression(&self) -> c_int

Calls C++ function: int QImageWriter::compression() const.

Source

pub unsafe fn description(&self) -> CppBox<QString>

Calls C++ function: QString QImageWriter::description() const.

Source

pub unsafe fn device(&self) -> QPtr<QIODevice>

Calls C++ function: QIODevice* QImageWriter::device() const.

Source

pub unsafe fn error(&self) -> ImageWriterError

Calls C++ function: QImageWriter::ImageWriterError QImageWriter::error() const.

Source

pub unsafe fn error_string(&self) -> CppBox<QString>

Calls C++ function: QString QImageWriter::errorString() const.

Source

pub unsafe fn file_name(&self) -> CppBox<QString>

Calls C++ function: QString QImageWriter::fileName() const.

Source

pub unsafe fn format(&self) -> CppBox<QByteArray>

Calls C++ function: QByteArray QImageWriter::format() const.

Source

pub unsafe fn gamma(&self) -> c_float

Calls C++ function: float QImageWriter::gamma() const.

Source

pub unsafe fn image_formats_for_mime_type( mime_type: impl CastInto<Ref<QByteArray>>, ) -> CppBox<QListOfQByteArray>

Calls C++ function: static QList<QByteArray> QImageWriter::imageFormatsForMimeType(const QByteArray& mimeType).

Source

pub unsafe fn new() -> CppBox<QImageWriter>

Calls C++ function: [constructor] void QImageWriter::QImageWriter().

Source

pub unsafe fn from_q_io_device_q_byte_array( device: impl CastInto<Ptr<QIODevice>>, format: impl CastInto<Ref<QByteArray>>, ) -> CppBox<QImageWriter>

Calls C++ function: [constructor] void QImageWriter::QImageWriter(QIODevice* device, const QByteArray& format).

Source

pub unsafe fn from_q_string_q_byte_array( file_name: impl CastInto<Ref<QString>>, format: impl CastInto<Ref<QByteArray>>, ) -> CppBox<QImageWriter>

Calls C++ function: [constructor] void QImageWriter::QImageWriter(const QString& fileName, const QByteArray& format = …).

Source

pub unsafe fn from_q_string( file_name: impl CastInto<Ref<QString>>, ) -> CppBox<QImageWriter>

Calls C++ function: [constructor] void QImageWriter::QImageWriter(const QString& fileName).

Source

pub unsafe fn optimized_write(&self) -> bool

Calls C++ function: bool QImageWriter::optimizedWrite() const.

Source

pub unsafe fn progressive_scan_write(&self) -> bool

Calls C++ function: bool QImageWriter::progressiveScanWrite() const.

Source

pub unsafe fn quality(&self) -> c_int

Calls C++ function: int QImageWriter::quality() const.

Source

pub unsafe fn set_compression(&self, compression: c_int)

Calls C++ function: void QImageWriter::setCompression(int compression).

Source

pub unsafe fn set_description(&self, description: impl CastInto<Ref<QString>>)

Calls C++ function: void QImageWriter::setDescription(const QString& description).

Source

pub unsafe fn set_device(&self, device: impl CastInto<Ptr<QIODevice>>)

Calls C++ function: void QImageWriter::setDevice(QIODevice* device).

Source

pub unsafe fn set_file_name(&self, file_name: impl CastInto<Ref<QString>>)

Calls C++ function: void QImageWriter::setFileName(const QString& fileName).

Source

pub unsafe fn set_format(&self, format: impl CastInto<Ref<QByteArray>>)

Calls C++ function: void QImageWriter::setFormat(const QByteArray& format).

Source

pub unsafe fn set_gamma(&self, gamma: c_float)

Calls C++ function: void QImageWriter::setGamma(float gamma).

Source

pub unsafe fn set_optimized_write(&self, optimize: bool)

Calls C++ function: void QImageWriter::setOptimizedWrite(bool optimize).

Source

pub unsafe fn set_progressive_scan_write(&self, progressive: bool)

Calls C++ function: void QImageWriter::setProgressiveScanWrite(bool progressive).

Source

pub unsafe fn set_quality(&self, quality: c_int)

Calls C++ function: void QImageWriter::setQuality(int quality).

Source

pub unsafe fn set_sub_type(&self, type_: impl CastInto<Ref<QByteArray>>)

Calls C++ function: void QImageWriter::setSubType(const QByteArray& type).

Source

pub unsafe fn set_text( &self, key: impl CastInto<Ref<QString>>, text: impl CastInto<Ref<QString>>, )

Calls C++ function: void QImageWriter::setText(const QString& key, const QString& text).

Source

pub unsafe fn set_transformation(&self, orientation: QFlags<Transformation>)

Calls C++ function: void QImageWriter::setTransformation(QFlags<QImageIOHandler::Transformation> orientation).

Source

pub unsafe fn sub_type(&self) -> CppBox<QByteArray>

Calls C++ function: QByteArray QImageWriter::subType() const.

Source

pub unsafe fn supported_image_formats() -> CppBox<QListOfQByteArray>

Calls C++ function: static QList<QByteArray> QImageWriter::supportedImageFormats().

Source

pub unsafe fn supported_mime_types() -> CppBox<QListOfQByteArray>

Calls C++ function: static QList<QByteArray> QImageWriter::supportedMimeTypes().

Source

pub unsafe fn supported_sub_types(&self) -> CppBox<QListOfQByteArray>

Calls C++ function: QList<QByteArray> QImageWriter::supportedSubTypes() const.

Source

pub unsafe fn supports_option(&self, option: ImageOption) -> bool

Calls C++ function: bool QImageWriter::supportsOption(QImageIOHandler::ImageOption option) const.

Source

pub unsafe fn tr( source_text: *const c_char, disambiguation: *const c_char, n: c_int, ) -> CppBox<QString>

Calls C++ function: static QString QImageWriter::tr(const char* sourceText, const char* disambiguation, int n).

Source

pub unsafe fn tr_utf8( source_text: *const c_char, disambiguation: *const c_char, n: c_int, ) -> CppBox<QString>

Calls C++ function: static QString QImageWriter::trUtf8(const char* sourceText, const char* disambiguation, int n).

Source

pub unsafe fn transformation(&self) -> QFlags<Transformation>

Calls C++ function: QFlags<QImageIOHandler::Transformation> QImageWriter::transformation() const.

Source

pub unsafe fn write(&self, image: impl CastInto<Ref<QImage>>) -> bool

Calls C++ function: bool QImageWriter::write(const QImage& image).

Trait Implementations§

Source§

impl CppDeletable for QImageWriter

Source§

unsafe fn delete(&self)

Calls C++ function: [destructor] void QImageWriter::~QImageWriter().

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T, U> CastInto<U> for T
where U: CastFrom<T>,

Source§

unsafe fn cast_into(self) -> U

Performs the conversion. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> StaticUpcast<T> for T

Source§

unsafe fn static_upcast(ptr: Ptr<T>) -> Ptr<T>

Convert type of a const pointer. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.