Commit Graph
12839 Commits
Author SHA1 Message Date
Michael Stahl 09f23a3dc5 tdf#105844 package,sfx2: remove checksum infoleak when using AEAD
AEAD provides the verification of the password automatically, by reading
the entire stream the tag at the end will be verified.

The existing attributes manifest:checksum-type/manifest:checksum leak
information about the plain text.

This was mitigated with the addChaffWhenEncryptedStorage() functions
(see commit f57baefbd3) but a better
solution that also works for non-XML streams is to simply omit the
attributes; authenticated encryption provides better verification
without any leak.

* "ChecksumAlgorithm" property can be set to void now to remove the
  checksum
* change a bunch of members in EncryptionData, ZipPackage,
  ZipPackageStream to optional
* change ZipFile::checkValidPassword() to open the stream and return it

Change-Id: Id95288d0c238c4f9940fc5a185df814e8edcbad3
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/160711
Tested-by: Jenkins
Reviewed-by: Michael Stahl <michael.stahl@allotropia.de>
2023-12-13 22:02:52 +01:00
Michael Stahl f0fda7ad22 tdf#105844 offapi,package,sfx2,xmlsecurity: add AEAD w/ AES GCM
... and use it in the new experimental ODF encryption mode.

https://www.w3.org/TR/xmlenc-core1/#sec-AES-GCM

Unfortunately it turned out that NSS PK11_CipherOp() does not work with
CKM_AES_GCM because it is initialized with "context->multi = PR_FALSE"
in sftk_CryptInit(), so the one-step functions PK11_Encrypt() and
PK11_Decrypt() have to be used.

NSS 3.52 also changed a parameter struct definition - see
https://fedoraproject.org/wiki/Changes/NssGCMParams - which is not a
problem for RHEL or SUSE system NSS since those are rebased, but it
is likely a problem for less well maintained Ubuntu LTS, so use
the old struct definition which evidently still works with NSS 3.94.

NSS 3.52 also added a new PK11_AEADOp() API but it looks like this
doesn't support incremental encryption either.

Change-Id: Ibd4a672db74b65b1218926ba35ff8d2f70444c7e
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/160505
Tested-by: Jenkins
Reviewed-by: Michael Stahl <michael.stahl@allotropia.de>
2023-12-11 20:46:40 +01:00
Samuel Mehrbrodt 030b72df0a tdf#157432 Expert config: Allow filtering by changed values
Change-Id: Ib8bbb7fc9e8014a9367278f3fa640f53af46dd2b
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/159986
Tested-by: Jenkins
Reviewed-by: Samuel Mehrbrodt <samuel.mehrbrodt@allotropia.de>
2023-12-07 08:03:36 +01:00
Gabor Kelemen 9e8df5bfe8 tdf#148986 Support XF86Forward / XF86Back key events
Multimedia keys found on certain presentation clicker devices.
Not added to the Customize dialog, as that was not yet asked for.
As I have no access to a MAC, did not add support for that in vcl.

Inspiration for code taken from
commit ca74511985

Change-Id: I417e6ba7e79c5f6e774a56ba747803a156d5f50f
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/160255
Tested-by: Thorsten Behrens <thorsten.behrens@allotropia.de>
Reviewed-by: Thorsten Behrens <thorsten.behrens@allotropia.de>
2023-12-06 15:51:42 +01:00
Regina Henschel 44ee19c99b [API CHANGE] Add OOXML way of curved connector routing
The paths generated for curved connectors are basically incompatible
between LibreOffice and OOXML. Thus it was not possible to render curved
connectors the same way as MS Office. The patch adds an OOXML compatible
method for calculating the path. The new method results in a different
svg:d attribute when saved in ODF, but needs no change to ODF.

The patch introduces the boolean connector property 'EdgeOOXMLCurve' to
switch between the two methods. The property value is determined from
the svg:d attribute in case of import from ODF. In case of missing
svg:d attribute the property value is set to 'true', because Word
currently does not write a svg:d attribute when it exports to ODF.
The property value is set to 'true' for import of connectors on a
drawing canvas in docx. Default value for new connectors is 'false'.

The new property has no UI, but can be used via macro.

Currently the new method is used for import of curved connectors on
drawing canvas in docx documents.

