-
Notifications
You must be signed in to change notification settings - Fork 2
Usage
-
Start LibreOffice from the command line
soffice "--accept=socket,host=localhost,port=2002;urp;StarOffice.ComponentContext" --norestore
/opt/libreofficedev5.4/program/soffice "--accept=socket,host=localhost,port=2002;urp;StarOffice.ComponentContext" --norestore
-
Start Dash-like offline documentation browser
-
Open your macro file in editor
Create your macro file, eg, copy template
simple_macro.py
toLIBREOFFICE_PATH/4/user/Scripts/python
directory. -
Set breakpoints in the source code
Left click in the very small column just after the line number's column.
-
Run source code in the editor
Menu
Run -> Run file as script
-
Debugging
Double clik on property or method to drill down or move to next line.
Use the toolbar buttons to move to the next line. Please note, in order to show property or method in workspace or shell use the debug toolbar buttons to move to the next line.
More information about debugging with Pyzo you can find here
-
Examine property or method
In PyUNO_Workspace double clik on property or method to drill down
or find more information with right clik on property or method.
-
Examine variable value in shell
-
Set arguments
Write argument ("Standard") and double click on method (getByName)
More examples: 0 = object.getByIndex(0), [space] = object.getMethod( )
-
Insert code in editor
Pres icon
to insert code at cursor position
Inserted code in the script
initial_target = document.BasicLibraries item = initial_target.getByName("Standard")