Dr. Dobb's is part of the Informa Tech Division of Informa PLC

This site is operated by a business or businesses owned by Informa PLC and all copyright resides with them. Informa PLC's registered office is 5 Howick Place, London SW1P 1WG. Registered in England and Wales. Number 8860726.


Channels ▼
RSS

C/C++

Qt Jambi: Rich Client Dev Framework for Java


DDJ: We're talking today with Naren Karattup, product director of development tools at Trolltech.

Naren, I originally thought that Qt Jambi was Qt for Java. But it turns out that Jambi has a toolset for C++ developers too. So why would a C++ programmer use Qt Jambi instead of Qt?

NK: Java is an intuitive programming language generally considered -- and designed especially to be -- much less error prone than C++. Thus, it might be deemed both safer and easier to employ this programming language as the foundation for a software project. However, Java lacks power in areas such as accessing platform or hardware specific features, memory management and per-instruction speed optimizations. Also, a company may have legacy code written in C++, making the company less interested in rewriting in a new language.

To allow programmers to combine their C++ code with Java code, Qt Jambi has a tool which will establish a Java API based on C++ header files.

DDJ: Qt Jambi appears to offer an alternative to Swing. If I have existing Swing-based applications, can I port them to Qt Jambi?

NK: Yes, you can. Qt Jambi lets you combine Swing top-level windows with Qt Jambi top-level windows to make the porting process easier. The Qt Jambi team is also researching the possibility of combining the libraries on a widget basis (Swing widgets as children of Qt Jambi widgets and vice versa).

DDJ: What was the most challenging aspect of building Qt Jambi?

NK: The most challenging aspect has been the subtle, but quite immense differences between the C++ and Java languages. C++ is a lower level language than Java, and supports a great range of programming language mechanisms that are not available to Java programmers. Examples of such mechanisms are: Manual memory management, address by pointer, pass-by-value function calls, heterogeneous generics, multiple inheritance, non-virtual functions, function shadowing, function pointers, preprocessing, and many more. Mapping an API that uses these mechanisms into a language that does not support them has by far been the greatest challenge, although it has also been the most interesting part of the project. In the end, the Qt Jambi team has found good, intuitive solutions for all these inherent binding problems, and has created a Java version of the Qt API which expresses the same concepts and ideas as its original, despite the failure of Java to be able to express the same API concepts as C++.

DDJ: What's the #1 problem that Qt Jambi solves for developers?

NK: Java has failed to some extent in becoming a programming language for making desktop applications. Compared to other languages, there are very few successful desktop applications available that are written in Java.

We believe this is due to the lack of available tools that are good enough, intuitive enough and convenient enough to make Java attractive as a desktop application platform. This is where Qt Jambi shines the most. Qt Jambi is a well-documented, intuitive, and professionally supported toolkit, which lets programmers focus their energy on solving the specific problems and tasks of their own applications, instead of having to fight against their toolkit to make it do what they want. Qt Jambi is flexible and powerful while still maintaining a great degree of readability and sensible default behavior.

It will help make the routine work of application developers easier, faster, and more pleasant.

DDJ: Anything else?

NK: For more information and to download a free 30-day trial of Qt Jambi, readers can visit www.trolltech.com/products/qt/jambi.


Related Reading


More Insights






Currently we allow the following HTML tags in comments:

Single tags

These tags can be used alone and don't need an ending tag.

<br> Defines a single line break

<hr> Defines a horizontal line

Matching tags

These require an ending tag - e.g. <i>italic text</i>

<a> Defines an anchor

<b> Defines bold text

<big> Defines big text

<blockquote> Defines a long quotation

<caption> Defines a table caption

<cite> Defines a citation

<code> Defines computer code text

<em> Defines emphasized text

<fieldset> Defines a border around elements in a form

<h1> This is heading 1

<h2> This is heading 2

<h3> This is heading 3

<h4> This is heading 4

<h5> This is heading 5

<h6> This is heading 6

<i> Defines italic text

<p> Defines a paragraph

<pre> Defines preformatted text

<q> Defines a short quotation

<samp> Defines sample computer code text

<small> Defines small text

<span> Defines a section in a document

<s> Defines strikethrough text

<strike> Defines strikethrough text

<strong> Defines strong text

<sub> Defines subscripted text

<sup> Defines superscripted text

<u> Defines underlined text

Dr. Dobb's encourages readers to engage in spirited, healthy debate, including taking us to task. However, Dr. Dobb's moderates all comments posted to our site, and reserves the right to modify or remove any content that it determines to be derogatory, offensive, inflammatory, vulgar, irrelevant/off-topic, racist or obvious marketing or spam. Dr. Dobb's further reserves the right to disable the profile of any commenter participating in said activities.

 
Disqus Tips To upload an avatar photo, first complete your Disqus profile. | View the list of supported HTML tags you can use to style comments. | Please read our commenting policy.