LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Programming (https://www.linuxquestions.org/questions/programming-9/)
-   -   Is firefox written in GTK or QT ? (https://www.linuxquestions.org/questions/programming-9/is-firefox-written-in-gtk-or-qt-873420/)

vzxen 04-06-2011 02:48 PM

Is firefox written in GTK or QT ?
 
Hi,

I wanted to develop a cross platform GUI application.
So I thought I would research on Firefox.
I havent been able to find out which GUI framework is FireFox using ??
Is it GTK, QT, or what ?

Please assist.

dugan 04-06-2011 02:49 PM

GTK.

It also uses Mozilla's own higher-level UI toolkit, which is called XUL.

cascade9 04-06-2011 02:53 PM

Quote:

The Mozilla toolkit has a backend that uses the Qt application and UI framework from Nokia. There were several attempts at this prior to the current Mozilla code for Qt version 4.x.

As of February 2010 Mozilla Corp does not ship products using the Qt backend, but individuals have produced Firefox and Fennec builds using it. Search wiki.mozilla.org for engineers' notes on building software using this backend.
https://wiki.mozilla.org/Qt

I dont know, but it might be useful info for you vzxen.

vzxen 04-06-2011 03:02 PM

Hi,

"As of February 2010 Mozilla Corp does not ship products using the Qt backend"
So what does it use now ??

Is GTK used by firefox even on mac or windows ?

dugan 04-06-2011 03:06 PM

Quote:

Originally Posted by vzxen (Post 4316243)
Is GTK used by firefox even on mac or windows ?

Not on Mac, according to this link:

http://boomswaggerboom.wordpress.com...nder-the-hood/

If you want to use the same cross-platform toolkit that Firefox is using then you do not use GTK or Qt. You use XUL (which on Linux is a layer above GTK) and write it as a XULRunner app.

vzxen 04-06-2011 03:10 PM

Hi,

There are lots of confusing links like these which this and that about Mozilla.

At the end of the day I just want to know whether can we develop STANDALONE GUI Applications (Compiled into binaries) using Mozilla ?
THAT is : IS Mozilla having a GUI Framework like QT, wxWidgets ?

dugan 04-06-2011 03:13 PM

Quote:

Originally Posted by vzxen (Post 4316253)
There are lots of confusing links like these which this and that about Mozilla.

How unbelievably rude. You just said you weren't willing to look at any of the links posted.

Quote:

At the end of the day I just want to know whether can we develop STANDALONE GUI Applications (Compiled into binaries) using Mozilla ?
THAT is : IS Mozilla having a GUI Framework like QT, wxWidgets ?
Yes. See all of my previous posts in this thread.

vzxen 04-06-2011 03:19 PM

Hi,

I am sorry, I didnt mean to be rude in any sense sir.
I read that article link posted by you.
Well, I got a little more confused. It says that Gecko is written in Cocoa. Then how does Gecko work on Windows ?
Is there a Gecko implementation for each platform ?

Also XUL (I am assuming XULRunner) as you said is the Higher Level API of Mozilla is for XML Based designing right ?
How does one compile that ?
I was going through Firefoxs files on Windows and didnt find any XUL based XML definitions. Just a xul.dll

Again, I didnt mean to be rude sir.

dugan 04-06-2011 03:28 PM

Firefox definitely uses GTK on Linux. It uses Cocoa on Mac OS. So yes, there is a separate implementation for each platform.

If you want to make your own cross-platform app, you probably don't want to do it the way Firefox did it. You probably want to write it once and just recompile it for each platform. You can do that with either GTK or Qt, although I'm personally a big fan of Qt.

If you must do it the way Firefox did it, then write a XULRunner app. Instructions are on the MDC. But I would recommend just using Qt.

vzxen 04-06-2011 03:33 PM

Hi,

What is better for commercial apps QT or wxWidgets ?
I am a little unclear with Qts Commercial license.
If I want to sell my QT developed Application will I need to buy a License from QT or will I need to buy a License from QT only if I modify QTs source codes and then develop my app using QTs modified sources ?

dugan 04-06-2011 03:41 PM

Qt is better than WxWidgets.

As for Qt's licensing conditions: you did read this page, right?

http://qt.nokia.com/products/licensing/

You certainly don't need a commercial license to sell an app you developed with Qt. You don't even need a commercial license to modify Qt. You will, however, need one if you're planning to modify Qt and then keep your modified version of Qt to yourself.

vzxen 04-06-2011 03:48 PM

Hi,

I did read that page sir.
I dont understand the Part "The commercial license will be required if you modify QT and want to keep the modifications with me"
Does developing a Desktop Application mean modifying QT. If my Application is a commercial one and I dont want to share the sources will I need to license QT commercial license ?
As far as I understand I guess we dont because developing a GUI app using QT doesnt amount to modifying QT right ?

Then what does modifying QT amount to ? Modifying QTs libraries itself, like its bindings and its SOURCE ? Am I right in assuming this ?

dugan 04-06-2011 03:56 PM

Your assumption is correct.

In most cases, your application will simply link against Qt. Linking against Qt does not involve modifying Qt. You don't need a commercial license for that.

In extreme cases, you might have to edit Qt's source code in order to make part of your application work. That's what it means to modify Qt. If you're willing to make your modified version of Qt available to people outside of your organization or company, then you don't need the commercial license. If you're not willing to give people outside of your company access to your changed version of Qt, then you do need the commercial license.

vzxen 04-06-2011 04:03 PM

Hi,

Thanks for the clarification.

Another newbie question I have is that, does QT act like XULRunner ?
Will the app depend on QT binary of any sort ?
OR
Will it be a STANDALONE Destop Application like a standard Win32 Application (if developed in VC++)

dugan 04-06-2011 04:06 PM

Qt apps are standalone applications.

BTW, if you still want details about Firefox' GUI framework, this is a great overview:

http://www.kodewerx.org/wiki/A_Brief...Runner:_Part_1


All times are GMT -5. The time now is 04:20 PM.