Fix lyx2lyx issue with complex beamer arguments.

Fixes: #9254