docs: describe the pmdaroot process interfaces
[pcp.git] / src / pmchart / main.h
blob63567f808099e1637c6ea897c0ba86ee351fa742
1 /*
2 * Copyright (c) 2014, Red Hat.
3 * Copyright (c) 2007, Aconex. All Rights Reserved.
4 * Copyright (c) 2006, Ken McDonell. All Rights Reserved.
5 *
6 * This program is free software; you can redistribute it and/or modify it
7 * under the terms of the GNU General Public License as published by the
8 * Free Software Foundation; either version 2 of the License, or (at your
9 * option) any later version.
11 * This program is distributed in the hope that it will be useful, but
12 * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
13 * or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
14 * for more details.
16 #ifndef MAIN_H
17 #define MAIN_H
19 #include <stdio.h>
20 #include <pcp/pmapi.h>
21 #include <pcp/impl.h>
23 #include "tab.h"
24 #include "colorscheme.h"
25 #include "qed_console.h"
26 #include "timecontrol.h"
27 #include "qed_fileiconprovider.h"
28 #include "pmchart.h"
30 typedef struct {
31 // Sampling
32 double chartDelta;
33 bool chartDeltaModified;
34 double loggerDelta;
35 bool loggerDeltaModified;
36 int sampleHistory;
37 bool sampleHistoryModified;
38 int visibleHistory;
39 bool visibleHistoryModified;
41 // Default Colors
42 QColor chartBackground;
43 QString chartBackgroundName;
44 bool chartBackgroundModified;
45 QColor chartHighlight;
46 QString chartHighlightName;
47 bool chartHighlightModified;
48 // Color Schemes
49 ColorScheme defaultScheme;
50 bool defaultSchemeModified;
51 QList<ColorScheme> colorSchemes;
52 bool colorSchemesModified;
54 // Toolbar
55 int initialToolbar;
56 bool initialToolbarModified;
57 int nativeToolbar;
58 bool nativeToolbarModified;
59 int toolbarLocation;
60 int toolbarLocationModified;
61 QStringList toolbarActions;
62 bool toolbarActionsModified;
64 // Font
65 QString fontFamily;
66 bool fontFamilyModified;
67 QString fontStyle;
68 bool fontStyleModified;
69 int fontSize;
70 bool fontSizeModified;
72 // Saved Hosts
73 QStringList savedHosts;
74 bool savedHostsModified;
75 } Settings;
77 extern Settings globalSettings;
78 extern void writeSettings();
79 extern QColor nextColor(QString, int *);
81 extern int Cflag;
82 extern int Lflag;
83 extern int Wflag;
84 extern char *outfile;
85 extern char *outgeometry;
87 extern QFont *globalFont;
89 extern GroupControl *activeGroup;
90 extern GroupControl *liveGroup;
91 extern GroupControl *archiveGroup;
93 class PmChart;
94 extern PmChart *pmchart;
96 class TimeControl;
97 extern TimeControl *pmtime;
99 extern double torange(struct timeval, int);
100 extern char *timeString(double);
101 extern char *timeHiResString(double);
102 extern void nomem(void);
105 * number of Y pixels to move the time axis up when exporting to
106 * an image or printing
108 #define TIMEAXISFUDGE 0
110 #endif // MAIN_H