JBrowser Source Docs
You are reading the documentation for JBrowser 1.5.3. The newest release is 1.5.4. Go to the latest documentation

jbrowser.core.motion

Generated from the source code of JBrowser 1.5.3.

jbrowser/core/motion.py · 88 lines

Global motion policy: every animation in JBrowser asks this object for its duration.

When "Fluid Animations" is switched off all durations collapse to 0 ms, which makes every transition instantaneous (for low-spec hardware or reduced-motion preferences).

Motion#

class Motion(QObject)source
Motion(enabled: bool=True, parent: QObject | None=None)

Signals

Signal Arguments
changed (bool)

Attributes

Name Value
FAST 120
NORMAL 200
SLOW 280

Motion.enabled#

property enabledsource

Motion.set_enabled#

set_enabled(enabled: bool) -> Nonesource

Motion.ms#

ms(duration: int) -> intsource

Motion.animate_property#

animate_property(target: QObject, prop: bytes, start, end, duration: int=NORMAL, easing: QEasingCurve.Type=QEasingCurve.Type.OutCubic, on_finished: Callable[[], None] | None=None) -> QPropertyAnimation | Nonesource

Animate a Qt property, or jump straight to end when motion is disabled.

Motion.animate_value#

animate_value(parent: QObject, start, end, on_value: Callable[[object], None], duration: int=NORMAL, easing: QEasingCurve.Type=QEasingCurve.Type.OutCubic, on_finished: Callable[[], None] | None=None) -> QVariantAnimation | Nonesource

Functions#

motion#

motion() -> Motionsource