blob: 56be9c8dd2c17da75b91a4198d82d86fa6f19729 [file] [log] [blame] [raw]
/* 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 "config.h"
#include "Vector.h"
#include "Settings.h"
#include "ProcessList.h"
#ifdef DISK_STATS
#include "DiskList.h"
#endif
#include "Meter.h"
#undef columns
typedef struct Header_ {
Vector** columns;
Settings* settings;
ProcessList *pl;
#ifdef DISK_STATS
DiskList *disk_list;
#endif
int nrColumns;
int pad;
int height;
} Header;
#ifndef MAX
#define MAX(a,b) ((a)>(b)?(a):(b))
#endif
#ifndef Header_forEachColumn
#define Header_forEachColumn(this_, i_) for (int (i_)=0; (i_) < (this_)->nrColumns; ++(i_))
#endif
Header* Header_new(ProcessList *pl, Settings* settings, int nrColumns);
void Header_delete(Header* this);
void Header_populateFromSettings(Header* this);
void Header_writeBackToSettings(const Header* this);
MeterModeId Header_addMeterByName(Header* this, const char *name, int column);
void Header_setMode(Header* this, int i, MeterModeId mode, int column);
Meter* Header_addMeterByClass(Header* this, MeterClass* type, int param, int column);
int Header_size(Header* this, int column);
char* Header_readMeterName(Header* this, int i, int column);
MeterModeId Header_readMeterMode(Header* this, int i, int column);
void Header_reinit(const Header *this);
void Header_draw(const Header* this);
int Header_calculateHeight(Header* this);
void Header_runSetup(Header *this, Settings *settings, const ProcessList *pl);
#endif