summaryrefslogtreecommitdiff
path: root/xmloff/inc
diff options
context:
space:
mode:
authorSkyler Grey <skyler.grey@collabora.com>2023-10-20 14:30:31 +0000
committerCaolán McNamara <caolan.mcnamara@collabora.com>2023-10-30 20:07:01 +0100
commit6412a74b35a3e6089b65b4ad04549262e4bf93c8 (patch)
tree34d931f8fb5883b9b30967c5422c361558eb81cc /xmloff/inc
parente195c22533de44cd4f6afab7836c7eb6a613d202 (diff)
Enable STYLEREF flag export/import with ODF
This commit enables exporting the following STYLEREF flags with ODF - 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 (Ib664fec059aa1f7f130acc76c253d5d298fa59f7) - DOCX/ODF filters (here and Ib664fec059aa1f7f130acc76c253d5d298fa59f7) Change-Id: Iad8e8001807f5ceeaedc9665838672695174a936 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/158351 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
Diffstat (limited to 'xmloff/inc')
-rw-r--r--xmloff/inc/txtfld.hxx28
-rw-r--r--xmloff/inc/txtflde.hxx9
-rw-r--r--xmloff/inc/txtfldi.hxx2
3 files changed, 39 insertions, 0 deletions
diff --git a/xmloff/inc/txtfld.hxx b/xmloff/inc/txtfld.hxx
new file mode 100644
index 000000000000..c562644a5f18
--- /dev/null
+++ b/xmloff/inc/txtfld.hxx
@@ -0,0 +1,28 @@
+/* -*- 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/.
+ *
+ * This file incorporates work covered by the following license notice:
+ *
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed
+ * with this work for additional information regarding copyright
+ * ownership. The ASF licenses this file to you under the Apache
+ * License, Version 2.0 (the "License"); you may not use this file
+ * except in compliance with the License. You may obtain a copy of
+ * the License at http://www.apache.org/licenses/LICENSE-2.0 .
+ */
+
+/** @#file
+ * Constants, helpers etc. that need to be shared between text field import
+ * and export
+ */
+
+#pragma once
+
+#define REFFLDFLAG_STYLE_FROM_BOTTOM 0xc100
+#define REFFLDFLAG_STYLE_HIDE_NON_NUMERICAL 0xc200
diff --git a/xmloff/inc/txtflde.hxx b/xmloff/inc/txtflde.hxx
index 459dea29f550..f98fb7c5c421 100644
--- a/xmloff/inc/txtflde.hxx
+++ b/xmloff/inc/txtflde.hxx
@@ -34,6 +34,8 @@
#include <memory>
#include <string_view>
+#include "txtfld.hxx"
+
class SvXMLExport;
struct XMLPropertyState;
@@ -239,6 +241,13 @@ private:
bool i_bAutoStyles, bool i_bProgress,
bool & rPrevCharIsSpace);
+
+ void ProcessBoolean(
+ enum ::xmloff::token::XMLTokenEnum eXmlName, /// attribute token
+ bool bBool, /// attribute value
+ bool bDefault,
+ sal_uInt16 nPrefix); /// namespace
+
/// export a boolean attribute
void ProcessBoolean(
enum ::xmloff::token::XMLTokenEnum eXmlName, /// attribute token (namespace text)
diff --git a/xmloff/inc/txtfldi.hxx b/xmloff/inc/txtfldi.hxx
index 0a15329c31ec..3d56c547811e 100644
--- a/xmloff/inc/txtfldi.hxx
+++ b/xmloff/inc/txtfldi.hxx
@@ -34,6 +34,7 @@
#include <xmloff/xmltkmap.hxx>
#include <rtl/ustrbuf.hxx>
#include <vector>
+#include "txtfld.hxx"
namespace com::sun::star {
namespace xml::sax { class XAttributeList; }
@@ -795,6 +796,7 @@ class XMLReferenceFieldImportContext final : public XMLTextFieldImportContext
sal_Int32 nElementToken;
sal_Int16 nSource;
sal_Int16 nType;
+ sal_uInt16 nFlags;
bool bNameOK;
bool bTypeOK;