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

List:       kde-devel
Subject:    How to make an extra toolbar?
From:       Robin Atwood <robin () binro ! org>
Date:       2009-06-28 12:58:54
Message-ID: 200906281958.54802.robin () binro ! org
[Download RAW message or body]

>In the KDE3 version of my app I created an extra toolbar with no associated
>menu simply by doing:
>
>	toolBar( "extra" )->insertButton(...)
>	toolBar( "extra" )->insertComboBox(...)
>
>I tried a similar thing with KDE4 by declaring a couple of KPushButton and
>KComboBox objects and adding them them via:
>
>	toolBar( "extra" )->addWidget( pb1 ), etc.
>
>Everything compiled cleanly, so imagine my dismay when after starting the
> app there was no sign of the new toolbar. :( Is it necessary for every
> toolbar to be configured in the XML rc file? Must I use actions rather than
> widgets?

I didn't get any reply on this so after days of examining the code and looking 
at the code in other apps and not finding the problem, I had suddenly had the 
insight to delete the ~/.kde/share/config/apprc file in my home directory. 
Then the new toolbar appeared. Toolbar setting are saved in apprc and all my 
experiments had completely munged it up. HTH some other n00b developer. :)

Cheers
-Robin
-- 
----------------------------------------------------------------------
Robin Atwood.

"Ship me somewheres east of Suez, where the best is like the worst,
 Where there ain't no Ten Commandments an' a man can raise a thirst"
         from "Mandalay" by Rudyard Kipling
----------------------------------------------------------------------










 
>> 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