* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the
- * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
- * Boston, MA 02111-1307, USA.
+ * License along with this library. If not, see <http://www.gnu.org/licenses/>.
*/
#include <gtk/gtk.h>
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);
gtk_container_add (GTK_CONTAINER (frame), scale);
gtk_box_pack_start (GTK_BOX (box), frame, FALSE, FALSE, 0);
+ frame = gtk_frame_new ("Simple marks up");
+ 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_scale_add_mark (GTK_SCALE (scale), marks[0], GTK_POS_TOP, NULL);
+ gtk_scale_add_mark (GTK_SCALE (scale), marks[1], GTK_POS_TOP, NULL);
+ gtk_scale_add_mark (GTK_SCALE (scale), marks[2], GTK_POS_TOP, NULL);
+ gtk_container_add (GTK_CONTAINER (frame), scale);
+ gtk_box_pack_start (GTK_BOX (box), frame, FALSE, FALSE, 0);
+
frame = gtk_frame_new ("Labeled marks");
box2 = gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 6);