 |
My Project
debian-1:4.1.1-p2+ds-4
|
Go to the documentation of this file. 1 #ifndef __cxxtest__X11Gui_h__
2 #define __cxxtest__X11Gui_h__
18 #include <X11/Xutil.h>
114 for (
int i = 1;
i + 1 < argc; ++
i ) {
115 if ( !strcmp( argv[
i],
"-title" ) )
117 else if ( !strcmp( argv[
i],
"-fn" ) || !strcmp( argv[
i],
"-font" ) )
119 else if ( !strcmp( argv[
i],
"-fg" ) || !strcmp( argv[
i],
"-foreground" ) )
121 else if ( !strcmp( argv[
i],
"-bg" ) || !strcmp( argv[
i],
"-background" ) )
123 else if ( !strcmp( argv[
i],
"-green" ) )
125 else if ( !strcmp( argv[
i],
"-yellow" ) )
127 else if ( !strcmp( argv[
i],
"-red" ) )
222 Screen *screen = XDefaultScreenOfDisplay(
_display );
223 int screenWidth = WidthOfScreen( screen );
224 int screenHeight = HeightOfScreen( screen );
225 int xCenter = screenWidth / 2;
226 int yCenter = screenHeight / 2;
228 _width = (screenWidth * 4) / 5;
245 unsigned length = strlen(
_programName ) + strlen( suiteName ) + strlen( testName ) +
sizeof(
" - ::()" );
263 XWindowAttributes attributes;
265 _width = attributes.width;
294 char str[
sizeof(
"1000000000 of ") +
sizeof(
_strTotalTests) +
sizeof(
" (100%)")];
296 unsigned len = strlen( str );
298 int textWidth = XTextWidth(
_fontInfo, str, len );
327 #endif //__cxxtest__X11Gui_h__
void setWindowName(const char *suiteName, const char *testName)
unsigned long _foreground
void guiEnterTest(const char *suiteName, const char *testName)
static BOOLEAN length(leftv result, leftv arg)
const char * _foregroundName
char _strTotalTests[WorldDescription::MAX_STRLEN_TOTAL_TESTS]
unsigned long _background
void getTotalTests(const WorldDescription &wd)
const char * _programName
char * strTotalTests(char *) const
void * malloc(size_t size)
virtual unsigned numTotalTests(void) const =0
void parseCommandLine(int &argc, char **argv)
void enterGui(int &argc, char **argv)
void enterWorld(const WorldDescription &wd)
char name(const Variable &v)
unsigned long getColor(const char *colorName)
void initializeBar(const WorldDescription &wd)
const char * _backgroundName