How to set up IDE with autocompletion for libreoffice?

I’m been trying to set up IDE for libreoffice scripting this whole day to no avail. Can someone please tell me how did you set it up? I don’t mind any language (basic, python or javascript) or text editor (built-in, vscode, emacs), but I don’t know how to learn scripting without autocompletion.

I’ve tried XrayTool, APSO and built-in experimental autcompletion option in Libreoffice. None of them gave me an autocompletion at the end.

I have been working feverishly on this for a while now. I have started some Guides that are just the beginning, but important because how you set up your environment is imporant to accomplish this task.

I have written many python packages to do what you are asking.
The Most prevelent to date being OOO Dev Tools (OooDev).

  • types-unopy, Types for over 4000 LibreOffice API Object and classes.
  • types-scriptforge that give type support for ScriptForge python ( in IDE).
  • oooenv for configuring Python Virtual Enivronment to work with LibreOffice.

and much more…

I will be publishing git repository by tomorrow that demonstrates how to debug and/or give type support to your python projects.

There will be more guides to come soon…

3 Likes

Wow, this documentation is fantastic. Thank you very much for publishing it! I will dive right in.
Definitely looking forward to more guides and tomorrow’s repo then.

I’m obviously to old to explain this…
.
But once upon the time there were written documentation outside of computers available on paper. I don’t remember any autocomplete at Kernighan&Ritchie or Wirth.
.
I was told at university there were left some readers for batches of punch cards, but not used often at that time for Fortran4

Offtop. I saw programmers who determined the typed text by the holes on the punched card. :slightly_smiling_face:

Thank you for explaining, that makes sense. I am trying to highlight occurrences of some word within cells, which isn’t supported by the API (there are not methods to edit text in cells) and will require some advanced knowledge of the object model to pull off. In this situation I would argue that more approachable IDE would make a huge difference.

Well, a few things got in my way today so did not get as far as I would have liked, but all the same an early version is up.
LibreOffice Python Script Modern Code Editor Examples. Keep checking for updates because there is much more to come.

1 Like

An important “trick” I’ve just learnt is to use the “Watch” panel to debug the code and display all the properties and their current values at runtime:

image

While it’s not the autocompletion asked in the question it does help tremendously. You will still need to lookup function names somewhere else, but oh well as the Great Mediocrates once said it: