Sadly, it didn't help. I've disabled double buffering like you've said, but the bug remained. Then I've tried again to run emacs without cairo and harfbuzz and with disabled double buffering the issue remained. I have also tried to run "emacs -nw" and "emacs -nw -Q" with all aforementioned setup, sadly the same problem occurred.