[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-devel
Subject:    Re: using QtCreator/Designer .ui form with KDE
From:       Jan Kalcic <jandot () googlemail ! com>
Date:       2012-02-11 18:07:39
Message-ID: 4F36AE6B.8070003 () gmail ! com
[Download RAW message or body]

On 02/11/2012 10:24 AM, Kevin Krammer wrote:
> On Saturday, 2012-02-11, Jan Kalcic wrote:
>> Hi there,
>>
>> It is a bit I am getting to know Qt developing small and almost useless
>> applications just to practice, particularly using Qt Creator (I find it
>> very easy, intuitive, powerful and also cool BTW)
>>
>> Now I have one app which I am starting to take more seriously and with
>> this I would like to "swtich" to KDE classes. It seems to be not too
>> difficult but I still have a missing point. I assume it is possible to
>> use .ui forms created with QtCreator/Designer and I also assume that the
>> .ui file which is converted in the header file by the UIC (invoked
>> automatically by qmake) is the same XML file I can use as .rc file
>> (needed by KXMLGUIClient). Am I wrong? I am sure I am as it does not
>> work and it also seems the two XML files actually have difference syntax.
>>
>> So how can this be achieved?
> As Andreas already said those two are independent and for different purposes.
>
> You continue to use your .ui files the same way you do in a normal Qt
> application.
>
> KXMLGUIClient stuff is mainly for the main window's menu's and toolbars, a main
> window's content will in most cases still be a designer created widget.
Understand, now I see where I was wrong. I have just stripped out from 
the constructor the ui->setupUi(this); as I thought the 
setupGUI(Default); was the replacement. Instead I need them both, the 
first one to generate the User Interface and second one to add menus 
toolbars etc etc..

What it was actually misleading was the fact the GUI did not appear, 
without throwing any error BTW, when I was trying to not setup the Ui 
with ui->setupUi(this);
Now I see the problem was instead the function setCentralWidget(this); 
when this is called the GUI still does not appear. I still need to 
investigate why, do not if you guys have any suggestion..

Thanks
Jan



>> Visit http://mail.kde.org/mailman/listinfo/kde-devel#unsub to unsubscribe <<
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic