[gtk+] testscale: add a scale with a fill level to the test
- From: Cosimo Cecchi <cosimoc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk+] testscale: add a scale with a fill level to the test
- Date: Wed, 16 May 2012 14:29:42 +0000 (UTC)
commit ba965b30d270edf50a469f8209dbbfcec291e319
Author: Cosimo Cecchi <cosimoc gnome org>
Date: Wed May 16 10:29:05 2012 -0400
testscale: add a scale with a fill level to the test
tests/testscale.c | 9 +++++++++
1 files changed, 9 insertions(+), 0 deletions(-)
---
diff --git a/tests/testscale.c b/tests/testscale.c
index e71595c..0ac8252 100755
--- a/tests/testscale.c
+++ b/tests/testscale.c
@@ -132,6 +132,15 @@ int main (int argc, char *argv[])
gtk_container_add (GTK_CONTAINER (frame), scale);
gtk_box_pack_start (GTK_BOX (box), frame, FALSE, FALSE, 0);
+ frame = gtk_frame_new ("With fill level");
+ scale = gtk_scale_new_with_range (GTK_ORIENTATION_HORIZONTAL, 0, 100, 1);
+ scales = g_slist_prepend (scales, scale);
+ gtk_scale_set_draw_value (GTK_SCALE (scale), FALSE);
+ gtk_range_set_show_fill_level (GTK_RANGE (scale), TRUE);
+ gtk_range_set_fill_level (GTK_RANGE (scale), 50);
+ gtk_container_add (GTK_CONTAINER (frame), scale);
+ gtk_box_pack_start (GTK_BOX (box), frame, FALSE, FALSE, 0);
+
frame = gtk_frame_new ("Simple marks");
extra_scale = scale = gtk_scale_new_with_range (GTK_ORIENTATION_HORIZONTAL, 0, 100, 1);
scales = g_slist_prepend (scales, scale);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]