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

List:       kde-core-devel
Subject:    Re: use of namespaces in KDE (was: Re: koffice/kimageshop/tools)
From:       m_elter () t-online ! de (Matthias Elter)
Date:       1999-12-23 16:10:16
[Download RAW message or body]

Matthias Elter wrote:
> 
> Harri Porten wrote:
> >
> > CVS by elter wrote:
> (...)
> > > Log Message:
> > > Core classes are now prefixed with "Kis" to avoid name clashes.
> >
> > How about a namespace ? Makes the code a bit less ugly.
> 
> Yes I know, but unfortunately I get name clashes with KParts in classes
> like Kis::Doc.
> IMO its very bad to name classes in kdelibs "View" "Shell" or "Doc". Can
> this be moved into a namespace for the new kparts or at least make it
> use a class prefix like "KP"? I'm going to rename my stuff to
> "Kis::_Doc" for now.
> 
> By the way, I don't like the fact that KDE is using namespaces _and_
> class prefixes. Can we agree on a standard to use only namespaces _or_
> prefixes. With namespace support in most modern c++ compilers I vote for
> namespaces.


I forgot about this:
The new kparts in kdenonbeta/kparts is not a replacement for the
Doc/View model found in kdelibs/kparts. kdenonbeta/kparts is only a
replacement for the embedding/xml-gui part. The Doc/View model found in
kdelibs/kparts will be based on kdenonbeta/kparts and moved to
koffice/lib. So simply waiting for the new kparts does not solve the
problem. We have to rename the classes I mentioned sooner or later. As I
favour a namespace, one solution that comes to my mind is to put
kdelibs/kparts in a namespace and to use "using Kparts" in koffice for
now.


Greetings, Matthias

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

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