This is a small FAQ for the KVirc irc client.

##############################################################
What are the requirements for installing and compiling kvirc?
##############################################################

-Kvirc requires the Qt toolkit , in a version >= 1.40
 That toolkit can be obtained from www.troll.no.
 The qt library standalone will not suffice.
 You will need the qt-*-devel package that contains
 the header files.
 Believe me...better if you compile Qt by yourself from the source package:
 Qt is known to compile easily on most platforms..(like type make twice...)
-Kvirc requires the KDE libraries , in a version >= 1.0
 The libraries can be obtained from www.kde.org. 
 Check the KDE Readme files for a correct installation.

#############################################
Can I run KVirc on a non-KDE window manager?
#############################################

Yes...but you still need the KDE libraries installed.
Kvirc is known to run under windowmaker and fvwm.
However ,some features may be missing , and kvirc
may behave in a different way.
Also the installation process may need some 'hacking'.

@@@@@@@@@@@@@@@@@@@@
What to do when :
@@@@@@@@@@@@@@@@@@@@

################################################################
The configure script can not find the Qt library and/or headers
################################################################

First make sure that you have the appropriate version of
qtlib.(1.40).
On your system , this should be the ONLY qtlib installed.
Make sure that your QTDIR enviroinment variable is set properly:
If qt is installed in /usr/local/qt , set QTDIR to that path 
(in /etc/profile or your system's equivalent).
The configure script looks for the library in $QTDIR/lib
and the include files (headers) in $QTDIR/include.
Check the LD_LIBRARY_PATH as described in the topics below!!!

######################################################################
I got 'undefined refernece to _XSetLocale'
######################################################################
If you have problems with linkage suchas 'undefined reference to '_XSetLocale'
in libXt...please check that it is the correct libXt.
On many RedHat systems I've found an ld.so.conf that defines
the [usr]/i486-linux-libc5/lib libraries directory before the ...[usr]/X11R6/lib directory.
That causes gcc to link the wrong library version.
If it happens please place [usr]/X11R6/lib as the first entry in ld.so.conf and run ldconfig.

######################################################################
I got 'undefined reference to 'SOMETHING'
######################################################################
See above , and 'ld:cannot load shared library :..'

######################################################################
I have recently moved to egcs and kvirc won't compile/start
######################################################################
Pleas recompile the Qt library and the KDE libraries.
Make sure that you have ALL the standard system libraries
requred by egcs in the correct version. (This means : INSTALL
egcs properly and everything will work)

######################################################################
KVirc don't save my settings...
######################################################################
KVIrc saves the settings in the following directories :
$HOME/kvirc/*
$HOME/.kde/share/config
$KDEDIR/share/config
$KDEDIR/share/apps
Please make sure that you have the right access to that directories.
Kvirc will save settings correctly if your KDE is configured correctly
(eg. other KDE apps save the settings correctly)

######################################################################
the linker says : '....undefined symbol:'
######################################################################
This error is common when upgrading to egcs.Please read the related
answer.

######################################################################
ld:cannot load shared library : libkdecore.so (libSOMETHING.so)
######################################################################
....
kvirc: error in loading shared libraries
libkdecore.so.1: cannot open shared object file: No such file or directory 
....
This is usually due to a misconfigured runtime linker.
Please make sure that your LD_LIBRARY_PATH is set correctly,
ld.so.conf has the correct entries. (e.g it should contain $KDEDIR/lib , $QTDIR/lib...)
Check (AGAIN) for the correct libraries installation and the PATH settings.
Check (AGAIN) for twice libraries...try to make your system 'consistent'.

########################################################################
KVirc refuses to write my popups file complaining about a File I/O error
########################################################################
See KVirc don't save my settings

#########################################################################
I get : 'No mathing function for QMenuData::insertItem...' (or similar..)
#########################################################################
You have the wrong version of the Qt library installed,you miss a header,
or you have upgraded the Qt library leaving some old files somewhere.
Reinstall correctly the library (only make install) after removing
ALL the older copies of the lib.
If you really need to keep different versions of libraries , make sure that
the c++ uses the proper include (and library include -L) directory.
( c++ -I/directory_to_NEW_qt_headers -L/directory_to_NEW_qt_libraries)
If not , change it in the Makefiles.
Make also sure that QTDIR points to the right directory.
(Same applies to KDE if you get something as 
'No mathing function for KToolBar::getWidget...")
If you need to keep more copies of a library on your system that
have the same name (eg libqt.1.33 and libqt.1.40) , moving it
to different directories may solve the problem....
Just make sure that the linker finds the right one as FIRST.
(check ld.so.conf and put the directory as the first entry)

######################################################################
KVirc don't want to show my national characters.
######################################################################
Well..this feature is still a little buggy, (especially in DCC Chat)
and if someone could help me with that...
Howewer , only few problems are due to the bug...
Usually, this is due to an incorrecto configuration:
You must use translation and select the correct TRANSLATION MAP!
You must also SELECT THE CORRECT FONT (tha font must have the right
charset...)
And it's still not sure that it will work.
Sometimes,there are different translation tables for one language:
that means that each table is to be used with a specified charset (and font)
For example ,in russian there is more than one standard charset.(koi , ISO...)
So you need to find the correct match map-font.
You can always create a correct mapby yourself.
The bug manifest itself (for example:) when you can read the characters 
in the channel window but not in a DCC Chat...

######################################################################
Can't find the command 'X' as in the irc client 'Y'
######################################################################
Well,you can always add an alias for that command :
For example an alias for /WHO could be : /RAW who $0.
In each new version I will try to increase the available commands.

######################################################################
KVIrc sometimes 'jumps' over other newly created windows.
######################################################################
It is bug in the focus managing code...still can't solve it in a
reasonable way...you can just 'hope' that it will be solved later
or try to solve it by yourself and send me a patch.

######################################################################
KVirc succesfuly run for some days....but today it won't start...
######################################################################
Users noticed that KVirc may lock after installing a badly created
script. The kvi.cache.conf file may get messed. Removing that file
from the $HOME/kvirc/Config directory should solve that problem.
If it still won't work...try removinf kvi.alias.conf too.
(You will loose your aliases , that's why it is a good idea to save
you script when you make big changes).
KVirc should not segfault by now (but since it is a beta it is not guaranteed).
While developing (well...I think that I have erased 3-400 core files since now:),
I noticed also that if kvirc segfaults for some reason , it may mess
with the configuration files,and refuse to start next time.
Removing one of the configuration files was always a good solution.

######################################################################
Some image formats are not loaded properly
######################################################################
KVirc relies on the Qt and KDE code to load images.
So if you're not able to load something (as jpegs or some kind of gifs)
it is NOT due to KVirc.

######################################################################
KVirc tells me 'A horrible UNKNOWN error occured' while connecting to
a server...
######################################################################
This is only a fancy message...to tell you that an 'unhandled' error occured.
Many systems have it's own particular error codes that kvirc can
not understand...but he knows that this is an error.
A UNKNOWN error can be sometimes translated to:
Network is unreachable : You've tried to connect to a server
that is in a sub-network that can not be reached from yours.
Port (or protocol) is unreachable : Similar to the above.
Connection refused : You've tried the wrong port or tried to connect
to a non-irc server...
Various kinds of tcp errors like wrong packets size...no route to host.
The UNKNOWN error appears especially when using the SOCKS firewall.
The firewall (or proxy...as you prefer) is contacted, and the
connection to server is negotiated.
Then the firewall tries to connect to the server indicated.
If the server can not be contacted for some reason,
or refuses the connection (very common case :) , the fire replies us
an error.I still can't guess if that error is exactly the one that
the firewall gets , or it is a 'remapped' (and random for us)
error indicating that the connection has failed.
So if you get this error , simply change the firewall or server and try again.

Can't find the answer to my question in this FAQ
######################################################################
Write your question to kvirc@tin.it and please be patient.

@@@@@@@@@@@@@@@@@@@@@@@@
Other common questions :
@@@@@@@@@@@@@@@@@@@@@@@@

######################################################################
What is IRC?
######################################################################
Huh?...
Oh...ok :)
main documentation sources and where to find it:
RFC1459 (yahoo search) : IRC Protocol
Mirc help file and IRC Faq (www.mirc.co.uk) : Really well written IRC description for beginners.
channels as #IRCHelp (any IRC network) : On-line help for beginners.

######################################################################
How can I enable logging?
######################################################################
Each window hai its own separate logging system.
It is NOT enabled when the window is created. (Just because the autolog
feature is really resource-consuming...).
You must select the 'logging...' item from the window-system menu. (left
button in the caption).

######################################################################
Where can I find documentation/help for my scripts?
######################################################################
The help files are not finished yet...but try it....maybe the part
that you're looking for is already there.
There is also a /HELP command that explain sytax and meaning of ALL commands 
and identifiers.

######################################################################
I can't find the feature 'X' as in the irc client 'Y'
######################################################################
First check twice if the feature really is not there (maybe a little
hidden or with another name)...
....if you still can't find it,that means that there is NOT.
If you don't like it just uninstall kvirc and continue using the client 'Y'.
If you like kvirc enough to ask yourself if this feature/command
could be added please read the answer to the next question.

######################################################################
KVirc crashed unexpectedly (WHILE RUNNING)
######################################################################
Ops....you've found a bug?...
Please report it to kvirc@tin.it , including ,if possible, a log of
the 'debug-output' or a gdb backtrace...

######################################################################
How can I enable/disable the debug output?
######################################################################
You need to uncomment/comment the debug switch in the kvi_debug.h
file (line 29) and recompile (make clean first).

######################################################################
Why don't you add the feature 'X'
######################################################################
Yes , I will add it...but when finished to add/fix the other
231839138938393813103443244432 things in the TODO LIST :)
While waiting, if you want to try to add the feature by yourself,
and see your name in the 'HallOfFame' dialog, just read the answer
to the next question.

######################################################################
Can I help you in '*****ANYTHING*****' ?
######################################################################
Yes please! Just write to kvirc@tin.it and explain what you would like
to do...
Before sending pathes , please send a mail requesting the latest snapshot
of kvirc and describing briefly the patch you want to write.
I will send you immediately the daily snapshot , and will try to not
modify the files that you're working on,so I will be able to apply your
patch correctly.
This is an invite to join our project :)

######################################################################
How to make a cup of coffee using kvirc?
######################################################################
This may require some additional hacking in the configure script:
you may need to add the --coffee-columbian option to the command line.
You will also need the Java SDK properly installed and egcs as the compiler.
Once compiled and installed , connect to irc.tin.it on port 6669 with nick
'coffee' and username 'hot' , then type : /exec 'kvirc-cafe-realize'.
This will start a program that may ask you for setting up some additional 
swap space on the device fd0 , and how many spoons of sugar you want to
put in there.
Then it will attempt to make the coffee using the 

######################################################################
The coffee comes out , but is cold!
######################################################################
Well...that means that your coffee machine is not java-enabled.
I'm working on it,so please be patient...
Walking on water wasn't developed in one day...

Szymon Stefanek
