summaryrefslogtreecommitdiff
path: root/offapi
diff options
context:
space:
mode:
authorMiklos Vajna <vmiklos@collabora.com>2022-09-05 10:16:21 +0200
committerMiklos Vajna <vmiklos@collabora.com>2022-09-05 13:15:57 +0200
commitb9da26fac9cd17cff0ed56327fade37f5105d500 (patch)
tree334802b282d901df1d9315d73efc95421b2f14f7 /offapi
parent11999e2114040ba165da29ca6811d8e09e735413 (diff)
offapi: document com.sun.star.text.ContentControl
It has a lot of properties and what's inside ListItems was also rather unclear. Change-Id: Iaef719d72b95374da6d0dfa8247870fa5f76d18d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/139406 Reviewed-by: Miklos Vajna <vmiklos@collabora.com> Tested-by: Jenkins
Diffstat (limited to 'offapi')
-rw-r--r--offapi/UnoApi_offapi.mk1
-rw-r--r--offapi/com/sun/star/text/ContentControl.idl101
-rw-r--r--offapi/com/sun/star/text/TextRangeContentProperties.idl6
3 files changed, 108 insertions, 0 deletions
diff --git a/offapi/UnoApi_offapi.mk b/offapi/UnoApi_offapi.mk
index 6abbddc21b5d..331e5eadaf5f 100644
--- a/offapi/UnoApi_offapi.mk
+++ b/offapi/UnoApi_offapi.mk
@@ -1343,6 +1343,7 @@ $(eval $(call gb_UnoApi_add_idlfiles_noheader,offapi,com/sun/star/text,\
CellRange \
ChainedTextFrame \
ChapterNumberingRule \
+ ContentControl \
ContentIndex \
ContentIndexMark \
Defaults \
diff --git a/offapi/com/sun/star/text/ContentControl.idl b/offapi/com/sun/star/text/ContentControl.idl
new file mode 100644
index 000000000000..641ffd9cebd4
--- /dev/null
+++ b/offapi/com/sun/star/text/ContentControl.idl
@@ -0,0 +1,101 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*
+ * This file is part of the LibreOffice project.
+ *
+ * This Source Code Form is subject to the terms of the Mozilla Public
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
+ */
+
+module com { module sun { module star { module text {
+
+/** This service specifies a content control with properties in a TextDocument.
+
+ A content control wraps one or more text portions and controls the behavior of that content.
+
+ @since LibreOffice 7.4
+*/
+service ContentControl
+{
+
+ /** Provides a way to insert the content control using insertTextContent().
+ */
+ interface com::sun::star::text::XTextContent;
+
+ /** Current content is placeholder text.
+ */
+ [optional, property] boolean ShowingPlaceHolder;
+
+ /** Display the content control as a checkbox.
+ */
+ [optional, property] boolean Checkbox;
+
+ /** If Checkbox is true, is the checkbox checked?
+ */
+ [optional, property] boolean Checked;
+
+ /** If Checkbox is true, the value of a checked checkbox.
+ */
+ [optional, property] string CheckedState;
+
+ /** If Checkbox is true, the value of an unchecked checkbox.
+ */
+ [optional, property] string UncheckedState;
+
+ /** List items of a dropdown: DisplayText + Value pairs with string values for each item.
+
+ If the list is non-empty, a dropdown control is provided on the UI.
+ */
+ [optional, property] sequence< sequence< com::sun::star::beans::PropertyValue > > ListItems;
+
+ /** Display the content control as a picture.
+ */
+ [optional, property] boolean Picture;
+
+ /** Display the content control as a date.
+
+ If true, a date picker is provided on the UI.
+ */
+ [optional, property] boolean Date;
+
+ /** If Date is true, the date format in a syntax accepted by the NumberFormatter.
+ */
+ [optional, property] string DateFormat;
+
+ /** If Date is true, the date's BCP 47 language tag.
+ */
+ [optional, property] string DateLanguage;
+
+ /** Date in YYYY-MM-DDT00:00:00Z format.
+ */
+ [optional, property] string CurrentDate;
+
+ /** Plain text, i.e. not rich text.
+ */
+ [optional, property] boolean PlainText;
+
+ /** The placeholder's doc part: just remembered.
+ */
+ [optional, property] string PlaceholderDocPart;
+
+ /** The data bindings's prefix mappings: just remembered.
+ */
+ [optional, property] string DataBindingPrefixMappings;
+
+ /** The data bindings's XPath: just remembered.
+ */
+ [optional, property] string DataBindingXpath;
+
+ /** The data bindings's store item ID: just remembered.
+ */
+ [optional, property] string DataBindingStoreItemID;
+
+ /** The color: just remembered.
+ */
+ [optional, property] string Color;
+};
+
+
+}; }; }; };
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/offapi/com/sun/star/text/TextRangeContentProperties.idl b/offapi/com/sun/star/text/TextRangeContentProperties.idl
index 7ba4068ddd17..1f12a475375b 100644
--- a/offapi/com/sun/star/text/TextRangeContentProperties.idl
+++ b/offapi/com/sun/star/text/TextRangeContentProperties.idl
@@ -81,6 +81,12 @@ service TextRangeContentProperties
*/
[optional, readonly, property] com::sun::star::text::XTextContent LineBreak;
+ /** may contain a content control.
+
+ @since LibreOffice 7.4
+ */
+ [optional, readonly, property] com::sun::star::text::XTextContent ContentControl;
+
};