Need Python Macro extention tutorial

Discussions about using 3rd party extension with OpenOffice.org

Need Python Macro extention tutorial

Postby matmir » Mon Sep 09, 2019 3:23 pm

Hello,
I'm principiant on this ambient, but I'm a senior developer.
I know python language, but i don't find any tutorial to create oxt extension on libreoffice by python.
Is there someone to help me, to find pdf tutorial or link to any page to guide on step by step create oxt extension.
I'm open to any solution to resolve my problem.
Thanks to everyone who answers.
 Edit: This was originally posted in the Tutorials forum but it is not a tutorial and does not belong there.
-- MrProgrammer, Forum Moderator, 2019-09-09 14:14 UTC 
LibreOffice Versione: 6.2.1.2 (x64) on Windows 7
matmir
 
Posts: 1
Joined: Mon Sep 09, 2019 3:15 pm

Re: Need Python Macro extention tutorial

Postby Villeroy » Mon Sep 09, 2019 5:45 pm

A Python macro is a script that is stored as plain text in <user_profile>/Scripts/python
It can be accessed through menu:Tools>Macros and several event dialogs for objects and menu:Tools>Customize... [Events]

An extension integrates some new class(es) into the application, including the API. You have to be familiar with the overall architekture, write xml files, install the SDK and generate IDL files.

I can offer a Writer template which stores a plain text file (i.e. a macro) within the script folder.
You edit a user-defined text field (dbl-clikc), call a Basic macro which is part of the template and the document text will be installed as plain text.
---
Currently, I can not access my templates. Here is a macro document derived from the said template: viewtopic.php?f=21&t=97134

Extensions wiki: https://wiki.openoffice.org/wiki/Extensions
Please, edit this topic's initial post and add "[Solved]" to the subject line if your problem has been solved.
Ubuntu 18.04, no OpenOffice, LibreOffice 6.x
User avatar
Villeroy
Volunteer
 
Posts: 27092
Joined: Mon Oct 08, 2007 1:35 am
Location: Germany

Re: Need Python Macro extention tutorial

Postby Villeroy » Mon Sep 09, 2019 7:43 pm

ExtensionCompiler.ott is a Writer template which works very much like a huge input form.
Please, edit this topic's initial post and add "[Solved]" to the subject line if your problem has been solved.
Ubuntu 18.04, no OpenOffice, LibreOffice 6.x
User avatar
Villeroy
Volunteer
 
Posts: 27092
Joined: Mon Oct 08, 2007 1:35 am
Location: Germany


Return to Extensions

Who is online

Users browsing this forum: No registered users and 0 guests