LibreOffice Module writerfilter (master) 1
ConversionHelper.hxx
Go to the documentation of this file.
1/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2/*
3 * This file is part of the LibreOffice project.
4 *
5 * This Source Code Form is subject to the terms of the Mozilla Public
6 * License, v. 2.0. If a copy of the MPL was not distributed with this
7 * file, You can obtain one at http://mozilla.org/MPL/2.0/.
8 *
9 * This file incorporates work covered by the following license notice:
10 *
11 * Licensed to the Apache Software Foundation (ASF) under one or more
12 * contributor license agreements. See the NOTICE file distributed
13 * with this work for additional information regarding copyright
14 * ownership. The ASF licenses this file to you under the Apache
15 * License, Version 2.0 (the "License"); you may not use this file
16 * except in compliance with the License. You may obtain a copy of
17 * the License at http://www.apache.org/licenses/LICENSE-2.0 .
18 */
19#pragma once
20
21#include <sal/types.h>
22#include <rtl/ustring.hxx>
23#include <com/sun/star/util/DateTime.hpp>
24#include <com/sun/star/style/NumberingType.hpp>
25#include <com/sun/star/table/BorderLine2.hpp>
26#include <com/sun/star/text/RubyAdjust.hpp>
27
28namespace com::sun::star{
29 namespace lang{
30 struct Locale;
31 }
32 namespace table{
33 struct BorderLine2;
34 }
35}
36
38
39 // create a border line and return the distance value
40 void MakeBorderLine(sal_Int32 nLineThickness,
41 sal_Int32 nLineType,
42 sal_Int32 nLineColor,
43 css::table::BorderLine2& rToFill,
44 bool bIsOOXML);
45 //convert the number format string form MS format to SO format
46 OUString ConvertMSFormatStringToSO(const OUString& rFormat, css::lang::Locale& rLocale, bool bHijri);
47 // export just for test
48 SAL_DLLPUBLIC_EXPORT sal_Int32 convertTwipToMM100(sal_Int32 _t);
49 sal_Int32 convertTwipToMM100WithoutLimit(sal_Int32 _t);
50 double convertTwipToMM100Double(sal_Int32 _t);
51 SAL_DLLPUBLIC_EXPORT sal_uInt32 convertTwipToMM100Unsigned(sal_Int32 _t);
52 sal_Int16 convertTableJustification( sal_Int32 nIntValue );
53 css::text::RubyAdjust convertRubyAlign( sal_Int32 nIntValue );
54 sal_Int16 ConvertNumberingType(const sal_Int32 nFmt, const sal_Int16 nDefault = css::style::NumberingType::ARABIC);
55 sal_Int16 ConvertCustomNumberFormat(std::u16string_view rFormat);
56
57 css::util::DateTime ConvertDateStringToDateTime(std::u16string_view rDateTime);
58} // namespace writerfilter::dmapper::ConversionHelper
59
60/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
@ table
OUString ConvertMSFormatStringToSO(const OUString &rFormat, lang::Locale &rLocale, bool bHijri)
void MakeBorderLine(sal_Int32 nLineThickness, sal_Int32 nLineToken, sal_Int32 nLineColor, table::BorderLine2 &rToFill, bool bIsOOXML)
sal_uInt32 convertTwipToMM100Unsigned(sal_Int32 _t)
sal_Int32 convertTwipToMM100WithoutLimit(sal_Int32 _t)
sal_Int16 convertTableJustification(sal_Int32 nIntValue)
text::RubyAdjust convertRubyAlign(sal_Int32 nIntValue)
sal_Int16 ConvertNumberingType(const sal_Int32 nFmt, const sal_Int16 nDefault)
util::DateTime ConvertDateStringToDateTime(std::u16string_view rDateTime)
sal_Int16 ConvertCustomNumberFormat(std::u16string_view rFormat)