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

List:       kde-core-devel
Subject:    Re: New i18n interface for KDE 4, second try
From:       Ingo =?iso-8859-15?q?Kl=F6cker?= <kloecker () kde ! org>
Date:       2005-10-30 15:30:13
Message-ID: 200510301630.14245 () erwin ! ingo-kloecker ! de
[Download RAW message or body]


On Sunday 30 October 2005 16:05, Nicolas Goutte wrote:
> On Sunday 30 October 2005 15:59, Ingo Klöcker wrote:
> > On Sunday 30 October 2005 15:51, Nicolas Goutte wrote:
> > > On Sunday 30 October 2005 15:37, Ingo Klöcker wrote:
> > > > On Sunday 30 October 2005 14:40, Chusslove Illich wrote:
> > >
> > > (...)
> > >
> > > > The multiple argument variant of QString::arg() only exists for
> > > > multiple QStrings so using something like
> > > >   QString("(x,y)=(%1,%2)").arg(3, 5)
> > >
> > > No, for integer numbers such a QString::arg would have another
> > > meaning:
> > >
> > > QString QString::arg ( long a, int fieldWidth = 0, int base = 10
> > > ) const
> >
> > Yeah, sorry. Bad example (or good example because it doesn't work
> > as one would expect if one only knows about QString::arg( const
> > QString & a1, const QString & a2 )). And I should have used
> >   QString("%1 %2 %3").arg( "foo", "bar", 5 )
> > as example.
>
> That is not a good example either, as the compiler cannot do anything
> with the integer as third parameter.

Well, that's the point I was trying to make. Currently something like 
this doesn't work and therefore I don't think we'd miss support for 
multiple non-QString arguments in the new i18n(). Chusslove proposed an 
i18n() variant which would accept
  i18n( "%1 %2 %3", "foo", "bar", 5 )
and I think that's not necessary. For me having to write
  i18n( "%1 %2 %3", "foo", "bar", QString::number( 5 ) )
instead would be perfectly alright.

Regards,
Ingo

[Attachment #3 (application/pgp-signature)]

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

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