forked from hishamhm/htop
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Header.h
58 lines (39 loc) · 1.22 KB
/
Header.h
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
/* Do not edit this file. It was automatically generated. */
#ifndef HEADER_Header
#define HEADER_Header
/*
htop - Header.h
(C) 2004-2011 Hisham H. Muhammad
Released under the GNU GPL, see the COPYING file
in the source distribution for its full text.
*/
#include "ProcessList.h"
#include "Meter.h"
typedef enum HeaderSide_ {
LEFT_HEADER,
RIGHT_HEADER
} HeaderSide;
typedef struct Header_ {
Vector* leftMeters;
Vector* rightMeters;
ProcessList* pl;
int height;
int pad;
bool margin;
} Header;
#ifndef MAX
#define MAX(a,b) ((a)>(b)?(a):(b))
#endif
Header* Header_new(ProcessList* pl);
void Header_delete(Header* this);
void Header_createMeter(Header* this, char* name, HeaderSide side);
void Header_setMode(Header* this, int i, MeterModeId mode, HeaderSide side);
Meter* Header_addMeter(Header* this, MeterClass* type, int param, HeaderSide side);
int Header_size(Header* this, HeaderSide side);
char* Header_readMeterName(Header* this, int i, HeaderSide side);
MeterModeId Header_readMeterMode(Header* this, int i, HeaderSide side);
void Header_defaultMeters(Header* this, int cpuCount);
void Header_reinit(Header* this);
void Header_draw(const Header* this);
int Header_calculateHeight(Header* this);
#endif