[][src]Struct qt_gui::q_abstract_text_document_layout::PaintContext

#[repr(C)]
pub struct PaintContext { /* fields omitted */ }

The QAbstractTextDocumentLayout::PaintContext class is a convenience class defining the parameters used when painting a document's layout.

C++ class: QAbstractTextDocumentLayout::PaintContext.

C++ documentation:

The QAbstractTextDocumentLayout::PaintContext class is a convenience class defining the parameters used when painting a document's layout.

A paint context is used when rendering custom layouts for QTextDocuments with the QAbstractTextDocumentLayout::draw() function. It is specified by a cursor position, default text color, clip rectangle and a collection of selections.

Methods

impl PaintContext[src]

pub unsafe fn clip(&self) -> Ref<QRectF>[src]

Returns a reference to the clip field.

pub unsafe fn clip_mut(&mut self) -> MutRef<QRectF>[src]

Returns a mutable reference to the clip field.

pub unsafe fn copy_from(
    &mut self,
    other: impl CastInto<Ref<PaintContext>>
) -> MutRef<PaintContext>
[src]

The QAbstractTextDocumentLayout::PaintContext class is a convenience class defining the parameters used when painting a document's layout.

Calls C++ function: QAbstractTextDocumentLayout::PaintContext& QAbstractTextDocumentLayout::PaintContext::operator=(const QAbstractTextDocumentLayout::PaintContext& other).

C++ documentation:

The QAbstractTextDocumentLayout::PaintContext class is a convenience class defining the parameters used when painting a document's layout.

A paint context is used when rendering custom layouts for QTextDocuments with the QAbstractTextDocumentLayout::draw() function. It is specified by a cursor position, default text color, clip rectangle and a collection of selections.

pub unsafe fn cursor_position(&self) -> c_int[src]

Returns the value of the cursorPosition field.

pub unsafe fn new() -> CppBox<PaintContext>[src]

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

pub unsafe fn new_copy(
    other: impl CastInto<Ref<PaintContext>>
) -> CppBox<PaintContext>
[src]

The QAbstractTextDocumentLayout::PaintContext class is a convenience class defining the parameters used when painting a document's layout.

Calls C++ function: [constructor] void QAbstractTextDocumentLayout::PaintContext::PaintContext(const QAbstractTextDocumentLayout::PaintContext& other).

C++ documentation:

The QAbstractTextDocumentLayout::PaintContext class is a convenience class defining the parameters used when painting a document's layout.

A paint context is used when rendering custom layouts for QTextDocuments with the QAbstractTextDocumentLayout::draw() function. It is specified by a cursor position, default text color, clip rectangle and a collection of selections.

pub unsafe fn palette(&self) -> Ref<QPalette>[src]

Returns a reference to the palette field.

pub unsafe fn palette_mut(&mut self) -> MutRef<QPalette>[src]

Returns a mutable reference to the palette field.

pub unsafe fn selections(&self) -> Ref<QVectorOfSelection>[src]

Returns a reference to the selections field.

pub unsafe fn selections_mut(&mut self) -> MutRef<QVectorOfSelection>[src]

Returns a mutable reference to the selections field.

pub unsafe fn set_clip(&mut self, value: impl CastInto<Ref<QRectF>>)[src]

Sets the value of the clip field.

pub unsafe fn set_cursor_position(&mut self, value: c_int)[src]

Sets the value of the cursorPosition field.

pub unsafe fn set_palette(&mut self, value: impl CastInto<Ref<QPalette>>)[src]

Sets the value of the palette field.

pub unsafe fn set_selections(
    &mut self,
    value: impl CastInto<Ref<QVectorOfSelection>>
)
[src]

Sets the value of the selections field.

Trait Implementations

impl CppDeletable for PaintContext[src]

unsafe fn delete(&mut self)[src]

The QAbstractTextDocumentLayout::PaintContext class is a convenience class defining the parameters used when painting a document's layout.

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

C++ documentation:

The QAbstractTextDocumentLayout::PaintContext class is a convenience class defining the parameters used when painting a document's layout.

A paint context is used when rendering custom layouts for QTextDocuments with the QAbstractTextDocumentLayout::draw() function. It is specified by a cursor position, default text color, clip rectangle and a collection of selections.

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T, U> CastInto<U> for T where
    U: CastFrom<T>, 
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> StaticUpcast<T> for T[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

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

The type returned in the event of a conversion error.