tdf#130857 qt weld: Implement QtInstanceWidget::strip_mnemonic
[LibreOffice.git] / i18npool / source / characterclassification / unoscripttypedetector.cxx
blob673b486d73aa1a4b0702a2c56994f509d74cd3dc
1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 /*
3 * This file is part of the LibreOffice project.
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/.
9 * This file incorporates work covered by the following license notice:
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 .
20 #include <unoscripttypedetector.hxx>
21 #include <cppuhelper/supportsservice.hxx>
22 #include <i18nutil/scripttypedetector.hxx>
24 namespace com::sun::star::uno { class XComponentContext; }
26 sal_Int16 SAL_CALL
27 UnoScriptTypeDetector::getScriptDirection( const OUString& Text, sal_Int32 nPos, sal_Int16 defaultScriptDirection )
29 return ScriptTypeDetector::getScriptDirection(Text, nPos, defaultScriptDirection);
32 // return value '-1' means either the direction on nPos is not same as scriptDirection or nPos is out of range.
33 sal_Int32 SAL_CALL
34 UnoScriptTypeDetector::beginOfScriptDirection( const OUString& Text, sal_Int32 nPos, sal_Int16 direction )
36 return ScriptTypeDetector::beginOfScriptDirection(Text, nPos, direction);
39 sal_Int32 SAL_CALL
40 UnoScriptTypeDetector::endOfScriptDirection( const OUString& Text, sal_Int32 nPos, sal_Int16 direction )
42 return ScriptTypeDetector::endOfScriptDirection(Text, nPos, direction);
45 sal_Int16 SAL_CALL
46 UnoScriptTypeDetector::getCTLScriptType( const OUString&, sal_Int32 )
48 throw css::uno::RuntimeException(u"not implemented"_ustr);
51 sal_Int32 SAL_CALL
52 UnoScriptTypeDetector::beginOfCTLScriptType( const OUString&, sal_Int32 )
54 throw css::uno::RuntimeException(u"not implemented"_ustr);
57 sal_Int32 SAL_CALL
58 UnoScriptTypeDetector::endOfCTLScriptType( const OUString&, sal_Int32 )
60 throw css::uno::RuntimeException(u"not implemented"_ustr);
63 OUString SAL_CALL
64 UnoScriptTypeDetector::getImplementationName()
66 return u"com.sun.star.i18n.ScriptTypeDetector"_ustr;
69 sal_Bool SAL_CALL
70 UnoScriptTypeDetector::supportsService(const OUString& ServiceName)
72 return cppu::supportsService(this, ServiceName);
75 css::uno::Sequence< OUString > SAL_CALL
76 UnoScriptTypeDetector::getSupportedServiceNames()
78 return { u"com.sun.star.i18n.ScriptTypeDetector"_ustr };
81 extern "C" SAL_DLLPUBLIC_EXPORT css::uno::XInterface *
82 com_sun_star_i18n_ScriptTypeDetector_get_implementation(
83 css::uno::XComponentContext *,
84 css::uno::Sequence<css::uno::Any> const &)
86 return cppu::acquire(new UnoScriptTypeDetector);
89 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */