@mrjj Thank for reply.
I'm sorry. I meant this in last message: QKeyEvent(QEvent::KeyPress, Qt::Key_Up, Qt::NoModifier).nativeScanCode(); It had not worked too, and now I almost understand why. Explain please, what is sym key? Symbol key?
I don't know am I right, but I think that it hadn't worked because real event calls this constructor with ready nativeVirtualKey and scanCode:
QKeyEvent::QKeyEvent(Type type, int key, Qt::KeyboardModifiers modifiers, quint32 nativeScanCode, quint32 nativeVirtualKey, quint32 nativeModifiers, const QString & text = QString(), bool autorep = false, ushort count = 1)
I thought, this codes are calculating somewhere In constructor, but as i see - they need to be listed when constructor is called.

I get good nativeVirtualKey in keyboardEvent and it also equals 37, 38, 39, 40, but I wanted to get constants anywhere else and not to use Windows constants. Is there any possible way?

@Dani
Hi
yes sym = symbol key. bad name. its more like native key value.
The reason its not working is that the native/os/nativeVirtualKey is part of the real os event and added to the
QKeyEvent class when a real OS event happens.
So I do not think creating one will contain the info you want.

@mrjj With keyboardEvent I store pressed keys.I need to react on English and non-English keyboard the same. So I wanted to use nativeVirtualKey to perform the same reaction on same keys (but in different language). But it hadn't worked for arrow keys: Qt::Key_Up has value 16 777 235. So I needed to do something with that.