1 // Copyright (C) 2007-2013 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.
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"
32 \brief Get minimal allowed value for deflection coefficient
34 double minDeflection()
36 return 1e-06; // DEFLECTION_MIN
40 \brief Get character used to separate parameter names
42 QString sectionSeparator()
44 return "_"; // NAME_SEPARATOR
48 \brief Get character used to separate numeric parameter values (color = r:g:b)
50 QString subSectionSeparator()
52 return ":"; // DIGIT_SEPARATOR
55 QString propertyName( Property type )
57 static const char* names[] = {
59 "Visibility", // VISIBILITY_PROP
61 "Transparency", // TRANSPARENCY_PROP
63 "DisplayMode", // DISPLAY_MODE_PROP
64 // number of the iso lines (along u and v directions)
66 // main / shading color
67 "Color", // COLOR_PROP
68 // "show edges direction" flag
69 "VectorMode", // VECTOR_MODE_PROP
70 // deflection coefficient
71 "DeflectionCoeff", // DEFLECTION_COEFF_PROP
73 "MarkerType", // MARKER_TYPE_PROP
75 "Material", // MATERIAL_PROP
77 "EdgeWidth", // EDGE_WIDTH_PROP
79 "IsosWidth", // ISOS_WIDTH_PROP
81 "TopLevelFlag", // TOP_LEVEL_PROP
83 "Opacity", // OPACITY_PROP
87 "WireframeColor", // -
88 // standalone edges color
90 // free boundaries color
99 return ( type >= GEOM::Visibility && type <= GEOM::LastProperty ) ? names[type] : QString();