![]() |
![]() |
![]() |
libmokoui Reference Manual | ![]() |
---|---|---|---|---|
MokoFingerScroll; enum MokoFingerScrollMode; enum MokoFingerScrollIndicatorMode; GtkWidget* moko_finger_scroll_new (void); GtkWidget* moko_finger_scroll_new_full (gint mode, gboolean enabled, gdouble vel_min, gdouble vel_max, gdouble decel, guint sps); void moko_finger_scroll_add_with_viewport (MokoFingerScroll *scroll, GtkWidget *child);
GObject +----GInitiallyUnowned +----GtkObject +----GtkWidget +----GtkContainer +----GtkBin +----GtkEventBox +----MokoFingerScroll
"deceleration" gdouble : Read / Write / Construct "enabled" gboolean : Read / Write / Construct "hindicator-mode" MokoFingerScrollIndicatorMode : Read / Write / Construct "mode" MokoFingerScrollMode : Read / Write / Construct "spring-color" guint : Read / Write / Construct "spring-speed" gdouble : Read / Write / Construct "sps" guint : Read / Write / Construct "velocity-max" gdouble : Read / Write / Construct "velocity-min" gdouble : Read / Write / Construct "vindicator-mode" MokoFingerScrollIndicatorMode : Read / Write / Construct
MokoFingerScroll implements a scrolled window designed to be used with a touch screen interface. The user scrolls the child widget by activating the pointing device and dragging it over the widget.
typedef struct _MokoFingerScroll MokoFingerScroll;
MokoFingerScroll has no publicly accessible fields
typedef enum { MOKO_FINGER_SCROLL_MODE_PUSH, MOKO_FINGER_SCROLL_MODE_ACCEL, MOKO_FINGER_SCROLL_MODE_AUTO } MokoFingerScrollMode;
Used to change the behaviour of the finger scrolling
typedef enum { MOKO_FINGER_SCROLL_INDICATOR_MODE_AUTO, MOKO_FINGER_SCROLL_INDICATOR_MODE_SHOW, MOKO_FINGER_SCROLL_INDICATOR_MODE_HIDE } MokoFingerScrollIndicatorMode;
GtkWidget* moko_finger_scroll_new (void);
Create a new finger scroll widget
Returns : |
the newly created MokoFingerScroll |
GtkWidget* moko_finger_scroll_new_full (gint mode, gboolean enabled, gdouble vel_min, gdouble vel_max, gdouble decel, guint sps);
Create a new MokoFingerScroll widget and set various properties
|
MokoFingerScrollMode |
|
Value for the enabled property |
|
Value for the velocity-min property |
|
Value for the velocity-max property |
|
Value for the deceleration property |
|
Value for the sps property |
Returns : |
the newly create MokoFingerScrull |
void moko_finger_scroll_add_with_viewport (MokoFingerScroll *scroll, GtkWidget *child);
Convenience function used to add a child to a GtkViewport, and add the viewport to the scrolled window.
|
A MokoFingerScroll |
|
Child widget to add to the viewport |
"deceleration"
property"deceleration" gdouble : Read / Write / Construct
The multiplier used when decelerating when in acceleration scrolling mode.
Allowed values: [0,1]
Default value: 0.95
"enabled"
property"enabled" gboolean : Read / Write / Construct
Enable or disable finger-scroll.
Default value: TRUE
"hindicator-mode"
property"hindicator-mode" MokoFingerScrollIndicatorMode : Read / Write / Construct
Mode of the horizontal scrolling indicator.
Default value: MOKO_FINGER_SCROLL_INDICATOR_MODE_AUTO
"mode"
property"mode" MokoFingerScrollMode : Read / Write / Construct
Change the finger-scrolling mode.
Default value: MOKO_FINGER_SCROLL_MODE_AUTO
"spring-color"
property"spring-color" guint : Read / Write / Construct
spring area color.
Default value: 4294967295
"spring-speed"
property"spring-speed" gdouble : Read / Write / Construct
The multiplier used when decelerating when in spring.
Allowed values: [0,1]
Default value: 0.85
"sps"
property"sps" guint : Read / Write / Construct
Amount of scroll events to generate per second.
Default value: 15
"velocity-max"
property"velocity-max" gdouble : Read / Write / Construct
Maximum distance the child widget should scroll per 'frame', in pixels.
Allowed values: >= 0
Default value: 48
"velocity-min"
property"velocity-min" gdouble : Read / Write / Construct
Minimum distance the child widget should scroll per 'frame', in pixels.
Allowed values: >= 0
Default value: 0
"vindicator-mode"
property"vindicator-mode" MokoFingerScrollIndicatorMode : Read / Write / Construct
Mode of the vertical scrolling indicator.
Default value: MOKO_FINGER_SCROLL_INDICATOR_MODE_AUTO