File: button.h

package info (click to toggle)
jwm 1.5-1
  • links: PTS
  • area: main
  • in suites: etch, etch-m68k
  • size: 1,212 kB
  • ctags: 1,758
  • sloc: ansic: 14,975; sh: 2,704; makefile: 183
file content (33 lines) | stat: -rw-r--r-- 717 bytes parent folder | download
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
/***************************************************************************
 * Header for the button functions.
 * Copyright (C) 2004 Joe Wingbermuehle
 ***************************************************************************/

#ifndef BUTTON_H
#define BUTTON_H

#include "font.h"

typedef enum {
	BUTTON_MENU,
	BUTTON_MENU_ACTIVE,
	BUTTON_TASK,
	BUTTON_TASK_ACTIVE
} ButtonType;

typedef enum {
	ALIGN_LEFT,
	ALIGN_CENTER,
	ALIGN_RIGHT
} AlignmentType;

void SetButtonDrawable(Drawable d, GC g);
void SetButtonFont(FontType f);
void SetButtonSize(int w, int h);
void SetButtonAlignment(AlignmentType a);
void SetButtonTextOffset(int o);

void DrawButton(int x, int y, ButtonType type, const char *str);

#endif