You need to put a file named xchat.protocol in /usr/share/kde4/services that contains:
exec=xchat --existing --url=%u
It can works for other irc clients, just change the name to yours and maybe a little bit the command line 🙂
In fact, if you have something that use xdg-open to try to open a link or an url, it will look up the protocol or mime type and try to find if there is any services attached to the protocol or applications to the mime type. An application usually describes the mime types it can read in its .desktop file (same folder as the protocol files).