By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
458,127 Members | 1,154 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 458,127 IT Pros & Developers. It's quick & easy.

Dipping my toes in cross-platform GUI

P: n/a

I don't know the first thing about cross-platform GUI programming, so
I'd like to ask a few quick questions.

Which library is best for someone who appreciates portable programming
and correct efficient code, and who'd like the library to fit well with the
C++ Standard Library? Also I'd like the library to work on as many
platforms as possible (Windows, Linux, Mac, and even the new game consoles
such as Playstation 3 and XBox 360 if possible).

I've heard of wxWidgets and Qt, but I haven't a clue what they're like.
I've seen the cross-platform media player, VLAN; it uses wxWidgets and it
looks good. What GUI libraries are all the well-known programs using, such
as Mozilla, Xilinx?

Is there any cross-platform networking library that stands head and
shoulders above the rest?

--
Tomás Ó hÉilidhe
Jan 8 '08 #1
Share this Question
Share on Google+
12 Replies


P: n/a
On Mon, 07 Jan 2008 21:45:17 -0500, Victor Bazarov wrote:
Tomás Ó hÉilidhe wrote:
> I don't know the first thing about cross-platform GUI programming,
so I'd like to ask a few quick questions.

Which library is best for someone who appreciates portable
programming and correct efficient code, and who'd like the library to
fit well with the C++ Standard Library? Also I'd like the library to
work on as many platforms as possible (Windows, Linux, Mac, and even
the new game consoles such as Playstation 3 and XBox 360 if possible).

I've heard of wxWidgets and Qt, but I haven't a clue what they're
like. I've seen the cross-platform media player, VLAN; it uses
wxWidgets and it looks good. What GUI libraries are all the well-known
programs using, such as Mozilla, Xilinx?

Is there any cross-platform networking library that stands head and
shoulders above the rest?

I'll tell you my experience. Take it at its face value.
[...]

Bravo Victor!

I hereby declare any further discussion on this topic, including future
threads, closed.

--
Lionel B
Jan 8 '08 #2

P: n/a
"Lionel B" <me@privacy.netwrote in message
news:h6*******************@newsfe1-win.ntli.net...
On Mon, 07 Jan 2008 21:45:17 -0500, Victor Bazarov wrote:
>Tomás Ó hÉilidhe wrote:
>> I don't know the first thing about cross-platform GUI programming,
so I'd like to ask a few quick questions.

Which library is best for someone who appreciates portable
programming and correct efficient code, and who'd like the library to
fit well with the C++ Standard Library? Also I'd like the library to
work on as many platforms as possible (Windows, Linux, Mac, and even
the new game consoles such as Playstation 3 and XBox 360 if possible).

I've heard of wxWidgets and Qt, but I haven't a clue what they're
like. I've seen the cross-platform media player, VLAN; it uses
wxWidgets and it looks good. What GUI libraries are all the well-known
programs using, such as Mozilla, Xilinx?

Is there any cross-platform networking library that stands head and
shoulders above the rest?

I'll tell you my experience. Take it at its face value.

[...]

Bravo Victor!

I hereby declare any further discussion on this topic, including future
threads, closed.
:^)

Jan 8 '08 #3

P: n/a
"Tomás Ó hÉilidhe" <to*@lavabit.comwrote in
news:Xn**************************@194.125.133.14:
>
I don't know the first thing about cross-platform GUI programming,
so
I'd like to ask a few quick questions.

Which library is best for someone who appreciates portable
programming
and correct efficient code, and who'd like the library to fit well
with the C++ Standard Library? Also I'd like the library to work on as
many platforms as possible (Windows, Linux, Mac, and even the new game
consoles such as Playstation 3 and XBox 360 if possible).

I've heard of wxWidgets and Qt, but I haven't a clue what they're
like.
I've seen the cross-platform media player, VLAN; it uses wxWidgets and
it looks good. What GUI libraries are all the well-known programs
using, such as Mozilla, Xilinx?

