summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRoss Burton <ross@linux.intel.com>2005-02-03 18:12:38 +0000
committerRoss Burton <ross@linux.intel.com>2005-02-03 18:12:38 +0000
commitffd3fd379f248ccb3cb056c1336ae560a5827cc4 (patch)
treefa8ddadeba61c238d0e1f37a71b6af25e5590753
parent92b9f4c509f795f58ab6ff95cff329c7e695b08e (diff)
downloadfstests-ffd3fd379f248ccb3cb056c1336ae560a5827cc4.tar.gz
fstests-ffd3fd379f248ccb3cb056c1336ae560a5827cc4.tar.bz2
fstests-ffd3fd379f248ccb3cb056c1336ae560a5827cc4.zip
Add switch to disable double buffering
-rw-r--r--tests/test-gtk.c13
1 files changed, 10 insertions, 3 deletions
diff --git a/tests/test-gtk.c b/tests/test-gtk.c
index 17abfe7..3bf515b 100644
--- a/tests/test-gtk.c
+++ b/tests/test-gtk.c
@@ -58,6 +58,7 @@ static Display *dpy;
static int scr;
static Bool Verbose;
+static Bool Buffered = True;
static unsigned long long
GetTimeInMillis(void)
@@ -75,7 +76,7 @@ x_open(void)
gtk_window_set_default_size (GTK_WINDOW (window), gdk_screen_get_width (gdk_screen_get_default()), gdk_screen_get_height (gdk_screen_get_default()));
gtk_widget_show (window);
gtk_widget_map (window);
- gtk_widget_set_double_buffered (window, FALSE);
+ gtk_widget_set_double_buffered (window, Buffered);
gdk_window_fullscreen (window->window);
dpy = gdk_x11_get_default_xdisplay ();
scr = gdk_x11_get_default_screen ();
@@ -211,11 +212,12 @@ void
usage(void)
{
fprintf(stderr,
- "test-pango " VERSION "\n"
- "usage: test-pango [options..]\n"
+ "test-gtk " VERSION "\n"
+ "usage: test-gtk [options..]\n"
"Options are;\n"
"-display <X display>\n"
"--verbose\n"
+ "--no-buffering Turn of GTK+ double buffering\n"
"--text-str <str> text to render ( defaults to alphabet )\n"
"--font <str> Xft font to use ( defaults to " DEFAULT_FONT ")\n"
"--nlines <int> Number of lines to draw per cycle\n"
@@ -266,6 +268,11 @@ main (int argc, char **argv)
continue;
}
+ if (!strcmp ("--no-buffering", argv[i])) {
+ Buffered = False;
+ continue;
+ }
+
usage();
}