]> Pileus Git - ~andy/gtk/blob - gtk/gtkvruler.c
Updated galician translations
[~andy/gtk] / gtk / gtkvruler.c
1 /* GTK - The GIMP Toolkit
2  * Copyright (C) 1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald
3  *
4  * This library is free software; you can redistribute it and/or
5  * modify it under the terms of the GNU Lesser General Public
6  * License as published by the Free Software Foundation; either
7  * version 2 of the License, or (at your option) any later version.
8  *
9  * This library is distributed in the hope that it will be useful,
10  * but WITHOUT ANY WARRANTY; without even the implied warranty of
11  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
12  * Lesser General Public License for more details.
13  *
14  * You should have received a copy of the GNU Lesser General Public
15  * License along with this library; if not, write to the
16  * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
17  * Boston, MA 02111-1307, USA.
18  */
19
20 /*
21  * Modified by the GTK+ Team and others 1997-2000.  See the AUTHORS
22  * file for a list of people on the GTK+ Team.  See the ChangeLog
23  * files for a list of changes.  These files are distributed with
24  * GTK+ at ftp://ftp.gtk.org/pub/gtk/.
25  */
26
27 #include "config.h"
28
29 #include "gtkorientable.h"
30 #include "gtkvruler.h"
31
32
33 /**
34  * SECTION:gtkvruler
35  * @Short_description: A vertical ruler
36  * @Title: GtkVRuler
37  *
38  * <note>
39  *  This widget is considered too specialized/little-used for
40  *  GTK+, and will in the future be moved to some other package.  If
41  *  your application needs this widget, feel free to use it, as the
42  *  widget does work and is useful in some applications; it's just not
43  *  of general interest. However, we are not accepting new features for
44  *  the widget, and it will eventually move out of the GTK+
45  *  distribution.
46  * </note>
47  *
48  * The VRuler widget is a widget arranged vertically creating a ruler that is
49  * utilized around other widgets such as a text widget. The ruler is used to show
50  * the location of the mouse on the window and to show the size of the window in
51  * specified units. The available units of measurement are GTK_PIXELS, GTK_INCHES
52  * and GTK_CENTIMETERS. GTK_PIXELS is the default unit of measurement.
53  */
54
55 G_DEFINE_TYPE (GtkVRuler, gtk_vruler, GTK_TYPE_RULER)
56
57 static void
58 gtk_vruler_class_init (GtkVRulerClass *klass)
59 {
60 }
61
62 static void
63 gtk_vruler_init (GtkVRuler *vruler)
64 {
65   gtk_orientable_set_orientation (GTK_ORIENTABLE (vruler),
66                                   GTK_ORIENTATION_VERTICAL);
67 }
68
69 /**
70  * gtk_vruler_new:
71  *
72  * Creates a new vertical ruler
73  *
74  * Returns: a new #GtkVRuler.
75  */
76 GtkWidget *
77 gtk_vruler_new (void)
78 {
79   return g_object_new (GTK_TYPE_VRULER, NULL);
80 }