1 // Copyright (C) 2007-2016 CEA/DEN, EDF R&D, OPEN CASCADE
3 // Copyright (C) 2003-2007 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
4 // CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
6 // This library is free software; you can redistribute it and/or
7 // modify it under the terms of the GNU Lesser General Public
8 // License as published by the Free Software Foundation; either
9 // version 2.1 of the License, or (at your option) any later version.
11 // This library is distributed in the hope that it will be useful,
12 // but WITHOUT ANY WARRANTY; without even the implied warranty of
13 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 // Lesser General Public License for more details.
16 // You should have received a copy of the GNU Lesser General Public
17 // License along with this library; if not, write to the Free Software
18 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
20 // See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
23 // File : GEOM_Constants.cxx
24 // Author : Vadim SANDLER, Open CASCADE S.A.S. (vadim.sandler@opencascade.com)
26 #include "GEOM_Constants.h"
34 \brief Get minimal allowed value for deflection coefficient
36 double minDeflection()
38 return 1e-06; // DEFLECTION_MIN
42 \brief Get character used to separate parameter names
44 QString sectionSeparator()
46 return "_"; // NAME_SEPARATOR
50 \brief Get character used to separate numeric parameter values (color = r:g:b)
52 QString subSectionSeparator()
54 return ":"; // DIGIT_SEPARATOR
57 QString propertyName( Property type )
59 static const char* names[] = {
61 "Visibility", // VISIBILITY_PROP
63 "Transparency", // TRANSPARENCY_PROP
65 "DisplayMode", // DISPLAY_MODE_PROP
66 // number of the iso lines (along u and v directions)
68 // main / shading color
69 "Color", // COLOR_PROP
70 // "show edges direction" flag
71 "VectorMode", // VECTOR_MODE_PROP
72 // "show vertices" flag
73 "VerticesMode", // VERTICES_MODE_PROP
75 "NameMode", // NAME_MODE_PROP
76 // deflection coefficient
77 "DeflectionCoeff", // DEFLECTION_COEFF_PROP
79 "MarkerType", // MARKER_TYPE_PROP
81 "Material", // MATERIAL_PROP
83 "EdgeWidth", // EDGE_WIDTH_PROP
85 "IsosWidth", // ISOS_WIDTH_PROP
87 "TopLevelFlag", // TOP_LEVEL_PROP
89 "Opacity", // OPACITY_PROP
93 "WireframeColor", // -
94 // standalone edges color
96 // free boundaries color
109 "ShapeAnnotations" // -
111 return ( type >= GEOM::Visibility && type <= GEOM::LastProperty ) ? names[type] : QString();
115 \brief Id used for storing properties of objects in study shared between viewers.
117 int sharedPropertiesId()