Qt-jambi-interest Archive, April 2007
beta2 and juic - compiler
Message 1 in thread
Hello and gratulations to the beta2 of qt-jambi
A quick glance off the beta2 seems to fix a lot of bugs. But some of my
problems with the *.jui files made the decision to stay remain ...
The last time I had to change the (renamed) *.ui file via the generator
to *.jui. After this the teamwork of the designer and the juic -
compiler works fine (except some bugs within the layout). Now these bugs
seemed to be fixed, even the policy and margin problems.
But - I feel really sorry for that - now the integrated designer always
produces a *.jui file, which includes the following header
<ui version="4.0">
...
and from that, the juic- compiler builds an empty *.java file. Renaming
the file to *.ui and running the 'generator --convert-to-jui ...' on
that file finally builds the correct *.jui file, which was afterwards
converted to a well formed bugfree ui_xxx.java file.
If I made some changes with the designer, I have to repeat that step
again, caused to the fact, that the designer stores the (aboriginal)
file without the feature <language = "jambi">
So my question :
does I really need that step ? Should'nt the eclipse-plugin-designer
(the new one) be able create/store a correct file with the header
<ui version="4.0" language="jambi" >
...
(simply renaming that line doesnt work)
Or do I have to change anything in the eclipse plugins or the
environment variables ?
There is no difference using the plugin - designer or the designer in
the qtjambi dir.
best greetings
Arne
Message 2 in thread
Arne Stocker wrote:
>
>
> But - I feel really sorry for that - now the integrated designer
> always produces a *.jui file, which includes the following header
>
> <ui version="4.0">
> ...
>
> and from that, the juic- compiler builds an empty *.java file.
> Renaming the file to *.ui and running the 'generator --convert-to-jui
> ...' on that file finally builds the correct *.jui file, which was
> afterwards converted to a well formed bugfree ui_xxx.java file.
>
> If I made some changes with the designer, I have to repeat that step
> again, caused to the fact, that the designer stores the (aboriginal)
> file without the feature <language = "jambi">
>
> So my question :
>
> does I really need that step ? Should'nt the eclipse-plugin-designer
> (the new one) be able create/store a correct file with the header
>
> <ui version="4.0" language="jambi" >
Yes, the integrated designer should definitely create a correct file for
you. The --convert-to-jui tool is for porting legacy .ui files to Jambi,
but all the tools that are shipped with Jambi should produce
Jambi-compliant files.
The Eclipse integration needs to be able to load the native Qt Jambi
plugins as well as the Qt Jambi class files. If you are not getting the
"language=jambi" attribute in the first tag of the .jui file when you
save it, it means that the plugins have not been loaded correctly.
The first part should be automatic, as the native plugins are unpacked
into and loaded from plugins/com.trolltech.qtdesignerplugins in your
Eclipse directory when you unpack the Eclipse Integration package. In
order to find the class files, you need to set the path to your Qt Jambi
installation in the Eclipse preferences. If either step does not
succeed, you should see an error message saying something like "Cannot
load Qt Jambi plugins" or "Cannot find qtjambi.jar". Do you get any
error messages like this?
-- Eskil
Message 3 in thread
Hi Eskil
> "Cannot load Qt Jambi plugins" or "Cannot find qtjambi.jar". Do you get any error messages like this?
not really. The problem occurs as well, running the 'designer.exe'
directly from the '../qtjambi/bin' directory, that means the
'designer.exe' constructs the same code (as far as I could concern) as
the eclipse-designer-plugin (without the language="jambi" entry).
Here's a snapshot from the (designer.exe) Plugin-Information. It seems
to me, that all plugins are loaded.
my environments (system, not eclipse) but that should not annoy the
designer.exe :
PATH = C:\Entwickler\eclipse\qtjambi-win
QT_PLUGIN_PATH = C:\Entwickler\Eclipse\qtjambi-win\plugins
QTDIR = C:\Entwickler\Qt4\
JAMBI_INSTALL_DIR = C:\Entwickler\Eclipse\qtjambi-win
best regards
Arne
PS.: I'm currently using the eclipse - integration from the last beta (I
could not find an actual one on your website). Hope, I was'nt to stupid
to discover. But I think it was not especially an
eclipse-plugin-designer problem.


Message 4 in thread
Arne Stocker wrote:
>
> not really. The problem occurs as well, running the 'designer.exe'
> directly from the '../qtjambi/bin' directory, that means the
> 'designer.exe' constructs the same code (as far as I could concern) as
> the eclipse-designer-plugin (without the language="jambi" entry).
>
> Here's a snapshot from the (designer.exe) Plugin-Information. It seems
> to me, that all plugins are loaded.
It does look that way. Can you see any other signs that the Jambi
plugins are loaded? Such as:
1. Jambi examples in the widget box
2. Java syntax in the signals and slots editor
3. Java syntax in the property editor
4. Default to .jui as file name extension in the open/save dialogs?
> PS.: I'm currently using the eclipse - integration from the last beta
> (I could not find an actual one on your website). Hope, I was'nt to
> stupid to discover. But I think it was not especially an
> eclipse-plugin-designer problem.
>
There is a new Eclipse Integration almost all the way at the bottom of
the Qt Jambi Download Page (the same page where the different Qt Jambi
packages can be downloaded.) The old integration is not compatible with
the new Qt Jambi, so while this does not explain the problem you are
having in Designer, it could explain the problem in Eclipse. Could you
please try the new Eclipse integration to see if it solves the problem
for you there? The Eclipse Integration has some extra logic for finding
the plugins and resolving libraries etc. which could work around
whichever problems you may be having with standalone Designer.
-- Eskil
Message 5 in thread
Hi Eskil
first I changed the qtjambi-dir from 'qtjambi-win' to 'qtjambi'
C:\Entwickler\eclipse\qtjambi\
and set additionly the
LD_LIBRARY_PATH = C:\Entwickler\eclipse\qtjambi\lib
(as well as for Ecplise and the system) and receive
the attached message when starting the designer.exe (or designer.bat).
JAMBI_INSTALL_DIR = C:\Entwickler\Eclipse\qtjambi\
PATH = C:\Entwickler\eclipse\qtjambi\bin\;
C:\Entwickler\eclipse\qtjambi\
QT_PLUGIN_PATH = C:\Entwickler\Eclipse\qtjambi\plugins\
QTDIR = C:\Entwickler\Qt4
I hope, that I'm not wasting your time by overlook some very clearly
install-instructions. Is there any influence from other Qt
Installations. I uninstalled and reinstalled Qt4 (version 4.1.3) but the
problem seems to stay on
------------------------------------------------------------------------
The install of the eclipse plugin solved the problem. The plugin
designer builds a valid *.jui file :-)
The designer.exe (designer.bat) continues to communicate the message as
shown in the attachment.
thank you and greetings
Arne


Message 6 in thread
Hi, Arne.
Arne Stocker wrote:
>
>
> The install of the eclipse plugin solved the problem. The plugin
> designer builds a valid *.jui file :-)
>
> The designer.exe (designer.bat) continues to communicate the message
> as shown in the attachment.
The message you are receiving is usually produced when the plugins it
attempts to load are built against a binary incompatible version of Qt.
However. the designer.bat ought to make sure you are running against the
DLLs that are shipped with Jambi.
Could you please try running regedit and deleting the key
"HKEY_CURRENT_USER\Software\Trolltech\OrganizationDefaults\Qt Plugin
Cache 4.3.false" (make sure you do not delete anything else. You could
just rename the key instead if you are worried you might be losing
something, or back up your registry first.)
The plugins could have been marked as invalid in this registry entry,
due to the fact that you were running an old version of the Eclipse
Integration against a new version of Qt Jambi, and due to the fact that
the two Qt Jambi betas are based on two incompatible versions of Qt 4.3.
Usually, compatibility would be maintained and this would not happen,
but it's a result of the Qt Jambi betas being based on beta-versions of
Qt 4.3. Anyway, if you delete this entry, it will tell Qt Jambi to check
the plugins again, and Designer will hopefully load them correctly.
-- Eskil
Message 7 in thread
Hi Eskil
> deleting the key "HKEY_CURRENT_USER\Software\Trolltech\OrganizationDefaults\Qt Plugin Cache 4.3.false"
perfect ! It did the job for the designer.exe :-)
thank you
Arne