In this file, replace xim by scim in both GTK_IM_MODULE=xim and QT_IM_MODULE=xim expressions.

Save and quit. Edit the second file as well:

cd /etc/scim/
cp global global.old
gedit global

and add your current locale fr_FR.UTF-8 to the first line as in /SupportedUnicodeLocales = en_US.UTF-8,fr_FR.UTF-8. Logout and re-login.

Using SCIM

Warning: the French keyboard layout will not let you select a character using digits once you wrote pinyin, choose the American keyboard layout instead. Just add the keyboard selection tool to the Gnome or KDE taskbar.

Open the application in which you want to write chinese, then press simultaneously the ctrl and space keys to get to the Chinese input method. If it fails, try to simultaneously press the ctrl and shift keys: