1 /*  This file is part of the GtkHTML library.
2  *
3  *  Copyright 2002 Ximian, Inc.
4  *
5  *  Author: Radek Doulik
6  *
7  *
8  *  This library is free software; you can redistribute it and/or
9  *  modify it under the terms of the GNU Library General Public
10  *  License as published by the Free Software Foundation; either
11  *  version 2 of the License, or (at your option) any later version.
12  *
13  *  This library is distributed in the hope that it will be useful,
14  *  but WITHOUT ANY WARRANTY; without even the implied warranty of
15  *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
16  *  Library General Public License for more details.
17  *
18  *  You should have received a copy of the GNU Library General Public License
19  *  along with this library; see the file COPYING.LIB.  If not, write to
20  *  the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
21  *  Boston, MA 02110-1301, USA.
22  */
23 
24 #ifndef __HTML_A11Y_HYPER_LINK_H__
25 #define __HTML_A11Y_HYPER_LINK_H__
26 
27 #include "text.h"
28 #define G_TYPE_HTML_A11Y_HYPER_LINK            (html_a11y_hyper_link_get_type ())
29 #define HTML_A11Y_HYPER_LINK(obj)              (G_TYPE_CHECK_INSTANCE_CAST ((obj), \
30 									   G_TYPE_HTML_A11Y_HYPER_LINK, \
31 									   HTMLA11YHyperLink))
32 #define HTML_A11Y_HYPER_LINK_CLASS(klass)      (G_TYPE_CHECK_CLASS_CAST ((klass), \
33 									G_TYPE_HTML_A11Y_HYPER_LINK, \
34 									HTMLA11YHyperLinkClass))
35 #define G_IS_HTML_A11Y_HYPER_LINK(obj)         (G_TYPE_CHECK_INSTANCE_TYPE ((obj), G_TYPE_HTML_A11Y_HYPER_LINK))
36 #define G_IS_HTML_A11Y_HYPER_LINK_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), G_TYPE_HTML_A11Y_HYPER_LINK))
37 #define HTML_A11Y_HYPER_LINK_GET_CLASS(obj)    (G_TYPE_INSTANCE_GET_CLASS ((obj), G_TYPE_HTML_A11Y_HYPER_LINK, \
38 									  HTMLA11YHyperLinkClass))
39 
40 typedef struct _HTMLA11YHyperLink      HTMLA11YHyperLink;
41 typedef struct _HTMLA11YHyperLinkClass HTMLA11YHyperLinkClass;
42 
43 struct _HTMLA11YHyperLink {
44 	AtkHyperlink atk_hyper_link;
45 
46 	/* use the union for valid type-punning */
47 	union {
48 		HTMLA11Y *object;
49 		gpointer weakref;
50 	} a11y;
51 	gint num;
52 	gint offset;
53 	gchar *description;
54 };
55 
56 GType html_a11y_hyper_link_get_type (void);
57 
58 struct _HTMLA11YHyperLinkClass {
59 	AtkHyperlinkClass parent_class;
60 };
61 
62 AtkHyperlink * html_a11y_hyper_link_new (HTMLA11Y *a11y, gint link_index);
63 
64 #endif
65