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

List:       kde-core-devel
Subject:    Re: KTMainWindow: KDE2PORTING
From:       Waldo Bastian <bastian () kde ! org>
Date:       2000-09-01 17:37:46
[Download RAW message or body]

On Fri, 01 Sep 2000, Reginald Stadlbauer wrote:
> On Fri, 01 Sep 2000, Waldo Bastian wrote:
> > Please review... Is it me or is this whole API for toolbar/statusbar
> > hiding/showing butt-ugly?
>
> What is butt ugly if you have to call something->show() or
> something->hide() if you wont to show or hide something?

Well, I found out later that you could indeed use show()/hide() as well 
luclily this was well documented in several places (not). Remains the fact 
that you sometimes need to use toolBar() and sometimes toolBar("mainToolBar") 
depending on?? time of day? Phase of the moon? (Luckily we have kmoon)

> > <H3><A NAME="KTMainWindow">KTMainWindow</A></H3>
> >
> > KTMainWindow has been replaced with KMainWindow.<p>
> >
> > The KMainWindow constructor needs a parent widget as first argument.
> > You can use 0 for this.<p>
> > setView() has been replaced with setCentralWidget().<p>
> > view() has been replaced with centralWidget().<p>
> > setMenu(...) has been removed, it is not needed any more.<p>
> > setStatusBar(...) has been removed, it is not needed any more.<p>
> > enableStatusBar(...) has been removed, use statusBar()->show() and/or
> > statusBar()->hide() instead.<p>
> > enableToolBar(...) has been removed, use toolBar()->enable(...) instead.
> > The arguments can remain the same. You might need to use
> > toolBar("toolbar-name") instead of toolBar().
>
> You can just do toolbar()->show() or toolbar()->hide() as well, the
> toolbar->enable() is there for compatibility and does nothing more.

I just had a revolutionairy idea. Let's tell the rest of the developers about 
this as well by adding some comments to the header.

Cheers,
Waldo
-- 
KDE/Linux, Leading the Desktop Revolution.

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

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