There is no good automated way of doing this unfortunately this is due to the fact that there are many people out there like me who use some programs from both gnome and kde, Personally I pick my desktop environment based off which one suites my needs best then use each program based off there merit regardless of if they are kde gnome or other. Yes this causes some minor inconsistencies, but if you set them both to use the same theme, or a gnome-kde theme these are only minor.
To answer your question though, there is a way to do this manually, when you install "KDE" or install "gnome" what you really do is install a pattern, all this pattern is, is a list of other programs to install. If you go to the software manager in YAST, and select the Pattern tab, you can see all the programs in the respective patterns and manually uninstall them, in your case probably the KDE4 Base System and KDE4 Desktop environment patterns. You should note though there are programs such as firefox that are neither kde or gnome programs and are probably present in both the KDE and Gnome patterns