office-gobmx/svx/inc/numberingtype.hrc
Stephan Bergmann dcea29c283 Make NC_ constexpr-friendly
...by moving the char8_t -> char reinterpret_cast out of any potential constexpr
paths into a new TranslateId::getId.  And demonstrate constexpr'ability by
making the aCategories var in OApplicationIconControl::Fill
(dbaccess/source/ui/app/AppIconControl.cxx) constexpr.  (And there might be more
such cases that could now be made constexpr.)

Change-Id: I0b4e3292faf8f6b901f9b9e934e1aa6bf0f583ff
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/157862
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2023-10-12 18:17:49 +02:00

74 lines
6.2 KiB
Text
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

/* -*- 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 .
*/
#ifndef INCLUDED_SVX_INC_NUMBERINGTYPE_HRC
#define INCLUDED_SVX_INC_NUMBERINGTYPE_HRC
#include <unotools/resmgr.hxx>
#include <utility>
#define NC_(Context, String) TranslateId(Context, u8##String)
const std::pair<TranslateId, int> RID_SVXSTRARY_NUMBERINGTYPE[] =
{
{ /* SVX_NUM_NUMBER_NONE */ NC_("RID_SVXSTRARY_NUMBERINGTYPE", "None") , 5 },
{ /* SVX_NUM_CHAR_SPECIAL */ NC_("RID_SVXSTRARY_NUMBERINGTYPE", "Bullet") , 6 },
{ /* SVX_NUM_BITMAP */ NC_("RID_SVXSTRARY_NUMBERINGTYPE", "Graphics") , 8 },
{ /* SVX_NUM_BITMAP|0x80 */ NC_("RID_SVXSTRARY_NUMBERINGTYPE", "Linked graphics") , 136 },
{ /* SVX_NUM_ARABIC */ NC_("RID_SVXSTRARY_NUMBERINGTYPE", "1, 2, 3, ...") , 4 },
{ /* SVX_NUM_CHARS_UPPER_LETTER */ NC_("RID_SVXSTRARY_NUMBERINGTYPE", "A, B, C, ...") , 0 },
{ /* SVX_NUM_CHARS_LOWER_LETTER */ NC_("RID_SVXSTRARY_NUMBERINGTYPE", "a, b, c, ...") , 1 },
{ /* SVX_NUM_ROMAN_UPPER */ NC_("RID_SVXSTRARY_NUMBERINGTYPE", "I, II, III, ...") , 2 },
{ /* SVX_NUM_ROMAN_LOWER */ NC_("RID_SVXSTRARY_NUMBERINGTYPE", "i, ii, iii, ...") , 3 },
{ /* TEXT_NUMBER */ NC_("RID_SVXSTRARY_NUMBERINGTYPE", "1st, 2nd, 3rd, ...") , 60 },
{ /* TEXT_CARDINAL */ NC_("RID_SVXSTRARY_NUMBERINGTYPE", "One, Two, Three, ...") , 61 },
{ /* TEXT_ORDINAL */ NC_("RID_SVXSTRARY_NUMBERINGTYPE", "First, Second, Third, ...") , 62 },
{ /* SVX_NUM_CHARS_UPPER_LETTER_N */ NC_("RID_SVXSTRARY_NUMBERINGTYPE", "A, .., AA, .., AAA, ...") , 9 },
{ /* SVX_NUM_CHARS_LOWER_LETTER_N */ NC_("RID_SVXSTRARY_NUMBERINGTYPE", "a, .., aa, .., aaa, ...") , 10 },
{ /* SYMBOL_CHICAGO */ NC_("RID_SVXSTRARY_NUMBERINGTYPE", "*, †, ‡, §, **, ††, ...") , 63 },
{ /* NATIVE_NUMBERING */ NC_("RID_SVXSTRARY_NUMBERINGTYPE", "Native Numbering") , 12 },
{ /* CHARS_CYRILLIC_UPPER_LETTER_BG */ NC_("RID_SVXSTRARY_NUMBERINGTYPE", "А, Б, .., Аа, Аб, ... (Bulgarian)") , 38 },
{ /* CHARS_CYRILLIC_LOWER_LETTER_BG */ NC_("RID_SVXSTRARY_NUMBERINGTYPE", "а, б, .., аа, аб, ... (Bulgarian)") , 39 },
{ /* CHARS_CYRILLIC_UPPER_LETTER_N_BG */ NC_("RID_SVXSTRARY_NUMBERINGTYPE", "А, Б, .., Аа, Бб, ... (Bulgarian)") , 40 },
{ /* CHARS_CYRILLIC_LOWER_LETTER_N_BG */ NC_("RID_SVXSTRARY_NUMBERINGTYPE", "а, б, .., аа, бб, ... (Bulgarian)") , 41 },
{ /* CHARS_CYRILLIC_UPPER_LETTER_RU */ NC_("RID_SVXSTRARY_NUMBERINGTYPE", "А, Б, .., Аа, Аб, ... (Russian)") , 42 },
{ /* CHARS_CYRILLIC_LOWER_LETTER_RU */ NC_("RID_SVXSTRARY_NUMBERINGTYPE", "а, б, .., аа, аб, ... (Russian)") , 43 },
{ /* CHARS_CYRILLIC_UPPER_LETTER_N_RU */ NC_("RID_SVXSTRARY_NUMBERINGTYPE", "А, Б, .., Аа, Бб, ... (Russian)") , 44 },
{ /* CHARS_CYRILLIC_LOWER_LETTER_N_RU */ NC_("RID_SVXSTRARY_NUMBERINGTYPE", "а, б, .., аа, бб, ... (Russian)") , 45 },
{ /* CHARS_CYRILLIC_UPPER_LETTER_SR */ NC_("RID_SVXSTRARY_NUMBERINGTYPE", "А, Б, .., Аа, Аб, ... (Serbian)") , 48 },
{ /* CHARS_CYRILLIC_LOWER_LETTER_SR */ NC_("RID_SVXSTRARY_NUMBERINGTYPE", "а, б, .., аа, аб, ... (Serbian)") , 49 },
{ /* CHARS_CYRILLIC_UPPER_LETTER_N_SR */ NC_("RID_SVXSTRARY_NUMBERINGTYPE", "А, Б, .., Аа, Бб, ... (Serbian)") , 50 },
{ /* CHARS_CYRILLIC_LOWER_LETTER_N_SR */ NC_("RID_SVXSTRARY_NUMBERINGTYPE", "а, б, .., аа, бб, ... (Serbian)") , 51 },
{ /* CHARS_CYRILLIC_UPPER_LETTER_UK */ NC_("RID_SVXSTRARY_NUMBERINGTYPE", "А, Б, .., Аа, Аб, ... (Ukrainian)") , 72 },
{ /* CHARS_CYRILLIC_LOWER_LETTER_UK */ NC_("RID_SVXSTRARY_NUMBERINGTYPE", "а, б, .., аа, аб, ... (Ukrainian)") , 73 },
{ /* CHARS_CYRILLIC_UPPER_LETTER_N_UK */ NC_("RID_SVXSTRARY_NUMBERINGTYPE", "А, Б, .., Аа, Бб, ... (Ukrainian)") , 74 },
{ /* CHARS_CYRILLIC_LOWER_LETTER_N_UK */ NC_("RID_SVXSTRARY_NUMBERINGTYPE", "а, б, .., аа, бб, ... (Ukrainian)") , 75 },
{ /* CHARS_GREEK_UPPER_LETTER */ NC_("RID_SVXSTRARY_NUMBERINGTYPE", "Α, Β, Γ, ... (Greek)"), 52 },
{ /* CHARS_GREEK_LOWER_LETTER */ NC_("RID_SVXSTRARY_NUMBERINGTYPE", "α, β, γ, ... (Greek)"), 53 },
{ /* NUMBER_HEBREW */ NC_("RID_SVXSTRARY_NUMBERINGTYPE", "א...י, יא...כ, ...") , 56 },
{ /* CHARS_HEBREW */ NC_("RID_SVXSTRARY_NUMBERINGTYPE", "א...ת, אא...תת, ...") , 33 },
{ /* NUMBER_ARABIC_INDIC */ NC_("RID_SVXSTRARY_NUMBERINGTYPE", "١, ٢, ٣, ٤, ... (Arabic)"), 57 },
{ /* NUMBER_EAST_ARABIC_INDIC */ NC_("RID_SVXSTRARY_NUMBERINGTYPE", "۱, ۲, ۳, ۴, ... (Farsi)"), 58 },
{ /* NUMBER_INDIC_DEVANAGARI */ NC_("RID_SVXSTRARY_NUMBERINGTYPE", "१, २, ३, ..."), 59 },
};
#endif
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */