st-scroll-view: St Reference Manual

## st-scroll-view st-scroll-view — a container for scrollable children |

## Functions

StWidget * | st_scroll_view_new ()
ClutterActor * | st_scroll_view_get_hscroll_bar ()
ClutterActor * | st_scroll_view_get_vscroll_bar ()
gfloat | st_scroll_view_get_column_size ()
void | st_scroll_view_set_column_size ()
gfloat | st_scroll_view_get_row_size ()
void | st_scroll_view_set_row_size ()
void | st_scroll_view_set_mouse_scrolling ()
gboolean | st_scroll_view_get_mouse_scrolling ()
void | st_scroll_view_set_overlay_scrollbars ()
gboolean | st_scroll_view_get_overlay_scrollbars ()
void | st_scroll_view_set_policy ()
void | st_scroll_view_update_fade_effect ()

## Types and Values

#define | ST_TYPE_SCROLL_VIEW
enum | StPolicyType
struct | StScrollView
| StScrollViewPrivate

## Description

StScrollView is a single child container for actors that implement StScrollable. It provides scrollbars around the edge of the child to allow the user to move around the scrollable area.

## Functions

### st_scroll_view_new ()

    StWidget *
    st_scroll_view_new (void);

Create a new StScrollView.

#### Returns

a new StScrollView.

[transfer full]

### st_scroll_view_get_hscroll_bar ()

    ClutterActor *
    st_scroll_view_get_hscroll_bar (StScrollView *scroll);

Gets the horizontal StScrollBar of the StScrollView.

#### Parameters

scroll | a StScrollView |

#### Returns

the horizontal scrollbar.

[transfer none]

### st_scroll_view_get_vscroll_bar ()

    ClutterActor *
    st_scroll_view_get_vscroll_bar (StScrollView *scroll);

Gets the vertical scrollbar of the StScrollView.

#### Parameters

scroll | a StScrollView |

#### Returns

the vertical StScrollBar.

[transfer none]

### st_scroll_view_get_column_size ()

    gfloat
    st_scroll_view_get_column_size (StScrollView *scroll);

Get the step increment of the horizontal plane.

#### Parameters

scroll | a StScrollView |

#### Returns

the horizontal step increment

### st_scroll_view_set_column_size ()

    void
    st_scroll_view_set_column_size (StScrollView *scroll,
                                    gfloat column_size);

Set the step increment of the horizontal plane to `column_size` .

#### Parameters

scroll | a StScrollView |
column_size | horizontal step increment |

### st_scroll_view_get_row_size ()

    gfloat
    st_scroll_view_get_row_size (StScrollView *scroll);

Get the step increment of the vertical plane.

#### Parameters

scroll | a StScrollView |

#### Returns

the vertical step increment

### st_scroll_view_set_row_size ()

    void
    st_scroll_view_set_row_size (StScrollView *scroll,
                                 gfloat row_size);

Set the step increment of the vertical plane to `row_size` .

#### Parameters

scroll | a StScrollView |
row_size | vertical step increment |

### st_scroll_view_set_mouse_scrolling ()

    void
    st_scroll_view_set_mouse_scrolling (StScrollView *scroll,
                                        gboolean enabled);

Sets automatic mouse wheel scrolling to enabled or disabled.

#### Parameters

scroll | a StScrollView |
enabled | `TRUE` or `FALSE` |

### st_scroll_view_get_mouse_scrolling ()

    gboolean
    st_scroll_view_get_mouse_scrolling (StScrollView *scroll);

Get whether automatic mouse wheel scrolling is enabled or disabled.

#### Parameters

scroll | a StScrollView |

#### Returns

`TRUE` if enabled, `FALSE` otherwise

### st_scroll_view_set_overlay_scrollbars ()

    void
    st_scroll_view_set_overlay_scrollbars (StScrollView *scroll,
                                           gboolean enabled);

Sets whether scrollbars are painted on top of the content.

#### Parameters

scroll | A StScrollView |
enabled | Whether to enable overlay scrollbars |

### st_scroll_view_get_overlay_scrollbars ()

    gboolean
    st_scroll_view_get_overlay_scrollbars (StScrollView *scroll);

Gets whether scrollbars are painted on top of the content.

#### Parameters

scroll | A StScrollView |

#### Returns

`TRUE` if enabled, `FALSE` otherwise

### st_scroll_view_set_policy ()

    void
    st_scroll_view_set_policy (StScrollView *scroll,
                               StPolicyType hscroll,
                               StPolicyType vscroll);

Set the scroll policy.

#### Parameters

scroll | A StScrollView |
hscroll | Whether to enable horizontal scrolling |
vscroll | Whether to enable vertical scrolling |

### st_scroll_view_update_fade_effect ()

    void
    st_scroll_view_update_fade_effect (StScrollView *scroll,
                                       ClutterMargin *fade_margins);

Sets the fade effects in all four edges of the view. A value of 0 disables the effect.

#### Parameters

scroll | a StScrollView |
fade_margins | a ClutterMargin defining the vertical fade effects, in pixels. |

## Types and Values

### ST_TYPE_SCROLL_VIEW

    #define ST_TYPE_SCROLL_VIEW            (st_scroll_view_get_type())

### enum StPolicyType

#### Members

ST_POLICY_ALWAYS |  |
ST_POLICY_AUTOMATIC |  |
ST_POLICY_NEVER |  |
ST_POLICY_EXTERNAL |  |

### struct StScrollView

    struct StScrollView {
    };

The contents of this structure are private and should only be accessed through the public API.

### StScrollViewPrivate

    typedef struct _StScrollViewPrivate StScrollViewPrivate;