Change-Id: I53d99f44febe4d74c2b611f5fdb9de86628c4519
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/159708
Tested-by: Jenkins
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2023-12-01 08:44:01 +01:00
Miklos Vajna a596070f8a sw floattable, per-frame wrap-on-all-pages mode: add UNO API
This exposes the internal property SwFormatWrapTextAtFlyStart on the UNO
API.

We need this, because otherwise the ODT filter can't read/write it.

Change-Id: I67d3c28e3531b19183f8361a6df87b7a4ca84294
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/159888
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
Tested-by: Jenkins
2023-11-24 10:05:38 +01:00
Samuel Mehrbrodt a91892ec49 Use existing types, instead of strings
as suggested in https://gerrit.libreoffice.org/c/core/+/158028/comments/b7a803f4_7e5899ca

Change-Id: I7d4c46b24307922b51e463bacdfacfca85956b80
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/159524
Reviewed-by: Stephan Bergmann <stephan.bergmann@allotropia.de>
Tested-by: Jenkins
Reviewed-by: Samuel Mehrbrodt <samuel.mehrbrodt@allotropia.de>
2023-11-20 11:17:23 +01:00
Andrea Gelmini c09de4e11c Fix typo
Change-Id: Idcfcd6aca1c74cb3e10dac09cd347b69a9bdb949
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/159406
Tested-by: Jenkins
Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2023-11-14 22:32:38 +01:00
Andrea Gelmini 5767cb0eaf Fix typo
Change-Id: Id3be5eb786bfa245155fef17e819a72dee322e18
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/159397
Tested-by: Jenkins
Reviewed-by: Taichi Haradaguchi <20001722@ymail.ne.jp>
2023-11-14 12:37:44 +01:00
Michael Weghorn d6c6472bbe tdf#123864 a11y: Add new AccessibleStateType::CHECKABLE
Both, AT-SPI and IAccessible2 have a CHECKABLE state
that describes whether an item is checkable, i.e.
whether it can be checked, i.e. whether it is possible
that this object can have the CHECKED state.

So far, LibreOffice didn't have any equivalent, and
e.g. a checkbox that is ticked would report state
CHECKED but not CHECKABLE, which is inconsistent.
("How can an object that is not checkable be checked?")

For an unchecked object, the fact that it can be checked
is unclear since that one will just have the CHECKED state
not being present.

Introduce a new a11y state, `AccessibleStateType::CHECKABLE`
with the same semantics as in AT-SPI and IAccessible2 to
bridge the gap.

Map the state in winaccessibility (to IAccessible2),
gtk3 and an the Qt-based VCL plugins, which are
responsible for mapping to AT-SPI.

While Qt has an equivalent state flag, it currently
doesn't map that to AT-SPI yet.
Pending upstream Gerrit change to implement that: [1]

The gtk4 a11y API doesn't have a direct equivalent and will
be handled separately in a following commit.

Reporting the new state where applicable will be
implemented in following commits.

[1] https://codereview.qt-project.org/c/qt/qtbase/+/517844

Change-Id: I6aa7fec3b3bd728a5cfedcdc8d6b66f06337f7ce
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/159382
Tested-by: Jenkins
Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
2023-11-14 08:09:02 +01:00
Mike Kaganski c60a9db1f2 tdf#158185: fix Excel's Range.Find and Range.Replace wildcard recognition
VBAToRegexp is wrong, using Basic wildcards. The functionality introduced
in tdf#72196 matches the required wildcard repertoire.

This introduces a new WildcardEscapeCharacter property to SearchDescriptor
service. Interestingly, the default value there was backslash.

TODO: also fix Range.AutoFilter, and drop VBAToRegexp. To do that, a new
property is needed in service SheetFilterDescriptor, to use wildcards,
in addition to "UseRegularExpressions" property.

Change-Id: Idebcf00d4b7376e5d7feaf8ae800fb19d05689d4
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/159391
Tested-by: Jenkins
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2023-11-13 23:06:18 +01:00
Samuel Mehrbrodt 700ac29771 Use proper type in expert config dialog
In preparation for proper editing support for the different types.

Change-Id: I7044ff100c9bfcca5fa8894ff4525a1aac692796
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/158028
Tested-by: Jenkins
Reviewed-by: Samuel Mehrbrodt <samuel.mehrbrodt@allotropia.de>
2023-11-09 15:37:16 +01:00
Samuel Mehrbrodt db3078bd8c tdf#157431 Show description for expert config items
Change-Id: I7d0257c2e06ed384f90ca3b51a6d2549044f2cf3
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/157148
Tested-by: Jenkins
Reviewed-by: Samuel Mehrbrodt <samuel.mehrbrodt@allotropia.de>
2023-11-09 08:14:38 +01:00
Mike Kaganski ce625d02aa Clarify FROM_LIST_AND_SIGNED_WARN description a bit
Change-Id: Icab6b5b2e0c290bf67f1b330ad82553e9e37328e
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/159098
Tested-by: Jenkins
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2023-11-08 11:39:14 +01:00
Mike Kaganski 59c7713e3a Fix a typo
Change-Id: I01dae264822c5394cabbb5cc4f7d4cb63190d23e
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/159030
Tested-by: Jenkins
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2023-11-07 13:25:00 +01:00
Skyler Grey e195c22533 Enable STYLEREF flag export/import with OOXML
This commit enables exporting the following STYLEREF flags with OOXML
- Search from bottom to top
- Hide non numerical

After this commit, the following steps have been implemented
- The document model (I7d8f455ffe90cface4f3b1acf6b9bef6a045ed19)
- The layout (I7d8f455ffe90cface4f3b1acf6b9bef6a045ed19)
- The UI (I7d8f455ffe90cface4f3b1acf6b9bef6a045ed19)
- UNO
- DOCX filter

Change-Id: Ib664fec059aa1f7f130acc76c253d5d298fa59f7
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/158350
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
2023-10-30 20:04:01 +01:00
Michael Weghorn b7d2a9c824 tdf#135586 sw a11y: Use BLOCK_QUOTE role for "Block Quotation" para
If a paragraph is using the "Block Quotation" paragraph style,
report the newly introduced BLOCK_QUOTE a11y role for it instead
of the PARAGRAPH role.

This is similar to how the HEADING role is reported when
one of the paragraph styles for headings is used
(s. `SwAccessibleParagraph::GetRealHeadingLevel`).

This is also in line with what is documented for mapping
LO elements to tagged PDF elements in
sw/inc/EnhancedPDFExportHelper.hxx:

> * Mapping of OOo elements to tagged pdf elements:
> *
> * OOo element                              tagged pdf element
> * -----------                              ------------------
> * [...]
> * SwFormat Quotations                       BlockQuote

This makes the Orca screen reader with the gtk3 VCL plugin on Linux
and the NVDA screen reader on Windows explicitly announce a paragraph
as block quote when moving there with the cursor.

Adapt some places that have specific handling for the
PARAGRAPH role to take into account the BLOCK_QUOTE
role as well.

Change-Id: I4a89625c2a3f07d37df09e68cb7045a59cfff633
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/158574
Tested-by: Jenkins
Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
2023-10-28 05:45:25 +02:00
Michael Weghorn f44eae4912 tdf#135586 a11y: Add a new BLOCK_QUOTE a11y role
A block quote role exists in all of WAI-ARIA 1.3
(role "blockquote", [1]), IAccessible2
(`IA2_ROLE_BLOCK_QUOTE`,  [2]) and AT-SPI
(`ROLE_BLOCK_QUOTE`, [3]).

Take over the definition that is the same in WAI-ARIA
and IAccessible2:

> A section of content that is quoted from another source.

The intended use for now is for a Writer paragraph using
the "Block Quotation" paragraph style, similar to how the
HEADING role is used for paragraphs using a corresponding
paragraph style.

For gtk3 (ATK) and winaccessibility (IAccessible2),
map the new role to the equivalant roles.

For macOS and the gtk4 as well as the Qt-based VCL plugins
on Linux which currently don't have an equivalent role,
fall back to the same role that the PARAGRAPH role is
mapped to.
This way, the behavior there will remain unchanged
once the BLOCK_QUOTE role is used for Writer paragraphs
with the corresponding style.

In general, treat BLOCK_QUOTE like PARAGRAPH
in code applying special handling for the PARAGRAPH
role.

[1] https://w3c.github.io/aria/#blockquote
[2] https://github.com/LinuxA11y/IAccessible2/blob/3d8c7f0b833453f761ded6b12d8be431507bfe0b/api/AccessibleRole.idl#L318
[3] https://gitlab.gnome.org/GNOME/at-spi2-core/-/blob/7cc4cee53ddbd22631fd110f0e5ce045dec2e411/xml/Accessible.xml#L615-616

Change-Id: I248c183a2e7ec5d6f0a89bf3cb4829bbd8588c77
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/158573
Tested-by: Jenkins
Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
2023-10-28 05:45:15 +02:00
Noel Grandin 0446f73d27 tdf#153519 use new IdleTask::waitUntilIdleDispatched
to wait until the Idle inside sw/ has done populating the navigator
tree.

Which required
(*) moving the code down from test/ to vcl/ to avoid circular dependency
issues.
(*) adding a call SolarMutexGuard before Application::Yield inside
IdleTask::waitUntilIdleDispatched
(*) exposing the function to python by adding a method to the
XToolkitExperimental UNO API

Change-Id: Iee418f7a0beb1f5b53addb7fe25823d61720eb3a
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/158495
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2023-10-26 16:10:29 +02:00
Andrea Gelmini 11b12589c2 Fix typo
Change-Id: Iac1d0f9a00fe5ccab84da1f1fb033354920341fa
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/158366
Tested-by: Jenkins
Reviewed-by: Taichi Haradaguchi <20001722@ymail.ne.jp>
2023-10-24 09:38:43 +02:00
Michael Weghorn a8cfd280fb a11y: Make XAccessibleValue doc more consistent
* Align the method names in the documentation
  to what the acual methods are called
  (e.g. `getMaximumValue`, not `getMaximumAccessibleValue`).

* Use "minimum" and "maximum" consistently, not "minimal"
  and "maximal" in some places.

Change-Id: Idf4f36dca118a614b04a4b958e97d225f70dde0d
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/158347
Tested-by: Jenkins
Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
2023-10-23 20:36:07 +02:00
Michael Weghorn cfaa52ed74 a11y: Improve XAccessibleExtendedAttributes doc
The existing

    // MT: I guess it's not formula only?

comment was justified.

`XAccessibleExtendedAttributes::getExtendedAttributes`,
is not only used to report formulae, but e.g. used to
report a heading level by Writer paragraphs
(s. `SwAccessibleParagraph::getExtendedAttributes`),
so adjust the documentation and align it with
the `IAcccessible2::attributes` one [1] that also
uses the cell formula as an example.

[1] https://accessibility.linuxfoundation.org/a11yspecs/ia2/docs/html/interface_i_accessible2.html#a0d51b0c189a000ee3b6ddf7f68da2009

Change-Id: I2d6f38911c3802edb55f9426a35b8986dd6e399a
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/158259
Tested-by: Jenkins
Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
2023-10-21 13:48:59 +02:00
Skyler Grey 32c588dd11 tdf#86790: Add support for a word-style styleref
STYLEREF is a field type in Word which changes its content based on
nearby paragraphs. For example, upon creating a styleref referencing
"Heading 1" you will see the text of the nearest "Heading 1"-styled
paragraph that is above the field.

This patch implements STYLEREF in Writer as a cross-reference. By using
"insert>cross-reference>styles" you'll be presented with a list of
styles. Selecting one and clicking "insert" will create a field which
has text from the "most relevant" instance of the style. To find the
most relevant instance we first search up for paragraphs with the style,
and if there are any we take the closest. If there weren't any, we
search down for paragraphs with the style.

This patch also updates our use of STYLEREF for chapters exported to
docx by using it for all chapters not only those in headers and footers.
This allows us to approximate more chapter field functionality even when
moving between Writer and Word.

Finally, this patch adds some tests for STYLEREF:
- testTdf86790 tests that the "sample file with STYLEREF" document from
  tdf#86790 has the correct fields
- testStyleRefSearchUp tests that the STYLEREF searches up when there
  are bits of text both above and below it
- testStyleRefSearchDown tests that the STYLEREF searches down when
  there are bits of text below it only
- testMarginalStyleRef tests that the STYLEREF searches from the page
  top when it is placed in a footer
- testFootnotetyleRef tests that the STYLEREF searches from the
  reference mark when it is placed in a footnote

Still TODO:
- [  ] Update documentation
- [  ] Implement reverse-searching (\l) and nondelimiter
       suppression (\t)
       - Probably these 2 will be in a followup patch

Change-Id: I25dd7a6940abee5651a784b9059fe23b32547d6c
Signed-off-by: Skyler Grey <skyler.grey@collabora.com>
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/157456
Tested-by: Jenkins
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2023-10-20 08:53:34 +02:00
Gökay Şatır ca74511985 Add NUMBERSIGN key handler.
German keyboard layout has number sign key.
Users can print number sign without using modification keys.
So this key can be assigned a shortcut.
Subscript is assigned to CTRL + NUMBERSIGN.

Below PR is used as reference when adding the new key handler:
https://gerrit.libreoffice.org/c/core/+/86713

Signed-off-by: Gökay Şatır <gokaysatir@collabora.com>
Change-Id: I340dc47764e9200d2477f8db740a629f62f48004
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/157554
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
(cherry picked from commit 1db8f6d484b884301a7d3673f4d05478e28cd853)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/157959
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
2023-10-14 21:51:43 +02:00
Jaume Pujantell 5082d50d24 writerfilter: use content controls for text in block SDTs
Text inside block SDTs was shown as Text Fields wich ignored properties such as
alias and formatting. Now those texts are imported as content controls like in
the case of run SDTs.

Added the ability for content controls to remember and export the "multiline"
property of block SDT text.

Some existing tests have been changed due to some different export results.

Change-Id: Ice1eb4ca6dd53c99d5abb239371f8ac896c3b6e4
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/156867
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
Tested-by: Jenkins
2023-10-11 15:19:58 +02:00
Noel Grandin dd009cffc3 tdf#157650 Unhelpful error when XML in content.xml is malformed
regression from
    commit d9e322d60f
    replace ErrorInfo with simpler mechanism
we need to tunnel the necessary information through the uui stuff, so
add a new Exception class to do that.

