[Konversation-devel] Fwd: konversation .protocol files

Eike Hein hein at kde.org
Wed May 16 17:15:59 UTC 2012



-------- Original Message --------
Subject: konversation .protocol files
Date: Wed, 16 May 2012 12:33:06 +0200
From: David Faure <faure at kde.org>
Organization: KDE
To: Eike Hein <hein at kde.org>

Hi Eike,

For kde frameworks 5, I'm reworking the implementation of KProtocolInfo, 
the
code that reads .protocol files, to extract this out of ksycoca.

For speed reasons, though, I would like the filename to match the protocol
name, so that we don't have to open all files just to find the right one.

Most existing .protocol files match this rule, but konversation's don't :-)

irc6 is defined in konvirc6.protocol
irc is defined in konvirc.protocol
ircs is defined in konvircs.protocol

Initially I was writing to ask you to rename these protocol files.
But I can see the idea of "namespacing the filename" so that it doesn't 
clash
with another app installing a protocol file ... (in fact they *would* have
clashed still -- not at the filesystem level, but surely in the 
KProtocolInfo
code, which would not know which definition to use, so which one would win,
would be pretty much undefined...). But OK, that's probably better than 
a clash
between distro packages, people don't like that.

Ah, I know what the real solution is: removing these files altogether and
adding x-scheme-handler/irc (and the others) to konversation.desktop, in 
the
MimeType line. This requires kdelibs >= 4.7 though, I'm not sure if you can
already do that then, but at least you know what to do when requiring 
4.7, to
avoid breaking in 5.0.

-- 
David Faure, faure at kde.org, http://www.davidfaure.fr
Sponsored by Nokia to work on KDE, incl. KDE Frameworks 5



More information about the Konversation-devel mailing list