Alexander Neundorf neundorf at
Tue Nov 14 00:14:28 GMT 2006

Hi Dirk, 

thanks for looking at it.

On Monday 13 November 2006 14:35, you wrote:
> On Sunday 12 November 2006 02:41, Alexander Neundorf wrote:
> > fix #15876: if a file name contains a newline, the newline was displayed
> > in the status bar, which m
> This looks a bit like a wrong fix to me. it should use prettyURL() which
> should have fixed this issue already..


int main()
   KURL url("\nphp");
   QString pretty=url.prettyURL();
   QString filename=url.fileName();
   cout<<"pretty: -"<<pretty.latin1()<<"- name: -"<<filename.latin1

   KURL url2(filename);
   QString pretty2(url2.prettyURL());
   cout<<"pretty2: -"<<pretty2.latin1()<<"-"<<endl;
   return 0;


~/src/tests/kde3kurl$ ./hello
pretty: - name: -main.
pretty2: -main.

So it seems prettyURL()/lazy_encode() doesn't handle the newline. Or maybe 
it's just that KURL::bMalFormed is true, since just the filename is probably 
no valid URL, is it ?
So, do I really have to do something like 
url.prettyURL().mid(url.prettyURL().findRev('/')); or something like this ?

Work: alexander.neundorf AT -
Home: neundorf AT                -
      alex AT               -

More information about the kde-core-devel mailing list