This has been tested on Arch Linux 2017 (Linux Kernel 4.12.12-1-ARCH) with KDE Plasma 5.10 installed, with libreoffice-fresh version 5.4.1.2.0 and other KDE apps.
Install the necessary pacakges:
sudo pacman -S fcitx fcitx-qt4 fcitx-qt5 m17n-db fcitx-m17n fcitx-configtool
You can install this if you want to access fcitx configuration from KDE settings (optional):
sudo pacman -S kcm-fcitx # optional
Run this and go to Interface, then choose fcitx as input method:
qtconfig-qt4
Run nano ~/.xprofile
and add at bottom:
# fcitx
export GTK_IM_MODULE=xim # for gtk apps
export QT_IM_MODULE=fcitx
export QT4_IM_MODULE=fcitx
export XMODIFIERS=@im=fcitx
fcitx &
Run nano ~/.bashrc
and add at bottom:
export XMODIFIERS=@im=fcitx
Now run this:
fcitx
This will bring up a new icon in the taskbar. You can close the terminal, fcitx will run in background.
You will not be able to write in Bangla yet. Reboot the machine (logout and login should also work).
You can run fcitx-diagnose
to find out if there's any problem with the setup.