diff options
author | Miklos Vajna <vmiklos@collabora.com> | 2023-01-04 08:56:04 +0100 |
---|---|---|
committer | Miklos Vajna <vmiklos@collabora.com> | 2023-01-04 08:41:53 +0000 |
commit | babba472391d26aed68d7ac31c7a918c08e65256 (patch) | |
tree | 2f99dc80a00e67dcdbd5a643207463b5f706c1ea /sw/sdi | |
parent | 2eab74ab78b0b2a7a9c846251e2b79f595bc0878 (diff) |
sw, UpdateFields: add new TypeName, NamePrefix and Fields parameters
Currently the .uno:InsertField command allows inserting a refmark with a
provided name & content, but existing refmarks can't be updated
similarly. This is a problem in case Zotero citations are to be modeled
with refmarks.
Another trouble is that refmarks don't have dummy characters and have to
stay inside a single paragraph, so we need to be careful to replace the
content in a way that keeps the refmark alive, a naive delete + insert
will delete the refmark as well.
Fix the problem by extending the existing .uno:UpdateFields command with
3 new optional parameters, somewhat similar to what commit
724180ec495a696c79332653cb6fb52ecfbccc29 (sw: add a new
.uno:UpdateBookmarks UNO command, 2022-12-14) did.
As usual, the provided new text is meant to be HTML, which allows
formatted content.
Change-Id: Ib0951aa1a39e1b47bcf8b47bc9d65c89e0853e96
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/145033
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
Tested-by: Jenkins
Diffstat (limited to 'sw/sdi')
-rw-r--r-- | sw/sdi/swriter.sdi | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/sw/sdi/swriter.sdi b/sw/sdi/swriter.sdi index e14b52cba879..ebd54c064402 100644 --- a/sw/sdi/swriter.sdi +++ b/sw/sdi/swriter.sdi @@ -6514,7 +6514,7 @@ SfxVoidItem UpdateCurIndex FN_UPDATE_CUR_TOX ] SfxVoidItem UpdateFields FN_UPDATE_FIELDS -() +(SfxStringItem TypeName FN_PARAM_1, SfxStringItem NamePrefix FN_PARAM_2, SfxUnoAnyItem Fields FN_PARAM_3) [ AutoUpdate = FALSE, FastCall = TRUE, |