You didn’t mention anything about any application and we haven’t touched theming yet. We don’t know either if you are mixing desktops - both Xfce and Plasma on the same system - such mixing only creates frustration.
GTK is the toolkit used for GTK based systems Xfce among others and Qt is a toolkit used by Plasma and LXQt.
It may be the chosen theme which switches the layout.
I run the the same app (it does use qt) and the buttons come up in different order. Quite a problem when muscle memory expects the Ok where the Delete is.
Both from github, on Manjaro it is AUR freecad-git. That produces the same git build id when I build from git on Debian. It has been this way for as long as I remember.
The default dialog button order is dictated by the desktop environment. KDE is the same Ok/Cancel order as Windows, GNOME and other GTK-based DE’s like Xfce is Cancel/Ok order like macOS.
I think that using a GTK theme in KDE will only change the button order in GTK apps. Qt apps should follow the DE preference so change it in Xfce I guess.
Or much simpler solution is don’t use two DE’s which have opposite opinions about button order
Xfce can use qt5ct or kvantum-manager for managing QT theme
qt5ctInterface tab has 4 options for Dialog buttons layout:
Windows, Mac OS X, KDE, GNOME
kvantum-managerConfigure Active Theme tab has 6 options for Dialog button layout:
Follow style, KDE layout, Gnome Layout, Windows layout, Mac layout, Android layout