Trying to understand ContentControl text portions

Creating a macro - Writing a Script - Using the API (OpenOffice Basic, Python, BeanShell, JavaScript)
Post Reply
_savage
Posts: 187
Joined: Sun Apr 21, 2013 12:55 am

Trying to understand ContentControl text portions

Post by _savage »

Hello,

I came across a TextPortion whose TextPortionType is ContentControl which I don’t see mentioned in the docs. This is for a text portion whose changes were tracked during document edit.

Using MRI and following its ContentControl property leads me to an object whose implementation name is SwXContentControl but I can’t find that documented, nor are there properties/methods attached which would hint at how to use it. Can somebody here share some pointers or experience as to how to access the current & previous text content, as well as the kind of control this objects wraps?

Much thanks!
Jens
Mac 10.14 using LO 7.2.0.2, Gentoo Linux using LO 7.2.3.2 headless.
JeJe
Volunteer
Posts: 2764
Joined: Wed Mar 09, 2016 2:40 pm

Re: Trying to understand ContentControl text portions

Post by JeJe »

Is it a Microsoft Word object perhaps?

https://support.microsoft.com/en-us/off ... 02c1cce1c2
Windows 10, Openoffice 4.1.11, LibreOffice 7.4.0.3 (x64)
cwolan
Posts: 129
Joined: Sun Feb 07, 2021 3:44 pm

Re: Trying to understand ContentControl text portions

Post by cwolan »

_savage wrote:I came across a TextPortion whose TextPortionType is ContentControl which I don’t see mentioned in the docs.[..]
Just to be sure: you came across it in LibreOffice 7.2.x (versions given in your signature)?
I see ContentControl (Object@SwXContentControl) in LibreOffice 7.4.x.
OpenOffice 1.1.5 – 4.1.15
LibreOffice 6.4.7 – 7.6.5
Windows 7,10,11 64-bit
cwolan
Posts: 129
Joined: Sun Feb 07, 2021 3:44 pm

Re: Trying to understand ContentControl text portions

Post by cwolan »

Additional information...
─────────
Check Box Content Control.png
Check Box Content Control.png (112.62 KiB) Viewed 658 times
─────────
ContentControl.png
ContentControl.png (85.83 KiB) Viewed 658 times
OpenOffice 1.1.5 – 4.1.15
LibreOffice 6.4.7 – 7.6.5
Windows 7,10,11 64-bit
Post Reply