summaryrefslogtreecommitdiffstats
path: root/include/scrollbar.h
blob: 37a4663f37caf6023aeb802a4ad6f480d6f9671e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
#ifndef ROFI_SCROLLBAR_H
#define ROFI_SCROLLBAR_H

typedef struct _scrollbar
{
    Window       window, parent;
    short        x, y, w, h;
    GC           gc;
    unsigned int length;
    unsigned int pos;
    unsigned int pos_length;
} scrollbar;

scrollbar *scrollbar_create ( Window parent, XVisualInfo *vinfo, Colormap map,
                              short x, short y, short w, short h );

void scrollbar_hide ( scrollbar *sb );
void scrollbar_show ( scrollbar *sb );
void scrollbar_free ( scrollbar *sb );
void scrollbar_set_pos_length ( scrollbar *sb, unsigned int pos_length );
void scrollbar_set_pos ( scrollbar *sb, unsigned int pos );
void scrollbar_set_length ( scrollbar *sb, unsigned int length );
void scrollbar_draw ( scrollbar *sb );
#endif // ROFI_SCROLLBAR_H