Update git submodules
[LibreOffice.git] / drawinglayer / source / primitive3d / Tools.cxx
blob23ecc0851f40ea0367e97527398b4cf3cabe9c9e
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 */
11 #include <drawinglayer/primitive3d/Tools.hxx>
12 #include <drawinglayer/primitive3d/drawinglayer_primitivetypes3d.hxx>
14 using namespace css;
16 namespace drawinglayer::primitive3d
18 OUString idToString(sal_uInt32 nId)
20 switch (nId)
22 case PRIMITIVE3D_ID_GROUPPRIMITIVE3D:
23 return u"GROUPPRIMITIVE3D"_ustr;
24 case PRIMITIVE3D_ID_HATCHTEXTUREPRIMITIVE3D:
25 return u"HATCHTEXTUREPRIMITIVE3D"_ustr;
26 case PRIMITIVE3D_ID_MODIFIEDCOLORPRIMITIVE3D:
27 return u"MODIFIEDCOLORPRIMITIVE3D"_ustr;
28 case PRIMITIVE3D_ID_POLYGONHAIRLINEPRIMITIVE3D:
29 return u"POLYGONHAIRLINEPRIMITIVE3D"_ustr;
30 case PRIMITIVE3D_ID_POLYGONSTROKEPRIMITIVE3D:
31 return u"POLYGONSTROKEPRIMITIVE3D"_ustr;
32 case PRIMITIVE3D_ID_POLYGONTUBEPRIMITIVE3D:
33 return u"POLYGONTUBEPRIMITIVE3D"_ustr;
34 case PRIMITIVE3D_ID_POLYPOLYGONMATERIALPRIMITIVE3D:
35 return u"POLYPOLYGONMATERIALPRIMITIVE3D"_ustr;
36 case PRIMITIVE3D_ID_SDRCUBEPRIMITIVE3D:
37 return u"SDRCUBEPRIMITIVE3D"_ustr;
38 case PRIMITIVE3D_ID_SDREXTRUDEPRIMITIVE3D:
39 return u"SDREXTRUDEPRIMITIVE3D"_ustr;
40 case PRIMITIVE3D_ID_SDRLATHEPRIMITIVE3D:
41 return u"SDRLATHEPRIMITIVE3D"_ustr;
42 case PRIMITIVE3D_ID_SDRPOLYPOLYGONPRIMITIVE3D:
43 return u"SDRPOLYPOLYGONPRIMITIVE3D"_ustr;
44 case PRIMITIVE3D_ID_SDRSPHEREPRIMITIVE3D:
45 return u"SDRSPHEREPRIMITIVE3D"_ustr;
46 case PRIMITIVE3D_ID_SHADOWPRIMITIVE3D:
47 return u"SHADOWPRIMITIVE3D"_ustr;
48 case PRIMITIVE3D_ID_UNIFIEDTRANSPARENCETEXTUREPRIMITIVE3D:
49 return u"UNIFIEDTRANSPARENCETEXTUREPRIMITIVE3D"_ustr;
50 case PRIMITIVE3D_ID_GRADIENTTEXTUREPRIMITIVE3D:
51 return u"GRADIENTTEXTUREPRIMITIVE3D"_ustr;
52 case PRIMITIVE3D_ID_BITMAPTEXTUREPRIMITIVE3D:
53 return u"BITMAPTEXTUREPRIMITIVE3D"_ustr;
54 case PRIMITIVE3D_ID_TRANSPARENCETEXTUREPRIMITIVE3D:
55 return u"TRANSPARENCETEXTUREPRIMITIVE3D"_ustr;
56 case PRIMITIVE3D_ID_TRANSFORMPRIMITIVE3D:
57 return u"TRANSFORMPRIMITIVE3D"_ustr;
58 case PRIMITIVE3D_ID_HIDDENGEOMETRYPRIMITIVE3D:
59 return u"HIDDENGEOMETRYPRIMITIVE3D"_ustr;
60 default:
61 return OUString::number((nId >> 16) & 0xFF) + "|" + OUString::number(nId & 0xFF);
65 } // end of namespace drawinglayer::primitive2d
67 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */