all repos — openbox @ f17b225daadb483b8736dc0e57a9def68e770ae9

openbox fork - make it a bit more like ryudo

openbox/dock.h (raw)

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
#ifndef __dock_h
#define __dock_h

#include "timer.h"
#include "window.h"
#include "stacking.h"
#include "geom.h"
#include "render/render.h"

#include <glib.h>
#include <X11/Xlib.h>
#include <X11/Xutil.h>

typedef enum {
    DockPos_Floating,
    DockPos_TopLeft,
    DockPos_Top,
    DockPos_TopRight,
    DockPos_Right,
    DockPos_BottomRight,
    DockPos_Bottom,
    DockPos_BottomLeft,
    DockPos_Left
} DockPosition;

typedef struct Dock {
    ObWindow obwin;

    Window frame;
    Appearance *a_frame;

    /* actual position (when not auto-hidden) */
    int x, y;
    int w, h;

    gboolean hidden;
    Timer *hide_timer;

    GList *dock_apps;
} Dock;

typedef struct DockApp {
    ObWindow obwin;

    int ignore_unmaps;

    Window icon_win;
    Window win;

    char *name;
    char *class;

    int x;
    int y;
    int w;
    int h;
} DockApp;

extern Strut dock_strut;

void dock_startup();
void dock_shutdown();

void dock_configure();
void dock_hide(gboolean hide);

void dock_add(Window win, XWMHints *wmhints);

void dock_remove_all();
void dock_remove(DockApp *app, gboolean reparent);

void dock_app_drag(DockApp *app, XMotionEvent *e);
void dock_app_configure(DockApp *app, int w, int h);

#endif