Is there any cross-platform networking library that stands head
and
shoulders above the rest?
Victor answered quite well the main thrust of your question, so I
thought I would throw in a few thoughts about portable gui-s in general.
Have you ever noticed that you can generally pick out a java app from a
mile away? The problem is that while they have a wonderful api that is
portable everywhere a compatible JVM exists, they all have a certain
look and feel and that look and feel doesn't quite fit anywhere.

Each of the OS's you mention have certain expectations for the look and
feel of a program. Everything from the location of menu items to how
you browse for files is generally specified in the OS's look and feel
guide. Applications that are targeted toward non-computer people
generally follow the OS's guide unless they have a good reason to
deviate from it.

The mentioned GUI libraries do a wonderful job of making portable
widgets, but are generally less fantastic about whether the actual look
and feel matches the platform the user is running. For certain things,
this is ok, but for others this can be a real pain in the backside of
your users.

So, the advice is that if you really want to do your portability right,
you will strive to separate your business logic from your GUI and
implement things in your GUI such that the look and feel matches user
expectations. Of course, by the time you do this the portable GUI
libraries make less difference. If your application doesn't really have
much of a user interface, then you might get away without this
separation, but at least think about it.

joe
Jan 8 '08 #4

P: n/a
"Victor Bazarov" <v.********@comAcast.netwrote in comp.lang.c++:
Here is the advice part of the story. Pick one and learn it. Use
it to the best of your ability; they are all equally capable when
employed properly.

I read what your wrote Victor, and it was helpful. Not to sound naive
though... but could someone just throw a library name at me? I don't need a
review of the library, just even "You'll be on the right track if you go
with X". Right now I'm thinking of going with wxWidgets.

--
Tomás Ó hÉilidhe
Jan 8 '08 #5

P: n/a
Tomás Ó hÉilidhe wrote:
"Victor Bazarov" <v.********@comAcast.netwrote in comp.lang.c++:
>Here is the advice part of the story. Pick one and learn it. Use
it to the best of your ability; they are all equally capable when
employed properly.


I read what your wrote Victor, and it was helpful. Not to sound
naive though... but could someone just throw a library name at me? I
don't need a review of the library, just even "You'll be on the right
track if you go with X". Right now I'm thinking of going with
wxWidgets.
James mentioned Qt and wxWidgets. Go to their sites and look at
their capabilities. Perhaps they even list some comparative
advantages of one over the other. I've used Qt, I've not used
wxWidgets. If I were to create another GUI app to target more
than one platform, that's what I'd use. But it's not because Qt
is objectively better, it's because I have some experience with
Qt and it *did the job*. I simply don't want to waste time to
learn another library that does pretty much the same thing.

Again, I am not speaking in favor of one or the other; you've asked
to throw a name at you, so here.

V
--
Please remove capital 'A's when replying by e-mail
I do not respond to top-posted replies, please don't ask
Jan 8 '08 #6

P: n/a
"Victor Bazarov" <v.********@comAcast.netwrote in comp.lang.c++:
James mentioned Qt and wxWidgets. Go to their sites and look at
their capabilities.

I started using wxWidgets about an hour ago and I'm already making great
progress... the interface couldn't be easier! Plus I love its class
structure, makes it very easy to do stuff :-D

--
Tomás Ó hÉilidhe
Jan 8 '08 #7

P: n/a
On 2008-01-08 14:39, Joe Greer wrote:
"Tom疽 モ hノilidhe" <to*@lavabit.comwrote in
news:Xn**************************@194.125.133.14:
>>
I don't know the first thing about cross-platform GUI programming,
so
I'd like to ask a few quick questions.

Which library is best for someone who appreciates portable
programming
and correct efficient code, and who'd like the library to fit well
with the C++ Standard Library? Also I'd like the library to work on as
many platforms as possible (Windows, Linux, Mac, and even the new game
consoles such as Playstation 3 and XBox 360 if possible).

I've heard of wxWidgets and Qt, but I haven't a clue what they're
like.
I've seen the cross-platform media player, VLAN; it uses wxWidgets and
it looks good. What GUI libraries are all the well-known programs
using, such as Mozilla, Xilinx?

Is there any cross-platform networking library that stands head
and
shoulders above the rest?

