2 * AT-SPI - Assistive Technology Service Provider Interface
3 * (Gnome Accessibility Project; http://developer.gnome.org/projects/gap)
5 * Copyright 2001, 2002 Sun Microsystems Inc.,
6 * Copyright 2001, 2002 Ximian, Inc.
7 * Copyright 2010, 2011 Novell, Inc.
9 * This library is free software; you can redistribute it and/or
10 * modify it under the terms of the GNU Library General Public
11 * License as published by the Free Software Foundation; either
12 * version 2 of the License, or (at your option) any later version.
14 * This library is distributed in the hope that it will be useful,
15 * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
17 * Library General Public License for more details.
19 * You should have received a copy of the GNU Library General Public
20 * License along with this library; if not, write to the
21 * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
22 * Boston, MA 02111-1307, USA.
25 #ifndef _ATSPI_STATE_SET_H_
26 #define _ATSPI_STATE_SET_H_
28 #define ATSPI_TYPE_STATE_SET (atspi_state_set_get_type ())
29 #define ATSPI_STATE_SET(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), ATSPI_TYPE_STATE_SET, AtspiStateSet))
30 #define ATSPI_STATE_SET_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), ATSPI_TYPE_STATE_SET, AtspiStateSetClass))
31 #define ATSPI_IS_STATE_SET(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), ATSPI_TYPE_STATE_SET))
32 #define ATSPI_IS_STATE_SET_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), ATSPI_TYPE_STATE_SET))
33 #define ATSPI_STATE_SET_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), ATSPI_TYPE_STATE_SET, AtspiStateSetClass))
37 typedef struct _AtspiStateSet AtspiStateSet;
41 struct _AtspiAccessible *accessible;
45 typedef struct _AtspiStateSetClass AtspiStateSetClass;
46 struct _AtspiStateSetClass
48 GObjectClass parent_class;
51 GType atspi_state_set_get_type (void);
53 AtspiStateSet * atspi_state_set_new (GArray *states);
55 void atspi_state_set_set_by_name (AtspiStateSet *set, const gchar *name, gboolean enabled);
57 void atspi_state_set_add (AtspiStateSet *set, AtspiStateType state);
59 AtspiStateSet * atspi_state_set_compare (AtspiStateSet *set, AtspiStateSet *set2);
61 gboolean atspi_state_set_contains (AtspiStateSet *set, AtspiStateType state);
63 gboolean atspi_state_set_equals (AtspiStateSet *set, AtspiStateSet *set2);
65 GArray * atspi_state_set_get_states (AtspiStateSet *set);
67 gboolean atspi_state_set_is_empty (AtspiStateSet *set);
69 void atspi_state_set_remove (AtspiStateSet *set, AtspiStateType state);
71 AtspiStateSet * _atspi_state_set_new_internal (struct _AtspiAccessible *accessible, gint64 states);
75 #endif /* _ATSPI_STATE_SET_H_ */