Re: Porting Between Linux and Windows
- From: Chris Vine <chris cvine freeserve co uk>
- To: Allin Cottrell <cottrell wfu edu>
- Cc: gtk-app-devel-list gnome org, Eric Tavenner <estavenner gmail com>
- Subject: Re: Porting Between Linux and Windows
- Date: Sun, 24 Jun 2012 00:42:02 +0100
On Sat, 23 Jun 2012 18:13:41 -0400 (EDT)
Allin Cottrell <cottrell wfu edu> wrote:
You say you're learning C++. If you have good reason to do that,
then fine, but note that GTK itself is written in C and is
C-oriented. Using C++ will complicate matters. You say you're new to
this, so let me point out that C and C++ are separate languages and
although C++ interfaces for GTK are available (gtkmm) the more
standard development path is to use C with GTK.
To put the counter argument for someone who says he is a newbie, I
think you are looking at this from the wrong direction. The GTK+
headers are in the subset common to C and C++, and can be used in
either language (there is also no need to use gtkmm in C++, and
sometimes good reasons not to do so).
The real question is what language best suits the problem space the
program is trying to solve. For some things, C++ is better (in my
opinion). With C++11 auto variables, variadic templates and particularly
lambda expressions, it is quicker to write code for some problem areas
using C++ than C. The GTK+ code you write for a graphical interface
will look pretty much the same in either language, if you are not using
a wrapper, for the reasons I have mentioned.
In other words, GTK+ is the servant and not the master in language
choice here.
Chris
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]