Change-Id: Ie1fde486e8637b802340795348a5e5aad6a54e96
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/157732
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2023-10-09 22:13:18 +02:00
Rafael Lima 8938bc7039 tdf#154449 Add support for hidden named ranges
This patch adds the possibility of having "hidden" named ranges in Calc, in a way similar to what MS Excel has (i.e. they're not visible in the UI and can only be hidden/shown via scripting).

This is done by creating a new HIDDEN flag in com.sun.star.sheet.NamedRangeFlag.

Hence thia patch makes it so that named ranges can be made hidden/visible via scripting. For instance, consider a Calc document with a named range "NamedRange1". The following scripts hides "NamedRange1" from the UI (i.e. it's no longer visible in the Manage Names dialog):

Sub SetHidden
  Dim eFlags : eFlags = com.sun.star.sheet.NamedRangeFlag
  aNamedRange = ThisComponent.NamedRanges.getByName("NamedRange1")
  nType = aNamedRange.getType() Or eFlags.HIDDEN
  aNamedRange.setType(nType)
End Sub

To make the named range visible again:

Sub RemoveHidden
  Dim eFlags : eFlags = com.sun.star.sheet.NamedRangeFlag
  aNamedRange = ThisComponent.NamedRanges.getByName("NamedRange1")
  nType = aNamedRange.getType()
  nType = nType - (aNamedRange.getType() And eFlags.HIDDEN)
  aNamedRange.setType(nType)
End Sub

This patch also implements ODS and OOX import/export, as well as QA tests.

Change-Id: I10efe46938fe772b87dc17fc597cb83648b5efb2
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/155599
Tested-by: Jenkins
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2023-10-01 13:01:32 +02:00
Sarper Akdemir 43df1237a0 remove repeated idl file in gb_UnoApi_add_idl_files call
XConditionEntry was repeated twice on line 3498 and 3495 of
offapi/UnoApi_offapi.mk

Removed the first one.

Change-Id: I7dd7db3c527a2a6825363ba4fb24eb266f870f53
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/156857
Tested-by: Jenkins
Reviewed-by: Sarper Akdemir <sarper.akdemir.extern@allotropia.de>
2023-09-12 23:32:07 +02:00
Stephan Bergmann 2bd5b489db Fix some misspelled LibreOffice @since tags
Change-Id: Id6602a06574e435b09a36997f3d1dd5cf3a6859e
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/156693
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2023-09-08 11:16:50 +02:00
Stephan Bergmann d016642988 Update the reference rdbs to libreoffice-7.6.0.3
.../master/instdir/sdk/bin/unoidl-read --published \
 .../libreoffice-7.6.0.3/instdir/program/types.rdb \
 >.../master/udkapi/type_reference/udkapi.idl

.../master/instdir/sdk/bin/unoidl-read --published \
 .../libreoffice-7.6.0.3/instdir/program/types.rdb \
 .../libreoffice-7.6.0.3/instdir/program/types/offapi.rdb \
 >.../master/offapi/type_reference/offapi.idl

Change-Id: I3ed0f2fd05caaeb083ac8d5f3c40c30c389847b2
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/156529
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2023-09-05 07:36:05 +02:00
Sarper Akdemir 0deea02b1d tdf#138792: PDF export: add batch of dublin core attributes
Adds support for exporting, editing in the UI and storage in
ODF for the dublin core attributes listed below.

Contributor (http://purl.org/dc/elements/1.1/contributor)
Coverage (http://purl.org/dc/elements/1.1/coverage)
Identifier (http://purl.org/dc/elements/1.1/identifier)
Publisher (http://purl.org/dc/elements/1.1/publisher)
Relation (http://purl.org/dc/elements/1.1/relation)
Rights (http://purl.org/dc/elements/1.1/rights)
Source (http://purl.org/dc/elements/1.1/source)
Type (http://purl.org/dc/elements/1.1/type)

Introduces XDocumentProperties2 to extend XDocumentProperties interface.

Change-Id: Ie2e0b1fbbbd00b66aef477ba1bf4e4f61c03a3b3
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/156330
Tested-by: Jenkins
Reviewed-by: Sarper Akdemir <sarper.akdemir.extern@allotropia.de>
2023-09-04 20:54:19 +02:00
Khaled Hosny 5c5c71266f tdf#134193: Add the ability to set RTL math direction
This adds a new IsRightToLeft document property, reads/writes it, and
sets dir="rtl" on the top level MathML <math> element if set to true.

Rendering will be handled in next commits.

Change-Id: Ia3078b8a269fef7c3f037a2f1b7799744df2680b
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/155737
Tested-by: Jenkins
Reviewed-by: خالد حسني <khaled@libreoffice.org>
2023-09-04 18:15:50 +02:00
Pierre 5b205d2b39 tdf#156816 Base handles scale on SQL type TIME as with TIMESTAMP
Generally import new DataType identification constants from OpenJDK's
java.sql.Types
Use same values for compatibility.

Change-Id: I6e3eb986dc34e8a5e2af75669363177785ff56e5
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/155866
Reviewed-by: Lionel Mamane <lionel@mamane.lu>
Tested-by: Julien Nabet <serval2412@yahoo.fr>
2023-08-31 20:28:50 +02:00
Tomaž Vajngerl 9d5a7d9257 ComplexColor various clean-up and (trivial) refactorings
Don't allow access to member variables of ComplexColor and makes
them private. Needs a lot of changes.

Change "scheme" to "theme" to be more consistent. In LO we usually
call the "theme color" what is usually refered to as "scheme color"
in OOXML, where it is sometimes refered to as "scheme" and other times
as theme color.

Remove ThemeColor class which was replaced with CmplexColor some
time ago.

Remove un-needed includes and un-needed components.

Use isValidThemeColor in many places where we check that the
ComplexColor is of "Theme" type and that ThemeColorType is set to
a valid value.

Change-Id: I325595fa65b8e56a4707e9d22acc6330aac28961
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/155359
Tested-by: Jenkins
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2023-08-15 20:58:13 +02:00
Michael Weghorn f3754e5dbb a11y: Drop extra "no" in XAccessibleComponent doc
Change-Id: I32870920d3eacf8c557870abf4a243bb1ba9f584
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/155454
Tested-by: Jenkins
Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
2023-08-08 16:36:16 +02:00
Michael Weghorn 3121642fb1 a11y: Clarify AccessibleEventId::ROLE_CHANGED doc
Mention that old and new value don't need to be
set in this kind of event and how the new role
can be retrieved.

Change-Id: Iefde16a91b71af87feccb5ec2e6a32e682d60b4c
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/154987
Reviewed-by: Colomban Wendling <cwendling@hypra.fr>
Tested-by: Jenkins
Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
2023-07-27 16:58:35 +02:00
Mike Kaganski 79113484ca [API CHANGE] tdf#144512: keep autosave interval separately for each document
Maybe this would make a better UX, as the request suggests ... or maybe not.

css::document::XDocumentRecovery2 is introduced for this, allowing to query
the document dirty state duration.

Change-Id: I25997788bc5da261f7e4131616ab8d4a245de380
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/154505
Tested-by: Jenkins
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2023-07-18 19:15:33 +02:00
Mike Kaganski fd64b426bc tdf#150408: Implement "Legal" numbering (all levels using Arabic numbers)
Enabling this feature on a list level makes all numbered sublevels, that
constitute the number of this level, to use Arabic numerals. This doesn't
change the labels of other levels: e.g., if level 1 uses A,B,C; level 2
uses i,ii,iii; level 3 uses a,b,c, and is "Legal"; and level 4 uses 1,2,3;
then a list may look like

  A. Something
    A.i. Some subitem
    A.ii. Another subitem
      1.2.1. This is a "Legal" sub-subitem
        A.ii.a.1. And its child

This improves interoperability with Word.

This change introduces document model, ODF and OOXML import and export.
In ODF, a new boolean attribute of 'text:outline-level-style' element,
'loext:is-legal', is introduced; its default value is "false".

Change-Id: I5ae9f970864854c7e84c4b2f7ce46634b3ef104e
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/154288
Tested-by: Jenkins
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2023-07-11 14:02:19 +02:00
Michael Stahl 6efc72b99a tdf#138504 svx,etc.: decorative flag on SdrObject shapes
* SdrObject new member m_IsDecorative
* new Undo SdrUndoObjDecorative
* surprising amount of changes in sw including additional SwUndoFlyDecorative
* svx API SvxShape property "Decorative"
* UI checkbox "Decorative"
* ODF import/export as loext:decorative on style:graphic-properties
* PDF/UA export: ViewObjectContcat tag shapes with this flag as Artifact

Change-Id: I37f7a0597eab92c6c6aff94fad6c16c59b231c80
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/154063
Tested-by: Jenkins
Reviewed-by: Michael Stahl <michael.stahl@allotropia.de>
2023-07-05 19:54:17 +02:00
Michael Stahl a67675e7e2 offapi: add Title/Description properties from CWS aw038 (OOo 2.2)
Change-Id: I2a851ef76b840d1fa5479dcb182a63590a2d4065
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/154052
Tested-by: Jenkins
Reviewed-by: Michael Stahl <michael.stahl@allotropia.de>
2023-07-05 15:45:55 +02:00
Khaled Hosny 68a4f005bc tdf#155810: Pass Kashida insertion positions through canvas
This was missed in:

commit 3901e029bd
Author: Khaled Hosny <khaled@aliftype.com>
Date:   Mon Aug 8 22:08:37 2022 +0200

    tdf#104921: Cleanup Kashida insertion logic

The width adjustment passed through, but Kashida insertion positions
didn’t, leaving gaps in place of Kashidas when canvas is used
(apparently canvas is only used for slideshow).

Change-Id: I25ff30f10cc46a5c87bda2f3936df26b2fc926b1
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/153234
Tested-by: Jenkins
Reviewed-by: خالد حسني <khaled@libreoffice.org>
2023-06-18 22:01:53 +02:00
Noel Grandin e899a75fc6 Revert "Convert XFastParser into a normal C++ interface"
This reverts commit 5e68d6cfad.

Reason for revert: Seems like outside users have been using this API

Change-Id: I8814cf1eb4f000eeb4cbbb5db9c282d001465993
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/152441
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2023-06-01 15:07:18 +02:00
Noel Grandin 5e68d6cfad Convert XFastParser into a normal C++ interface
There is no need for it to be an UNO interface anymore (ever since
we started supporting dynamic_cast on UNO objects).

Which means that XImportFilter2 also needs become a C++ interface.

Change-Id: Ice2db0f098271bba32b199bd083b08cb8410ce93
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/152388
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2023-06-01 11:59:06 +02:00
Khaled Hosny d7ddac2085 Remove recently unused CTLScriptType code
This is now unused after:

commit 98f7ec383d
Author: Khaled Hosny <khaled@libreoffice.org>
Date:   Sun May 28 16:28:52 2023 +0300

    tdf#139863, tdf#155514: Don’t split COMPLEX text portions

The code is also broken as it doesn’t handle surrogate pairs.

The UNO API now throws an exception.

Change-Id: I454ed741e3834e762a2731d671c21a3e73515da3
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/152359
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
Reviewed-by: خالد حسني <khaled@libreoffice.org>
2023-05-29 16:23:07 +02:00
Olivier Hallot 363c6bec73 Fix text in IDL file
+ Copy&Paste is evil...

Change-Id: I11352ec41d96cfbc7d4176773789066aee292a0a
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/152281
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2023-05-26 08:35:19 +02:00
Miklos Vajna 98a87f0158 [API CHANGE] remove XModuleUIConfigurationManager3 and XUIConfigurationManager3
The motivation was to not modify XModuleUIConfigurationManager /
XUIConfigurationManager, but as pointed out at
<https://gerrit.libreoffice.org/c/core/+/151798/10#message-31d00a775989b981a5f50639623cc773d6ea930d>,
it may be fine to modify XModuleUIConfigurationManager2 and
XUIConfigurationManager2 instead of adding
XModuleUIConfigurationManager3 and XUIConfigurationManager3.

Indeed, searching for usage in <https://github.com/libreoffice/wollmux>,
only the published interfaces are used, so let's fold
XModuleUIConfigurationManager3 into XModuleUIConfigurationManager2 and
XUIConfigurationManager3 into XUIConfigurationManager2.

This is a reasonable middle ground between 0 API change and breaking
known users of the public API.

Change-Id: I2dedee7e255f9dda9c9057961e6c829f83b2b709
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/152254
Tested-by: Jenkins
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2023-05-25 10:35:41 +02:00
Gökay Şatır d4bc98c5bf [API CHANGE] Add createShortCutManager function to uiconfigurationmanager.
We need to have different accelerator classes for differnt languages.
This PR creates a new accelerator class for different languages.

Since current code uses single instance for accelerators, i needed to add a create function.

Also we now have an unordered map for different languages and modules.

Reviewed-on: https://gerrit.libreoffice.org/c/core/+/147157
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/148680
Tested-by: Miklos Vajna <vmiklos@collabora.com>
Change-Id: Ia646f20b3206f430ece614fc127e8b748044e4c7
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151798
Tested-by: Jenkins
2023-05-23 15:40:57 +02:00
Julien Nabet 82816547cc idl: they're not params but attributes
Fix these warnings:
/home/tdf/jenkins/workspace/gerrit_windows@2/offapi/com/sun/star/ui/dialogs/DialogClosedEvent.idl:33:
warning: com::sun::star::ui::dialogs::DialogClosedEvent::DialogResult has @param documentation sections but no arguments

/home/tdf/jenkins/workspace/gerrit_windows@2/offapi/com/sun/star/ui/dialogs/FilePickerEvent.idl:29:
warning: com::sun::star::ui::dialogs::FilePickerEvent::ElementId has @param documentation sections but no arguments

Change-Id: Ic2ae5f70f3f6aa744bd61044f80e9ab525407ecc
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/152020
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Tested-by: Noel Grandin <noel.grandin@collabora.co.uk>
2023-05-20 12:56:37 +02:00
László Németh f517c839f7 sw offapi: clean up com::sun::star::text::CellProperties::HasTextChangesOnly
Reported by Stephan Bergmann.

Change-Id: Ide8d17dcc7775f3a4f97088e2cbb00ddef271929
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151676
Tested-by: Jenkins
Reviewed-by: László Németh <nemeth@numbertext.org>
2023-05-12 08:58:00 +02:00
Tomaž Vajngerl ca3bfa9bde change ComplexColor to show more useful properties
Change-Id: Ie19f080f2faf388f9b8ba3e9a4b3c0926d5ebdd4
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151674
Tested-by: Jenkins
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2023-05-12 05:00:39 +02:00