/[svn]/gigedit/trunk/src/gigedit/compat.cpp
ViewVC logotype

Contents of /gigedit/trunk/src/gigedit/compat.cpp

Parent Directory Parent Directory | Revision Log Revision Log


Revision 2170 - (show annotations) (download)
Sun Mar 6 07:52:43 2011 UTC (13 years ago) by persson
File size: 1429 byte(s)
- added new files missing in previous commit

1 /*
2 * Copyright (C) 2011 Andreas Persson
3 *
4 * This program is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU General Public License as
6 * published by the Free Software Foundation; either version 2, or (at
7 * your option) any later version.
8 *
9 * This program is distributed in the hope that it will be useful, but
10 * WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 * General Public License for more details.
13 *
14 * You should have received a copy of the GNU General Public License
15 * along with program; see the file COPYING. If not, write to the Free
16 * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
17 * 02110-1301 USA.
18 */
19
20 #include <gtkmmconfig.h>
21
22 #if (GTKMM_MAJOR_VERSION == 2 && GTKMM_MINOR_VERSION < 90) || GTKMM_MAJOR_VERSION < 2
23 #include <gdkmm/general.h>
24 #include <gdk/gdkcairo.h>
25 #include "compat.h"
26
27 namespace Gdk {
28 namespace Cairo {
29 void set_source_rgba(const ::Cairo::RefPtr< ::Cairo::Context >& context,
30 const Gdk::RGBA& color) {
31 #if (GTKMM_MAJOR_VERSION == 2 && GTKMM_MINOR_VERSION < 10) || GTKMM_MAJOR_VERSION < 2
32 gdk_cairo_set_source_color(context->cobj(),
33 const_cast<GdkColor*>(color.gobj()));
34 #else
35 set_source_color(context, color);
36 #endif
37 }
38 }
39 }
40 #endif

  ViewVC Help
Powered by ViewVC