[−][src]Struct qt_gui::QScrollEvent
The QScrollEvent class is sent when scrolling.
C++ class: QScrollEvent
.
The QScrollEvent class is sent when scrolling.
The scroll event is sent to indicate that the receiver should be scrolled. Usually the receiver should be something visual like QWidget or QGraphicsObject.
Some care should be taken that no conflicting QScrollEvents are sent from two sources. Using QScroller::scrollTo is save however.
Methods
impl QScrollEvent
[src]
pub unsafe fn content_pos(&self) -> CppBox<QPointF>
[src]
Returns the new scroll position.
Calls C++ function: QPointF QScrollEvent::contentPos() const
.
Returns the new scroll position.
pub unsafe fn copy_from(
&mut self,
other: impl CastInto<Ref<QScrollEvent>>
) -> MutRef<QScrollEvent>
[src]
&mut self,
other: impl CastInto<Ref<QScrollEvent>>
) -> MutRef<QScrollEvent>
The QScrollEvent class is sent when scrolling.
Calls C++ function: QScrollEvent& QScrollEvent::operator=(const QScrollEvent& other)
.
The QScrollEvent class is sent when scrolling.
The scroll event is sent to indicate that the receiver should be scrolled. Usually the receiver should be something visual like QWidget or QGraphicsObject.
Some care should be taken that no conflicting QScrollEvents are sent from two sources. Using QScroller::scrollTo is save however.
pub unsafe fn new(
content_pos: impl CastInto<Ref<QPointF>>,
overshoot: impl CastInto<Ref<QPointF>>,
scroll_state: ScrollState
) -> CppBox<QScrollEvent>
[src]
content_pos: impl CastInto<Ref<QPointF>>,
overshoot: impl CastInto<Ref<QPointF>>,
scroll_state: ScrollState
) -> CppBox<QScrollEvent>
Creates a new QScrollEvent contentPos is the new content position, overshootDistance is the new overshoot distance while scrollState indicates if this scroll event is the first one, the last one or some event in between.
Calls C++ function: [constructor] void QScrollEvent::QScrollEvent(const QPointF& contentPos, const QPointF& overshoot, QScrollEvent::ScrollState scrollState)
.
Creates a new QScrollEvent contentPos is the new content position, overshootDistance is the new overshoot distance while scrollState indicates if this scroll event is the first one, the last one or some event in between.
pub unsafe fn new_copy(
other: impl CastInto<Ref<QScrollEvent>>
) -> CppBox<QScrollEvent>
[src]
other: impl CastInto<Ref<QScrollEvent>>
) -> CppBox<QScrollEvent>
The QScrollEvent class is sent when scrolling.
Calls C++ function: [constructor] void QScrollEvent::QScrollEvent(const QScrollEvent& other)
.
The QScrollEvent class is sent when scrolling.
The scroll event is sent to indicate that the receiver should be scrolled. Usually the receiver should be something visual like QWidget or QGraphicsObject.
Some care should be taken that no conflicting QScrollEvents are sent from two sources. Using QScroller::scrollTo is save however.
pub unsafe fn overshoot_distance(&self) -> CppBox<QPointF>
[src]
Returns the new overshoot distance. See QScroller for an explanation of the term overshoot.
Calls C++ function: QPointF QScrollEvent::overshootDistance() const
.
pub unsafe fn scroll_state(&self) -> ScrollState
[src]
Returns the current scroll state as a combination of ScrollStateFlag values. ScrollStarted (or ScrollFinished) will be set, if this scroll event is the first (or last) event in a scrolling activity. Please note that both values can be set at the same time, if the activity consists of a single QScrollEvent. All other scroll events in between will have their state set to ScrollUpdated.
Calls C++ function: QScrollEvent::ScrollState QScrollEvent::scrollState() const
.
Returns the current scroll state as a combination of ScrollStateFlag values. ScrollStarted (or ScrollFinished) will be set, if this scroll event is the first (or last) event in a scrolling activity. Please note that both values can be set at the same time, if the activity consists of a single QScrollEvent. All other scroll events in between will have their state set to ScrollUpdated.
A widget could for example revert selections when scrolling is started and stopped.
Trait Implementations
impl CppDeletable for QScrollEvent
[src]
unsafe fn delete(&mut self)
[src]
Destroys QScrollEvent.
Calls C++ function: virtual [destructor] void QScrollEvent::~QScrollEvent()
.
Destroys QScrollEvent.
impl Deref for QScrollEvent
[src]
type Target = QEvent
The resulting type after dereferencing.
fn deref(&self) -> &QEvent
[src]
Calls C++ function: QEvent* static_cast<QEvent*>(QScrollEvent* ptr)
.
impl DerefMut for QScrollEvent
[src]
fn deref_mut(&mut self) -> &mut QEvent
[src]
Calls C++ function: QEvent* static_cast<QEvent*>(QScrollEvent* ptr)
.
impl DynamicCast<QScrollEvent> for QEvent
[src]
unsafe fn dynamic_cast(ptr: Ptr<QEvent>) -> Ptr<QScrollEvent>
[src]
Calls C++ function: QScrollEvent* dynamic_cast<QScrollEvent*>(QEvent* ptr)
.
unsafe fn dynamic_cast_mut(ptr: MutPtr<QEvent>) -> MutPtr<QScrollEvent>
[src]
Calls C++ function: QScrollEvent* dynamic_cast<QScrollEvent*>(QEvent* ptr)
.
impl StaticDowncast<QScrollEvent> for QEvent
[src]
unsafe fn static_downcast(ptr: Ptr<QEvent>) -> Ptr<QScrollEvent>
[src]
Calls C++ function: QScrollEvent* static_cast<QScrollEvent*>(QEvent* ptr)
.
unsafe fn static_downcast_mut(ptr: MutPtr<QEvent>) -> MutPtr<QScrollEvent>
[src]
Calls C++ function: QScrollEvent* static_cast<QScrollEvent*>(QEvent* ptr)
.
impl StaticUpcast<QEvent> for QScrollEvent
[src]
unsafe fn static_upcast(ptr: Ptr<QScrollEvent>) -> Ptr<QEvent>
[src]
Calls C++ function: QEvent* static_cast<QEvent*>(QScrollEvent* ptr)
.
unsafe fn static_upcast_mut(ptr: MutPtr<QScrollEvent>) -> MutPtr<QEvent>
[src]
Calls C++ function: QEvent* static_cast<QEvent*>(QScrollEvent* ptr)
.
Auto Trait Implementations
impl RefUnwindSafe for QScrollEvent
impl Send for QScrollEvent
impl Sync for QScrollEvent
impl Unpin for QScrollEvent
impl UnwindSafe for QScrollEvent
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T, U> CastInto<U> for T where
U: CastFrom<T>,
[src]
U: CastFrom<T>,
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> StaticUpcast<T> for T
[src]
unsafe fn static_upcast(ptr: Ptr<T>) -> Ptr<T>
[src]
unsafe fn static_upcast_mut(ptr: MutPtr<T>) -> MutPtr<T>
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,