libgnomecanvasmm
line.h
Go to the documentation of this file.
1 // -*- c++ -*-
2 // Generated by gtkmmproc -- DO NOT MODIFY!
3 #ifndef _LIBGNOMECANVASMM_LINE_H
4 #define _LIBGNOMECANVASMM_LINE_H
5 
6 
7 #include <glibmm.h>
8 
9 /* $Id: line.hg,v 1.12 2004/05/02 10:32:35 murrayc Exp $ */
10 
11 /* line.h
12  *
13  * Copyright (C) 1998 EMC Capital Management Inc.
14  * Developed by Havoc Pennington <hp@pobox.com>
15  *
16  * Copyright (C) 1999 The Gtk-- Development Team
17  *
18  * This library is free software; you can redistribute it and/or
19  * modify it under the terms of the GNU Lesser General Public
20  * License as published by the Free Software Foundation; either
21  * version 2.1 of the License, or (at your option) any later version.
22  *
23  * This library is distributed in the hope that it will be useful,
24  * but WITHOUT ANY WARRANTY; without even the implied warranty of
25  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
26  * Lesser General Public License for more details.
27  *
28  * You should have received a copy of the GNU Lesser General Public
29  * License along with this library; if not, write to the Free
30  * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
31  */
32 
33 #include <libgnomecanvasmm/item.h>
34 #include <libgnomecanvas/gnome-canvas-line.h>
35 #include <libgnomecanvas/gnome-canvas-util.h>
36 #include <libgnomecanvas/libgnomecanvas.h>
37 #include <vector>
38 
39 
40 #ifndef DOXYGEN_SHOULD_SKIP_THIS
41 typedef struct _GnomeCanvasLine GnomeCanvasLine;
42 typedef struct _GnomeCanvasLineClass GnomeCanvasLineClass;
43 #endif /* DOXYGEN_SHOULD_SKIP_THIS */
44 
45 
46 namespace Gnome
47 {
48 
49 namespace Canvas
50 { class Line_Class; } // namespace Canvas
51 
52 } // namespace Gnome
53 namespace Gnome
54 {
55 
56 namespace Canvas
57 {
58 
59 class GnomeGroup;
60 
61 // Sample use of Gnome_CanvasPoints :
62 
63 // Gnome_CanvasPoints points;
64 //
65 // points.push_back(Art::Point(0, 0));
66 // points.push_back(Art::Point(100,0));
67 // points.push_back(Art::Point(0,100));
68 // points.push_back(Art::Point(100,100));
69 //
70 // line = new Gnome_CanvasLine(&m_canvasgroup,points);
71 
72 //using std::vector;
73 
78 class Points : public std::vector<Art::Point>
79 {
80 public:
81  Points(size_type nbpoints = 0);
82  explicit Points(GnomeCanvasPoints* castitem);
83  ~Points();
84 
85 #ifndef DOXYGEN_SHOULD_SKIP_THIS
86  typedef GnomeCanvasPoints BaseObjectType; //So that this works with tempaltes that are intended for normal BoxedTypes.
87 #endif /* DOXYGEN_SHOULD_SKIP_THIS */
88 
89  operator bool() const;
90  bool is_null() const;
91 
92  const GnomeCanvasPoints* gobj() const { return _gobj(); }
93  GnomeCanvasPoints* gobj() { return _gobj(); }
94  static GType get_type () { return GNOME_TYPE_CANVAS_POINTS; }
95 
96 protected:
97  GnomeCanvasPoints* _gobj() const;
98  mutable GnomeCanvasPoints* points_;
99  mutable bool owned_;
100 };
101 
102 
103 class Line : public Item
104 {
105  public:
106 #ifndef DOXYGEN_SHOULD_SKIP_THIS
107  typedef Line CppObjectType;
108  typedef Line_Class CppClassType;
109  typedef GnomeCanvasLine BaseObjectType;
110  typedef GnomeCanvasLineClass BaseClassType;
111 #endif /* DOXYGEN_SHOULD_SKIP_THIS */
112 
113  virtual ~Line();
114 
115 #ifndef DOXYGEN_SHOULD_SKIP_THIS
116 
117 private:
118  friend class Line_Class;
119  static CppClassType line_class_;
120 
121  // noncopyable
122  Line(const Line&);
123  Line& operator=(const Line&);
124 
125 protected:
126  explicit Line(const Glib::ConstructParams& construct_params);
127  explicit Line(GnomeCanvasLine* castitem);
128 
129 #endif /* DOXYGEN_SHOULD_SKIP_THIS */
130 
131 public:
132 #ifndef DOXYGEN_SHOULD_SKIP_THIS
133  static GType get_type() G_GNUC_CONST;
134  static GType get_base_type() G_GNUC_CONST;
135 #endif
136 
138  GnomeCanvasLine* gobj() { return reinterpret_cast<GnomeCanvasLine*>(gobject_); }
139 
141  const GnomeCanvasLine* gobj() const { return reinterpret_cast<GnomeCanvasLine*>(gobject_); }
142 
143 
144 public:
145  //C++ methods used to invoke GTK+ virtual functions:
146 #ifdef GLIBMM_VFUNCS_ENABLED
147 #endif //GLIBMM_VFUNCS_ENABLED
148 
149 protected:
150  //GTK+ Virtual Functions (override these to change behaviour):
151 #ifdef GLIBMM_VFUNCS_ENABLED
152 #endif //GLIBMM_VFUNCS_ENABLED
153 
154  //Default Signal Handlers::
155 #ifdef GLIBMM_DEFAULT_SIGNAL_HANDLERS_ENABLED
156 #endif //GLIBMM_DEFAULT_SIGNAL_HANDLERS_ENABLED
157 
158 
159 private:
160 
161 public:
162  explicit Line(Group& parent);
163  Line(Group& parent, const Points& points);
164 
165  #ifdef GLIBMM_PROPERTIES_ENABLED
166 
172  Glib::PropertyProxy<Points> property_points() ;
173 #endif //#GLIBMM_PROPERTIES_ENABLED
174 
175 #ifdef GLIBMM_PROPERTIES_ENABLED
176 
182  Glib::PropertyProxy_ReadOnly<Points> property_points() const;
183 #endif //#GLIBMM_PROPERTIES_ENABLED
184 
185  #ifdef GLIBMM_PROPERTIES_ENABLED
186 
192  Glib::PropertyProxy<Glib::ustring> property_fill_color() ;
193 #endif //#GLIBMM_PROPERTIES_ENABLED
194 
195 #ifdef GLIBMM_PROPERTIES_ENABLED
196 
202  Glib::PropertyProxy_ReadOnly<Glib::ustring> property_fill_color() const;
203 #endif //#GLIBMM_PROPERTIES_ENABLED
204 
205  #ifdef GLIBMM_PROPERTIES_ENABLED
206 
212  Glib::PropertyProxy<Gdk::Color> property_fill_color_gdk() ;
213 #endif //#GLIBMM_PROPERTIES_ENABLED
214 
215 #ifdef GLIBMM_PROPERTIES_ENABLED
216 
222  Glib::PropertyProxy_ReadOnly<Gdk::Color> property_fill_color_gdk() const;
223 #endif //#GLIBMM_PROPERTIES_ENABLED
224 
225  #ifdef GLIBMM_PROPERTIES_ENABLED
226 
232  Glib::PropertyProxy<guint> property_fill_color_rgba() ;
233 #endif //#GLIBMM_PROPERTIES_ENABLED
234 
235 #ifdef GLIBMM_PROPERTIES_ENABLED
236 
242  Glib::PropertyProxy_ReadOnly<guint> property_fill_color_rgba() const;
243 #endif //#GLIBMM_PROPERTIES_ENABLED
244 
245  #ifdef GLIBMM_PROPERTIES_ENABLED
246 
252  Glib::PropertyProxy< Glib::RefPtr<Gdk::Bitmap> > property_fill_stipple() ;
253 #endif //#GLIBMM_PROPERTIES_ENABLED
254 
255 #ifdef GLIBMM_PROPERTIES_ENABLED
256 
262  Glib::PropertyProxy_ReadOnly< Glib::RefPtr<Gdk::Bitmap> > property_fill_stipple() const;
263 #endif //#GLIBMM_PROPERTIES_ENABLED
264 
265  #ifdef GLIBMM_PROPERTIES_ENABLED
266 
272  Glib::PropertyProxy<guint> property_width_pixels() ;
273 #endif //#GLIBMM_PROPERTIES_ENABLED
274 
275 #ifdef GLIBMM_PROPERTIES_ENABLED
276 
282  Glib::PropertyProxy_ReadOnly<guint> property_width_pixels() const;
283 #endif //#GLIBMM_PROPERTIES_ENABLED
284 
285  #ifdef GLIBMM_PROPERTIES_ENABLED
286 
292  Glib::PropertyProxy<double> property_width_units() ;
293 #endif //#GLIBMM_PROPERTIES_ENABLED
294 
295 #ifdef GLIBMM_PROPERTIES_ENABLED
296 
302  Glib::PropertyProxy_ReadOnly<double> property_width_units() const;
303 #endif //#GLIBMM_PROPERTIES_ENABLED
304 
305  #ifdef GLIBMM_PROPERTIES_ENABLED
306 
312  Glib::PropertyProxy<Gdk::CapStyle> property_cap_style() ;
313 #endif //#GLIBMM_PROPERTIES_ENABLED
314 
315 #ifdef GLIBMM_PROPERTIES_ENABLED
316 
322  Glib::PropertyProxy_ReadOnly<Gdk::CapStyle> property_cap_style() const;
323 #endif //#GLIBMM_PROPERTIES_ENABLED
324 
325  #ifdef GLIBMM_PROPERTIES_ENABLED
326 
332  Glib::PropertyProxy<Gdk::JoinStyle> property_join_style() ;
333 #endif //#GLIBMM_PROPERTIES_ENABLED
334 
335 #ifdef GLIBMM_PROPERTIES_ENABLED
336 
342  Glib::PropertyProxy_ReadOnly<Gdk::JoinStyle> property_join_style() const;
343 #endif //#GLIBMM_PROPERTIES_ENABLED
344 
345  #ifdef GLIBMM_PROPERTIES_ENABLED
346 
352  Glib::PropertyProxy<Gdk::LineStyle> property_line_style() ;
353 #endif //#GLIBMM_PROPERTIES_ENABLED
354 
355 #ifdef GLIBMM_PROPERTIES_ENABLED
356 
362  Glib::PropertyProxy_ReadOnly<Gdk::LineStyle> property_line_style() const;
363 #endif //#GLIBMM_PROPERTIES_ENABLED
364 
365  #ifdef GLIBMM_PROPERTIES_ENABLED
366 
372  Glib::PropertyProxy<bool> property_first_arrowhead() ;
373 #endif //#GLIBMM_PROPERTIES_ENABLED
374 
375 #ifdef GLIBMM_PROPERTIES_ENABLED
376 
382  Glib::PropertyProxy_ReadOnly<bool> property_first_arrowhead() const;
383 #endif //#GLIBMM_PROPERTIES_ENABLED
384 
385  #ifdef GLIBMM_PROPERTIES_ENABLED
386 
392  Glib::PropertyProxy<bool> property_last_arrowhead() ;
393 #endif //#GLIBMM_PROPERTIES_ENABLED
394 
395 #ifdef GLIBMM_PROPERTIES_ENABLED
396 
402  Glib::PropertyProxy_ReadOnly<bool> property_last_arrowhead() const;
403 #endif //#GLIBMM_PROPERTIES_ENABLED
404 
405  #ifdef GLIBMM_PROPERTIES_ENABLED
406 
412  Glib::PropertyProxy<bool> property_smooth() ;
413 #endif //#GLIBMM_PROPERTIES_ENABLED
414 
415 #ifdef GLIBMM_PROPERTIES_ENABLED
416 
422  Glib::PropertyProxy_ReadOnly<bool> property_smooth() const;
423 #endif //#GLIBMM_PROPERTIES_ENABLED
424 
425  #ifdef GLIBMM_PROPERTIES_ENABLED
426 
432  Glib::PropertyProxy<guint> property_spline_steps() ;
433 #endif //#GLIBMM_PROPERTIES_ENABLED
434 
435 #ifdef GLIBMM_PROPERTIES_ENABLED
436 
442  Glib::PropertyProxy_ReadOnly<guint> property_spline_steps() const;
443 #endif //#GLIBMM_PROPERTIES_ENABLED
444 
445  #ifdef GLIBMM_PROPERTIES_ENABLED
446 
452  Glib::PropertyProxy<double> property_arrow_shape_a() ;
453 #endif //#GLIBMM_PROPERTIES_ENABLED
454 
455 #ifdef GLIBMM_PROPERTIES_ENABLED
456 
462  Glib::PropertyProxy_ReadOnly<double> property_arrow_shape_a() const;
463 #endif //#GLIBMM_PROPERTIES_ENABLED
464 
465  #ifdef GLIBMM_PROPERTIES_ENABLED
466 
472  Glib::PropertyProxy<double> property_arrow_shape_b() ;
473 #endif //#GLIBMM_PROPERTIES_ENABLED
474 
475 #ifdef GLIBMM_PROPERTIES_ENABLED
476 
482  Glib::PropertyProxy_ReadOnly<double> property_arrow_shape_b() const;
483 #endif //#GLIBMM_PROPERTIES_ENABLED
484 
485  #ifdef GLIBMM_PROPERTIES_ENABLED
486 
492  Glib::PropertyProxy<double> property_arrow_shape_c() ;
493 #endif //#GLIBMM_PROPERTIES_ENABLED
494 
495 #ifdef GLIBMM_PROPERTIES_ENABLED
496 
502  Glib::PropertyProxy_ReadOnly<double> property_arrow_shape_c() const;
503 #endif //#GLIBMM_PROPERTIES_ENABLED
504 
505 
506 };
507 
508 } /* namespace Canvas */
509 } /* namespace Gnome */
510 
511 
512 #ifndef DOXYGEN_SHOULD_SKIP_THIS
513 namespace Glib
514 {
515 
516 template <>
517 class Value<Gnome::Canvas::Points> : public Value_Boxed<Gnome::Canvas::Points>
518 {
519 public:
520  static GType value_type() G_GNUC_CONST;
521 };
522 
523 } // namespace Glib
524 #endif /* DOXYGEN_SHOULD_SKIP_THIS */
525 
526 
527 namespace Glib
528 {
537  Gnome::Canvas::Line* wrap(GnomeCanvasLine* object, bool take_copy = false);
538 } //namespace Glib
539 
540 
541 #endif /* _LIBGNOMECANVASMM_LINE_H */
542 
Glib::PropertyProxy< Glib::ustring > property_fill_color()
You rarely need to use properties because there are get_ and set_ methods for almost all of them...
Glib::PropertyProxy< double > property_arrow_shape_b()
You rarely need to use properties because there are get_ and set_ methods for almost all of them...
Glib::PropertyProxy< double > property_width_units()
You rarely need to use properties because there are get_ and set_ methods for almost all of them...
Points(size_type nbpoints=0)
Definition: bpath.h:149
static GType get_type()
Definition: line.h:94
GnomeCanvasPoints * points_
Definition: line.h:98
Wrapper for GnomeCanvasPoints.
Definition: line.h:78
Definition: affinetrans.h:29
Glib::PropertyProxy< guint > property_fill_color_rgba()
You rarely need to use properties because there are get_ and set_ methods for almost all of them...
Glib::PropertyProxy< Gdk::CapStyle > property_cap_style()
You rarely need to use properties because there are get_ and set_ methods for almost all of them...
bool is_null() const
const GnomeCanvasPoints * gobj() const
Definition: line.h:92
bool owned_
Definition: line.h:99
Glib::PropertyProxy< double > property_arrow_shape_a()
You rarely need to use properties because there are get_ and set_ methods for almost all of them...
Glib::PropertyProxy< guint > property_spline_steps()
You rarely need to use properties because there are get_ and set_ methods for almost all of them...
GnomeCanvasLine * gobj()
Provides access to the underlying C GtkObject.
Definition: line.h:138
Glib::PropertyProxy< bool > property_last_arrowhead()
You rarely need to use properties because there are get_ and set_ methods for almost all of them...
Definition: line.h:103
Glib::PropertyProxy< guint > property_width_pixels()
You rarely need to use properties because there are get_ and set_ methods for almost all of them...
Glib::PropertyProxy< bool > property_first_arrowhead()
You rarely need to use properties because there are get_ and set_ methods for almost all of them...
Line(Group &parent)
Glib::PropertyProxy< Glib::RefPtr< Gdk::Bitmap > > property_fill_stipple()
You rarely need to use properties because there are get_ and set_ methods for almost all of them...
Glib::PropertyProxy< Gdk::Color > property_fill_color_gdk()
You rarely need to use properties because there are get_ and set_ methods for almost all of them...
GnomeCanvasPoints * gobj()
Definition: line.h:93
Definition: item.h:66
Definition: group.h:59
Glib::PropertyProxy< Points > property_points()
You rarely need to use properties because there are get_ and set_ methods for almost all of them...
Glib::PropertyProxy< bool > property_smooth()
You rarely need to use properties because there are get_ and set_ methods for almost all of them...
const GnomeCanvasLine * gobj() const
Provides access to the underlying C GtkObject.
Definition: line.h:141
GnomeCanvasPoints * _gobj() const
Glib::PropertyProxy< double > property_arrow_shape_c()
You rarely need to use properties because there are get_ and set_ methods for almost all of them...
Glib::PropertyProxy< Gdk::LineStyle > property_line_style()
You rarely need to use properties because there are get_ and set_ methods for almost all of them...
Glib::PropertyProxy< Gdk::JoinStyle > property_join_style()
You rarely need to use properties because there are get_ and set_ methods for almost all of them...