summaryrefslogtreecommitdiff
path: root/schema
diff options
context:
space:
mode:
authorLaurent Balland <laurent.balland@mailo.fr>2023-02-04 09:29:20 +0100
committerEike Rathke <erack@redhat.com>2023-08-25 17:49:17 +0200
commit74d9da037cac01c5abd768a99b2f948553fbf144 (patch)
treed91cf6581202c313f9a9c74fcc9f4ef31eb6928e /schema
parentc7b59c9484ae6ff88cd8d7017aeb83b02e212c9c (diff)
tdf#152724 Extend ODF for blank width "_x"
Number format code "_x" is currently saved as a text string containing a number of spaces corresponding to the width of character "x". It may be confusing for user if its format code is modified. This change introduces a new XML tag XML_BLANK_WIDTH_CHAR to replace the previous text string if ODF version is extended <number:text> and <number:embedded-text>: the attribute is composed of a string containing the used character and its position in the text string (if position is 0, it is omitted). Several blank code characters are separated by '_'. Replacement blanks in the text string are preserved to enable compatibility. Example: format code "foo"_M_I_N"!"???,???.000_.000"!"_) is saved as: <number:number-style style:name="N173"> <number:text loext:blank-width-char="M3_I6_N7">foo !</number:text> <number:number number:decimal-places="6" number:min-decimal-places="6" number:min-integer-digits="6" loext:max-blank-integer-digits="6" number:grouping="true"> <number:embedded-text number:position="-4" loext:blank-width-char="."> </number:embedded-text> </number:number> <number:text loext:blank-width-char=")1">! </number:text> </number:number-style> Add QA test Change-Id: I785e1a14ecccc900e9fd5af88dd7b743fefcc48c Reviewed-on: https://gerrit.libreoffice.org/c/core/+/146582 Tested-by: Jenkins Reviewed-by: Eike Rathke <erack@redhat.com>
Diffstat (limited to 'schema')
-rw-r--r--schema/libreoffice/OpenDocument-v1.3+libreoffice-schema.rng28
1 files changed, 28 insertions, 0 deletions
diff --git a/schema/libreoffice/OpenDocument-v1.3+libreoffice-schema.rng b/schema/libreoffice/OpenDocument-v1.3+libreoffice-schema.rng
index b1a344e7bf4a..b7ad4b8a1a7c 100644
--- a/schema/libreoffice/OpenDocument-v1.3+libreoffice-schema.rng
+++ b/schema/libreoffice/OpenDocument-v1.3+libreoffice-schema.rng
@@ -2047,6 +2047,14 @@ xmlns:loext="urn:org:documentfoundation:names:experimental:office:xmlns:loext:1.
<rng:empty/>
</rng:element>
</rng:define>
+ <rng:define name="number-text">
+ <rng:element name="number:text">
+ <rng:optional>
+ <rng:ref name="number-text-attlist"/>
+ </rng:optional>
+ <rng:text/>
+ </rng:element>
+ </rng:define>
</rng:include>
@@ -2745,6 +2753,26 @@ xmlns:loext="urn:org:documentfoundation:names:experimental:office:xmlns:loext:1.
</rng:optional>
</rng:define>
+ <rng:define name="number-embedded-text-attlist" combine="interleave">
+ <!-- TODO no proposal, -->
+ <rng:optional>
+ <rng:attribute name="loext:blank-width-char">
+ <rng:ref name="string"/>
+ </rng:attribute>
+ </rng:optional>
+ </rng:define>
+
+ <!-- TODO no proposal, -->
+ <rng:define name="number-text-attlist">
+ <rng:interleave>
+ <rng:optional>
+ <rng:attribute name="loext:blank-width-char">
+ <rng:ref name="string"/>
+ </rng:attribute>
+ </rng:optional>
+ </rng:interleave>
+ </rng:define>
+
<!-- TODO no proposal -->
<rng:define name="table-data-pilot-level-attlist" combine="interleave">
<rng:optional>
/cib_contract49d&id=492b0d5d076d38234fea4e4e7c5dbec578296fd2'>weld conditional formattingCaolán McNamara 2019-05-09loplugin:unusedmethodsNoel Grandin 2019-05-09loplugin:unusedfieldsNoel Grandin