Victor answered quite well the main thrust of your question, so I
thought I would throw in a few thoughts about portable gui-s in general.
Have you ever noticed that you can generally pick out a java app from a
mile away? The problem is that while they have a wonderful api that is
portable everywhere a compatible JVM exists, they all have a certain
look and feel and that look and feel doesn't quite fit anywhere.

Each of the OS's you mention have certain expectations for the look and
feel of a program. Everything from the location of menu items to how
you browse for files is generally specified in the OS's look and feel
guide. Applications that are targeted toward non-computer people
generally follow the OS's guide unless they have a good reason to
deviate from it.

The mentioned GUI libraries do a wonderful job of making portable
widgets, but are generally less fantastic about whether the actual look
and feel matches the platform the user is running. For certain things,
this is ok, but for others this can be a real pain in the backside of
your users.
I would like to disagree, at least with Qt you can make applications
that looks and feels like native applications (at least for Unix and
Windows, I have never targeted Mac). The problem is that since the look
and feel differs between different systems there are some occasions
where it is not enough to have the right look and feel on the individual
widgets, it is a question about overall layout. In these cases you have
to choose one system and let the others be what they become since the
alternative is to have different layouts for each system (which in most
cases is overkill).

--
Erik Wikström
Jan 8 '08 #8

P: n/a
=?UTF-8?B?RXJpayBXaWtzdHLDtm0=?= <Er***********@telia.comwrote in
news:ys*****************@newsb.telia.net:
>>
Victor answered quite well the main thrust of your question, so I
thought I would throw in a few thoughts about portable gui-s in
general. Have you ever noticed that you can generally pick out a
java app from a mile away? The problem is that while they have a
wonderful api that is portable everywhere a compatible JVM exists,
they all have a certain look and feel and that look and feel doesn't
quite fit anywhere.

Each of the OS's you mention have certain expectations for the look
and feel of a program. Everything from the location of menu items to
how you browse for files is generally specified in the OS's look and
feel guide. Applications that are targeted toward non-computer
people generally follow the OS's guide unless they have a good reason
to deviate from it.

The mentioned GUI libraries do a wonderful job of making portable
widgets, but are generally less fantastic about whether the actual
look and feel matches the platform the user is running. For certain
things, this is ok, but for others this can be a real pain in the
backside of your users.

I would like to disagree, at least with Qt you can make applications
that looks and feels like native applications (at least for Unix and
Windows, I have never targeted Mac). The problem is that since the
look and feel differs between different systems there are some
occasions where it is not enough to have the right look and feel on
the individual widgets, it is a question about overall layout. In
these cases you have to choose one system and let the others be what
they become since the alternative is to have different layouts for
each system (which in most cases is overkill).
You disagree and yet your arguments line up with what I said. I am confused.
To what exactly are you disagreeing?

joe
Jan 8 '08 #9

P: n/a
On 2008-01-08 20:55, Joe Greer wrote:
=?UTF-8?B?RXJpayBXaWtzdHLDtm0=?= <Er***********@telia.comwrote in
news:ys*****************@newsb.telia.net:
>>>
Victor answered quite well the main thrust of your question, so I
thought I would throw in a few thoughts about portable gui-s in
general. Have you ever noticed that you can generally pick out a
java app from a mile away? The problem is that while they have a
wonderful api that is portable everywhere a compatible JVM exists,
they all have a certain look and feel and that look and feel doesn't
quite fit anywhere.

Each of the OS's you mention have certain expectations for the look
and feel of a program. Everything from the location of menu items to
how you browse for files is generally specified in the OS's look and
feel guide. Applications that are targeted toward non-computer
people generally follow the OS's guide unless they have a good reason
to deviate from it.

The mentioned GUI libraries do a wonderful job of making portable
widgets, but are generally less fantastic about whether the actual
look and feel matches the platform the user is running. For certain
things, this is ok, but for others this can be a real pain in the
backside of your users.

I would like to disagree, at least with Qt you can make applications
that looks and feels like native applications (at least for Unix and
Windows, I have never targeted Mac). The problem is that since the
look and feel differs between different systems there are some
occasions where it is not enough to have the right look and feel on
the individual widgets, it is a question about overall layout. In
these cases you have to choose one system and let the others be what
they become since the alternative is to have different layouts for
each system (which in most cases is overkill).

You disagree and yet your arguments line up with what I said. I am confused.
To what exactly are you disagreeing?
My point was that they can match the look and feel of a platform, but
seldom more than one. It might have been what you were saying but the
way I read your post you were saying that they can not get the look and
feel right on any platform.

--
Erik Wikström
Jan 8 '08 #10

P: n/a
=?UTF-8?B?RXJpayBXaWtzdHLDtm0=?= <Er***********@telia.comwrote in
news:91*****************@newsb.telia.net:
>
My point was that they can match the look and feel of a platform, but
seldom more than one. It might have been what you were saying but the
way I read your post you were saying that they can not get the look
and feel right on any platform.
Ahhhh. No, I wasn't trying to say that. What I was trying to say is that it is hard to get
the look and feel right on every platform. Usually the program looks good on the platform
it is developed on, and just a little out of place everywhere else.
joe
Jan 9 '08 #11

P: n/a
Joe Greer wrote:
=?UTF-8?B?RXJpayBXaWtzdHLDtm0=?= <Er***********@telia.comwrote in
news:91*****************@newsb.telia.net:
>>
My point was that they can match the look and feel of a platform, but
seldom more than one. It might have been what you were saying but the
way I read your post you were saying that they can not get the look
and feel right on any platform.

Ahhhh. No, I wasn't trying to say that. What I was trying to say is
that it is hard to get the look and feel right on every platform.
Usually the program looks good on the platform it is developed on,
and just a little out of place everywhere else.
I think you hit very close to the bullseye. IME, the program looks
good on the platform where the portable GUI library originated.

V
--
Please remove capital 'A's when replying by e-mail
I do not respond to top-posted replies, please don't ask
Jan 9 '08 #12

P: n/a
On Jan 8, 5:35 am, "Tomás Ó hÉilidhe" <t...@lavabit.comwrote:
I don't know the first thing about cross-platform GUI programming, so
I'd like to ask a few quick questions.

Which library is best for someone who appreciates portable programming
and correct efficient code, and who'd like the library to fit well with the
C++ Standard Library? Also I'd like the library to work on as many
platforms as possible (Windows, Linux, Mac, and even the new game consoles
such as Playstation 3 and XBox 360 if possible).

I've heard of wxWidgets and Qt, but I haven't a clue what they're like..
I've seen the cross-platform media player, VLAN; it uses wxWidgets and it
looks good. What GUI libraries are all the well-known programs using, such
as Mozilla, Xilinx?

Is there any cross-platform networking library that stands head and
shoulders above the rest?

--
Tomás Ó hÉilidhe
Why not Gtkmm (site: http://www.gtkmm.org/ a C++ wrapper over GTK)? It
is purely an GUI library - nothing more, nothing less. Whereas
wxWidgets and Qt are not JUST gui libraries. They have xml parsing
code (it is very basic with SAX and DOM interfaces don't support
Schemas or XSLT - hence I recommend to use Xerces or libxml2 for your
xml code instead of Qt's xml library), networking api, database api
(for Qt) and even Vectors, Lists, Maps their own String classes (like
QString in Qt). Why do you as a these with your gui library. There are
excellent Boost libraries (or open source libraries) to do most of
these in a very better way. No pointing in learning these again. If
you are only interested in GUI application, Gtkmm is a clean api. It
works fine on Windows and excellent on Linux (and UNIX systems like
Solaris, FreeBSD) - I am not sure how it look on Mac.
Glade library (http://glade.gnome.org/) can even make things better.
It generates Glade XML which can be used in C, C++, Python or even in
Java (From their site: By using libglade, Glade XML files can be used
in numerous programming languages including C, C++, Java, Perl,
Python, C#, Pike, Ruby, Haskell, Objective Caml and Scheme. Adding
support for other languages is easy too.), making Gtk not only a cross-
platform UI library but even language independent.
Tomorrow if you want to migrate your C++ project to Java (or Python),
no need to do anything with your Glade XML UI - it is already
portable.

I recommend to have a look at Gtkmm and Glade.

Jan 15 '08 #13

This discussion thread is closed

Replies have been disabled for this discussion.