2 // Generated by gtkmmproc -- DO NOT MODIFY!
3 #ifndef _ATKMM_HYPERLINK_H
4 #define _ATKMM_HYPERLINK_H
11 /* Copyright (C) 2003 The gtkmm Development Team
13 * This library is free software; you can redistribute it and/or
14 * modify it under the terms of the GNU Library General Public
15 * License as published by the Free Software Foundation; either
16 * version 2 of the License, or (at your option) any later version.
18 * This library is distributed in the hope that it will be useful,
19 * but WITHOUT ANY WARRANTY; without even the implied warranty of
20 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
21 * Library General Public License for more details.
23 * You should have received a copy of the GNU Library General Public
24 * License along with this library; if not, write to the Free
25 * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
28 #include <atkmm/action.h>
31 #ifndef DOXYGEN_SHOULD_SKIP_THIS
32 typedef struct _AtkHyperlink AtkHyperlink;
33 typedef struct _AtkHyperlinkClass AtkHyperlinkClass;
34 #endif /* DOXYGEN_SHOULD_SKIP_THIS */
38 { class Hyperlink_Class; } // namespace Atk
44 /* An ATK object which encapsulates a link or set of links in a hypertext document.
45 * It implements the AtkAction interface.
49 : public Glib::Object,
53 #ifndef DOXYGEN_SHOULD_SKIP_THIS
56 typedef Hyperlink CppObjectType;
57 typedef Hyperlink_Class CppClassType;
58 typedef AtkHyperlink BaseObjectType;
59 typedef AtkHyperlinkClass BaseClassType;
61 private: friend class Hyperlink_Class;
62 static CppClassType hyperlink_class_;
66 Hyperlink(const Hyperlink&);
67 Hyperlink& operator=(const Hyperlink&);
70 explicit Hyperlink(const Glib::ConstructParams& construct_params);
71 explicit Hyperlink(AtkHyperlink* castitem);
73 #endif /* DOXYGEN_SHOULD_SKIP_THIS */
78 #ifndef DOXYGEN_SHOULD_SKIP_THIS
79 static GType get_type() G_GNUC_CONST;
80 static GType get_base_type() G_GNUC_CONST;
83 ///Provides access to the underlying C GObject.
84 AtkHyperlink* gobj() { return reinterpret_cast<AtkHyperlink*>(gobject_); }
86 ///Provides access to the underlying C GObject.
87 const AtkHyperlink* gobj() const { return reinterpret_cast<AtkHyperlink*>(gobject_); }
89 ///Provides access to the underlying C instance. The caller is responsible for unrefing it. Use when directly setting fields in structs.
90 AtkHyperlink* gobj_copy();
100 /** Get a the URI associated with the anchor specified
101 * by @a i of @a link .
103 * Multiple anchors are primarily used by client-side image maps.
104 * @param i A (zero-index) integer specifying the desired anchor.
105 * @return A string specifying the URI.
107 Glib::ustring get_uri(int i) const;
110 /** Returns the item associated with this hyperlinks nth anchor.
111 * For instance, the returned Atk::Object will implement Atk::Text
112 * if @a link is a text hyperlink, Atk::Image if @a link is an image
115 * Multiple anchors are primarily used by client-side image maps.
116 * @param i A (zero-index) integer specifying the desired anchor.
117 * @return An Atk::Object associated with this hyperlinks i-th anchor.
119 Glib::RefPtr<Atk::Object> get_object(int i);
121 /** Returns the item associated with this hyperlinks nth anchor.
122 * For instance, the returned Atk::Object will implement Atk::Text
123 * if @a link is a text hyperlink, Atk::Image if @a link is an image
126 * Multiple anchors are primarily used by client-side image maps.
127 * @param i A (zero-index) integer specifying the desired anchor.
128 * @return An Atk::Object associated with this hyperlinks i-th anchor.
130 Glib::RefPtr<const Atk::Object> get_object(int i) const;
133 /** Gets the index with the hypertext document at which this link ends.
134 * @return The index with the hypertext document at which this link ends.
136 int get_end_index() const;
139 /** Gets the index with the hypertext document at which this link begins.
140 * @return The index with the hypertext document at which this link begins.
142 int get_start_index() const;
145 /** Since the document that a link is associated with may have changed
146 * this method returns <tt>true</tt> if the link is still valid (with
147 * respect to the document it references) and <tt>false</tt> otherwise.
148 * @return Whether or not this link is still valid.
150 bool is_valid() const;
153 /** Indicates whether the link currently displays some or all of its
154 * content inline. Ordinary HTML links will usually return
155 * <tt>false</tt>, but an inline <src> HTML element will return
158 * @return Whether or not this link displays its content inline.
160 bool is_inline() const;
163 /** Gets the number of anchors associated with this hyperlink.
164 * @return The number of anchors associated with this hyperlink.
166 int get_n_anchors() const;
168 /** Determines whether this AtkHyperlink is selected
169 * @return True is the AtkHyperlink is selected, False otherwise.
171 bool is_selected_link() const;
176 * <tt>void on_my_%link_activated()</tt>
179 Glib::SignalProxy0< void > signal_link_activated();
182 #ifdef GLIBMM_PROPERTIES_ENABLED
183 /** Specifies whether the AtkHyperlink object is selected.
185 * You rarely need to use properties because there are get_ and set_ methods for almost all of them.
186 * @return A PropertyProxy that allows you to get or set the property of the value, or receive notification when
187 * the value of the property changes.
189 Glib::PropertyProxy_ReadOnly<bool> property_selected_link() const;
190 #endif //#GLIBMM_PROPERTIES_ENABLED
193 #ifdef GLIBMM_PROPERTIES_ENABLED
194 /** The number of anchors associated with the AtkHyperlink object.
196 * You rarely need to use properties because there are get_ and set_ methods for almost all of them.
197 * @return A PropertyProxy that allows you to get or set the property of the value, or receive notification when
198 * the value of the property changes.
200 Glib::PropertyProxy_ReadOnly<int> property_number_of_anchors() const;
201 #endif //#GLIBMM_PROPERTIES_ENABLED
204 #ifdef GLIBMM_PROPERTIES_ENABLED
205 /** The end index of the AtkHyperlink object.
207 * You rarely need to use properties because there are get_ and set_ methods for almost all of them.
208 * @return A PropertyProxy that allows you to get or set the property of the value, or receive notification when
209 * the value of the property changes.
211 Glib::PropertyProxy_ReadOnly<int> property_end_index() const;
212 #endif //#GLIBMM_PROPERTIES_ENABLED
215 #ifdef GLIBMM_PROPERTIES_ENABLED
216 /** The start index of the AtkHyperlink object.
218 * You rarely need to use properties because there are get_ and set_ methods for almost all of them.
219 * @return A PropertyProxy that allows you to get or set the property of the value, or receive notification when
220 * the value of the property changes.
222 Glib::PropertyProxy_ReadOnly<int> property_start_index() const;
223 #endif //#GLIBMM_PROPERTIES_ENABLED
227 #ifdef GLIBMM_VFUNCS_ENABLED
228 virtual gchar* get_uri_vfunc(int i) const;
229 #endif //GLIBMM_VFUNCS_ENABLED
231 #ifdef GLIBMM_VFUNCS_ENABLED
232 virtual Glib::RefPtr<Atk::Object> get_object_vfunc(int i);
233 #endif //GLIBMM_VFUNCS_ENABLED
235 #ifdef GLIBMM_VFUNCS_ENABLED
236 virtual int get_end_index_vfunc() const;
237 #endif //GLIBMM_VFUNCS_ENABLED
239 #ifdef GLIBMM_VFUNCS_ENABLED
240 virtual int get_start_index_vfunc() const;
241 #endif //GLIBMM_VFUNCS_ENABLED
243 #ifdef GLIBMM_VFUNCS_ENABLED
244 virtual bool is_valid_vfunc() const;
245 #endif //GLIBMM_VFUNCS_ENABLED
247 #ifdef GLIBMM_VFUNCS_ENABLED
248 virtual int get_n_anchors_vfunc() const;
249 #endif //GLIBMM_VFUNCS_ENABLED
251 #ifdef GLIBMM_VFUNCS_ENABLED
252 virtual guint link_state_vfunc() const;
253 #endif //GLIBMM_VFUNCS_ENABLED
255 #ifdef GLIBMM_VFUNCS_ENABLED
256 virtual bool is_selected_link_vfunc() const;
257 #endif //GLIBMM_VFUNCS_ENABLED
263 //C++ methods used to invoke GTK+ virtual functions:
264 #ifdef GLIBMM_VFUNCS_ENABLED
265 #endif //GLIBMM_VFUNCS_ENABLED
268 //GTK+ Virtual Functions (override these to change behaviour):
269 #ifdef GLIBMM_VFUNCS_ENABLED
270 #endif //GLIBMM_VFUNCS_ENABLED
272 //Default Signal Handlers::
273 #ifdef GLIBMM_DEFAULT_SIGNAL_HANDLERS_ENABLED
274 virtual void on_link_activated();
275 #endif //GLIBMM_DEFAULT_SIGNAL_HANDLERS_ENABLED
285 /** A Glib::wrap() method for this object.
287 * @param object The C instance.
288 * @param take_copy False if the result should take ownership of the C instance. True if it should take a new copy or ref.
289 * @result A C++ instance that wraps this C instance.
291 * @relates Atk::Hyperlink
293 Glib::RefPtr<Atk::Hyperlink> wrap(AtkHyperlink* object, bool take_copy = false);
297 #endif /* _ATKMM_HYPERLINK_H */