Finally figured it out. Installed kde-builder and built kwin project. Somehow ended up using CLion, but tried a few other IDEs too.
Probably not the best way, but I got where I needed to be: I can set breakpoints and debug kcm application. Settings for CLion “Run/Debug Configuration”:
Executable: ~/kde/usr/bin/kcmshell6
Program arguments: $CMakeCurrentProductFile$
Working directory: $CMakeCurrentLocalBuildDir$
This is more of a reminder to myself in the future. Please share comments if I did something wrong, or could’ve done better. All feedback is appreciated.