which GUI tool to use?

P

phony

Hi all,

I am programming under Linux using c++. I need to visualize some
curves and 2-D graphs in my program. Is there any package to do this?
And I also need to add a user interfaces to my program. Could you also
suggest a tool for GUI? GTK+ and QT are popular. Which one is better
to use for normal program? Thanks a lot!


Best wishes!


Phony
 
P

Phlip

phony said:
I am programming under Linux using c++. I need to visualize some
curves and 2-D graphs in my program. Is there any package to do this?

Look up gnuplot. You should write a data file and a command file, then call
popen() or system() so gnuplot can eat them. It can create an X window
containing the output, and it can produce file outputs such as postscript -
possibly others. Then you can read the output files and host them in your
own windows.

If you need more interaction, look up BLT. But that can couple with Tk.
And I also need to add a user interfaces to my program. Could you also
suggest a tool for GUI? GTK+ and QT are popular. Which one is better
to use for normal program? Thanks a lot!

Tk is the most popular, and its Canvas and Text controls have an excellent
full-featured architecture. But the best hosts for Tk are Ruby or Perl or
Python. pTk binds with C, but I don't know how clean it is.

This leads to the question: Why C++? Because everyone else was using it? If
you just need some glue between components, and some logic, and some
visualizations, any lite language would be much more productive.

Warning: Specific questions about those systems will get the best answers on
newsgroups devoted to Linux, GNU, or those systems.
 
J

Jonathan Turkanis

phony said:
I am programming under Linux using c++. I need to visualize some
curves and 2-D graphs in my program. Is there any package to do this?
And I also need to add a user interfaces to my program. Could you also
suggest a tool for GUI? GTK+ and QT are popular. Which one is better
to use for normal program? Thanks a lot!

Hi,

People ask this type of question every day, and the response is
always the same: this is a newsgroup devoted to standard C++, which
does not include GUI facilities.

Just out of curiosity, how do you end up posting here without
reading a description of the group?

Regards,

Jonathan
 
K

Kevin Goodsell

Darius said:
where would one find a description of the group anyway?

The welcome message, posted 2 or 3 times a week. Or the FAQ, easily
located via any of the various FAQ archives, or by using Google (first
hit on "c++ faq").

And please don't top-post. See section 5 of the FAQ for more information.

-Kevin
 
H

Hendrik Belitz

phony said:
Hi all,

I am programming under Linux using c++. I need to visualize some
curves and 2-D graphs in my program. Is there any package to do this?
And I also need to add a user interfaces to my program. Could you also
suggest a tool for GUI? GTK+ and QT are popular. Which one is better
to use for normal program? Thanks a lot!

Now that's simple. Just test both options, e.g. with a simple dialog
application. I personally prefer QT, but GTK+ also has many advantages.

BTW: Asking such questions will not give you any useful answers most of the
time, but instead only results in flaming wars between ignorant people.
 
P

phony

Thanks a lot!

Actually, other groups related to Linux is in the second page of group
list. So I chose this group, which I think is the most related. :)

Best regards!

Phony
 
P

phony

Thanks a lot!

I found gnuplot is really nice. There are some c/c++ interfaces,
through which gunplot command could be sent from c/c++ program. Since
I want to display the time serials data, how about the speed of
displaying graphs very often (say 1 plot per second)?

Best regards!

phony
 
P

Phlip

phony said:
Actually, other groups related to Linux is in the second page of group
list. So I chose this group, which I think is the most related. :)

It would be nice if other posters would say this:

- your question would get a better answer on newsgroup X

- the question "what cross-platform library does Y" is on-topic here,
because we don't trust any other newsgroup to pick a good one.
But specific questions about Y belong on its newsgroup.

But they just say "get lost - this question is off-topic, because our topic
is Standard C++". That's too narrow to admit nearly any question, but its
benefit is they can remember it.

However, I don't know how to upgrade GnuPlot in real-time. I know that BLT
has interactive hooks for Tk. Why don't you use Python instead of C++? Did
you actually assess your need? Or did you use C++ just because it has such a
polite newsgroup?
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,755
Messages
2,569,537
Members
45,022
Latest member
MaybelleMa

Latest Threads

Top