<div dir="ltr"><div>Hello,</div><div><br></div><div>I had initially  hard-coded C++ wrapper MyClass around the mxDocText object (SimpleBootstrap_cpp.cxx), and then exported that C++ wrapper to Lua. </div><div><br></div><div>I then refactored the code (with guidance from Stephan), to map the C++ UNO objects to LUA and have a generic way to call UNO interface methods. I did this by passing UNO objects as a Reference<XInterface> and then using UNO_QUERY to get the correct userdata type.</div><div><br></div><div>I am currently working on changing UNO interface  methods that are hard-coded as individual C++ functions to a single a C++ method mapped to the __index metamethod.  </div><div><br></div><div><a href="https://gerrit.libreoffice.org/c/core/+/168298">https://gerrit.libreoffice.org/c/core/+/168298</a>  (WIP) <br></div><div><br></div><div>Regards,</div><div>Venetia Furtado          </div></div>