Update: Now I know, that the reason is 8-bit color in the system. But I still have no decision.
The first dialog created with Xlib and the second one is the Qt dialog. Both dialogs are very simple.
The code for Qt Project is here Window Flags Example.
QApplication::setGraphicsSystem("native");