LibreOffice Module vcl (master) 1
fontcharmap.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
20#ifndef INCLUDED_FONTCHARMAP_HXX
21#define INCLUDED_FONTCHARMAP_HXX
22
23#include <vcl/dllapi.h>
24#include <vcl/vclenum.hxx>
25#include <tools/ref.hxx>
26#include <vector>
27
28class ImplFontCharMap;
29class FontCharMap;
30class OutputDevice;
31
34
36{
37public:
42
45 FontCharMap(bool bMicrosoftSymbolMap, std::vector<sal_UCS4> aRangeCodes);
46
47 virtual ~FontCharMap() override;
48
53 static FontCharMapRef GetDefaultMap(bool bMicrosoftSymbolMap);
54
60 bool IsDefaultMap() const;
61
66 bool HasChar( sal_UCS4 ) const;
67
77 int CountCharsInRange( sal_UCS4 cMin, sal_UCS4 cMax ) const;
78
83 int GetCharCount() const;
84
89 sal_UCS4 GetFirstChar() const;
90
95 sal_UCS4 GetLastChar() const;
96
105 sal_UCS4 GetNextChar( sal_UCS4 cChar ) const;
106
115 sal_UCS4 GetPrevChar( sal_UCS4 cChar ) const;
116
126 int GetIndexFromChar( sal_UCS4 cChar ) const;
127
137 sal_UCS4 GetCharFromIndex( int nCharIndex ) const;
138
139 bool isMicrosoftSymbolMap() const;
140
141private:
143
144 friend class ::OutputDevice;
145
146 int findRangeIndex( sal_UCS4 ) const;
147
149
150 // prevent assignment and copy construction
151 FontCharMap( const FontCharMap& ) = delete;
152 void operator=( const FontCharMap& ) = delete;
153};
154
155#endif // INCLUDED_FONTCHARMAP_HXX
156
157/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
ImplFontCharMapRef mpImplFontCharMap
FontCharMap(const FontCharMap &)=delete
void operator=(const FontCharMap &)=delete
Some things multiple-inherit from VclAbstractDialog and OutputDevice, so we need to use virtual inher...
Definition: outdev.hxx:170
#define VCL_DLLPUBLIC
Definition: dllapi.h:29
tools::SvRef< ImplFontCharMap > ImplFontCharMapRef
Definition: fontcharmap.hxx:30
tools::SvRef< FontCharMap > FontCharMapRef
Definition: fontcharmap.hxx:33
sal_uInt32 sal_UCS4
Definition: vclenum.hxx:160