From: Nasser M. Abbasi on
Hello;

I have not kept up with Ada for sometime. I was wondering, if someone wants
to develop a simple GUI (plots, menus, buttons, graphs, etc..) using Ada,
and have the code compile to a .exe on windows and linux, which is the
current most popular software pieces needed for the GUI?

Assuming I will be using GNAT. Which gcc version should I be using these
days which has the latest Ada support in it? Should I be using gcc directly
for Ada programming these days, or use GNAT GPL 2009 version from Libre web
site http://libre.adacore.com/libre/ ?

I know there are few choices for the GUI, and just wanted to check what is
the "best" choice do you think for that. One with a GUI builder would be
nice (i.e. where one can pick the components and lay them out to design the
interface). This will be an school program, nothing commercial. I wanted to
try to write some basic finite element code in Ada, but need a GUI part for
the simulation part.

Thanks,
--Nasser


From: Dmitry A. Kazakov on
On Fri, 18 Dec 2009 14:44:54 -0600, Nasser M. Abbasi wrote:

> I have not kept up with Ada for sometime. I was wondering, if someone wants
> to develop a simple GUI (plots, menus, buttons, graphs, etc..) using Ada,
> and have the code compile to a .exe on windows and linux, which is the
> current most popular software pieces needed for the GUI?

I guess that among portable frameworks the most popular ones with Ada
bindings are Gtk, Qt.

> Assuming I will be using GNAT. Which gcc version should I be using these
> days which has the latest Ada support in it? Should I be using gcc directly
> for Ada programming these days, or use GNAT GPL 2009 version from Libre web
> site http://libre.adacore.com/libre/ ?

AFAIK, for GtkAda either would go.

> I know there are few choices for the GUI, and just wanted to check what is
> the "best" choice do you think for that. One with a GUI builder would be
> nice (i.e. where one can pick the components and lay them out to design the
> interface). This will be an school program, nothing commercial. I wanted to
> try to write some basic finite element code in Ada, but need a GUI part for
> the simulation part.

As for Gtk, it has such a tool GLADE. I am using Gtk for a long time, but I
never felt any desire or necessity to use GLADE. I prefer to go rather OO,
designing custom widgets derived from Gtk containers, which is fairly
simple in Gtk (while many other things, trivial in other GUI frameworks are
unnecessary difficult in Gtk).

Gtk has a widget sizing model somewhat similar to TeX, this is an approach
in its core opposite to the GUI design tool. Imagine a text editor, in
which you would move each word of the text around paper in a way the sorts
were used in typesetting? Admittedly a design tool gives you some
approximate result quicker. But it is never good and never scalable.

--
Regards,
Dmitry A. Kazakov
http://www.dmitry-kazakov.de
From: Vadim Godunko on
On Dec 18, 11:44 pm, "Nasser M. Abbasi" <n...(a)12000.org> wrote:
>
> I know there are few choices for the GUI, and just wanted to check what is
> the "best" choice do you think for that.  One with a GUI builder would be
> nice (i.e. where one can pick the components and lay them out to design the
> interface). This will be an school program, nothing commercial. I wanted to
> try to write some basic finite element code in Ada, but need a GUI part for
> the simulation part.
>
As for Qt, it includes GUI development tool known as Qt Designer. In
contrast to Gtk+, Qt has very nice documentation and special tool to
navigate and to do search in it. QGraphicsView framework can be a
significant help to develop some kinds of 2D graphical application, Qt
includes integration with OpenGL also.
From: Nasser M. Abbasi on

"Dmitry A. Kazakov" <mailbox(a)dmitry-kazakov.de> wrote in message
>
>> Assuming I will be using GNAT. Which gcc version should I be using these
>> days which has the latest Ada support in it? Should I be using gcc
>> directly
>> for Ada programming these days, or use GNAT GPL 2009 version from Libre
>> web
>> site http://libre.adacore.com/libre/ ?
>
> AFAIK, for GtkAda either would go.
>

Thanks Dmitry;

I know now gcc supports GNAT ada. If I use gcc directly, instead of GPL GNAT
2009 edition, would I be losing any features? I am a bit confused why there
are different GNAT versions around. The reason if would prefer gcc is that
gcc is more likely to be installed on all Linux systems than GNAT itself, so
if someone wants to compile the code, they would not have to download GNAT
first, or is my thinking wrong on this? If I were to develope Ada code in
GNAT, then may be it will not compile with gcc due to some features not
being the same? I need to catch up on Ada, been a while...

I'll look at GTK for the GUI.

--Nasser


From: Nasser M. Abbasi on

"Vadim Godunko" <vgodunko(a)gmail.com> wrote in message
news:b10955e8-390b-4f44-abe5-d457a2012713(a)m3g2000yqf.googlegroups.com...
On Dec 18, 11:44 pm, "Nasser M. Abbasi" <n...(a)12000.org> wrote:
>
> I know there are few choices for the GUI, and just wanted to check what is
> the "best" choice do you think for that. One with a GUI builder would be
> nice (i.e. where one can pick the components and lay them out to design
> the
> interface). This will be an school program, nothing commercial. I wanted
> to
> try to write some basic finite element code in Ada, but need a GUI part
> for
> the simulation part.
>
"As for Qt, it includes GUI development tool known as Qt Designer. In
contrast to Gtk+, Qt has very nice documentation and special tool to
navigate and to do search in it. QGraphicsView framework can be a
significant help to develop some kinds of 2D graphical application, Qt
includes integration with OpenGL also."



Thanks Vadim for the info; I will look at Qt also. I always find a GUI
builder easier to use to layout components than doing that using just code.
Much less time, but may be not as flexible, but the time saving is worth it
for me.

--Nasser