]> OCCT Git - occt-copy.git/commitdiff
0032340: OCCT Documentation - highlight C++ code snippets
authorbtokarev <btokarev@opencascade.com>
Tue, 18 May 2021 10:09:50 +0000 (13:09 +0300)
committerbugmaster <bugmaster@opencascade.com>
Sat, 22 May 2021 07:36:38 +0000 (10:36 +0300)
Added {.cpp} highlighting markers to the C++ code blocks in documentation;
Excessive tildes "~~~~~~~" in code block borders are reduced to required minimum of "~~~~" (4);
Removed obsolete space bars after code block borders;
TCL code blocks are now highlighted with {.php} markers;
Removed excessive {.cpp} highlighting markers appended to non-code blocks such as lists, reports and file content or structure examples;
Minor fixes for tests.md and draw_test_harness.md (whitespace removal and structural fix for "Where:" in code examples);
Minimum HDD space for OCCT updated in introduction.md.

25 files changed:
dox/build/build_occt/building_occt.md
dox/contribution/coding_rules.md
dox/contribution/git_guide/git_guide.md
dox/contribution/tests/tests.md
dox/debug/debug.md
dox/introduction/introduction.md
dox/samples/ocaf.md
dox/samples/ocaf_func.md
dox/specification/boolean_operations/boolean_operations.md
dox/specification/brep_format.md
dox/tutorial/tutorial.md
dox/upgrade/upgrade.md
dox/user_guides/draw_test_harness/draw_test_harness.md
dox/user_guides/foundation_classes/foundation_classes.md
dox/user_guides/iges/iges.md
dox/user_guides/inspector/inspector.md
dox/user_guides/mesh/mesh.md
dox/user_guides/modeling_algos/modeling_algos.md
dox/user_guides/modeling_data/modeling_data.md
dox/user_guides/ocaf/ocaf.md
dox/user_guides/shape_healing/shape_healing.md
dox/user_guides/step/step.md
dox/user_guides/vis/vis.md
dox/user_guides/visualization/visualization.md
dox/user_guides/xde/xde.md

index 748ffba8350ff8d4a114441ac3f250bd6d3a15e8..e921e9e99b666ba56a49abb26575f17a5d6fbaa0 100644 (file)
@@ -243,9 +243,9 @@ The environment is defined in the file *custom.sh* (on Linux and OS X) or *custo
   * *ShortCut* - short-cut header files will be created, redirecting to same-named header located in *src*;
   * "HardLink* - hard links to headers located in *src* will be created.
 * For optional  third-party libraries, set corresponding environment variable <i>HAVE_<LIBRARY_NAME></i> to either *false*,  e.g.:
-~~~~~
+~~~~
        export HAVE_FREEIMAGE=false
-~~~~~
+~~~~
 
 Alternatively, or when *custom.sh* or *custom.bat* does not exist, you can launch **genconf** tool to configure environment interactively:
 
@@ -257,10 +257,10 @@ Click "Save" to store the specified configuration in *custom.sh* or *custom.bat*
 
 Launch **genproj** tool with option *cbp* to update content of *inc* folder and generate project files after changes in OCCT code affecting layout or composition of source files:
 
-~~~~~
+~~~~
   $ cd /dev/OCCT/opencascade-7.0.0
   $ ./genproj cbp
-~~~~~
+~~~~
 
 The generated Code::Blocks project are placed into subfolder *adm/&lt;OS&gt;/cbp*.
 
@@ -273,9 +273,9 @@ To start **Code::Blocks**, launch script *codeblocks.sh*.
 To build all toolkits, click **Build->Build workspace** in the menu bar.
 
 To start *DRAWEXE*, which has been built with **Code::Blocks** on Mac OS X, run the script
-~~~~~
+~~~~
    ./draw.sh cbp [d]
-~~~~~
+~~~~
 Option *d* is used if OCCT has been built in **Debug** mode.
 
 @subsection build_occt_genproj Building with Genproj tool
@@ -344,9 +344,9 @@ Launch **genproj** to update content of *inc* folder and generate project files
 @note To use **genproj** and **genconf** tools you need to have Tcl installed and accessible by PATH.
 If Tcl is not found, the tool may prompt you to enter the path to directory where Tcl can be found.
  
-~~~~~
+~~~~
   $ genproj.bat
-~~~~~
+~~~~
 
 Note that if *custom.bat* is not present, **genproj** will start **genconf** to configure environment.
 
@@ -470,9 +470,9 @@ The environment is defined in the file *custom.sh* which can be edited directly:
   * *ShortCut* - short-cut header files will be created, redirecting to same-named header located in *src*;
   * "HardLink* - hard links to headers located in *src* will be created.
 * For optional  third-party libraries, set corresponding environment variable <i>HAVE_<LIBRARY_NAME></i> to either *false*,  e.g.:
-~~~~~
+~~~~
        export HAVE_FREEIMAGE=false
-~~~~~
+~~~~
 
 Alternatively, or when *custom.sh* does not exist, you can launch *genconf.sh* to configure environment interactively:
 
@@ -488,10 +488,10 @@ Launch **genproj** tool to update content of *inc* folder and generate project f
 
 For instance, in Terminal application:
 
-~~~~~
+~~~~
   $ cd /dev/OCCT/opencascade-7.0.0
   $ ./genproj
-~~~~~
+~~~~
 
 <h2>Building</h2>
 
@@ -513,14 +513,14 @@ To start *DRAWEXE*, which has been built with Xcode on Mac OS X, perform the fol
 1.Open Terminal application
 
 2.Enter <i>\<OCCT_ROOT_DIR\></i>:
-~~~~~
+~~~~
    cd \<OCCT_ROOT_DIR\>
-~~~~~
+~~~~
 
 3.Run the script
-~~~~~
+~~~~
    ./draw_cbp.sh xcd [d]
-~~~~~
+~~~~
 
 Option *d* is used if OCCT has been built in **Debug** mode.
 
@@ -543,9 +543,9 @@ directly:
   * *ShortCut* - short-cut header files will be created, redirecting to same-named header located in *src*;
   * "HardLink* - hard links to headers located in *src* will be created.
 * For optional  third-party libraries, set corresponding environment variable <i>HAVE_<LIBRARY_NAME></i> to either *false*,  e.g.:
-~~~~~
+~~~~
        export HAVE_FREEIMAGE=false
-~~~~~
+~~~~
 
 Alternatively, or when *custom.sh* or *custom.bat* does not exist, you can launch **genconf** tool to configure
  environment interactively:
@@ -559,10 +559,10 @@ Click "Save" to store the specified configuration in *custom.sh* or *custom.bat*
 Launch **genproj** tool with option *cbp* to update content of *inc* folder and generate project files after changes in 
 OCCT code affecting layout or composition of source files:
 
-~~~~~
+~~~~
   $ cd /dev/OCCT/opencascade-7.0.0
   $ ./genproj cbp
-~~~~~
+~~~~
 
 The generated Code::Blocks project are placed into subfolder *adm/&lt;OS&gt;/cbp*.
 
@@ -575,7 +575,7 @@ To start **Code::Blocks**, launch script *codeblocks.sh*.
 To build all toolkits, click **Build->Build workspace** in the menu bar.
 
 To start *DRAWEXE*, which has been built with **Code::Blocks** on Mac OS X, run the script
-~~~~~
+~~~~
    ./draw_cbp.sh cbp [d]
-~~~~~
+~~~~
 Option *d* is used if OCCT has been built in **Debug** mode.
index 7f8f6238c73db8fb6795015c2756b3a4b943565e..c8f9a37ea9e43a5b621eb8145b513ec69a17dadb 100644 (file)
@@ -48,11 +48,11 @@ For example, method *GetCoord* returns a triple of real values and is defined fo
 Camel Case style is preferred for names.
 For example:
 
-~~~~~{.cpp}
+~~~~{.cpp}
 Standard_Integer awidthofbox;  // this is bad
 Standard_Integer width_of_box; // this is bad
 Standard_Integer aWidthOfBox;  // this is OK
-~~~~~
+~~~~
 
 @subsection occt_coding_rules_2_2 Names of development units
 
@@ -80,9 +80,9 @@ Toolkit names are prefixed by *TK*, followed by a meaningful part of the name ex
 
 Names of public classes and other types (structures, enums, typedefs) should match the common pattern: name of the package followed by underscore and suffix (the own name of the type):
 
-~~~~~
+~~~~{.cpp}
     <package-name>_<class-name>
-~~~~~
+~~~~
 
 Static methods related to the whole package are defined in the class with the same name as package (without suffix).
 
@@ -95,9 +95,9 @@ This rule also applies to complex types constructed by instantiation of template
 Such types should be given own names using *typedef* statement, located in same-named header file.
 
 For example, see definition in the file *TColStd_IndexedDataMapOfStringString.hxx*:
-~~~~~
+~~~~{.cpp}
 typedef NCollection_IndexedDataMap<TCollection_AsciiString,TCollection_AsciiString,TCollection_AsciiString> TColStd_IndexedDataMapOfStringString;
-~~~~~
+~~~~
 
 ### Names of functions
 
@@ -109,7 +109,7 @@ The term **function** here is defined as:
 It is preferred to start names of public methods from an upper case character and to start names of protected and private methods from a lower case character.
 
 
-~~~~~{.cpp}
+~~~~{.cpp}
 class MyPackage_MyClass
 {
 
@@ -123,7 +123,7 @@ private:
   void setIntegerValue (const Standard_Integer theValue);
 
 };
-~~~~~
+~~~~
 
 @subsection occt_coding_rules_2_3 Names of variables
 
@@ -137,13 +137,13 @@ The name of a variable should not start with an underscore.
 
 See the following examples:
 
-~~~~~{.cpp}
+~~~~{.cpp}
 Standard_Integer Elapsed_Time = 0; // this is bad - possible class   name
 Standard_Integer gp = 0;           // this is bad - existing package name
 Standard_Integer aGp = 0;          // this is OK
 Standard_Integer _KERNEL = 0;      // this is bad
 Standard_Integer THE_KERNEL = 0;   // this is OK
-~~~~~
+~~~~
 
 ### Names of function parameters
 
@@ -151,11 +151,11 @@ The name of a function (procedure, class method) parameter should start with pre
 
 See the following examples:
 
-~~~~~{.cpp}
+~~~~{.cpp}
 void Package_MyClass::MyFunction (const gp_Pnt& p);        // this is bad
 void Package_MyClass::MyFunction (const gp_Pnt& theP);     // this is OK
 void Package_MyClass::MyFunction (const gp_Pnt& thePoint); // this is preferred
-~~~~~
+~~~~
 
 ### Names of class member variables
 
@@ -163,11 +163,11 @@ The name of a class member variable should start with prefix *my* followed by th
 
 See the following examples:
 
-~~~~~{.cpp}
+~~~~{.cpp}
 Standard_Integer counter;   // This is bad
 Standard_Integer myC;       // This is OK
 Standard_Integer myCounter; // This is preferred
-~~~~~
+~~~~
 
 ### Names of global variables
 
@@ -176,18 +176,18 @@ However, as soon as a global variable is necessary, its name should be prefixed
 
 See the following examples:
 
-~~~~~{.cpp}
+~~~~{.cpp}
 Standard_Integer MyPackage_myGlobalVariable = 0;
 Standard_Integer MyPackage_MyClass_myGlobalVariable = 0;
-~~~~~
+~~~~
 
 Static constants within the file should be written in upper-case and begin with prefix *THE_*:
-~~~~~{.cpp}
+~~~~{.cpp}
 namespace
 {
   static const Standard_Real THE_CONSTANT_COEF = 3.14;
 };
-~~~~~
+~~~~
 
 ### Names of local variables
 
@@ -197,12 +197,12 @@ It is preferred to prefix local variable names with *a* and *an* (or *is*, *to*
 
 See the following example:
 
-~~~~~{.cpp}
+~~~~{.cpp}
 Standard_Integer theI;    // this is bad
 Standard_Integer i;       // this is bad
 Standard_Integer index;   // this is bad
 Standard_Integer anIndex; // this is OK
-~~~~~
+~~~~
 
 ### Avoid dummy names
 Avoid dummy names, such as <i>i, j, k</i>. Such names are meaningless and easy to mix up.
@@ -211,7 +211,7 @@ The code becomes more and more complicated when such dummy names are used there
 
 See the following examples for preferred style:
 
-~~~~~{.cpp}
+~~~~{.cpp}
 void Average (const Standard_Real** theArray,
               Standard_Integer      theRowsNb,
               Standard_Integer      theRowLen,
@@ -227,7 +227,7 @@ void Average (const Standard_Real** theArray,
     theResult /= Standard_Real(aRowsNb * aRowLen);
   }
 }
-~~~~~
+~~~~
 
 @section occt_coding_rules_3 Formatting rules
 
@@ -262,7 +262,7 @@ Punctuation rules follow the rules of the English language.
 * For better readability it is also recommended to surround conventional operators by a space character. 
 Examples:
 
-~~~~~{.cpp}
+~~~~{.cpp}
 while (true)                            // NOT: while( true ) ...
 {
   DoSomething (theA, theB, theC, theD); // NOT: DoSomething(theA,theB,theC,theD);
@@ -271,7 +271,7 @@ for (anIter = 0; anIter < 10; ++anIter) // NOT: for (anIter=0;anIter<10;++anIter
 {
   theA = (theB + theC) * theD;          // NOT: theA=(theB+theC)*theD
 }
-~~~~~
+~~~~
 
 ### Declaration of pointers and references
 
@@ -281,7 +281,7 @@ Since declaration of several variables with mixed pointer types contrudicts this
 
 Examples:
 
-~~~~~{.cpp}
+~~~~{.cpp}
 Standard_Integer   *theVariable;      // not recommended
 Standard_Integer *  theVariable;      // not recommended
 Standard_Integer*   theVariable;      // this is OK
@@ -295,7 +295,7 @@ Standard_Integer ** theVariable;      // not recommended
 Standard_Integer**  theVariable;      // this is OK
 
 Standard_Integer *theA, theB, **theC; // not recommended (declare each variable independently)
-~~~~~
+~~~~
 
 ### Separate logical blocks
 
@@ -303,7 +303,7 @@ Separate logical blocks of code with one blank line and comments.
 
 See the following example:
 
-~~~~~{.cpp}
+~~~~{.cpp}
 // check arguments
 Standard_Integer anArgsNb = argCount();
 if (anArgsNb < 3 || isSmthInvalid)
@@ -318,7 +318,7 @@ if (anArgsNb < 3 || isSmthInvalid)
 // do our job
 ...
 ...
-~~~~~
+~~~~
 
 Notice that multiple blank lines should be avoided.
 
@@ -329,7 +329,7 @@ Each descriptive block should contain at least a function name and purpose descr
 
 See the following example:
 
-~~~~~{.cpp}
+~~~~{.cpp}
 // =======================================================================
 // function : TellMeSmthGood
 // purpose  : Gives me good news
@@ -347,19 +347,19 @@ void TellMeSmthBad()
 {
   ...
 }
-~~~~~
+~~~~
 
 ### Block layout [MANDATORY]
 Figure brackets <i>{ }</i> and each operator <i>(for, if, else, try, catch)</i> should be written on a dedicated line.
 
 In general, the layout should be as follows:
 
-~~~~~{.cpp}
+~~~~{.cpp}
 while (expression)
 {
   ...
 }
-~~~~~
+~~~~
 
 Entering a block increases and leaving a block decreases the indentation by one tabulation.
 
@@ -367,7 +367,7 @@ Entering a block increases and leaving a block decreases the indentation by one
 
 Single-line conditional operators <i>(if, while, for,</i> etc.) can be written without brackets on the following line.
 
-~~~~~{.cpp}
+~~~~{.cpp}
 if (!myIsInit) return Standard_False; // bad
 
 if (thePtr == NULL)                   // OK
@@ -377,7 +377,7 @@ if (!theAlgo.IsNull())                // preferred
 {
   DoSomething();
 }
-~~~~~
+~~~~
 
 Having all code in the same line is less convenient for debugging.
 
@@ -386,7 +386,7 @@ Having all code in the same line is less convenient for debugging.
 In comparisons, put the variable (in the current context) on the left side and constant on the right side of expression.
 That is, the so called "Yoda style" is to be avoided.
 
-~~~~~{.cpp}
+~~~~{.cpp}
 if (NULL != thePointer)    // Yoda style, not recommended
 if (thePointer != NULL)    // OK
 
@@ -398,13 +398,13 @@ if (anIter <= theNbValues) // OK
 
 if (THE_LIMIT == theValue) // bad style (global constant vs. variable)
 if (theValue == THE_LIMIT) // OK
-~~~~~
+~~~~
 
 ### Alignment
 
 Use alignment wherever it enhances the readability. See the following example:
 
-~~~~~{.cpp}
+~~~~{.cpp}
 MyPackage_MyClass anObject;
 Standard_Real     aMinimum = 0.0;
 Standard_Integer  aVal     = theVal;
@@ -415,7 +415,7 @@ switch (aVal)
   case 3:
   default: computeSomethingElseYet();       break;
 }
-~~~~~
+~~~~
 
 ### Indentation of comments
 
@@ -425,7 +425,7 @@ The text of the comment should be separated from the slash character by a single
 
 See the following example:
 
-~~~~~{.cpp}
+~~~~{.cpp}
 while (expression)   //bad comment
 {
   // this is a long multi-line comment
@@ -433,7 +433,7 @@ while (expression)   //bad comment
   DoSomething();     // maybe, enough
   DoSomethingMore(); // again
 }
-~~~~~
+~~~~
 
 ### Early return statement
 
@@ -441,7 +441,7 @@ Use an early return condition rather than collect indentations.
 
 Write like this:
 
-~~~~~{.cpp}
+~~~~{.cpp}
 Standard_Integer ComputeSumm (const Standard_Integer* theArray,
                               const Standard_Size     theSize)
 {
@@ -454,11 +454,11 @@ Standard_Integer ComputeSumm (const Standard_Integer* theArray,
   ... computing summ ...
   return aSumm;
 }
-~~~~~
+~~~~
 
 Rather than:
 
-~~~~~{.cpp}
+~~~~{.cpp}
 Standard_Integer ComputeSumm (const Standard_Integer* theArray,
                               const Standard_Size     theSize)
 {
@@ -469,7 +469,7 @@ Standard_Integer ComputeSumm (const Standard_Integer* theArray,
   }
   return aSumm;
 }
-~~~~~
+~~~~
 
 This helps to improve readability and reduce the unnecessary indentation depth.
 
@@ -490,7 +490,7 @@ An exception to the rule is ordering system headers generating a macros declarat
 
 The source or header file should include only minimal set of headers necessary for compilation, without duplicates (considering nested includes).
 
-~~~~~{.cpp}
+~~~~{.cpp}
 // the header file of implemented class
 #include <PackageName_ClassName.hxx>
 
@@ -506,7 +506,7 @@ The source or header file should include only minimal set of headers necessary f
 // system headers
 #include <iostream>
 #include <windows.h>
-~~~~~
+~~~~
 
 @section occt_coding_rules_4 Documentation rules
 
@@ -623,7 +623,7 @@ A class with virtual function(s) ought to have a virtual destructor.
 Declaration of overriding method should contains specifiers "virtual" and "override"
 (using Standard_OVERRIDE alias for compatibility with old compilers).
 
-~~~~~{.cpp}
+~~~~{.cpp}
 class MyPackage_BaseClass
 {
 
@@ -641,7 +641,7 @@ public:
   Standard_EXPORT virtual Standard_Boolean Perform() Standard_OVERRIDE;
 
 };
-~~~~~
+~~~~
 
 This makes class definition more clear (virtual methods become highlighted).
 
@@ -667,20 +667,20 @@ Avoid *goto* statement unless it is really needed.
 
 Declare a cycle variable in the header of the *for()* statement if not used out of cycle.
 
-~~~~~{.cpp}
+~~~~{.cpp}
 Standard_Real aMinDist = Precision::Infinite();
 for (NCollection_Sequence<gp_Pnt>::Iterator aPntIter (theSequence);
      aPntIter.More(); aPntIter.Next())
 {
   aMinDist = Min (aMinDist, theOrigin.Distance (aPntIter.Value()));
 }
-~~~~~
+~~~~
 
 ### Condition statements within zero
 
 Avoid usage of C-style comparison for non-boolean variables:
 
-~~~~~{.cpp}
+~~~~{.cpp}
 void Function (Standard_Integer theValue,
                Standard_Real*   thePointer)
 {
@@ -699,7 +699,7 @@ void Function (Standard_Integer theValue,
     DoSome2();
   }
 }
-~~~~~
+~~~~
 
 @section occt_coding_rules_7 Portability issues
 
@@ -791,11 +791,11 @@ In C++ use *new* and *delete* operators instead of *malloc()* and *free()*. Try
 
 Use the same form of new and delete.
 
-~~~~~{.cpp}
+~~~~{.cpp}
 aPtr1 = new TypeA[n];              ... ; delete[]        aPtr1;
 aPtr2 = new TypeB();               ... ; delete          aPtr2;
 aPtr3 = Standard::Allocate (4096); ... ; Standard::Free (aPtr3);
-~~~~~
+~~~~
 
 ### Methods managing dynamical allocation [MANDATORY]
 
@@ -805,10 +805,10 @@ Define a destructor, a copy constructor and an assignment operator for classes w
 
 Every variable should be initialized.
 
-~~~~~{.cpp}
+~~~~{.cpp}
 Standard_Integer aTmpVar1;     // bad
 Standard_Integer aTmpVar2 = 0; // OK
-~~~~~
+~~~~
 
 Uninitialized variables might be kept only within performance-sensitive code blocks and only when their initialization is guaranteed by subsequent code.
 
@@ -824,12 +824,12 @@ In *operator=()* assign to all data members and check for assignment to self.
 
 Don't check floats for equality or non-equality; check for GT, GE, LT or LE.
 
-~~~~~{.cpp}
+~~~~{.cpp}
 if (Abs (theFloat1 - theFloat2) < theTolerance)
 {
   DoSome();
 }
-~~~~~
+~~~~
 
 Package *Precision* provides standard values for SI units and widely adopted by existing modeling algorithms:
 
@@ -872,7 +872,7 @@ Generally, try to reduce misaligned accesses since they impact the performance (
 
 List class data members in the constructor's initialization list in the order they are declared.
 
-~~~~~{.cpp}
+~~~~{.cpp}
 class MyPackage_MyClass
 {
 
@@ -892,19 +892,19 @@ private:
   Standard_Integer myPropertyB;
 
 };
-~~~~~
+~~~~
 
 ### Initialization over assignment
 
 Prefer initialization over assignment in class constructors.
 
-~~~~~{.cpp}
+~~~~{.cpp}
 MyPackage_MyClass()
 : myPropertyA (1)  // preferred
 {
   myPropertyB = 2; // not recommended
 }
-~~~~~
+~~~~
 
 ### Optimize caching
 
@@ -912,23 +912,23 @@ When programming procedures with extensive memory access, try to optimize them i
 
 On x86 this code
 
-~~~~~{.cpp}
+~~~~{.cpp}
 Standard_Real anArray[4096][2];
 for (Standard_Integer anIter = 0; anIter < 4096; ++anIter)
 {
   anArray[anIter][0] = anArray[anIter][1];
 }
-~~~~~
+~~~~
 
 is more efficient then
 
-~~~~~{.cpp}
+~~~~{.cpp}
 Standard_Real anArray[2][4096];
 for (Standard_Integer anIter = 0; anIter < 4096; ++anIter)
 {
   anArray[0][anIter] = anArray[1][anIter];
 }
-~~~~~
+~~~~
 
 since linear access does not invalidate cache too often.
 
@@ -952,7 +952,7 @@ Command arguments should be validated before usage. The user should see a human-
 
 Command should warn the user about unknown arguments, including cases when extra parameters have been pushed for the command with a fixed number of arguments.
 
-~~~~~{.cpp}
+~~~~{.cpp}
   if (theArgsNb != 3)
   {
     std::cout << "Syntax error - wrong number of arguments!\n";
@@ -971,7 +971,7 @@ Command should warn the user about unknown arguments, including cases when extra
   }
   DBRep::Set (aResName, aFaceShape);
   return 0;
-~~~~~
+~~~~
 
 ### Message printing
 
@@ -984,9 +984,9 @@ Information printed into Draw Interpreter should be well-structured to allow usa
 Any command with a long list of obligatory parameters should be considered as ill-formed by design.
 Optional parameters should start with flag name (with '-' prefix) and followed by its values:
 
-~~~~~{.tcl}
+~~~~{.php}
 myCommand -flag1 value1 value2 -flag2 value3
-~~~~~
+~~~~
 
 ### Arguments parser
 
@@ -996,7 +996,7 @@ myCommand -flag1 value1 value2 -flag2 value3
 
 Functions *Draw::Atof()* and *Draw::Atoi()* support expressions and read values in C-locale.
 
-~~~~~{.cpp}
+~~~~{.cpp}
   Standard_Real aPosition[3] = {0.0, 0.0, 0.0};
   for (Standard_Integer anArgIter = 1; anArgIter < theArgsNb; ++anArgIter)
   {
@@ -1020,7 +1020,7 @@ Functions *Draw::Atof()* and *Draw::Atoi()* support expressions and read values
       return 1;
     }
   }
-~~~~~
+~~~~
 
 @section occt_coding_rules_11 Examples
 
@@ -1051,7 +1051,7 @@ private: //! \@name private fields
 
 @endverbatim
 
-~~~~~
+~~~~{.cpp}
 #include <Package_Class.hxx>
 // ==========================================================
 // function : Square
@@ -1071,11 +1071,11 @@ void Package_Class::increment()
 {
   ++myCounter;
 }
-~~~~~
+~~~~
 
 ### TCL script for Draw Harness
 
-~~~~~{.tcl}
+~~~~{.tcl}
 # show fragments (solids) in shading with different colors
 proc DisplayColored {theShape} {
   set aSolids [uplevel #0 explode $theShape so]
@@ -1106,10 +1106,10 @@ vzbufftrihedron
 DisplayColored c
 vfit
 vdump $imagedir/${casename}.png 512 512
-~~~~~
+~~~~
 
 ### GLSL program:
-~~~~~{.fs}
+~~~~{.cpp}
 vec3 Ambient;  //!< Ambient  contribution of light sources
 vec3 Diffuse;  //!< Diffuse  contribution of light sources
 vec3 Specular; //!< Specular contribution of light sources
@@ -1149,4 +1149,4 @@ void main()
                                   normalize (View),
                                   Position);
 }
-~~~~~
+~~~~
index da07e71f3f453ff2feb92a1ac2073fe56c2cf45d..bf18ce21f6c2d11ef677ad14acad464622d67050 100644 (file)
@@ -152,11 +152,11 @@ The official repository contains:
   Make sure to configure Git so that the user name is equal to your username 
   on the OCCT development portal, and set SafeCrLf option to true:
 
-~~~~~
+~~~~
     > git config --global user.name "Your User Name"
     > git config --global user.email your@mail.address
     > git config --global your@mail.address
-~~~~~
+~~~~
 
 @section occt_gitguide_3 Getting access to the repository
 
@@ -213,9 +213,9 @@ The official repository contains:
   On Windows, you might need to start **Git Bash** command prompt window.
   
   Use the following command to generate SSH keys:
-~~~~~  
+~~~~
     > ssh-keygen -t rsa -C "your@mail.address"
-~~~~~  
+~~~~
 
   The last argument is an optional comment, which can be included with the public key and used to distinguish between different keys (if you have many).  The common practice is to put here your mail address or workstation name.
   
@@ -290,9 +290,9 @@ Click **Save** to input the key to the system.
 
   * From command line by command: 
 
-~~~~~  
+~~~~
     > git clone gitolite@git.dev.opencascade.org:occt <path>
-~~~~~
+~~~~
 
   where <i>\<path\></i> is the path to the new folder which will be created for the repository.
     
@@ -314,9 +314,9 @@ Click **Save** to input the key to the system.
 
 In the console:
 
-~~~~~
+~~~~
     > git checkout -b CR12345 origin/master
-~~~~~
+~~~~
   
 In TortoiseGit: 
   * Go to the local copy of the repository. 
@@ -332,9 +332,9 @@ In TortoiseGit:
   If you need to switch to another branch, use Git command checkout for that.
   In the console:
 
-~~~~~
+~~~~
     > git checkout CR12345
-~~~~~
+~~~~
   
   In TortoiseGit: right-click in the explorer window and select in the context menu **TortoiseGit** -> **Switch/Checkout**.
  
@@ -351,11 +351,11 @@ In TortoiseGit:
   
   * In the console:
   
-~~~~~
+~~~~
     > git diff
     …
     > git commit -a -m "Write meaningful commit message here"
-~~~~~
+~~~~
 
   Option -a tells the command to automatically include (stage) files 
   that have been modified or deleted, but it will omit the new files that might have been added by you. 
@@ -363,12 +363,12 @@ In TortoiseGit:
 
   To find new unstaged files and them to commit, use commands:
 
-~~~~~
+~~~~
     > git status -s
       ?? file1.hxx 
       ?? file2.cxx
     > git add file1.hxx file2.cxx
-~~~~~
+~~~~
 
   * In TortoiseGit: right-click in the explorer window and select in the context menu <b>Git Commit -> CR…</b>:
  
@@ -384,9 +384,9 @@ In TortoiseGit:
   
   * In the console:
 
-~~~~~  
+~~~~
     > git push "origin" CR12345:CR12345
-~~~~~
+~~~~
 
   * In TortoiseGit: right-click in the explorer window and select in the context menu, TortoiseGit -> **Push**
 
@@ -410,9 +410,9 @@ Note that Git forbids pushing a branch if the corresponding remote branch alread
   Use Git command *fetch* with option *prune* to get the update of all branches from the remote repository and to clean your local repository from the remote branches that have been deleted.
   
   * In the console:
-~~~~~  
+~~~~
     > git fetch --prune 
-~~~~~
+~~~~
     
   * In TortoiseGit: right-click in the explorer window and select in the context menu **TortoiseGit** -> **Fetch**. Check in **Prune** check-box.  
   
@@ -423,9 +423,9 @@ Note that Git forbids pushing a branch if the corresponding remote branch alread
   This operation is required in particular to update your local master branch when the remote master changes.
   
   * In console:
-~~~~~  
+~~~~
     > git pull
-~~~~~    
+~~~~
 
   * In TortoiseGit: right-click in the explorer window and select in the context menu **TortoiseGit** -> **Pull**.
 
@@ -436,9 +436,9 @@ Note that the local branches of your repository are the primary place, where you
 Remove the local branches that you do not need any more. Note that you cannot delete the current branch. It means that you need to switch to another one (e.g. master) if the branch you are going to delete is the current one.
   
   * In the console:
-~~~~
+~~~~
     > git branch -d CR12345
-~~~~~
+~~~~
     
   * In TortoiseGit: right-click in the explorer window and select in the context menu **TortoiseGit** -> **Git Show Log**.
 
index 8f73b0cceaa74643cd4da1cf12dfd118f513ccd0..ef8dd4e71141080f7bf48fb795b617b6d5d9d23c 100644 (file)
@@ -51,9 +51,9 @@ For this it is recommended to add a file *DrawAppliInit* in the directory which
 
 Example (Windows)
 
-~~~~~{.tcl}
+~~~~{.php}
 set env(CSF_TestDataPath) $env(CSF_TestDataPath)\;d:/occt/test-data
-~~~~~
+~~~~
 
 Note that variable *CSF_TestDataPath* is set to default value at DRAW start, pointing at the folder <i>$CASROOT/data</i>. 
 In this example, subdirectory <i>d:/occt/test-data</i> is added to this path. Similar code could be used on Linux and Mac OS X except that on non-Windows platforms colon ":" should be used as path separator instead of semicolon ";".
@@ -66,18 +66,18 @@ To run all tests, type command *testgrid*
 
 Example:
 
-~~~~~
+~~~~{.php}
 Draw[]> testgrid
-~~~~~
+~~~~
 
 To run only a subset of test cases, give masks for group, grid, and test case names to be executed.
 Each argument is a list of file masks separated with commas or spaces; by default "*" is assumed.
 
 Example:
 
-~~~~~
+~~~~{.php}
 Draw[]> testgrid bugs caf,moddata*,xde
-~~~~~
+~~~~
 
 As the tests progress, the result of each test case is reported. 
 At the end of the log a summary of test cases is output, 
@@ -86,7 +86,7 @@ including the list of detected regressions and improvements, if any.
 
 Example:
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.tcl}
+~~~~{.php}
     Tests summary
 
     CASE 3rdparty export A1: OK 
@@ -97,7 +97,7 @@ Example:
     Total cases: 208 BAD, 31 SKIPPED, 3 IMPROVEMENT, 1791 OK
     Elapsed time: 1 Hours 14 Minutes 33.7384512019 Seconds
     Detailed logs are saved in D:/occt/results_2012-06-04T0919
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 The tests are considered as non-regressive if only OK, BAD (i.e. known problem), and SKIPPED (i.e. not executed, typically because of lack of a data file) statuses are reported. See @ref testmanual_details_results "Interpretation of test results" for details.
 
@@ -105,22 +105,22 @@ The results and detailed logs of the tests are saved by default to a new subdire
 If necessary, a non-default output directory can be specified using option <i> -outdir</i> followed by a path to the directory. This directory should be new or empty; use option <i>-overwrite</i> to allow writing results in the existing non-empty directory. 
 
 Example:
-~~~~~
+~~~~{.php}
 Draw[]> testgrid -outdir d:/occt/last_results -overwrite
-~~~~~
+~~~~
 In the output directory, a cumulative HTML report <i>summary.html</i> provides links to reports on each test case. An additional report in JUnit-style XML format can be output for use in Jenkins or other continuous integration system.
 
 To re-run the test cases, which were detected as regressions on the previous run, option <i>-regress dirname</i> should be used.
 <i>dirname</i> is a path to the directory containing the results of the previous run. Only the test cases with *FAILED* and *IMPROVEMENT* statuses will be tested.
 
 Example:
-~~~~~
+~~~~{.php}
 Draw[]> testgrid -regress d:/occt/last_results
-~~~~~
+~~~~
 
 Type <i>help testgrid</i> in DRAW prompt to get help on options supported by *testgrid* command:
 
-~~~~~
+~~~~{.php}
 Draw[3]> help testgrid
 testgrid: Run all tests, or specified group, or one grid
     Use: testgrid [groupmask [gridmask [casemask]]] [options...]
@@ -135,7 +135,7 @@ testgrid: Run all tests, or specified group, or one grid
                       Here "dirname" is a path to the directory containing the results of the previous run.
     Groups, grids, and test cases to be executed can be specified by the list of file 
     masks separated by spaces or commas; default is all (*).
-~~~~~
+~~~~
 
 @subsubsection testmanual_1_3_3 Running a Single Test
 
@@ -143,11 +143,11 @@ To run a single test, type command *test* followed by names of group, grid, and
 
 Example:
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.tcl}
+~~~~{.php}
     Draw[1]> test blend simple A1
     CASE blend simple A1: OK
     Draw[2]>
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 Note that normally an intermediate output of the script is not shown. The detailed log of the test can be obtained after the test execution by running command <i>"dlog get"</i>. 
 
@@ -156,7 +156,7 @@ To see intermediate commands and their output during the test execution, add one
 
 Type <i>help test</i> in DRAW prompt to get help on options supported by *test* command:
 
-~~~~~
+~~~~{.php}
 Draw[3]> help test
 test: Run specified test case
  Use: test group grid casename [options...]
@@ -174,7 +174,7 @@ test: Run specified test case
  -beep: play sound signal at the end of the test
  -errors: show all lines from the log report that are recognized as errors
         This key will be ignored if the "-echo" key is already set.
-~~~~~
+~~~~
 
 @subsubsection testmanual_intro_quick_create Creating a New Test
 
@@ -182,50 +182,50 @@ The detailed rules of creation of new tests are given in @ref testmanual_3 "Crea
 
 Use prefix <i>bug</i> followed by Mantis issue ID and, if necessary, additional suffixes, for naming the test script, data files, and DRAW commands specific for this test case.
 
-1.     If the test requires C++ code, add it as new DRAW command(s) in one of files in *QABugs* package. 
-2.     Add script(s) for the test case in the subfolder corresponding to the relevant OCCT module of the group *bugs* <i>($CASROOT/tests/bugs)</i>. See @ref testmanual_5_2 "the correspondence map".
-3.     In the test script:
-       *       Load all necessary DRAW modules by command *pload*.
-       *       Use command *locate_data_file* to get a path to data files used by test script. (Make sure to have this command not inside catch statement if it is used.)
-       *       Use DRAW commands to reproduce the tested situation.
-       *       Make sure that in case of failure the test produces a message containing word "Error" or other recognized by the test system as error (add new error patterns in file parse.rules if necessary).
-       *       If the test case reports error due to an existing problem and the fix is not available, add @ref testmanual_3_6 "TODO" statement for each error to mark it as a known problem. The TODO statements must be specific so as to match the actually generated messages but not all similar errors.
-       *       To check expected output which should be obtained as the test result, add @ref testmanual_3_7 "REQUIRED" statement for each line of output to mark it as required.
-       *       If the test case produces error messages (contained in parse.rules), which are expected in that test and should not be considered as its failure (e.g. test for *checkshape* command), add REQUIRED statement for each error to mark it as required output.
-4.     To check whether the data files needed for the test are already present in the database, use DRAW command *testfile* (see below).
+1.  If the test requires C++ code, add it as new DRAW command(s) in one of files in *QABugs* package. 
+2.  Add script(s) for the test case in the subfolder corresponding to the relevant OCCT module of the group *bugs* <i>($CASROOT/tests/bugs)</i>. See @ref testmanual_5_2 "the correspondence map".
+3.  In the test script:
+  * Load all necessary DRAW modules by command *pload*.
+  * Use command *locate_data_file* to get a path to data files used by test script. (Make sure to have this command not inside catch statement if it is used.)
+  * Use DRAW commands to reproduce the tested situation.
+  * Make sure that in case of failure the test produces a message containing word "Error" or other recognized by the test system as error (add new error patterns in file parse.rules if necessary).
+  * If the test case reports error due to an existing problem and the fix is not available, add @ref testmanual_3_6 "TODO" statement for each error to mark it as a known problem. The TODO statements must be specific so as to match the actually generated messages but not all similar errors.
+  * To check expected output which should be obtained as the test result, add @ref testmanual_3_7 "REQUIRED" statement for each line of output to mark it as required.
+  * If the test case produces error messages (contained in parse.rules), which are expected in that test and should not be considered as its failure (e.g. test for *checkshape* command), add REQUIRED statement for each error to mark it as required output.
+4.  To check whether the data files needed for the test are already present in the database, use DRAW command *testfile* (see below).
     If the data file is already present, use it for a new test instead of adding a duplicate.
     If the data file(s) are not yet present in the test database, put them to a folder and add it to the environment variable *CSF_TestDataPath* to be found by the test system.
     The location of the data files, which need to be accessed by OCC team and put to the official database, should be provided in the comment to Mantis issue, clearly indicating how the names of the files used by the test script match the actual names of the files.
     The simplest way is to attach the data files to the Mantis issue, with the same names as used by the test script.
-5.     Check that the test case runs as expected (test for fix: OK with the fix, FAILED without the fix; test for existing problem: BAD), and integrate it to the Git branch created for the issue.
+5.  Check that the test case runs as expected (test for fix: OK with the fix, FAILED without the fix; test for existing problem: BAD), and integrate it to the Git branch created for the issue.
 
 Example:
 
 * Added files:
 
-~~~~~
+~~~~{.php}
 git status -short
 A tests/bugs/heal/data/bug210_a.brep
 A tests/bugs/heal/data/bug210_b.brep
 A tests/bugs/heal/bug210_1
 A tests/bugs/heal/bug210_2
-~~~~~
+~~~~
 
 * Test script
 
-~~~~~{.tcl}
+~~~~{.php}
 puts "OCC210 (case 1): Improve FixShape for touching wires"
 
 restore [locate_data_file bug210_a.brep] a 
 
 fixshape result a 0.01 0.01
 checkshape result
-~~~~~
+~~~~
 
 DRAW command *testfile* should be used to check the data files used by the test for possible duplication of content or names.
 The command accepts the list of paths to files to be checked (as a single argument) and gives a conclusion on each of the files, for instance:
 
-~~~~~
+~~~~{.php}
 Draw[1]> testfile [glob /my/data/path/bug12345*]
 Collecting info on test data files repository...
 Checking new file(s)...
@@ -247,7 +247,7 @@ Checking new file(s)...
 * /my/data/path/case_8_wire4.brep: error
   name is already used by existing file
   --> //server/occt_tests_data/public/brep/case_8_wire4.brep
-~~~~~
+~~~~
 
 @section testmanual_2 Organization of Test Scripts
 
@@ -284,11 +284,11 @@ The names of directories of test groups containing systematic test grids corresp
 
 Example:
 
-~~~~~
+~~~~
   caf
   mesh
   offset
-~~~~~
+~~~~
 
 Test group *bugs* is used to collect the tests coming from bug reports. Group *demo* collects tests of the test system, DRAW, samples, etc.
 
@@ -296,19 +296,19 @@ Test group *bugs* is used to collect the tests coming from bug reports. Group *d
 
 This test group contains file *grids.list*, which defines an ordered list of grids in this group in the following format:
 
-~~~~~~~~~~~~~~~~~
+~~~~
 001 gridname1
 002 gridname2
 ...
 NNN gridnameN
-~~~~~~~~~~~~~~~~~
+~~~~
 
 Example:
 
-~~~~~~~~~~~~~~~~~
+~~~~
     001 basic
     002 advanced
-~~~~~~~~~~~~~~~~~
+~~~~
 
 @subsubsection testmanual_2_2_3 File "begin"
 
@@ -318,10 +318,10 @@ additional Tcl functions used in test scripts.
 
 Example:
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.tcl}
+~~~~{.php}
     pload TOPTEST ;# load topological command
     set cpulimit 300 ;# set maximum time allowed for script execution
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 @subsubsection testmanual_2_2_4 File "end"
 
@@ -332,14 +332,14 @@ Note: *TEST COMPLETED* string should be present in the output to indicate that t
 See @ref testmanual_3 "Creation and modification of tests" chapter for more information.
 
 Example:
-~~~~~
+~~~~{.php}
     if { [isdraw result] } {
         checkshape result
     } else {
         puts "Error: The result shape can not be built"
     }
     puts "TEST COMPLETED"
-~~~~~
+~~~~
 
 @subsubsection testmanual_2_2_5 File "parse.rules"
 
@@ -353,12 +353,12 @@ The rest of the line can contain a comment message, which will be added to the t
 
 Example:
 
-~~~~~
+~~~~
     FAILED /\b[Ee]xception\b/ exception
     FAILED /\bError\b/ error
     SKIPPED /Cannot open file for reading/ data file is missing
     SKIPPED /Could not read file .*, abandon/ data file is missing
-~~~~~
+~~~~
 
 Lines starting with a *#* character and blank lines are ignored to allow comments and spacing.
 
@@ -368,11 +368,11 @@ If a line matches several rules, the first one applies. Rules defined in the gri
 
 Example:
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.tcl}
+~~~~
     FAILED /\\bFaulty\\b/ bad shape
     IGNORE /^Error [23]d = [\d.-]+/ debug output of blend command
     IGNORE /^Tcl Exception: tolerance ang : [\d.-]+/ blend failure
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 @subsubsection testmanual_2_2_6  Directory "data"
 The test group may contain subdirectory *data*, where test scripts shared by different test grids can be put. See also @ref testmanual_2_3_5 "Directory data".
@@ -386,12 +386,12 @@ Each directory contains a set of related test cases. The name of a directory sho
 
 Example:
 
-~~~~~
+~~~~
 caf
    basic
    bugs
    presentation
-~~~~~
+~~~~
 
 Here *caf* is the name of the test group and *basic*, *bugs*, *presentation*, etc. are the names of grids.
 
@@ -403,9 +403,9 @@ Usually it sets variables specific for the current grid.
 
 Example:
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.tcl}
+~~~~{.php}
     set command bopfuse ;# command tested in this grid
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 @subsubsection testmanual_2_3_3 File "end"
 
@@ -415,9 +415,9 @@ Usually it executes a specific sequence of commands common for all tests in the
 
 Example:
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.tcl}
+~~~~{.php}
     vdump $imagedir/${casename}.png ;# makes a snap-shot of AIS viewer
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 @subsubsection testmanual_2_3_4 File "cases.list"
 
@@ -427,9 +427,9 @@ This file should contain a single line defining the relative path to the collect
 
 Example:
 
-~~~~~
+~~~~
 ../data/simple
-~~~~~
+~~~~
 
 This option is used for creation of several grids of tests with the same data files and operations but performed with differing parameters. The common scripts are usually located place in the common 
 subdirectory of the test group, <i>data/simple</i> for example.
@@ -450,25 +450,25 @@ and produces meaningful messages that can be used to check the validity of the r
 
 Example:
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.tcl}
+~~~~{.php}
     pcylinder c1 10 20 ;# create first cylinder
     pcylinder c2 5 20 ;# create second cylinder
     ttranslate c2 5 0 10 ;# translate second cylinder to x,y,z
     bsection result c1 c2 ;# create a section of two cylinders
     checksection result ;# will output error message if result is bad
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 The test case can have any name (except for the reserved names *begin, end, data, cases.list* and  *parse.rules*). 
 For systematic grids it is usually a capital English letter followed by a number.
 
 Example:
 
-~~~~~
+~~~~
     A1
     A2
     B1
     B2
-~~~~~
+~~~~
 
 Such naming facilitates compact representation of tests execution results in tabular format within HTML reports.
 
@@ -488,11 +488,11 @@ The test case name in the bugs group should be prefixed by the ID of the corresp
 
 Example:
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.tcl}
+~~~~
     bug12345_coaxial
     bug12345_orthogonal_1
     bug12345_orthogonal_2
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 If the new test corresponds to a functionality already covered by the existing systematic test grid (e.g. group *mesh* for *BRepMesh* issues), this test can be added (or moved later by OCC team) to that grid. 
 
@@ -526,32 +526,32 @@ The test should run commands necessary to perform the tested operations, in gene
 Usually the script represents a set of commands that a person would run interactively to perform the operation and see its results, with additional comments to explain what happens.
 
 Example:
-~~~~~
+~~~~{.php}
 # Simple test of fusing box and sphere
 box b 10 10 10 
 sphere s 5
 bfuse result b s
 checkshape result
-~~~~~
+~~~~
 
 Make sure that file *parse.rules* in the grid or group directory contains a regular expression to catch possible messages indicating the failure of the test. 
 
 For instance, for catching errors reported by *checkshape* command relevant grids define a rule to recognize its report by the word *Faulty*:
 
-~~~~~
+~~~~
 FAILED /\bFaulty\b/ bad shape
-~~~~~
+~~~~
 
 For the messages generated in the script it is recommended to use the word 'Error' in the error message.
 
 Example:
 
-~~~~~
+~~~~{.php}
 set expected_length 11
 if { [expr $actual_length - $expected_length] > 0.001 } {
     puts "Error: The length of the edge should be $expected_length"
 }
-~~~~~
+~~~~
 
 At the end, the test script should output *TEST COMPLETED* string to mark a successful completion of the script. This is often done by the *end* script in the grid.
 
@@ -571,9 +571,9 @@ During execution of the test, location of such data file can be constructed usin
 
 Example:
 
-~~~~~
+~~~~{.php}
 checkresult $result $::dirname/$::groupname/$::gridname/data/${::casename}.txt
-~~~~~
+~~~~
 
 CAD models and other data files which are not going to change over time should be stored separately from the source repository.
 Use Tcl procedure *locate_data_file* to get a path to such data files, instead of coding the path explicitly. 
@@ -583,9 +583,9 @@ If the file is not found, *locate_data_file* will raise exception, and the test
 
 Example:
 
-~~~~~
+~~~~{.php}
 stepread [locate_data_file CAROSKI_COUPELLE.step] a *
-~~~~~
+~~~~
 
 When the test needs to produce some snapshots or other artefacts, use Tcl variable *imagedir* as the location where such files should be put. 
 * Command *testgrid* sets this variable to the subdirectory of the results folder corresponding to the grid. 
@@ -601,20 +601,20 @@ The test system can recognize an image file (snapshot) and include it in HTML lo
 The image format (defined by extension) should be *png*.
 
 Example:
-~~~~~
+~~~~{.php}
 xwd $::imagedir/${::casename}.png
 vdisplay result; vfit
 vdump $::imagedir/${::casename}-axo.png
 vfront; vfit
 vdump $::imagedir/${::casename}-front.png
-~~~~~
+~~~~
 
 would produce:
-~~~~~
+~~~~
 A1.png
 A1-axo.png
 A1-front.png
-~~~~~
+~~~~
 
 Note that OCCT must be built with FreeImage support to be able to produce usable images.
 
@@ -644,26 +644,26 @@ The new test created for an unsolved problem should return BAD. The new test cre
 If the test produces an invalid result at a certain moment then the corresponding bug should be created in the OCCT issue tracker located at https://tracker.dev.opencascade.org, and the problem should be marked as TODO in the test script.
 
 The following statement should be added to such a test script:
-~~~~~
+~~~~{.php}
 puts "TODO BugNumber ListOfPlatforms: RegularExpression"
-~~~~~
+~~~~
 
 Here:
 * *BugNumber* is the bug ID in the tracker. For example: #12345.
 * *ListOfPlatforms* is a list of platforms, at which the bug is reproduced (Linux, Windows, MacOS, or All). Note that the platform name is custom for the OCCT test system; Use procedure *checkplatform* to get the platform name.
 
 Example:
-~~~~~
+~~~~{.php}
 Draw[2]> checkplatform
 Windows
-~~~~~
+~~~~
 
 * RegularExpression is a regular expression, which should be matched against the line indicating the problem in the script output. 
 
 Example:
-~~~~~
+~~~~{.php}
 puts "TODO #22622 Mandriva2008: Abort .* an exception was raised"
-~~~~~
+~~~~
 
 The parser checks the test output and if an output line matches the *RegularExpression* then it will be assigned a BAD status instead of FAILED.
 
@@ -673,29 +673,29 @@ To mark the test as BAD for an incomplete case (when the final *TEST COMPLETE* m
 
 Example:
 
-~~~~~
+~~~~{.php}
 puts "TODO OCC22817 All: exception.+There are no suitable edges"
 puts "TODO OCC22817 All: \\*\\* Exception \\*\\*"
 puts "TODO OCC22817 All: TEST INCOMPLETE"
-~~~~~
+~~~~
 
 @subsection testmanual_3_7 Marking required output
 
 To check the obtained test output matches the expected results considered correct, add REQUIRED statement for each specific message.
 For that, the following statement should be added to the corresponding test script:
 
-~~~~~
+~~~~{.php}
 puts "REQUIRED ListOfPlatforms: RegularExpression"
-~~~~~
+~~~~
 
 Here *ListOfPlatforms* and *RegularExpression* have the same meaning as in TODO statements described above.
 
 The REQUIRED statement can also be used to mask the message that would normally be interpreted as error (according to the rules defined in *parse.rules*) but should not be considered as such within the current test.
 
 Example:
-~~~~~
+~~~~{.php}
 puts "REQUIRED Linux: Faulty shapes in variables faulty_1 to faulty_5"
-~~~~~
+~~~~
 
 This statement notifies test system that errors reported by *checkshape* command are expected in that test case, and test should be considered as OK if this message appears, despite of presence of general rule stating that 'Faulty' signals failure.
 
@@ -711,13 +711,13 @@ Note: in OCCT 6.5.3, file *DrawAppliInit* already exists in <i>$CASROOT/src/Draw
 
 For example, let us assume that *d:/occt* contains an up-to-date version of OCCT sources with tests, and the test data archive is unpacked to *d:/test-data*):
 
-~~~~~
+~~~~{.php}
 set env(CASROOT) d:/occt
 set env(CSF_TestScriptsPath) $env(CASROOT)/tests
 source $env(CASROOT)/src/DrawResources/TestCommands.tcl
 set env(CSF_TestDataPath) $env(CASROOT)/data;d:/test-data
 return
-~~~~~
+~~~~
 
 Note that on older versions of OCCT the tests are run in compatibility mode and thus not all output of the test command can be captured; this can lead to absence of some error messages (can be reported as either a failure or an improvement).
 
@@ -728,13 +728,13 @@ You can extend the test system by adding your own tests. For that it is necessar
 Use Tcl command <i>_path_separator</i> to insert a platform-dependent separator to the path list.
 
 For example:
-~~~~~
+~~~~{.php}
 set env(CSF_TestScriptsPath) \
   $env(TestScriptsPath)[_path_separator]d:/MyOCCTProject/tests
 set env(CSF_TestDataPath) \
   d:/occt/test-data[_path_separator]d:/MyOCCTProject/data
 return ;# this is to avoid an echo of the last command above in cout
-~~~~~
+~~~~
 
 @subsection testmanual_4_3 Parallel execution of tests
 
@@ -749,21 +749,21 @@ Some test results are very dependent on the characteristics of the workstation,
 
 OCCT test system provides a dedicated command *testdiff* for comparing CPU time of execution, memory usage, and images produced by the tests.
 
-~~~~~
+~~~~{.php}
 testdiff dir1 dir2 [groupname [gridname]] [options...]
-~~~~~
+~~~~
 Here *dir1* and *dir2* are directories containing logs of two test runs.
 
 Possible options are:
 * <i>-save \<filename\> </i> -- saves the resulting log in a specified file (<i>$dir1/diff-$dir2.log</i> by default). HTML log is saved with the same name and extension .html;
 * <i>-status {same|ok|all}</i> -- allows filtering compared cases by their status:
-       * *same* -- only cases with same status are compared (default);
-       * *ok*   -- only cases with OK status in both logs are compared;
-       * *all*  -- results are compared regardless of status;
+  * *same* -- only cases with same status are compared (default);
+  * *ok*   -- only cases with OK status in both logs are compared;
+  * *all*  -- results are compared regardless of status;
 * <i>-verbose \<level\> </i> -- defines the scope of output data:
-       * 1 -- outputs only differences;
-       * 2 -- additionally outputs the list of logs and directories present in one of directories only;
-       * 3 -- (by default) additionally outputs progress messages;
+  * 1 -- outputs only differences;
+  * 2 -- additionally outputs the list of logs and directories present in one of directories only;
+  * 3 -- (by default) additionally outputs progress messages;
 * <i>-image [filename]</i> - compare images and save the resulting log in specified file (<i>$dir1/diffimage-$dir2.log</i> by default)
 * <i>-cpu [filename]</i> - compare overall CPU and save the resulting log in specified file (<i>$dir1/diffcpu-$dir2.log</i> by default)
 * <i>-memory [filename]</i> - compare memory delta and save the resulting log in specified file (<i>$dir1/diffmemory-$dir2.log</i> by default)
@@ -771,18 +771,18 @@ Possible options are:
 
 Example:
 
-~~~~~
+~~~~{.php}
 Draw[]> testdiff results/CR12345-2012-10-10T08:00 results/master-2012-10-09T21:20 
-~~~~~
+~~~~
 
 Particular tests can generate additional data that need to be compared by *testdiff* command.
 For that, for each parameter to be controlled, the test should produce the line containing keyword "COUNTER* followed by arbitrary name of the parameter, then colon and numeric value of the parameter.
 
 Example of test code:
 
-~~~~~
+~~~~{.php}
 puts "COUNTER Memory heap usage at step 5: [meminfo h]"
-~~~~~
+~~~~
 
 @section testmanual_5 APPENDIX
 
@@ -794,10 +794,10 @@ This group allows testing the interaction of OCCT and 3rdparty products.
 
 DRAW module: VISUALIZATION.
 
-| Grid | Commands      | Functionality |
+| Grid  | Commands  | Functionality |
 | :---- | :----- | :------- | 
-| export       | vexport       | export of images to different formats |
-| fonts         | vtrihedron, vcolorscale, vdrawtext   | display of fonts |
+| export  | vexport | export of images to different formats |
+| fonts  | vtrihedron, vcolorscale, vdrawtext | display of fonts |
 
 
 @subsubsection testmanual_5_1_2 blend
@@ -806,15 +806,15 @@ This group allows testing blends (fillets) and related operations.
 
 DRAW module: MODELING.
 
-| Grid | Commands      | Functionality |
+| Grid  | Commands  | Functionality |
 | :---- | :----- | :------- | 
-| simple       | blend | fillets on simple shapes |
-| complex      | blend         | fillets on complex shapes, non-trivial geometry |
-| tolblend_simple      | tolblend, blend | |
-| buildevol    | buildevol     | |
-| tolblend_buildvol |  tolblend, buildevol |   use of additional command tolblend |
-| bfuseblend   | bfuseblend    | | 
-| encoderegularity     | encoderegularity      | | 
+| simple  | blend | fillets on simple shapes |
+| complex | blend   | fillets on complex shapes, non-trivial geometry |
+| tolblend_simple | tolblend, blend | |
+| buildevol | buildevol | |
+| tolblend_buildvol |   tolblend, buildevol | use of additional command tolblend |
+| bfuseblend  | bfuseblend  | | 
+| encoderegularity  | encoderegularity  | | 
 
 @subsubsection testmanual_5_1_3 boolean
 
@@ -827,32 +827,32 @@ Grids names are based on name of the command used, with suffixes:
 * <i>_simple</i> -- for tests operating on simple shapes (boxes, cylinders, toruses, etc.);
 * <i>_complex</i> -- for tests dealing with complex shapes.
 
-| Grid | Commands      | Functionality |
+| Grid  | Commands  | Functionality |
 | :---- | :----- | :------- | 
-| bcommon_2d   | bcommon       | Common operation (old algorithm), 2d |
-| bcommon_complex      | bcommon       | Common operation (old algorithm), complex shapes |
-| bcommon_simple       | bcommon       | Common operation (old algorithm), simple shapes |
-| bcut_2d      | bcut | Cut operation (old algorithm), 2d |
-| bcut_complex | bcut  | Cut operation (old algorithm), complex shapes |
-| bcut_simple  | bcut |        Cut operation (old algorithm), simple shapes |
-| bcutblend    | bcutblend     | | 
-| bfuse_2d     | bfuse | Fuse operation (old algorithm), 2d |
-| bfuse_complex        | bfuse |       Fuse operation (old algorithm), complex shapes |
-| bfuse_simple | bfuse | Fuse operation (old algorithm), simple shapes |
-| bopcommon_2d | bopcommon |   Common operation, 2d |
-| bopcommon_complex    | bopcommon     | Common operation, complex shapes | 
-| bopcommon_simple     | bopcommon     | Common operation, simple shapes |
-| bopcut_2d |  bopcut |        Cut operation, 2d |
-| bopcut_complex |     bopcut |        Cut operation, complex shapes |
-| bopcut_simple        | bopcut        | Cut operation, simple shapes |
-| bopfuse_2d   | bopfuse       | Fuse operation, 2d |
-| bopfuse_complex      | bopfuse       | Fuse operation, complex shapes |
-| bopfuse_simple       | bopfuse       | Fuse operation, simple shapes |
-| bopsection   | bopsection    | Section |
-| boptuc_2d    | boptuc        | |
-| boptuc_complex       | boptuc        | |
-| boptuc_simple        | boptuc        | |
-| bsection |   bsection        | Section (old algorithm) |
+| bcommon_2d  | bcommon | Common operation (old algorithm), 2d |
+| bcommon_complex | bcommon | Common operation (old algorithm), complex shapes |
+| bcommon_simple  | bcommon | Common operation (old algorithm), simple shapes |
+| bcut_2d | bcut | Cut operation (old algorithm), 2d |
+| bcut_complex  | bcut  | Cut operation (old algorithm), complex shapes |
+| bcut_simple | bcut |  Cut operation (old algorithm), simple shapes |
+| bcutblend | bcutblend | | 
+| bfuse_2d  | bfuse | Fuse operation (old algorithm), 2d |
+| bfuse_complex | bfuse | Fuse operation (old algorithm), complex shapes |
+| bfuse_simple  | bfuse | Fuse operation (old algorithm), simple shapes |
+| bopcommon_2d  | bopcommon | Common operation, 2d |
+| bopcommon_complex | bopcommon | Common operation, complex shapes | 
+| bopcommon_simple  | bopcommon | Common operation, simple shapes |
+| bopcut_2d | bopcut |  Cut operation, 2d |
+| bopcut_complex |  bopcut |  Cut operation, complex shapes |
+| bopcut_simple | bopcut  | Cut operation, simple shapes |
+| bopfuse_2d  | bopfuse | Fuse operation, 2d |
+| bopfuse_complex | bopfuse | Fuse operation, complex shapes |
+| bopfuse_simple  | bopfuse | Fuse operation, simple shapes |
+| bopsection  | bopsection  | Section |
+| boptuc_2d | boptuc  | |
+| boptuc_complex  | boptuc  | |
+| boptuc_simple | boptuc  | |
+| bsection |  bsection  | Section (old algorithm) |
 
 @subsubsection testmanual_5_1_4 bugs
 
@@ -867,15 +867,15 @@ This group allows testing OCAF functionality.
 
 DRAW module: OCAFKERNEL.
 
-| Grid | Commands      | Functionality |
+| Grid  | Commands  | Functionality |
 | :---- | :----- | :------- | 
-| basic        | |     Basic attributes |
-| bugs | |     Saving and restoring of document |
-| driver       | |     OCAF drivers |
-| named_shape  | |     *TNaming_NamedShape* attribute |
-| presentation | | *AISPresentation* attributes |
-| tree | |     Tree construction attributes |
-| xlink         | |    XLink attributes |
+| basic | |   Basic attributes |
+| bugs  | | Saving and restoring of document |
+| driver  | | OCAF drivers |
+| named_shape | | *TNaming_NamedShape* attribute |
+| presentation  | | *AISPresentation* attributes |
+| tree  | | Tree construction attributes |
+| xlink  | |  XLink attributes |
 
 @subsubsection testmanual_5_1_6 chamfer
 
@@ -885,17 +885,17 @@ DRAW module: MODELING.
 
 The test grid name is constructed depending on the type of the tested chamfers. Additional suffix <i>_complex</i> is used for test cases involving complex geometry (e.g. intersections of edges forming a chamfer); suffix <i>_sequence</i> is used for grids where chamfers are computed sequentially.
 
-| Grid | Commands      | Functionality |
+| Grid  | Commands  | Functionality |
 | :---- | :----- | :------- | 
-| equal_dist   | |     Equal distances from edge |
-| equal_dist_complex   | |     Equal distances from edge, complex shapes |
-| equal_dist_sequence  | |     Equal distances from edge, sequential operations |
-| dist_dist    | |     Two distances from edge |
-| dist_dist_complex    | |     Two distances from edge, complex shapes |
-| dist_dist_sequence   | |     Two distances from edge, sequential operations |
-| dist_angle   | |     Distance from edge and given angle |
-| dist_angle_complex   | |     Distance from edge and given angle |
-| dist_angle_sequence  | |     Distance from edge and given angle |
+| equal_dist  | |   Equal distances from edge |
+| equal_dist_complex  | | Equal distances from edge, complex shapes |
+| equal_dist_sequence | | Equal distances from edge, sequential operations |
+| dist_dist | | Two distances from edge |
+| dist_dist_complex | | Two distances from edge, complex shapes |
+| dist_dist_sequence  | | Two distances from edge, sequential operations |
+| dist_angle  | | Distance from edge and given angle |
+| dist_angle_complex  | | Distance from edge and given angle |
+| dist_angle_sequence | | Distance from edge and given angle |
 
 @subsubsection testmanual_5_1_7 de
 
@@ -903,7 +903,7 @@ This group tests reading and writing of CAD data files (iges, step) to and from
 
 Test cases check transfer status, shape and attributes against expected reference values.
 
-| Grid | Commands | Functionality |
+| Grid  | Commands | Functionality |
 | :---- | :----- | :------- | 
 | iges_1, iges_2, iges_3 | igesbrep, brepiges, ReadIges, WriteIges | IGES tests | 
 | step_1, step_2, step_3, step_4, step_5 | stepread, stepwrite, ReadStep, WriteStep | STEP tests |
@@ -912,11 +912,11 @@ Test cases check transfer status, shape and attributes against expected referenc
 
 This group allows demonstrating how testing cases are created, and testing DRAW commands and the test system as a whole.
 
-| Grid | Commands      | Functionality |
+| Grid  | Commands  | Functionality |
 | :---- | :----- | :------- | 
-| draw |  getsource, restore   | Basic DRAW commands |
-| testsystem   | |     Testing system |
-| samples      | |     OCCT samples | 
+| draw  |  getsource, restore | Basic DRAW commands |
+| testsystem  | | Testing system |
+| samples | | OCCT samples | 
 
 
 @subsubsection testmanual_5_1_9 draft
@@ -925,9 +925,9 @@ This group allows testing draft operations.
 
 DRAW module: MODELING.
 
-| Grid | Commands      | Functionality |
+| Grid  | Commands  | Functionality |
 | :---- | :----- | :------- | 
-| Angle        | depouille     | Drafts with angle (inclined walls) |
+| Angle | depouille | Drafts with angle (inclined walls) |
 
 
 @subsubsection testmanual_5_1_10 feat
@@ -936,13 +936,13 @@ This group allows testing creation of features on a shape.
 
 DRAW module: MODELING (package *BRepTest*).
 
-| Grid | Commands      | Functionality |
+| Grid  | Commands  | Functionality |
 | :---- | :----- | :------- | 
-| featdprism           | | |
-| featlf               | | |
-| featprism            | | |
-| featrevol            | | | 
-| featrf               | | |
+| featdprism    | | |
+| featlf    | | |
+| featprism   | | |
+| featrevol   | | | 
+| featrf    | | |
 
 @subsubsection testmanual_5_1_11 heal
 
@@ -950,28 +950,28 @@ This group allows testing the functionality provided by *ShapeHealing* toolkit.
 
 DRAW module: XSDRAW
 
-| Grid | Commands      | Functionality |
+| Grid  | Commands  | Functionality |
 | :---- | :----- | :------- | 
-| fix_shape    | fixshape      | Shape healing | 
-| fix_gaps     | fixwgaps      | Fixing gaps between edges on a wire |
-| same_parameter       | sameparameter | Fixing non-sameparameter edges |
-| same_parameter_locked        | sameparameter | Fixing non-sameparameter edges |
-| fix_face_size        | DT_ApplySeq   | Removal of small faces |
-| elementary_to_revolution     | DT_ApplySeq   | Conversion of elementary surfaces to revolution |
-| direct_faces | directfaces   | Correction of axis of elementary surfaces | 
-| drop_small_edges     | fixsmall      | Removal of small edges | 
-| split_angle  | DT_SplitAngle |       Splitting periodic surfaces by angle |
-| split_angle_advanced | DT_SplitAngle | Splitting periodic surfaces by angle |
-| split_angle_standard | DT_SplitAngle | Splitting periodic surfaces by angle |
-| split_closed_faces | DT_ClosedSplit  | Splitting of closed faces |
-| surface_to_bspline | DT_ToBspl       | Conversion of surfaces to b-splines |
-| surface_to_bezier | DT_ShapeConvert |        Conversion of surfaces to bezier |
-| split_continuity     | DT_ShapeDivide | Split surfaces by continuity criterion |
+| fix_shape | fixshape  | Shape healing | 
+| fix_gaps  | fixwgaps  | Fixing gaps between edges on a wire |
+| same_parameter  | sameparameter | Fixing non-sameparameter edges |
+| same_parameter_locked | sameparameter | Fixing non-sameparameter edges |
+| fix_face_size | DT_ApplySeq | Removal of small faces |
+| elementary_to_revolution  | DT_ApplySeq | Conversion of elementary surfaces to revolution |
+| direct_faces  | directfaces | Correction of axis of elementary surfaces | 
+| drop_small_edges  | fixsmall  | Removal of small edges | 
+| split_angle | DT_SplitAngle | Splitting periodic surfaces by angle |
+| split_angle_advanced | DT_SplitAngle  | Splitting periodic surfaces by angle |
+| split_angle_standard | DT_SplitAngle  | Splitting periodic surfaces by angle |
+| split_closed_faces |  DT_ClosedSplit  | Splitting of closed faces |
+| surface_to_bspline |  DT_ToBspl | Conversion of surfaces to b-splines |
+| surface_to_bezier | DT_ShapeConvert | Conversion of surfaces to bezier |
+| split_continuity  | DT_ShapeDivide | Split surfaces by continuity criterion |
 | split_continuity_advanced | DT_ShapeDivide | Split surfaces by continuity criterion |
 | split_continuity_standard | DT_ShapeDivide | Split surfaces by continuity criterion |
-| surface_to_revolution_advanced |     DT_ShapeConvertRev      | Convert elementary surfaces to revolutions, complex cases |
-| surface_to_revolution_standard |     DT_ShapeConvertRev      | Convert elementary surfaces to revolutions, simple cases |
-| update_tolerance_locked      | updatetolerance       | Update the tolerance of shape so that it satisfy the rule: toler(face)<=toler(edge)<=toler(vertex) |
+| surface_to_revolution_advanced |  DT_ShapeConvertRev  | Convert elementary surfaces to revolutions, complex cases |
+| surface_to_revolution_standard |  DT_ShapeConvertRev  | Convert elementary surfaces to revolutions, simple cases |
+| update_tolerance_locked | updatetolerance | Update the tolerance of shape so that it satisfy the rule: toler(face)<=toler(edge)<=toler(vertex) |
 
 @subsubsection testmanual_5_1_12 mesh
 
@@ -979,14 +979,14 @@ This group allows testing shape tessellation (*BRepMesh*) and shading.
 
 DRAW modules: MODELING (package *MeshTest*), VISUALIZATION (package *ViewerTest*)
 
-| Grid | Commands      | Functionality |
+| Grid  | Commands  | Functionality |
 | :---- | :----- | :------- | 
-| advanced_shading     | vdisplay      | Shading, complex shapes |
-| standard_shading     | vdisplay      | Shading, simple shapes |
-| advanced_mesh        | mesh |        Meshing of complex shapes |
-| standard_mesh | mesh |       Meshing of simple shapes |
-| advanced_incmesh     | incmesh       | Meshing of complex shapes |
-| standard_incmesh     | incmesh       | Meshing of simple shapes |
+| advanced_shading  | vdisplay  | Shading, complex shapes |
+| standard_shading  | vdisplay  | Shading, simple shapes |
+| advanced_mesh | mesh |  Meshing of complex shapes |
+| standard_mesh | mesh |  Meshing of simple shapes |
+| advanced_incmesh  | incmesh | Meshing of complex shapes |
+| standard_incmesh  | incmesh | Meshing of simple shapes |
 | advanced_incmesh_parallel | incmesh | Meshing of complex shapes, parallel mode |
 | standard_incmesh_parallel | incmesh | Meshing of simple shapes, parallel mode |
 
@@ -996,14 +996,14 @@ This group allows testing creation of simple surfaces.
 
 DRAW module: MODELING (package *BRepTest*)
 
-| Grid | Commands      | Functionality |
+| Grid  | Commands  | Functionality |
 | :---- | :----- | :------- | 
-| after_trim | mkface  | |
-| after_offset | mkface        | |
-| after_extsurf_and_offset     | mkface  | |   
-| after_extsurf_and_trim | mkface      | | 
-| after_revsurf_and_offset | mkface    | | 
-| mkplane | mkplane    | |
+| after_trim | mkface | |
+| after_offset | mkface | |
+| after_extsurf_and_offset  | mkface  | | 
+| after_extsurf_and_trim | mkface | | 
+| after_revsurf_and_offset | mkface | | 
+| mkplane | mkplane | |
 
 @subsubsection testmanual_5_1_14 nproject
 
@@ -1011,9 +1011,9 @@ This group allows testing normal projection of edges and wires onto a face.
 
 DRAW module: MODELING (package *BRepTest*) 
 
-| Grid | Commands      | Functionality |
+| Grid  | Commands  | Functionality |
 | :---- | :----- | :------- | 
-| Base | nproject      |  |
+| Base  | nproject  |  |
 
 @subsubsection testmanual_5_1_15 offset
 
@@ -1021,25 +1021,25 @@ This group allows testing offset functionality for curves and surfaces.
 
 DRAW module: MODELING (package *BRepTest*) 
 
-| Grid | Commands      | Functionality |
+| Grid  | Commands  | Functionality |
 | :---- | :----- | :------- | 
-| compshape    | offsetcompshape       | Offset of shapes with removal of some faces | 
-| faces_type_a | offsetparameter, offsetload, offsetperform | Offset on a subset of faces with a fillet |
-| faces_type_i         | offsetparameter, offsetload, offsetperform |  Offset on a subset of faces with a sharp edge |
-| shape_type_a         | offsetparameter, offsetload, offsetperform |  Offset on a whole shape with a fillet |
-| shape_type_i         | offsetparameter, offsetload, offsetperform |  Offset on a whole shape with a fillet |
-| shape         | offsetshape  | |
-| wire_closed_outside_0_005, wire_closed_outside_0_025, wire_closed_outside_0_075, wire_closed_inside_0_005, wire_closed_inside_0_025, wire_closed_inside_0_075, wire_unclosed_outside_0_005, wire_unclosed_outside_0_025, wire_unclosed_outside_0_075 |       mkoffset | 2d offset of closed and unclosed planar wires with different offset step and directions of offset ( inside / outside ) |
-       
+| compshape | offsetcompshape | Offset of shapes with removal of some faces | 
+| faces_type_a  | offsetparameter, offsetload, offsetperform | Offset on a subset of faces with a fillet |
+| faces_type_i  | offsetparameter, offsetload, offsetperform |  Offset on a subset of faces with a sharp edge |
+| shape_type_a  | offsetparameter, offsetload, offsetperform |  Offset on a whole shape with a fillet |
+| shape_type_i  | offsetparameter, offsetload, offsetperform |  Offset on a whole shape with a fillet |
+| shape  | offsetshape  | |
+| wire_closed_outside_0_005, wire_closed_outside_0_025, wire_closed_outside_0_075, wire_closed_inside_0_005, wire_closed_inside_0_025, wire_closed_inside_0_075, wire_unclosed_outside_0_005, wire_unclosed_outside_0_025, wire_unclosed_outside_0_075  | mkoffset | 2d offset of closed and unclosed planar wires with different offset step and directions of offset ( inside / outside ) |
+  
 @subsubsection testmanual_5_1_16 pipe
 
 This group allows testing construction of pipes (sweeping of a contour along profile).
 
 DRAW module: MODELING (package *BRepTest*) 
 
-| Grid | Commands      | Functionality |
+| Grid  | Commands  | Functionality |
 | :---- | :----- | :------- | 
-| Standard     | pipe  | |
+| Standard  | pipe  | |
 
 @subsubsection testmanual_5_1_17 prism
 
@@ -1047,9 +1047,9 @@ This group allows testing construction of prisms.
 
 DRAW module: MODELING (package *BRepTest*) 
 
-| Grid | Commands      | Functionality |
+| Grid  | Commands  | Functionality |
 | :---- | :----- | :------- | 
-| seminf | prism       | |
+| seminf | prism  | |
 
 @subsubsection testmanual_5_1_18 sewing
 
@@ -1057,46 +1057,46 @@ This group allows testing sewing of faces by connecting edges.
 
 DRAW module: MODELING (package *BRepTest*) 
 
-| Grid | Commands      | Functionality |
+| Grid  | Commands  | Functionality |
 | :---- | :----- | :------- | 
-| tol_0_01     | sewing | Sewing faces with tolerance 0.01 |
-| tol_1        | sewing | Sewing faces with tolerance 1 |
+| tol_0_01  | sewing | Sewing faces with tolerance 0.01 |
+| tol_1 | sewing | Sewing faces with tolerance 1 |
 | tol_100 | sewing | Sewing faces with tolerance 100 | 
 
 @subsubsection testmanual_5_1_19 thrusection
 
 This group allows testing construction of shell or a solid passing through a set of sections in a given sequence (loft).
 
-| Grid | Commands      | Functionality |
+| Grid  | Commands  | Functionality |
 | :---- | :----- | :------- | 
-| solids       | thrusection | Lofting with resulting solid | 
-| not_solids | thrusection     | Lofting with resulting shell or face | 
+| solids  | thrusection | Lofting with resulting solid | 
+| not_solids | thrusection  | Lofting with resulting shell or face | 
 
 @subsubsection testmanual_5_1_20 xcaf
 
 This group allows  testing extended data exchange packages.
 
-| Grid | Commands      | Functionality |
+| Grid  | Commands  | Functionality |
 | :---- | :----- | :------- | 
-| dxc, dxc_add_ACL, dxc_add_CL, igs_to_dxc, igs_add_ACL, brep_to_igs_add_CL, stp_to_dxc, stp_add_ACL, brep_to_stp_add_CL, brep_to_dxc, add_ACL_brep, brep_add_CL       | | Subgroups are divided by format of source file, by format of result file and by type of document modification. For example, *brep_to_igs* means that the source shape in brep format was added to the document, which was saved into igs format after that. The postfix *add_CL* means that colors and layers were initialized in the document before saving and the postfix *add_ACL* corresponds to the creation of assembly and initialization of colors and layers in a document before saving. |
-       
+| dxc, dxc_add_ACL, dxc_add_CL, igs_to_dxc, igs_add_ACL, brep_to_igs_add_CL, stp_to_dxc, stp_add_ACL, brep_to_stp_add_CL, brep_to_dxc, add_ACL_brep, brep_add_CL  | | Subgroups are divided by format of source file, by format of result file and by type of document modification. For example, *brep_to_igs* means that the source shape in brep format was added to the document, which was saved into igs format after that. The postfix *add_CL* means that colors and layers were initialized in the document before saving and the postfix *add_ACL* corresponds to the creation of assembly and initialization of colors and layers in a document before saving. |
+  
 
 @subsection testmanual_5_2 Mapping of OCCT functionality to grid names in group *bugs*
 
-| OCCT Module / Mantis category        | Toolkits      | Test grid in group bugs |
+| OCCT Module / Mantis category | Toolkits  | Test grid in group bugs |
 | :---------- | :--------- | :---------- | 
-| Application Framework        | PTKernel, TKPShape, TKCDF, TKLCAF, TKCAF, TKBinL, TKXmlL, TKShapeSchema, TKPLCAF, TKBin, TKXml, TKPCAF, FWOSPlugin, TKStdLSchema, TKStdSchema, TKTObj, TKBinTObj, TKXmlTObj | caf |
-| Draw | TKDraw, TKTopTest, TKViewerTest, TKXSDRAW, TKDCAF, TKXDEDRAW, TKTObjDRAW, TKQADraw, DRAWEXE, Problems of testing system |     draw | 
+| Application Framework | PTKernel, TKPShape, TKCDF, TKLCAF, TKCAF, TKBinL, TKXmlL, TKShapeSchema, TKPLCAF, TKBin, TKXml, TKPCAF, FWOSPlugin, TKStdLSchema, TKStdSchema, TKTObj, TKBinTObj, TKXmlTObj | caf |
+| Draw  | TKDraw, TKTopTest, TKViewerTest, TKXSDRAW, TKDCAF, TKXDEDRAW, TKTObjDRAW, TKQADraw, DRAWEXE, Problems of testing system | draw | 
 | Shape Healing | TKShHealing | heal |
-| Mesh | TKMesh, TKXMesh | mesh |
-| Data Exchange        | TKIGES        | iges |
-| Data Exchange        |       TKSTEPBase, TKSTEPAttr, TKSTEP209, TKSTEP |     step |
-| Data Exchange        |       TKSTL, TKVRML   | stlvrml |
-| Data Exchange        | TKXSBase, TKXCAF, TKXCAFSchema, TKXDEIGES, TKXDESTEP, TKXmlXCAF, TKBinXCAF | xde |
-| Foundation Classes | TKernel, TKMath | fclasses |
-| Modeling_algorithms |        TKGeomAlgo, TKTopAlgo, TKPrim, TKBO, TKBool, TKHLR, TKFillet, TKOffset, TKFeat, TKXMesh |       modalg |
-| Modeling Data | TKG2d, TKG3d, TKGeomBase, TKBRep     | moddata |
-| Visualization | TKService, TKV2d, TKV3d, TKOpenGl, TKMeshVS, TKNIS   | vis |
+| Mesh  | TKMesh, TKXMesh | mesh |
+| Data Exchange | TKIGES  | iges |
+| Data Exchange | TKSTEPBase, TKSTEPAttr, TKSTEP209, TKSTEP | step |
+| Data Exchange | TKSTL, TKVRML   | stlvrml |
+| Data Exchange | TKXSBase, TKXCAF, TKXCAFSchema, TKXDEIGES, TKXDESTEP, TKXmlXCAF, TKBinXCAF | xde |
+| Foundation Classes |  TKernel, TKMath | fclasses |
+| Modeling_algorithms | TKGeomAlgo, TKTopAlgo, TKPrim, TKBO, TKBool, TKHLR, TKFillet, TKOffset, TKFeat, TKXMesh | modalg |
+| Modeling Data | TKG2d, TKG3d, TKGeomBase, TKBRep  | moddata |
+| Visualization | TKService, TKV2d, TKV3d, TKOpenGl, TKMeshVS, TKNIS  | vis |
 
 
 @subsection testmanual_5_3 Recommended approaches to checking test results
@@ -1106,50 +1106,50 @@ This group allows  testing extended data exchange packages.
 Run command *checkshape* on the result (or intermediate) shape and make sure that *parse.rules* of the test grid or group reports bad shapes (usually recognized by word "Faulty") as error.
 
 Example
-~~~~~
+~~~~{.php}
 checkshape result
-~~~~~
+~~~~
 
 To check the number of faults in the shape command *checkfaults* can be used.
 
 Use: checkfaults shape source_shape [ref_value=0]
 
 The default syntax of *checkfaults* command:
-~~~~~
+~~~~{.php}
 checkfaults results a_1
-~~~~~
+~~~~
 
 The command will check the number of faults in the source shape (*a_1*) and compare it
 with number of faults in the resulting shape (*result*). If shape *result* contains
 more faults, you will get an error:
-~~~~~
+~~~~{.php}
 checkfaults results a_1
 Error : Number of faults is 5
-~~~~~
+~~~~
 It is possible to set the reference value for comparison (reference value is 4):
 
-~~~~~
+~~~~{.php}
 checkfaults results a_1 4
-~~~~~
+~~~~
 
 If number of faults in the resulting shape is unstable, reference value should be set to "-1".
 As a result command *checkfaults* will return the following error:
 
-~~~~~
+~~~~{.php}
 checkfaults results a_1 -1
 Error : Number of faults is UNSTABLE
-~~~~~
+~~~~
 
 @subsubsection testmanual_5_3_2 Shape tolerance
 
 The maximal tolerance of sub-shapes of each kind of the resulting shape can be extracted from output of tolerance command as follows:
 
-~~~~~
+~~~~{.php}
 set tolerance [tolerance result]
 regexp { *FACE +: +MAX=([-0-9.+eE]+)} $tolerance dummy max_face
 regexp { *EDGE +: +MAX=([-0-9.+eE]+)} $tolerance dummy max_edgee
 regexp { *VERTEX +: +MAX=([-0-9.+eE]+)} $tolerance dummy max_vertex
-~~~~~
+~~~~
 
 It is possible to use command *checkmaxtol* to check maximal tolerance of shape and compare it with reference value.
 
@@ -1162,39 +1162,39 @@ Allowed options are:
  *   <i>-multi_tol</i> -- tolerance multiplier.
 
 The default syntax of *checkmaxtol* command for comparison with the reference value:
-~~~~~
+~~~~{.php}
 checkmaxtol result -ref 0.00001
-~~~~~
+~~~~
 
 There is an opportunity to compare max tolerance of resulting shape with max tolerance of source shape.
 In the following example command *checkmaxtol* gets max tolerance among objects *a_1* and *a_2*.
 Then it chooses the maximum value between founded tolerance and value -min_tol (0.000001)
 and multiply it on the coefficient -multi_tol (i.e. 2):
 
-~~~~~
+~~~~{.php}
 checkmaxtol result -source {a_1 a_2} -min_tol 0.000001 -multi_tol 2
-~~~~~
+~~~~
 
 If the value of maximum tolerance more than founded tolerance for comparison, the command will return an error.
 
 Also, command *checkmaxtol* can be used to get max tolerance of the shape:
 
-~~~~~
+~~~~{.php}
 set maxtol [checkmaxtol result]
-~~~~~
+~~~~
 
 @subsubsection testmanual_5_3_3 Shape volume, area, or length
 
 Use command *vprops, sprops,* or *lprops* to correspondingly measure volume, area, or length of the shape produced by the test. The value can be extracted from the result of the command by *regexp*.
 
 Example:
-~~~~~
+~~~~{.php}
 # check area of shape result with 1% tolerance
 regexp {Mass +: +([-0-9.+eE]+)} [sprops result] dummy area
 if { abs($area - $expected) > 0.1 + 0.01 * abs ($area) } {
     puts "Error: The area of result shape is $area, while expected $expected"
 }
-~~~~~
+~~~~
 
 @subsubsection testmanual_5_3_4 Memory leaks
 
@@ -1204,7 +1204,7 @@ To check memory leak on a particular operation, run it in a cycle, measure the m
 The command *checktrend* (defined in *tests/bugs/begin*) can be used to analyze a sequence of memory measurements and to get a statistically based evaluation of the leak presence.
 
 Example: 
-~~~~~
+~~~~{.php}
 set listmem {}
 for {set i 1} {$i < 100} {incr i} {
     # run suspect operation 
@@ -1216,13 +1216,13 @@ for {set i 1} {$i < 100} {incr i} {
         break
     }
 }
-~~~~~
+~~~~
 
 @subsubsection testmanual_5_3_5 Visualization
 
 The following command sequence allows you to take a snapshot of the viewer, give it the name of the test case, and save in the directory indicated by Tcl variable *imagedir*. 
 
-~~~~~
+~~~~{.php}
 vinit
 vclear
 vdisplay result
@@ -1230,7 +1230,7 @@ vsetdispmode 1
 vfit
 vzfit
 vdump $imagedir/${casename}_shading.png
-~~~~~
+~~~~
 
 This image will be included in the HTML log produced by *testgrid* command and will be checked for non-regression through comparison of images by command *testdiff*.
 
@@ -1245,32 +1245,32 @@ Allowed options are:
 *   <i>-vdispmode N</i> -- sets *vdispmode* for 3d viewer (default value is 1)
 *   <i>-screenshot</i> -- makes a screenshot of already created viewer
 *   The procedure can check a property of shape (length, area or volume) and compare it with value *N*:
-       * <i>-l [N]</i>
-       * <i>-s [N]</i>
-       * <i>-v [N]</i>
-       * If the current property is equal to value *N*, the shape is marked as valid in the procedure.
-       * If value *N* is not given, the procedure will mark the shape as valid if the current property is non-zero.
+  * <i>-l [N]</i>
+  * <i>-s [N]</i>
+  * <i>-v [N]</i>
+  * If the current property is equal to value *N*, the shape is marked as valid in the procedure.
+  * If value *N* is not given, the procedure will mark the shape as valid if the current property is non-zero.
 *   <i>-with {a b c}</i> -- displays shapes *a, b* and *c* together with the shape (if the shape is valid)
 *   <i>-otherwise {d e f}</i> -- displays shapes *d, e* and *f* instead of the shape (if the shape is NOT valid)
 
 Note that is required to use either option <i> -2d </i> or option <i> -3d</i>.
 
 Examples:
-~~~~~
+~~~~{.php}
 checkview -display result -2d -path ${imagedir}/${test_image}.png
 checkview -display result -3d -path ${imagedir}/${test_image}.png
 checkview -display result_2d -2d v2d -path ${imagedir}/${test_image}.png
-~~~~~
+~~~~
 
-~~~~~
+~~~~{.php}
 box a 10 10 10
 box b 5 5 5 10 10 10
 bcut result b a
 set result_vertices [explode result v]
 checkview -display result -2d -with ${result_vertices} -otherwise { a b } -l -path ${imagedir}/${test_image}.png
-~~~~~
+~~~~
 
-~~~~~
+~~~~{.php}
 box a 10 10 10
 box b 5 5 5 10 10 10
 bcut result b a
@@ -1278,7 +1278,7 @@ vinit
 vdisplay a b
 vfit
 checkview -screenshot -3d -path ${imagedir}/${test_image}.png
-~~~~~
+~~~~
 
 @subsubsection testmanual_5_3_6 Number of free edges
 
@@ -1290,9 +1290,9 @@ Allowed options are:
  * <i>-tol N</i> -- used tolerance (default -0.01);
  * <i>-type N</i> -- used type, possible values are "closed" and "opened" (default "closed").
 
-~~~~~
+~~~~{.php}
 checkfreebounds result 13
-~~~~~
+~~~~
 
 Option <i>-tol N</i> defines tolerance for command *freebounds*, which is used within command *checkfreebounds*.
 
@@ -1301,10 +1301,10 @@ Option <i>-type N</i> is used to select the type of counted free edges: closed o
 If the number of free edges in the resulting shape is unstable, the reference value should be set to "-1".
 As a result command *checkfreebounds* will return the following error:
 
-~~~~~
+~~~~{.php}
 checkfreebounds result -1
 Error : Number of free edges is UNSTABLE
-~~~~~
+~~~~
 
 @subsubsection testmanual_5_3_7 Compare numbers
 
@@ -1312,9 +1312,9 @@ Procedure *checkreal* checks the equality of two reals with a tolerance (relativ
 
 Use: checkreal name value expected tol_abs tol_rel
 
-~~~~~
+~~~~{.php}
 checkreal "Some important value" $value 5 0.0001 0.01
-~~~~~
+~~~~
 
 @subsubsection testmanual_5_3_8 Check number of sub-shapes
 
@@ -1336,9 +1336,9 @@ Allowed options are:
       the same sub-shapes with different location as different sub-shapes.
  * <i>-m msg</i> -- prints "msg" in case of error
 
-~~~~~
+~~~~{.php}
 checknbshapes result -vertex 8 -edge 4
-~~~~~
+~~~~
 
 @subsubsection testmanual_5_3_9 Check pixel color
 
@@ -1354,9 +1354,9 @@ This procedure checks color with tolerance (5x5 area).
 
 Next example will compare color of point with coordinates x=100 y=100 with RGB color R=1 G=0 B=0.
 If colors are not equal, procedure will check the nearest ones points (5x5 area)
-~~~~~
+~~~~{.php}
 checkcolor 100 100 1 0 0
-~~~~~
+~~~~
 
 @subsubsection testmanual_5_3_10 Compute length, area and volume of input shape
 
@@ -1375,10 +1375,10 @@ Allowed options are:
 
 Options <i> -l, -s </i> and <i> -v</i> are independent and can be used in any order. Tolerance *epsilon* is the same for all options.
 
-~~~~~
+~~~~{.php}
 checkprops result -s 6265.68 
 checkprops result -s -equal FaceBrep
-~~~~~
+~~~~
 
 @subsubsection testmanual_5_3_11 Parse output dump and compare it with reference values
 
@@ -1391,9 +1391,9 @@ Allowed options are:
  * <i>-ref VALUE</i> -- list of reference values for each parameter in *NAME*; 
  * <i>-eps EPSILON</i> -- the epsilon defines relative precision of computation.
 
-~~~~~
+~~~~{.php}
 checkdump result -name {Center Axis XAxis YAxis Radii} -ref {{-70 0} {-1 -0} {-1 -0} {0 -1} {20 10}} -eps 0.01
-~~~~~
+~~~~
 
 @subsubsection testmanual_5_3_12 Compute length of input curve
 
@@ -1407,10 +1407,10 @@ Allowed options are:
  * <i>-equal CURVE</i> -- compares the length of input curves. Puts error if they are not equal;
  * <i>-notequal CURVE</i> -- compares the length of input curves. Puts error if they are equal.
 
-~~~~~
+~~~~{.php}
 checklength cp1 -l 7.278
 checklength res -l -equal ext_1
-~~~~~
+~~~~
 @subsubsection testmanual_5_3_13 Check maximum deflection, number of triangles and nodes in mesh
 
 Command *checktrinfo* can be used to to check the maximum deflection, as well as the number of nodes and triangles in mesh.
@@ -1438,33 +1438,33 @@ Note that options <i> -tri, -nod </i> and <i> -defl </i> do not work together wi
 Examples:
 
 Comparison with some reference values:
-~~~~~
+~~~~{.php}
 checktrinfo result -tri 129 -nod 131 -defl 0.01
-~~~~~
+~~~~
 
 Comparison with another mesh:
-~~~~~
+~~~~{.php}
 checktrinfo result -ref [tringo a]
-~~~~~
+~~~~
 
 Comparison of deflection with the max possible value:
-~~~~~
+~~~~{.php}
 checktrinfo result -max_defl 1
-~~~~~
+~~~~
 
 Check that the current values are not equal to zero:
-~~~~~
+~~~~{.php}
 checktrinfo result -tri -nod -defl
-~~~~~
+~~~~
 
 Check that the number of triangles and the number of nodes are not equal to some specific values:
-~~~~~
+~~~~{.php}
 checktrinfo result -tri !10 -nod !8
-~~~~~
+~~~~
 
 It is possible to compare current values with reference values with some tolerances.
 Use options <i>-tol_\* </i> for that.
-~~~~~
+~~~~{.php}
 checktrinfo result -defl 1 -tol_abs_defl 0.001
-~~~~~
+~~~~
 
index cbd67cae5887f9dd4ccca01b4adb106c686e397f..b21551abb02013ac3fd6be835a1119a58875052f 100644 (file)
@@ -49,34 +49,34 @@ Open CASCADE Test Harness or @ref occt_user_guides__test_harness "DRAW" provides
 
 In some cases the objects to be inspected are available in DRAW as results of DRAW commands. In other cases, however, it is necessary to inspect intermediate objects created by the debugged algorithm. To support this, DRAW provides a set of commands allowing the developer to store intermediate objects directly from the debugger stopped at some point during the program execution (usually at a breakpoint).
 
-~~~~~
+~~~~{.php}
 const char* Draw_Eval (const char *theCommandStr)
-~~~~~
+~~~~
 
 Evaluates a DRAW command or script.
 A command is passed as a string parameter.
 
-~~~~~
+~~~~{.php}
 const char* DBRep_Set (const char* theNameStr, void* theShapePtr)
-~~~~~
+~~~~
 
 Sets the specified shape as a value of DRAW interpreter variable with the given name.
 - *theNameStr* -- the DRAW interpreter variable name to set.
 - *theShapePtr* -- a pointer to *TopoDS_Shape* variable.
 
-~~~~~
+~~~~{.php}
 const char* DBRep_SetComp (const char* theNameStr, void* theListPtr)
-~~~~~
+~~~~
 
 Makes a compound from the specified list of shapes and sets it as a value of DRAW interpreter variable with the given name.
 - *theNameStr* -- the DRAW interpreter variable name to set.
 - *theListPtr* -- a pointer to *TopTools_ListOfShape* variable.
 
-~~~~~
+~~~~{.php}
 const char* DrawTrSurf_Set (const char* theNameStr, void* theHandlePtr)
 const char* DrawTrSurf_SetPnt (const char* theNameStr, void* thePntPtr)
 const char* DrawTrSurf_SetPnt2d (const char* theNameStr, void* thePnt2dPtr)
-~~~~~
+~~~~
 
 Sets the specified geometric object as a value of DRAW interpreter variable with the given name.
 - *theNameStr* -- the DRAW interpreter variable name to set.
@@ -90,27 +90,27 @@ All these functions are defined in *TKDraw* toolkit and return a string indicati
 
 The following functions are provided by *TKBRep* toolkit and can be used from debugger prompt:
 
-~~~~~
+~~~~{.php}
 const char* BRepTools_Write (const char* theFileNameStr, void* theShapePtr)
-~~~~~
+~~~~
 
 Saves the specified shape to a file with the given name.
 - *theFileNameStr* -- the name of the file where the shape is saved.
 - *theShapePtr* -- a pointer to *TopoDS_Shape* variable.
 
-~~~~~
+~~~~{.php}
 const char* BRepTools_Dump (void* theShapePtr)
 const char* BRepTools_DumpLoc (void* theShapePtr)
-~~~~~
+~~~~
 
 Dumps shape or its location to cout.
 - *theShapePtr* -- a pointer to *TopoDS_Shape* variable.
 
 The following function is provided by *TKMesh* toolkit:
 
-~~~~~
+~~~~{.php}
 const char* BRepMesh_Dump (void* theMeshHandlePtr, const char* theFileNameStr)
-~~~~~
+~~~~
 
 Stores mesh produced in parametric space to BREP file.
 - *theMeshHandlePtr* -- a pointer to *Handle(BRepMesh_DataStructureOfDelaun)* variable.
@@ -118,10 +118,10 @@ Stores mesh produced in parametric space to BREP file.
 
 The following functions are provided by *TKTopTest* toolkit:
 
-~~~~~
+~~~~{.php}
 const char* MeshTest_DrawLinks(const char* theNameStr, void* theFaceAttr)
 const char* MeshTest_DrawTriangles(const char* theNameStr, void* theFaceAttr)
-~~~~~
+~~~~
 
 Sets the edges or triangles from mesh data structure of type *Handle(BRepMesh_FaceAttribute)* as DRAW interpreter variables, assigning a unique name in the form "<theNameStr>_<index>" to each object.
 - *theNameStr* -- the prefix to use in names of objects.
@@ -129,9 +129,9 @@ Sets the edges or triangles from mesh data structure of type *Handle(BRepMesh_Fa
 
 The following additional function is provided by *TKGeomBase* toolkit:
 
-~~~~~
+~~~~{.php}
 const char* GeomTools_Dump (void* theHandlePtr)
-~~~~~
+~~~~
 
 Dump geometric object to cout.
 - *theHandlePtr* -- a pointer to the geometric variable (<i>Handle</i> to *Geom_Geometry* or *Geom2d_Curve* or descendant) to be set.
@@ -174,7 +174,7 @@ It is implemented in 'vaspect' and 'boundingbox' commands.
 
 Json output for Bnd_OBB (using command 'bounding v -obb -dumpJson'):
 
-~~~~~
+~~~~{.java}
 "Bnd_OBB": {
    "Center": {
       "gp_XYZ": [1, 2, 3]
@@ -193,7 +193,7 @@ Json output for Bnd_OBB (using command 'bounding v -obb -dumpJson'):
    "HDims[2]": 0,
    "IsAABox": 1,
 }
-~~~~~
+~~~~
 
 @section occt_debug_vstudio Using Visual Studio debugger 
 
@@ -206,18 +206,18 @@ When the execution is interrupted by a breakpoint, you can use this window to ca
 For example, assume that you are debugging a function, where local variable *TopoDS_Edge* *anEdge1* is of interest.
 The following set of commands in the Command window will save this edge to file *edge1.brep*, then put it to DRAW variable *e1* and show it maximized in the axonometric DRAW view:
 
-~~~~~
+~~~~{.php}
 >? ({,,TKBRep.dll}BRepTools_Write)("d:/edge1.brep",(void*)&anEdge1)
 0x04a2f234 "d:/edge1.brep"
 >? ({,,TKDraw.dll}DBRep_Set)("e1",(void*)&anEdge1)
 0x0369eba8 "e1"
 >? ({,,TKDraw.dll}Draw_Eval)("donly e1; axo; fit")
 0x029a48f0 ""
-~~~~~
+~~~~
 
 For convenience it is possible to define aliases to commands in this window, for instance (here ">" is prompt provided by the command window; in the Immediate window this symbol should be entered manually):
 
-~~~~~
+~~~~{.php}
 >alias deval      ? ({,,TKDraw}Draw_Eval)
 >alias dsetshape  ? ({,,TKDraw}DBRep_Set)
 >alias dsetcomp   ? ({,,TKDraw}DBRep_SetComp)
@@ -229,18 +229,18 @@ For convenience it is possible to define aliases to commands in this window, for
 >alias dumploc    ? ({,,TKBRep}BRepTools_DumpLoc)
 >alias dumpmesh   ? ({,,TKMesh}BRepMesh_Dump)
 >alias dumpgeom   ? ({,,TKGeomBase}GeomTools_Dump)
-~~~~
+~~~~
 
 Note that aliases are stored in the Visual Studio user's preferences and it is sufficient to define them once on a workstation. With these aliases, the above example can be reproduced easier (note the space symbol after alias name!):
 
-~~~~~
+~~~~{.php}
 >saveshape ("d:/edge1.brep",(void*)&anEdge1)
 0x04a2f234 "d:/edge1.brep"
 >dsetshape ("e1",(void*)&anEdge1)
 0x0369eba8 "e1"
 >deval ("donly e1; axo; fit")
 0x029a48f0 ""
-~~~~~
+~~~~
 
 Note that there is no guarantee that the call will succeed and will not affect the program execution, thus use this feature at your own risk. In particular, the commands interacting with window system (such as *axo*, *vinit*, etc.) are known to cause application crash when the program is built in 64-bit mode. To avoid this, it is recommended to prepare all necessary view windows in advance, and arrange these windows to avoid overlapping with the Visual Studio window, to ensure that they are visible during debug. 
 
@@ -252,7 +252,7 @@ In Visual Studio 2005-2010 the rules for this display are defined in file *autoe
 
 ### \[AutoExpand\] section 
 
-~~~~~
+~~~~{.cpp}
 ; Open CASCADE classes
 Standard_Transient=<,t> count=<count,d>
 Handle_Standard_Transient=<entity,x> count=<entity->count,d> <,t>
@@ -274,11 +274,11 @@ gp_Dir2d=<coord.x,g>, <coord.y,g>
 gp_Vec2d=<coord.x,g>, <coord.y,g>
 gp_Mat2d={<matrix[0][0],g>,<matrix[0][1],g>}, {<matrix[1][0],g>,<matrix[1][1],g>}
 gp_Ax1=loc={<loc.coord.x,g>, <loc.coord.y,g>, <loc.coord.z,g>} vdir={<vdir.coord.x,g>, <vdir.coord.y,g>, <vdir.coord.z,g>}
-~~~~
+~~~~
 
 ### \[Visualizer\] section
 
-~~~~~
+~~~~{.cpp}
 ; Open CASCADE classes
 
 NCollection_Handle<*> {
@@ -342,7 +342,7 @@ Handle_TCollection_HAsciiString {
              #array( expr: ((TCollection_HAsciiString*)$e.entity)->myString.mystring[$i], 
                      size: ((TCollection_HAsciiString*)$e.entity)->myString.mylength) ) )
 }
-~~~~~
+~~~~
 
 In Visual Studio 2012 and later, visualizers can be put in a separate file in subdirectory *Visualizers*. See file *occt.natvis* for example.
 
@@ -403,7 +403,10 @@ Example of configuration steps for Ubuntu:
 
 7. Run DRAW and perform tests as usual, keeping in mind that running with sanitizer is much heavier than normal build:
 > ./draw.sh relwithdeb  <br>
-> Draw[]> testgrid -parallel 0
+
+~~~~{.php}
+Draw[]> testgrid -parallel 0
+~~~~
 
 Note that when running tests under sanitizers, behavior may be different.
 Known problems (as of CLang 6.0) are:
index 4d5cc2ce9f33d78916dbe2c9ab96a8899e6a206e..c32ef176cab9f7d1168c56fb44fadc0c13db0c11 100644 (file)
@@ -380,7 +380,7 @@ https://www.opencascade.com/content/3rd-party-components
 | Component | Requirement |
 | --------- | ----------- |
 | Minimum memory    | 512 MB, 1 GB recommended |
-| Free disk space (complete installation) | 600 MB approx. |
+| Free disk space (complete installation) | 1,5 GB approx. |
 
 On desktop, 3D viewer for optimal performance requires graphics processing unit (GPU) supporting OpenGL 3.3 or above. 
 Ray tracing requires OpenGL 4.0+ or OpenGL 3.3+ with *GL_ARB_texture_buffer_object_rgb32* extension.
index f267d962b266062fd86a3b5a4a9fe1a08c715d8a..57cf5fb8acc8d924da079c808eea9b5bf0620e4f 100644 (file)
@@ -128,7 +128,7 @@ ad696002-5b34-11d1-b5ba-00a0c9064368.Location: PAppStdPlugin
  
 ## Implementation of Attribute Transformation in a HXX file
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~
 \#include <TDF_Attribute.hxx>
 
 \#include <gp_Ax3.hxx>
@@ -223,11 +223,11 @@ private:
   gp_Pnt myFirstPoint;
   gp_Pnt mySecondPoint;
 }; 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 ## Implementation of Attribute Transformation in a CPP file
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
 \#include <MyPackage_Transformation.hxx> 
 
 //======================================================================= 
@@ -526,7 +526,7 @@ Standard_OStream& MyPackage_Transformation::Dump(Standard_OStream& anOS) const
 MyPackage_Transformation::MyPackage_Transformation():myType(gp_Identity){ 
 
 }
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 ##  Implementation of typical actions with standard OCAF attributes.
 
index 12576ab2ba97d03dd0888be6f27d39399d03086e..dec2b81bec28a2cc0825df1da41955972d4a6394 100644 (file)
@@ -160,7 +160,7 @@ drivers for a function  driver table with the help of *TFunction_DriverTable* cl
 
   This is an example of the code for iteration and execution of functions.  
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
 
     // The scope of functions is  defined.  
     Handle(TFunction_Scope) scope = TFunction_Scope::Set( anyLabel );  
@@ -200,14 +200,14 @@ drivers for a function  driver table with the help of *TFunction_DriverTable* cl
       } // end of iteration of current functions  
     } // end of iteration of  functions.
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 ### Example 2: Cylinder function driver
 
   This is an example of the code for a cylinder function driver. To make the things clearer, the methods 
 <i>\::Arguments()</i>  and <i>\::Results()</i>  from the base class are also mentioned.   
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
 
     // A virtual method  ::Arguments() returns a list of arguments of the function.  
     CylinderDriver::Arguments( TDF_LabelList&amp; args )  
@@ -283,4 +283,4 @@ drivers for a function  driver table with the help of *TFunction_DriverTable* cl
        
       return 0;
     }
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
index 96de5fe0c1dc0229a0aea604f9c8e9ff06195da8..1d2fac6b72e0b6aaf16a908bccfcbb5f9841b0bb 100644 (file)
@@ -811,7 +811,7 @@ The following example illustrates how to use the GF algorithm:
 
 #### Usage of the GF algorithm on C++ level
 
-~~~~
+~~~~{.cpp}
 BOPAlgo_Builder aBuilder;
 // Setting arguments
 TopTools_ListOfShape aLSObjects = …; // Objects
@@ -865,7 +865,7 @@ const TopoDS_Shape& aResult = aBuilder.Shape();
 
 #### Usage of the GF algorithm on Tcl level
 
-~~~~
+~~~~{.cpp}
 # prepare the arguments
 box b1 10 10 10 
 box b2 3 4 5 10 10 10 
@@ -1199,7 +1199,7 @@ It is based on the General Fuse  algorithm, thus all options of the General Fuse
 @subsubsection specification__boolean_8_3_1 API
 
 On the low level the Splitter algorithm is implemented in class *BOPAlgo_Splitter*. The usage of this algorithm looks as follows:
-~~~~~
+~~~~{.cpp}
 BOPAlgo_Splitter aSplitter;
 // Setting arguments and tools
 TopTools_ListOfShape aLSObjects = …; // Objects
@@ -1218,12 +1218,12 @@ if (aSplitter.HasErrors()) { //check error status
 }
 //
 const TopoDS_Shape& aResult = aSplitter.Shape(); // result of the operation
-~~~~~
+~~~~
 
 @subsubsection specification__boolean_8_3_2 DRAW
 
 The command *bsplit* implements the Splitter algorithm in DRAW. Similarly to the *bbuild* command for the General Fuse algorithm, the *bsplit* command should be used after the Pave Filler is filled.
-~~~~~
+~~~~{.cpp}
 # s1 s2 s3 - objects
 # t1 t2 t3 - tools
 bclearobjects
@@ -1232,7 +1232,7 @@ baddobjects s1 s2 s3
 baddtools t1 t2 t3
 bfillds
 bsplit result
-~~~~~
+~~~~
 
 @subsection specification__boolean_8_4 Examples
 
@@ -1240,7 +1240,7 @@ bsplit result
 
 Splitting a face by the set of edges:
 
-~~~~
+~~~~{.cpp}
 # draw script for reproducing
 bclearobjects
 bcleartools
@@ -1286,7 +1286,7 @@ bsplit result
 
 Splitting a plate by the set of cylinders:
 
-~~~~
+~~~~{.cpp}
 # draw script for reproducing:
 bclearobjects
 bcleartools
@@ -2182,7 +2182,7 @@ This option is useful e.g. for building a solid from the faces of one shell or f
 
 #### C++ Level
 The usage of the algorithm on the API level:
-~~~~
+~~~~{.cpp}
 BOPAlgo_MakerVolume aMV;
 // Set the arguments
 TopTools_ListOfShape aLS = …; // arguments
@@ -2206,7 +2206,7 @@ const TopoDS_Shape& aResult = aMV.Shape(); // result of the operation
 
 #### Tcl Level
 To use the algorithm in Draw the command mkvolume has been implemented. The usage of this command is following:
-~~~~
+~~~~{.php}
 Usage: mkvolume r b1 b2 ... [-c] [-ni] [-ai]
 Options:
 -c - use this option to have input compounds considered as set of separate arguments (allows passing multiple arguments as one compound);
@@ -2309,7 +2309,7 @@ aResult = aCBuilder.Shape(); // the result
 #### DRAW usage
 
 The following set of new commands has been implemented to run the algorithm in DRAW Test Harness:
-~~~~
+~~~~{.php}
 bcbuild          : Initialization of the Cells Builder. Use: *bcbuild r*
 bcadd            : Add parts to result. Use: *bcadd r s1 (0,1) s2 (0,1) ... [-m material [-u]]*
 bcaddall         : Add all parts to result. Use: *bcaddall r [-m material [-u]]*
@@ -2320,7 +2320,7 @@ bcmakecontainers : Make containers from the parts added to result. Use: *bcmakec
 ~~~~
 
 Here is the example of the algorithm use on the DRAW level:
-~~~~
+~~~~{.php}
 psphere s1 15
 psphere s2 15
 psphere s3 15
@@ -2343,7 +2343,7 @@ bcremoveint res
 @subsection specification__boolean_10c_Cells_2 Examples
 
 The following simple example illustrates the possibilities of the algorithm working on a cylinder and a sphere intersected by a plane:
-~~~~
+~~~~{.php}
 pcylinder c 10 30 
 psphere s 15
 ttranslate s 0 0 30
@@ -2353,7 +2353,7 @@ mkface f p -25 30 -17 17
 
 @figure{/specification/boolean_operations/images/cells_algorithm_001.png,"Arguments",160} 
 
-~~~~
+~~~~{.php}
 bclearobjects
 bcleartools
 baddobjects c s f
@@ -2363,7 +2363,7 @@ bcbuild r
 
 #### 1. Common for all arguments
 
-~~~~
+~~~~{.php}
 bcremoveall
 bcadd res c 1 s 1 f 1
 ~~~~
@@ -2372,7 +2372,7 @@ bcadd res c 1 s 1 f 1
 
 #### 2. Common between cylinder and face
 
-~~~~
+~~~~{.php}
 bcremoveall
 bcadd res f 1 c 1
 ~~~~
@@ -2381,7 +2381,7 @@ bcadd res f 1 c 1
 
 #### 3. Common between cylinder and sphere
 
-~~~~
+~~~~{.php}
 bcremoveall
 bcadd res c 1 s 1
 ~~~~
@@ -2390,7 +2390,7 @@ bcadd res c 1 s 1
 
 #### 4. Fuse of cylinder and sphere
 
-~~~~
+~~~~{.php}
 bcremoveall
 bcadd res c 1 -m 1
 bcadd res s 1 -m 1
@@ -2401,7 +2401,7 @@ bcremoveint res
 
 #### 5. Parts of the face inside solids - FUSE(COMMON(f, c), COMMON(f, s))
 
-~~~~
+~~~~{.php}
 bcremoveall
 bcadd res f 1 s 1 -m 1
 bcadd res f 1 c 1 -m 1
@@ -2409,7 +2409,7 @@ bcadd res f 1 c 1 -m 1
 
 @figure{/specification/boolean_operations/images/cells_algorithm_006_1.png,"Parts of the face inside solids",160} 
 
-~~~~
+~~~~{.php}
 bcremoveint res
 ~~~~
 
@@ -2417,7 +2417,7 @@ bcremoveint res
 
 #### 6. Part of the face outside solids
 
-~~~~
+~~~~{.php}
 bcremoveall
 bcadd res f 1 c 0 s 0
 ~~~~
@@ -2426,7 +2426,7 @@ bcadd res f 1 c 0 s 0
 
 #### 7. Fuse operation (impossible using standard Boolean Fuse operation)
 
-~~~~
+~~~~{.php}
 bcremoveall
 bcadd res c 1 -m 1
 bcadd res s 1 -m 1
@@ -2788,7 +2788,7 @@ For setting the Gluing options in DRAW it is necessary to call the <i>bglue</i>
 * 1 - for partial coincidence;
 * 2 - for full coincidence
 
-~~~~
+~~~~{.php}
 bglue 1
 ~~~~
 
@@ -2836,7 +2836,7 @@ To enable the safe processing mode for the operation in DRAW, it is necessary to
 * 0 - default value, the safe mode is switched off;
 * 1 - the safe mode will be switched on.
 
-~~~~
+~~~~{.php}
 bnondestructive 1
 ~~~~
 
@@ -2867,7 +2867,7 @@ To enable/disable the classification of the solids in DRAW, it is necessary to c
 * 0 - disabling the classification;
 * 1 - default value, enabling the classification.
 
-~~~~
+~~~~{.php}
 bcheckinverted 0
 ~~~~
 
@@ -2893,7 +2893,7 @@ aGF.SetUseOBB(Standard_True);
 To enable/disable the usage of OBB in the operation in DRAW it is necessary to call the *buseobb* command with the appropriate value:
 * 0 - disabling the usage of OBB;
 * 1 - enabling the usage of OBB.
-~~~~
+~~~~{.php}
 buseobb 1
 ~~~~
 
@@ -2919,7 +2919,7 @@ Note that messages corresponding to errors and warnings are defined in resource
 These messages can be localized; for that put translated version to separate file and load it in the application by call to *Message_MsgFile::Load()* .
 
 Here is the example of how to use this system:
-~~~~~
+~~~~{.php}
 BOPAlgo_PaveFiller aPF;
 aPF.SetArguments(...);
 aPF.Perform();
@@ -2934,12 +2934,12 @@ if (aPF.HasErrors()) {
   }
   ...
 }
-~~~~~
+~~~~
 
 DRAW commands executing Boolean operations output errors and warnings generated by these operations in textual form.
 Additional option allows saving shapes for which warnings have been generated, as DRAW variables. 
 To activate this option, run command *bdrawwarnshapes* with argument 1 (or with 0 to deactivate):
-~~~~
+~~~~{.php}
 bdrawwarnshapes 1
 ~~~~
 
@@ -2978,7 +2978,7 @@ But if the faces are fully coinciding, the result must be empty, and both faces
 
 Example of the overlapping faces:
 
-~~~~
+~~~~{.php}
 plane p 0 0 0 0 0 1
 mkface f1 p -10 10 -10 10
 mkface f2 p 0 20 -10 10
@@ -3005,7 +3005,7 @@ Thus, each of the input edges will be Modified into its two splits.
 But in the CUT operation on the same edges, the tool edge will be Deleted from the result and, thus, will not have any Modified shapes.
 
 Example of the intersecting edges:
-~~~~
+~~~~{.php}
 line l1 0 0 0 1 0 0
 mkedge e1 l1 -10 10
 
@@ -3051,7 +3051,7 @@ Two intersecting edges will both have the intersection vertices Generated from t
 
 As for the operation with intersecting faces, consider the following example:
 
-~~~~
+~~~~{.php}
 plane p1 0 0 0 0 0 1
 mkface f1 p1 -10 10 -10 10
 
@@ -3115,7 +3115,7 @@ For controlling this possibility in DRAW the command **bsimplify** has been impl
 
 Here is the simple example of simplification of the result of Fuse operation of two boxes:
 
-~~~~
+~~~~{.php}
 bsimplify -f 1
 
 box b1 10 10 15
@@ -3173,7 +3173,7 @@ The following example illustrates how to use General Fuse operator:
 
 #### C++ Level
 
-~~~~
+~~~~{.cpp}
 #include <TopoDS_Shape.hxx>
 #include <TopTools_ListOfShape.hxx>
 #include <BRepAlgoAPI_BuilderAlgo.hxx>
@@ -3205,7 +3205,7 @@ The following example illustrates how to use General Fuse operator:
 
 #### Tcl Level
 
-~~~~
+~~~~{.php}
 # prepare the arguments
 box b1 10 10 10 
 box b2 3 4 5 10 10 10 
@@ -3231,7 +3231,7 @@ The following example illustrates how to use the Splitter operator:
 
 #### C++ Level
 
-~~~~
+~~~~{.cpp}
 #include <TopoDS_Shape.hxx>
 #include <TopTools_ListOfShape.hxx>
 #include <BRepAlgoAPI_Splitter.hxx>
@@ -3265,7 +3265,7 @@ const TopoDS_Shape& aResult = aSplitter.Shape();
 
 #### Tcl Level
 
-~~~~
+~~~~{.php}
 # prepare the arguments
 # objects
 box b1 10 10 10 
@@ -3297,7 +3297,7 @@ The following example illustrates how to use Common operation:
 
 #### C++ Level
 
-~~~~
+~~~~{.cpp}
 #include <TopoDS_Shape.hxx>
 #include <TopTools_ListOfShape.hxx>
 #include < BRepAlgoAPI_Common.hxx>
@@ -3336,7 +3336,7 @@ The following example illustrates how to use Common operation:
 
 #### Tcl Level
 
-~~~~
+~~~~{.php}
 # prepare the arguments
 box b1 10 10 10 
 box b2 7 0 4 10 10 10 
@@ -3364,7 +3364,7 @@ The following example illustrates how to use Fuse operation:
 
 #### C++ Level
 
-~~~~
+~~~~{.cpp}
 #include <TopoDS_Shape.hxx>
 #include <TopTools_ListOfShape.hxx>
 #include < BRepAlgoAPI_Fuse.hxx>
@@ -3403,7 +3403,7 @@ The following example illustrates how to use Fuse operation:
 
 #### Tcl Level
 
-~~~~
+~~~~{.php}
 # prepare the arguments
 box b1 10 10 10 
 box b2 7 0 4 10 10 10 
@@ -3431,7 +3431,7 @@ The following example illustrates how to use Cut operation:
 
 #### C++ Level
 
-~~~~
+~~~~{.cpp}
 #include <TopoDS_Shape.hxx>
 #include <TopTools_ListOfShape.hxx>
 #include < BRepAlgoAPI_Cut.hxx>
@@ -3470,7 +3470,7 @@ The following example illustrates how to use Cut operation:
 
 #### Tcl Level
 
-~~~~
+~~~~{.php}
 # prepare the arguments
 box b1 10 10 10 
 box b2 7 0 4 10 10 10 
@@ -3499,7 +3499,7 @@ The following example illustrates how to use Section operation:
 
 #### C++ Level
 
-~~~~
+~~~~{.cpp}
 #include <TopoDS_Shape.hxx>
 #include <TopTools_ListOfShape.hxx>
 #include < BRepAlgoAPI_Section.hxx>
@@ -3538,7 +3538,7 @@ The following example illustrates how to use Section operation:
 
 #### Tcl Level
 
-~~~~
+~~~~{.php}
 # prepare the arguments
 box b1 10 10 10 
 box b2 3 4 5 10 10 10 
index 767a59d313ee8389eb68d46fe4489ead9fb0b8b5..4565bb21ace2866616b279359e9eeb0f6d40cecc 100644 (file)
@@ -35,12 +35,12 @@ Each of these methods has two arguments:
 
 The following sample code reads a shape from ASCII file and writes it to a binary one:
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
   TopoDS_Shape aShape;
   if (BRepTools::Read (aShape, "source_file.txt")) {
     BinTools::Write (aShape, "result_file.bin");
   }
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
  
 @section specification__brep_format_3 Format Common Structure
  
@@ -250,7 +250,7 @@ The example record is interpreted as a line which  passes through a point *P*=(1
  
 **BNF-like Definition**
  
-~~~~
+~~~~{.cpp}
     <3D curve record 2> = "2" <_> <3D circle center> <_> <3D circle N> <_> <3D circle Dx> <_> <3D circle Dy> <_> <3D circle radius> <_\n>;  
      
     <3D circle center> = <3D point>;  
@@ -283,7 +283,7 @@ The  example record is interpreted as a circle which has its center *P*=(1, 2, 3
  
 **BNF-like Definition**
 
-~~~~
+~~~~{.cpp}
     <3D curve record 3> = "3" <_> <3D ellipse center> <_> <3D ellipse N> <_> <3D ellipse Dmaj> <_> <3D ellipse Dmin> <_> <3D ellipse Rmaj> <_> <3D ellipse Rmin> <_\n>;  
      
     <3D ellipse center> = <3D point>;  
@@ -318,7 +318,7 @@ The  example record is interpreted as an ellipse which has its center *P*=(1, 2,
  
 **BNF-like Definition**  
 
-~~~~
+~~~~{.cpp}
     <3D curve record 4> = "4" <_> <3D parabola origin> <_> <3D parabola N> <_> <3D parabola Dx> <_> <3D parabola Dy> <_> <3D parabola focal length> <_\n>;  
      
     <3D parabola origin> = <3D point>;  
@@ -352,7 +352,7 @@ The  example record is interpreted as a parabola in plane which passes through a
  
 **BNF-like Definition**  
 
-~~~~
+~~~~{.cpp}
     <3D curve record 5> = "5" <_> <3D hyperbola origin> <_> <3D hyperbola N> <_> <3D hyperbola Dx> <_> <3D hyperbola Dy> <_> <3D hyperbola Kx> <_> <3D hyperbola Ky> <_\n>;  
      
     <3D hyperbola origin> = <3D point>;  
@@ -428,7 +428,7 @@ The example record is interpreted as a Bezier curve with a rational flag *r*=1,
  
 **BNF-like Definition**
 
-~~~~
+~~~~{.cpp}
        <3D curve record 7> = "7" <_> <3D B-spline rational flag> <_> "0" <_> <3D B-spline degree> <_> 
        <3D B-spline pole count> <_> <3D B-spline multiplicity knot count> <3D B-spline weight poles> 
        <_\n> <3D B-spline multiplicity knots> <_\n>;
@@ -492,7 +492,7 @@ The example record is interpreted as a B-spline curve  with a rational flag *r*=
  
 **BNF-like Definition**  
 
-~~~~
+~~~~{.cpp}
        <3D curve record 8> = "8" <_> <3D trimmed curve u min> <_> <3D trimmed curve u max> <_\n> <3D curve record>;
 
        <3D trimmed curve u min> = <real>;
@@ -764,7 +764,7 @@ where @f$ V(v)=(5,2,0)+4 \cdot (cos(v) \cdot (1,0,0)+sin(v) \cdot (0,1,0)), V_{D
  
 **BNF-like Definition**
 
-~~~~
+~~~~{.cpp}
        <surface record 8> = "8" <_> <Bezier surface u rational flag> <_> <Bezier surface v rational flag> <_> <Bezier surface u degree> <_> <Bezier surface v degree> <_> 
        <Bezier surface weight poles>;
 
@@ -1076,7 +1076,7 @@ The example record is interpreted as a line which  passes through a point *P*=(3
  
 **BNF-like Definition**
 
-~~~~
+~~~~{.cpp}
        <2D curve record 2> = "2" <_> <2D circle center> <_> <2D circle Dx> <_> <2D circle Dy> <_> <2D circle radius> <_\n>;
 
        <2D circle center> = <2D point>;
@@ -1247,7 +1247,7 @@ The example record is interpreted as a Bezier curve  with a rational flag *r*=1,
  
 **BNF-like Definition**
 
-~~~~
+~~~~{.cpp}
        <2D curve record 7> = "7" <_> <2D B-spline rational flag> <_> "0" <_> <2D B-spline degree> <_> <2D B-spline pole count> <_> <2D B-spline multiplicity knot count> <2D B-spline weight poles> <_\n> <2D B-spline multiplicity knots> <_\n>;
 
        <2D B-spline rational flag> = <flag>;
@@ -1430,7 +1430,7 @@ The example record describes a polyline from *m*=2 nodes with a parameter prese
  
 **BNF-like Definition**
 
-~~~~
+~~~~{.cpp}
        <triangulations> = <triangulation header> <_\n> <triangulation records>;
 
        <triangulation header> = "Triangulations" <_> <triangulation count>;
@@ -1785,7 +1785,7 @@ The usage of \<vertex data representation u  parameter\> *U* is  described belo
  
 **BNF-like Definition**
 
-~~~~
+~~~~{.cpp}
        <edge data> = <_> <edge data tolerance> <_> <edge data same parameter flag> <_> edge data same range flag> <_> <edge data degenerated flag> <_\n> <edge data representations>;
 
        <edge data tolerance> = <real>;
@@ -1855,7 +1855,7 @@ Flags \<edge data same parameter flag\>, \<edge data same range flag\> and \<edg
  
 **BNF-like Definition**
 
-~~~~
+~~~~{.cpp}
        <face data> = <face data natural restriction flag> <_> <face data tolerance> <_> <surface number> <_> <location number> <\n> ["2" <_> <triangulation number>];
 
        <face data natural restriction flag> = <flag>;
index 5447e2f2375b8b18ed869d9148f8d48ea25ee45b..7858488bef48165083953b113ebdf5718b1f7903 100644 (file)
@@ -66,19 +66,19 @@ To choose the best class for this application, consider the following:
 Since all the points you will define are only used to create the profile's curves, an object with a limited lifetime will do. Choose the *gp_Pnt* class.
 To instantiate a *gp_Pnt* object, just specify the X, Y, and Z coordinates of the points in the global Cartesian coordinate system:
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
     gp_Pnt aPnt1(-myWidth / 2., 0, 0);
     gp_Pnt aPnt2(-myWidth / 2., -myThickness / 4., 0);
     gp_Pnt aPnt3(0, -myThickness / 2., 0);
     gp_Pnt aPnt4(myWidth / 2., -myThickness / 4., 0);
     gp_Pnt aPnt5(myWidth / 2., 0, 0);
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 Once your objects are instantiated, you can use methods provided by the class to access and modify its data. For example, to get the X coordinate of a point:
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
 Standard_Real xValue1 = aPnt1.X();
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 @subsection OCCT_TUTORIAL_SUB2_2 Profile: Defining the Geometry
 With the help of the previously defined points, you can compute a part of the bottle's profile geometry. As shown in the figure below, it will consist of two segments and one arc.
@@ -95,15 +95,15 @@ This is because the *GC* provides two algorithm classes which are exactly what i
 
 Both of these classes return a *Geom_TrimmedCurve* manipulated by handle. This entity represents a base curve (line or circle, in our case), limited between two of its parameter values. For example, circle C is parameterized between 0 and 2PI. If you need to create a quarter of a circle, you create a *Geom_TrimmedCurve* on C limited between 0 and M_PI/2.
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
     Handle(Geom_TrimmedCurve) aArcOfCircle = GC_MakeArcOfCircle(aPnt2,aPnt3,aPnt4);
     Handle(Geom_TrimmedCurve) aSegment1    = GC_MakeSegment(aPnt1, aPnt2);
     Handle(Geom_TrimmedCurve) aSegment2    = GC_MakeSegment(aPnt4, aPnt5);
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 All *GC* classes provide a casting method to obtain a result automatically with a function-like call. Note that this method will raise an exception if construction has failed. To handle possible errors more explicitly, you may use the *IsDone* and *Value* methods. For example:
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
     GC_MakeSegment mkSeg (aPnt1, aPnt2);
     Handle(Geom_TrimmedCurve) aSegment1;
     if(mkSegment.IsDone()){
@@ -112,7 +112,7 @@ All *GC* classes provide a casting method to obtain a result automatically with
     else {
     // handle error
     }
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 
 @subsection OCCT_TUTORIAL_SUB2_3 Profile: Defining the Topology
@@ -144,18 +144,18 @@ Referring to the previous table, to build the profile, you will create:
 However, the *TopoDS* package provides only the data structure of the topological entities. Algorithm classes available to compute standard topological objects can be found in the *BRepBuilderAPI* package.
 To create an edge, you use the BRepBuilderAPI_MakeEdge class with the previously computed curves:
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
     TopoDS_Edge aEdge1 = BRepBuilderAPI_MakeEdge(aSegment1);
     TopoDS_Edge aEdge2 = BRepBuilderAPI_MakeEdge(aArcOfCircle);
     TopoDS_Edge aEdge3 = BRepBuilderAPI_MakeEdge(aSegment2);
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 In Open CASCADE Technology, you can create edges in several ways. One possibility is to create an edge directly from two points, in which case the underlying geometry of this edge is a line, bounded by two vertices being automatically computed from the two input points. For example, aEdge1 and aEdge3 could have been computed in a simpler way:
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
     TopoDS_Edge aEdge1 = BRepBuilderAPI_MakeEdge(aPnt1, aPnt3);
     TopoDS_Edge aEdge2 = BRepBuilderAPI_MakeEdge(aPnt4, aPnt5);
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 To connect the edges, you need to create a wire with the *BRepBuilderAPI_MakeWire* class. There are two ways of building a wire with this class:
 
@@ -164,9 +164,9 @@ To connect the edges, you need to create a wire with the *BRepBuilderAPI_MakeWir
 
 When building a wire from less than four edges, as in the present case, you can use the constructor directly as follows:
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
     TopoDS_Wire aWire = BRepBuilderAPI_MakeWire(aEdge1, aEdge2, aEdge3);
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 
 @subsection OCCT_TUTORIAL_SUB2_4 Profile: Completing the Profile
@@ -186,17 +186,17 @@ The first way is to define it from scratch, using its geometric definition:
   * X axis is located at (0, 0, 0) - use the *gp_Pnt* class.
   * X axis direction is (1, 0, 0) - use the *gp_Dir* class. A *gp_Dir* instance is created out of its X, Y and Z coordinates.
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
     gp_Pnt aOrigin(0, 0, 0);
     gp_Dir xDir(1, 0, 0);
     gp_Ax1 xAxis(aOrigin, xDir);
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 The second and simplest way is to use the geometric constants defined in the gp package (origin, main directions and axis of the global coordinate system). To get the X axis, just call the *gp::OX* method:
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
     gp_Ax1 xAxis = gp::OX();
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 As previously explained, the 3D geometric transformation is defined with the *gp_Trsf* class. There are two different ways to use this class:
 
@@ -205,43 +205,43 @@ As previously explained, the 3D geometric transformation is defined with the *gp
     
 Since the simplest approach is always the best one, you should use the SetMirror method with the axis as the center of symmetry.
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
     gp_Trsf aTrsf;
     aTrsf.SetMirror(xAxis);
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 You now have all necessary data to apply the transformation with the BRepBuilderAPI_Transform class by specifying:
 
   * the shape on which the transformation must be applied.
   * the geometric transformation
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
     BRepBuilderAPI_Transform aBRepTrsf(aWire, aTrsf);
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 *BRepBuilderAPI_Transform* does not modify the nature of the shape: the result of the reflected wire remains a wire. But the function-like call or the *BRepBuilderAPI_Transform::Shape* method returns a *TopoDS_Shape* object:
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
     TopoDS_Shape aMirroredShape = aBRepTrsf.Shape();
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 What you need is a method to consider the resulting reflected shape as a wire. The *TopoDS* global functions provide this kind of service by casting a shape into its real type. To cast the transformed wire, use the *TopoDS::Wire* method.
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
     TopoDS_Wire aMirroredWire = TopoDS::Wire(aMirroredShape);
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 The bottle's profile is almost finished. You have created two wires: *aWire* and *aMirroredWire*. You need to concatenate them to compute a single shape. To do this, you use the *BRepBuilderAPI_MakeWire* class as follows:
 
   * create an instance of *BRepBuilderAPI_MakeWire*.
   * add all edges of the two wires by using the *Add* method on this object.
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
     BRepBuilderAPI_MakeWire mkWire;
     mkWire.Add(aWire);
     mkWire.Add(aMirroredWire);
     TopoDS_Wire myWireProfile = mkWire.Wire();
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 
 @section sec3 Building the Body
@@ -266,9 +266,9 @@ Your current profile is a wire. Referring to the Shape/Generates table, you need
 To create a face, use the *BRepBuilderAPI_MakeFace* class. As previously explained, a face is a part of a surface bounded by a closed wire. Generally, *BRepBuilderAPI_MakeFace* computes a face out of a surface and one or more wires.
 When the wire lies on a plane, the surface is automatically computed.
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
     TopoDS_Face myFaceProfile = BRepBuilderAPI_MakeFace(myWireProfile);
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 The *BRepPrimAPI* package provides all the classes to create topological primitive constructions: boxes, cones, cylinders, spheres, etc. Among them is the *BRepPrimAPI_MakePrism* class. As specified above, the prism is defined by:
 
@@ -277,15 +277,15 @@ The *BRepPrimAPI* package provides all the classes to create topological primiti
 
 You want the solid to be finite, swept along the Z axis and to be myHeight height. The vector, defined with the *gp_Vec* class on its X, Y and Z coordinates, is:
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
     gp_Vec aPrismVec(0, 0, myHeight);
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 All the necessary data to create the main body of your bottle is now available. Just apply the *BRepPrimAPI_MakePrism* class to compute the solid:
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
     TopoDS_Shape myBody = BRepPrimAPI_MakePrism(myFaceProfile, aPrismVec);
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 
 @subsection OCCT_TUTORIAL_SUB3_2 Applying Fillets
@@ -305,9 +305,9 @@ To apply fillets on the edges of a shape, you use the *BRepFilletAPI_MakeFillet*
   * Add the fillet descriptions (an edge and a radius) using the *Add* method (you can add as many edges as you need).
   * Ask for the resulting filleted shape with the *Shape* method.
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
 BRepFilletAPI_MakeFillet mkFillet(myBody);
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 To add the fillet description, you need to know the edges belonging to your shape. The best solution is to explore your solid to retrieve its edges. This kind of functionality is provided with the *TopExp_Explorer* class, which explores the data structure described in a *TopoDS_Shape* and extracts the sub-shapes you specifically need. 
 Generally, this explorer is created by providing the following information:
@@ -315,9 +315,9 @@ Generally, this explorer is created by providing the following information:
   * the shape to explore
   * the type of sub-shapes to be found. This information is given with the *TopAbs_ShapeEnum* enumeration.
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
 TopExp_Explorer anEdgeExplorer(myBody, TopAbs_EDGE);
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 An explorer is usually applied in a loop by using its three main methods:
 
@@ -326,26 +326,26 @@ An explorer is usually applied in a loop by using its three main methods:
   * *Next()* to move onto the next sub-shape to explore.
 
   
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
     while(anEdgeExplorer.More()){
         TopoDS_Edge anEdge = TopoDS::Edge(anEdgeExplorer.Current());
         //Add edge to fillet algorithm
         ...
         anEdgeExplorer.Next();
     }
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 In the explorer loop, you have found all the edges of the bottle shape. Each one must then be added in the *BRepFilletAPI_MakeFillet* instance with the *Add()* method. Do not forget to specify the radius of the fillet along with it.
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
     mkFillet.Add(myThickness / 12., anEdge);
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 Once this is done, you perform the last step of the procedure by asking for the filleted shape.
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
     myBody = mkFillet.Shape();
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 
 @subsection OCCT_TUTORIAL_SUB3_3 Adding the Neck
@@ -358,31 +358,31 @@ To add a neck to the bottle, you will create a cylinder and fuse it to the body.
 To position the cylinder, you need to define a coordinate system with the *gp_Ax2* class defining a right-handed coordinate system from a point and two directions - the main (Z) axis direction and the X direction (the Y direction is computed from these two).
 To align the neck with the center of the top face, being in the global coordinate system (0, 0, *myHeight*), with its normal on the global Z axis, your local coordinate system can be defined as follows:
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
     gp_Pnt neckLocation(0, 0, myHeight);
     gp_Dir neckAxis = gp::DZ();
     gp_Ax2 neckAx2(neckLocation, neckAxis);
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 To create a cylinder, use another class from the primitives construction package: the *BRepPrimAPI_MakeCylinder* class. The information you must provide is:
 
   * the coordinate system where the cylinder will be located;
   * the radius and height.
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
     Standard_Real myNeckRadius = myThickness / 4.;
     Standard_Real myNeckHeight = myHeight / 10;
     BRepPrimAPI_MakeCylinder MKCylinder(neckAx2, myNeckRadius, myNeckHeight);
     TopoDS_Shape myNeck = MKCylinder.Shape();
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 You now have two separate parts: a main body and a neck that you need to fuse together.
 The *BRepAlgoAPI* package provides services to perform Boolean operations between shapes, and especially: *common* (Boolean intersection), *cut* (Boolean subtraction) and *fuse* (Boolean union).
 Use *BRepAlgoAPI_Fuse* to fuse the two shapes:
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
     myBody = BRepAlgoAPI_Fuse(myBody, myNeck);
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 
 @subsection OCCT_TUTORIAL_SUB3_4 Creating a Hollowed Solid
@@ -411,11 +411,11 @@ The challenging part in this procedure is to find the face to remove from your s
     
 To find the face with such characteristics, you will once again use an explorer to iterate on all the bottle's faces to find the appropriate one.
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
     for(TopExp_Explorer aFaceExplorer(myBody, TopAbs_FACE) ; aFaceExplorer.More() ; aFaceExplorer.Next()){
         TopoDS_Face aFace = TopoDS::Face(aFaceExplorer.Current());
     }
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 For each detected face, you need to access the geometric properties of the shape: use the *BRep_Tool* class for that. The most commonly used methods of this class are:
     
@@ -423,9 +423,9 @@ For each detected face, you need to access the geometric properties of the shape
   * *Curve* to access the 3D curve of an edge;
   * *Point* to access the 3D point of a vertex.
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
 Handle(Geom_Surface) aSurface = BRep_Tool::Surface(aFace);
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 As you can see, the *BRep_Tool::Surface* method returns an instance of the *Geom_Surface* class manipulated by handle. However, the *Geom_Surface* class does not provide information about the real type of the object *aSurface*, which could be an instance of *Geom_Plane*, *Geom_CylindricalSurface*, etc.
 All objects manipulated by handle, like *Geom_Surface*, inherit from the *Standard_Transient* class which provides two very useful methods concerning types:
@@ -436,52 +436,52 @@ All objects manipulated by handle, like *Geom_Surface*, inherit from the *Standa
 DynamicType returns the real type of the object, but you need to compare it with the existing known types to determine whether *aSurface* is a plane, a cylindrical surface or some other type.
 To compare a given type with the type you seek, use the *STANDARD_TYPE* macro, which returns the type of a class:
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
     if(aSurface->DynamicType() == STANDARD_TYPE(Geom_Plane)){
     //
     }
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 If this comparison is true, you know that the *aSurface* real type is *Geom_Plane*. You can then convert it from *Geom_Surface* to *Geom_Plane* by using the *DownCast()* method provided by each class inheriting *Standard_Transient*. As its name implies, this static method is used to downcast objects to a given type with the following syntax:
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
     Handle(Geom_Plane) aPlane = Handle(Geom_Plane)::DownCast(aSurface);
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 Remember that the goal of all these conversions is to find the highest face of the bottle lying on a plane. Suppose that you have these two global variables:
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
     TopoDS_Face faceToRemove;
     Standard_Real zMax = -1;
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 You can easily find the plane whose origin is the biggest in Z knowing that the location of the plane is given with the *Geom_Plane::Location* method. For example:
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
     gp_Pnt aPnt = aPlane->Location();
     Standard_Real aZ = aPnt.Z();
     if(aZ > zMax){
         zMax = aZ;
         faceToRemove = aFace;
     }
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 You have now found the top face of the neck. Your final step before creating the hollowed solid is to put this face in a list. Since more than one face can be removed from the initial solid, the *BRepOffsetAPI_MakeThickSolid* constructor takes a list of faces as arguments.
 Open CASCADE Technology provides many collections for different kinds of objects: see *TColGeom* package for collections of objects from *Geom* package, *TColgp* package for collections of objects from gp package, etc.
 The collection for shapes can be found in the *TopTools* package. As *BRepOffsetAPI_MakeThickSolid* requires a list, use the *TopTools_ListOfShape* class.
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
     TopTools_ListOfShape facesToRemove;
     facesToRemove.Append(faceToRemove);
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 All the necessary data are now available so you can create your hollowed solid by calling the *BRepOffsetAPI_MakeThickSolid* MakeThickSolidByJoin method:
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
     BRepOffsetAPI_MakeThickSolid BodyMaker;
     BodyMaker.MakeThickSolidByJoin(myBody, facesToRemove, -myThickness / 50, 1.e-3);
     myBody = BodyMaker.Shape();
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 
 @section sec4 Building the Threading
@@ -504,11 +504,11 @@ Using the same coordinate system *neckAx2* used to position the neck, you create
 
 Notice that one of the cylindrical surfaces is smaller than the neck. There is a good reason for this: after the thread creation, you will fuse it with the neck. So, we must make sure that the two shapes remain in contact.
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
     Handle(Geom_CylindricalSurface) aCyl1 = new Geom_CylindricalSurface(neckAx2, myNeckRadius * 0.99);
 
     Handle(Geom_CylindricalSurface) aCyl2 = new Geom_CylindricalSurface(neckAx2, myNeckRadius * 1.05);
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 
 @subsection OCCT_TUTORIAL_SUB4_2 Defining 2D Curves
@@ -564,11 +564,11 @@ To use 2D primitive geometry types of Open CASCADE Technology for defining a poi
   * To define a 2D direction (unit vector) from its X and Y coordinates, use the gp_Dir2d class. The coordinates will automatically be normalized.
   * To define a 2D right-handed coordinate system, use the *gp_Ax2d* class, which is computed from a point (origin of the coordinate system) and a direction - the X direction of the coordinate system. The Y direction will be automatically computed.
   
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
     gp_Pnt2d aPnt(2. * M_PI, myNeckHeight / 2.);
     gp_Dir2d aDir(2. * M_PI, myNeckHeight / 4.);
     gp_Ax2d anAx2d(aPnt, aDir);
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 You will now define the curves. As previously mentioned, these thread profiles are computed on two cylindrical surfaces. In the following figure, curves on the left define the base (on *aCyl1* surface) and the curves on the right define the top of the thread's shape (on *aCyl2* surface).
 
@@ -588,36 +588,36 @@ Supposing that:
 
 Your ellipses are defined as follows:
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
     Standard_Real aMajor = 2. * M_PI;
     Standard_Real aMinor = myNeckHeight / 10;
     Handle(Geom2d_Ellipse) anEllipse1 = new Geom2d_Ellipse(anAx2d, aMajor, aMinor);
     Handle(Geom2d_Ellipse) anEllipse2 = new Geom2d_Ellipse(anAx2d, aMajor, aMinor / 4);
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 To describe portions of curves for the arcs drawn above, you define *Geom2d_TrimmedCurve* trimmed curves out of the created ellipses and two parameters to limit them.
 As the parametric equation of an ellipse is P(U) = O + (MajorRadius * cos(U) * XDirection) + (MinorRadius * sin(U) * YDirection), the ellipses need to be limited between 0 and M_PI.
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
     Handle(Geom2d_TrimmedCurve) anArc1 = new Geom2d_TrimmedCurve(anEllipse1, 0, M_PI);
     Handle(Geom2d_TrimmedCurve) anArc2 = new Geom2d_TrimmedCurve(anEllipse2, 0, M_PI);
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 The last step consists in defining the segment, which is the same for the two profiles: a line limited by the first and the last point of one of the arcs.
 To access the point corresponding to the parameter of a curve or a surface, you use the Value or D0 method (meaning 0th derivative), D1 method is for first derivative, D2 for the second one.
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
     gp_Pnt2d anEllipsePnt1 = anEllipse1->Value(0);
     gp_Pnt2d anEllipsePnt2;
     anEllipse1->D0(M_PI, anEllipsePnt2);
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 When creating the bottle's profile, you used classes from the *GC* package, providing algorithms to create elementary geometries.
 In 2D geometry, this kind of algorithms is found in the *GCE2d* package. Class names and behaviors are similar to those in *GC*. For example, to create a 2D segment out of two points:
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
     Handle(Geom2d_TrimmedCurve) aSegment = GCE2d_MakeSegment(anEllipsePnt1, anEllipsePnt2);
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 
 @subsection OCCT_TUTORIAL_SUB4_3 Building Edges and Wires
@@ -637,28 +637,28 @@ Previously, you have built:
 
 To compute the edges out of these curves, once again use the *BRepBuilderAPI_MakeEdge* class. One of its constructors allows you to build an edge out of a curve described in the 2D parametric space of a surface.
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
     TopoDS_Edge anEdge1OnSurf1 = BRepBuilderAPI_MakeEdge(anArc1, aCyl1);
     TopoDS_Edge anEdge2OnSurf1 = BRepBuilderAPI_MakeEdge(aSegment, aCyl1);
     TopoDS_Edge anEdge1OnSurf2 = BRepBuilderAPI_MakeEdge(anArc2, aCyl2);
     TopoDS_Edge anEdge2OnSurf2 = BRepBuilderAPI_MakeEdge(aSegment, aCyl2);
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 Now, you can create the two profiles of the threading, lying on each surface.
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
     TopoDS_Wire threadingWire1 = BRepBuilderAPI_MakeWire(anEdge1OnSurf1, anEdge2OnSurf1);
     TopoDS_Wire threadingWire2 = BRepBuilderAPI_MakeWire(anEdge1OnSurf2, anEdge2OnSurf2);
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 Remember that these wires were built out of a surface and 2D curves.
 One important data item is missing as far as these wires are concerned: there is no information on the 3D curves. Fortunately, you do not need to compute this yourself, which can be a difficult task since the mathematics can be quite complex.
 When a shape contains all the necessary information except 3D curves, Open CASCADE Technology provides a tool to build them automatically. In the BRepLib tool package, you can use the *BuildCurves3d* method to compute 3D curves for all the edges of a shape.
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp} 
+~~~~{.cpp}
     BRepLib::BuildCurves3d(threadingWire1);
     BRepLib::BuildCurves3d(threadingWire2);
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 
 @subsection OCCT_TUTORIAL_SUB4_4 Creating Threading
@@ -675,12 +675,12 @@ The loft function is implemented in the *BRepOffsetAPI_ThruSections* class, whic
   * Use the *CheckCompatibility* method to activate (or deactivate) the option that checks whether the wires have the same number of edges. In this case, wires have two edges each, so you can deactivate this option.
   * Ask for the resulting loft shape with the Shape method.
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp} 
+~~~~{.cpp}
     BRepOffsetAPI_ThruSections aTool(Standard_True);
     aTool.AddWire(threadingWire1); aTool.AddWire(threadingWire2);
     aTool.CheckCompatibility(Standard_False);
     TopoDS_Shape myThreading = aTool.Shape();
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 
 @section sec5 Building the Resulting Compound
@@ -688,13 +688,13 @@ The loft function is implemented in the *BRepOffsetAPI_ThruSections* class, whic
 
 You are almost done building the bottle. Use the *TopoDS_Compound* and *BRep_Builder* classes to build single shape from *myBody* and *myThreading*:
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp} 
+~~~~{.cpp}
     TopoDS_Compound aRes;
     BRep_Builder aBuilder;
     aBuilder.MakeCompound (aRes);
     aBuilder.Add (aRes, myBody);
     aBuilder.Add (aRes, myThreading);
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 Congratulations! Your bottle is complete. Here is the result snapshot of the Tutorial application:
 
@@ -709,7 +709,7 @@ If you want to know more and develop major projects using Open CASCADE Technolog
 
 Complete definition of MakeBottle function (defined in the file src/MakeBottle.cxx of the Tutorial):
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp} 
+~~~~{.cpp}
     TopoDS_Shape MakeBottle(const Standard_Real myWidth, const Standard_Real myHeight,
                             const Standard_Real myThickness)
     {
@@ -846,5 +846,5 @@ Complete definition of MakeBottle function (defined in the file src/MakeBottle.c
 
         return aRes;
     }
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
index d41c636374f47efd897d7a51eab7c0ff2158210e..f80902056535ffc227deda5fc65b87e1a7707e01 100644 (file)
@@ -39,7 +39,7 @@ Porting of user applications from an earlier OCCT version to version 6.5 require
 Porting of user applications from an earlier OCCT version to version 6.5.1 requires taking into account the following major changes:
 
 *      Method *Graphic3d_Structure::Groups()* now returns *Graphic3d_SequenceOfGroup*. If this method has been used, the application code should be updated to iterate another collection type or, if *Graphic3d_HSetOfGroup* is required, to fill its own collection:
-~~~~
+~~~~{.cpp}
 const Graphic3d_SequenceOfGroup& aGroupsSeq = theStructure.Groups();
 Handle(Graphic3d_HSetOfGroup) aGroupSet = new Graphic3d_HSetOfGroup();
 Standard_Integer aLen = aGroupsSeq.Length();
@@ -62,7 +62,7 @@ Porting of user applications from an earlier OCCT version to version 6.5.2 requi
 * If the callback mechanism in call_togl_redraw function was used in the application code, it is necessary to revise it to take into account the new callback execution and provide a check of reason value of Aspect_GraphicCallbackStruct in callback methods to confirm that the callback code is executed at the right moment. Now the callbacks are executed before redrawing the underlayer, before redrawing the overlayer and at the end of redrawing. The information about the moment when the callback is invoked is provided with the reason value in form of an additional bit flag <i>(OCC_PRE_REDRAW, OCC_PRE_OVERLAY)</i>. The state of OpenGl changed in callback methods will not be restored automatically, which might lead to unwanted behavior in redrawing procedure.
 * The print method used in the application code might need to be revised to take into account the ability to choose between print algorithms: tile and stretch. The stretch algorithm will be selected by default during porting.
 * It is recommended to *BRepMesh_DiscretFactory* users, to check *BRepMesh_DiscretFactory::SetDefault()* return value to determine plugin availability / validity. *BRepMesh_DiscretFactory::Discret()* method now returns handle instead of pointer. The code should be updated in the following manner:
-~~~~
+~~~~{.cpp}
 Handle(BRepMesh_DiscretRoot) aMeshAlgo = BRepMesh_DiscretFactory::Get().Discret (theShape, theDeflection, theAngularToler);
  if (!aMeshAlgo.IsNull())  {}
 ~~~~
@@ -88,7 +88,7 @@ Porting of user applications from an earlier OCCT version to version 6.5.3 requi
 
 Porting of user applications from an earlier OCCT version to version 6.5.4 requires taking into account the following major changes:
 * The code using obsolete classes *Aspect_PixMap, Xw_PixMap* and *WNT_PixMap* should be rewritten implementing class *Image_PixMap*, which is now retrieved by *ToPixMap* methods as argument. A sample code using *ToPixMap* is given below:
-~~~~
+~~~~{.cpp}
 #include <Image_AlienPixMap.hxx>
 void dump (Handle(V3d_View)& theView3D)
 {
@@ -121,7 +121,7 @@ Correspondingly, the code using methods *SetAnimationModeOn(), SetAnimationModeO
    * Interactive selection of 2D presentations should be set up inside *ComputeSelection()* virtual method of a custom interactive object class, using standard sensitive entities from *Select3D* package and standard or custom entity owners derived from *SelectMgr_EntityOwner* base.
 Refer to the Visualization User's Guide for further details concerning OCCT 3D visualization and selection classes. See also *Viewer2D* OCCT sample application, which shows how 2D drawing can be implemented using TKV3d API.
 * Run-time graphic driver library loading mechanism based on *CSF_GraphicShr* environment variable usage has been replaced by explicit linking against *TKOpenGl* library. The code sample below shows how the graphic driver should be created and initialized in the application code: 
-~~~~
+~~~~{.cpp}
 // initialize a new viewer with OpenGl graphic driver
 Handle(Graphic3d_GraphicDriver) aGraphicDriver = 
 new OpenGl_GraphicDriver ("TKOpenGl");
@@ -264,7 +264,7 @@ Custom Interactive Objects should implement new virtual method *SelectMgr_Select
 
 Now the method *SelectMgr_Selection::Sensitive()* does not return *SelectBasics_SensitiveEntity*. It returns an instance of *SelectMgr_SensitiveEntity*, which belongs to a different class hierarchy (thus *DownCast()* will fail). To access base sensitive it is necessary to use method *SelectMgr_SensitiveEntity::BaseSensitive()*. For example:
 
-~~~~
+~~~~{.cpp}
 Handle(SelectMgr_Selection) aSelection = anInteractiveObject->Selection (aMode);
 for (aSelection->Init(); aSelection->More(); aSelection->Next())
 {
@@ -286,7 +286,7 @@ The depth and distance to the center of geometry must be calculated for the 3D p
 
 Here is an example of overlap/inclusion test for a box:
 
-~~~~
+~~~~{.cpp}
 if (!theMgr.IsOverlapAllowed()) // check for inclusion
 {
   Standard_Boolean isInside = Standard_True;
@@ -404,26 +404,26 @@ Most of typical changes required for upgrading code for OCCT 7.0 can be done aut
 This tool is a Tcl script, thus Tcl should be available on your workstation to run it.
 
 Example:
-~~~~~
+~~~~{.php}
  $ tclsh
  % source <path_to_occt>/adm/upgrade.tcl
  % upgrade -recurse -all -src=<path_to_your_sources>
-~~~~~
+~~~~
 
 On Windows, the helper batch script *upgrade.bat* can be used, provided that Tcl is either available in *PATH*, or configured via *custom.bat* script (for instance, if you use OCCT installed from Windows installer package). Start it from the command prompt:
 
-~~~~~
+~~~~
 cmd> <path_to_occt>\upgrade.bat -recurse -all -inc=<path_to_occt>\inc -src=<path_to_your_sources> [options]
-~~~~~
+~~~~
 
 Run the upgrade tool without arguments to see the list of available options.
 
 The upgrade tool performs the following changes in the code.
 
 1. Replaces macro *DEFINE_STANDARD_RTTI* by *DEFINE_STANDARD_RTTIEXT*, with second argument indicating base class for the main argument class (if inheritance is recognized by the script):
-~~~~~
+~~~~{.cpp}
 DEFINE_STANDARD_RTTI(Class) -> DEFINE_STANDARD_RTTIEXT(Class, Base)
-~~~~~
+~~~~
 
    @note If macro *DEFINE_STANDARD_RTTI* with two arguments (used in intermediate development versions of OCCT 7.0) is found, the script will convert it to either *DEFINE_STANDARD_RTTIEXT* or *DEFINE_STANDARD_RTTI_INLINE*. 
    The former case is used if current file is header and source file with the same name is found in the same folder. 
@@ -431,50 +431,50 @@ DEFINE_STANDARD_RTTI(Class) -> DEFINE_STANDARD_RTTIEXT(Class, Base)
    The latter variant defines all methods for RTTI as inline, and does not require *IMPLEMENT_STANDARD_RTTIEXT* macro. 
 
 2. Replaces forward declarations of collection classes previously generated from CDL generics (defined in *TCollection* package) by inclusion of the corresponding header:
-~~~~~
+~~~~{.cpp}
 class TColStd_Array1OfReal; -> #include <TColStd_Array1OfReal.hxx>
-~~~~~
+~~~~
 
 3. Replaces underscored names of *Handle* classes by usage of a macro:
-~~~~~
+~~~~{.cpp}
 Handle_Class -> Handle(Class)
-~~~~~
+~~~~
   This change is not applied if the source or header file is recognized as containing the definition of Qt class with signals or slots, to avoid possible compilation errors of MOC files caused by inability of MOC to recognize macros (see https://doc.qt.io/qt-4.8/signalsandslots.html).
   The file is considered as defining a Qt object if it contains strings *Q_OBJECT* and either *slots:* or *signals:*. 
 
 4. Removes forward declarations of classes with names <i>Handle(C)</i> or *Handle_C*, replacing them either by forward declaration of its argument class, or (for files defining Qt objects) <i>\#include</i> statement for a header with the name of the argument class and extension .hxx:
-~~~~~
+~~~~{.cpp}
 class Handle(TColStd_HArray1OfReal); -> #include <TColStd_HArray1OfReal.hxx>
-~~~~~
+~~~~
 
 5. Removes <i> \#includes </i> of files <i>Handle_...hxx</i> that have disappeared in OCCT 7.0:
-~~~~~
+~~~~{.cpp}
 #include <Handle_Geom_Curve.hxx> ->
-~~~~~
+~~~~
 
 6. Removes *typedef* statements that use *Handle* macro to generate the name:
-~~~~~
+~~~~{.cpp}
 typedef NCollection_Handle<Message_Msg> Handle(Message_Msg); ->
-~~~~~
+~~~~
 
 7. Converts C-style casts applied to Handles into calls to <i>DownCast()</i> method:
-~~~~~
+~~~~{.cpp}
     ((Handle(A)&)b)     -> Handle(A)::DownCast(b)
     (Handle(A)&)b       -> Handle(A)::DownCast(b)
     (*((Handle(A)*)&b)) -> Handle(A)::DownCast(b)
     *((Handle(A)*)&b)   -> Handle(A)::DownCast(b)
     (*(Handle(A)*)&b)   -> Handle(A)::DownCast(b)
-~~~~~
+~~~~
 
 8. Moves <i>Handle()</i> macro out of namespace scope:
-~~~~~
+~~~~{.cpp}
 Namespace::Handle(Class) -> Handle(Namespace::Class)
-~~~~~
+~~~~
 
 9. Converts local variables of reference type, which are initialized by a temporary object returned by call to <i>DownCast()</i>, to the variables of non-reference type (to avoid using references to destroyed memory):
-~~~~~
+~~~~{.cpp}
     const Handle(A)& a = Handle(B)::DownCast (b); -> Handle(A) a (Handle(B)::DownCast (b));
-~~~~~
+~~~~
 
 10. Adds  <i>\#include</i> for all classes used as argument to macro <i>STANDARD_TYPE()</i>, except for already included ones;
 
@@ -487,9 +487,9 @@ Namespace::Handle(Class) -> Handle(Namespace::Class)
 As long as the upgrade routine runs, some information messages are sent to the standard output. 
 In some cases the warnings or errors like the following may appear:
 
-~~~~~
+~~~~
   Error in {HEADER_FILE}: Macro DEFINE_STANDARD_RTTI used for class {CLASS_NAME} whose declaration is not found in this file, cannot fix
-~~~~~
+~~~~
 
 Be sure to check carefully all reported errors and warnings, as the corresponding code will likely require manual corrections.
 In some cases these messages may help you to detect errors in your code, for instance, cases where *DEFINE_STANDARD_RTTI* macro is used with incorrect class name as an argument.
@@ -506,12 +506,12 @@ The use of handle objects (construction, comparison using operators == or !=, us
 
 For example, the following lines will fail to compile if *Geom_Line.hxx* is not included:
 
-~~~~~
+~~~~{.cpp}
 Handle(Geom_Line) aLine = 0;
 if (aLine != aCurve) {...} 
 if (aCurve->IsKind(STANDARD_TYPE(Geom_Line)) {...}
 aLine = Handle(Geom_Line)::DownCast (aCurve);
-~~~~~
+~~~~
 
 Note that it is not necessary to include header of the class to declare Handle to it.
 However, if you define a class *B* that uses Handle(*A*) in its fields, or contains a method returning Handle(*A*), it is advisable to have header defining *A* included in the header of *B*.
@@ -523,31 +523,31 @@ This issue appears in the compilers that do not support default arguments in tem
 The problem is that operator  <i> const handle<T2>& </i> is defined for any type *T2*, thus the compiler cannot make the right choice.
 
 Example:
-~~~~~
+~~~~{.cpp}
 void func (const Handle(Geom_Curve)&);
 void func (const Handle(Geom_Surface)&);
 
 Handle(Geom_TrimmedCurve) aCurve = new Geom_TrimmedCurve (...);
 func (aCurve); // ambiguity error in VC++ 10
-~~~~~
+~~~~
 
 Note that this problem can be avoided in many cases if macro *OCCT_HANDLE_NOCAST* is used, see @ref upgrade_occt700_cdl_nocast "below".
 
 To resolve this ambiguity, change your code so that argument type should correspond exactly to the function signature. 
 In some cases this can be done by using the relevant type for the corresponding variable, like in the example above:
 
-~~~~~
+~~~~{.cpp}
 Handle(Geom_Curve) aCurve = new Geom_TrimmedCurve (...);  
-~~~~~
+~~~~
 
 Other variants consist in assigning the argument to a local variable of the correct type and using the direct cast or constructor:
 
-~~~~~
+~~~~{.cpp}
 const Handle(Geom_Curve)& aGCurve (aTrimmedCurve);
 func (aGCurve); // OK - argument has exact type
 func (static_cast(aCurve)); // OK - direct cast 
 func (Handle(Geom_Curve)(aCurve)); // OK - temporary handle is constructed
-~~~~~
+~~~~
 
 Another possibility consists in defining additional template variant of the overloaded function causing ambiguity, and using *SFINAE* to resolve the ambiguity.
 This technique can be illustrated by the definition of the template variant of method <i>IGESData_IGESWriter::Send()</i>.
@@ -558,31 +558,31 @@ As the cast of a handle to the reference to another handle to the base type has
 
 For example:
 
-~~~~~
+~~~~{.cpp}
 Handle(Geom_Geometry) aC = GC_MakeLine (p, v); // compiler error
-~~~~~
+~~~~
 
 The problem is that the class *GC_MakeLine* has a user-defined conversion to <i>const Handle(Geom_TrimmedCurve)&,</i> which is not the same as the type of the local variable *aC*.
 
 To resolve this, use method <i>Value()</i>:
 
-~~~~~
+~~~~{.cpp}
 Handle(Geom_Geometry) aC = GC_MakeLine (p, v).Value(); // ok
-~~~~~
+~~~~
 
 or use variable of the appropriate type:
 
-~~~~~
+~~~~{.cpp}
 Handle(Geom_TrimmedCurve) aC = GC_MakeLine (p, v); // ok
-~~~~~
+~~~~
 
 A similar problem appears with GCC compiler, when *const* handle to derived type is used to construct handle to base type via assignment (and in some cases in return statement), for instance:
 
-~~~~~
+~~~~{.cpp}
   const Handle(Geom_Line) aLine;
   Handle(Geom_Curve) c1 = aLine; // GCC error 
   Handle(Geom_Curve) c2 (aLine); // ok
-~~~~~
+~~~~
 
 This problem is specific to GCC and it does not appear if macro *OCCT_HANDLE_NOCAST* is used, see @ref upgrade_occt700_cdl_nocast "below".
 
@@ -593,20 +593,20 @@ You might need to clean your code from incorrect use of macros *STANDARD_TYPE*()
 1. Explicit definitions of static functions with names generated by macro *STANDARD_TYPE()*, which are artifacts of old implementation of RTTI, should be removed.
    
    Example:
-~~~~~
+~~~~{.cpp}
 const Handle(Standard_Type)& STANDARD_TYPE(math_GlobOptMin)
 {
   static Handle(Standard_Type) _atype = new Standard_Type ("math_GlobOptMin", sizeof (math_GlobOptMin));
   return _atype;
 }
-~~~~~
+~~~~
 
 2. Incorrect location of closing parenthesis of *Handle()* macro that was not detectable in OCCT 6.x will cause a compiler error and must be corrected.
 
    Example (note misplaced closing parenthesis):
-~~~~~
+~~~~{.cpp}
 aBSpline = Handle( Geom2d_BSplineCurve::DownCast(BS->Copy()) );
-~~~~~
+~~~~
 
 #### Use of class Standard_AncestorIterator
 
@@ -617,20 +617,20 @@ Class *Standard_AncestorIterator* has been removed; use method *Parent()* of *St
 Handles in OCCT 7.0 do not have the operator of conversion to <i>Standard_Transient*,</i> which was present in earlier versions.
 This is done to prevent possible unintended errors like this:
 
-~~~~~
+~~~~{.cpp}
 Handle(Geom_Line) aLine = ...;
 Handle(Geom_Surface) aSurf = ...;
 ...
 if (aLine == aSurf) {...} // will cause a compiler error in OCCT 7.0, but not OCCT 6.x
-~~~~~
+~~~~
 
 The places where this implicit cast has been used should be corrected manually.
 The typical situation is when Handle is passed to stream:
 
-~~~~~
+~~~~{.cpp}
 Handle(Geom_Line) aLine = ...;
 os << aLine; // in OCCT 6.9.0, resolves to operator << (void*) 
-~~~~~
+~~~~
 
 Call method <i>get()</i> explicitly to output the address of the Handle.
 
@@ -639,24 +639,24 @@ Call method <i>get()</i> explicitly to output the address of the Handle.
 Method *DownCast()* in OCCT 7.0 is made templated; if its argument is not a base class, "deprecated" compiler warning is generated.
 This is done to prevent possible unintended errors like this:
 
-~~~~~
+~~~~{.cpp}
 Handle(Geom_Surface) aSurf = ;
 Handle(Geom_Line) aLine = 
   Handle(Geom_Line)::DownCast (aSurf); // will cause a compiler warning in OCCT 7.0, but not OCCT 6.x
-~~~~~
+~~~~
 
 The places where this cast has been used should be corrected manually.
 
 If down casting is used in a template context where the argument can have the same or unrelated type so that *DownCast()* may be not available in all cases, use C++ *dynamic_cast<>* instead, e.g.: 
 
-~~~~~
+~~~~{.cpp}
 template <class T>
 bool CheckLine (const Handle(T) theArg)
 {
   Handle(Geom_Line) aLine = dynamic_cast<Geom_Line> (theArg.get());
   ...
 }
-~~~~~
+~~~~
 
 @subsubsection upgrade_occt700_cdl_runtime Possible runtime problems
 
@@ -671,19 +671,19 @@ This problem does not appear if macro *OCCT_HANDLE_NOCAST* is used during compil
 
 Example:
 
-~~~~~
+~~~~{.cpp}
 // note that DownCast() returns new temporary object!
 const Handle(Geom_BoundedCurve)& aBC =
 Handle(Geom_TrimmedCurve)::DownCast(aCurve);
 aBC->Transform (T); // access violation in OCCT 7.0
-~~~~~
+~~~~
 
 @subsubsection upgrade_occt700_cdl_nocast Option to avoid cast of handle to reference to base type
 
 In OCCT 6.x and earlier versions the handle classes formed a hierarchy echoing the hierarchy of the corresponding object classes .
 This automatically enabled the possibility to use the handle to a derived class in all contexts where the handle to a base class was needed, e.g. to pass it in a function by reference without copying:
 
-~~~~
+~~~~{.cpp}
 Standard_Boolean GetCurve (Handle(Geom_Curve)& theCurve);
 ....
 Handle(Geom_Line) aLine;
@@ -705,13 +705,13 @@ This implies creation of temporary objects and hence may be more expensive at ru
 The code that relies on the possibility of casting to base should be amended to always use the handle of argument type in function call and to use *DownCast()* to safely convert the result to the desired type.
 For instance, the code from the example below can be changed as follows:
 
-~~~~~
+~~~~{.cpp}
 Handle(Geom_Line) aLine;
 Handle(Geom_Curve) aCurve;
 if (GetCurve (aCure) && !(aLine = Handle(Geom_Line)::DownCast (aCurve)).IsNull()) {
   // use aLine safely
 }
-~~~~~
+~~~~
 
 @subsubsection upgrade_occt700_cdl_compat Preserving compatibility with OCCT 6.x
 
@@ -724,12 +724,12 @@ If you like to preserve the compatibility of your application code with OCCT ver
 3. Define macros *DEFINE_STANDARD_RTTIEXT* and *DEFINE_STANDARD_RTTI_INLINE* when building with previous versions of OCCT, resolving to *DEFINE_STANDARD_RTTI* with single argument 
 
    Example:
-~~~~~   
+~~~~{.cpp}
 #if OCC_VERSION_HEX < 0x070000
   #define DEFINE_STANDARD_RTTIEXT(C1,C2) DEFINE_STANDARD_RTTI(C1)
   #define DEFINE_STANDARD_RTTI_INLINE(C1,C2) DEFINE_STANDARD_RTTI(C1)
 #endif
-~~~~~
+~~~~
 
 @subsubsection upgrade_occt700_cdl_wok Applications based on CDL and WOK
 
@@ -768,7 +768,7 @@ The code that used the tools provided by that package should be corrected manual
 The recommended approach is to use sorting algorithms provided by STL.
 
 For instance:
-~~~~~
+~~~~{.cpp}
 #include <SortTools_StraightInsertionSortOfReal.hxx>
 #include <SortTools_ShellSortOfReal.hxx>
 #include <TCollection_CompareOfReal.hxx>
@@ -777,15 +777,15 @@ TCollection_Array1OfReal aValues = ...;
 ...
 TCollection_CompareOfReal aCompReal;
 SortTools_StraightInsertionSortOfReal::Sort(aValues, aCompReal);
-~~~~~
+~~~~
 can be replaced by:
-~~~~~
+~~~~{.cpp}
 #include <algorithm>
 ...
 TCollection_Array1OfReal aValues = ...;
 ...
 std::stable_sort (aValues.begin(), aValues.end());
-~~~~~
+~~~~
 
 @subsection upgrade_occt700_2dlayers On-screen objects and ColorScale
 
@@ -802,7 +802,7 @@ Predefined Z-layers *Graphic3d_ZLayerId_TopOSD* and *Graphic3d_ZLayerId_BotOSD*
 The property of *V3d_View* storing the global *ColorScale* object has been removed with associated methods *V3d_View::ColorScaleDisplay(), V3d_View::ColorScaleErase(), V3d_View::ColorScaleIsDisplayed()* and *V3d_View::ColorScale()* as well as the classes *V3d_ColorScale, V3d_ColorScaleLayerItem* and *Aspect_ColorScale*.
 Here is an example of creating *ColorScale* using the updated API:
 
-~~~~~
+~~~~{.cpp}
 Handle(AIS_ColorScale) aCS = new AIS_ColorScale();
 // configuring
 Standard_Integer aWidth, aHeight;
@@ -815,13 +815,13 @@ aCS->SetZLayer (Graphic3d_ZLayerId_TopOSD);
 aCS->SetTransformPersistence (Graphic3d_TMF_2d, gp_Pnt (-1,-1,0));
 aCS->SetToUpdate();
 theContextAIS->Display (aCS);
-~~~~~
+~~~~
 
 To see how 2d objects are implemented in OCCT you can call Draw commands *vcolorscale, vlayerline* or *vdrawtext* (with <i>-2d</i> option).
 Draw command *vcolorscale* now requires the name of *ColorScale* object as argument.
 To display this object use command *vdisplay*. For example:
 
-~~~~~
+~~~~{.php}
 pload VISUALIZATION
 vinit
 vcolorscale cs -demo
@@ -832,16 +832,16 @@ vsetdispmode 1
 vfit
 vlayerline 0 300 300 300 10
 vdrawtext t "2D-TEXT" -2d -pos 0 150 0 -color red
-~~~~~
+~~~~
 
 Here is a small example in C++ illustrating how to display a custom AIS object in 2d:
-~~~~~
+~~~~{.cpp}
 Handle(AIS_InteractiveContext) aContext = ...;
 Handle(AIS_InteractiveObject) anObj =...; // create an AIS object
 anObj->SetZLayer(Graphic3d_ZLayerId_TopOSD); // display object in overlay
 anObj->SetTransformPersistence (Graphic3d_TMF_2d, gp_Pnt (-1,-1,0)); // set 2d flag, coordinate origin is set to down-left corner
 aContext->Display (anObj); // display the object
-~~~~~
+~~~~
 
 @subsection upgrade_occt700_userdraw UserDraw and Visual3d
 
@@ -879,7 +879,7 @@ The functionality previously provided by *Visual3d* package has been redesigned
 Old APIs based on global callback functions for creating *UserDraw* objects and for performing custom OpenGL rendering within the view have been dropped.
 *UserDraw* callbacks are no more required since *OpenGl_Group* now inherits *Graphic3d_Group* and thus can be accessed directly from *AIS_InteractiveObject*:
 
-~~~~~
+~~~~{.cpp}
 //! Class implementing custom OpenGL element.
 class UserDrawElement : public OpenGl_Element {};
 
@@ -901,12 +901,12 @@ void UserDrawObject::Compute (const Handle(PrsMgr_PresentationManager)& thePrsMg
   // invalidate bounding box of the scene
   thePrsMgr->StructureManager()->Update();
 }
-~~~~~
+~~~~
 
 To perform a custom OpenGL code within the view, it is necessary to inherit from class *OpenGl_View*.
 See the following code sample:
 
-~~~~~
+~~~~{.cpp}
 //! Custom view.
 class UserView : public OpenGl_View
 {
@@ -953,7 +953,7 @@ public:
   }
 };
 
-~~~~~
+~~~~
 
 @subsection upgrade_occt700_localcontext Deprecation of Local Context
 
@@ -1172,22 +1172,22 @@ Class *BRepOffsetAPI_MakeOffsetShape*:
 * *BRepOffsetAPI_MakeOffsetShape::PerformByJoin()* - method has been added. This method is old algorithm behaviour. 
 
 The code below shows new calling procedure:
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
     BRepOffsetAPI_MakeOffsetShape OffsetMaker;
     OffsetMaker.PerformByJoin(Shape, OffsetValue, Tolerance);
     NewShape = OffsetMaker.Shape();
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 Class *BRepOffsetAPI_MakeThickSolid*:
 * *BRepOffsetAPI_MakeThickSolid::BRepOffsetAPI_MakeThickSolid()* - constructor with parameters has been deleted.
 * *BRepOffsetAPI_MakeThickSolid::MakeThickSolidByJoin()* - method has been added. This method is old algorithm behaviour. 
 
 The code below shows new calling procedure:
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
     BRepOffsetAPI_MakeThickSolid BodyMaker;
     BodyMaker.MakeThickSolidByJoin(myBody, facesToRemove, -myThickness / 50, 1.e-3);
     myBody = BodyMaker.Shape();
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 @subsection upgrade_720_highlight Highlight style
 
@@ -1317,7 +1317,7 @@ One can use this functionality in two ways:
 
 The code example below demonstrates how to read shapes from a storage driver using *StdStorage* class.
 
-~~~~
+~~~~{.cpp}
 // aDriver should be created and opened for reading
 Handle(StdStorage_Data) aData;
 
@@ -1355,7 +1355,7 @@ if (!aRoots.IsNull())
 
 The following code demonstrates how to write shapes in OCCT 7.2.0 using *StdStorage* class.
 
-~~~~
+~~~~{.cpp}
 // Create a file driver
 NCollection_Handle<Storage_BaseDriver> aFileDriver(new FSD_File());
 
@@ -1640,7 +1640,7 @@ The following changes have been introduced in the API of *BRepMesh_IncrementalMe
 
 Example of usage:
 Case 1 (explicit parameters):
-~~~~
+~~~~{.cpp}
 #include <IMeshData_Status.hxx>
 #include <IMeshTools_Parameters.hxx>
 #include <BRepMesh_IncrementalMesh.hxx>
@@ -1688,7 +1688,7 @@ In fact, drawing points or lines with lighting applied is a valid use case, but
 As aspects for different primitive types have been merged, Graphic3d_Group does no more provide per-type aspect properties.
 Existing code relying on old behavior and putting interleaved per-type aspects into single Graphic3d_Group should be updated.
 For example, the following pseudo-code will not work anymore, because all *SetGroupPrimitivesAspect* calls will setup the same property:
-~~~~
+~~~~{.cpp}
 Handle(Graphic3d_Group) aGroup = thePrs->NewGroup();
 aGroup->SetGroupPrimitivesAspect (myDrawer->ShadingAspect()->Aspect());
 aGroup->SetGroupPrimitivesAspect (myDrawer->LineAspect()->Aspect());    //!< overrides previous aspect
@@ -1700,7 +1700,7 @@ aGroup->AddPrimitiveArray (aTris);
 ~~~~
 
 To solve the problem, the code should be modified to either put primitives into dedicated groups (preferred approach), or using *SetPrimitivesAspect* in proper order:
-~~~~
+~~~~{.cpp}
 Handle(Graphic3d_Group) aGroup = thePrs->NewGroup();
 
 aGroup->SetGroupPrimitivesAspect (myDrawer->ShadingAspect()->Aspect());
@@ -1718,7 +1718,7 @@ Decomposition of Ambient, Diffuse, Specular and Emissive properties has been eli
 As result, the following methods of *Graphic3d_MaterialAspect* class have been removed: SetReflectionMode(), SetReflectionModeOn(), Ambient(), Diffuse(), Emissive(), Specular(), SetAmbient(), SetDiffuse(), SetSpecular(), SetEmissive().
 
 Previously, computation of final value required the following code:
-~~~~
+~~~~{.cpp}
 Graphic3d_MaterialAspect theMaterial; Quantity_Color theInteriorColor;
 Graphic3d_Vec3 anAmbient (0.0f);
 if (theMaterial.ReflectionMode (Graphic3d_TOR_AMBIENT))
@@ -1730,7 +1730,7 @@ if (theMaterial.ReflectionMode (Graphic3d_TOR_AMBIENT))
 ~~~~
 
 New code looks like this:
-~~~~
+~~~~{.cpp}
 Graphic3d_MaterialAspect theMaterial; Quantity_Color theInteriorColor;
 Graphic3d_Vec3 anAmbient = theMaterial.AmbientColor();
 if (theMaterial.MaterialType (Graphic3d_MATERIAL_ASPECT)) { anAmbient *= (Graphic3d_Vec3 )theInteriorColor; }
@@ -1751,7 +1751,7 @@ Existing code should be updated to:
 Parameters of *Text* in *Graphic3d_Group* are moved into a new *Graphic3d_Text* class. *AddText* of *Graphic3d_Group* should be used instead of the previous *Text*.
 
 The previous code:
-~~~~
+~~~~{.cpp}
 Standard_Real x, y, z;
 theAttachmentPoint.Coord(x,y,z);
 theGroup->Text (theText,
@@ -1763,7 +1763,7 @@ theGroup->Text (theText,
                 theAspect->VerticalJustification());
 ~~~~
 should be replaced by the new code:
-~~~~
+~~~~{.cpp}
 Handle(Graphic3d_Text) aText = new Graphic3d_Text (theAspect->Height());
 aText->SetText (theText.ToExtString());
 aText->SetPosition (theAttachmentPoint);
@@ -1927,7 +1927,7 @@ The method Select3D_SensitiveEntity::NbSubElements() has been changed to be cons
 @subsection upgrade_750_Booleans Changes in Boolean operations algorithm
 
 * TreatCompound method has been moved from *BOPAlgo_Tools* to *BOPTools_AlgoTools*. Additionally, the map parameter became optional:
-~~~~
+~~~~{.cpp}
 void BOPTools_AlgoTools::TreatCompound (const TopoDS_Shape& theS,
                                         TopTools_ListOfShape& theLS,
                                         TopTools_MapOfShape* theMap = NULL);
@@ -2094,25 +2094,25 @@ corresponding type of the message.
 The code that used operator << for messenger, should be ported as follows.
 
 Before the change:
-~~~~~
+~~~~{.cpp}
   Handle(Message_Messenger) theMessenger = ...;
   theMessenger << "Value = " << anInteger << Message_EndLine;
-~~~~~
+~~~~
 
 After the change, single-line variant:
-~~~~~
+~~~~{.cpp}
   Handle(Message_Messenger) theMessenger = ...;
   theMessenger->SendInfo() << "Value = " << anInteger << std::endl;
-~~~~~
+~~~~
 
 After the change, extended variant:
-~~~~~
+~~~~{.cpp}
   Handle(Message_Messenger) theMessenger = ...;
   Message_Messenger::StreamBuffer aSender = theMessenger->SendInfo();
   aSender << "Array: [ ";
   for (int i = 0; i < aNb; ++i) { aSender << anArray[i] << " "; }
   aSender << "]" << std::endl; // aSender can be used further for other messages
-~~~~~
+~~~~
 
 @subsection upgrade_750_message_printer Message_Printer interface change
 
@@ -2136,13 +2136,13 @@ provided that each thread deals with its own instance of *TDataStd_Application*
 Note that neither *TDataStd_Application* nor *TDocStd_Document* is protected from concurrent access from several threads.
 Such protection, if necessary, shall be implemented on the application level.
 For an example, access to labels and attributes could be protected by mutex if there is a probability that different threads access the same labels / attributes:
-~~~~~
+~~~~{.cpp}
   {
     Standard_Mutex::Sentry aSentry (myMainLabelAccess);
     TDF_Label aChildLab = aDocument->Main().NewChild();
     TDataStd_Integer::Set(aChildLab, 0);
   }
-~~~~~
+~~~~
 
 @subsection upgrade_750_draw_hotkeys Draw Harness hotkeys
 
@@ -2179,10 +2179,10 @@ Existing code relying on old behavior, if any, shall be rewritten.
 
 Geom_RectangularTrimmedSurface sequentially trimming in U and V directions already no longer loses the first trim.
 For example:
-~~~~~
+~~~~{.cpp}
   Handle(Geom_RectangularTrimmedSurface) ST  = new Geom_RectangularTrimmedSurface (Sbase, u1, u2, Standard_True); // trim along U
   Handle(Geom_RectangularTrimmedSurface) ST1 = new Geom_RectangularTrimmedSurface (ST, v1, v2, Standard_False); // trim along V
-~~~~~
+~~~~
 gives different result.
 In current version ST1 - surface trimmed only along V, U trim is removed;
 After modification ST1 - surface trimmed along U and V, U trim is kept.
index ccc6625139e330f57e4b62192d450c2ee0ff743e..b10b73dc1d4ed9bf906197ac108d4302e90215a4 100644 (file)
@@ -50,18 +50,18 @@ This documentation describes:
 
 This document is a reference manual. It contains a full description of each command. All descriptions have the format illustrated below for the exit command. 
 
-~~~~~
+~~~~{.php}
 exit
-~~~~~
+~~~~
 
 Terminates the Draw, TCL session. If the commands are read from a file using the source command, this will terminate the file. 
 
 **Example:** 
 
-~~~~~
+~~~~{.php}
 # this is a very short example 
 exit 
-~~~~~
+~~~~
 
 
 @subsection occt_draw_1_3 Getting started
@@ -86,38 +86,38 @@ The format of the file is compliant with standard Open CASCADE Technology resour
 Each key defines a sequence of either further (nested) keys or a name of the dynamic library. Keys can be nested down to an arbitrary level. However, cyclic dependencies between the keys are not checked. 
 
 **Example:** (excerpt from DrawPlugin): 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~
 OCAF               : VISUALIZATION, OCAFKERNEL 
 VISUALIZATION      : AISV 
 OCAFKERNEL         : DCAF 
 
 DCAF               : TKDCAF 
 AISV               : TKViewerTest 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 @subsubsection occt_draw_1_3_3 Activation of commands implemented in the plug-in
 
 To load a plug-in declared in the resource file and to activate the commands the following command must be used in Test Harness: 
 
-~~~~~
+~~~~{.php}
 pload [-PluginFileName] [[Key1] [Key2]...]
-~~~~~
+~~~~
 
-where: 
+Where: 
 
 * <i>-PluginFileName</i> -- defines the name of a plug-in resource file (prefix "-" is mandatory) described above. If this parameter is omitted then the default name *DrawPlugin* is used. 
 * *Key* -- defines the key(s) enumerating plug-ins to be loaded. If no keys are specified then the key named *DEFAULT* is used (if there is no such key in the file then no plug-ins are loaded). 
 
 According to the OCCT resource file management rules, to access the resource file the environment variable *CSF_PluginFileNameDefaults* (and optionally *CSF_PluginFileNameUserDefaults*) must be set and point to the directory storing the resource file. If it is omitted then the plug-in resource file will be searched in the <i>$CASROOT/src/DrawResources</i> directory. 
 
-~~~~~
+~~~~{.php}
 Draw[]        pload -DrawPlugin OCAF 
-~~~~~
+~~~~
 This command will search the resource file *DrawPlugin* using variable *CSF_DrawPluginDefaults* (and *CSF_DrawPluginUserDefaults*) and will start with the OCAF key. Since the *DrawPlugin* is the file shipped with Open CASCADE Technology it will be found in the <i>$CASROOT/src/DrawResources</i> directory (unless this location is redefined by user's variables). The OCAF key will be recursively extracted into two toolkits/plug-ins: *TKDCAF* and *TKViewerTest* (e.g. on Windows they correspond to *TKDCAF.dll* and *TKViewerTest.dll*). Thus, commands implemented for Visualization and OCAF will be loaded and activated in Test Harness. 
 
-~~~~~
+~~~~{.php}
 Draw[]        pload (equivalent to pload -DrawPlugin DEFAULT). 
-~~~~~
+~~~~
 This command will find the default DrawPlugin file and the DEFAULT key. The latter finally maps to the TKTopTest toolkit which implements basic modeling commands. 
 
 
@@ -140,11 +140,11 @@ TCL is an interpreted command language, not a structured language like C, Pascal
 
 The basic program for TCL is a script. A script consists of one or more commands. Commands are separated by new lines or semicolons. 
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.php}
 set a 24 
 set b 15 
 set a 25; set b 15 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 Each command consists of one or more *words*; the first word is the name of a command and additional words are arguments to that command. 
 
@@ -157,7 +157,7 @@ The following substitutions are performed by TCL:
 Variable substitution is triggered by the $ character (as with csh), the content of the variable is substituted; { } may be used as in csh to enclose the name of the variable.
 
 **Example:** 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.php}
 # set a variable value 
 set file documentation 
 puts $file #to display file contents on the screen 
@@ -172,19 +172,19 @@ set pfile ${file}PS
 # a last one, 
 # delete files NEWdocumentation and OLDdocumentation 
 foreach prefix {NEW OLD} {rm $prefix$file} 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 Command substitution is triggered by the [ ] characters. The brackets must enclose a valid script. The script is evaluated and the result is substituted. 
 
 Compare command construction in csh. 
 
 **Example:** 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.php}
 set degree 30 
 set pi 3.14159265 
 # expr is a command evaluating a numeric expression 
 set radian [expr $pi*$degree/180] 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 Backslash substitution is triggered by the backslash character. It is used to insert special characters like $, [ , ] , etc. It is also useful to insert a new line, a backslash terminated line is continued on the following line. 
 
@@ -193,16 +193,16 @@ TCL uses two forms of *quoting* to prevent substitution and word breaking.
 Double quote *quoting* enables the definition of a string with space and tabs as a single word. Substitutions are still performed inside the inverted commas " ". 
 
 **Example:** 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.php}
 # set msg to ;the price is 12.00; 
 set price 12.00 
 set msg ;the price is $price; 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 Braces *quoting* prevents all substitutions. Braces are also nested. The main use of braces is to defer evaluation when defining procedures and control structures. Braces are used for a clearer presentation of TCL scripts on several lines. 
 
 **Example:** 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.php}
 set x 0 
 # this will loop for ever 
 # because while argument is ;0 < 3; 
@@ -220,22 +220,22 @@ while {$x < 3}
 { 
 set x [expr $x+1] 
 } 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 Comments start with a \# character as the first non-blank character in a command. To add a comment at the end of the line, the comment must be preceded by a semi-colon to end the preceding command. 
 
 **Example:** 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.php}
 # This is a comment 
 set a 1 # this is not a comment 
 set b 1; # this is a comment 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 The number of words is never changed by substitution when parsing in TCL. For example, the result of a substitution is always a single word. This is different from csh but convenient as the behavior of the parser is more predictable. It may sometimes be necessary to force a second round of parsing. **eval** accomplishes this: it accepts several arguments, concatenates them and executes the resulting script. 
 
 
 **Example:** 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~{.php}
 # I want to delete two files 
 
 set files ;foo bar; 
@@ -246,7 +246,7 @@ set files ;foo bar;
 exec rm $files 
 
 # a second evaluation will do it 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 @subsection occt_draw_2_3 Accessing variables in TCL and Draw
 
@@ -261,22 +261,22 @@ There are many kinds of Draw variables, and new ones may be added with C++. Geom
 Draw numeric variables can be used within an expression anywhere a Draw command requires a numeric value. The *expr* command is useless in this case as the variables are stored not as strings but as floating point values. 
 
 **Example:** 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.php}
 # dset is used for numeric variables 
 # pi is a predefined Draw variable 
 dset angle pi/3 radius 10 
 point p radius*cos(angle) radius*sin(angle) 0 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 It is recommended that you use TCL variables only for strings and Draw for numerals. That way, you will avoid the *expr* command. As a rule, Geometry and Topology require numbers but no strings. 
 
 @subsubsection occt_draw_2_3_1 set, unset
 
-Syntax:                  
+Syntax:
 
-~~~~~
+~~~~{.php}
 set varname [value] 
 unset varname [varname varname ...] 
-~~~~~
+~~~~
 
 *set* assigns a string value to a variable. If the variable does not already exist, it is created. 
 
@@ -285,14 +285,14 @@ Without a value, *set* returns the content of the variable.
 *unset* deletes variables. It is also used to delete Draw variables.
 
 **Example:** 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.php}
 set a "Hello world"
 set b "Goodbye" 
 set a 
 == "Hello world" 
 unset a b 
 set a 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 **Note**, that the *set* command can set only one variable, unlike the *dset* command. 
 
@@ -301,10 +301,10 @@ set a
 
 Syntax
 
-~~~~~
+~~~~{.php}
 dset var1 value1 vr2 value2 ... 
 dval name 
-~~~~~
+~~~~
 
 *dset* assigns values to Draw numeric variables. The argument can be any numeric expression including Draw numeric variables. Since all Draw commands expect a numeric expression, there is no need to use $ or *expr*. The *dset* command can assign several variables. If there is an odd number of arguments, the last variable will be assigned a value of 0. If the variable does not exist, it will be created. 
 
@@ -312,7 +312,7 @@ dval name
 
 
 **Example:** 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.php}
 # z is set to 0 
 dset x 10 y 15 z 
 == 0 
@@ -323,17 +323,17 @@ point p x y z
 # "puts" prints a string 
 puts ;x = [dval x], cos(x/pi) = [dval cos(x/pi)]; 
 == x = 10, cos(x/pi) = -0.99913874099467914 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 **Note,** that in TCL, parentheses are not considered to be special characters. Do not forget to quote an expression if it contains spaces in order to avoid parsing different words. <i>(a + b)</i> is parsed as three words: <i>"(a + b)"</i> or <i>(a+b)</i> are correct.
 
 @subsubsection occt_draw_2_3_3 del, dall
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 del varname_pattern [varname_pattern ...] 
 dall
-~~~~~
+~~~~
 
 *del* command does the same thing as *unset*, but it deletes the variables matched by the pattern.
 
@@ -346,13 +346,13 @@ TCL uses lists. A list is a string containing elements separated by spaces or ta
 This allows you to insert lists within lists. 
 
 **Example:** 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.php}
 # a list of 3 strings 
 ;a b c; 
 
 # a list of two strings the first is a list of 2 
 ;{a b} c; 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 Many TCL commands return lists and **foreach** is a useful way to create loops on list elements. 
 
@@ -368,16 +368,16 @@ TCL allows looping using control structures. The control structures are implemen
 
 Syntax       
 
-~~~~~
+~~~~{.php}
 if condition script [elseif script .... else script] 
-~~~~~
+~~~~
 
 **If** evaluates the condition and the script to see whether the condition is true. 
 
 
 
 **Example:** 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.php}
 if {$x > 0} { 
 puts ;positive; 
 } elseif {$x == 0} { 
@@ -385,23 +385,23 @@ puts ;null;
 } else { 
 puts ;negative; 
 } 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 @subsubsection occt_draw_2_5_2 while, for, foreach
 
-Syntax:                  
+Syntax:
 
 
-~~~~~
+~~~~{.php}
 while condition script 
 for init condition reinit script 
 foreach varname list script 
-~~~~~
+~~~~
 
 The three loop structures are similar to their C or csh equivalent. It is important to use braces to delay evaluation. **foreach** will assign the elements of the list to the variable before evaluating the script. \
 
 **Example:** 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.php}
 # while example 
 dset x 1.1 
 while {[dval x] < 100} { 
@@ -416,28 +416,28 @@ for {set i 0} {$i < 10} {incr i} {
 } 
 # foreach example 
 foreach object {crapo tomson lucas} {display $object} 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 @subsubsection occt_draw_2_5_3 break, continue
 
-Syntax:                  
+Syntax:
 
-~~~~~
+~~~~{.php}
 break 
 continue 
-~~~~~
+~~~~
 
 Within loops, the **break** and **continue** commands have the same effect as in C. 
 
 **break** interrupts the innermost loop and **continue** jumps to the next iteration. 
 
 **Example:** 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.php}
 # search the index for which t$i has value ;secret; 
 for {set i 1} {$i <= 100} {incr i} { 
   if {[set t$i] == ;secret;} break; 
 } 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 @subsection occt_draw_2_6 Procedures
 
@@ -454,16 +454,16 @@ As TCL is not a strongly typed language it is very difficult to detect programmi
 
 Syntax:
 
-~~~~~
+~~~~{.php}
 proc argumentlist script 
-~~~~~
+~~~~
 
 **proc** defines a procedure. An argument may have a default value. It is then a list of the form {argument value}. The script is the body of the procedure. 
 
 **return** gives a return value to the procedure. 
 
 **Example:** 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.php}
 # simple procedure 
 proc hello {} { 
   puts ;hello world; 
@@ -478,17 +478,17 @@ proc fact n {
     return [expr n*[fact [expr n -1]]] 
   } 
 } 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 
 @subsubsection occt_draw_2_6_2 global, upvar
 
-Syntax:                 
+Syntax:
 
-~~~~~
+~~~~{.php}
 global varname [varname ...] 
 upvar varname localname [varname localname ...] 
-~~~~~
+~~~~
 
 
 **global** accesses high level variables. Unlike C, global variables are not visible in procedures. 
@@ -498,7 +498,7 @@ upvar varname localname [varname localname ...]
 **Note** that in the following examples the \$ character is always necessarily used to access the arguments.
  
 **Example:** 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.php}
 # convert degree to radian 
 # pi is a global variable 
 proc deg2rad (degree} { 
@@ -509,7 +509,7 @@ proc linang {linename x y angle} {
   upvar linename l 
   line l $x $y cos($angle) sin($angle) 
 }
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 @section occt_draw_3 Basic Commands
 
@@ -536,11 +536,11 @@ This section describes several useful commands:
 
 @subsubsection occt_draw_3_1_1 help
 
-Syntax:                  
+Syntax:
 
-~~~~~
+~~~~{.php}
 help [command [helpstring group]] 
-~~~~~
+~~~~
 
 Provides help or modifies the help information. 
 
@@ -549,29 +549,29 @@ Provides help or modifies the help information.
 Specifying the command returns its syntax and in some cases, information on the command, The joker \* is automatically added at the end so that all completing commands are returned as well. 
 
 **Example:** 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.php}
 # Gives help on all commands starting with *a* 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 
 @subsubsection occt_draw_3_1_2 source
 
 Syntax:
 
-~~~~~
+~~~~{.php}
 source filename 
-~~~~~
+~~~~
 Executes a file. 
 
 The **exit** command will terminate the file. 
 
 @subsubsection occt_draw_3_1_3 spy
 
-Syntax:                  
+Syntax:
 
-~~~~~
+~~~~{.php}
 spy [filename] 
-~~~~~
+~~~~
 
 Saves interactive commands in the file. If spying has already been performed, the current file is closed. **spy** without an argument closes the current file and stops spying. If a file already exists, the file is overwritten. Commands are not appended. 
 
@@ -580,51 +580,51 @@ If a command returns an error it is saved with a comment mark.
 The file created by **spy** can be executed with the **source** command. 
 
 **Example:** 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.php}
 # all commands will be saved in the file ;session; 
 spy session 
 # the file ;session; is closed and commands are not saved 
 spy 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 
 
 @subsubsection occt_draw_3_1_4 cpulimit
 
-Syntax:                  
+Syntax:
 
-~~~~~
+~~~~{.php}
 cpulimit [nbseconds] 
-~~~~~
+~~~~
 
 **cpulimit**limits a process after the number of seconds specified in nbseconds. It is used in tests to avoid infinite loops. **cpulimit** without arguments removes all existing limits. 
 
 **Example:** 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.php}
 #limit cpu to one hour 
 cpulimit 3600 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 @subsubsection occt_draw_3_1_5 wait
 
 Syntax:
-~~~~~
+~~~~{.php}
 wait [nbseconds] 
-~~~~~
+~~~~
 Suspends execution for the number of seconds specified in *nbseconds*. The default value is ten (10) seconds. This is a useful command for a slide show. 
 
-~~~~~
+~~~~{.php}
 # You have ten seconds ... 
 wait 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_3_1_6 chrono
 
-Syntax:                  
+Syntax:
 
-~~~~~
+~~~~{.php}
 chrono [ name start/stop/reset/show/restart/[counter text]]
-~~~~~
+~~~~
 
 Without arguments, **chrono** activates Draw chronometers. The elapsed time ,cpu system and cpu user times for each command will be printed. 
 
@@ -637,31 +637,31 @@ With arguments, **chrono** is used to manage activated chronometers. You can per
   * display the current time with specified text (output example - *COUNTER text: N*), command <i>testdiff</i> will compare such outputs between two test runs (counter).
 
 **Example:** 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.php}
 chrono 
 ==Chronometers activated. 
 ptorus t 20 5 
 ==Elapsed time: 0 Hours 0 Minutes 0.0318 Seconds 
 ==CPU user time: 0.01 seconds 
 ==CPU system time: 0 seconds 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 @subsection occt_draw_3_2  Variable management commands
 
 @subsubsection occt_draw_3_2_1 isdraw, directory
 
-Syntax:                  
-~~~~~
+Syntax:
+~~~~{.php}
 isdraw varname 
 directory [pattern] 
-~~~~~
+~~~~
 
 **isdraw** tests to see if a variable is a Draw variable. **isdraw** will return 1 if there is a Draw value attached to the variable. 
 
 Use **directory** to return a list of all Draw global variables matching a pattern. 
 
 **Example:** 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.php}
 set a 1 
 isdraw a 
 === 0 
@@ -676,24 +676,24 @@ isdraw c
 
 # to destroy all Draw objects with name containing curve 
 foreach var [directory *curve*] {unset $var} 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 
 @subsubsection occt_draw_3_2_2 whatis, dump
 
 Syntax:
 
-~~~~~
+~~~~{.php}
 whatis varname [varname ...] 
 dump varname [varname ...] 
-~~~~~
+~~~~
 
 **whatis** returns short information about a Draw variable. This is usually the type name. 
 
 **dump** returns a brief type description, the coordinates, and if need be, the parameters of a Draw variable. 
 
 **Example:** 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.php}
 circle c 0 0 1 0 5 
 whatis c 
 c is a 2d curve 
@@ -706,39 +706,39 @@ Center :0, 0
 XAxis :1, 0 
 YAxis :-0, 1 
 Radius :5 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 **Note** The behavior of *whatis* on other variables (not Draw) is not excellent. 
 
 
 @subsubsection occt_draw_3_2_3 renamevar, copy
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 renamevar varname tovarname [varname tovarname ...] 
 copy varname tovarname [varname tovarname ...] 
-~~~~~
+~~~~
 
   * **renamevar** changes the name of a Draw variable. The original variable will no longer exist. Note that the content is not modified. Only the name is changed. 
   * **copy** creates a new variable with a copy of the content of an existing variable. The exact behavior of **copy** is type dependent; in the case of certain topological variables, the content may still be shared. 
 
 **Example:** 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.php}
 circle c1 0 0 1 0 5 
 renamevar c1 c2 
 
 # curves are copied, c2 will not be modified 
 copy c2 c3 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 @subsubsection occt_draw_3_2_4 datadir, save, restore
 
 Syntax:
-~~~~~
+~~~~{.php}
 datadir [directory] 
 save variable [filename] 
 restore filename [variablename] 
-~~~~~
+~~~~
 
   * **datadir** without arguments prints the path of the current data directory. 
   * **datadir** with an argument sets the data directory path. \
@@ -751,7 +751,7 @@ If the path starts with a dot (.) only the last directory name will be changed i
 The exact content of the file is type-dependent. They are usually ASCII files and so, architecture independent. 
 
 **Example:** 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.php}
 # note how TCL accesses shell environment variables 
 # using $env() 
 datadir 
@@ -770,7 +770,7 @@ ls [datadir]
 
 restore theBox 
 == theBox 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 @subsection occt_draw_3_3 User defined commands
 
@@ -782,7 +782,7 @@ restore theBox
 
 #### In *DrawTrSurf* package:
 
-~~~~~
+~~~~{.php}
 void Set(Standard_CString& Name,const gp_Pnt& G) ; 
 void Set(Standard_CString& Name,const gp_Pnt2d& G) ; 
 void Set(Standard_CString& Name, 
@@ -795,51 +795,51 @@ void Set(Standard_CString& Name,
 const Handle(Poly_Polygon3D)& P) ; 
 void Set(Standard_CString& Name, 
 const Handle(Poly_Polygon2D)& P) ; 
-~~~~~
+~~~~
 
 #### In *DBRep* package:
 
-~~~~~
+~~~~{.php}
 void Set(const Standard_CString Name, 
 const TopoDS_Shape& S) ; 
-~~~~~
+~~~~
 
 Example of *DrawTrSurf*
 
-~~~~~
+~~~~{.php}
 Handle(Geom2d_Circle) C1 = new Geom2d_Circle 
 (gce_MakeCirc2d (gp_Pnt2d(50,0,) 25)); 
 DrawTrSurf::Set(char*, C1); 
-~~~~~
+~~~~
 
 Example of *DBRep* 
 
-~~~~~
+~~~~{.php}
 TopoDS_Solid B; 
 B = BRepPrimAPI_MakeBox (10,10,10); 
 DBRep::Set(char*,B); 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_3_3_2 get
 
 #### In *DrawTrSurf* package:
  
-~~~~~
+~~~~{.php}
 Handle_Geom_Geometry Get(Standard_CString& Name) ; 
-~~~~~
+~~~~
 
 #### In *DBRep* package:
 
-~~~~~
+~~~~{.php}
 TopoDS_Shape Get(Standard_CString& Name, 
 const TopAbs_ShapeEnum Typ = TopAbs_SHAPE, 
 const Standard_Boolean Complain 
 = Standard_True) ; 
-~~~~~
+~~~~
 
 Example of *DrawTrSurf*
 
-~~~~~
+~~~~{.php}
 Standard_Integer MyCommand 
 (Draw_Interpretor& theCommands, 
 Standard_Integer argc, char** argv) 
@@ -848,11 +848,11 @@ Standard_Integer argc, char** argv)
 // name 
 Handle (Geom_Geometry) aGeom= DrawTrSurf::Get(argv[1]); 
 } 
-~~~~~
+~~~~
 
 Example of *DBRep*
 
-~~~~~
+~~~~{.php}
 Standard_Integer MyCommand 
 (Draw_Interpretor& theCommands, 
 Standard_Integer argc, char** argv) 
@@ -861,7 +861,7 @@ Standard_Integer argc, char** argv)
 // name 
 TopoDS_Solid B = DBRep::Get(argv[1]); 
 } 
-~~~~~
+~~~~
 
 @section occt_draw_4 Graphic Commands
 
@@ -871,11 +871,11 @@ Graphic commands are used to manage the Draw graphic system. Draw provides a 2d
 
 @subsubsection occt_draw_4_1_1 view, delete
 
-Syntax:                  
-~~~~~
+Syntax:
+~~~~{.php}
 view index type [X Y W H] 
 delete [index] 
-~~~~~
+~~~~
 
 **view** is the basic view creation command: it creates a new view with the given index. If a view with this index already exits, it is deleted. The view is created with default parameters and X Y W H are the position and dimensions of the window on the screen. Default values are 0, 0, 500, 500. 
 
@@ -893,7 +893,7 @@ Type selects from the following range:
 The index, the type, the current zoom are displayed in the window title . 
 
 **Example:** 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.php}
 # this is the content of the mu4 procedure 
 proc mu4 {} { 
 delete 
@@ -902,20 +902,20 @@ view 2 +X+Y 320 450 400 400
 view 3 +Y+Z 728 20 400 400 
 view 4 AXON 728 450 400 400 
 } 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 See also: **axo, pers, top, bottom, left, right, front, back, mu4, v2d, av2d, smallview** 
 
 @subsubsection occt_draw_4_1_2  axo, pers, top, ...
 
-Syntax:      
+Syntax:
 
-~~~~~
+~~~~{.php}
 axo 
 pers 
 ... 
 smallview type 
-~~~~~
+~~~~
 
 All these commands are procedures used to define standard screen layout. They delete all existing views and create new ones. The layout usually complies with the European convention, i.e. a top view is under a front view. 
 
@@ -933,12 +933,12 @@ See also: **view**, **delete**
 
 Syntax:
 
-~~~~~
+~~~~{.php}
     mu [index] value 
     2dmu [index] value 
     zoom [index] value 
     wzoom 
-~~~~~
+~~~~
 
 * **mu** (magnify up) increases the zoom in one or several views by a factor of 10%. 
 * **md** (magnify down) decreases the zoom by the inverse factor. **2dmu** and **2dmd** 
@@ -947,7 +947,7 @@ perform the same on one or all 2d views.
 * **wzoom** (window zoom) allows you to select the area you want to zoom in on with the mouse. You will be prompted to give two of the corners of the area that you want to magnify and the rectangle so defined will occupy the window of the view. 
 
 **Example:** 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.php}
     # set a zoom of 2.5 
     zoom 2.5 
 
@@ -955,21 +955,21 @@ perform the same on one or all 2d views.
     mu 1 
 
     # magnify by 20% 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 See also: **fit**, **2dfit** 
 
 
 @subsubsection occt_draw_4_14 pu, pd, pl, pr, 2dpu, 2dpd, 2dpl, 2dpr
 
-Syntax:                  
+Syntax:
 
-~~~~~
+~~~~{.php}
 pu [index] 
 pd [index] 
-~~~~~
+~~~~
 
 The <i>p_</i> commands are used to pan. **pu** and **pd** pan up and down respectively; **pl** and **pr** pan to the left and to the right respectively. Each time the view is displaced by 40 pixels. When no index is given, all views will pan in the direction specified. 
-~~~~~
+~~~~{.php}
 # you have selected one anonometric view
 pu
 # or
@@ -977,69 +977,69 @@ pu 1
 
 # you have selected an mu4 view; the object in the third view will pan up
 pu 3
-~~~~~
+~~~~
 See also: **fit**, **2dfit** 
 
 
 @subsubsection occt_draw_4_1_5 fit, 2dfit
 
-Syntax:      
+Syntax:
 
-~~~~~
+~~~~{.php}
 fit [index] 
 2dfit [index] 
-~~~~~
+~~~~
 
 **fit** computes the best zoom and pans on the content of the view. The content of the view will be centered and fit the whole window. 
 
 When fitting all views a unique zoom is computed for all the views. All views are on the same scale. 
 
 **Example:** 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.php}
 # fit only view 1 
 fit 1 
 # fit all 2d views 
 2dfit 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 See also: **zoom**, **mu**, **pu** 
 
 
 @subsubsection occt_draw_4_1_6 u, d, l, r
 
-Syntax:      
+Syntax:
 
-~~~~~
+~~~~{.php}
 u [index] 
 d [index] 
 l [index] 
 r [index] 
-~~~~~
+~~~~
 
 **u**, **d**, **l**, **r** Rotate the object in view around its axis by five degrees up, down, left or right respectively. This command is restricted to axonometric and perspective views. 
 
 **Example:** 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.php}
 # rotate the view up 
 u 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 @subsubsection occt_draw_4_1_7 focal, fu, fd
 
-Syntax:                  
-~~~~~
+Syntax:
+~~~~{.php}
 focal [f] 
 fu [index] 
 fd [index] 
-~~~~~
+~~~~
 
 * **focal** changes the vantage point in perspective views. A low f value increases the perspective effect; a high one give a perspective similar to that of an axonometric view. The default value is 500. 
 * **fu** and **fd** increase or decrease the focal value by 10%. **fd** makes the eye closer to the object. 
 
 **Example:** 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.php}
 pers 
 repeat 10 fd 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 **Note**: Do not use a negative or null focal value. 
 
@@ -1047,58 +1047,58 @@ See also: **pers**
 
 @subsubsection occt_draw_4_1_8 color
 
-Syntax: 
+Syntax:
 
-~~~~~
+~~~~{.php}
 color index name 
-~~~~~
+~~~~
 
 **color** sets the color to a value. The index of the *color* is a value between 0 and 15. The name is an X window color name. The list of these can be found in the file *rgb.txt* in the X library directory. 
 
 The default values are: 0 White, 1 Red, 2 Green, 3 Blue, 4 Cyan, 5 Gold, 6 Magenta, 7 Marron, 8 Orange, 9 Pink, 10 Salmon, 11 Violet, 12 Yellow, 13 Khaki, 14 Coral. 
 
 **Example:** 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.php}
 # change the value of blue 
 color 3 "navy blue" 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 
 **Note** that the color change will be visible on the next redraw of the views, for example, after *fit* or *mu*, etc. 
 
 @subsubsection occt_draw_4_1_9 dtext
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 dtext [x y [z]] string 
-~~~~~
+~~~~
 
 **dtext** displays a string in all 3d or 2d views. If no coordinates are given, a graphic selection is required. If two coordinates are given, the text is created in a 2d view at the position specified. With 3 coordinates, the text is created in a 3d view. 
 
 The coordinates are real space coordinates. 
 
 **Example:** 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.php}
 # mark the origins 
 dtext 0 0 bebop 
 dtext 0 0 0 bebop 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 @subsubsection occt_draw_4_1_10 hardcopy, hcolor, xwd
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 hardcopy [index] 
 hcolor index width gray 
 xwd [index] filename 
-~~~~~
+~~~~
 
 * **hardcopy** creates a postcript file called a4.ps in the current directory. This file contains the postscript description of the view index, and will allow you to print the view. 
 * **hcolor** lets you change the aspect of lines in the postscript file. It allows to specify a width and a gray level for one of the 16 colors. **width** is measured in points with default value as 1, **gray** is the gray level from 0 = black to 1 = white with default value as 0. All colors are bound to the default values at the beginning. 
 * **xwd** creates an X window xwd file from an active view. By default, the index is set to1. To visualize an xwd file, use the unix command **xwud**. 
 
 **Example:** 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.php}
 # all blue lines (color 3) 
 # will be half-width and gray 
 hcolor 3 0.5 
@@ -1110,7 +1110,7 @@ lpr a4.ps
 # make an xwd file and display it 
 xwd theview 
 xwud -in theview 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 **Note:** When more than one view is present, specify the index of the view. 
 
@@ -1121,11 +1121,11 @@ See also: **color**
 
 @subsubsection occt_draw_4_1_11 wclick, pick
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 wclick 
 pick index X Y Z b [nowait] 
-~~~~~
+~~~~
 
 **wclick** defers an event until the mouse button is clicked. The message <code>just click</code> is displayed. 
 
@@ -1141,7 +1141,7 @@ This option is useful for tracking the pointer.
 **Note** that the results are stored in Draw numeric variables.
 
 **Example:** 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.php}
 # make a circle at mouse location 
 pick index x y z b 
 circle c x y z 0 0 1 1 0 0 0 30 
@@ -1156,7 +1156,7 @@ pick index x y z b nowait
 circle c x y z 0 0 1 1 0 0 0 30 
 repaint 
 } 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 See also: **repaint** 
 
 
@@ -1171,7 +1171,7 @@ The variable name "." (dot) has a special status in Draw. Any Draw command expec
   * If you do not see what you expected while executing loops or sourcing files, use the **repaint** and **dflush** commands.
 
 **Example:** 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.php}
 # OK use dot to dump an object on the screen 
 dump . 
 
@@ -1194,23 +1194,23 @@ point . x y z
 
 # give a name to a graphic object 
 renamevar . x 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 
 @subsubsection occt_draw_4_1_12 autodisplay
 
-Syntax:      
+Syntax:
 
-~~~~~
+~~~~{.php}
 autodisplay [0/1] 
-~~~~~
+~~~~
 
 By default, Draw automatically displays any graphic object as soon as it is created. This behavior known as autodisplay can be removed with the command **autodisplay**. Without arguments, **autodisplay** toggles the autodisplay mode. The command always returns the current mode. 
 
 When **autodisplay** is off, using the dot return argument is ineffective. 
 
 **Example:** 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.php}
 # c is displayed 
 circle c 0 0 1 0 5 
 
@@ -1221,38 +1221,38 @@ circle c 0 0 1 0 5
 
 # c is erased, but not displayed 
 display c 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 @subsubsection occt_draw_4_1_13 display, donly
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 display varname [varname ...] 
 donly varname [varname ...] 
-~~~~~
+~~~~
 
 * **display** makes objects visible. 
 * **donly** *display only* makes objects visible and erases all other objects. It is very useful to extract one object from a messy screen. 
 
 **Example:** 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.php}
 \# to see all objects 
 foreach var [directory] {display $var} 
 
 \# to select two objects and erase the other ones 
 donly . . 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 
 @subsubsection occt_draw_4_1_14 erase, clear, 2dclear
 
-Syntax:      
+Syntax:
 
-~~~~~
+~~~~{.php}
 erase [varname varname ...] 
 clear 
 2dclear 
-~~~~~
+~~~~
 
 **erase** removes objects from all views. **erase** without arguments erases everything in 2d and 3d. 
 
@@ -1260,31 +1260,31 @@ clear
 
 
 **Example:** 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.php}
 # erase eveerything with a name starting with c_ 
 foreach var [directory c_*] {erase $var} 
 
 # clear 2d views 
 2dclear 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 @subsubsection occt_draw_4_1_14_1 disp, don, era
 
 These commands have the same meaning as correspondingly display, donly and erase, but with the difference that they evaluate the arguments using glob pattern rules.
 For example, to display all objects with names d_1, d_2, d_3, etc. it is enough to run the command:
-~~~~~{.cpp}
+~~~~{.php}
 disp d_*
-~~~~~
+~~~~
 
 @subsubsection occt_draw_4_1_15 repaint, dflush
 
 
 Syntax:
 
-~~~~~
+~~~~{.php}
 repaint 
 dflush 
-~~~~~
+~~~~
 
 * **repaint** forces repainting of views. 
 * **dflush** flushes the graphic buffers. 
@@ -1301,14 +1301,14 @@ See also: @ref occt_draw_4_1_11 "pick" command.
 
 @subsubsection occt_draw_4_2_1 vinit
 
-Syntax:                  
-~~~~~
+Syntax:
+~~~~{.php}
 vinit 
-~~~~~
+~~~~
 Creates a new View window with the specified *view_name*.
 By default the view is created in the viewer and in the graphic driver shared with the active view.
 
-~~~~
+~~~~{.php}
 name = {driverName/viewerName/viewName | viewerName/viewName | viewName}
 ~~~~
 
@@ -1318,110 +1318,110 @@ If *viewerName* is not specified the viewer will be shared with the active view.
 @subsubsection occt_draw_4_2_2 vhelp
 
 Syntax:
-~~~~~
+~~~~{.php}
 vhelp 
-~~~~~
+~~~~
 Displays help in the 3D viewer window. The help consists in a list of hotkeys and their functionalities. 
 
 @subsubsection occt_draw_4_2_3 vtop
 
 Syntax:
-~~~~~
+~~~~{.php}
 vtop 
-~~~~~
+~~~~
 
 Displays top view in the 3D viewer window. Orientation +X+Y.
 
 **Example:** 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.php}
 vinit 
 box b 10 10 10 
 vdisplay b 
 vfit 
 vtop 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 @subsubsection occt_draw_4_2_4 vaxo
 
-Syntax:                  
-~~~~~
+Syntax:
+~~~~{.php}
 vaxo 
-~~~~~
+~~~~
 
 Displays axonometric view in the 3D viewer window. Orientation +X-Y+Z.
 
 **Example:** 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.php}
 vinit 
 box b 10 10 10 
 vdisplay b 
 vfit 
 vaxo 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 @subsubsection occt_draw_4_2_5 vsetbg
 
-Syntax:                  
-~~~~~
+Syntax:
+~~~~{.php}
 vsetbg imagefile [filltype] 
-~~~~~
+~~~~
 
 Loads image file as background. *filltype* must be NONE, CENTERED, TILED or STRETCH. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 vinit 
 vsetbg myimage.brep CENTERED 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_4_2_6 vclear
 
-Syntax:                  
-~~~~~
+Syntax:
+~~~~{.php}
 vclear 
-~~~~~
+~~~~
 Removes all objects from the viewer. 
 
 @subsubsection occt_draw_4_2_7 vrepaint
 
-Syntax:                  
-~~~~~
+Syntax:
+~~~~{.php}
 vrepaint 
-~~~~~
+~~~~
 Forcibly redisplays the shape in the 3D viewer window. 
 
 @subsubsection occt_draw_4_2_8 vfit
 
-Syntax:                  
-~~~~~
+Syntax:
+~~~~{.php}
 vfit 
-~~~~~
+~~~~
 Automatic zoom/panning. Objects in the view are visualized to occupy the maximum surface. 
 
 @subsubsection occt_draw_4_2_9 vzfit
 
-Syntax:                  
-~~~~~
+Syntax:
+~~~~{.php}
 vzfit 
-~~~~~
+~~~~
 
 Automatic depth panning. Objects in the view are visualized to occupy the maximum 3d space. 
 
 @subsubsection occt_draw_4_2_10  vreadpixel
 
-Syntax:     
-~~~~~
+Syntax:
+~~~~{.php}
 vreadpixel xPixel yPixel [{rgb|rgba|depth|hls|rgbf|rgbaf}=rgba] [name] 
-~~~~~
+~~~~
 Read pixel value for active view.
 
 
 @subsubsection occt_draw_4_2_11  vselect
 
-Syntax:     
-~~~~~
+Syntax:
+~~~~{.php}
 vselect x1 y1 [x2 y2 [x3 y3 ... xn yn]] [-allowoverlap 0|1] [shift_selection = 0|1]
-~~~~~
+~~~~
 
 Emulates different types of selection:
 
@@ -1433,19 +1433,19 @@ Emulates different types of selection:
 
 @subsubsection occt_draw_4_2_12  vmoveto
 
-Syntax:     
+Syntax:
 
-~~~~~
+~~~~{.php}
 vmoveto x y
-~~~~~
+~~~~
 Emulates cursor movement to pixel position (x,y).
 
 @subsubsection occt_draw_4_2_13  vviewparams
 
-Syntax:     
-~~~~~
+Syntax:
+~~~~{.php}
 vviewparams [-scale [s]] [-eye [x y z]] [-at [x y z]] [-up [x y z]] [-proj [x y z]] [-center x y] [-size sx]
-~~~~~
+~~~~
 Gets or sets the current view parameters.
 * If called without arguments, all view parameters are printed.
 * The options are:
@@ -1459,36 +1459,36 @@ Gets or sets the current view parameters.
 
 @subsubsection occt_draw_4_2_14  vchangeselected
 
-Syntax:     
-~~~~~
+Syntax:
+~~~~{.php}
 vchangeselected shape
-~~~~~
+~~~~
 Adds a shape to selection or removes one from it.
 
 @subsubsection occt_draw_4_2_16  vnbselected
 
-Syntax:     
-~~~~~
+Syntax:
+~~~~{.php}
 vnbselected
-~~~~~
+~~~~
 Returns the number of selected objects in the interactive context.
 
 @subsubsection occt_draw_4_2_19  vhlr
 
-Syntax:     
-~~~~~
+Syntax:
+~~~~{.php}
 vhlr is_enabled={on|off} [show_hidden={1|0}]
-~~~~~
+~~~~
 Hidden line removal algorithm:
  * <i>is_enabled</i> applies HLR algorithm.
  * <i>show_hidden</i> if equals to 1, hidden lines are drawn as dotted ones.
 
 @subsubsection occt_draw_4_2_20  vhlrtype
 
-Syntax:     
-~~~~~
+Syntax:
+~~~~{.php}
 vhlrtype  algo_type={algo|polyalgo} [shape_1 ... shape_n]
-~~~~~
+~~~~
 
 Changes the type of HLR algorithm used for shapes.
 If the algo_type is algo, the exact HLR algorithm is used, otherwise the polygonal algorithm is used for defined shapes. 
@@ -1500,14 +1500,14 @@ If no shape is specified through the command arguments, the given HLR algorithm_
 @subsubsection occt_draw_4_2_21 vcamera
 
 Syntax:
-~~~~~
+~~~~{.php}
 vcamera [-ortho] [-projtype]
         [-persp]
         [-fovy   [Angle]] [-distance [Distance]]
         [-stereo] [-leftEye] [-rightEye]
         [-iod [Distance]] [-iodType    [absolute|relative]]
         [-zfocus [Value]] [-zfocusType [absolute|relative]]
-~~~~~
+~~~~
 
 Manages camera parameters.
 Prints the current value when the option is called without argument.
@@ -1530,20 +1530,20 @@ Stereoscopic camera:
  * -zfocusType -- focus type, absolute or relative.
 
 **Example:**
-~~~~~
+~~~~{.php}
 vinit
 box b 10 10 10
 vdisplay b
 vfit
 vcamera -persp
-~~~~~
+~~~~
 
 @subsubsection occt_draw_4_2_22 vstereo
 
 Syntax:
-~~~~~
+~~~~{.php}
 vstereo [0|1] [-mode Mode] [-reverse {0|1}] [-anaglyph Filter]
-~~~~~
+~~~~
 
 Defines the stereo output mode. The following modes are available:
  * quadBuffer -- OpenGL QuadBuffer stereo, requires driver support. Should be called BEFORE *vinit*!
@@ -1557,7 +1557,7 @@ Available Anaglyph filters for -anaglyph:
  * redCyan, redCyanSimple, yellowBlue, yellowBlueSimple, greenMagentaSimple.
 
 **Example:**
-~~~~~
+~~~~{.php}
 vinit
 box b 10 10 10
 vdisplay b
@@ -1566,14 +1566,14 @@ vfit
 vcamera -stereo -iod 1
 vcamera -lefteye
 vcamera -righteye
-~~~~~
+~~~~
 
 @subsubsection occt_draw_4_2_23 vfrustumculling
 
 Syntax:
-~~~~~
+~~~~{.php}
 vfrustumculling [toEnable]
-~~~~~
+~~~~
 
 Enables/disables objects clipping.
 
@@ -1582,15 +1582,15 @@ Enables/disables objects clipping.
 
 @subsubsection occt_draw_4_3_1 vdisplay
 
-Syntax: 
-~~~~~                 
+Syntax:
+~~~~{.php}
 vdisplay [-noupdate|-update] [-local] [-mutable] [-neutral]
          [-trsfPers {pan|zoom|rotate|trihedron|full|none}=none] [-trsfPersPos X Y [Z]] [-3d|-2d|-2dTopDown]
          [-dispMode mode] [-highMode mode]
          [-layer index] [-top|-topmost|-overlay|-underlay]
          [-redisplay]
          name1 [name2] ... [name n]
-~~~~~
+~~~~
 
 Displays named objects.
 Option <i>-local</i> enables display of objects in the local selection context.
@@ -1613,62 +1613,62 @@ Local selection context will be opened if there is not any.
 * *redisplay* recomputes presentation of objects.
 
 **Example:** 
-~~~~
+~~~~{.php}
 vinit 
 box b 40 40 40 10 10 10 
 psphere s 20 
 vdisplay s b 
 vfit 
-~~~~
+~~~~
 
 @subsubsection occt_draw_4_3_2 vdonly
 
-Syntax:                  
-~~~~~
+Syntax:
+~~~~{.php}
 vdonly [-noupdate|-update] [name1] ...  [name n]
-~~~~
+~~~~
 
 Displays only selected or named objects. If there are no selected or named objects, nothing is done. 
 
 **Example:** 
-~~~~
+~~~~{.php}
 vinit 
 box b 40 40 40 10 10 10 
 psphere s 20 
 vdonly b 
 vfit
-~~~~
+~~~~
  
 @subsubsection occt_draw_4_3_3 vdisplayall
 
-Syntax:                  
-~~~~
+Syntax:
+~~~~{.php}
 vdisplayall [-local]
-~~~~
+~~~~
 
 Displays all erased interactive objects (see vdir and vstate).
 Option <i>-local</i> enables displaying objects in the local selection context.
 
 **Example:** 
-~~~~
+~~~~{.php}
 vinit 
 box b 40 40 40 10 10 10 
 psphere s 20 
 vdisplayall 
 vfit 
-~~~~
+~~~~
 
 @subsubsection occt_draw_4_3_4 verase
 
-Syntax:                  
-~~~~~
+Syntax:
+~~~~{.php}
 verase [name1] [name2] … [name n]
-~~~~
+~~~~
 
 Erases some selected or named objects. If there are no selected or named objects, the whole viewer is erased. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 vinit 
 box b1 40 40 40 10 10 10 
 box b2 -40 -40 -40 10 10 10 
@@ -1679,19 +1679,19 @@ vfit
 verase b1 
 # erase second box and sphere 
 verase
-~~~~
+~~~~
 
 @subsubsection occt_draw_4_3_5 veraseall
 
-Syntax:                  
-~~~~~
+Syntax:
+~~~~{.php}
 veraseall
-~~~~
+~~~~
 
 Erases all objects displayed in the viewer. 
 
 **Example:**
-~~~~
+~~~~{.php}
 vinit 
 box b1 40 40 40 10 10 10 
 box b2 -40 -40 -40 10 10 10 
@@ -1702,14 +1702,14 @@ vfit
 verase b1 
 # erase second box and sphere 
 verseall
-~~~~
+~~~~
 
 @subsubsection occt_draw_4_3_6 vsetdispmode
 
-Syntax:                  
-~~~~~
+Syntax:
+~~~~{.php}
 vsetdispmode [name] mode(0,1,2,3)
-~~~~
+~~~~
 
 Sets display mode for all, selected or named objects. 
 * *0* (*WireFrame*), 
@@ -1718,47 +1718,47 @@ Sets display mode for all, selected or named objects.
 * *3* (*Exact HideLineremoval*). 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 vinit 
 box b 10 10 10 
 vdisplay b 
 vsetdispmode 1 
 vfit
-~~~~~
+~~~~
  
 @subsubsection occt_draw_4_3_7 vdisplaytype
 
-Syntax:                  
-~~~~~
+Syntax:
+~~~~{.php}
 vdisplaytype type
-~~~~
+~~~~
 
 Displays all objects of a given type. 
 The following types are possible: *Point*, *Axis*, *Trihedron*, *PlaneTrihedron*, *Line*, *Circle*, *Plane*, *Shape*, *ConnectedShape*, *MultiConn.Shape*, *ConnectedInter.*, *MultiConn.*, *Constraint* and *Dimension*. 
 
 @subsubsection occt_draw_4_3_8 verasetype
 
-Syntax:                  
-~~~~~
+Syntax:
+~~~~{.php}
 verasetype type
-~~~~
+~~~~
 
 Erases all objects of a given type. 
 Possible type is *Point*, *Axis*, *Trihedron*, *PlaneTrihedron*, *Line*, *Circle*, *Plane*, *Shape*, *ConnectedShape*, *MultiConn.Shape*, *ConnectedInter.*, *MultiConn.*, *Constraint* and *Dimension*. 
 
 @subsubsection occt_draw_4_3_9 vtypes
 
-Syntax:                  
-~~~~~
+Syntax:
+~~~~{.php}
 vtypes
-~~~~
+~~~~
 
 Makes a list of known types and signatures in AIS. 
 
 @subsubsection occt_draw_4_3_10 vaspects
 
 Syntax:
-~~~~~
+~~~~{.php}
 vaspects [-noupdate|-update] [name1 [name2 [...]] | -defaults]
          [-setVisibility 0|1]
          [-setColor ColorName] [-setcolor R G B] [-unsetColor]
@@ -1773,7 +1773,7 @@ vaspects [-noupdate|-update] [name1 [name2 [...]] | -defaults]
          [-isoontriangulation 0|1]
          [-setMaxParamValue {value}]
 
-~~~~~
+~~~~
 
 Manages presentation properties of all, selected or named objects.
 * *-subshapes* -- assigns presentation properties to the specified sub-shapes.
@@ -1781,45 +1781,45 @@ Manages presentation properties of all, selected or named objects.
 If *-defaults* option is used there should not be any names of objects and *-subshapes* specifier.
 
 Aliases:
-~~~~~
+~~~~{.php}
 vsetcolor [-noupdate|-update] [name] ColorName
 
-~~~~~
+~~~~
 
 
 Manages presentation properties (color, material, transparency) of all objects, selected or named.
 
 **Color**. The *ColorName* can be: *BLACK*, *MATRAGRAY*, *MATRABLUE*, *ALICEBLUE*, *ANTIQUEWHITE*, *ANTIQUEWHITE1*, *ANTIQUEWHITE2*, *ANTIQUEWHITE3*, *ANTIQUEWHITE4*, *AQUAMARINE1*, *AQUAMARINE2*, *AQUAMARINE4*, *AZURE*, *AZURE2*, *AZURE3*, *AZURE4*, *BEIGE*, *BISQUE*, *BISQUE2*, *BISQUE3*, *BISQUE4*, *BLANCHEDALMOND*, *BLUE1*, *BLUE2*, *BLUE3*, *BLUE4*, *BLUEVIOLET*, *BROWN*, *BROWN1*, *BROWN2*, *BROWN3*, *BROWN4*, *BURLYWOOD*, *BURLYWOOD1*, *BURLYWOOD2*, *BURLYWOOD3*, *BURLYWOOD4*, *CADETBLUE*, *CADETBLUE1*, *CADETBLUE2*, *CADETBLUE3*, *CADETBLUE4*, *CHARTREUSE*, *CHARTREUSE1*, *CHARTREUSE2*, *CHARTREUSE3*, *CHARTREUSE4*, *CHOCOLATE*, *CHOCOLATE1*, *CHOCOLATE2*, *CHOCOLATE3*, *CHOCOLATE4*, *CORAL*, *CORAL1*, *CORAL2*, *CORAL3*, *CORAL4*, *CORNFLOWERBLUE*, *CORNSILK1*, *CORNSILK2*, *CORNSILK3*, *CORNSILK4*, *CYAN1*, *CYAN2*, *CYAN3*, *CYAN4*, *DARKGOLDENROD*, *DARKGOLDENROD1*, *DARKGOLDENROD2*, *DARKGOLDENROD3*, *DARKGOLDENROD4*, *DARKGREEN*, *DARKKHAKI*, *DARKOLIVEGREEN*, *DARKOLIVEGREEN1*, *DARKOLIVEGREEN2*, *DARKOLIVEGREEN3*, *DARKOLIVEGREEN4*, *DARKORANGE*, *DARKORANGE1*, *DARKORANGE2*, *DARKORANGE3*, *DARKORANGE4*, *DARKORCHID*, *DARKORCHID1*, *DARKORCHID2*, *DARKORCHID3*, *DARKORCHID4*, *DARKSALMON*, *DARKSEAGREEN*, *DARKSEAGREEN1*, *DARKSEAGREEN2*, *DARKSEAGREEN3*, *DARKSEAGREEN4*, *DARKSLATEBLUE*, *DARKSLATEGRAY1*, *DARKSLATEGRAY2*, *DARKSLATEGRAY3*, *DARKSLATEGRAY4*, *DARKSLATEGRAY*, *DARKTURQUOISE*, *DARKVIOLET*, *DEEPPINK*, *DEEPPINK2*, *DEEPPINK3*, *DEEPPINK4*, *DEEPSKYBLUE1*, *DEEPSKYBLUE2*, *DEEPSKYBLUE3*, *DEEPSKYBLUE4*, *DODGERBLUE1*, *DODGERBLUE2*, *DODGERBLUE3*, *DODGERBLUE4*, *FIREBRICK*, *FIREBRICK1*, *FIREBRICK2*, *FIREBRICK3*, *FIREBRICK4*, *FLORALWHITE*, *FORESTGREEN*, *GAINSBORO*, *GHOSTWHITE*, *GOLD*, *GOLD1*, *GOLD2*, *GOLD3*, *GOLD4*, *GOLDENROD*, *GOLDENROD1*, *GOLDENROD2*, *GOLDENROD3*, *GOLDENROD4*, *GRAY*, *GRAY0*, *GRAY1*, *GRAY10*, *GRAY11*, *GRAY12*, *GRAY13*, *GRAY14*, *GRAY15*, *GRAY16*, *GRAY17*, *GRAY18*, *GRAY19*, *GRAY2*, *GRAY20*, *GRAY21*, *GRAY22*, *GRAY23*, *GRAY24*, *GRAY25*, *GRAY26*, *GRAY27*, *GRAY28*, *GRAY29*, *GRAY3*, *GRAY30*, *GRAY31*, *GRAY32*, *GRAY33*, *GRAY34*, *GRAY35*, *GRAY36*, *GRAY37*, *GRAY38*, *GRAY39*, *GRAY4*, *GRAY40*, *GRAY41*, *GRAY42*, *GRAY43*, *GRAY44*, *GRAY45*, *GRAY46*, *GRAY47*, *GRAY48*, *GRAY49*, *GRAY5*, *GRAY50*, *GRAY51*, *GRAY52*, *GRAY53*, *GRAY54*, *GRAY55*, *GRAY56*, *GRAY57*, *GRAY58*, *GRAY59*, *GRAY6*, *GRAY60*, *GRAY61*, *GRAY62*, *GRAY63*, *GRAY64*, *GRAY65*, *GRAY66*, *GRAY67*, *GRAY68*, *GRAY69*, *GRAY7*, *GRAY70*, *GRAY71*, *GRAY72*, *GRAY73*, *GRAY74*, *GRAY75*, *GRAY76*, *GRAY77*, *GRAY78*, *GRAY79*, *GRAY8*, *GRAY80*, *GRAY81*, *GRAY82*, *GRAY83*, *GRAY85*, *GRAY86*, *GRAY87*, *GRAY88*, *GRAY89*, *GRAY9*, *GRAY90*, *GRAY91*, *GRAY92*, *GRAY93*, *GRAY94*, *GRAY95*, *GREEN*, *GREEN1*, *GREEN2*, *GREEN3*, *GREEN4*, *GREENYELLOW*, *GRAY97*, *GRAY98*, *GRAY99*, *HONEYDEW*, *HONEYDEW2*, *HONEYDEW3*, *HONEYDEW4*, *HOTPINK*, *HOTPINK1*, *HOTPINK2*, *HOTPINK3*, *HOTPINK4*, *INDIANRED*, *INDIANRED1*, *INDIANRED2*, *INDIANRED3*, *INDIANRED4*, *IVORY*, *IVORY2*, *IVORY3*, *IVORY4*, *KHAKI*, *KHAKI1*, *KHAKI2*, *KHAKI3*, *KHAKI4*, *LAVENDER*, *LAVENDERBLUSH1*, *LAVENDERBLUSH2*, *LAVENDERBLUSH3*, *LAVENDERBLUSH4*, *LAWNGREEN*, *LEMONCHIFFON1*, *LEMONCHIFFON2*, *LEMONCHIFFON3*, *LEMONCHIFFON4*, *LIGHTBLUE*, *LIGHTBLUE1*, *LIGHTBLUE2*, *LIGHTBLUE3*, *LIGHTBLUE4*, *LIGHTCORAL*, *LIGHTCYAN1*, *LIGHTCYAN2*, *LIGHTCYAN3*, *LIGHTCYAN4*, *LIGHTGOLDENROD*, *LIGHTGOLDENROD1*, *LIGHTGOLDENROD2*, *LIGHTGOLDENROD3*, *LIGHTGOLDENROD4*, *LIGHTGOLDENRODYELLOW*, *LIGHTGRAY*, *LIGHTPINK*, *LIGHTPINK1*, *LIGHTPINK2*, *LIGHTPINK3*, *LIGHTPINK4*, *LIGHTSALMON1*, *LIGHTSALMON2*, *LIGHTSALMON3*, *LIGHTSALMON4*, *LIGHTSEAGREEN*, *LIGHTSKYBLUE*, *LIGHTSKYBLUE1*, *LIGHTSKYBLUE2*, *LIGHTSKYBLUE3*, *LIGHTSKYBLUE4*, *LIGHTSLATEBLUE*, *LIGHTSLATEGRAY*, *LIGHTSTEELBLUE*, *LIGHTSTEELBLUE1*, *LIGHTSTEELBLUE2*, *LIGHTSTEELBLUE3*, *LIGHTSTEELBLUE4*, *LIGHTYELLOW*, *LIGHTYELLOW2*, *LIGHTYELLOW3*, *LIGHTYELLOW4*, *LIMEGREEN*, *LINEN*, *MAGENTA1*, *MAGENTA2*, *MAGENTA3*, *MAGENTA4*, *MAROON*, *MAROON1*, *MAROON2*, *MAROON3*, *MAROON4*, *MEDIUMAQUAMARINE*, *MEDIUMORCHID*, *MEDIUMORCHID1*, *MEDIUMORCHID2*, *MEDIUMORCHID3*, *MEDIUMORCHID4*, *MEDIUMPURPLE*, *MEDIUMPURPLE1*, *MEDIUMPURPLE2*, *MEDIUMPURPLE3*, *MEDIUMPURPLE4*, *MEDIUMSEAGREEN*, *MEDIUMSLATEBLUE*, *MEDIUMSPRINGGREEN*, *MEDIUMTURQUOISE*, *MEDIUMVIOLETRED*, *MIDNIGHTBLUE*, *MINTCREAM*, *MISTYROSE*, *MISTYROSE2*, *MISTYROSE3*, *MISTYROSE4*, *MOCCASIN*, *NAVAJOWHITE1*, *NAVAJOWHITE2*, *NAVAJOWHITE3*, *NAVAJOWHITE4*, *NAVYBLUE*, *OLDLACE*, *OLIVEDRAB*, *OLIVEDRAB1*, *OLIVEDRAB2*, *OLIVEDRAB3*, *OLIVEDRAB4*, *ORANGE*, *ORANGE1*, *ORANGE2*, *ORANGE3*, *ORANGE4*, *ORANGERED*, *ORANGERED1*, *ORANGERED2*, *ORANGERED3*, *ORANGERED4*, *ORCHID*, *ORCHID1*, *ORCHID2*, *ORCHID3*, *ORCHID4*, *PALEGOLDENROD*, *PALEGREEN*, *PALEGREEN1*, *PALEGREEN2*, *PALEGREEN3*, *PALEGREEN4*, *PALETURQUOISE*, *PALETURQUOISE1*, *PALETURQUOISE2*, *PALETURQUOISE3*, *PALETURQUOISE4*, *PALEVIOLETRED*, *PALEVIOLETRED1*, *PALEVIOLETRED2*, *PALEVIOLETRED3*, *PALEVIOLETRED4*, *PAPAYAWHIP*, *PEACHPUFF*, *PEACHPUFF2*, *PEACHPUFF3*, *PEACHPUFF4*, *PERU*, *PINK*, *PINK1*, *PINK2*, *PINK3*, *PINK4*, *PLUM*, *PLUM1*, *PLUM2*, *PLUM3*, *PLUM4*, *POWDERBLUE*, *PURPLE*, *PURPLE1*, *PURPLE2*, *PURPLE3*, *PURPLE4*, *RED*, *RED1*, *RED2*, *RED3*, *RED4*, *ROSYBROWN*, *ROSYBROWN1*, *ROSYBROWN2*, *ROSYBROWN3*, *ROSYBROWN4*, *ROYALBLUE*, *ROYALBLUE1*, *ROYALBLUE2*, *ROYALBLUE3*, *ROYALBLUE4*, *SADDLEBROWN*, *SALMON*, *SALMON1*, *SALMON2*, *SALMON3*, *SALMON4*, *SANDYBROWN*, *SEAGREEN*, *SEAGREEN1*, *SEAGREEN2*, *SEAGREEN3*, *SEAGREEN4*, *SEASHELL*, *SEASHELL2*, *SEASHELL3*, *SEASHELL4*, *BEET*, *TEAL*, *SIENNA*, *SIENNA1*, *SIENNA2*, *SIENNA3*, *SIENNA4*, *SKYBLUE*, *SKYBLUE1*, *SKYBLUE2*, *SKYBLUE3*, *SKYBLUE4*, *SLATEBLUE*, *SLATEBLUE1*, *SLATEBLUE2*, *SLATEBLUE3*, *SLATEBLUE4*, *SLATEGRAY1*, *SLATEGRAY2*, *SLATEGRAY3*, *SLATEGRAY4*, *SLATEGRAY*, *SNOW*, *SNOW2*, *SNOW3*, *SNOW4*, *SPRINGGREEN*, *SPRINGGREEN2*, *SPRINGGREEN3*, *SPRINGGREEN4*, *STEELBLUE*, *STEELBLUE1*, *STEELBLUE2*, *STEELBLUE3*, *STEELBLUE4*, *TAN*, *TAN1*, *TAN2*, *TAN3*, *TAN4*, *THISTLE*, *THISTLE1*, *THISTLE2*, *THISTLE3*, *THISTLE4*, *TOMATO*, *TOMATO1*, *TOMATO2*, *TOMATO3*, *TOMATO4*, *TURQUOISE*, *TURQUOISE1*, *TURQUOISE2*, *TURQUOISE3*, *TURQUOISE4*, *VIOLET*, *VIOLETRED*, *VIOLETRED1*, *VIOLETRED2*, *VIOLETRED3*, *VIOLETRED4*, *WHEAT*, *WHEAT1*, *WHEAT2*, *WHEAT3*, *WHEAT4*, *WHITE*, *WHITESMOKE*, *YELLOW*, *YELLOW1*, *YELLOW2*, *YELLOW3*, *YELLOW4* and *YELLOWGREEN*.
-~~~~~
+~~~~{.php}
 vaspects    [name] [-setcolor ColorName] [-setcolor R G B] [-unsetcolor]
 vsetcolor   [name] ColorName
 vunsetcolor [name]
-~~~~~
+~~~~
 
 **Transparency. The *Transp* may be between 0.0 (opaque) and 1.0 (fully transparent).
 **Warning**: at 1.0 the shape becomes invisible.
-~~~~~
+~~~~{.php}
 vaspects           [name] [-settransparency Transp] [-unsettransparency]
 vsettransparency   [name] Transp
 vunsettransparency [name]
-~~~~~
+~~~~
 
 **Material**. The *MatName* can be *BRASS*, *BRONZE*, *COPPER*, *GOLD*, *PEWTER*, *PLASTER*, *PLASTIC*, *SILVER*, *STEEL*, *STONE*, *SHINY_PLASTIC*, *SATIN*, *METALIZED*, *NEON_GNC*, *CHROME*, *ALUMINIUM*, *OBSIDIAN*, *NEON_PHC*, *JADE*, *WATER*, *GLASS*, *DIAMOND* or *CHARCOAL*.
-~~~~~
+~~~~{.php}
 vaspects       [name] [-setmaterial MatName] [-unsetmaterial]
 vsetmaterial   [name] MatName
 vunsetmaterial [name]
-~~~~~
+~~~~
 
 **Line width**. Specifies width of the edges. The *LineWidth* may be between 0.0 and 10.0.
-~~~~~
+~~~~{.php}
 vaspects    [name] [-setwidth LineWidth] [-unsetwidth]
 vsetwidth   [name] LineWidth
 vunsetwidth [name]
-~~~~~
+~~~~
 
 **Example:**
-~~~~~
+~~~~{.php}
 vinit
 box b 10 10 10
 vdisplay b
@@ -1828,7 +1828,7 @@ vfit
 vsetdispmode b 1
 vaspects -setcolor red -settransparency 0.2
 vrotate 10 10 10
-~~~~~
+~~~~
 
 
 
@@ -1837,38 +1837,38 @@ vrotate 10 10 10
 
 @subsubsection occt_draw_4_3_11 vsetshading
 
-Syntax:                  
-~~~~~
+Syntax:
+~~~~{.php}
 vsetshading shapename [coefficient]
-~~~~
+~~~~
 
 Sets deflection coefficient that defines the quality of the shape’s representation in the shading mode. Default coefficient is 0.0008. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 vinit 
 psphere s 20 
 vdisplay s 
 vfit 
 vsetdispmode 1 
 vsetshading s 0.005
-~~~~~
+~~~~
  
 @subsubsection occt_draw_4_3_12 vunsetshading
 
-Syntax:                  
-~~~~~
+Syntax:
+~~~~{.php}
 vunsetshading [shapename]
-~~~~
+~~~~
 
 Sets default deflection coefficient (0.0008) that defines the quality of the shape’s representation in the shading mode.
 
 @subsubsection occt_draw_4_3_13 vsetam
 
-Syntax:                  
-~~~~~
+Syntax:
+~~~~{.php}
 vsetam [shapename] mode
-~~~~
+~~~~
 
 Activates selection mode for all selected or named shapes: 
 * *0* for *shape* itself, 
@@ -1881,55 +1881,55 @@ Activates selection mode for all selected or named shapes:
 * *7* (*compounds*).
  
 **Example:** 
-~~~~~
+~~~~{.php}
 vinit 
 box b 10 10 10 
 vdisplay b 
 vfit 
 vsetam b 2
-~~~~~
+~~~~
  
 @subsubsection occt_draw_4_3_14 vunsetam
 
-Syntax:                  
-~~~~~
+Syntax:
+~~~~{.php}
 vunsetam
-~~~~
+~~~~
 
 Deactivates all selection modes for all shapes. 
 
 @subsubsection occt_draw_4_3_15 vdump
 
-Syntax:                  
-~~~~~
+Syntax:
+~~~~{.php}
 vdump <filename>.{png|bmp|jpg|gif} [-width Width -height Height]
       [-buffer rgb|rgba|depth=rgb]
       [-stereo mono|left|right|blend|sideBySide|overUnder=mono]
 
-~~~~
+~~~~
 
 Extracts the contents of the viewer window to a image file.
 
 @subsubsection occt_draw_4_3_16 vdir
 
-Syntax:                  
-~~~~~
+Syntax:
+~~~~{.php}
 vdir
-~~~~
+~~~~
 
 Displays the list of displayed objects. 
 
 @subsubsection occt_draw_4_3_17 vsub
 
-Syntax:                  
-~~~~~
+Syntax:
+~~~~{.php}
 vsub 0/1(on/off)[shapename]
-~~~~
+~~~~
 
 Hilights/unhilights named or selected objects which are displayed at neutral state with subintensity color.
  
 **Example:** 
-~~~~~
+~~~~{.php}
 vinit 
 box b 10 10 10 
 psphere s 20 
@@ -1937,14 +1937,14 @@ vdisplay b s
 vfit 
 vsetdispmode 1 
 vsub b 1
-~~~~
+~~~~
 
 @subsubsection occt_draw_4_3_20 vsensdis
 
-Syntax:                  
-~~~~~
+Syntax:
+~~~~{.php}
 vsensdis
-~~~~
+~~~~
 
 Displays active entities (sensitive entities of one of the standard types corresponding to active selection modes). 
 
@@ -1961,34 +1961,34 @@ Custom (application-defined) sensitive entity types are not processed by this co
 
 @subsubsection occt_draw_4_3_21 vsensera
 
-Syntax:                  
-~~~~~
+Syntax:
+~~~~{.php}
 vsensera
-~~~~
+~~~~
 
 Erases active entities. 
 
 @subsubsection occt_draw_4_3_23 vr
 
-Syntax:                  
-~~~~~
+Syntax:
+~~~~{.php}
 vr filename
-~~~~
+~~~~
 
 Reads shape from BREP-format file and displays it in the viewer. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 vinit 
 vr myshape.brep
-~~~~~
+~~~~
  
 @subsubsection occt_draw_4_3_24 vstate
 
-Syntax:                  
-~~~~~
+Syntax:
+~~~~{.php}
 vstate [-entities] [-hasSelected] [name1] ... [nameN]
-~~~~
+~~~~
 
 Reports show/hidden state for selected or named objects:
  * *entities* -- prints low-level information about detected entities;
@@ -1997,21 +1997,21 @@ Reports show/hidden state for selected or named objects:
 @subsubsection occt_draw_4_3_25 vraytrace
 
 Syntax:
-~~~~~
+~~~~{.php}
 vraytrace [0/1]
-~~~~~
+~~~~
 
 Turns on/off ray tracing renderer.
 
 @subsubsection occt_draw_4_3_26 vrenderparams
 
 Syntax:
-~~~~~
+~~~~{.php}
 vrenderparams [-rayTrace|-raster] [-rayDepth 0..10] [-shadows {on|off}]
               [-reflections {on|off}] [-fsaa {on|off}] [-gleam {on|off}]
               [-gi {on|off}] [-brng {on|off}] [-env {on|off}]
               [-shadin {color|flat|gouraud|phong}]
-~~~~~
+~~~~
 
 Manages rendering parameters:
 * rayTrace     -- Enables  GPU ray-tracing
@@ -2030,46 +2030,46 @@ Unlike *vcaps*, these parameters dramatically change visual properties.
 The command is intended to control presentation quality depending on hardware capabilities and performance.
 
 **Example:**
-~~~~~
+~~~~{.php}
 vinit
 box b 10 10 10
 vdisplay b
 vfit
 vraytrace 1
 vrenderparams -shadows 1 -reflections 1 -fsaa 1
-~~~~~
+~~~~
 @subsubsection occt_draw_4_3_27 vshaderprog
 
 Syntax:
-~~~~~
+~~~~{.php}
    'vshaderprog [name] pathToVertexShader pathToFragmentShader'
 or 'vshaderprog [name] off'   to disable GLSL program
 or 'vshaderprog [name] phong' to enable per-pixel lighting calculations
-~~~~~
+~~~~
 
 Enables rendering using a shader program.
 
 @subsubsection occt_draw_4_3_28 vsetcolorbg
 
 Syntax:
-~~~~~
+~~~~{.php}
 vsetcolorbg r g b
-~~~~~
+~~~~
 
 Sets background color.
 
 **Example:**
-~~~~~
+~~~~{.php}
 vinit
 vsetcolorbg 200 0 200
-~~~~~
+~~~~
 
 @subsection occt_draw_4_4 AIS viewer -- object commands
 
 @subsubsection occt_draw_4_4_1 vtrihedron
 
-Syntax:                  
-~~~~~
+Syntax:
+~~~~{.php}
 vtrihedron name [-dispMode {wf|sh|wireframe|shading}]
                 [-origin x y z ]
                 [-zaxis u v w -xaxis u v w ]
@@ -2088,12 +2088,12 @@ vtrihedron name [-dispMode {wf|sh|wireframe|shading}]
                                         |YArrow|ZArrow|XOYAxis|YOZAxis"
                                         |XOZAxis|Whole} value]
 
-~~~~
+~~~~
 
 Creates a new *AIS_Trihedron* object or changes existing trihedron. If no argument is set, the default trihedron (0XYZ) is created.
 
 **Example:** 
-~~~~~
+~~~~{.php}
 vinit 
 vtrihedron tr1
 
@@ -2101,92 +2101,92 @@ vtrihedron t2 -dispmode shading -origin -200 -200 -300
 vtrihedron t2 -color XAxis Quantity_NOC_RED
 vtrihedron t2 -color YAxis Quantity_NOC_GREEN
 vtrihedron t2 -color ZAxis|Origin Quantity_NOC_BLUE1
-~~~~
+~~~~
 
 @subsubsection occt_draw_4_4_2 vplanetri
 
-Syntax:                  
-~~~~~
+Syntax:
+~~~~{.php}
 vplanetri name
-~~~~
+~~~~
 
 Creates a plane from a trihedron selection. If no arguments are set, the default plane is created. 
 
 
 @subsubsection occt_draw_4_4_3 vsize
 
-Syntax:                  
-~~~~~
+Syntax:
+~~~~{.php}
 vsize [name] [size]
-~~~~
+~~~~
 
 Changes the size of a named or selected trihedron. If the name is not defined: it affects the selected trihedrons otherwise nothing is done. If the value is not defined, it is set to 100 by default.
  
 **Example:** 
-~~~~~
+~~~~{.php}
 vinit 
 vtrihedron tr1 
 vtrihedron tr2 0 0 0 1 0 0 1 0 0 
 vsize tr2 400
-~~~~
+~~~~
 
 @subsubsection occt_draw_4_4_4 vaxis
 
-Syntax:                  
-~~~~~
+Syntax:
+~~~~{.php}
 vaxis name [Xa Ya Za Xb Yb Zb]
-~~~~
+~~~~
 
 Creates an axis. If  the values are not defined, an axis is created by interactive selection of two vertices or one edge
  
 **Example:** 
-~~~~~
+~~~~{.php}
 vinit 
 vtrihedron tr 
 vaxis axe1 0 0 0 1 0 0 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_4_4_5 vaxispara
 
-Syntax:                  
-~~~~~
+Syntax:
+~~~~{.php}
 vaxispara name
-~~~~
+~~~~
 
 Creates an axis by interactive selection of an edge and a vertex. 
 
 @subsubsection occt_draw_4_4_6 vaxisortho
 
-Syntax:                  
-~~~~~
+Syntax:
+~~~~{.php}
 vaxisotrho name
-~~~~
+~~~~
 
 Creates an axis by interactive selection of an edge and a vertex. The axis will be orthogonal to the selected edge. 
 
 @subsubsection occt_draw_4_4_7 vpoint
 
-Syntax:                  
-~~~~~
+Syntax:
+~~~~{.php}
 vpoint name [Xa Ya Za]
-~~~~
+~~~~
 
 Creates a point from coordinates. If the values are not defined, a point is created by interactive selection of a vertice or an edge (in the center of the edge). 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 vinit 
 vpoint p 0 0 0 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_4_4_8 vplane
 
-Syntax:                  
-~~~~~
+Syntax:
+~~~~{.php}
 vplane name [AxisName] [PointName] 
 vplane name [PointName] [PointName] [PointName] 
 vplane name [PlaneName] [PointName]
-~~~~
+~~~~
 
 Creates a plane from named or interactively selected entities.
 TypeOfSensitivity:
@@ -2194,87 +2194,87 @@ TypeOfSensitivity:
  * 1 -- Boundary
 
 **Example:** 
-~~~~~
+~~~~{.php}
 vinit 
 vpoint p1 0 50 0 
 vaxis axe1 0 0 0 0 0 1 
 vtrihedron tr 
 vplane plane1 axe1 p1 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_4_4_9 vplanepara
 
-Syntax:                  
-~~~~~
+Syntax:
+~~~~{.php}
 vplanepara name
-~~~~
+~~~~
 
 Creates a plane from interactively selected vertex and face. 
 
 @subsubsection occt_draw_4_4_10 vplaneortho
 
-Syntax:                  
-~~~~~
+Syntax:
+~~~~{.php}
 vplaneortho name
-~~~~
+~~~~
 
 Creates a plane from interactive selected face and coplanar edge. 
 
 @subsubsection occt_draw_4_4_11 vline
 
-Syntax:                  
-~~~~~
+Syntax:
+~~~~{.php}
 vline name [PointName] [PointName] 
 vline name [Xa Ya Za Xb Yb Zb]
-~~~~
+~~~~
 
 Creates a line from coordinates, named or interactively selected vertices. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 vinit 
 vtrihedron tr 
 vpoint p1 0 50 0 
 vpoint p2 50 0 0 
 vline line1 p1 p2 
 vline line2 0 0 0 50 0 1 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_4_4_12 vcircle
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 vcircle name [PointName PointName PointName IsFilled] 
 vcircle name [PlaneName PointName Radius IsFilled] 
-~~~~~
+~~~~
 
 Creates a circle from named or interactively selected entities.  Parameter IsFilled is defined as 0 or 1.
  
 **Example:** 
-~~~~~
+~~~~{.php}
 vinit 
 vtrihedron tr 
 vpoint p1 0 50 0 
 vpoint p2 50 0 0 
 vpoint p3 0 0 0 
 vcircle circle1 p1 p2 p3 1
-~~~~
+~~~~
 
 @subsubsection occt_draw_4_4_13 vtri2d
 
-Syntax:                  
-~~~~~
+Syntax:
+~~~~{.php}
 vtri2d name
-~~~~
+~~~~
 
 Creates a plane with a 2D trihedron from an interactively selected face. 
 
 @subsubsection occt_draw_4_4_14 vselmode
 
-Syntax:                  
-~~~~~
+Syntax:
+~~~~{.php}
 vselmode [object] mode_number is_turned_on=(1|0)
-~~~~
+~~~~
 
 Sets the selection mode for an object. If the object value is not defined, the selection mode is set for all displayed objects. 
 *Mode_number* is a non-negative integer encoding different interactive object classes.
@@ -2293,25 +2293,25 @@ For shapes the following *mode_number* values are allowed:
  * 0 if mode is to be switched off
 
 **Example:** 
-~~~~~
+~~~~{.php}
 vinit 
 vpoint p1 0 0 0 
 vpoint p2 50 0 0 
 vpoint p3 25 40 0 
 vtriangle triangle1 p1 p2 p3 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_4_4_15 vconnect
 
-Syntax:                  
-~~~~~
+Syntax:
+~~~~{.php}
 vconnect vconnect name Xo Yo Zo object1 object2 ... [color=NAME]
-~~~~
+~~~~
 
 Creates *AIS_ConnectedInteractive* object from the input object and location and displays it.
 
 **Example:** 
-~~~~~
+~~~~{.php}
 vinit 
 vpoint p1 0 0 0 
 vpoint p2 50 0 0 
@@ -2319,49 +2319,49 @@ vsegment segment p1 p2
 restore CrankArm.brep obj 
 vdisplay obj 
 vconnect new obj 100100100 1 0 0 0 0 1
-~~~~
+~~~~
 
 @subsubsection occt_draw_4_4_16 vtriangle
 
-Syntax:                  
-~~~~~
+Syntax:
+~~~~{.php}
 vtriangle name PointName PointName PointName
-~~~~
+~~~~
 
 Creates and displays a filled triangle from named points. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 vinit 
 vpoint p1 0 0 0 
 vpoint p2 50 0 0 
 vpoint p3 25 40 0 
 vtriangle triangle1 p1 p2 p3
-~~~~
+~~~~
 
 @subsubsection occt_draw_4_4_17 vsegment
 
-Syntax:                  
-~~~~~
+Syntax:
+~~~~{.php}
 vsegment name PointName PointName 
-~~~~~
+~~~~
 
 Creates and displays a segment from named points. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 Vinit 
 vpoint p1 0 0 0 
 vpoint p2 50 0 0 
 vsegment segment p1 p2 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_4_4_18 vpointcloud
 
 Syntax:
-~~~~~
+~~~~{.php}
 vpointcloud name shape [-randColor] [-normals] [-noNormals]
-~~~~~
+~~~~
 
 Creates an interactive object for an arbitrary set of points from the triangulated shape.
 Additional options:
@@ -2369,9 +2369,9 @@ Additional options:
  * *normals*   -- generates a normal per point (default);
  * *noNormals* -- does not generate a normal per point.
 
-~~~~~
+~~~~{.php}
 vpointcloud name x y z r npts {surface|volume} [-randColor] [-normals] [-noNormals]
-~~~~~
+~~~~
 Creates an arbitrary set of points (npts) randomly distributed on a spheric surface or within a spheric volume (x y z r).
 Additional options:
  * *randColor* -- generates a random color per point;
@@ -2379,16 +2379,16 @@ Additional options:
  * *noNormals* -- does not generate a normal per point.
 
 **Example:**
-~~~~~
+~~~~{.php}
 vinit
 vpointcloud pc 0 0 0 100 100000 surface -randColor
 vfit
-~~~~~
+~~~~
 
 @subsubsection occt_draw_4_4_19 vclipplane
 
 Syntax:
-~~~~~
+~~~~{.php}
 vclipplane maxplanes <view_name> -- gets plane limit for the view.
 vclipplane create <plane_name> -- creates a new plane.
 vclipplane delete <plane_name> -- deletes a plane.
@@ -2404,12 +2404,12 @@ vclipplane change <plane_name> capping texscale <sx> <sy> -- sets texture scale.
 vclipplane change <plane_name> capping texorigin <tx> <ty> -- sets texture origin.
 vclipplane change <plane_name> capping texrotate <angle> -- sets texture rotation.
 vclipplane change <plane_name> capping hatch on/off/<id> -- sets hatching mask.
-~~~~~
+~~~~
 
 Manages clipping planes
 
 **Example:**
-~~~~~
+~~~~{.php}
 vinit
 vclipplane create pln1
 vclipplane change pln1 equation 1 0 0 -0.1
@@ -2420,12 +2420,12 @@ vsetdispmode 1
 vfit
 vrotate 10 10 10
 vselect 100 100
-~~~~~
+~~~~
 
 @subsubsection occt_draw_4_4_20 vdimension
 
 Syntax:
-~~~~~
+~~~~{.php}
 vdimension name {-angle|-length|-radius|-diameter} -shapes shape1 [shape2 [shape3]]
                 [-text 3d|2d wf|sh|wireframe|shading IntegerSize]
                 [-label left|right|hcenter|hfit top|bottom|vcenter|vfit]
@@ -2435,14 +2435,14 @@ vdimension name {-angle|-length|-radius|-diameter} -shapes shape1 [shape2 [shape
                                [-autovalue] [-value CustomRealValue] [-textvalue CustomTextValue]
                 [-dispunits DisplayUnitsString]
                 [-modelunits ModelUnitsString] [-showunits | -hideunits]
-~~~~~
+~~~~
 
 Builds angle, length, radius or diameter dimension interactive object **name**.
 
 **Attention:** length dimension can't be built without working plane.
 
 **Example:** 
-~~~~~
+~~~~{.php}
 vinit
 vpoint p1 0 0 0
 vpoint p2 50 50 0
@@ -2454,12 +2454,12 @@ vdimension dim2 -angle -shapes p1 p2 p3
 vcircle circle p1 p2 p3 0
 vdimension dim3 -radius -shapes circle
 vfit
-~~~~~
+~~~~
 
 @subsubsection occt_draw_4_4_21 vdimparam
 
 Syntax:
-~~~~~
+~~~~{.php}
 vdimparam name [-text 3d|2d wf|sh|wireframe|shading IntegerSize]
                [-label left|right|hcenter|hfit top|bottom|vcenter|vfit]
                [-arrow external|internal|fit]
@@ -2473,12 +2473,12 @@ vdimparam name [-text 3d|2d wf|sh|wireframe|shading IntegerSize]
                [-dispunits DisplayUnitsString]
                [-modelunits ModelUnitsString]
                [-showunits | -hideunits]
-~~~~~
+~~~~
 
 Sets parameters for angle, length, radius and diameter dimension **name**.
 
 **Example:** 
-~~~~~
+~~~~{.php}
 vinit
 vpoint p1 0 0 0
 vpoint p2 50 50 0
@@ -2487,20 +2487,20 @@ vdimparam dim1 -flyout -15 -arrowlength 4 -showunits -value 10
 vfit
 vdimparam dim1 -textvalue "w_1"
 vdimparam dim1 -autovalue
-~~~~~
+~~~~
 
 @subsubsection occt_draw_4_4_22 vangleparam
 
 Syntax:
-~~~~~
+~~~~{.php}
 vangleparam name [-type interior|exterior]
                  [-showarrow first|second|both|none]
-~~~~~
+~~~~
 
 Sets parameters for angle dimension **name**.
 
 **Example:** 
-~~~~~
+~~~~{.php}
 vinit
 vpoint p1 0 0 0
 vpoint p2 10 0 0
@@ -2508,20 +2508,20 @@ vpoint p3 10 5 0
 vdimension dim1 -angle -plane xoy -shapes p1 p2 p3
 vfit
 vangleparam dim1 -type exterior -showarrow first
-~~~~~
+~~~~
 
 @subsubsection occt_draw_4_4_23 vlengthparam
 
 Syntax:
-~~~~~
+~~~~{.php}
 vlengthparam name [-type interior|exterior]
                   [-showarrow first|second|both|none]
-~~~~~
+~~~~
 
 Sets parameters for length dimension **name**.
 
 **Example:** 
-~~~~~
+~~~~{.php}
 vinit
 vpoint p1 20 20 0
 vpoint p2 80 80 0
@@ -2530,14 +2530,14 @@ vtop
 vfit
 vzoom 0.5
 vlengthparam dim1 -direction ox
-~~~~~
+~~~~
 
 @subsubsection occt_draw_4_4_24 vmovedim
 
 Syntax:
-~~~~~
+~~~~{.php}
 vmovedim [name] [x y z]
-~~~~~
+~~~~
 
 Moves picked or named (if **name** parameter is defined) dimension
 to picked mouse position or input point with coordinates **x**,**y**,**z**.
@@ -2545,13 +2545,13 @@ Text label of dimension **name** is moved to position, another parts of dimensio
 are adjusted.
 
 **Example:** 
-~~~~~
+~~~~{.php}
 vinit
 vpoint p1 0 0 0
 vpoint p2 50 50 0
 vdimension dim1 -length -plane xoy -shapes p1 p2
 vmovedim dim1 -10 30 0
-~~~~~
+~~~~
 
 
 @subsection occt_draw_4_5 AIS viewer -- Mesh Visualization Service
@@ -2560,24 +2560,24 @@ vmovedim dim1 -10 30 0
 
 @subsubsection occt_draw_4_5_1 meshfromstl
 
-Syntax:                  
-~~~~~
+Syntax:
+~~~~{.php}
 meshfromstl meshname file
-~~~~
+~~~~
 
 Creates a *MeshVS_Mesh* object based on STL file data. The object will be displayed immediately.
  
 **Example:**
-~~~~
+~~~~{.php}
 meshfromstl mesh myfile.stl
-~~~~
+~~~~
 
 @subsubsection occt_draw_4_5_2 meshdispmode
 
-Syntax:                  
-~~~~~
+Syntax:
+~~~~{.php}
 meshdispmode meshname displaymode
-~~~~
+~~~~
 
 Changes the display mode of object **meshname**. The **displaymode** is integer, which can be:
 * *1* for *wireframe*, 
@@ -2585,18 +2585,18 @@ Changes the display mode of object **meshname**. The **displaymode** is integer,
 * *3* for *shrink* mode. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 vinit 
 meshfromstl mesh myfile.stl 
 meshdispmode mesh 2
-~~~~
+~~~~
 
 @subsubsection occt_draw_4_5_3 meshselmode
 
-Syntax:                  
-~~~~~
+Syntax:
+~~~~{.php}
 meshselmode meshname selectionmode
-~~~~
+~~~~
 
 Changes the selection mode of object **meshname**. The *selectionmode* is integer OR-combination of mode flags. The basic flags are the following: 
 * *1* -- node selection;
@@ -2605,50 +2605,50 @@ Changes the selection mode of object **meshname**. The *selectionmode* is intege
 * *8* -- faces.
  
 **Example:** 
-~~~~~
+~~~~{.php}
 vinit 
 meshfromstl mesh myfile.stl 
 meshselmode mesh 1
-~~~~
+~~~~
 
 @subsubsection occt_draw_4_5_4 meshshadcolor
 
-Syntax:                  
-~~~~~
+Syntax:
+~~~~{.php}
 meshshadcolor meshname red green blue
-~~~~
+~~~~
 
 Changes the face interior color of object **meshname**. The *red*, *green* and *blue* are real values between *0* and *1*.
  
 **Example:** 
-~~~~~
+~~~~{.php}
 vinit 
 meshfromstl mesh myfile.stl 
 meshshadcolormode mesh 0.5 0.5 0.5
-~~~~
+~~~~
 
 @subsubsection occt_draw_4_5_5 meshlinkcolor
 
-Syntax:                  
-~~~~~
+Syntax:
+~~~~{.php}
 meshlinkcolor meshname red green blue
-~~~~
+~~~~
 
 Changes the color of face borders for object **meshname**. The *red*, *green* and *blue* are real values between *0* and *1*.
  
 **Example:** 
-~~~~~
+~~~~{.php}
 vinit 
 meshfromstl mesh myfile.stl 
 meshlinkcolormode mesh 0.5 0.5 0.5
-~~~~
+~~~~
 
 @subsubsection occt_draw_4_5_6 meshmat
 
-Syntax:                  
-~~~~~
+Syntax:
+~~~~{.php}
 meshmat meshname material
-~~~~
+~~~~
 
 Changes the material of object **meshname**.
 
@@ -2676,117 +2676,117 @@ Changes the material of object **meshname**.
 * *20 -- UserDefined*
  
 **Example:** 
-~~~~~
+~~~~{.php}
 vinit 
 meshfromstl mesh myfile.stl 
 meshmat mesh JADE 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_4_5_7 meshshrcoef
 
-Syntax:                  
-~~~~~
+Syntax:
+~~~~{.php}
 meshshrcoef meshname shrinkcoefficient
-~~~~
+~~~~
 
 Changes the value of shrink coefficient used in the shrink mode. In the shrink mode the face is shown as a congruent part of a usual face, so that *shrinkcoefficient* controls the value of this part. The *shrinkcoefficient* is a positive real number.
  
 **Example:** 
-~~~~~
+~~~~{.php}
 vinit 
 meshfromstl mesh myfile.stl 
 meshshrcoef mesh 0.05
-~~~~
+~~~~
 
 @subsubsection occt_draw_4_5_8 meshshow
 
-Syntax:                  
-~~~~~
+Syntax:
+~~~~{.php}
 meshshow meshname
-~~~~
+~~~~
 
 Displays **meshname** in the viewer (if it is erased).
  
 **Example:** 
-~~~~~
+~~~~{.php}
 vinit 
 meshfromstl mesh myfile.stl 
 meshshow mesh
-~~~~
+~~~~
 
 @subsubsection occt_draw_4_5_9 meshhide
 
-Syntax:                  
-~~~~~
+Syntax:
+~~~~{.php}
 meshhide meshname
-~~~~
+~~~~
 
 Hides **meshname** in the viewer. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 vinit 
 meshfromstl mesh myfile.stl 
 meshhide mesh
-~~~~
+~~~~
 
 @subsubsection occt_draw_4_5_10 meshhidesel
 
-Syntax:                  
-~~~~~
+Syntax:
+~~~~{.php}
 meshhidesel meshname
-~~~~
+~~~~
 
 Hides only selected entities. The other part of **meshname** remains visible. 
 
 @subsubsection occt_draw_4_5_11 meshshowsel
 
-Syntax:                  
-~~~~~
+Syntax:
+~~~~{.php}
 meshshowsel meshname
-~~~~
+~~~~
 
 Shows only selected entities. The other part of **meshname** becomes invisible. 
 
 @subsubsection occt_draw_4_5_12 meshshowall
 
-Syntax:                  
-~~~~~
+Syntax:
+~~~~{.php}
 meshshowall meshname
-~~~~
+~~~~
 
 Changes the state of all entities to visible for **meshname**. 
 
 @subsubsection occt_draw_4_5_13 meshdelete
 
-Syntax:                  
-~~~~~
+Syntax:
+~~~~{.php}
 meshdelete meshname
-~~~~
+~~~~
 
 Deletes MeshVS_Mesh object **meshname**. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 vinit 
 meshfromstl mesh myfile.stl 
 meshdelete mesh 
-~~~~~
+~~~~
 
 @subsection occt_draw_4_6      VIS Viewer commands
 
 A specific plugin with alias *VIS* should be loaded to have access to VIS functionality in DRAW Test Harness:
 
-~~~~
+~~~~{.php}
 \> pload VIS
 ~~~~
 
 @subsubsection occt_draw_4_6_1 ivtkinit
 
 Syntax:
-~~~~~
+~~~~{.php}
 ivtkinit
-~~~~~
+~~~~
 
 Creates a window for VTK viewer.
 
@@ -2795,19 +2795,19 @@ Creates a window for VTK viewer.
 @subsubsection occt_draw_4_6_2 ivtkdisplay
 
 Syntax:
-~~~~~
+~~~~{.php}
 ivtkdisplay name1 [name2] …[name n]
-~~~~~
+~~~~
 
 Displays named objects.
 
 **Example:** 
-~~~~~
+~~~~{.php}
 ivtkinit
 # create cone
 pcone c 5 0 10
 ivtkdisplay c
-~~~~~
+~~~~
 
 @figure{/user_guides/draw_test_harness/images/draw_image002.png,"",261}
 
@@ -2815,14 +2815,14 @@ ivtkdisplay c
 @subsubsection occt_draw_4_6_3 ivtkerase
 
 Syntax:
-~~~~~
+~~~~{.php}
 ivtkerase [name1] [name2] … [name n]
-~~~~~
+~~~~
 
 Erases named objects. If no arguments are passed, erases all displayed objects.
 
 **Example:**
-~~~~~
+~~~~{.php}
 ivtkinit
 # create a sphere
 psphere s 10
@@ -2836,29 +2836,29 @@ ivtkdisplay s c cy
 ivtkerase cy
 # erase the sphere and the cone
 ivtkerase s c
-~~~~~
+~~~~
 
 @subsubsection occt_draw_4_6_4  ivtkfit
 
 Syntax:
-~~~~~
+~~~~{.php}
 ivtkfit
-~~~~~
+~~~~
 
 Automatic zoom/panning.
 
 @subsubsection occt_draw_4_6_5 ivtkdispmode
 
 Syntax:
-~~~~~
+~~~~{.php}
 ivtksetdispmode [name] {0|1}
-~~~~~
+~~~~
 
 Sets display mode for a named object. If no arguments are passed, sets the given display mode for all displayed objects
 The possible modes are: 0 (WireFrame) and 1 (Shading).
 
 **Example:**
-~~~~~
+~~~~{.php}
 ivtkinit
 # create a cone
 pcone c 5 0 10
@@ -2866,21 +2866,21 @@ pcone c 5 0 10
 ivtkdisplay c
 # set shading mode for the cone
 ivtksetdispmode c 1
-~~~~~
+~~~~
 
 @figure{/user_guides/draw_test_harness/images/draw_image003.png,"",262}
 
 @subsubsection occt_draw_4_6_6 ivtksetselmode
 
 Syntax:
-~~~~~
+~~~~{.php}
 ivtksetselmode [name] mode {0|1}
-~~~~~
+~~~~
 
 Sets selection mode for a named object. If no arguments are passed, sets the given selection mode for all the displayed objects.
 
 **Example:**
-~~~~~
+~~~~{.php}
 ivtkinit
 # load a shape from file
 restore CrankArm.brep a
@@ -2888,50 +2888,50 @@ restore CrankArm.brep a
 ivtkdisplay a
 # set the face selection mode
 ivtksetselmode a 4 1
-~~~~~
+~~~~
 
 @figure{/user_guides/draw_test_harness/images/draw_image004.png,"",291}
  
 @subsubsection occt_draw_4_6_7 ivtkmoveto
 
 Syntax:
-~~~~~
+~~~~{.php}
 ivtkmoveto x y
-~~~~~
+~~~~
 
 Imitates mouse cursor moving to point with the given display coordinates **x**,**y**.
 
 **Example:**
-~~~~~
+~~~~{.php}
 ivtkinit
 pcone c 5 0 10
 ivtkdisplay c
 ivtkmoveto 40 50
-~~~~~
+~~~~
 
 @subsubsection occt_draw_4_6_8 ivtkselect
 
 Syntax:
-~~~~~
+~~~~{.php}
 ivtkselect x y
-~~~~~
+~~~~
 
 Imitates mouse cursor moving to point with the given display coordinates and performs selection at this point.
 
 **Example:**
-~~~~~
+~~~~{.php}
 ivtkinit
 pcone c 5 0 10
 ivtkdisplay c
 ivtkselect 40 50
-~~~~~
+~~~~
 
 @subsubsection occt_draw_4_6_9 ivtkdump
 
 Syntax:
-~~~~~
+~~~~{.php}
 ivtkdump *filename* [buffer={rgb|rgba|depth}] [width height] [stereoproj={L|R}]
-~~~~~
+~~~~
 
 Dumps the contents of VTK viewer to image. It supports:
 * dumping in different raster graphics formats: PNG, BMP, JPEG, TIFF or PNM.
@@ -2940,34 +2940,34 @@ Dumps the contents of VTK viewer to image. It supports:
 * dumping of stereo projections (left or right).
 
 **Example:**
-~~~~~
+~~~~{.php}
 ivtkinit
 pcone c 5 0 10
 ivtkdisplay c
 ivtkdump D:/ConeSnapshot.png rgb 768 768
-~~~~~
+~~~~
 
 @subsubsection occt_draw_4_6_10        ivtkbgcolor
 
 
 Syntax:
-~~~~~
+~~~~{.php}
 ivtkbgcolor r g b [r2 g2 b2]
-~~~~~
+~~~~
 
 Sets uniform background color or gradient background if second triple of parameters is set. Color parameters r,g,b have to be chosen in the interval  [0..255].
 
 **Example:**
-~~~~~
+~~~~{.php}
 ivtkinit
 ivtkbgcolor 200 220 250
-~~~~~
+~~~~
  
 @figure{/user_guides/draw_test_harness/images/draw_image005.png,"",196}
 
-~~~~~
+~~~~{.php}
 ivtkbgcolor 10 30 80 255 255 255
-~~~~~
+~~~~
 
 @figure{/user_guides/draw_test_harness/images/draw_image006.png,"",190}
 
@@ -2981,354 +2981,354 @@ This chapter contains a set of commands for Open CASCADE Technology Application
 
 @subsubsection occt_draw_5_1_1 NewDocument
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 NewDocument docname [format]
-~~~~
+~~~~
 
 Creates a new **docname** document with MDTV-Standard or described format. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # Create new document with default (MDTV-Standard) format 
 NewDocument D 
 
 # Create new document with BinOcaf format 
 NewDocument D2 BinOcaf 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_5_1_2 IsInSession
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 IsInSession path
-~~~~
+~~~~
 
 Returns *0*, if **path** document is managed by the application session, *1* -- otherwise. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 IsInSession /myPath/myFile.std 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_5_1_3 ListDocuments
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 ListDocuments
-~~~~
+~~~~
 
 Makes a list of documents handled during the session of the application. 
 
 
 @subsubsection occt_draw_5_1_4 Open
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 Open path docname [-stream]
-~~~~
+~~~~
 
 Retrieves the document of file **docname** in the path **path**. Overwrites the document, if it is already in session. 
 
 option <i>-stream</i> activates usage of alternative interface of OCAF persistence working with C++ streams instead of file names.
 
 **Example:** 
-~~~~~
+~~~~{.php}
 Open /myPath/myFile.std D
-~~~~
+~~~~
 
 @subsubsection occt_draw_5_1_5 Close
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 Close docname
-~~~~
+~~~~
 
 Closes **docname** document. The document is no longer handled by the applicative session. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 Close D 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_5_1_6 Save
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 Save docname
-~~~~
+~~~~
 
 Saves **docname** active document. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 Save D 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_5_1_7 SaveAs
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 SaveAs docname path [-stream]
-~~~~
+~~~~
 
 Saves the active document in the file **docname** in the path **path**. Overwrites the file if it already exists.
 
 option <i>-stream</i> activates usage of alternative interface of OCAF persistence working with C++ streams instead of file names.
 
 **Example:** 
-~~~~~
+~~~~{.php}
 SaveAs D /myPath/myFile.std
-~~~~
+~~~~
 
 @subsection occt_draw_5_2 Basic commands
 
 @subsubsection occt_draw_5_2_1 Label
 
-Syntax:   
+Syntax:
 
-~~~~~
+~~~~{.php}
 Label docname entry
-~~~~~
+~~~~
 
 Creates the label expressed by <i>\<entry\></i> if it does not exist.
 
 Example
-~~~~~
+~~~~{.php}
 Label D 0:2
-~~~~~
+~~~~
 
 @subsubsection occt_draw_5_2_2 NewChild
 
-Syntax:   
+Syntax:
 
-~~~~~
+~~~~{.php}
 NewChild docname [taggerlabel = Root label]
-~~~~~
+~~~~
 Finds (or creates) a *TagSource* attribute located at father label of <i>\<taggerlabel\></i> and makes a new child label.
 
 Example
-~~~~~
+~~~~{.php}
 # Create new child of root label
 NewChild D
 
 # Create new child of existing label
 Label D 0:2
 NewChild D 0:2
-~~~~~
+~~~~
 
 @subsubsection occt_draw_5_2_3 Children
 
-Syntax:  
-~~~~~
+Syntax:
+~~~~{.php}
 Children docname label
-~~~~~
+~~~~
 Returns the list of attributes of label.
 
 Example
-~~~~~
+~~~~{.php}
 Children D 0:2
-~~~~~
+~~~~
 
 @subsubsection occt_draw_5_2_4 ForgetAll
 
-Syntax:   
-~~~~~
+Syntax:
+~~~~{.php}
 ForgetAll docname label
-~~~~~
+~~~~
 Forgets all attributes of the label.
 
 Example
-~~~~~
+~~~~{.php}
 ForgetAll D 0:2
-~~~~~
+~~~~
 
 
 @subsubsection occt_draw_5_3 Application commands
 
 @subsubsection occt_draw_5_3_1  Main
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 Main docname
-~~~~
+~~~~
 
 Returns the main label of the framework. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 Main D 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_5_3_2  UndoLimit
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 UndoLimit docname [value=0]
-~~~~
+~~~~
 
 
 Sets the limit on the number of Undo Delta stored. **0** will disable Undo on the document. A negative *value* means that there is no limit. Note that by default Undo is disabled. Enabling it will take effect with the next call to *NewCommand*. Of course, this limit is the same for Redo 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 UndoLimit D 100 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_5_3_3  Undo
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 Undo docname [value=1]
-~~~~
+~~~~
 
 Undoes **value** steps. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 Undo D 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_5_3_4  Redo
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 Redo docname [value=1]
-~~~~
+~~~~
 
 Redoes **value** steps.
  
 **Example:** 
-~~~~~
+~~~~{.php}
 Redo D 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_5_3_5  OpenCommand
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 OpenCommand docname
-~~~~
+~~~~
 
 Opens a new command transaction. 
 
 **Example:**
-~~~~
+~~~~{.php}
 OpenCommand D
-~~~~
+~~~~
 
 @subsubsection occt_draw_5_3_6  CommitCommand
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 CommitCommand docname
-~~~~
+~~~~
 
 Commits the Command transaction. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 CommitCommand D
-~~~~
+~~~~
 
 @subsubsection occt_draw_5_3_7  NewCommand
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 NewCommand docname
-~~~~
+~~~~
 
 This is a shortcut for Commit and Open transaction. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 NewCommand D 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_5_3_8  AbortCommand
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 AbortCommand docname
-~~~~
+~~~~
 
 Aborts the Command transaction. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 AbortCommand D 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_5_3_9  Copy
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 Copy docname entry Xdocname Xentry
-~~~~
+~~~~
 
 Copies the contents of *entry* to *Xentry*. No links are registered. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 Copy D1 0:2 D2 0:4 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_5_3_10  UpdateLink
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 UpdateLink docname [entry] 
-~~~~~
+~~~~
 
 Updates external reference set at *entry*. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 UpdateLink D 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_5_3_11  CopyWithLink
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 CopyWithLink docname entry Xdocname Xentry
-~~~~
+~~~~
 
 Aborts the Command transaction. 
 Copies the content of *entry* to *Xentry*. The link is registered with an *Xlink* attribute at *Xentry*  label. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 CopyWithLink D1 0:2 D2 0:4
-~~~~
+~~~~
 
 @subsubsection occt_draw_5_3_12  UpdateXLinks
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 UpdateXLinks docname entry
-~~~~
+~~~~
 
 Sets modifications on labels impacted by external references to the *entry*. The *document* becomes invalid and must be recomputed 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 UpdateXLinks D 0:2 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_5_3_13  DumpDocument
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 DumpDocument docname
-~~~~
+~~~~
 
 Displays parameters of *docname* document. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 DumpDocument D 
-~~~~~
+~~~~
 
 
 @subsection occt_draw_5_4  Data Framework commands
@@ -3336,545 +3336,545 @@ DumpDocument D
 
 @subsubsection occt_draw_5_4_1  MakeDF
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 MakeDF dfname
-~~~~
+~~~~
 
 Creates a new data framework. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 MakeDF D 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_5_4_2  ClearDF
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 ClearDF dfname
-~~~~
+~~~~
 
 Clears a data framework. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 ClearDF D 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_5_4_3  CopyDF
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 CopyDF dfname1 entry1 [dfname2] entry2
-~~~~
+~~~~
 
 Copies a data framework. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 CopyDF D 0:2 0:4 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_5_4_4  CopyLabel
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 CopyLabel dfname fromlabel tolablel
-~~~~
+~~~~
 
 Copies a label. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 CopyLabel D1 0:2 0:4 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_5_4_5  MiniDumpDF
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 MiniDumpDF dfname
-~~~~
+~~~~
 
 Makes a mini-dump of a data framework. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 MiniDumpDF D 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_5_4_6  XDumpDF
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 XDumpDF dfname
-~~~~
+~~~~
 
 Makes an extended dump of a data framework. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 XDumpDF D
-~~~~
+~~~~
 
 @subsection occt_draw_5_5  General attributes commands
 
 
 @subsubsection occt_draw_5_5_1  SetInteger
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 SetInteger dfname entry value
-~~~~
+~~~~
 
 Finds or creates an Integer attribute at *entry* label and sets *value*. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 SetInteger D 0:2 100 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_5_5_2  GetInteger
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 GetInteger dfname entry [drawname]
-~~~~
+~~~~
 
 Gets a value of an Integer attribute at *entry* label and sets it to *drawname* variable, if it is defined. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 GetInteger D 0:2 Int1 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_5_5_3  SetReal
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 SetReal dfname entry value
-~~~~
+~~~~
 
 Finds or creates a Real attribute at *entry* label and sets *value*. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 SetReal D 0:2 100. 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_5_5_4  GetReal
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 GetReal dfname entry [drawname]
-~~~~
+~~~~
 
 Gets a value of a Real attribute at *entry* label and sets it to *drawname* variable, if it is defined. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 GetReal D 0:2 Real1 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_5_5_5  SetIntArray
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 SetIntArray dfname entry lower upper value1 value2 … 
-~~~~~
+~~~~
 
 Finds or creates an IntegerArray attribute at *entry* label with lower and upper bounds and sets **value1*, *value2*... 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 SetIntArray D 0:2 1 4 100 200 300 400
-~~~~
+~~~~
 
 @subsubsection occt_draw_5_5_6  GetIntArray
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 GetIntArray dfname entry
-~~~~
+~~~~
 
 Gets a value of an *IntegerArray* attribute at *entry* label. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 GetIntArray D 0:2
-~~~~
+~~~~
 
 @subsubsection occt_draw_5_5_7  SetRealArray
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 SetRealArray dfname entry lower upper value1 value2 …
-~~~~
+~~~~
 
 Finds or creates a RealArray attribute at *entry* label with lower and upper bounds and sets *value1*, *value2*… 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 GetRealArray D 0:2 1 4 100. 200. 300. 400. 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_5_5_8  GetRealArray
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 GetRealArray dfname entry
-~~~~
+~~~~
 
 Gets a value of a RealArray attribute at *entry* label. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 GetRealArray D 0:2 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_5_5_9  SetComment
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 SetComment dfname entry value
-~~~~
+~~~~
 
 Finds or creates a Comment attribute at *entry* label and sets *value*. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 SetComment D 0:2 "My comment"
-~~~~
+~~~~
 
 @subsubsection occt_draw_5_5_10  GetComment
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 GetComment dfname entry
-~~~~
+~~~~
 
 Gets a value of a Comment attribute at *entry* label. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 GetComment D 0:2
-~~~~
+~~~~
 
 @subsubsection occt_draw_5_5_11  SetExtStringArray
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 SetExtStringArray dfname entry lower upper value1 value2 …
-~~~~
+~~~~
 
 Finds or creates an *ExtStringArray* attribute at *entry* label with lower and upper bounds and sets *value1*, *value2*… 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 SetExtStringArray D 0:2 1 3 *string1* *string2* *string3*
-~~~~
+~~~~
 
 @subsubsection occt_draw_5_5_12  GetExtStringArray
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 GetExtStringArray dfname entry
-~~~~
+~~~~
 
 Gets a value of an ExtStringArray attribute at *entry* label. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 GetExtStringArray D 0:2 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_5_5_13  SetName
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 SetName dfname entry value 
-~~~~~
+~~~~
 
 Finds or creates a Name attribute at *entry* label and sets *value*. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 SetName D 0:2 *My name* 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_5_5_14  GetName
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 GetName dfname entry 
-~~~~~
+~~~~
 
 Gets a value of a Name attribute at *entry* label. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 GetName D 0:2 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_5_5_15  SetReference
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 SetReference dfname entry reference 
-~~~~~
+~~~~
 
 Creates a Reference attribute at *entry* label and sets *reference*. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 SetReference D 0:2 0:4 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_5_5_16  GetReference
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 GetReference dfname entry 
-~~~~~
+~~~~
 
 Gets a value of a Reference attribute at *entry* label. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 GetReference D 0:2 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_5_5_17  SetUAttribute
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 SetUAttribute dfname entry localGUID 
-~~~~~
+~~~~
 
 Creates a UAttribute attribute at *entry* label with *localGUID*. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 set localGUID "c73bd076-22ee-11d2-acde-080009dc4422" 
 SetUAttribute D 0:2 ${localGUID} 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_5_5_18  GetUAttribute
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 GetUAttribute dfname entry loacalGUID 
-~~~~~
+~~~~
 
 Finds a *UAttribute* at *entry* label with *localGUID*. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 set localGUID "c73bd076-22ee-11d2-acde-080009dc4422" 
 GetUAttribute D 0:2 ${localGUID} 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_5_5_19  SetFunction
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 SetFunction dfname entry ID failure 
-~~~~~
+~~~~
 
 Finds or creates a *Function* attribute at *entry* label with driver ID and *failure* index. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 set ID "c73bd076-22ee-11d2-acde-080009dc4422" 
 SetFunction D 0:2 ${ID} 1 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_5_5_20  GetFunction
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 GetFunction dfname entry ID failure 
-~~~~~
+~~~~
 
 Finds a Function attribute at *entry* label and sets driver ID to *ID* variable and failure index to *failure* variable. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 GetFunction D 0:2 ID failure 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_5_5_21  NewShape
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 NewShape dfname entry [shape] 
-~~~~~
+~~~~
 
 Finds or creates a Shape attribute at *entry* label. Creates or updates the associated *NamedShape* attribute by *shape* if *shape* is defined. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 box b 10 10 10 
 NewShape D 0:2 b 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_5_5_22  SetShape
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 SetShape dfname entry shape 
-~~~~~
+~~~~
 
 Creates or updates a *NamedShape* attribute at *entry* label by *shape*. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 box b 10 10 10 
 SetShape D 0:2 b 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_5_5_23  GetShape
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 GetShape2 dfname entry shape 
-~~~~~
+~~~~
 
 Sets a shape from NamedShape attribute associated with *entry* label to *shape* draw variable. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 GetShape2 D 0:2 b 
-~~~~~
+~~~~
 
 @subsection occt_draw_5_6  Geometric attributes commands
 
 
 @subsubsection occt_draw_5_6_1  SetPoint
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 SetPoint dfname entry point
-~~~~
+~~~~
 
 Finds or creates a Point attribute at *entry* label and sets *point* as generated in the associated *NamedShape* attribute. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 point p 10 10 10 
 SetPoint D 0:2 p 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_5_6_2  GetPoint
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 GetPoint dfname entry [drawname] 
-~~~~~
+~~~~
 
 Gets a vertex from *NamedShape* attribute at *entry* label and sets it to *drawname* variable, if it is defined. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 GetPoint D 0:2 p 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_5_6_3  SetAxis
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 SetAxis dfname entry axis 
-~~~~~
+~~~~
 
 Finds or creates an Axis attribute at *entry* label and sets *axis* as generated in the associated *NamedShape* attribute. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 line l 10 20 30 100 200 300 
 SetAxis D 0:2 l 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_5_6_4  GetAxis
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 GetAxis dfname entry [drawname] 
-~~~~~
+~~~~
 
 Gets a line from *NamedShape* attribute at *entry* label and sets it to *drawname* variable, if it is defined. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 GetAxis D 0:2 l 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_5_6_5  SetPlane
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 SetPlane dfname entry plane 
-~~~~~
+~~~~
 
 Finds or creates a Plane attribute at *entry* label and sets *plane* as generated in the associated *NamedShape* attribute. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 plane pl 10 20 30 -1 0 0 
 SetPlane D 0:2 pl 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_5_6_6  GetPlane
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 GetPlane dfname entry [drawname] 
-~~~~~
+~~~~
 
 Gets a plane from *NamedShape* attribute at *entry* label and sets it to *drawname* variable, if it is defined. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 GetPlane D 0:2 pl 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_5_6_7  SetGeometry
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 SetGeometry dfname entry [type] [shape] 
-~~~~~
+~~~~
 
 Creates a Geometry attribute at *entry* label and sets *type* and *shape* as generated in the associated *NamedShape* attribute if they are defined. *type* must be one of the following: *any, pnt, lin, cir, ell, spl, pln, cyl*. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 point p 10 10 10 
 SetGeometry D 0:2 pnt p 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_5_6_8  GetGeometryType
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 GetGeometryType dfname entry
-~~~~
+~~~~
 
 Gets a geometry type from Geometry attribute at *entry* label. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 GetGeometryType D 0:2 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_5_6_9  SetConstraint
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 SetConstraint dfname entry keyword geometrie [geometrie …] 
 SetConstraint dfname entry "plane" geometrie 
 SetConstraint dfname entry "value" value
-~~~~~  
+~~~~
 
 1. Creates a Constraint attribute at *entry* label and sets *keyword* constraint between geometry(ies). 
 *keyword* must be one of the following: 
@@ -3883,83 +3883,83 @@ SetConstraint dfname entry "value" value
 3. Sets value for the existing constraint. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 SetConstraint D 0:2 "value" 5 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_5_6_10  GetConstraint
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 GetConstraint dfname entry
-~~~~
+~~~~
 
 Dumps a Constraint attribute at *entry* label 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 GetConstraint D 0:2 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_5_6_11  SetVariable
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 SetVariable dfname entry isconstant(0/1) units 
-~~~~~
+~~~~
 
 Creates a Variable attribute at *entry* label and sets *isconstant* flag and *units* as a string. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 SetVariable D 0:2 1 "mm" 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_5_6_12  GetVariable
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 GetVariable dfname entry isconstant units 
-~~~~~
+~~~~
 
 Gets an *isconstant* flag and units of a Variable attribute at *entry* label. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 GetVariable D 0:2 isconstant units 
 puts "IsConstant=${isconstant}" 
 puts "Units=${units}" 
-~~~~~
+~~~~
 
 @subsection occt_draw_5_7  Tree attributes commands
 
 
 @subsubsection occt_draw_5_7_1  RootNode
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 RootNode dfname treenodeentry [ID]
-~~~~
+~~~~
 
 Returns the ultimate father of *TreeNode* attribute identified by its *treenodeentry* and its *ID* (or default ID, if *ID* is not defined). 
 
 
 @subsubsection occt_draw_5_7_2  SetNode
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 SetNode dfname treenodeentry [ID]
-~~~~
+~~~~
 
 Creates a *TreeNode* attribute on the *treenodeentry* label with its tree *ID* (or assigns a default ID, if the *ID* is not defined). 
 
 
 @subsubsection occt_draw_5_7_3  AppendNode
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 AppendNode dfname fatherentry childentry [fatherID]
-~~~~
+~~~~
 
 
 Inserts a *TreeNode* attribute with its tree *fatherID* (or default ID, if *fatherID* is not defined) on *childentry* as last child of *fatherentry*. 
@@ -3969,10 +3969,10 @@ Inserts a *TreeNode* attribute with its tree *fatherID* (or default ID, if *fath
 
 @subsubsection occt_draw_5_7_4  PrependNode
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 PrependNode dfname fatherentry childentry [fatherID]
-~~~~
+~~~~
 
 
 Inserts a *TreeNode* attribute with its tree *fatherID* (or default ID, if *fatherID* is not defined) on *childentry* as first child of *fatherentry*. 
@@ -3980,46 +3980,46 @@ Inserts a *TreeNode* attribute with its tree *fatherID* (or default ID, if *fath
 
 @subsubsection occt_draw_5_7_5  InsertNodeBefore
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 InsertNodeBefore dfname treenodeentry beforetreenode [ID]
-~~~~
+~~~~
 
 Inserts a *TreeNode* attribute with tree *ID* (or default ID, if *ID* is not defined) *beforetreenode* before *treenodeentry*. 
 
 
 @subsubsection occt_draw_5_7_6  InsertNodeAfter
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 InsertNodeAfter dfname treenodeentry aftertreenode [ID]
-~~~~
+~~~~
 
 Inserts a *TreeNode* attribute with tree *ID* (or default ID, if *ID* is not defined) *aftertreenode* after *treenodeentry*. 
 
 
 @subsubsection occt_draw_5_7_7  DetachNode
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 DetachNode dfname treenodeentry [ID]
-~~~~
+~~~~
 
 Removes a *TreeNode* attribute with tree *ID* (or default ID, if *ID* is not defined) from *treenodeentry*. 
 
 
 @subsubsection occt_draw_5_7_8  ChildNodeIterate
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 ChildNodeIterate dfname treenodeentry alllevels(0/1) [ID]
-~~~~
+~~~~
 
 
 Iterates on the tree of *TreeNode* attributes with tree *ID* (or default ID, if *ID* is not defined). If *alllevels* is set to *1* it explores not only the first, but all the sub Step levels.
  
 **Example:** 
-~~~~~
+~~~~{.php}
 Label D 0:2 
 Label D 0:3 
 Label D 0:4 
@@ -4062,20 +4062,20 @@ ChildNodeIterate D 0:2 1
 ==0:7 
 ==0:6 
 ==0:5 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_5_7_9  InitChildNodeIterator
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 InitChildNodeIterator dfname treenodeentry alllevels(0/1) [ID]
-~~~~
+~~~~
 
 
 Initializes the iteration on the tree of *TreeNode* attributes with tree *ID* (or default ID, if *ID* is not defined). If *alllevels* is set to *1* it explores not only the first, but also all sub Step levels. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 InitChildNodeIterate D 0:5 1 
 set aChildNumber 0 
 for {set i 1} {$i < 100} {incr i} { 
@@ -4086,44 +4086,44 @@ for {set i 1} {$i < 100} {incr i} {
     } 
 } 
 puts "aChildNumber=$aChildNumber"
-~~~~
+~~~~
 
 @subsubsection occt_draw_5_7_10  ChildNodeMore
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 ChildNodeMore
-~~~~
+~~~~
 
 Returns TRUE if there is a current item in the iteration. 
 
 
 @subsubsection occt_draw_5_7_11  ChildNodeNext
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 ChildNodeNext
-~~~~
+~~~~
 
 Moves to the next Item. 
 
 
 @subsubsection occt_draw_5_7_12  ChildNodeValue
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 ChildNodeValue
-~~~~
+~~~~
 
 Returns the current treenode of *ChildNodeIterator*. 
 
 
 @subsubsection occt_draw_5_7_13  ChildNodeNextBrother
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 ChildNodeNextBrother
-~~~~
+~~~~
 
 Moves to the next *Brother*. If there is none, goes up. This method is interesting only with *allLevels* behavior. 
 
@@ -4133,214 +4133,214 @@ Moves to the next *Brother*. If there is none, goes up. This method is interesti
 
 @subsubsection occt_draw_5_8_1  AISInitViewer
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 AISInitViewer docname
-~~~~
+~~~~
 
 Creates and sets *AISViewer* attribute at root label, creates AIS viewer window. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 AISInitViewer D 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_5_8_2  AISRepaint
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 AISRepaint docname 
-~~~~~
+~~~~
 
 Updates the AIS viewer window. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 AISRepaint D 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_5_8_3  AISDisplay
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 AISDisplay docname entry [not_update] 
-~~~~~
+~~~~
 
 Displays a presantation of *AISobject* from *entry* label in AIS viewer. If *not_update* is not defined then *AISobject* is recomputed and all visualization settings are applied. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 AISDisplay D 0:5 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_5_8_4  AISUpdate
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 AISUpdate docname entry 
-~~~~~
+~~~~
 
 Recomputes a presentation of *AISobject* from *entry* label and applies the visualization setting in AIS viewer. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 AISUpdate D 0:5 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_5_8_5  AISErase
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 AISErase docname entry 
-~~~~~
+~~~~
 
 Erases *AISobject* of *entry* label in AIS viewer. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 AISErase D 0:5 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_5_8_6  AISRemove
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 AISRemove docname entry 
-~~~~~
+~~~~
 
 Erases *AISobject* of *entry* label in AIS viewer, then *AISobject* is removed from *AIS_InteractiveContext*. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 AISRemove D 0:5 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_5_8_7  AISSet
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 AISSet docname entry ID 
-~~~~~
+~~~~
 
 Creates *AISPresentation* attribute at *entry* label and sets as driver ID. ID must be one of the following: *A* (*axis*), *C* (*constraint*), *NS* (*namedshape*), *G* (*geometry*), *PL* (*plane*), *PT* (*point*). 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 AISSet D 0:5 NS 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_5_8_8  AISDriver
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 AISDriver docname entry [ID] 
-~~~~~
+~~~~
 
 Returns DriverGUID stored in *AISPresentation* attribute of an *entry* label or sets a new one. ID must be one of the following: *A* (*axis*), *C* (*constraint*), *NS* (*namedshape*), *G* (*geometry*), *PL* (*plane*), *PT* (*point*). 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # Get Driver GUID 
 AISDriver D 0:5 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_5_8_9  AISUnset
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 AISUnset docname entry 
-~~~~~
+~~~~
 
 Deletes *AISPresentation* attribute (if it exists) of an *entry* label. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 AISUnset D 0:5 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_5_8_10  AISTransparency
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 AISTransparency docname entry [transparency] 
-~~~~~
+~~~~
 
 Sets (if *transparency* is defined) or gets the value of transparency for *AISPresentation* attribute of an *entry* label. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 AISTransparency D 0:5 0.5 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_5_8_11  AISHasOwnTransparency
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 AISHasOwnTransparency docname entry 
-~~~~~
+~~~~
 
 Tests *AISPresentation* attribute of an *entry* label by own transparency. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 AISHasOwnTransparency D 0:5 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_5_8_12  AISMaterial
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 AISMaterial docname entry [material] 
-~~~~~
+~~~~
 
 Sets (if *material* is defined) or gets the value of transparency for *AISPresentation* attribute of an *entry* label. *material* is integer from 0 to 20 (see @ref occt_draw_4_5_6 "meshmat" command). 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 AISMaterial D 0:5 5 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_5_8_13  AISHasOwnMaterial
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 AISHasOwnMaterial docname entry 
-~~~~~
+~~~~
 
 Tests *AISPresentation* attribute of an *entry* label by own material. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 AISHasOwnMaterial D 0:5 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_5_8_14  AISColor
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 AISColor docname entry [color] 
-~~~~~
+~~~~
 
 Sets (if *color* is defined) or gets value of color for *AISPresentation* attribute of an *entry* label. *color* is integer from 0 to 516 (see color names in *vsetcolor*). 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 AISColor D 0:5 25 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_5_8_15  AISHasOwnColor
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 AISHasOwnColor docname entry 
-~~~~~
+~~~~
 
 Tests *AISPresentation* attribute of an *entry* label by own color. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 AISHasOwnColor D 0:5 
-~~~~~
+~~~~
 
 @section occt_draw_6 Geometry commands
 
@@ -4388,28 +4388,28 @@ Curves are displayed with an arrow showing the last parameter.
 
 @subsubsection occt_draw_6_2_1 point
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 point name x y [z] 
-~~~~~
+~~~~
   
 Creates a 2d or 3d point, depending on the number of arguments. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 # 2d point 
 point p1 1 2 
 
 # 3d point 
 point p2 10 20 -5 
-~~~~~
+~~~~
   
 @subsubsection occt_draw_6_2_2  line
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 line name x y [z] dx dy [dz]
-~~~~
+~~~~
 
   
 Creates a 2d or 3d line. *x y z* are the coordinates of the line’s point of origin; *dx, dy, dz* give the direction vector. 
@@ -4417,20 +4417,20 @@ Creates a 2d or 3d line. *x y z* are the coordinates of the line’s point of or
 A 2d line will be represented as *x y dx dy*, and a 3d line as *x y z dx dy dz* . A line is parameterized along its length starting from the point of origin along the direction vector. The direction vector is normalized and must not be null. Lines are infinite, even though their representation is not. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # a 2d line at 45 degrees of the X axis 
 line l 2 0 1 1 
 
 # a 3d line through the point 10 0 0 and parallel to Z 
 line l 10 0 0 0 0 1 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_6_2_3  circle
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 circle name x y [z [dx dy dz]] [ux uy [uz]] radius
-~~~~
+~~~~
 
 Creates a 2d or a 3d circle. 
 
@@ -4441,7 +4441,7 @@ In 3d, *x, y, z* are the coordinates of the center; *dx, dy, dz* give the vector
 The circle is parameterized by the angle in [0,2*pi] starting from the origin and. Note that the specification of origin direction and plane is the same for all analytical curves and surfaces. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # A 2d circle of radius 5 centered at 10,-2 
 circle c1 10 -2 5 
 
@@ -4458,27 +4458,27 @@ circle c4 10 20 -5 0 1 0 17
 
 # full 3d circle, axis X, origin on Z 
 circle c5 10 20 -5 1 0 0 0 0 1 17 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_6_2_4  ellipse
 
-Syntax: 
-~~~~~
+Syntax:
+~~~~{.php}
 ellipse name x y [z [dx dy dz]] [ux uy [uz]] firstradius secondradius 
-~~~~~
+~~~~
 
 Creates a 2d or 3d ellipse. In a 2d ellipse, the first two arguments define the center; in a 3d ellipse, the first three. The axis system is given by *firstradius*, the major radius, and *secondradius*, the minor radius. The parameter range of the ellipse is [0,2.*pi] starting from the X axis and going towards the Y axis. The Draw ellipse is parameterized by an angle: 
 
-~~~~~
+~~~~{.php}
 P(u) = O + firstradius*cos(u)*Xdir + secondradius*sin(u)*Ydir 
-~~~~~
-where: 
+~~~~
+Where: 
 
   * P is the point of parameter *u*,
   * *O, Xdir* and *Ydir* are respectively the origin, *X Direction* and *Y Direction* of its local coordinate system.
  
 **Example:**
-~~~~~
+~~~~{.php}
 # default 2d ellipse 
 ellipse e1 10 5 20 10 
 
@@ -4490,28 +4490,28 @@ ellipse e3 0 0 0 25 5
 
 # 3d ellipse in the X,Z plane with axis 1, 0 ,1 
 ellipse e4 0 0 0 0 1 0 1 0 1 25 5 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_6_2_5  hyperbola
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 hyperbola name x y [z [dx dy dz]] [ux uy [uz]] firstradius secondradius
-~~~~
+~~~~
 
 Creates a 2d or 3d conic. The first arguments define the center. The axis system is given by *firstradius*, the major radius, and *secondradius*, the minor radius. Note that the hyperbola has only one branch, that in the X direction. 
 
 The Draw hyperbola is parameterized as follows: 
-~~~~~
+~~~~{.php}
 P(U) = O + firstradius*Cosh(U)*XDir + secondradius*Sinh(U)*YDir 
-~~~~~
-where: 
+~~~~
+Where: 
 
   * *P* is the point of parameter *U*,
   * *O, XDir* and *YDir* are respectively the origin, *X Direction* and *YDirection* of its local coordinate system. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # default 2d hyperbola, with asymptotes 1,1 -1,1 
 hyperbola h1 0 0 30 30 
 
@@ -4520,30 +4520,30 @@ hyperbola h2 0 0 1 2 20 20
 
 # 3d hyperbola, in the XY plane 
 hyperbola h3 0 0 0 50 50 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_6_2_6  parabola
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 parabola name x y [z [dx dy dz]] [ux uy [uz]] FocalLength 
-~~~~~
+~~~~
 
 Creates a 2d or 3d parabola. in the axis system defined by the first arguments. The origin is the apex of the parabola. 
 
 The *Geom_Parabola* is parameterized as follows: 
 
-~~~~~
+~~~~{.php}
 P(u) = O + u*u/(4.*F)*XDir + u*YDir 
-~~~~~
+~~~~
 
-where: 
+Where: 
   * *P* is the point of parameter *u*,
   * *O, XDir* and *YDir* are respectively the origin, *X Direction* and *Y Direction* of its local coordinate system,
   * *F* is the focal length of the parabola.
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # 2d parabola 
 parabola p1 0 0 50 
 
@@ -4552,37 +4552,37 @@ parabola p2 0 0 0 1 50
 
 # 3d parabola in the Y-Z plane, convexity +Z 
 parabola p3 0 0 0 1 0 0 0 0 1 50 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_6_2_7  beziercurve, 2dbeziercurve
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 beziercurve name nbpole pole, [weight] 
 2dbeziercurve name nbpole pole, [weight]
-~~~~
+~~~~
 
 Creates a 3d rational or non-rational Bezier curve. Give the number of poles (control points,) and the coordinates of the poles *(x1 y1 z1 [w1] x2 y2 z2 [w2])*. The degree will be *nbpoles-1*. To create a rational curve, give weights with the poles. You must give weights for all poles or for none. If the weights of all the poles are equal, the curve is polynomial, and therefore non-rational. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # a rational 2d bezier curve (arc of circle) 
 2dbeziercurve ci 3 0 0 1 10 0 sqrt(2.)/2. 10 10 1 
 
 # a 3d bezier curve, not rational 
 beziercurve cc 4 0 0 0 10 0 0 10 0 10 10 10 10 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_6_2_8  bsplinecurve, 2dbsplinecurve, pbsplinecurve, 2dpbsplinecurve
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 bsplinecurve   name degree nbknots knot, umult pole, weight
 2dbsplinecurve name degree nbknots knot, umult pole, weight
 
 pbsplinecurve   name degree nbknots knot, umult pole, weight (periodic)
 2dpbsplinecurve name degree nbknots knot, umult pole, weight (periodic)
-~~~~~
+~~~~
 
 Creates 2d or 3d bspline curves; the **pbsplinecurve** and **2dpbsplinecurve** commands create periodic bspline curves. 
 
@@ -4597,7 +4597,7 @@ The poles must be given with their weights, use weights of 1 for a non rational
   * For a periodic curve: Sum of multiplicities - last multiplicity
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # a bspline curve with 4 poles and 3 knots 
 bsplinecurve bc 2 3 0 3 1 1 2 3 \ 
 10 0 7 1 7 0 7 1 3 0 8 1 0 0 7 1 
@@ -4612,45 +4612,45 @@ dset h sqrt(3)/2
 -0.25 h/6 1 \ 
 -0.5 -h/3 0.5 \ 
 0 -h/3 1 
-~~~~~
+~~~~
 
 **Note** that you can create the **NURBS** subset of bspline curves and surfaces by trimming analytical curves and surfaces and executing the command *convert*. 
 
 
 @subsubsection occt_draw_6_2_9  uiso, viso
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 uiso name surface u 
 viso name surface u 
-~~~~~
+~~~~
 
 Creates a U or V isoparametric curve from a surface. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # create a cylinder and extract iso curves 
 
 cylinder c 10 
 uiso c1 c pi/6 
 viso c2 c 
-~~~~~
+~~~~
 
 **Note** that this cannot be done from offset surfaces.
 
 
 @subsubsection occt_draw_6_2_10  to3d, to2d
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 to3d name curve2d [plane] 
 to2d name curve3d [plane] 
-~~~~~
+~~~~
 
 Create respectively a 3d curve from a 2d curve and a 2d curve from a 3d curve. The transformation uses a planar surface to define the XY plane in 3d (by default this plane is the default OXYplane). **to3d** always gives a correct result, but as **to2d** is not a projection, it may surprise you. It is always correct if the curve is planar and parallel to the plane of projection. The points defining the curve are projected on the plane. A circle, however, will remain a circle and will not be changed to an ellipse. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # the following commands 
 circle c 0 0 5 
 plane p -2 1 0 1 2 3 
@@ -4658,28 +4658,28 @@ to3d c c p
 
 # will create the same circle as 
 circle c -2 1 0 1 2 3 5 
-~~~~~
+~~~~
 
 See also: **project** 
 
 
 @subsubsection occt_draw_6_2_11  project
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 project name curve3d surface 
-~~~~~
+~~~~
 
 Computes a 2d curve in the parametric space of a surface corresponding to a 3d curve. This can only be used on analytical surfaces. 
 
 If we, for example, intersect a cylinder and a plane and project the resulting ellipse on the cylinder, this will create a 2d sinusoid-like bspline. 
 
-~~~~~
+~~~~{.php}
 cylinder c 5 
 plane p 0 0 0 0 1 1 
 intersect i c p 
 project i2d i c 
-~~~~~
+~~~~
 
 @subsection occt_draw_6_3  Surface creation
 
@@ -4694,10 +4694,10 @@ Surfaces are displayed with isoparametric lines. To show the parameterization, a
 
 @subsubsection occt_draw_6_3_1  plane
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 plane name [x y z [dx dy dz [ux uy uz]]]
-~~~~
+~~~~
 
 Creates an infinite plane. 
 
@@ -4710,26 +4710,26 @@ There are default values for the coordinate system. If no arguments are given, t
 Note that this definition will be used for all analytical surfaces. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # a plane through the point 10,0,0 perpendicular to X 
 # with U direction on Y 
 plane p1 10 0 0 1 0 0 0 1 0 
 
 # an horixontal plane with origin 10, -20, -5 
 plane p2 10 -20 -5 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_6_3_2  cylinder
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 cylinder name [x y z [dx dy dz [ux uy uz]]] radius 
-~~~~~
+~~~~
 
 A cylinder is defined by a coordinate system, and a radius. The surface generated is an infinite cylinder with the Z axis as the axis. The U parameter is the angle starting from X going in the Y direction. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # a cylinder on the default Z axis, radius 10 
 cylinder c1 10 
 
@@ -4742,71 +4742,71 @@ cylinder c2 5 10 -3 10
 dset lo pi/3. la pi/4. 
 cylinder c3 0 0 0 cos(la)*cos(lo) cos(la)*sin(lo) 
 sin(la) 10 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_6_3_3  cone
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 cone name [x y z [dx dy dz [ux uy uz]]] semi-angle radius 
-~~~~~
+~~~~
 Creates a cone in the infinite coordinate system along the Z-axis. The radius is that of the circle at the intersection of the cone and the XY plane. The semi-angle is the angle formed by the cone relative to the axis; it should be between -90 and 90. If the radius is 0, the vertex is the origin. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # a cone at 45 degrees at the origin on Z 
 cone c1 45 0 
 
 # a cone on axis Z with radius r1 at z1 and r2 at z2 
 cone c2 0 0 z1 180.*atan2(r2-r1,z2-z1)/pi r1 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_6_3_4  sphere
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 sphere name [x y z [dx dy dz [ux uy uz]]] radius 
-~~~~~
+~~~~
 
 Creates a sphere in the local coordinate system defined in the **plane** command. The sphere is centered at the origin. 
 
 To parameterize the sphere, *u* is the angle from X to Y, between 0 and 2*pi. *v* is the angle in the half-circle at angle *u* in the plane containing the Z axis. *v* is between -pi/2 and pi/2. The poles are the points Z = +/- radius; their parameters are u,+/-pi/2 for any u in 0,2*pi. 
 
 **Example:**
-~~~~
+~~~~{.php}
 # a sphere at the origin 
 sphere s1 10 
 # a sphere at 10 10 10, with poles on the axis 1,1,1 
 sphere s2 10 10 10 1 1 1 10 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_6_3_5  torus
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 torus name [x y z [dx dy dz [ux uy uz]]] major minor
-~~~~
+~~~~
 
 Creates a torus in the local coordinate system with the given major and minor radii. *Z* is the axis for the major radius. The major radius may be lower in value than the minor radius. 
 
 To parameterize a torus, *u* is the angle from X to Y; *v* is the angle in the plane at angle *u* from the XY plane to Z. *u* and *v* are in 0,2*pi. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # a torus at the origin 
 torus t1 20 5 
 
 # a torus in another coordinate system 
 torus t2 10 5 -2 2 1 0 20 5 
-~~~~~
+~~~~
 
 
 @subsubsection occt_draw_6_3_6  beziersurf
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 beziersurf name nbupoles nbvolpes pole, [weight] 
-~~~~~
+~~~~
 
 Use this command to create a bezier surface, rational or non-rational. First give the numbers of poles in the u and v directions. 
 
@@ -4815,25 +4815,25 @@ Then give the poles in the following order: *pole(1, 1), pole(nbupoles, 1), pole
 Weights may be omitted, but if you give one weight you must give all of them. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # a non-rational degree 2,3 surface 
 beziersurf s 3 4 \ 
 0 0 0 10 0 5 20 0 0 \ 
 0 10 2 10 10 3 20 10 2 \ 
 0 20 10 10 20 20 20 20 10 \ 
 0 30 0 10 30 0 20 30 0 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_6_3_7   bsplinesurf, upbsplinesurf, vpbsplinesurf, uvpbsplinesurf
 
-Syntax:     
-~~~~~
+Syntax:
+~~~~{.php}
 bsplinesurf name udegree nbuknots uknot umult ... nbvknot vknot 
 vmult ... x y z w ... 
 upbsplinesurf ... 
 vpbsplinesurf ... 
 uvpbsplinesurf ... 
-~~~~~
+~~~~
 
 * **bsplinesurf** generates bspline surfaces;
 * **upbsplinesurf** creates a bspline surface periodic in u; 
@@ -4845,7 +4845,7 @@ The syntax is similar to the *bsplinecurve* command. First give the degree in u
 See *bsplinecurve* to compute the number of poles, the poles are first given in U as in the *beziersurf* command. You must give weights if the surface is rational. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # create a bspline surface of degree 1 2 
 # with two knots in U and three in V 
 bsplinesurf s \ 
@@ -4855,17 +4855,17 @@ bsplinesurf s \
 0 10 2 1 10 10 3 1 \ 
 0 20 10 1 10 20 20 1 \ 
 0 30 0 1 10 30 0 1 
-~~~~~
+~~~~
 
 
 @subsubsection occt_draw_6_3_8  trim, trimu, trimv
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 trim newname name [u1 u2 [v1 v2] [usense vsense]]
 trimu newname name u1 u2 [usense]
 trimv newname name v1 v2 [vsense]
-~~~~~
+~~~~
 
 The **trim** commands create trimmed curves or trimmed surfaces. Note that trimmed curves and surfaces are classes of the *Geom* package. 
 * *trim* creates either a new trimmed curve from a curve or a new trimmed surface in u and v from a surface.
@@ -4877,7 +4877,7 @@ After an initial trim, a second execution with no parameters given recreates the
 **Note** that a trimmed curve or surface contains a copy of the basis geometry: modifying that will not modify the trimmed geometry. Trimming trimmed geometry will not create multiple levels of trimming. The basis geometry will be used. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # create a 3d circle 
 circle c 0 0 0 10 
 
@@ -4902,14 +4902,14 @@ trim cc c pi/2 2*pi
 # trim an infinite cylinder 
 cylinder cy 10 
 trimv cy cy 0 50 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_6_3_9  offset
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 offset name basename distance [dx dy dz]
-~~~~
+~~~~
 
 Creates offset curves or surfaces at a given distance from a basis curve or surface. Offset curves and surfaces are classes from the *Geom *package. 
 
@@ -4918,7 +4918,7 @@ The curve can be a 2d or a 3d curve. To compute the offsets for a 3d curve, you
 The offset curve or surface copies the basic geometry, which can be modified later. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # graphic demonstration that the outline of a torus 
 # is the offset of an ellipse 
 smallview +X+Y 
@@ -4928,14 +4928,14 @@ fit
 ellipse e 0 0 0 50 50*sin(angle) 
 # note that the distance can be negative 
 offset l1 e 20 0 0 1 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_6_3_10  revsurf
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 revsurf name curvename x y z dx dy dz
-~~~~
+~~~~
 
 Creates a surface of revolution from a 3d curve. 
 
@@ -4944,18 +4944,18 @@ A surface of revolution or revolved surface is obtained by rotating a curve (cal
 To parameterize a surface of revolution: u is the angle of rotation around the axis. Its origin is given by the position of the meridian on the surface. v is the parameter of the meridian. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # another way of creating a torus like surface 
 circle c 50 0 0 20 
 revsurf s c 0 0 0 0 1 0 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_6_3_11  extsurf
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 extsurf newname curvename dx dy dz 
-~~~~~
+~~~~
 
 Creates a surface of linear extrusion from a 3d curve. The basis curve is swept in a given direction,the *direction of extrusion* defined by a vector. 
 
@@ -4964,25 +4964,25 @@ In the syntax, *dx,dy,dz* gives the direction of extrusion.
 To parameterize a surface of extrusion: *u* is the parameter along the extruded curve; the *v* parameter is along the direction of extrusion. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # an elliptic cylinder 
 ellipse e 0 0 0 10 5 
 extsurf s e 0 0 1 
 # to make it finite 
 trimv s s 0 10 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_6_3_12  convert
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 convert newname name 
-~~~~~
+~~~~
 
 Creates a 2d or 3d NURBS curve or a NURBS surface from any 2d curve, 3d curve or surface. In other words, conics, beziers and bsplines are turned into NURBS. Offsets are not processed.
  
 **Example:** 
-~~~~~
+~~~~{.php}
 # turn a 2d arc of a circle into a 2d NURBS 
 circle c 0 0 5 
 trim c c 0 pi/3 
@@ -4992,7 +4992,7 @@ convert c1 c
 plane p 
 trim p p -1 1 -1 1 
 convert p1 p 
-~~~~~
+~~~~
 
 **Note** that offset curves and surfaces are not processed by this command.
 
@@ -5025,12 +5025,12 @@ Modifications for bspline:
 @subsubsection occt_draw_6_4_1  reverse, ureverse, vreverse
 
 
-Syntax:            
-~~~~~
+Syntax:
+~~~~{.php}
 reverse curvename 
 ureverse surfacename 
 vreverse surfacename 
-~~~~~
+~~~~
 
 The **reverse** command reverses the parameterization and inverses the orientation of a 2d or 3d curve. Note that the geometry is modified. To keep the curve or the surface, you must copy it before modification. 
 
@@ -5039,7 +5039,7 @@ The **reverse** command reverses the parameterization and inverses the orientati
 Reversing a parameter on an analytical surface may create an indirect coordinate system. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # reverse a trimmed 2d circle 
 circle c 0 0 5 
 trim c c pi/4 pi/2 
@@ -5047,33 +5047,33 @@ reverse c
 
 # dumping c will show that it is now trimmed between 
 # 3*pi/2 and 7*pi/4 i.e. 2*pi-pi/2 and 2*pi-pi/4 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_6_4_2  exchuv
 
-Syntax:                 
-~~~~~
+Syntax:
+~~~~{.php}
 exchuv surfacename 
-~~~~~
+~~~~
 
 For a bezier or bspline surface this command exchanges the u and v parameters. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # exchanging u and v on a spline (made from a cylinder) 
 cylinder c 5 
 trimv c c 0 10 
 convert c1 c 
 exchuv c1 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_6_4_3  segment, segsur
 
-Syntax:                  
-~~~~~
+Syntax:
+~~~~{.php}
 segment curve Ufirst Ulast 
 segsur surface Ufirst Ulast Vfirst Vlast 
-~~~~~
+~~~~
 
 **segment** and **segsur** segment a bezier curve and a bspline curve or surface respectively. 
 
@@ -5082,51 +5082,51 @@ These commands modify the curve to restrict it between the new parameters: *Ufir
 This command must not be confused with **trim** which creates a new geometry. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # segment a bezier curve in half 
 beziercurve c 3 0 0 0 10 0 0 10 10 0 
 segment c ufirst ulast 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_6_4_4  iincudeg, incvdeg
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 incudeg surfacename newdegree 
 incvdeg surfacename newdegree 
-~~~~~
+~~~~
 
 **incudeg** and **incvdeg** increase the degree in the U or V parameter of a bezier or bspline surface.
  
 **Example:** 
-~~~~~
+~~~~{.php}
 # make a planar bspline and increase the degree to 2 3 
 plane p 
 trim p p -1 1 -1 1 
 convert p1 p 
 incudeg p1 2 
 incvdeg p1 3 
-~~~~~
+~~~~
 
 **Note** that the geometry is modified.
 
 
 @subsubsection occt_draw_6_4_5  cmovep, movep, movecolp, moverowp
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 cmovep curve index dx dy [dz] 
 movep surface uindex vindex dx dy dz 
 movecolp surface uindex dx dy dz 
 moverowp surface vindex dx dy dz 
-~~~~~
+~~~~
 
 **move** methods translate poles of a bezier curve, a bspline curve or a bspline surface. 
 * **cmovep** and **movep** translate one pole with a given index. 
 * **movecolp** and **moverowp** translate a whole column (expressed by the *uindex*) or row (expressed by the *vindex*) of poles. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # start with a plane 
 # transform to bspline, raise degree and add relief 
 plane p 
@@ -5137,17 +5137,17 @@ incvd p1 2
 movecolp p1 2 0 0 5 
 moverowp p1 2 0 0 5 
 movep p1 2 2 0 0 5 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_6_4_6  insertpole, rempole, remcolpole, remrowpole
 
-Syntax:                  
-~~~~~
+Syntax:
+~~~~{.php}
 insertpole curvename index x y [z] [weight] 
 rempole curvename index 
 remcolpole surfacename index 
 remrowpole surfacename index
-~~~~
+~~~~
 
 **insertpole** inserts a new pole into a 2d or 3d bezier curve. You may add a weight for the pole. The default value for the weight is 1. The pole is added at the position after that of the index pole. Use an index 0 to insert the new pole before the first one already existing in your drawing. 
 
@@ -5156,104 +5156,104 @@ remrowpole surfacename index
 **remcolpole** and **remrowpole** remove a column or a row of poles from a bezier surface. A column is in the v direction and a row in the u direction The resulting degree must be at least 1; i.e there will be two rows and two columns left. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # start with a segment, insert a pole at end 
 # then remove the central pole 
 beziercurve c 2 0 0 0 10 0 0 
 insertpole c 2 10 10 0 
 rempole c 2 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_6_4_7  insertknot, insertuknot, insertvknot
 
-Syntax:                  
-~~~~~
+Syntax:
+~~~~{.php}
 insertknot name knot [mult = 1] [knot mult ...] 
 insertuknot surfacename knot mult 
 insertvknot surfacename knot mult 
-~~~~~
+~~~~
 
 **insertknot** inserts knots in the knot sequence of a bspline curve. You must give a knot value and a target multiplicity. The default multiplicity is 1. If there is already a knot with the given value and a multiplicity lower than the target one, its multiplicity will be raised. 
 
 **insertuknot** and **insertvknot** insert knots in a surface. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # create a cylindrical surface and insert a knot 
 cylinder c 10 
 trim c c 0 pi/2 0 10 
 convert c1 c 
 insertuknot c1 pi/4 1 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_6_4_8  remknot, remuknot, remvknot
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 remknot index [mult] [tol] 
 remuknot index [mult] [tol] 
 remvknot index [mult] [tol] 
-~~~~~
+~~~~
 
 **remknot** removes a knot from the knot sequence of a curve or a surface. Give the index of the knot and optionally, the target multiplicity. If the target multiplicity is not 0, the multiplicity of the knot will be lowered. As the curve may be modified, you are allowed to set a tolerance to control the process. If the tolerance is low, the knot will only be removed if the curve will not be modified. 
 
 By default, if no tolerance is given, the knot will always be removed. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # bspline circle, remove a knot 
 circle c 0 0 5 
 convert c1 c 
 incd c1 5 
 remknot c1 2 
-~~~~~
+~~~~
 
 **Note** that Curves or Surfaces may be modified.
 
 
 @subsubsection occt_draw_6_4_9  setperiodic, setnotperiodic, setuperiodic, setunotperiodic, setvperiodic, setvnotperiodic
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 setperiodic curve 
 setnotperiodic curve 
 setuperiodic surface 
 setunotperiodic surface 
 setvperiodic surface 
 setvnotperiodic surface
-~~~~
+~~~~
 
 **setperiodic** turns a bspline curve into a periodic bspline curve; the knot vector stays the same and excess poles are truncated. The curve may be modified if it has not been closed. **setnotperiodic** removes the periodicity of a periodic curve. The pole table mau be modified. Note that knots are added at the beginning and the end of the knot vector and the multiplicities are knots set to degree+1 at the start and the end. 
 
 **setuperiodic** and **setvperiodic** make the u or the v parameter of bspline surfaces periodic; **setunotperiodic**, and **setvnotperiodic** remove periodicity from the u or the v parameter of bspline surfaces. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # a circle deperiodicized 
 circle c 0 0 5 
 convert c1 c 
 setnotperiodic c1 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_6_4_10  setorigin, setuorigin, setvorigin
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 setorigin curvename index 
 setuorigin surfacename index 
 setuorigin surfacename index 
-~~~~~
+~~~~
 
 These commands change the origin of the parameters on periodic curves or surfaces. The new origin must be an existing knot. To set an origin other than an existing knot, you must first insert one with the *insertknot* command. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # a torus with new U and V origins 
 torus t 20 5 
 convert t1 t 
 setuorigin t1 2 
 setvorigin t1 2
-~~~~
+~~~~
 
 
 @subsection occt_draw_6_5  Transformations
@@ -5262,42 +5262,42 @@ Draw provides commands to apply linear transformations to geometric objects: the
 
 @subsubsection occt_draw_6_5_1  translate, dtranslate
 
-Syntax:                  
-~~~~~
+Syntax:
+~~~~{.php}
 translate name [names ...] dx dy dz 
 2dtranslate name [names ...] dx dy 
-~~~~~
+~~~~
 
 The **Translate** command translates 3d points, curves and surfaces along a vector *dx,dy,dz*. You can translate more than one object with the same command. 
 
 For 2d points or curves, use the **2dtranslate** command. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # 3d translation 
 point p 10 20 30 
 circle c 10 20 30 5 
 torus t 10 20 30 5 2 
 translate p c t 0 0 15
-~~~~~
+~~~~
  
 *NOTE* 
 *Objects are modified by this command.* 
 
 @subsubsection occt_draw_6_5_2  rotate, 2drotate
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 rotate name [name ...] x y z dx dy dz angle 
 2drotate name [name ...] x y angle
-~~~~
+~~~~
 
 The **rotate** command rotates a 3d point curve or surface. You must give an axis of rotation with a point *x,y,z*, a vector *dx,dy,dz* and an angle in degrees. 
 
 For a 2d rotation, you need only give the center point and the angle. In 2d or 3d, the angle can be negative. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # make a helix of circles. create a script file with 
 this code and execute it using **source**. 
 circle c0 10 0 0 3 
@@ -5306,18 +5306,18 @@ copy c[expr $i-1] c$i
 translate c$i 0 0 3 
 rotate c$i 0 0 0 0 0 1 36 
 } 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_6_5_3  pmirror, lmirror, smirror, dpmirror, dlmirror
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 pmirror name [names ...] x y z 
 lmirror name [names ...] x y z dx dy dz 
 smirror name [names ...] x y z dx dy dz 
 2dpmirror name [names ...] x y 
 2dlmirror name [names ...] x y dx dy 
-~~~~~
+~~~~
 
 The mirror commands perform a mirror transformation of 2d or 3d geometry. 
 
@@ -5328,7 +5328,7 @@ The mirror commands perform a mirror transformation of 2d or 3d geometry.
 * **2dlmirror** is the axis symmetry mirror in 2D.
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # build 3 images of a torus 
 torus t 10 10 10 1 2 3 5 1 
 copy t t1 
@@ -5337,25 +5337,25 @@ copy t t2
 lmirror t2 0 0 0 1 0 0 
 copy t t3 
 smirror t3 0 0 0 1 0 0 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_6_5_4  pscale, dpscale
 
-Syntax:                  
-~~~~~
+Syntax:
+~~~~{.php}
 pscale name [name ...] x y z s 
 2dpscale name [name ...] x y s 
-~~~~~
+~~~~
 
 The **pscale** and **2dpscale** commands transform an object by point scaling. You must give the center and the scaling factor. Because other scalings modify the type of the object, they are not provided. For example, a sphere may be transformed into an ellipsoid. Using a scaling factor of -1 is similar to using **pmirror**.
 
  
 **Example:** 
-~~~~~
+~~~~{.php}
 # double the size of a sphere 
 sphere s 0 0 0 10 
 pscale s 0 0 0 2 
-~~~~~
+~~~~
 
 @subsection occt_draw_6_6  Curve and surface analysis
 
@@ -5371,30 +5371,30 @@ pscale s 0 0 0 2
 
 @subsubsection occt_draw_6_6_1  coord
 
-Syntax:            
-~~~~~
+Syntax:
+~~~~{.php}
 coord P x y [z] 
-~~~~~
+~~~~
 
 Sets the x, y (and optionally z) coordinates of the point P. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # translate a point 
 point p 10 5 5 
 translate p 5 0 0 
 coord p x y z 
 # x value is 15 
-~~~~~
+~~~~
 
 
 @subsubsection occt_draw_6_6_2   cvalue, 2dcvalue
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 cvalue curve U x y z [d1x d1y d1z [d2x d2y d2z]] 
 2dcvalue curve U x y [d1x d1y [d2x d2y]] 
-~~~~~
+~~~~
 
 For a curve at a given parameter, and depending on the number of arguments, **cvalue** computes the coordinates in *x,y,z*, the first derivative in *d1x,d1y,d1z* and the second derivative in *d2x,d2y,d2z*. 
 
@@ -5402,76 +5402,76 @@ For a curve at a given parameter, and depending on the number of arguments, **cv
 
 Let on a bezier curve at parameter 0 the point is the first pole; the first derivative is the vector to the second pole multiplied by the degree; the second derivative is the difference first to the second pole, second to the third pole multipied by *degree-1* : 
 
-~~~~~
+~~~~{.php}
 2dbeziercurve c 4 0 0 1 1 2 1 3 0 
 2dcvalue c 0 x y d1x d1y d2x d2y 
 
 # values of x y d1x d1y d2x d2y 
 # are 0 0 3 3 0 -6 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_6_6_3  svalue
 
-Syntax: 
-~~~~~
+Syntax:
+~~~~{.php}
 svalue surfname U v x y z [dux duy duz dvx dvy dvz [d2ux d2uy d2uz d2vx d2vy d2vz d2uvx d2uvy d2uvz]] 
-~~~~~
+~~~~
 
 Computes points and derivatives on a surface for a pair of parameter values. The result depends on the number of arguments. You can compute the first and the second derivatives. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # display points on a sphere 
 sphere s 10 
 for {dset t 0} {[dval t] <= 1} {dset t t+0.01} { 
 svalue s t*2*pi t*pi-pi/2 x y z 
 point . x y z 
 } 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_6_6_4  localprop, minmaxcurandinf
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 localprop curvename U 
 minmaxcurandinf curve
-~~~~
+~~~~
 
 **localprop** computes the curvature of a curve. 
 **minmaxcurandinf** computes and prints the parameters of the points where the curvature is minimum and maximum on a 2d curve. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # show curvature at the center of a bezier curve 
 beziercurve c 3 0 0 0 10 2 0 20 0 0 
 localprop c 0.5 
 == Curvature : 0.02 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_6_6_5  parameters
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 parameters surf/curve x y z U [V] 
-~~~~~
+~~~~
 
 Returns the parameters on the surface of the 3d point *x,y,z* in variables *u* and *v*. This command may only be used on analytical surfaces: plane, cylinder, cone, sphere and torus. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # Compute parameters on a plane 
 plane p 0 0 10 1 1 0 
 parameters p 5 5 5 u v 
 # the values of u and v are : 0 5 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_6_6_6  proj, 2dproj
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 proj name x y z 
 2dproj name xy 
-~~~~~
+~~~~
 
 Use **proj** to project a point on a 3d curve or a surface and **2dproj** for a 2d curve. 
 
@@ -5481,18 +5481,18 @@ The command will compute and display all points in the projection. The lines joi
 
 Let us project a point on a torus 
 
-~~~~~
+~~~~{.php}
 torus t 20 5 
 proj t 30 10 7 
 == ext_1 ext_2 ext_3 ext_4 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_6_6_7  surface_radius
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 surface_radius surface u v [c1 c2] 
-~~~~~
+~~~~
 
 Computes the main curvatures of a surface at parameters *(u,v)*. If there are extra arguments, their curvatures are stored in variables *c1* and *c2*. 
 
@@ -5500,12 +5500,12 @@ Computes the main curvatures of a surface at parameters *(u,v)*. If there are ex
 
 Let us compute curvatures of a cylinder:
 
-~~~~~
+~~~~{.php}
 cylinder c 5 
 surface_radius c pi 3 c1 c2 
 == Min Radius of Curvature : -5 
 == Min Radius of Curvature : infinite 
-~~~~~
+~~~~
 
 
 @subsection occt_draw_6_7  Intersections
@@ -5516,27 +5516,27 @@ surface_radius c pi 3 c1 c2
 
 @subsubsection occt_draw_6_7_1  intersect
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 intersect name surface1 surface2
-~~~~
+~~~~
 
 Intersects two surfaces; if there is one intersection curve it will be named *name*, if there are more than one they will be named *name_1*, *name_2*, ... 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # create an ellipse 
 cone c 45 0 
 plane p 0 0 40 0 1 5 
 intersect e c p 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_6_7_2  2dintersect
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 2dintersect curve1 [curve2] [-tol tol] [-state]
-~~~~~
+~~~~
 
 Displays the intersection points between 2d curves.
 Options:
@@ -5544,31 +5544,31 @@ Options:
  -state - allows printing the intersection state for each point.
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # intersect two 2d ellipses 
 ellipse e1 0 0 5 2 
 ellipse e2 0 0 0 1 5 2 
 2dintersect e1 e2 -tol 1.e-10 -state
-~~~~~
+~~~~
 
 @subsubsection occt_draw_6_7_3 intconcon
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 intconcon curve1 curve2 
-~~~~~
+~~~~
 
 Displays the intersection points between two 2d curves. 
 Curves must be only conic sections: 2d lines, circles, ellipses,
 hyperbolas, parabolas. The algorithm from *IntAna2d_AnaIntersection* is used.
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # intersect two 2d ellipses 
 ellipse e1 0 0 5 2 
 ellipse e2 0 0 0 1 5 2 
 intconcon e1 e2 
-~~~~~
+~~~~
 
 @subsection occt_draw_6_8  Approximations
 
@@ -5582,11 +5582,11 @@ Draw provides command to create curves and surfaces by approximation.
 
 @subsubsection occt_draw_6_8_1   appro, dapprox
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 appro result nbpoint [curve] 
 2dapprox result nbpoint [curve / x1 y1 x2 y2]
-~~~~
+~~~~
 
 These commands fit a curve through a set of points. First give the number of points, then choose one of the three ways available to get the points. If you have no arguments, click on the points. If you have a curve argument or a list of points, the command launches computation of the points on the curve. 
 
@@ -5594,21 +5594,21 @@ These commands fit a curve through a set of points. First give the number of poi
 
 Let us pick points and they will be fitted 
 
-~~~~~
+~~~~{.php}
 2dapprox c 10 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_6_8_2  surfapp, grilapp, surfint
 
 
-Syntax: 
-~~~~~
+Syntax:
+~~~~{.php}
 surfapp name nbupoints nbvpoints x y z .... 
 or
 surfapp name nbupoints nbvpoints surf [periodic_flag = 0]
 grilapp name nbupoints nbvpoints xo dx yo dy z11 z12 ... 
 surfint name surf nbupoints nbvpoints [periodic_flag = 0]
-~~~~~
+~~~~
 
 * **surfapp** fits a surface through an array of u and v points, nbupoints*nbvpoints. 
 * **grilapp** has the same function, but the x,y coordinates of the points are on a grid starting at x0,y0 with steps dx,dy. 
@@ -5622,7 +5622,7 @@ U direction of result surface corresponds columns of initial array of points.
 If **periodic_flag** = 1, algorithm uses first row of array as last row and builds periodical surface.
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # a surface using the same data as in the beziersurf 
 example sect 4.4 
 surfapp s 3 4 \ 
@@ -5630,7 +5630,7 @@ surfapp s 3 4 \
 0 10 2 10 10 3 20 10 2 \ 
 0 20 10 10 20 20 20 20 10 \ 
 0 30 0 10 30 0 20 30 0 
-~~~~~
+~~~~
 
 @subsection  occt_draw_6_9  Projections
 
@@ -5643,9 +5643,9 @@ Draw provides commands to project points/curves on curves/surfaces.
 @subsubsection  occt_draw_6_9_1 projponf
 
 Syntax:
-~~~~~
+~~~~{.php}
 projponf face pnt [extrema flag: -min/-max/-minmax] [extrema algo: -g(grad)/-t(tree)]
-~~~~~
+~~~~
 
 **projponf** projects point *pnt* on the face *face*.
 You can change the Extrema options:
@@ -5658,7 +5658,7 @@ You can change the Extrema options:
  -minmax - to look for MinMax solutions.
 
 **Example**
-~~~~~
+~~~~{.php}
 plane p 0 0 0 0 0 1
 mkface f p
 point pnt 5 5 10
@@ -5667,7 +5667,7 @@ projponf f pnt
 # proj dist = 10
 # uvproj = 5 5
 # pproj = 5 5 0
-~~~~~
+~~~~
 
 @subsection occt_draw_6_10  Constraints
 
@@ -5677,10 +5677,10 @@ projponf f pnt
 
 @subsubsection occt_draw_6_10_1  cirtang
 
-Syntax: 
-~~~~~
+Syntax:
+~~~~{.php}
 cirtang result [-t <Tolerance>] -c <curve> -p <point> -r <Radius>...
-~~~~~
+~~~~
 
 Builds all circles satisfying the condition: 
 1. the circle must be tangent to every given curve;
@@ -5690,35 +5690,35 @@ Builds all circles satisfying the condition:
 Only following set of input data is supported: Curve-Curve-Curve, Curve-Curve-Point, Curve-Curve-Radius, Curve-Point-Point, Curve-Point-Radius, Point-Point-Point, Point-Point-Radius. The solutions will be stored in variables *result_1*, *result_2*, etc.
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # a point, a line and a radius. 2 solutions of type Curve-Point-Radius (C-P-R)
 point p 0 0 
 line l 10 0 -1 1 
 cirtang c -p p -c l -r 4 
 == Solution of type C-P-R is: c_1 c_2
-~~~~~
+~~~~
 
 Additionally it is possible to create a circle(s) with given center and tangent to the given curve (Curve-Point type).
 
 **Example:** 
-~~~~~
+~~~~{.php}
 point pp 1 1
 2dbsplinecurve cc 1 2 0 2 1 2 -10 -5 1 10 -5 1
 cirtang r -p pp -c cc 
 == Solution of type C-P is: r_1 r_2 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_6_10_2  lintan
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 lintan name curve curve [angle] 
-~~~~~
+~~~~
 
 Builds all 2d lines tangent to two curves. If the third angle argument is given the second curve must be a line and **lintan** will build all lines tangent to the first curve and forming the given angle with the line. The angle is given in degrees. The solutions are named *name_1*, *name_2*, etc. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # lines tangent to 2 circles, 4 solutions 
 circle c1 -10 0 10 
 circle c2 10 0 5 
@@ -5729,7 +5729,7 @@ solutions: l1_1 l1_2
 circle c1 -10 0 1 
 line l 2 0 1 1 
 lintan l1 c1 l 15 
-~~~~~
+~~~~
 
 @subsection occt_draw_6_11  Display
 
@@ -5746,12 +5746,12 @@ On bspline curves and surfaces you can toggle the display of the knots with the
 
 @subsubsection occt_draw_6_11_1  dmod, discr, defle
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 dmode name [name ...] u/d 
 discr name [name ...] nbintervals 
 defle name [name ...] deflection 
-~~~~~
+~~~~
 
 **dmod** command allows choosing the display mode for a curve or a surface. 
 
@@ -5762,39 +5762,39 @@ In *d*, or discretization mode, a fixed number of points is computed. This numbe
 If the curve or the isolines seem to present too many angles, you can either increase the discretization or lower the deflection, depending on the mode. This will increase the number of points. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # increment the number of points on a big circle 
 circle c 0 0 50 50 
 discr 100 
 
 # change the mode 
 dmode c u 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_6_11_2   nbiso
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 nbiso name [names...] nuiso nviso 
-~~~~~
+~~~~
 
 Changes the number of isoparametric curves displayed on a surface in the U and V directions. On a bspline surface, isoparametric curves are displayed by default at knot values. Use *nbiso* to turn this feature off. 
 
 **Example:** 
 
 Let us  display 35 meridians and 15 parallels on a sphere:
-~~~~
+~~~~{.php}
 sphere s 20 
 nbiso s 35 15 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_6_11_3  clpoles, shpoles
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 clpoles name 
 shpoles name 
-~~~~~
+~~~~
 
 On bezier and bspline curves and surfaces, the control polygon is displayed by default: *clpoles* erases it and *shpoles* restores it. 
 
@@ -5802,28 +5802,28 @@ On bezier and bspline curves and surfaces, the control polygon is displayed by d
 
 Let us make a bezier curve and erase the poles 
 
-~~~~~
+~~~~{.php}
 beziercurve c 3 0 0 0 10 0 0 10 10 0 
 clpoles c 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_6_11_4  clknots, shknots
 
-Syntax:   
-~~~~~
+Syntax:
+~~~~{.php}
 clknots name 
 shknots name 
-~~~~~
+~~~~
 
 By default, knots on a bspline curve or surface are displayed with markers at the points with parametric value equal to the knots. *clknots* removes them and *shknots* restores them. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # hide the knots on a bspline curve 
 bsplinecurve bc 2 3 0 3 1 1 2 3 \ 
 10 0 7 1 7 0 7 1 3 0 8 1 0 0 7 1 
 clknots bc
-~~~~~
+~~~~
 
 
 @section occt_draw_7 Topology commands
@@ -5878,11 +5878,11 @@ In Draw, shapes are displayed using isoparametric curves. There is color coding
 
 @subsubsection occt_draw_7_1_1  isos, discretisation
 
-Syntax:                  
-~~~~~
+Syntax:
+~~~~{.php}
 isos [name ...][nbisos] 
 discretisation nbpoints
-~~~~~
+~~~~
  
 Determines or changes the number of isoparametric curves on shapes. 
 
@@ -5891,24 +5891,24 @@ The same number is used for the u and v directions. With no arguments, *isos* pr
 *discretisation* changes the default number of points used to display the curves. The default value is 30. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # Display only the edges (the wireframe) 
 isos 0 
-~~~~~
+~~~~
 
 **Warning**: don’t confuse *isos* and *discretisation* with the geometric commands *nbisos* and *discr*. 
 
 
 @subsubsection occt_draw_7_1_2  orientation, complement, invert, normals, range
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 orientation name [name ...] F/R/E/I 
 complement name [name ...] 
 invert name 
 normals s (length = 10), disp normals 
 range name value value 
-~~~~~
+~~~~
 
 * **orientation** -- assigns the orientation of simple and complex shapes to one of the following four values: *FORWARD, REVERSED, INTERNAL, EXTERNAL*. 
 * **complement** -- changes the current orientation of shapes to its complement: *FORWARD* to *REVERSED* and  *INTERNAL* to *EXTERNAL*. 
@@ -5917,7 +5917,7 @@ range name value value
 * **range** -- defines the length of a selected edge by defining the values of a starting point and an end point.
  
 **Example:** 
-~~~~~
+~~~~{.php}
 # to invert normals of a box 
 box b 10 20 30 
 normals b 5 
@@ -5934,16 +5934,16 @@ makedge e 1
 # to define the length of the edge as starting from 0 
 and finishing at 1 
 range e 0 1 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_7_1_3  explode, exwire, nbshapes
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 explode name [C/So/Sh/F/W/E/V] 
 exwire name 
 nbshapes name 
-~~~~~
+~~~~
 
 **explode** extracts subshapes from an entity. The subshapes will be named *name_1*, *name_2*, ... Note that they are not copied but shared with the original. 
 
@@ -5954,7 +5954,7 @@ With name only, **explode** will extract the first sublevel of shapes: the shell
 **nbshapes** counts the number of shapes of each type in an entity. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # on a box 
 box b 10 20 30 
 
@@ -5985,16 +5985,16 @@ SOLID : 1
 COMPSOLID : 0 
 COMPOUND : 0 
 SHAPE : 34 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_7_1_4  emptycopy, add, compound
 
-Syntax:                  
-~~~~~
+Syntax:
+~~~~{.php}
 emptycopy [newname] name 
 add name toname 
 compound [name ...] compoundname 
-~~~~~
+~~~~
 
 **emptycopy** returns an empty shape with the same orientation, location, and geometry as the target shape, but with no sub-shapes. If the **newname** argument is not given, the new shape is stored with the same name. This command is used to modify a frozen shape. A frozen shape is a shape used by another one. To modify it, you must **emptycopy** it. Its subshape may be reinserted with the **add** command. 
 
@@ -6013,26 +6013,26 @@ compound [name ...] compoundname
 On the other hand, **compound** is a safe way to achieve a similar result. It creates a compound from shapes. If no shapes are given, the compound is empty. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # a compound with three boxes 
 box b1 0 0 0 1 1 1 
 box b2 3 0 0 1 1 1 
 box b3 6 0 0 1 1 1 
 compound b1 b2 b3 c 
-~~~~~
+~~~~
 
 
 @subsubsection occt_draw_7_1_5  compare
 
 Syntax:
-~~~~~
+~~~~{.php}
 compare shape1 shape2
-~~~~~
+~~~~
 
 **compare** compares the two shapes *shape1* and *shape2* using the methods *TopoDS_Shape::IsSame()* and *TopoDS_Shape::IsEqual()*.
 
 **Example**
-~~~~~
+~~~~{.php}
 box b1 1 1 1
 copy b1 b2
 compare b1 b2
@@ -6046,24 +6046,24 @@ compare b1 b2
 box b2 1 1 1
 compare b1 b2
 # shapes are not same
-~~~~~
+~~~~
 
 @subsubsection occt_draw_7_1_6  issubshape
 
 Syntax:
-~~~~~
+~~~~{.php}
 issubshape subshape shape
-~~~~~
+~~~~
 
 **issubshape** checks if the shape *subshape* is sub-shape of the shape *shape* and gets its index in the shape.
 
 **Example**
-~~~~~
+~~~~{.php}
 box b 1 1 1
 explode b f
 issubshape b_2 b
 # b_2 is sub-shape of b. Index in the shape: 2.
-~~~~~
+~~~~
 
 
 @subsection occt_draw_7_2  Curve and surface topology
@@ -6080,47 +6080,47 @@ This group of commands is used to create topology from shapes and to extract sha
 
 @subsubsection occt_draw_7_2_1  vertex
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 vertex name [x y z / p edge] 
-~~~~~
+~~~~
 
 Creates a vertex at either a 3d location x,y,z or the point at parameter p on an edge. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 vertex v1 10 20 30 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_7_2_1a  mkpoint
 
 Syntax:
-~~~~~
+~~~~{.php}
 mkpoint name vertex
-~~~~~
+~~~~
 
 Creates a point from the coordinates of a given vertex.
 
 **Example:** 
-~~~~~
+~~~~{.php}
 mkpoint p v1
-~~~~~
+~~~~
 
 @subsubsection occt_draw_7_2_2  edge, mkedge, uisoedge, visoedge
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 edge name vertex1 vertex2 
 mkedge edge curve [surface] [pfirst plast] [vfirst [pfirst] vlast [plast]] 
 uisoedge edge face u v1 v2 
 visoedge edge face v u1 u2 
-~~~~~
+~~~~
 
 * **edge** creates a straight line edge between two vertices. 
 * **mkedge** generates edges from curves<.Two parameters can be given for the vertices: the first and last parameters of the curve are given by default. Vertices can also be given with their parameters, this option allows blocking the creation of new vertices. If the parameters of the vertices are not given, they are computed by projection on the curve. Instead of a 3d curve, a 2d curve and a surface can be given. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # straight line edge 
 vertex v1 10 0 0 
 vertex v2 10 10 0 
@@ -6134,12 +6134,12 @@ mkedge e2 c 0 pi/2
 # The trimming is removed by mkedge 
 trim c c 0 pi/2 
 mkedge e2 c 
-~~~~~
+~~~~
 
 * **visoedge** and **uisoedge** are commands that generate a *uiso* parameter edge or a *viso* parameter edge. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # to create an edge between v1 and v2 at point u 
 # to create the example plane 
 plane p 
@@ -6153,16 +6153,16 @@ mkface p p
 # to create the edge in the plane at the u axis point 
 0.5, and between the v axis points v=0.2 and v =0.8 
 uisoedge e p 0.5 0.20 0.8 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_7_2_3  wire, polyline, polyvertex
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 wire wirename e1/w1 [e2/w2 ...] 
 polyline name x1 y1 z1 x2 y2 z2 ... 
 polyvertex name v1 v2 ... 
-~~~~~
+~~~~
 
 **wire** creates a wire from edges or wires. The order of the elements should ensure that the wire is connected, and vertex locations will be compared to detect connection. If the vertices are different, new edges will be created to ensure topological connectivity. The original edge may be copied in the new one. 
 
@@ -6171,20 +6171,20 @@ polyvertex name v1 v2 ...
 **polyvertex** creates a polygonal wire from vertices. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # create two polygonal wires 
 # glue them and define as a single wire 
 polyline w1 0 0 0 10 0 0 10 10 0 
 polyline w2 10 10 0 0 10 0 0 0 0 
 wire w w1 w2 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_7_2_4  profile
 
 Syntax       
-~~~~~
+~~~~{.php}
 profile name [code values] [code values] ... 
-~~~~~
+~~~~
 
 
 **profile** builds a profile in a plane using a moving point and direction. By default, the profile is closed and a face is created. The original point is 0 0, and direction is 1 0 situated in the XY plane. 
@@ -6225,14 +6225,14 @@ The profile shape definition is the suffix; no suffix produces a face, *w* is a
 Code letters are not case-sensitive. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # to create a triangular plane using a vertex at the
 origin, in the xy plane 
 profile p O 0 0 0 X 1 Y 0 x 1 y 1 
-~~~~~
+~~~~
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # to create a contour using the different code 
 possibilities 
 
@@ -6271,14 +6271,14 @@ profile p F 1 0 x 2 y 1 c 1 45 l 1 tt 1.5 1.5 xx 0.2 yy 2 c 1 290 ix 0 r 90 ix -
 
 # to create the plane with the same contour 
 profile p F 1 0 x 2 y 1 c 1 45 l 1 tt 1.5 1.5 xx 0.2 yy 2 c 1 290 ix 0 r 90 ix -0.3 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_7_2_5   bsplineprof
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 bsplineprof name [S face] [W WW] 
-~~~~~
+~~~~
 
 * for an edge : \<digitizes\> ... <mouse button 2>
 * to end profile : <mouse button 3>
@@ -6290,7 +6290,7 @@ Builds a profile in the XY plane from digitizes. By default the profile is close
 The profile shape definition is the suffix; no suffix produces a face, **w** is a closed wire, **ww** is an open wire. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 #to view the xy plane 
 top 
 #to create a 2d curve with the mouse 
@@ -6303,18 +6303,18 @@ bsplineprof res
 == 
 # click mb1 to create the second curve 
 # click mb3 to create the face 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_7_2_6  mkoffset
 
 **mkoffset** creates a parallel wire in the same plane using a face or an existing continuous set of wires as a reference. The number of occurrences is not limited. 
 The offset distance defines the spacing and the positioning of the occurrences. 
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 mkoffset result shape nboffset stepoffset [jointype(a/i) [alt]]
-~~~~~
-where:
+~~~~
+Where:
 * *result* - the base name for the resulting wires. The index of the occurrence (starting with 1) will be added to this name, so the resulting wires will have the names - *result_1*, *result_2* ...;
 * *shape* - input shape (face or compound of wires);
 * *nboffset* - the number of the parallel occurrences;
@@ -6324,7 +6324,7 @@ where:
 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # Create a box and select a face 
 box b 1 2 3 
 explode b f 
@@ -6338,12 +6338,12 @@ mkoffset r b_1 3 2 i
 
 # Create one interior parallel contour with an offset value of 0.4 
 mkoffset r b_1 1 -0.4 
-~~~~~
+~~~~
 
 **Note** that on a concave input contour for an interior step *mkoffset* command may produce several wires which will be contained in a single compound.
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # to create the example contour 
 profile p F 0 0 x 2 y 4 tt 1 1 tt 0 4 w 
 # creates an incoherent interior offset 
@@ -6352,22 +6352,22 @@ mkoffset r p 1 -0.50
 # creates two incoherent wires 
 mkoffset r p 1 -0.55 
 # r_1 is a compound of two wires
-~~~~~
+~~~~
 
 @subsubsection occt_draw_7_2_7  mkplane, mkface
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 mkplane name wire 
 mkface name surface [ufirst ulast vfirst vlast] 
-~~~~~
+~~~~
 
 **mkplane** generates a face from a planar wire. The planar surface will be constructed with an orientation which keeps the face inside the wire. 
 
 **mkface** generates a face from a surface. Parameter values can be given to trim a rectangular area. The default boundaries are those of the surface. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # make a polygonal face 
 polyline f 0 0 0 20 0 0 20 10 0 10 10 0 10 20 0 0 20 0 0 0 0 
 mkplane f f 
@@ -6376,40 +6376,40 @@ mkplane f f
 cylinder g 10 
 trim g g -pi/3 pi/2 0 15 
 mkface g g 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_7_2_8  mkcurve, mksurface
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 mkcurve curve edge 
 mksurface name face 
-~~~~~
+~~~~
 
 **mkcurve** creates a 3d curve from an edge. The curve will be trimmed to the edge boundaries. 
 
 **mksurface** creates a surface from a face. The surface will not be trimmed. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # make a line 
 vertex v1 0 0 0 
 vertex v2 10 0 0 
 edge e v1 v2 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_7_2_9  pcurve
 
-Syntax:      
+Syntax:
 
-~~~~~
+~~~~{.php}
 pcurve [name edgename] facename 
-~~~~~
+~~~~
 
 Extracts the 2d curve of an edge on a face. If only the face is specified, the command extracts all the curves and colors them according to their orientation. This is useful in checking to see if the edges in a face are correctly oriented, i.e. they turn counter-clockwise. To make curves visible, use a fitted 2d view. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # view the pcurves of a face 
 plane p 
 trim p p -1 1 -1 1 
@@ -6417,14 +6417,14 @@ mkface p p
 av2d; # a 2d view 
 pcurve p 
 2dfit 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_7_2_10  chfi2d
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 chfi2d result face [edge1 edge2 (F radius/CDD d1 d2/CDA d ang) .... 
-~~~~~
+~~~~
 
 
 Creates chamfers and fillets on 2D objects. Select two adjacent edges and: 
@@ -6440,7 +6440,7 @@ The distance is the length value from the edge between the two selected faces in
 
 Let us create a 2d fillet: 
 
-~~~~~
+~~~~{.php}
 top 
 profile p x 2 y 2 x -2 
 chfi2d cfr p . . F 0.3 
@@ -6448,22 +6448,22 @@ chfi2d cfr p . . F 0.3
 #select an edge 
 ==Pick an object 
 #select an edge 
-~~~~~
+~~~~
 
 Let us create a 2d chamfer using two distances:
  
-~~~~~
+~~~~{.php}
 profile p x 2 y 2 x -2 
 chfi2d cfr p . . CDD 0.3 0.6 
 ==Pick an object 
 #select an edge 
 ==Pick an object 
 #select an edge 
-~~~~~
+~~~~
 
 Let us create a 2d chamfer using a defined distance and angle 
 
-~~~~~
+~~~~{.php}
 top 
 profile p x 2 y 2 x -2 
 chfi2d cfr p . . CDA 0.3 75 
@@ -6471,20 +6471,20 @@ chfi2d cfr p . . CDA 0.3 75
 #select an edge 
 ==Pick an object 
 #select an edge 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_7_2_11  nproject
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 nproject pj e1 e2 e3 ... surf -g -d [dmax] [Tol 
 [continuity [maxdeg [maxseg]]] 
-~~~~~
+~~~~
 
 Creates a shape projection which is normal to the target surface. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 # create a curved surface 
 line l 0 0 0 1 0 0 
 trim l l 0 2 
@@ -6509,7 +6509,7 @@ mkedge e c
 donly p e 
 # create the normal projection of the shape(circle) 
 nproject r e p 
-~~~~~
+~~~~
 
 
 @subsection occt_draw_7_3  Primitives
@@ -6523,11 +6523,11 @@ Primitive commands make it possible to create simple shapes. They include:
 
 @subsubsection occt_draw_7_3_1  box, wedge
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 box name [x y z] dx dy dz 
 wedge name dx dy dz ltx / xmin zmin xmax xmax 
-~~~~~
+~~~~
 
 **box** creates a box parallel to the axes with dimensions *dx,dy,dz*. *x,y,z* is the corner of the box. It is the default origin. 
 
@@ -6536,7 +6536,7 @@ wedge name dx dy dz ltx / xmin zmin xmax xmax
 The other faces are defined between these faces. The face in the *y=yd* plane may be degenerated into a line if *ltx = 0*, or a point if *xmin = xmax* and *ymin = ymax*. In these cases, the line and the point both have 5 faces each. To position the wedge use the *ttranslate* and *trotate* commands. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # a box at the origin 
 box b1 10 20 30 
 
@@ -6551,18 +6551,18 @@ wedge w2 10 20 30 0
 
 # a pyramid 
 wedge w3 20 20 20 10 10 10 10 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_7_3_2  pcylinder, pcone, psphere, ptorus
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 pcylinder name [plane] radius height [angle] 
 pcone name [plane] radius1 radius2 height [angle] 
 pcone name [plane] radius1 radius2 height [angle] 
 psphere name [plane] radius1 [angle1 angle2] [angle] 
 ptorus name [plane] radius1 radius2 [angle1 angle2] [angle] 
-~~~~~
+~~~~
 
 All these commands create solid blocks in the default coordinate system, using the Z axis as the axis of revolution and the X axis as the origin of the angles. To use another system, translate and rotate the resulting solid or use a plane as first argument to specify a coordinate system. All primitives have an optional last argument which is an angle expressed in degrees and located on the Z axis, starting from the X axis. The default angle is 360. 
 
@@ -6575,7 +6575,7 @@ All these commands create solid blocks in the default coordinate system, using t
 **ptorus** creates a solid torus with the given radii, centered on the origin, which is a point along the z axis. If two angles increasing in degree in the range 0 -- 360 are given, the solid will be bounded by two planar surfaces at those positions on the circle. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # a can shape 
 pcylinder cy 5 10 
 
@@ -6587,24 +6587,24 @@ psphere sp 10 270
 
 # half torus 
 ptorus to 20 5 0 90 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_7_3_3  halfspace
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 halfspace result face/shell x y z 
-~~~~~
+~~~~
 
 **halfspace** creates an infinite solid volume based on a face in a defined direction. This volume can be used to perform the boolean operation of cutting a solid by a face or plane. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 box b 0 0 0 1 2 3 
 explode b f 
 ==b_1 b_2 b_3 b_4 b_5 b_6 
 halfspace hr b_3 0.5 0.5 0.5 
-~~~~~
+~~~~
 
 
 @subsection occt_draw_7_4  Sweeping
@@ -6620,50 +6620,50 @@ Sweeping creates shapes by sweeping out a shape along a defined path:
 
 @subsubsection occt_draw_7_4_1  prism
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 prism result base dx dy dz [Copy | Inf | SemiInf] 
-~~~~~
+~~~~
 
 Creates a new shape by sweeping a shape in a direction. Any shape can be swept: a vertex gives an edge; an edge gives a face; and a face gives a solid. 
 
 The shape is swept along the vector *dx dy dz*. The original shape will be shared in the result unless *Copy* is specified. If *Inf* is specified the prism is infinite in both directions. If *SemiInf* is specified the prism is infinite in the *dx,dy,dz* direction, and the length of the vector has no importance. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # sweep a planar face to make a solid 
 polyline f 0 0 0 10 0 0 10 5 0 5 5 0 5 15 0 0 15 0 0 0 0 
 mkplane f f 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_7_4_2  revol
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 revol result base x y z dx dy dz angle [Copy] 
-~~~~~
+~~~~
 
 Creates a new shape by sweeping a base shape through an angle along the axis *x,y,z dx,dy,dz*. As with the prism command, the shape can be of any type and is not shared if *Copy* is specified. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # shell by wire rotation 
 polyline w 0 0 0 10 0 0 10 5 0 5 5 0 5 15 0 0 15 0 
 revol s w 20 0 0 0 1 0 90 
-~~~~~
+~~~~
 
 
 @subsubsection occt_draw_7_4_3  pipe
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 pipe name wire_spine Profile 
-~~~~~
+~~~~
 
 Creates a new shape by sweeping a shape known as the profile along a wire known as the spine. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # sweep a circle along a bezier curve to make a solid 
 pipe 
 
@@ -6675,19 +6675,19 @@ mkedge profile profile
 wire profile profile 
 mkplane profile profile 
 pipe p spine profile 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_7_4_4  mksweep, addsweep, setsweep, deletesweep, buildsweep, simulsweep
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 mksweep wire 
 addsweep wire[vertex][-M][-C] [auxiilaryshape]
 deletesweep wire 
 setsweep options [arg1 [arg2 [...]]] 
 simulsweep r [n] [option] 
 buildsweep [r] [option] [Tol] 
-~~~~~
+~~~~
 
 options are : 
  * *-FR* : Tangent and Normal are defined by a Frenet trihedron 
@@ -6708,7 +6708,7 @@ At least one other wire is used to define the sweep profile.
 * **buildsweep** -- creates the sweep using the arguments defined by all the commands. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 #create a sweep based on a semi-circular wire using the 
 Frenet algorithm 
 #create a circular figure 
@@ -6727,20 +6727,20 @@ setsweep -CF
 addsweep w -R 
 # to simulate the sweep with a visual approximation 
 simulsweep w 3 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_7_4_5  thrusections
 
-Syntax:  
-~~~~~
+Syntax:
+~~~~{.php}
 thrusections [-N] result issolid isruled wire1 wire2 [..wire..] 
-~~~~~
+~~~~
 
 **thrusections** creates a shape using wires that are positioned in different planes. Each wire selected must have the same number of edges and vertices. 
 A bezier curve is generated between the vertices of each wire. The option *[-N]* means that no check is made on wires for direction. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 #create three wires in three planes 
 polyline w1 0 0 0 5 0 0 5 5 0 2 3 0 
 polyline w2 0 1 3 4 1 3 4 4 3 1 3 3 
@@ -6750,7 +6750,7 @@ thrusections th issolid isruled w1 w2 w3
 ==thrusections th issolid isruled w1 w2 w3 
 Tolerances obtenues   -- 3d : 0 
 -- 2d : 0 
-~~~~~
+~~~~
 
 
 @subsection occt_draw_7_5  Topological transformation
@@ -6764,15 +6764,15 @@ Transformations are applications of matrices. When the transformation is nondefo
 
 @subsubsection occt_draw_7_5_1   tcopy
 
-Syntax: 
-~~~~~
+Syntax:
+~~~~{.php}
 tcopy name toname [name toname ...] 
-~~~~~
+~~~~
 
 Copies the structure of one shape, including the geometry, into another, newer shape. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # create an edge from a curve and copy it 
 beziercurve c 3 0 0 0 10 0 0 20 10 0 
 mkedge e1 c 
@@ -6780,22 +6780,22 @@ ttranslate e1 0 5 0
 tcopy e1 e2 
 ttranslate e2 0 5 0 
 # now modify the curve, only e1 and e2 will be modified 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_7_5_2   tmove, treset
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 tmove name [name ...] shape 
 reset name [name ...] 
-~~~~~
+~~~~
 
 **tmove** and **reset** modify the location, or the local coordinate system of a shape. 
 
 **tmove** applies the location of a given shape to other shapes. **reset** restores one or several shapes it to its or their original coordinate system(s). 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # create two boxes 
 box b1 10 10 10 
 box b2 20 0 0 10 10 10 
@@ -6805,15 +6805,15 @@ ttranslate b1 0 10 0
 tmove b2 b1 
 # return to original positions 
 reset b1 b2 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_7_5_3   ttranslate, trotate
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 ttranslate [name ...] dx dy dz 
 trotate [name ...] x y z dx dy dz angle 
-~~~~~
+~~~~
 
 **ttranslate** translates a set of shapes by a given vector, and **trotate** rotates them by a given angle around an axis. Both commands only modify the location of the shape. 
 When creating multiple shapes, the same location is used for all the shapes. (See *toto.tcl* example below. Note that the code of this file can also be directly executed in interactive mode.) 
@@ -6821,7 +6821,7 @@ When creating multiple shapes, the same location is used for all the shapes. (Se
 Locations are very economic in the data structure because multiple occurrences of an object share the topological description.
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # make rotated copies of a sphere in between two cylinders 
 # create a file source toto.tcl 
 # toto.tcl code: 
@@ -6841,29 +6841,29 @@ ttranslate s 25 0 12.5
 
 # call the source file for multiple copies 
 source toto.tcl 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_7_5_4   tmirror, tscale
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 tmirror name x y z dx dy dz 
 tscale name x y z scale 
-~~~~~
+~~~~
 
 * **tmirror** makes a mirror copy of a shape about a plane x,y,z dx,dy,dz. 
 
 * **Tscale** applies a central homotopic mapping to a shape. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # mirror a portion of cylinder about the YZ plane 
 pcylinder c1 10 10 270 
 copy c1 c2 
 tmirror c2 15 0 0 1 0 0 
 # and scale it 
 tscale c1 0 0 0 0.5 
-~~~~~
+~~~~
 
 
 @subsection occt_draw_7_6  Old Topological operations
@@ -6879,11 +6879,11 @@ These commands are no longer supported, so the result may be unpredictable.
 Use the commands bfuse, bcut, bcommon instead.
 
 Syntax:
-~~~~~
+~~~~{.php}
 fuse name shape1 shape2 
 cut name shape1 shape2 
 common name shape1 shape2 
-~~~~~
+~~~~
 
 **fuse** creates a new shape by a boolean operation on two existing shapes. The new shape contains both originals intact. 
 
@@ -6892,7 +6892,7 @@ common name shape1 shape2
 **common** creates a new shape which contains only what is in common between the two original shapes in their intersection. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # all four boolean operations on a box and a cylinder 
 
 box b 0 -10 5 20 20 10 
@@ -6909,7 +6909,7 @@ ttranslate s3 0 40 0
 
 common s4 b c 
 ttranslate s4 0 -40 0 
-~~~~~
+~~~~
 
 
 @subsubsection occt_draw_7_6_2  section, psection
@@ -6917,18 +6917,18 @@ ttranslate s4 0 -40 0
 These commands are no longer supported, so the result may be unpredictable.
 Use the command **bsection** instead.
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 section result shape1 shape2 
 psection name shape plane 
-~~~~~
+~~~~
 
 **section** creates a compound object consisting of the edges for the intersection curves on the faces of two shapes. 
 
 **psection** creates a planar section consisting of the edges for the intersection curves on the faces of a shape and a plane. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # section line between a cylinder and a box 
 pcylinder c 10 20 
 box b 0 0 5 15 15 15 
@@ -6939,26 +6939,26 @@ section s b c
 pcone c 10 30 30 
 plane p 0 0 15 1 1 2 
 psection s c p 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_7_6_3  sewing
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 sewing result [tolerance] shape1 shape2 ... 
-~~~~~
+~~~~
 
 **Sewing** joins shapes by connecting their adjacent or near adjacent edges. Adjacency can be redefined by modifying the tolerance value. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # create two adjacent boxes 
 box b 0 0 0 1 2 3 
 box b2 0 2 0 1 2 3 
 sewing sr b b2 
 whatis sr 
 sr is a shape COMPOUND FORWARD Free Modified 
-~~~~~
+~~~~
 
 @subsection occt_draw_7_7 New Topological operations
 
@@ -6985,33 +6985,33 @@ Blending is the creation of a new shape by rounding edges to create a fillet.
 
 @subsubsection occt_draw_7_8_1  depouille
 
-Syntax: 
-~~~~~
+Syntax:
+~~~~{.php}
 dep result shape dirx diry dirz face angle x y x dx dy dz [face angle...] 
-~~~~~
+~~~~
 
 Creates a new shape by drafting one or more faces of a shape. 
 
 Identify the shape(s) to be drafted, the drafting direction, and the face(s) with an angle and an axis of rotation for each face. You can use dot syntax to identify the faces. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # draft a face of a box 
 box b 10 10 10 
 explode b f 
 == b_1 b_2 b_3 b_4 b_5 b_6 
 
 dep a b 0 0 1 b_2 10 0 10 0 1 0 5 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_7_8_2  chamf
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 chamf newname shape edge face S dist 
 chamf newname shape edge face dist1 dist2 
 chamf newname shape edge face A dist angle 
-~~~~~
+~~~~
 
 Creates a chamfer along the edge between faces using: 
 
@@ -7024,7 +7024,7 @@ Use the dot syntax to select the faces and edges.
 **Examples:**
 
 Let us create a chamfer based on equal distances from the edge (45 degree angle):
-~~~~~
+~~~~{.php}
 # create a box 
 box b 1 2 3 
 chamf ch b . . S 0.5 
@@ -7032,40 +7032,40 @@ chamf ch b . . S 0.5
 # select an edge 
 ==Pick an object 
 # select an adjacent face 
-~~~~~
+~~~~
 
 Let us create a chamfer based on different distances from the selected edge:
-~~~~~
+~~~~{.php}
 box b 1 2 3 
 chamf ch b . . 0.3 0.4 
 ==Pick an object 
 # select an edge 
 ==Pick an object 
 # select an adjacent face
-~~~~~
+~~~~
  
 Let us create a chamfer based on a distance from the edge and an angle:
  
-~~~~~
+~~~~{.php}
 box b 1 2 3 
 chamf ch b . . A 0.4 30 
 ==Pick an object 
 # select an edge 
 ==Pick an object 
 # select an adjacent face 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_7_8_3  blend
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 blend result object rad1 ed1 rad2 ed2 ... [R/Q/P] 
-~~~~~
+~~~~
 
 Creates a new shape by filleting the edges of an existing shape. The edge must be inside the shape. You may use the dot syntax. Note that the blend is propagated to the edges of tangential planar, cylindrical or conical faces. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # blend a box, click on an edge 
 box b 20 20 20 
 blend b b 2 . 
@@ -7084,54 +7084,54 @@ blend b b 2 .
 ==- FilDS 0s 
 ==- Reconstruction 0.06s 
 ==- SetRegul 0s 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_7_8_4  bfuseblend
 
 Syntax:
-~~~~~
+~~~~{.php}
 bfuseblend name shape1 shape2 radius [-d]
-~~~~~
+~~~~
  
 Creates a boolean fusion of two shapes and then blends (fillets) the intersection edges using the given radius.
 Option [-d] enables the Debugging mode in which the error messages, if any, will be printed.
 
 **Example:**
-~~~~~
+~~~~{.php}
 # fuse-blend two boxes
 box b1 20 20 5
 copy b1 b2
 ttranslate b2 -10 10 3
 bfuseblend a b1 b2 1
-~~~~~
+~~~~
 
 @subsubsection occt_draw_7_8_4a  bcutblend
 
 Syntax:
-~~~~~
+~~~~{.php}
 bcutblend name shape1 shape2 radius [-d]
-~~~~~
+~~~~
 
 Creates a boolean cut of two shapes and then blends (fillets) the intersection edges using the given radius.
 Option [-d] enables the Debugging mode in which the error messages, if any, will be printed.
 
 **Example:**
-~~~~~
+~~~~{.php}
 # cut-blend two boxes
 box b1 20 20 5
 copy b1 b2
 ttranslate b2 -10 10 3
 bcutblend a b1 b2 1
-~~~~~
+~~~~
 
 @subsubsection occt_draw_7_8_5  mkevol, updatevol, buildevol
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 mkevol result object (then use updatevol) [R/Q/P] 
 updatevol edge u1 radius1 [u2 radius2 ...] 
 buildevol 
-~~~~~
+~~~~
 
 These three commands work together to create fillets with evolving radii. 
 
@@ -7140,7 +7140,7 @@ These three commands work together to create fillets with evolving radii.
 * **buildevol** produces the result described previously in **mkevol** and **updatevol**. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # makes an evolved radius on a box 
 box b 10 10 10 
 mkevol b b 
@@ -7168,7 +7168,7 @@ buildevol
 ==- FilDS 0.01s 
 ==- Reconstruction 0.04s 
 ==- SetRegul 0s 
-~~~~~
+~~~~
 
 
 @subsection occt_draw_defeaturing Defeaturing
@@ -7176,9 +7176,9 @@ buildevol
 Draw command **removefeatures** is intended for performing @ref occt_modalg_defeaturing "3D Model Defeaturing", i.e. it performs the removal of the requested features from the shape.
 
 Syntax:
-~~~~
+~~~~{.php}
 removefeatures result shape f1 f2 ... [-nohist] [-parallel]
-
+~~~~
 Where:
 result   - result of the operation;
 shape    - the shape to remove the features from;
@@ -7187,7 +7187,7 @@ f1, f2   - features to remove from the shape;
 Options:
 nohist   - disables the history collection;
 parallel - enables the parallel processing mode.
-~~~~
+
 
 
 @subsection occt_draw_makeperiodic 3D Model Periodicity
@@ -7204,15 +7204,15 @@ The command makes the shape periodic in the required directions with the require
 If trimming is given it trims the shape to fit the requested period.
 
 Syntax:
-~~~~
+~~~~{.php}
 makeperiodic result shape [-x/y/z period [-trim first]]
-
+~~~~
 Where:
 result        - resulting periodic shape;
 shape         - input shape to make it periodic:
 -x/y/z period - option to make the shape periodic in X, Y or Z direction with the given period;
 -trim first   - option to trim the shape to fit the required period, starting the period in first.
-~~~~
+
 
 @subsubsection occt_draw_makeperiodic_repeatshape repeatshape
 
@@ -7221,13 +7221,13 @@ The result contains the all the repeated shapes glued together.
 The command should be called after **makeperiodic** command.
 
 Syntax:
-~~~~
+~~~~{.php}
 repeatshape result -x/y/z times
+~~~~
 
 Where:
 result       - resulting shape;
 -x/y/z times - direction for repetition and number of repetitions (negative number of times means the repetition in negative direction).
-~~~~
 
 @subsubsection occt_draw_makeperiodic_periodictwins periodictwins
 
@@ -7236,13 +7236,13 @@ All periodic twins should have the same geometry.
 The command should be called after **makeperiodic** command.
 
 Syntax:
-~~~~
+~~~~{.php}
 periodictwins twins shape
-
+~~~~
 Where:
 twins - periodic twins for the given shape
 shape - shape to find the twins for
-~~~~
+
 
 @subsubsection occt_draw_makeperiodic_clearrepetitions clearrepetitions
 
@@ -7265,13 +7265,13 @@ Draw module for @ref occt_modalg_makeconnected "making the touching same-dimensi
 The command makes the input touching shapes connected.
 
 Syntax:
-~~~~
+~~~~{.php}
 makeconnected result shape1 shape2 ...
+~~~~
 
 Where:
 result            - resulting connected shape.
 shape1 shape2 ... - shapes to be made connected.
-~~~~
 
 @subsubsection occt_draw_makeconnected_cmaterialson cmaterialson
 
@@ -7279,14 +7279,14 @@ The command returns the materials located on the requested side of the shape.
 The command should be called after the shapes have been made connected, i.e. after the command **makeconnected**.
 
 Syntax:
-~~~~
+~~~~{.php}
 cmaterialson result +/- shape
-
+~~~~
 Where:
 result - material shapes
 shape  - shape for which the materials are needed
 +/-    - side of a given shape ('+' for positive side, '-' - for negative).
-~~~~
+
 
 @subsubsection occt_draw_makeconnected_cmakeperiodic cmakeperiodic
 
@@ -7294,15 +7294,15 @@ The command makes the connected shape periodic in the required directions with t
 The command should be called after the shapes have been made connected, i.e. after the command **makeconnected**.
 
 Syntax:
-~~~~
+~~~~{.php}
 cmakeperiodic result [-x/y/z period [-trim first]]
+~~~~ 
 Where:
 result        - resulting periodic shape;
 shape         - input shape to make it periodic:
 -x/y/z period - option to make the shape periodic in X, Y or Z direction with the given period;
 -trim first   - option to trim the shape to fit the required period, starting the period in first.
-~~~~
+
 
 @subsubsection occt_draw_makeconnected_crepeatshape crepeatshape
 
@@ -7310,13 +7310,13 @@ The command repeats the connected periodic shape in the required periodic direct
 The command should be called after the shapes have been made connected and periodic, i.e. after the commands **makeconnected** and **cmakeperiodic**.
 
 Syntax:
-~~~~
+~~~~{.php}
 crepeatshape result -x/y/z times
-
+~~~~
 Where:
 result       - resulting shape;
 -x/y/z times - direction for repetition and number of repetitions (negative number of times means the repetition in negative direction).
-~~~~
+
 
 @subsubsection occt_draw_makeconnected_cperiodictwins cperiodictwins
 
@@ -7324,13 +7324,13 @@ The command returns all periodic twins for the shape.
 The command should be called after the shapes have been made connected and periodic, i.e. after the commands **makeconnected** and **cmakeperiodic**.
 
 Syntax:
-~~~~
+~~~~{.php}
 cperiodictwins twins shape
+~~~~
 
 Where:
 twins - periodic twins of a shape.
 shape - input shape.
-~~~~
 
 @subsubsection occt_draw_makeconnected_cclearrepetitions cclearrepetitions
 
@@ -7339,7 +7339,7 @@ The command should be called after the shapes have been made connected, periodic
 Otherwise the command will have no effect.
 
 Syntax:
-~~~~
+~~~~{.php}
 cclearrepetitions [result]
 ~~~~
 
@@ -7360,12 +7360,12 @@ Analysis of shapes includes commands to compute length, area, volumes and inerti
 
 @subsubsection occt_draw_7_9_1  lprops, sprops, vprops
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 lprops shape  [x y z] [-skip] [-full] [-tri]
 sprops shape [epsilon] [c[losed]] [x y z] [-skip] [-full] [-tri]
 vprops shape [epsilon] [c[losed]] [x y z] [-skip] [-full] [-tri] 
-~~~~~
+~~~~
 
 * **lprops** computes the mass properties of all edges in the shape with a linear density of 1;
 * **sprops** of all faces with a surface density of 1;
@@ -7385,7 +7385,7 @@ If epsilon is given, exact geometry (curves, surfaces) are used for calculations
 All three commands print the mass, the coordinates of the center of gravity, the matrix of inertia and the moments. Mass is either the length, the area or the volume. The center and the main axis of inertia are displayed. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # volume of a cylinder 
 pcylinder c 10 20 
 vprops c 
@@ -7408,15 +7408,15 @@ Moments :
 IX = 366519.141446336 
 IY = 366519.141444962 
 I.Z = 314159.265357595 
-~~~~~
+~~~~
 
 
 @subsubsection occt_draw_7_9_2   bounding
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 bounding {-s shape | -c xmin ymin zmin xmax ymax zmax} [-obb] [-shape name] [-dump] [-notriangulation] [-perfmeter name NbIters] [-save xmin ymin zmin xmax ymax zmax] [-nodraw] [-optimal] [-exttoler]
-~~~~~
+~~~~
 
 Computes and displays the bounding box (BndBox) of a shape. The bounding box is a cuboid that circumscribes the source shape.
 Generally, bounding boxes can be divided into two main types:
@@ -7426,16 +7426,16 @@ Generally, bounding boxes can be divided into two main types:
 Detailed information about this command is available in DRAW help-system (enter "help bounding" in DRAW application).
   
 **Example 1: Creation of AABB with given corners** 
-~~~~~
+~~~~{.php}
 bounding -c 50 100 30 180 200 100 -shape result
 # look at the box
 vdisplay result
 vfit
 vsetdispmode 1
-~~~~~
+~~~~
 
 **Example 2: Compare AABB and OBB** 
-~~~~~
+~~~~{.php}
 # Create a torus and rotate it
 ptorus t 20 5 
 trotate t 5 10 15 1 1 1 28
@@ -7474,11 +7474,11 @@ vprops ra 1.0e-12
 # Let us check this value
 dval (x2-x1)*(y2-y1)*(z2-z1)
 ==64949.886543606823
-~~~~~
+~~~~
 
 The same result is obtained.
 
-~~~~~
+~~~~{.php}
 # Create OBB from the torus
 bounding -s t -shape ro -dump -obb
 ==Oriented bounding box
@@ -7493,37 +7493,37 @@ bounding -s t -shape ro -dump -obb
 # Compute the volume of OBB
 vprops ro 1.0e-12
 ==Mass :         28694.7
-~~~~~
+~~~~
 
 As we can see, the volume of OBB is significantly less than the volume of AABB.
 
 @subsubsection occt_draw_7_9_2a   isbbinterf
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 isbbinterf shape1 shape2 [-o]
-~~~~~
+~~~~
 
 Checks whether the bounding boxes created from the given shapes are interfered. If "-o"-option is switched on then the oriented boxes will be checked. Otherwise, axis-aligned boxes will be checked.
 
 **Example 1: Not interfered AABB** 
-~~~~~
+~~~~{.php}
 box b1 100 60 140 20 10 80
 box b2 210 200 80 120 60 90
 isbbinterf b1 b2
 ==The shapes are NOT interfered by AABB.
-~~~~~
+~~~~
 
 **Example 2: Interfered AABB** 
-~~~~~
+~~~~{.php}
 box b1 300 300 300
 box b2 100 100 100 50 50 50
 isbbinterf b1 b2
 ==The shapes are interfered by AABB.
-~~~~~
+~~~~
 
 **Example 3: Not interfered OBB** 
-~~~~~
+~~~~{.php}
 box b1 100 150 200
 copy b1 b2
 trotate b1 -150 -150 -150 1 2 3 -40
@@ -7532,10 +7532,10 @@ trotate b2 -150 -150 -150 1 5 2 60
 # Check of interference
 isbbinterf b1 b2 -o
 ==The shapes are NOT interfered by OBB.
-~~~~~
+~~~~
 
 **Example 4: Interfered OBB** 
-~~~~~
+~~~~{.php}
 box b1 100 150 200
 copy b1 b2
 trotate b1 -50 -50 -50 1 1 1 -40
@@ -7544,19 +7544,19 @@ trotate b2 -50 -50 -50 1 1 1 60
 # Check of interference
 isbbinterf b1 b2 -o
 ==The shapes are interfered by OBB.
-~~~~~
+~~~~
 
 @subsubsection occt_draw_7_9_3  distmini
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 distmini name Shape1 Shape2 
-~~~~~
+~~~~
 
 Calculates the minimum distance between two shapes. The calculation returns the number of solutions, if more than one solution exists. The options are displayed in the viewer in red and the results are listed in the shell window. The *distmini* lines are considered as shapes which have a value v. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 box b 0 0 0 10 20 30 
 box b2 30 30 0 10 20 30 
 distmini d1 b b2 
@@ -7582,18 +7582,18 @@ are:
 ==X=30 Y=30 Z=0 
 
 ==d1_val d1 d12 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_7_9_4 xdistef, xdistcs, xdistcc, xdistc2dc2dss, xdistcc2ds 
 
 Syntax:
-~~~~~
+~~~~{.php}
 xdistef edge face
 xdistcs curve surface firstParam lastParam [NumberOfSamplePoints]
 xdistcc curve1 curve2 startParam finishParam [NumberOfSamplePoints]
 xdistcc2ds c curve2d surf startParam finishParam [NumberOfSamplePoints]
 xdistc2dc2dss curve2d_1 curve2d_2 surface_1 surface_2 startParam finishParam [NumberOfSamplePoints]
-~~~~~
+~~~~
 
 It is assumed that curves have the same parametrization range and *startParam* is less than *finishParam*.
 
@@ -7605,21 +7605,21 @@ Commands with prefix *xdist* allow checking the distance between two objects on
   * **xdistc2dc2dss** -- distance between two 2d curves on surface.
   
 **Examples**
-~~~~~
+~~~~{.php}
 bopcurves b1 b2 -2d 
 mksurf s1 b1
 mksurf s2 b2
 xdistcs c_1 s1 0 1 100
 xdistcc2ds c_1 c2d2_1 s2 0 1
 xdistc2dc2dss c2d1_1 c2d2_1 s1 s2 0 1 1000
-~~~~~
+~~~~
 
 @subsubsection occt_draw_7_9_5  checkshape
 
-Syntax:                  
-~~~~~
+Syntax:
+~~~~{.php}
 checkshape [-top] shape [result] [-short] 
-~~~~~
+~~~~
 
 Where: 
 * *top* -- optional parameter, which allows checking only topological validity of a shape. 
@@ -7630,20 +7630,20 @@ Where:
 **checkshape** examines the selected object for topological and geometric coherence. The object should be a three dimensional shape. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # checkshape returns a comment valid or invalid 
 box b1 0 0 0 1 1 1 
 checkshape b1 
 # returns the comment 
 this shape seems to be valid 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_7_9_6  tolsphere
 
-Syntax:                  
-~~~~~
+Syntax:
+~~~~{.php}
 tolsphere shape
-~~~~~
+~~~~
 
 Where: 
 * *shape* -- the name of the shape to process. 
@@ -7651,21 +7651,21 @@ Where:
 **tolsphere** shows vertex tolerances by drawing spheres around each vertex in the shape. Each sphere is assigned a name of the shape with suffix "_vXXX", where XXX is the number of the vertex in the shape.
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # tolsphere returns all names of created spheres.
 box b1 0 0 0 1 1 1 
 settolerance b1 0.05
 tolsphere b1
 # creates spheres and returns the names
 b1_v1 b1_v2 b1_v3 b1_v4 b1_v5 b1_v6 b1_v7 b1_v8
-~~~~~
+~~~~
 
 @subsubsection occt_draw_7_9_7  validrange
 
-Syntax:                  
-~~~~~
+Syntax:
+~~~~{.php}
 validrange edge [(out) u1 u2]
-~~~~~
+~~~~
 
 Where: 
 * *edge* -- the name of the edge to analyze. 
@@ -7674,7 +7674,7 @@ Where:
 **validrange** computes valid range of the edge. If *u1* and *u2* are not given, it returns the first and the last parameters. Otherwise, it sets variables *u1* and *u2*.
 
 **Example:** 
-~~~~~
+~~~~{.php}
 circle c 0 0 0 10
 mkedge e c
 mkedge e c 0 pi
@@ -7686,7 +7686,7 @@ dval u1
 1.9884375000000002e-008
 dval u2
 3.1415926337054181
-~~~~~
+~~~~
 
 
 @subsection occt_draw_7_10  Surface creation
@@ -7697,15 +7697,15 @@ Surface creation commands include surfaces created from boundaries and from spac
 
 @subsubsection occt_draw_7_10_1   gplate,
 
-Syntax: 
-~~~~~
+Syntax:
+~~~~{.php}
 gplate result nbrcurfront nbrpntconst [SurfInit] [edge 0] [edge tang (1:G1;2:G2) surf]...[point] [u v tang (1:G1;2:G2) surf] ... 
-~~~~~
+~~~~
 
 Creates a surface from a defined boundary. The boundary can be defined using edges, points, or other surfaces. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 plane p 
 trim p p -1 3 -1 3 
 mkface p p 
@@ -7759,15 +7759,15 @@ Loop number: 1
 Approximation results 
 Approximation error : 0.000422195884750181 
 Criterium error : 3.43709808053967e-05 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_7_10_2   filling, fillingparam
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 filling result nbB nbC nbP [SurfInit] [edge][face]order... 
 edge[face]order... point/u v face order... 
-~~~~~
+~~~~
 
 Creates a surface between borders. This command uses the **gplate** algorithm but creates a surface that is tangential to the adjacent surfaces. The result is a smooth continuous surface based on the G1 criterion. 
 
@@ -7789,7 +7789,7 @@ The options are:
  * <i>-a maxdeg maxseg </i> : Approximation option 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # to create four curved survaces and a point 
 plane p 
 trim p p -1 3 -1 3 
@@ -7832,7 +7832,7 @@ TolCurv = 0.1
 
 MaxDeg = 8 
 MaxSegments = 9 
-~~~~~
+~~~~
 
 
 @subsection occt_draw_7_11  Complex Topology
@@ -7842,11 +7842,11 @@ Complex topology is the group of commands that modify the topology of shapes. Th
 
 @subsubsection occt_draw_7_11_1  offsetshape, offsetcompshape
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 offsetshape r shape offset [tol] [face ...] 
 offsetcompshape r shape offset [face ...] 
-~~~~~
+~~~~
 
 **offsetshape** and **offsetcompshape** assign a thickness to the edges of a shape. The *offset* value can be negative or positive. This value defines the thickness and direction of the resulting shape. Each face can be removed to create a hollow object. 
 
@@ -7857,17 +7857,17 @@ In case of complex shapes, where intersections can occur from non-adjacent edges
 The opening between the object interior and exterior is defined by the argument face or faces. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 box b1 10 20 30 
 explode b1 f 
 == b1_1 b1_2 b1_3 b1_4 b1_5 b1_6 
 offsetcompshape r b1 -1 b1_3 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_7_11_2  featprism, featdprism, featrevol, featlf, featrf
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 featprism shape element skface Dirx Diry Dirz Fuse(0/1/2) Modify(0/1) 
 featdprism shape face skface angle Fuse(0/1/2) Modify(0/1) 
 featrevol shape element skface Ox Oy Oz Dx Dy Dz Fuse(0/1/2) Modify(0/1) 
@@ -7875,7 +7875,7 @@ featlf shape wire plane DirX DirY DirZ DirX DirY DirZ Fuse(0/1/2) Modify(0/1)
 featrf shape wire plane X Y Z DirX DirY DirZ Size Size Fuse(0/1/2) Modify(0/1) 
 featperform prism/revol/pipe/dprism/lf result [[Ffrom] Funtil] 
 featperformval prism/revol/dprism/lf result value 
-~~~~~
+~~~~
 
 **featprism** loads the arguments for a prism with contiguous sides normal to the face. 
 
@@ -7897,7 +7897,7 @@ All the features are created from a set of arguments which are defined when you
 
 Let us create a feature prism with a draft angle and a normal direction :
 
-~~~~~
+~~~~{.php}
 # create a box with a wire contour on the upper face 
 box b 1 1 1 
 profil f O 0 0 1 F 0.25 0.25 x 0.5 y 0.5 x -0.5 
@@ -7911,11 +7911,11 @@ BRepFeat_Form::GlobalPerform ()
  Gluer 
  still Gluer 
  Gluer result 
-~~~~~
+~~~~
 
 Let us  create a feature prism with circular direction :
 
-~~~~~
+~~~~{.php}
 # create a box with a wire contour on the upper face 
 box b 1 1 1 
 profil f O 0 0 1 F 0.25 0.25 x 0.5 y 0.5 x -0.5 
@@ -7928,12 +7928,12 @@ BRepFeat_Form::GlobalPerform ()
  Gluer 
  still Gluer 
  Gluer result 
-~~~~~
+~~~~
 
 
 Let us create a slot using the linear feature :
 
-~~~~~
+~~~~{.php}
 #create the base model using the multi viewer 
 mu4 
 profile p x 5 y 1 x -3 y -0.5 x -1.5 y 0.5 x 0.5 y 4 x -1 y -5 
@@ -7954,11 +7954,11 @@ plane pl 0.2 0.2 0.3 0 0 1
 # loads the linear feature arguments 
 featlf pr w pl 0 0 0.3 0 0 0 0 1 
 featperform lf result 
-~~~~~
+~~~~
 
 Let us create a rib using the revolution feature :
 
-~~~~~
+~~~~{.php}
 #create the base model using the multi viewer 
 mu4 
 pcylinder c1 3 5 
@@ -7971,14 +7971,14 @@ plane pl -3 0 1.5 0 1 0
 # loads the revolution feature arguments 
 featrf c1 w pl 0 0 0 0 0 1 0.3 0.3 1 1 
 featperform rf result 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_7_11_3  draft
 
-Syntax: 
-~~~~~
+Syntax:
+~~~~{.php}
 draft result shape dirx diry dirz angle shape/surf/length [-IN/-OUT] [Ri/Ro] [-Internal] 
-~~~~~
+~~~~
 
 Computes a draft angle surface from a wire. The surface is determined by the draft direction, the inclination of the draft surface, a draft angle, and a limiting distance. 
 
@@ -7993,7 +7993,7 @@ Computes a draft angle surface from a wire. The surface is determined by the dra
 **Note** that the original aim of adding a draft angle to a shape is to produce a shape which can be removed easily from a mould. The Examples below use larger angles than are used normally and the calculation results returned are not indicated.
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # to create a simple profile 
 profile p F 0 0 x 2 y 4 tt 0 4 w 
 # creates a draft with rounded angles 
@@ -8002,33 +8002,33 @@ draft res p 0 0 1 3 1 -Ro
 profile p F 0 0 x 2 y 4 tt 1 1.5 tt 0 4 w 
 # creates a draft with rounded external angles 
 draft res p 0 0 1 3 1 -Ro 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_7_11_4  deform
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 deform newname name CoeffX CoeffY CoeffZ
-~~~~~
+~~~~
 
 Modifies the shape using the x, y, and z coefficients. You can reduce or magnify the shape in the x,y, and z directions. 
  
 **Example:** 
-~~~~~
+~~~~{.php}
 pcylinder c 20 20 
 deform a c 1 3 5 
 # the conversion to bspline is followed by the 
 deformation 
-~~~~~
+~~~~
 
 
 @subsubsection occt_draw_7_11_5 nurbsconvert
 
 Syntax:
  
-~~~~~
+~~~~{.php}
 nurbsconvert result name [result name] 
-~~~~~
+~~~~
 
 Changes the NURBS curve definition of a shape to a Bspline curve definition.
 This conversion is required for asymmetric deformation and prepares the arguments for other commands such as **deform**.
@@ -8040,7 +8040,7 @@ The conversion can be necessary when transferring shape data to other applicatio
 **edgestofaces** - The command allows building planar faces from the planar edges randomly located in 3D space.
 
 It has the following syntax:
-~~~~
+~~~~{.php}
 edgestofaces r_faces edges [-a AngTol -s Shared(0/1)]
 ~~~~
 Options:
@@ -8063,7 +8063,7 @@ Draw module for @ref occt_modalg_hist "History Information support" includes the
 By default it is TRUE, i.e. the history is filled and saved.
 
 Syntax:
-~~~~
+~~~~{.php}
 setfillhistory  : Controls the history collection by the algorithms and its saving into the session after algorithm is done.
                 Usage: setfillhistory [flag]
                 w/o arguments prints the current state of the option;
@@ -8072,7 +8072,7 @@ setfillhistory  : Controls the history collection by the algorithms and its savi
 ~~~~
 
 Example:
-~~~~
+~~~~{.php}
 box b1 10 10 10
 box b2 10 10 10
 setfillhistory 0
@@ -8095,7 +8095,7 @@ dump h
 *savehistory* command saves the history from the session into a drawable object with the given name.
 
 Syntax:
-~~~~
+~~~~{.php}
 savehistory     : savehistory name
 ~~~~
 
@@ -8103,7 +8103,7 @@ If the history of shape modifications performed during an operation is needed, t
 If another operation supporting history will be performed before the history of the first operation is saved it will be overwritten with the new history.
 
 Example:
-~~~~
+~~~~{.php}
 box b1 10 10 10
 box b2 5 0 0 10 10 15
 bfuse r b1 b2
@@ -8131,12 +8131,12 @@ dump usd_hist
 *isdeleted* command checks if the given shape has been deleted in the given history.
 
 Syntax:
-~~~~
+~~~~{.php}
 isdeleted       : isdeleted history shape
 ~~~~
 
 Example:
-~~~~
+~~~~{.php}
 box b1 4 4 4 2 2 2
 box b2 10 10 10
 bcommon r b1 b2
@@ -8154,12 +8154,12 @@ foreach s [join [list [explode b2 v] [explode b2 e] [explode b2 f] ] ] {
 *modified* command returns the shapes Modified from the given shape in the given history. All modified shapes are put into a compound. If the shape has not been modified, the resulting compound will be empty. Note that if the shape has been modified into a single shape only, it will be returned without enclosure into the compound.
 
 Syntax:
-~~~~
+~~~~{.php}
 modified        : modified modified_shapes history shape
 ~~~~
 
 Example:
-~~~~
+~~~~{.php}
 box b 10 10 10
 explode b e
 fillet r b 2 b_1
@@ -8177,12 +8177,12 @@ modified m5 fillet_hist b_5
 *generated* command returns the shapes Generated from the given shape in the given history. All generated shapes are put into a compound. If no shapes have been generated from the shape, the resulting compound will be empty. Note that; if the shape has generated a single shape only, it will be returned without enclosure into the compound.
 
 Syntax:
-~~~~
+~~~~{.php}
 generated       : generated generated_shapes history shape
 ~~~~
 
 Example:
-~~~~
+~~~~{.php}
 polyline w1 0 0 0 10 0 0 10 10 0
 polyline w2 5 1 10 9 1 10 9 5 10
 
@@ -8210,12 +8210,12 @@ compare g12 g22
 Draw History mechanism allows fast and easy enabling of the Draw history support for the OCCT algorithms supporting standard history methods.
 To enable History commands for the algorithm it is necessary to save the history of the algorithm into the session.
 For that, it is necessary to put the following code into the command implementation just after the command is done:
-~~~~
+~~~~{.php}
 BRepTest_Objects::SetHistory(ListOfArguments, Algorithm);
 ~~~~
 
 Here is the example of how it is done in the command performing Split operation (see implementation of the *bapisplit* command):
-~~~~
+~~~~{.php}
 BRepAlgoAPI_Splitter aSplitter;
 // setting arguments
 aSplitter.SetArguments(BOPTest_Objects::Shapes());
@@ -8252,24 +8252,24 @@ Texture mapping allows you to map textures on a shape. Textures are texture imag
 
 @subsubsection occt_draw_7_12_1  vtexture
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 vtexture NameOfShape TextureFile 
 vtexture NameOfShape 
 vtexture NameOfShape ? 
 vtexture NameOfShape IdOfTexture 
-~~~~~
+~~~~
 
 **TextureFile** identifies the file containing the texture you want. The same syntax without **TextureFile** disables texture mapping. The question-mark <b>?</b> lists available textures. **IdOfTexture** allows applying predefined textures. 
 
 @subsubsection occt_draw_7_12_2  vtexscale
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 vtexscale NameOfShape ScaleU ScaleV 
 vtexscale NameOfShape ScaleUV 
 vtexscale NameOfShape 
-~~~~~
+~~~~
 
 *ScaleU* and *Scale V* allow scaling the texture according to the U and V parameters individually, while *ScaleUV* applies the same scale to both parameters. 
 
@@ -8277,12 +8277,12 @@ The syntax without *ScaleU*, *ScaleV* or *ScaleUV* disables texture scaling.
 
 @subsubsection occt_draw_7_12_3  vtexorigin
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 vtexorigin NameOfShape UOrigin VOrigin 
 vtexorigin NameOfShape UVOrigin 
 vtexorigin NameOfShape 
-~~~~~
+~~~~
 
 *UOrigin* and *VOrigin* allow placing the texture according to the U and V parameters individually, while *UVOrigin* applies the same position value to both parameters. 
 
@@ -8290,12 +8290,12 @@ The syntax without *UOrigin*, *VOrigin* or *UVOrigin* disables origin positionin
 
 @subsubsection occt_draw_7_12_4  vtexrepeat
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 vtexrepeat NameOfShape URepeat VRepeat 
 vtexrepeat NameOfShape UVRepeat 
 vtexrepeat NameOfShape 
-~~~~~
+~~~~
 
 *URepeat* and *VRepeat* allow repeating the texture along the U and V parameters individually, while *UVRepeat* applies the same number of repetitions for both parameters. 
 
@@ -8303,10 +8303,10 @@ The same syntax without *URepeat*, *VRepeat* or *UVRepeat* disables texture repe
 
 @subsubsection occt_draw_7_12_5  vtexdefault
 
-Syntax:       
-~~~~~
+Syntax:
+~~~~{.php}
 vtexdefault NameOfShape 
-~~~~~
+~~~~
 
 *Vtexdefault* sets or resets the texture mapping default parameters. 
 
@@ -8339,19 +8339,19 @@ These commands perform Boolean operations on two shapes:
 These commands allow intersecting the shapes only once for building all types of Boolean operations. After *bop* command is done, the other commands in this category use the intersection results prepared by *bop*.
 It may be very useful as the intersection part is usually most time-consuming part of the operation.
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 bop shape1 shape2 
 bopcommon result 
 bopfuse result 
 bopcut result 
 boptuc result 
-~~~~~
+~~~~
 
 **Example:** 
 
 Let's produce all four boolean operations on a box and a cylinder performing intersection only once:
-~~~~~
+~~~~{.php}
 box b 0 -10 5 20 20 10 
 pcylinder c 5 20 
 
@@ -8372,7 +8372,7 @@ bopcommon s4
 
 # section operation
 bopsection s5
-~~~~~
+~~~~
 
 
 @subsubsection occt_draw_bop_two_bapi bfuse, bcut, btuc, bcommon, bsection
@@ -8381,16 +8381,17 @@ These commands also perform Boolean operations on two shapes. These are the shor
 Each of these commands performs both intersection and building the result and may be useful if you need only the result of a single boolean operation.
 
 Syntax:
-~~~~~
+~~~~{.php}
 bcommon result shape1 shape2 
 bfuse result shape1 shape2 
 bcut result shape1 shape2 
 btuc result shape1 shape2 
-~~~~~
+~~~~
 
 **bection** command has some additional options for faces intersection:
-~~~~
+~~~~{.php}
 bsection result shape1 shape2 [-n2d/-n2d1/-n2d2] [-na]
+~~~~
 
 Where:
 result - result of the operation
@@ -8399,7 +8400,6 @@ shape1, shape2 - arguments of the operation
 -n2d1 - disables PCurve construction on first object
 -n2d2 - disables PCurve construction on second object
 -na - disables approximation of the section curves
-~~~~
 
 @subsection occt_draw_bop_multi Boolean Operations on multiple arguments
 
@@ -8437,8 +8437,9 @@ The command **bfillds** performs intersection of the arguments (**Objects** and
 The command **bbop** is used for building the result of Boolean Operation. It has to be used after **bfillds** command.
 
 Syntax:
-~~~~
+~~~~{.php}
 bbop result iOp
+~~~~
 
 Where:
 result - result of the operation
@@ -8448,10 +8449,10 @@ iOp - type of Boolean Operation. It could have the following values:
 2 - CUT operation
 3 - CUT21 (opposite CUT, i.e. objects and tools are swapped) operation
 4 - SECTION operation
-~~~~
+
 
 **Example**
-~~~~
+~~~~{.php}
 box b1 10 10 10
 box b2 5 5 5 10 10 10
 box b3 -5 -5 -5 10 10 10
@@ -8479,11 +8480,11 @@ The command **bbuild** is used for building the result of General Fuse Operation
 General Fuse operation does not make the difference between Objects and Tools considering both as objects.
 
 Syntax:
-~~~~
+~~~~{.php}
 bbuild result
 ~~~~
 **Example**
-~~~~
+~~~~{.php}
 box b1 10 10 10
 box b2 5 5 5 10 10 10
 box b3 -5 -5 -5 10 10 10
@@ -8507,7 +8508,7 @@ Split operation splits the **Objects** by the **Tools**.
 The command **bsplit** is used for building the result of Split operation. It has to be used after **bfillds** command.
 
 **Example**
-~~~~
+~~~~{.php}
 box b1 10 10 10
 box b2 5 5 5 10 10 10
 box b3 -5 -5 -5 10 10 10
@@ -8534,16 +8535,17 @@ The command has the following features:
 * History information for solids will be lost.
 
 Syntax:
-~~~~
+~~~~{.php}
 buildbop result -o s1 [s2 ...] -t s3 [s4 ...] -op operation (common/fuse/cut/tuc)
+~~~~
 Where:
 result      - result shape of the operation
 s1 s2 s3 s4 - arguments (solids) of the GF operation
 operation   - type of boolean operation
-~~~~
+
 
 **Example**
-~~~~
+~~~~{.php}
 box b1 10 10 10
 box b2 5 5 5 10 10 10
 box b3 -5 -5 -5 10 10 10
@@ -8601,7 +8603,7 @@ These commands have the same syntax as the analogical commands described above.
 The algorithms in Boolean component have a wide range of options.
 To see the current state of all option the command **boptions** should be used.
 It has the following syntax:
-~~~~
+~~~~{.php}
 boptions [-default]
 
 -default - allows to set all options to default state.
@@ -8614,14 +8616,14 @@ To have an effect the options should be set before the operation (before *bfilld
 **brunparallel** command enables/disables the parallel processing mode of the operation.
 
 Syntax:
-~~~~
+~~~~{.php}
 brunparallel flag
-
+~~~~
 Where:
 flag is the boolean flag controlling the mode:
 flag == 0 - parallel processing mode is off.
 flag != 0 - parallel processing mode is on.
-~~~~
+
 
 The command is applicable for all commands in the component.
 
@@ -8630,14 +8632,14 @@ The command is applicable for all commands in the component.
 **bnondestructive** command enables/disables the safe processing mode in which the input arguments are protected from modification.
 
 Syntax:
-~~~~
+~~~~{.php}
 bnondestructive flag
-
+~~~~
 Where:
 flag is the boolean flag controlling the mode:
 flag == 0 - safe processing mode is off.
 flag != 0 - safe processing mode is on.
-~~~~
+
 
 The command is applicable for all commands in the component.
 
@@ -8646,7 +8648,7 @@ The command is applicable for all commands in the component.
 **bfuzzyvalue** command sets the additional tolerance for operations.
 
 Syntax:
-~~~~
+~~~~{.php}
 bfuzzyvalue value
 ~~~~
 
@@ -8657,14 +8659,14 @@ The command is applicable for all commands in the component.
 **bglue** command sets the gluing mode for the BOP algorithms.
 
 Syntax:
-~~~~
+~~~~{.php}
 bglue 0/1/2
-
+~~~~
 Where:
 0 - disables gluing mode.
 1 - enables the Shift gluing mode.
 2 - enables the Full gluing mode.
-~~~~
+
 
 The command is applicable for all commands in the component.
 
@@ -8673,7 +8675,7 @@ The command is applicable for all commands in the component.
 **bcheckinverted** command enables/disables the check of the input solids on inverted status in BOP algorithms.
 
 Syntax:
-~~~~
+~~~~{.php}
 bcheckinverted 0 (off) / 1 (on)
 ~~~~
 
@@ -8684,7 +8686,7 @@ The command is applicable for all commands in the component.
 **buseobb** command enables/disables the usage of OBB in BOP algorithms.
 
 Syntax:
-~~~~
+~~~~{.php}
 buseobb 0 (off) / 1 (on)
 ~~~~
 
@@ -8695,21 +8697,21 @@ The command is applicable for all commands in the component.
 **bsimplify** command enables/disables the result simplification after BOP. The command is applicable only to the API variants of GF, BOP and Split operations.
 
 Syntax:
-~~~~
+~~~~{.php}
 bsimplify [-e 0/1] [-f 0/1] [-a tol]
-
+~~~~
 Where:
 -e 0/1 - enables/disables edges unification
 -f 0/1 - enables/disables faces unification
 -a tol - changes default angular tolerance of unification algo.
-~~~~
+
 
 @subsubsection occt_draw_bop_options_warn Drawing warning shapes
 
 **bdrawwarnshapes** command enables/disables drawing of warning shapes of BOP algorithms.
 
 Syntax:
-~~~~
+~~~~{.php}
 bdrawwarnshapes 0 (do not draw) / 1 (draw warning shapes)
 ~~~~
 
@@ -8723,7 +8725,7 @@ The following commands are analyzing the given shape on the validity of Boolean
 @subsubsection occt_draw_bop_check_1 bopcheck
 
 Syntax:
-~~~~
+~~~~{.php}
 bopcheck shape [level of check: 0 - 9]
 ~~~~
 
@@ -8740,7 +8742,7 @@ It checks the given shape for self-interference. The optional level of check all
 * 9 - V/V, V/E, E/E, V/F, E/F, F/F, V/S, E/S, F/S and S/S - all interferences (Default value)
 
 **Example:**
-~~~~
+~~~~{.php}
 box b1 10 10 10
 box b2 3 3 3 4 4 4
 compound b1 b2 c
@@ -8754,7 +8756,7 @@ In this example one box is completely included into other box. So the output sho
 @subsubsection occt_draw_bop_check_2 bopargcheck
 
 **bopargcheck** syntax:
-~~~~
+~~~~{.php}
 bopargcheck Shape1 [[Shape2] [-F/O/C/T/S/U] [/R|F|T|V|E|I|P|C|S]] [#BF]
 
  -<Boolean Operation>
@@ -8791,7 +8793,7 @@ As you can see *bopargcheck* performs more extended check of the given shapes th
 
 **Example:**
 Let's make an edge with big vertices:
-~~~~
+~~~~{.php}
 vertex v1 0 0 0
 settolerance v1 0.5
 vertex v2 1 0 0
@@ -8803,7 +8805,7 @@ tolsphere e
 bopargcheck e
 ~~~~
 Here is the output of this command:
-~~~~
+~~~~{.php}
 Made faulty shape: s1si_1
 Made faulty shape: s1se_1
 Faulties for FIRST  shape found : 2
@@ -8835,8 +8837,8 @@ All commands listed below  are available when the Intersection Part of the algor
 
 **bopds**
        
-Syntax: 
-~~~~
+Syntax:
+~~~~{.php}
 bopds -v [e, f]        
 ~~~~
 
@@ -8851,7 +8853,7 @@ Displays:
 Prints contents of the DS. 
 
 Example:
-~~~~
+~~~~{.php}
  Draw[28]> bopdsdump
  *** DS ***
  Ranges:2                      number of ranges
@@ -8878,7 +8880,7 @@ Example:
 **bopindex**
 
 Syntax:
-~~~~
+~~~~{.php}
 bopindex S
 ~~~~
 Prints DS index of shape *S*.
@@ -8887,9 +8889,9 @@ Prints DS index of shape *S*.
 **bopiterator**
 
 Syntax:
-~~~~~
+~~~~{.php}
 bopiterator [t1 t2]
-~~~~~
+~~~~
 
 Prints pairs of DS indices of source shapes that are intersected in terms of bounding boxes.
 
@@ -8899,7 +8901,7 @@ Prints pairs of DS indices of source shapes that are intersected in terms of bou
 * *4* -- face.
 
 Example:
-~~~~
+~~~~{.php}
  Draw[104]> bopiterator 6 4
  EF: ( z58 z12 )
  EF: ( z17 z56 )
@@ -8915,8 +8917,8 @@ Example:
 
 **bopinterf**
 
-Syntax: 
-~~~~
+Syntax:
+~~~~{.php}
 bopinterf t
 ~~~~
 
@@ -8928,7 +8930,7 @@ Prints contents of *myInterfTB* for the type of interference *t*:
 * *t=4* : edge/face.
 
 Example:
-~~~~
+~~~~{.php}
  Draw[108]> bopinterf 4
  EF: (58, 12, 68), (17, 56, 69), (19, 64, 70), (45, 26, 71), (29, 36, 72), (38, 32, 73), 6 EF found.
 ~~~~
@@ -8944,7 +8946,7 @@ Here, record <i>(58, 12, 68)</i> means:
 Displays split edges. 
 
 Example:
-~~~~
+~~~~{.php}
  Draw[33]> bopsp
  edge 58 : z58_74 z58_75
  edge 17 : z17_76 z17_77
@@ -8960,7 +8962,7 @@ Example:
 **bopcb**
 
 Syntax:
-~~~~
+~~~~{.php}
 bopcb [nE]
 ~~~~
 
@@ -8969,7 +8971,7 @@ Prints Common Blocks for:
 * the source edge with the specified index *nE*.
 
 Example:
-~~~~
+~~~~{.php}
  Draw[43]> bopcb 17
  -- CB:
  PB:{ E:71 orE:17 Pave1: { 68 3.000 } Pave2: { 18 10.000 } }
@@ -8989,13 +8991,13 @@ This command dumps common blocks for the source edge with index 17.
 **bopfin**
 
 Syntax:
-~~~~
+~~~~{.php}
 bopfin nF      
 ~~~~
 Prints Face Info about IN-parts for the face with DS index *nF*.
 
 Example:
-~~~~
+~~~~{.php}
  Draw[47]> bopfin 36
  pave blocks In:
  PB:{ E:71 orE:17 Pave1: { 68 3.000 } Pave2: { 18 10.000 } }
@@ -9011,13 +9013,13 @@ Example:
 **bopfon**
 
 Syntax:
-~~~~
+~~~~{.php}
 bopfon nF
 ~~~~
 Print Face Info about ON-parts for the face with DS index *nF*.
 
 Example:
-~~~~
+~~~~{.php}
  Draw[58]> bopfon 36
  pave blocks On:
  PB:{ E:72 orE:38 Pave1: { 69 0.000 } Pave2: { 68 10.000 } }
@@ -9034,14 +9036,14 @@ Example:
 **bopwho**
 
 Syntax:
-~~~~
+~~~~{.php}
 bopwho nS
 ~~~~
 
 Prints the information about the shape with DS index *nF*.
 
 Example:
-~~~~
+~~~~{.php}
  Draw[116]> bopwho 5
  rank: 0
 ~~~~
@@ -9049,7 +9051,7 @@ Example:
 * *rank: 0* -- means that shape 5 results from the Argument with index 0.
 
 Example:
-~~~~
+~~~~{.php}
  Draw[118]> bopwho 68
  the shape is new
  EF: (58, 12),
@@ -9065,7 +9067,7 @@ This means that shape 68 is a result of the following interferences:
 **bopnews**
 
 Syntax:
-~~~~
+~~~~{.php}
 bopnews -v [-e]
 ~~~~
 
@@ -9078,8 +9080,8 @@ The commands listed below are available when the Building Part of the algorithm
 
 **bopim**
 
-Syntax: 
-~~~~
+Syntax:
+~~~~{.php}
 bopim S
 ~~~~
 Shows the compound of shapes that are images of shape *S* from the argument.
@@ -9108,10 +9110,10 @@ The model and the map are used for working with most of DE commands.
 
 @subsubsection occt_draw_8_1_1  igesread
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 igesread <file_name> <result_shape_name> [<selection>]
-~~~~~
+~~~~
 
 Reads an IGES file to an OCCT shape. This command will interactively ask the user to select a set of entities to be converted. 
 
@@ -9134,38 +9136,38 @@ The second parameter of this command defines the name of the loaded shape. If se
 See also the detailed description of <a href="user_guides__iges.html#occt_iges_2_3_4">Selecting IGES entities</a>.
 
 **Example:**
-~~~~~
+~~~~{.php}
 # translation all roots from file 
 igesread /disk01/files/model.igs a  * 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_1_2   tplosttrim
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 tplosttrim [<IGES_type>] 
-~~~~~
+~~~~
 
 Sometimes the trimming contours of IGES faces (i.e., entity 141 for 143, 142 for 144) can be lost during translation due to fails. This command gives us a number of lost trims and the number of corresponding IGES entities. 
 It outputs the rank and numbers of faces that lost their trims and their numbers for each type (143, 144, 510) and their total number. If a face lost several of its trims it is output only once. 
 Optional parameter <i>\<IGES_type\></i> can be *0TrimmedSurface, BoundedSurface* or *Face* to specify the only type of IGES faces. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 tplosttrim TrimmedSurface 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_1_3  brepiges
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 brepiges <shape_name> <filename.igs>
-~~~~~
+~~~~
 
 Writes an OCCT shape to an IGES file. 
 
 **Example:** 
-~~~~~    
+~~~~{.php}
 # write shape with name aa to IGES file 
 brepiges aa /disk1/tmp/aaa.igs 
 == unit (write) : MM 
@@ -9175,7 +9177,7 @@ brepiges aa /disk1/tmp/aaa.igs
 ==  Now, to write a file, command : writeall filename 
 ==  Output on file : /disk1/tmp/aaa.igs 
 ==  Write OK 
-~~~~~
+~~~~
 
 @subsection occt_draw_8_2  STEP commands 
 
@@ -9184,10 +9186,10 @@ These commands are used during the translation of STEP models.
 
 @subsubsection occt_draw_8_2_1  stepread
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 stepread file_name result_shape_name [selection] 
-~~~~~
+~~~~
 
 Read a STEP file to an OCCT shape. 
 This command will interactively ask the user to select a set of entities to be converted: 
@@ -9207,17 +9209,17 @@ The second parameter of this command defines the name of the loaded shape. If se
 See also the detailed description of <a href="user_guides__step.html#occt_step_2_3_6">Selecting STEP entities</a>.
 
 **Example:**
-~~~~~
+~~~~{.php}
 # translation all roots from file 
 stepread /disk01/files/model.stp a  * 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_2_2   stepwrite
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 stepwrite mode shape_name file_name 
-~~~~~
+~~~~
 
 Writes an OCCT shape to a STEP file. 
 
@@ -9234,9 +9236,9 @@ For further information see <a href="#user_guides__step.html#occt_step_6_5">Writ
 
 Let us write shape *a* to a STEP file in mode *0*. 
 
-~~~~~
+~~~~{.php}
 stepwrite 0 a /disk1/tmp/aaa.igs 
-~~~~~
+~~~~
 
 
 @subsection occt_draw_8_3  General commands 
@@ -9245,10 +9247,10 @@ These are auxiliary commands used for the analysis of result of translation of I
 
 @subsubsection occt_draw_8_3_1  count
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 count <counter> [<selection>] 
-~~~~~
+~~~~
 
 Calculates statistics on the entities in the model and outputs a count of entities. 
 
@@ -9260,25 +9262,25 @@ The optional selection argument, if specified, defines a subset of entities, whi
 | step214-types | Calculates how many entities of each STEP type exist |
 
 **Example:**
-~~~~~
+~~~~{.php}
 count xst-types 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_3_2 data
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 data <symbol>
-~~~~~
+~~~~
 
 Obtains general statistics on the loaded data. 
 The information printed by this command depends on the symbol specified. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 # print full information about warnings and fails 
 data c 
-~~~~~
+~~~~
 
 | Symbol | Output |
 | :------ | :------ |
@@ -9293,100 +9295,100 @@ data c
 
 @subsubsection occt_draw_8_3_3  elabel
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 elabel <num>
-~~~~~
+~~~~
 
 Entities in the IGES and STEP files are numbered in the succeeding order. An entity can be identified either by its number or by its label. Label is the letter ‘#'(for STEP, for IGES use ‘D’) followed by the rank. This command gives us a label for an entity with a known number. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 elabel 84 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_3_4  entity
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 entity <#(D)>_or_<num> <level_of_information>
-~~~~~
+~~~~
 
 The content of an IGES or STEP entity can be obtained by using this command. 
 Entity can be determined by its number or label. 
 <i>\<level_of_information\></i> has range [0-6]. You can get more information about this level using this command without parameters. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 # full information for STEP entity with label 84 
 entity #84 6 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_3_5  enum
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 enum <#(D)> 
-~~~~~
+~~~~
 
 Prints a number for the entity with a given label. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 # give a number for IGES entity with label 21 
 enum D21 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_3_6  estatus
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 estatus <#(D)>_or_<num>
-~~~~~
+~~~~
 
 The list of entities referenced by a given entity and the list of entities referencing to it can be obtained by this command. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 estatus #315 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_3_7  fromshape
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 fromshape <shape_name>
-~~~~~
+~~~~
 
 Gives the number of an IGES or STEP entity corresponding to an OCCT shape. If no corresponding entity can be found and if OCCT shape is a compound the command explodes it to subshapes and try to find corresponding entities for them. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 fromshape a_1_23 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_3_8  givecount
 
 Syntax:
-~~~~~
+~~~~{.php}
 givecount <selection_name> [<selection_name>]
-~~~~~
+~~~~
 
 
 Prints a number of loaded entities defined by the selection argument.
 Possible values of \<selection_name\> you can find in the “IGES FORMAT Users’s Guide”.
 
 **Example:**
-~~~~~
+~~~~{.php}
 givecount xst-model-roots 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_3_9  givelist
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 givelist <selection_name>
-~~~~~
+~~~~
 
 Prints a list of a subset of loaded entities defined by the selection argument: 
 | Selection | Description |
@@ -9399,14 +9401,14 @@ Prints a list of a subset of loaded entities defined by the selection argument:
 
 
 **Example:**
-~~~~~
+~~~~{.php}
 # give a list of all entities of the model 
 givelist xst-model-all 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_3_10  listcount
 
-Syntax:     listcount \<counter\> [\<selection\> ...]
+Syntax:listcount \<counter\> [\<selection\> ...]
 
 Prints a list of entities per each type matching the criteria defined by arguments. 
 Optional <i>\<selection\></i> argument, if specified, defines a subset of entities, which are to be taken into account. Argument <i>\<counter\></i>  should be one of the currently defined counters: 
@@ -9418,46 +9420,46 @@ Optional <i>\<selection\></i> argument, if specified, defines a subset of entiti
 | iges-levels | Calculates how many entities lie in different IGES levels |
 
 **Example:**
-~~~~~
+~~~~{.php}
 listcount xst-types 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_3_11  listitems
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 listitems 
-~~~~~
+~~~~
 
 This command prints a list of objects (counters, selections etc.) defined in the current session. 
 
 
 @subsubsection occt_draw_8_3_12  listtypes
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 listtypes [<selection_name> ...]
-~~~~~
+~~~~
 
 Gives a list of entity types which were encountered in the last loaded file (with a number of entities of each type). The list can be shown not for all entities but for a subset of them. This subset is defined by an optional selection argument. 
 
 
 @subsubsection occt_draw_8_3_13  newmodel
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 newmodel 
-~~~~~
+~~~~
 
 Clears the current model. 
 
 
 @subsubsection occt_draw_8_3_14  param
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 param [<parameter>] [<value>]
-~~~~~
+~~~~
 
 This command is used to manage translation parameters. 
 Command without arguments gives a full list of parameters with current values. 
@@ -9467,30 +9469,30 @@ Command with <i>\<parameter\></i> (without <i><value></i>) gives us the current
 
 Let us get the information about possible schemes for writing STEP file :
 
-~~~~~
+~~~~{.php}
 param write.step.schema 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_3_15  sumcount
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 sumcount <counter> [<selection> ...]
-~~~~~
+~~~~
 
 Prints only a number of entities per each type matching the criteria defined by arguments. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 sumcount xst-types 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_3_16  tpclear
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 tpclear  
-~~~~~
+~~~~
 
 Clears the map of correspondences between IGES or STEP entities and OCCT shapes. 
 
@@ -9498,36 +9500,36 @@ Clears the map of correspondences between IGES or STEP entities and OCCT shapes.
 
 @subsubsection occt_draw_8_3_17  tpdraw
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 tpdraw <#(D)>_or_<num>
-~~~~~
+~~~~
 
 **Example:**
-~~~~~
+~~~~{.php}
 tpdraw 57 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_3_18  tpent
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 tpent <#(D)>_or_<num>
-~~~~~
+~~~~
 
 Get information about the result of translation of the given IGES or STEP entity.
 
 **Example:**
-~~~~~
+~~~~{.php}
 tpent \#23 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_3_19  tpstat
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 tpstat [*|?]<symbol> [<selection>]
-~~~~~
+~~~~
 
 
 Provides all statistics on the last transfer, including a list of transferred entities with mapping from IGES or STEP to OCCT types, as well as fail and warning messages. The parameter <i>\<symbol\></i> defines what information will be printed: 
@@ -9553,24 +9555,24 @@ Optional argument \<selection\> can limit the action of the command to the selec
 To get help, run this command without arguments. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 # translation ratio on IGES faces 
 tpstat *l iges-faces 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_3_20  xload
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 xload <file_name>
-~~~~~
+~~~~
 
 This command loads an IGES or STEP file into memory (i.e. to fill the model with data from the file) without creation of an OCCT shape. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 xload /disk1/tmp/aaa.stp 
-~~~~~
+~~~~
 
 
 @subsection occt_draw_8_4  Overview of XDE commands 
@@ -9587,165 +9589,165 @@ Reminding: All operations of translation are performed with parameters managed b
 
 @subsubsection occt_draw_8_4_1  ReadIges
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 ReadIges document file_name 
-~~~~~
+~~~~
 
 Reads information from an IGES file to an XCAF document. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 ReadIges D /disk1/tmp/aaa.igs 
 ==> Document saved with name D 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_4_2  ReadStep
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 ReadStep <document> <file_name>
-~~~~~
+~~~~
 
 Reads information from a STEP file to an XCAF document. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 ReadStep D /disk1/tmp/aaa.stp 
 == Document saved with name D 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_4_3  WriteIges
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 WriteIges <document> <file_name>
-~~~~~
+~~~~
 
 **Example:**
-~~~~~
+~~~~{.php}
 WriteIges D /disk1/tmp/aaa.igs 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_4_4  WriteStep
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 WriteStep <document> <file_name>
-~~~~~
+~~~~
 
 Writes information from an XCAF document to a STEP file. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 WriteStep D /disk1/tmp/aaa.stp 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_4_5  XFileCur
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 XFileCur  
-~~~~~
+~~~~
 
 Returns the name of file which is set as the current one in the Draw session. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 XFileCur 
 == *as1-ct-203.stp* 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_4_6  XFileList
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 XFileList  
-~~~~~
+~~~~
 
 Returns a list all files that were transferred by the last transfer. This command is  meant (assigned) for the assemble step file. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 XFileList 
 ==> *as1-ct-Bolt.stp* 
 ==> *as1-ct-L-Bracktet.stp* 
 ==> *as1-ct-LBA.stp* 
 ==> *as1-ct-NBA.stp* 
 ==> … 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_4_7  XFileSet
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 XFileSet <filename> 
-~~~~~
+~~~~
 
 Sets the current file taking it from the components list of the assemble file. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 XFileSet as1-ct-NBA.stp 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_4_8  XFromShape
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 XFromShape <shape>
-~~~~~
+~~~~
 
 This command is similar to the command @ref occt_draw_8_3_7 "fromshape", but gives additional information about the file name. It is useful if a shape was translated from several files. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 XFromShape a 
 ==> Shape a: imported from entity 217:#26 in file as1-ct-Nut.stp 
-~~~~~
+~~~~
 
 @subsection occt_draw_8_5  XDE general commands 
 
 @subsubsection occt_draw_8_5_1  XNewDoc
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 XNewDoc <document>
-~~~~~
+~~~~
 
 Creates a new XCAF document. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 XNewDoc D 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_5_2  XShow
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 XShow <document> [ <label1> … ]
-~~~~~
+~~~~
 
 Shows a shape from a given label in the 3D viewer. If the label is not given -- shows all shapes from the document. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 # show shape from label 0:1:1:4 from document D 
 XShow D 0:1:1:4 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_5_3  XStat
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 XStat <document>
-~~~~~
+~~~~
 
 Prints common information from an XCAF document. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 XStat D 
 ==>Statistis of shapes in the document: 
 ==>level N 0 : 9 
@@ -9762,34 +9764,34 @@ XStat D
 ==>Number of colors = 4 
 ==>BLUE1 RED YELLOW BLUE2 
 ==>Number of layers = 0 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_5_4  XWdump
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 XWdump <document> <filename>
-~~~~~
+~~~~
 
 Saves the contents of the viewer window as an image (XWD, png or BMP file). 
 <i>\<filename\></i> must have a corresponding extension. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 XWdump D /disk1/tmp/image.png 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_5_5  Xdump
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 Xdump <document> [int deep {0|1}]
-~~~~~
+~~~~
 
 Prints information about the tree structure of the document. If parameter 1 is given, then the tree is printed with a link to shapes. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 Xdump D 1 
 ==> ASSEMBLY 0:1:1:1 L-BRACKET(0xe8180448) 
 ==> ASSEMBLY 0:1:1:2 NUT(0xe82151e8) 
@@ -9803,16 +9805,16 @@ Xdump D 1
 ==>               ASSEMBLY 0:1:1:2 NUT(0xe82151e8) 
 ==>               ASSEMBLY 0:1:1:3 BOLT(0xe829b000) 
 etc. 
-~~~~~
+~~~~
 
 @subsection occt_draw_8_6  XDE shape commands 
 
 @subsubsection occt_draw_8_6_1  XAddComponent
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 XAddComponent <document> <label> <shape> 
-~~~~~
+~~~~
 
 Adds a component shape to assembly. 
 
@@ -9820,63 +9822,63 @@ Adds a component shape to assembly.
 
 Let us add shape b as component shape to assembly shape from label *0:1:1:1* 
 
-~~~~~
+~~~~{.php}
 XAddComponent D 0:1:1:1 b 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_6_2  XAddShape
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 XAddShape <document> <shape> [makeassembly=1]
-~~~~~
+~~~~
 
 Adds a shape (or an assembly) to a document. If this shape already exists in the document, then prints the label which points to it. By default, a new shape is added as an assembly (i.e. last parameter 1), otherwise it is necessary to pass 0 as the last parameter. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 # add shape b to document D 
 XAddShape D b 0 
 == 0:1:1:10 
 # if pointed shape is compound and last parameter in 
 # XAddShape command is used by default (1), then for 
 # each subshapes new label is created 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_6_3  XFindComponent
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 XFindComponent <document> <shape>
-~~~~~
+~~~~
 
 Prints a sequence of labels of the assembly path. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 XFindComponent D b 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_6_4  XFindShape
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 XFindShape <document> <shape>
-~~~~~
+~~~~
 
 Finds and prints a label with an indicated top-level shape. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 XFindShape D a 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_6_5  XGetFreeShapes
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 XGetFreeShapes <document> [shape_prefix]
-~~~~~
+~~~~
 
 Print labels or create DRAW shapes for all free shapes in the document. 
 If *shape_prefix* is absent -- prints labels, else -- creates DRAW shapes with names 
@@ -9885,493 +9887,493 @@ If *shape_prefix* is absent -- prints labels, else -- creates DRAW shapes with n
 **Note**: a free shape is a shape to which no other shape refers to. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 XGetFreeShapes D 
 == 0:1:1:6 0:1:1:10 0:1:1:12 0:1:1:13 
 
 XGetFreeShapes D sh 
 == sh_1 sh_2 sh_3 sh_4 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_6_6  XGetOneShape
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 XGetOneShape <shape> <document>
-~~~~~
+~~~~
 
 Creates one DRAW shape for all free shapes from a document. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 XGetOneShape a D 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_6_7  XGetReferredShape
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 XGetReferredShape <document> <label>
-~~~~~
+~~~~
 
 Prints a label that contains a top-level shape that corresponds to a shape at a given label. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 XGetReferredShape D 0:1:1:1:1 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_6_8  XGetShape
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 XGetShape <result> <document> <label>
-~~~~~
+~~~~
 
 Puts a shape from the indicated label in document to result. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 XGetShape b D 0:1:1:3 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_6_9  XGetTopLevelShapes
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 XGetTopLevelShapes <document>
-~~~~~
+~~~~
 
 Prints labels that contain top-level shapes. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 XGetTopLevelShapes D 
 == 0:1:1:1 0:1:1:2 0:1:1:3 0:1:1:4 0:1:1:5 0:1:1:6 0:1:1:7 
 0:1:1:8 0:1:1:9 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_6_10  XLabelInfo
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 XLabelInfo <document> <label>
-~~~~~
+~~~~
 
 Prints information about a shape, stored at an indicated label. 
 
 **Example:** 
-~~~~~    
+~~~~{.php}
 XLabelInfo D 0:1:1:6 
 ==> There are TopLevel shapes. There is an Assembly. This Shape is not used. 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_6_11  XNewShape
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 XNewShape <document>
-~~~~~
+~~~~
 
 Creates a new empty top-level shape. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 XNewShape D 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_6_12  XRemoveComponent
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 XRemoveComponent <document> <label>
-~~~~~
+~~~~
 
 Removes a component from the components label. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 XRemoveComponent D 0:1:1:1:1 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_6_13  XRemoveShape
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 XRemoveShape <document> <label>
-~~~~~
+~~~~
 
 Removes a shape from a document (by it’s label). 
 
 **Example:**
-~~~~~
+~~~~{.php}
 XRemoveShape D 0:1:1:2 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_6_14  XSetShape
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 XSetShape <document> <label> <shape>
-~~~~~
+~~~~
 
 Sets a shape at the indicated label. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 XSetShape D 0:1:1:3 b 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_6_15  XUpdateAssemblies
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 XUpdateAssemblies <document>
-~~~~~
+~~~~
 
 Updates all assembly compounds in the XDE document.
 
 **Example:**
-~~~~~
+~~~~{.php}
 XUpdateAssemblies D
-~~~~~
+~~~~
 
 @subsection occt_draw_8_7_  XDE color commands 
 
 @subsubsection occt_draw_8_7_1  XAddColor
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 XAddColor <document> <R> <G> <B>
-~~~~~
+~~~~
 
 Adds color in document to the color table. Parameters R,G,B are real. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 XAddColor D 0.5 0.25 0.25 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_7_2  XFindColor
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 XFindColor <document> <R> <G> <B>
-~~~~~
+~~~~
 
 Finds a label where the indicated color is situated. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 XFindColor D 0.25 0.25 0.5 
 ==> 0:1:2:2 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_7_3  XGetAllColors
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 XGetAllColors <document> 
-~~~~~
+~~~~
 
 Prints all colors that are defined in the document. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 XGetAllColors D 
 ==> RED DARKORANGE BLUE1 GREEN YELLOW3 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_7_4  XGetColor
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 XGetColor <document> <label>
-~~~~~
+~~~~
 
 Returns a color defined at the indicated label from the color table. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 XGetColor D 0:1:2:3 
 == BLUE1 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_7_5  XGetObjVisibility
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 XGetObjVisibility <document> {<label>|<shape>}
-~~~~~
+~~~~
 
 Returns the visibility of a shape. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 XGetObjVisibility D 0:1:1:4 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_7_6  XGetShapeColor
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 XGetShapeColor <document> <label> <colortype(s|c)>
-~~~~~
+~~~~
 
 Returns the color defined by label. If <i>colortype</i>=’s’ -- returns surface color, else -- returns curve color. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 XGetShapeColor D 0:1:1:4 c 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_7_7  XRemoveColor
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 XRemoveColor <document> <label>
-~~~~~
+~~~~
 
 Removes a color from the color table in a document. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 XRemoveColor D 0:1:2:1 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_7_8  XSetColor
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 XSetColor <document> {<label>|<shape>} <R> <G> <B>
-~~~~~
+~~~~
 
 Sets an RGB color to a shape given by label. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 XsetColor D 0:1:1:4 0.5 0.5 0. 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_7_9  XSetObjVisibility
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 XSetObjVisibility <document> {<label>|<shape>} {0|1}
-~~~~~
+~~~~
 
 Sets the visibility of a shape. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 # set shape from label 0:1:1:4 as invisible 
 XSetObjVisibility D 0:1:1:4 0 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_7_10  XUnsetColor
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 XUnsetColor <document> {<label>|<shape>} <colortype>
-~~~~~
+~~~~
 
 Unset a color given type (‘s’ or ‘c’) for the indicated shape. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 XUnsetColor D 0:1:1:4 s 
-~~~~~
+~~~~
 
 
 @subsection occt_draw_8_8_  XDE layer commands 
 
 @subsubsection occt_draw_8_8_1  XAddLayer
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 XAddLayer <document> <layer>
-~~~~~
+~~~~
 
 Adds a new layer in an XCAF document. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 XAddLayer D layer2 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_8_2  XFindLayer
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 XFindLayer <document> <layer>
-~~~~~
+~~~~
 
 Prints a label where a layer is situated. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 XFindLayer D Bolt 
 == 0:1:3:2 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_8_3  XGetAllLayers
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 XGetAllLayers <document> 
-~~~~~
+~~~~
 
 Prints all layers in an XCAF document. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 XGetAllLayers D 
 == *0:1:1:3* *Bolt* *0:1:1:9* 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_8_4  XGetLayers
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 XGetLayers <document> {<shape>|<label>}
-~~~~~
+~~~~
 
 Returns names of layers, which are pointed to by links of an indicated shape. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 XGetLayers D 0:1:1:3 
 == *bolt* *123* 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_8_5  XGetOneLayer
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 XGetOneLayer <document> <label>
-~~~~~
+~~~~
 
 Prints the name of a layer at a given label. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 XGetOneLayer D 0:1:3:2 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_8_6  XIsVisible
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 XIsVisible <document> {<label>|<layer>}
-~~~~~
+~~~~
 
 Returns 1 if the indicated layer is visible, else returns 0. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 XIsVisible D 0:1:3:1 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_8_7  XRemoveAllLayers
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 XRemoveAllLayers <document> 
-~~~~~
+~~~~
 
 Removes all layers from an XCAF document. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 XRemoveAllLayers D 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_8_8  XRemoveLayer
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 XRemoveLayer <document> {<label>|<layer>}
-~~~~~
+~~~~
 
 Removes the indicated layer from an XCAF document. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 XRemoveLayer D layer2 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_8_9  XSetLayer
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 XSetLayer XSetLayer <document> {<shape>|<label>} <layer> [shape_in_one_layer {0|1}]
 
-~~~~~
+~~~~
  
 Sets a reference between a shape and a layer (adds a layer if it is necessary). 
 Parameter <i>\<shape_in_one_layer\></i> shows whether a shape could be in a number of layers or only in one (0 by default). 
 
 **Example:**
-~~~~~
+~~~~{.php}
 XSetLayer D 0:1:1:2 layer2 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_8_10  XSetVisibility
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 XSetVisibility <document> {<label>|<layer>} <isvisible {0|1}>
-~~~~~
+~~~~
 
 Sets the visibility of a layer. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 # set layer at label 0:1:3:2 as invisible 
 XSetVisibility D 0:1:3:2 0 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_8_11  XUnSetAllLayers
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 XUnSetAllLayers <document> {<label>|<shape>}
-~~~~~
+~~~~
 
 Unsets a shape from all layers. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 XUnSetAllLayers D 0:1:1:2 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_8_12  XUnSetLayer
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 XUnSetLayer <document> {<label>|<shape>} <layer>
-~~~~~
+~~~~
 
 Unsets a shape from the indicated layer. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 XUnSetLayer D 0:1:1:2 layer1 
-~~~~~
+~~~~
 
 @subsection occt_draw_8_9  XDE property commands 
 
 @subsubsection occt_draw_8_9_1  XCheckProps
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 XCheckProps <document> [ {0|deflection} [<shape>|<label>] ]
-~~~~~
+~~~~
 
 Gets properties for a given shape (*volume*, *area* and <i>centroid</i>) and compares them with the results after internal calculations. If the second parameter is 0, the standard OCCT tool is used for the computation of properties. If the second parameter is not 0, it is processed as a deflection. If the deflection is positive the computation is done by triangulations, if it is negative -- meshing is forced. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 # check properties for shapes at label 0:1:1:1 from 
 # document using standard Open CASCADE Technology tools 
 XCheckProps D 0 0:1:1:1 
@@ -10379,118 +10381,118 @@ XCheckProps D 0 0:1:1:1
 ==  Area defect:        -0.0 (  0%) 
 ==  Volume defect:       0.0 (  0%) 
 ==  CG defect: dX=-0.000, dY=0.000, dZ=0.000 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_9_2  XGetArea
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 XGetArea <document> {<shape>|<label>}
-~~~~~
+~~~~
 
 Returns the area of a given shape. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 XGetArea D 0:1:1:1 
 == 24628.31815094999 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_9_3  XGetCentroid
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 XGetCentroid <document> {<shape>|<label>}
-~~~~~
+~~~~
 
 Returns the center of gravity coordinates of a given shape. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 XGetCentroid D 0:1:1:1 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_9_4  XGetVolume
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 XGetVolume <document> {<shape>|<label>}
-~~~~~
+~~~~
 
 Returns the volume of a given shape. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 XGetVolume D 0:1:1:1 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_9_5  XSetArea
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 XSetArea <document> {<shape>|<label>} <area>
-~~~~~
+~~~~
 
 Sets new area to attribute list ??? given shape. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 XSetArea D 0:1:1:1 2233.99 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_9_6  XSetCentroid
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 XSetCentroid <document> {<shape>|<label>} <x> <y> <z>
-~~~~~
+~~~~
 
 Sets new center of gravity  to the attribute list given shape. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 XSetCentroid D 0:1:1:1 0. 0. 100. 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_9_7  XSetMaterial
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 XSetMaterial <document> {<shape>|<label>} <name> <density(g/cu sm)>
-~~~~
+~~~~
 
 Adds a new label with material into the material table in a document, and adds a link to this material to the attribute list of a given shape or a given label. The last parameter sets the density of a pointed material. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 XSetMaterial D 0:1:1:1 Titanium 8899.77 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_9_8  XSetVolume
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 XSetVolume <document> {<shape>|<label>} <volume>
-~~~~~
+~~~~
 
 Sets new volume to the attribute list ??? given shape. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 XSetVolume D 0:1:1:1 444555.33 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_9_9  XShapeMassProps
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 XShapeMassProps <document> [ <deflection> [{<shape>|<label>}] ]
-~~~~~
+~~~~
 
 Computes and returns real mass and real center of gravity for a given shape or for all shapes in a document. The second parameter is used for calculation of the volume and CG(center of gravity). If it is 0, then the standard CASCADE tool (geometry) is used for computation, otherwise -- by triangulations with a given deflection. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 XShapeMassProps D 
 == Shape from label : 0:1:1:1 
 == Mass = 193.71681469282299 
@@ -10498,21 +10500,21 @@ XShapeMassProps D
     20.20271885211281,Z = 49.999999385313245 
 == Shape from label : 0:1:1:2 not have a mass 
 etc. 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_8_9_10  XShapeVolume
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 XShapeVolume <shape> <deflection>
-~~~~~
+~~~~
 
 Calculates the real volume of a pointed shape with a given deflection. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 XShapeVolume a 0 
-~~~~~
+~~~~
 
 @section occt_draw_9 Shape Healing commands
 
@@ -10522,53 +10524,53 @@ XShapeVolume a 0
 
 @subsubsection occt_draw_9_1_1 bsplres
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 bsplres <result> <shape> <tol3d> <tol2d< <reqdegree> <reqnbsegments> <continuity3d> <continuity2d> <PriorDeg> <RationalConvert>
-~~~~~
+~~~~
 
 Performs approximations of a given shape (BSpline curves and surfaces or other surfaces) to BSpline with given required parameters. The specified continuity can be reduced if the approximation with a specified continuity was not done successfully. Results are put into the shape, which is given as a parameter result. For a more detailed description see the ShapeHealing User’s Guide (operator: **BSplineRestriction**). 
 
 @subsubsection occt_draw_9_1_2 checkfclass2d
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 checkfclass2d <face> <ucoord> <vcoord>
-~~~~~
+~~~~
 
 Shows where a point which is given by coordinates is located in relation to a given face -- outbound, inside or at the bounds. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 checkfclass2d f 10.5 1.1 
 == Point is OUT 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_9_1_3 checkoverlapedges
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 checkoverlapedges <edge1> <edge2> [<toler> <domaindist>]
-~~~~~
+~~~~
 
 Checks the overlapping of two given edges. If the distance between two edges is less than the given value of tolerance then edges are overlapped. Parameter \<domaindist\> sets length of part of edges on which edges are overlapped. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 checkoverlapedges e1 e2 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_9_1_4 comtol
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 comptol <shape> [nbpoints] [prefix]
-~~~~~
+~~~~
 
 Compares the real value of tolerance on curves with the value calculated by standard (using 23 points). The maximal value of deviation of 3d curve from pcurve at given simple points is taken as a real value (371 is by default). Command returns the maximal, minimal and average value of tolerance for all edges and difference between real values and set values. Edges with the maximal value of tolerance and relation will be saved if the ‘prefix’ parameter is given. 
 
 **Example:** 
-~~~~~    
+~~~~{.php}
 comptol h 871 t 
 
 ==> Edges tolerance computed by 871 points: 
@@ -10577,87 +10579,87 @@ comptol h 871 t
 ==> MAX=0.80001130696523448 AVG=0.06349345591805905 MIN=0 
 ==> Edge with max tolerance saved to t_edge_tol 
 ==> Concerned faces saved to shapes t_1, t_2 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_9_1_5 convtorevol
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 convtorevol <result> <shape>
-~~~~~
+~~~~
 
 Converts all elementary surfaces of a given shape into surfaces of revolution. 
 Results are put into the shape, which is given as the <i>\<result\></i> parameter. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 convtorevol r a 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_9_1_6 directfaces
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 directfaces <result> <shape>
-~~~~~
+~~~~
 
 Converts indirect surfaces and returns the results into the shape, which is given as the result parameter. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 directfaces r a 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_9_1_7 expshape
 
-Syntax:   
-~~~~~
+Syntax:
+~~~~{.php}
 expshape <shape> <maxdegree> <maxseg>
-~~~~~
+~~~~
 
 Gives statistics for a given shape. This test command is working with Bezier and BSpline entities. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 expshape a 10 10 
 ==> Number of Rational Bspline curves 128 
 ==> Number of Rational Bspline pcurves 48 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_9_1_8 fixsmall
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 fixsmall <result> <shape> [<toler>=1.]
-~~~~~
+~~~~
 
 Fixes small edges in given shape by merging adjacent edges with agiven tolerance. Results are put into the shape, which is given as the result parameter. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 fixsmall r a 0.1 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_9_1_9 fixsmalledges
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 fixsmalledges <result> <shape> [<toler> <mode> <maxangle>]
-~~~~~
+~~~~
 
 Searches at least one small edge at a given shape. If such edges have been found, then small edges are merged with a given tolerance. If parameter <i>\<mode\></i> is equal to *Standard_True* (can be given any values, except 2), then  small edges, which can not be merged, are removed, otherwise they are to be kept (*Standard_False* is used by default). Parameter <i>\<maxangle\></i> sets a maximum possible angle for merging two adjacent edges, by default no limit angle is applied (-1). Results are put into the shape, which is given as parameter result. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 fixsmalledges r a 0.1 1 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_9_1_10 fixshape
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 fixshape <result> <shape> [<preci> [<maxpreci>]] [{switches}]
-~~~~~
+~~~~
 
 Performs fixes of all sub-shapes (such as *Solids*, *Shells*, *Faces*, *Wires* and *Edges*) of a given shape. Parameter <i>\<preci\></i> sets a basic precision value, <i>\<maxpreci\></i> sets the maximal allowed tolerance. Results are put into the shape, which is given as parameter result. <b>{switches}</b> allows to tune parameters of ShapeFix 
 
@@ -10678,66 +10680,66 @@ The following syntax is used:
 For enhanced message output, use switch '+?' 
 
 **Example:**
-~~~~~
+~~~~{.php}
 fixshape r a 0.001 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_9_1_11 fixwgaps
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 fixwgaps <result> <shape> [<toler>=0]
-~~~~~
+~~~~
 
 Fixes gaps between ends of curves of adjacent edges (both 3d and pcurves) in wires in a given shape with a given tolerance. Results are put into the shape, which is given as parameter result. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 fixwgaps r a 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_9_1_12 offsetcurve, offset2dcurve
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 offsetcurve <result> <curve> <offset> <direction(as point)>
 offset2dcurve <result> <curve> <offset>
-~~~~~
+~~~~
 
 **offsetcurve** works with the curve in 3d space, **offset2dcurve** in 2d space. 
 
 Both commands are intended to create a new offset curve by copying the given curve to distance, given by parameter <i>\<offset\></i>. Parameter <i>\<direction\></i> defines direction of the offset curve. It is created as a point. For correct work of these commands the direction of normal of the offset curve must be perpendicular to the plane, the basis curve is located there. Results are put into the curve, which is given as parameter <i>\<result\></i>.  
 
 **Example:**
-~~~~~
+~~~~{.php}
 point pp 10 10 10 
 offsetcurve r c 20 pp 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_9_1_13 projcurve
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 projcurve <edge>|<curve3d>|<curve3d first last>  <X> <Y> <Z>
-~~~~~
+~~~~
 
 **projcurve** returns the projection of a given point on a given curve. The curve may be defined by three ways: by giving the edge name, giving the 3D curve and by giving the unlimited curve and limiting it by pointing its start and finish values. 
 
 **Example:** 
-~~~~~    
+~~~~{.php}
 projcurve k_1 0 1 5 
 ==Edge k_1 Params from 0 to 1.3 
 ==Precision (BRepBuilderAPI) : 9.9999999999999995e-008  ==Projection : 0  1  5 
 ==Result : 0  1.1000000000000001  0 
 ==Param = -0.20000000000000001  Gap = 5.0009999000199947 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_9_1_14 projpcurve
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 projpcurve <edge> <face>  <Tol> <X> <Y> <Z> [<start_param>]
-~~~~~
+~~~~
 
 **projpcurve** returns the projection of a given point on a given curve on surface.
 The curve on surface is defined by giving the edge and face names.
@@ -10747,97 +10749,97 @@ If this parameter is not set, algorithm uses whole parametric interval of pcurve
 
 **Example:** 
 
-~~~~
+~~~~{.php}
 # Using global searching   
 projpcurve f_1 f 1.e-7 0.877 0 0.479
 ==Point: 0.87762772831890712 0 0.47934285275342808
 ==Param: 0.49990578239977856
 ==Dist: 0.0007152557954264938
-~~~~~
+~~~~
 
-~~~~~
+~~~~{.php}
 # Using starting parameter on edge
 projpcurve f_1 f 1.e-7 0.877 0 0.479 .6
 ==Point: 0.87762772831890712 0 0.47934285275342808
 ==Param: 0.49990578239977856
 ==Dist: 0.0007152557954264938
-~~~~~
+~~~~
 
 @subsubsection occt_draw_9_1_15 projface
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 projface <face> <X> <Y> [<Z>]
-~~~~~
+~~~~
 
 Returns the projection of a given point to a given face in 2d or 3d space. If two coordinates (2d space) are given then returns coordinates projection of this point in 3d space and vice versa. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 projface a_1 10.0 0.0 
 ==  Point UV  U = 10  V = 0 
 ==   =   proj  X = -116  Y = -45  Z = 0 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_9_1_16 scaleshape
 
-Syntax:   
-~~~~~
+Syntax:
+~~~~{.php}
 scaleshape <result> <shape> <scale>
-~~~~~
+~~~~
 
 Returns a new shape, which is the result of scaling of a given shape with a coefficient equal to the parameter <i>\<scale\></i>. Tolerance is calculated for the  new shape as well.
 
 **Example:**
-~~~~~
+~~~~{.php}
 scaleshape r a_1 0.8 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_9_1_17 settolerance
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 settolerance <shape> [<mode>=v-e-w-f-a] <val>(fix value) or
                    <tolmin> <tolmax>
-~~~~
+~~~~
 
 Sets new values of tolerance for a given shape. If the second parameter <i>mode</i> is given, then the tolerance value is set only for these sub shapes. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 settolerance a 0.001 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_9_1_18 splitface
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 splitface <result> <face> [u usplit1 usplit2...] [v vsplit1 vsplit2 ...]
-~~~~~
+~~~~
 
 Splits a given face in parametric space and puts the result into the given parameter <i>\<result\></i>. 
 Returns the status of split face. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 # split face f by parameter u = 5 
 splitface r f u 5 
 ==> Splitting by   U:   ,5 
 ==> Status:  DONE1 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_9_1_19 statshape
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 statshape <shape> [particul]
-~~~~~
+~~~~
 
 Returns the number of sub-shapes, which compose the given shape. For example, the number of solids, number of faces etc.  It also returns the number of geometrical objects or sub-shapes with a specified type, example, number of free faces, number of C0 
 surfaces. The last parameter becomes out of date. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 statshape a 
 ==> Count     Item 
 ==> -----     ---- 
@@ -10850,19 +10852,19 @@ statshape a
 ==> 78      Wire 
 ==> 4      Face with more than one wire 
 ==> 34     bspsur: BSplineSurface 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_9_1_20 tolerance
 
 Syntax:
-~~~~~
+~~~~{.php}
 tolerance <shape> [<mode>:D v e f c] [<tolmin> <tolmax>:real]
-~~~~~
+~~~~
 
 Returns tolerance (maximal, avg and minimal values)  of all given shapes and tolerance of their *Faces*, *Edges* and *Vertices*. If parameter <i>\<tolmin\></i> or <i>\<tolmax\></i> or both of them are given, then sub-shapes are returned as a result of analys of this shape, which satisfy the given tolerances. If a particular value of entity ((**D**)all shapes  (**v**) *vertices* (**e**) *edges* (**f**) *faces* (**c**) *combined* (*faces*)) is given as the second parameter then only this group will be analyzed for tolerance. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 tolerance a 
 ==> Tolerance MAX=0.31512672416608001 AVG=0.14901359484722074 MIN=9.9999999999999995e-08 
 ==> FACE    : MAX=9.9999999999999995e-08 AVG=9.9999999999999995e-08 MIN=9.9999999999999995e-08 
@@ -10871,48 +10873,48 @@ tolerance a
 
 tolerance a v 0.1 0.001 
 ==>  Analysing Vertices gives 6 Shapes between tol1=0.10000000000000001 and tol2=0.001 , named tol_1 to tol_6 
-~~~~~
+~~~~
 
 
 @subsection occt_draw_9_2 Conversion commands 
 
 @subsubsection occt_draw_9_2_1 DT_ClosedSplit
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 DT_ClosedSplit <result> <shape>
-~~~~~
+~~~~
 
 Divides all closed faces in the shape (for example cone) and returns result of given shape into shape, which is given as parameter result. Number of faces in resulting shapes will be increased. 
 Note: A closed face is a face with one or more seam. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 DT_ClosetSplit r a 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_9_2_2 DT_ShapeConvert, DT_ShapeConvertRev
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 DT_ShapeConvert <result> <shape> <convert2d> <convert3d>
 DT_ShapeConvertRev <result> <shape> <convert2d> <convert3d>
-~~~~~
+~~~~
  
 Both commands are intended for the conversion of 3D, 2D curves to Bezier curves and surfaces to Bezier based surfaces. Parameters convert2d and convert3d take on a value 0 or 1. If the given value is 1, then the conversion will be performed, otherwise it will not be performed. The results are put into the shape, which is given as parameter Result. Command *DT_ShapeConvertRev* differs from *DT_ShapeConvert* by converting all elementary surfaces into surfaces of revolution first. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 DT_ShapeConvert r a 1 1 
 == Status: DONE1 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_9_2_3 DT_ShapeDivide
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 DT_ShapeDivide <result> <shape> <tol>
-~~~~~
+~~~~
 
 Divides the shape with C1 criterion and returns the result of geometry conversion of a given shape into the shape, which is given as parameter result. This command illustrates how class *ShapeUpgrade_ShapeDivideContinuity* works. This class allows to convert geometry with a continuity less than the specified continuity to geometry with target continuity. If conversion is not possible then the geometrical object is split into several ones, which satisfy the given tolerance. It also returns the  status shape splitting: 
  * OK      : no splitting was done 
@@ -10921,66 +10923,66 @@ Divides the shape with C1 criterion and returns the result of geometry conversio
  * Fail1    : Some errors occurred 
 
 **Example:**
-~~~~~
+~~~~{.php}
 DT_ShapeDivide r a 0.001 
 == Status: OK 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_9_2_4 DT_SplitAngle
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 DT_SplitAngle <result> <shape> [MaxAngle=95]
-~~~~~
+~~~~
 
 Works with all revolved surfaces, like cylinders, surfaces of revolution, etc. This command divides given revolved surfaces into segments so that each resulting segment covers not more than the given *MaxAngle* degrees and puts the result of splitting into the shape, which is given as parameter result. Values of returned status are given above. 
 This command illustrates how class *ShapeUpgrade_ShapeDivideAngle* works. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 DT_SplitAngle r a 
 == Status: DONE2 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_9_2_5 DT_SplitCurve
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 DT_SplitCurve <curve> <tol> <split(0|1)>
-~~~~~
+~~~~
 
 Divides the 3d curve with C1 criterion and returns the result of splitting of the given curve into a new curve. If the curve had been divided by segments, then each segment is put to an individual result.  This command can correct a given curve at a knot with the given tolerance, if it is impossible, then the given surface is split at that knot. If the last parameter is 1, then 5 knots are added at the given curve, and its surface is split by segments, but this will be performed not for all parametric spaces. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 DT_SplitCurve r c 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_9_2_6 DT_SplitCurve2d
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 DT_SplitCurve2d Curve Tol Split(0/1) 
-~~~~~
+~~~~
 
 Works just as **DT_SplitCurve** (see above), only with 2d curve. 
 
 **Example:**
-~~~~~
+~~~~{.php}
 DT_SplitCurve2d r c 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_9_2_7 DT_SplitSurface
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 DT_SplitSurface <result> <Surface|GridSurf> <tol> <split(0|1)>
-~~~~~
+~~~~
 
 Divides surface with C1 criterion and returns the result of splitting of a given surface into surface, which is given as parameter result. If the surface has been divided into segments, then each segment is put to an individual result.  This command can correct a given C0 surface at a knot with a given tolerance, if it is impossible, then the given surface is split at that knot. If the last parameter is 1, then 5 knots are added to the given surface, and its surface is split by segments, but this will be performed not for all parametric spaces. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 # split surface with name "su"
 DT_SplitSurface res su 0.1 1 
 ==> single surf 
@@ -10991,40 +10993,40 @@ DT_SplitSurface res su 0.1 1
 ==> appel a Surfaces 
 ==> transfert resultat 
 ==> res1_1_1 res1_2_1 res1_3_1 res1_4_1 res1_5_1 res1_6_1 
-~~~~~
+~~~~
 
 @subsubsection occt_draw_9_2_8 DT_ToBspl
 
 Syntax:
-~~~~~
+~~~~{.php}
 DT_ToBspl <result> <shape>
-~~~~~
+~~~~
 
 Converts a surface of linear extrusion, revolution and offset surfaces into BSpline surfaces. Returns the result into the shape, which is given as parameter result. 
 
 **Example:** 
-~~~~~    
+~~~~{.php}
 DT_ToBspl res sh
 == error = 5.20375663162094e-08   spans = 10
 ==  Surface is approximated with continuity 2
-~~~~~
+~~~~
 
 @section occt_draw_10 Performance evaluation commands
 
 
 @subsection occt_draw_10_1 VDrawSphere
 
-Syntax:      
-~~~~~
+Syntax:
+~~~~{.php}
 vdrawsphere shapeName Fineness [X=0.0 Y=0.0 Z=0.0] [Radius=100.0] [ToEnableVBO=1] [NumberOfViewerUpdate=1] [ToShowEdges=0] 
-~~~~~
+~~~~
 
 Calculates and displays in a given number of steps a sphere with given coordinates, radius and fineness. Returns the information about the properties of the sphere, the time and the amount of memory required to build it. 
 
 This command can be used for visualization performance evaluation instead of the outdated Visualization Performance Meter. 
 
 **Example:** 
-~~~~~
+~~~~{.php}
 vdrawsphere s 200 1 1 1 500 1 
 == Compute Triangulation... 
 == NumberOfPoints: 39602 
@@ -11037,7 +11039,7 @@ vdrawsphere s 200 1 1 1 500 1
 == CPU user time: 15.6000999999998950 msec 
 == CPU system time: 0.0000000000000000 msec 
 == CPU average time of scene redrawing: 15.6000999999998950 msec 
-~~~~~
+~~~~
 
 
 @section occt_draw_12 Simple vector algebra and measurements
@@ -11047,7 +11049,7 @@ This section contains description of auxiliary commands that can be useful for s
 @subsection occt_draw_12_1 Vector algebra commands
 
 This section describes commands providing simple calculations with 2D and 3D vectors. The vector is represented by a TCL list of double values (coordinates). The commands get input vector coordinates from the command line as distinct values. So, if you have a vector stored in a variable you need to use *eval* command as a prefix, for example, to compute the magnitude of cross products of two vectors given by 3 points the following commands can be used:
-~~~~~{.cpp}
+~~~~{.php}
 Draw[10]> set vec1 [vec 12 28 99 12 58 99]
 0 30 0
 Draw[13]> set vec2 [vec 12 28 99 16 21 89]
@@ -11056,357 +11058,357 @@ Draw[14]> set cross [eval cross $vec1 $vec2]
 -300 0 -120
 Draw[15]> eval module $cross
 323.10988842807024
-~~~~~
+~~~~
 
 @subsubsection occt_draw_12_1_1 vec
 
 Syntax:
-~~~~~
+~~~~{.php}
 vec <x1> <y1> <z1> <x2> <y2> <z2>
-~~~~
+~~~~
 
 Returns coordinates of vector between two 3D points.
 
 Example:
-~~~~~{.cpp}
+~~~~{.php}
 vec 1 2 3 6 5 4
-~~~~~
+~~~~
 
 @subsubsection occt_draw_12_1_2 2dvec
 
 Syntax:
-~~~~~
+~~~~{.php}
 2dvec <x1> <y1> <x2> <y2>
-~~~~
+~~~~
 
 Returns coordinates of vector between two 2D points.
 
 Example: 
-~~~~~{.cpp}
+~~~~{.php}
 2dvec 1 2 4 3
-~~~~~
+~~~~
 
 @subsubsection occt_draw_12_1_3 pln
 
 Syntax:
-~~~~~
+~~~~{.php}
 pln <x1> <y1> <z1> <x2> <y2> <z2> <x3> <y3> <z3>
-~~~~
+~~~~
 
 Returns plane built on three points. A plane is represented by 6 double values: coordinates of the origin point and the normal directoin.
 
 Example: 
-~~~~~{.cpp}
+~~~~{.php}
 pln 1 2 3 6 5 4 9 8 7
-~~~~~
+~~~~
 
 @subsubsection occt_draw_12_1_4 module
 
 Syntax:
-~~~~~
+~~~~{.php}
 module <x> <y> <z>
-~~~~
+~~~~
 
 Returns module of a vector.
 
 Example: 
-~~~~~{.cpp}
+~~~~{.php}
 module 1 2 3
-~~~~~
+~~~~
 
 @subsubsection occt_draw_12_1_5 2dmodule
 
 Syntax:
-~~~~~
+~~~~{.php}
 2dmodule <x> <y>
-~~~~
+~~~~
 
 Returns module of a 2D vector.
 
 Example: 
-~~~~~{.cpp}
+~~~~{.php}
 2dmodule 1 2
-~~~~~
+~~~~
 
 @subsubsection occt_draw_12_1_6 norm
 
 Syntax:
-~~~~~
+~~~~{.php}
 norm <x> <y> <z>
-~~~~
+~~~~
 
 Returns unified vector from a given 3D vector.
 
 Example: 
-~~~~~{.cpp}
+~~~~{.php}
 norm 1 2 3
-~~~~~
+~~~~
 
 @subsubsection occt_draw_12_1_7 2dnorm
 
 Syntax:
-~~~~~
+~~~~{.php}
 2dnorm <x> <y>
-~~~~
+~~~~
 
 Returns unified vector from a given 2D vector.
 
 Example: 
-~~~~~{.cpp}
+~~~~{.php}
 2dnorm 1 2
-~~~~~
+~~~~
 
 @subsubsection occt_draw_12_1_8 inverse
 
 Syntax:
-~~~~~
+~~~~{.php}
 inverse <x> <y> <z>
-~~~~
+~~~~
 
 Returns inversed 3D vector.
 
 Example: 
-~~~~~{.cpp}
+~~~~{.php}
 inverse 1 2 3
-~~~~~
+~~~~
 
 @subsubsection occt_draw_12_1_9 2dinverse
 
 Syntax:
-~~~~~
+~~~~{.php}
 2dinverse <x> <y>
-~~~~
+~~~~
 
 Returns inversed 2D vector.
 
 Example: 
-~~~~~{.cpp}
+~~~~{.php}
 2dinverse 1 2
-~~~~~
+~~~~
 
 @subsubsection occt_draw_12_1_10 2dort
 
 Syntax:
-~~~~~
+~~~~{.php}
 2dort <x> <y>
-~~~~
+~~~~
 
 Returns 2D vector rotated on 90 degrees.
 
 Example: 
-~~~~~{.cpp}
+~~~~{.php}
 2dort 1 2
-~~~~~
+~~~~
 
 @subsubsection occt_draw_12_1_11 distpp
 
 Syntax:
-~~~~~
+~~~~{.php}
 distpp <x1> <y1> <z1> <x2> <y2> <z2>
-~~~~
+~~~~
 
 Returns distance between two 3D points.
 
 Example: 
-~~~~~{.cpp}
+~~~~{.php}
 distpp 1 2 3 4 5 6
-~~~~~
+~~~~
 
 @subsubsection occt_draw_12_1_12 2ddistpp
 
 Syntax:
-~~~~~
+~~~~{.php}
 2ddistpp <x1> <y1> <x2> <y2>
-~~~~
+~~~~
 
 Returns distance between two 2D points.
 
 Example: 
-~~~~~{.cpp}
+~~~~{.php}
 2ddistpp 1 2 3 4
-~~~~~
+~~~~
 
 @subsubsection occt_draw_12_1_13 distplp
 
 Syntax:
-~~~~~
+~~~~{.php}
 distplp <x0> <y0> <z0> <nx> <ny> <nz> <xp> <yp> <zp>
-~~~~
+~~~~
 
 Returns distance between plane defined by point and normal direction and another point.
 
 Example: 
-~~~~~{.cpp}
+~~~~{.php}
 distplp 0 0 0 0 0 1 5 6 7
-~~~~~
+~~~~
 
 @subsubsection occt_draw_12_1_14 distlp
 
 Syntax:
-~~~~~
+~~~~{.php}
 distlp <x0> <y0> <z0> <dx> <dy> <dz> <xp> <yp> <zp>
-~~~~
+~~~~
 
 Returns distance between 3D line defined by point and direction and another point.
 
 Example: 
-~~~~~{.cpp}
+~~~~{.php}
 distlp 0 0 0 1 0 0 5 6 7
-~~~~~
+~~~~
 
 @subsubsection occt_draw_12_1_15 2ddistlp
 
 Syntax:
-~~~~~
+~~~~{.php}
 2ddistlp <x0> <y0> <dx> <dy> <xp> <yp>
-~~~~
+~~~~
 
 Returns distance between 2D line defined by point and direction and another point.
 
 Example: 
-~~~~~{.cpp}
+~~~~{.php}
 2ddistlp 0 0 1 0 5 6
-~~~~~
+~~~~
 
 @subsubsection occt_draw_12_1_16 distppp
 
 Syntax:
-~~~~~
+~~~~{.php}
 distppp <x1> <y1> <z1> <x2> <y2> <z2> <x3> <y3> <z3>
-~~~~
+~~~~
 
 Returns deviation of point (x2,y2,z2) from segment defined by points (x1,y1,z1) and (x3,y3,z3).
 
 Example: 
-~~~~~{.cpp}
+~~~~{.php}
 distppp 0 0 0 1 1 0 2 0 0
-~~~~~
+~~~~
 
 @subsubsection occt_draw_12_1_17 2ddistppp
 
 Syntax:
-~~~~~
+~~~~{.php}
 2ddistppp <x1> <y1> <x2> <y2> <x3> <y3>
-~~~~
+~~~~
 
 Returns deviation of point (x2,y2) from segment defined by points (x1,y1) and (x3,y3). The result is a signed value. It is positive if the point (x2,y2) is on the left side of the segment, and negative otherwise.
 
 Example: 
-~~~~~{.cpp}
+~~~~{.php}
 2ddistppp 0 0 1 -1 2 0
-~~~~~
+~~~~
 
 @subsubsection occt_draw_12_1_18 barycen
 
 Syntax:
-~~~~~
+~~~~{.php}
 barycen <x1> <y1> <z1> <x2> <y2> <z2> <par>
-~~~~
+~~~~
 
 Returns point of a given parameter between two 3D points.
 
 Example: 
-~~~~~{.cpp}
+~~~~{.php}
 barycen 0 0 0 1 1 1 0.3
-~~~~~
+~~~~
 
 @subsubsection occt_draw_12_1_19 2dbarycen
 
 Syntax:
-~~~~~
+~~~~{.php}
 2dbarycen <x1> <y1> <x2> <y2> <par>
-~~~~
+~~~~
 
 Returns point of a given parameter between two 2D points.
 
 Example: 
-~~~~~{.cpp}
+~~~~{.php}
 2dbarycen 0 0 1 1 0.3
-~~~~~
+~~~~
 
 @subsubsection occt_draw_12_1_20 cross
 
 Syntax:
-~~~~~
+~~~~{.php}
 cross <x1> <y1> <z1> <x2> <y2> <z2>
-~~~~
+~~~~
 
 Returns cross product of two 3D vectors.
 
 Example: 
-~~~~~{.cpp}
+~~~~{.php}
 cross 1 0 0 0 1 0
-~~~~~
+~~~~
 
 @subsubsection occt_draw_12_1_21 2dcross
 
 Syntax:
-~~~~~
+~~~~{.php}
 2dcross <x1> <y1> <x2> <y2>
-~~~~
+~~~~
 
 Returns cross product of two 2D vectors.
 
 Example: 
-~~~~~{.cpp}
+~~~~{.php}
 2dcross 1 0 0 1
-~~~~~
+~~~~
 
 @subsubsection occt_draw_12_1_22 dot
 
 Syntax:
-~~~~~
+~~~~{.php}
 dot <x1> <y1> <z1> <x2> <y2> <z2>
-~~~~
+~~~~
 
 Returns scalar product of two 3D vectors.
 
 Example: 
-~~~~~{.cpp}
+~~~~{.php}
 dot 1 0 0 0 1 0
-~~~~~
+~~~~
 
 @subsubsection occt_draw_12_1_23 2ddot
 
 Syntax:
-~~~~~
+~~~~{.php}
 2ddot <x1> <y1> <x2> <y2>
-~~~~
+~~~~
 
 Returns scalar product of two 2D vectors.
 
 Example: 
-~~~~~{.cpp}
+~~~~{.php}
 2ddot 1 0 0 1
-~~~~~
+~~~~
 
 @subsubsection occt_draw_12_1_24 scale
 
 Syntax:
-~~~~~
+~~~~{.php}
 scale <x> <y> <z> <factor>
-~~~~
+~~~~
 
 Returns 3D vector multiplied by scalar.
 
 Example: 
-~~~~~{.cpp}
+~~~~{.php}
 scale 1 0 0 5
-~~~~~
+~~~~
 
 @subsubsection occt_draw_12_1_25 2dscale
 
 Syntax:
-~~~~~
+~~~~{.php}
 2dscale <x> <y> <factor>
-~~~~
+~~~~
 
 Returns 2D vector multiplied by scalar.
 
 Example: 
-~~~~~{.cpp}
+~~~~{.php}
 2dscale 1 0 5
-~~~~~
+~~~~
 
 @subsection occt_draw_12_2 Measurements commands
 
@@ -11415,134 +11417,134 @@ This section describes commands that make possible to provide measurements on a
 @subsubsection occt_draw_12_2_1 pnt
 
 Syntax:
-~~~~~
+~~~~{.php}
 pnt <object>
-~~~~
+~~~~
 
 Returns coordinates of point in the given Draw variable. Object can be of type point or vertex. Actually this command is built up from the commands @ref occt_draw_7_2_1a "mkpoint" and @ref occt_draw_6_6_1 "coord".
 
 Example: 
-~~~~~{.cpp}
+~~~~{.php}
 vertex v 0 1 0
 pnt v
-~~~~~
+~~~~
 
 @subsubsection occt_draw_12_2_2 pntc
 
 Syntax:
-~~~~~
+~~~~{.php}
 pntc <curv> <par>
-~~~~
+~~~~
 
 Returns coordinates of point on 3D curve with given parameter. Actually this command is based on the command @ref occt_draw_6_6_2 "cvalue".
 
 Example: 
-~~~~~{.cpp}
+~~~~{.php}
 circle c 0 0 0 10
 pntc c [dval pi/2]
-~~~~~
+~~~~
 
 @subsubsection occt_draw_12_2_3 2dpntc
 
 Syntax:
-~~~~~
+~~~~{.php}
 2dpntc <curv2d> <par>
-~~~~
+~~~~
 
 Returns coordinates of point on 2D curve with given parameter. Actually this command is based on the command @ref occt_draw_6_6_2 "2dcvalue".
 
 Example: 
-~~~~~{.cpp}
+~~~~{.php}
 circle c 0 0 10
 2dpntc c [dval pi/2]
-~~~~~
+~~~~
 
 @subsubsection occt_draw_12_2_4 pntsu
 
 Syntax:
-~~~~~
+~~~~{.php}
 pntsu <surf> <u> <v>
-~~~~
+~~~~
 
 Returns coordinates of point on surface with given parameters. Actually this command is based on the command @ref occt_draw_6_6_3 "svalue".
 
 Example: 
-~~~~~{.cpp}
+~~~~{.php}
 cylinder s 10
 pntsu s [dval pi/2] 5
-~~~~~
+~~~~
 
 @subsubsection occt_draw_12_2_5 pntcons
 
 Syntax:
-~~~~~
+~~~~{.php}
 pntcons <curv2d> <surf> <par>
-~~~~
+~~~~
 
 Returns coordinates of point on surface defined by point on 2D curve with given parameter. Actually this command is based on the commands @ref occt_draw_6_6_2 "2dcvalue" and @ref occt_draw_6_6_3 "svalue".
 
 Example: 
-~~~~~{.cpp}
+~~~~{.php}
 line c 0 0 1 0
 cylinder s 10
 pntcons c s [dval pi/2]
-~~~~~
+~~~~
 
 @subsubsection occt_draw_12_2_6 drseg
 
 Syntax:
-~~~~~
+~~~~{.php}
 drseg <name> <x1> <y1> <z1> <x2> <y2> <z2>
-~~~~
+~~~~
 
 Creates a linear segment between two 3D points. The new object is given the *name*. The object is drawn in the axonometric view.
 
 Example: 
-~~~~~{.cpp}
+~~~~{.php}
 drseg s 0 0 0 1 0 0
-~~~~~
+~~~~
 
 @subsubsection occt_draw_12_2_7 2ddrseg
 
 Syntax:
-~~~~~
+~~~~{.php}
 2ddrseg <name> <x1> <y1> <x2> <y2>
-~~~~
+~~~~
 
 Creates a linear segment between two 2D points. The new object is given the *name*. The object is drawn in the 2D view.
 
 Example: 
-~~~~~{.cpp}
+~~~~{.php}
 2ddrseg s 0 0 1 0
-~~~~~
+~~~~
 
 @subsubsection occt_draw_12_2_8 mpick
 
 Syntax:
-~~~~~
+~~~~{.php}
 mpick
-~~~~
+~~~~
 
 Prints in the console the coordinates of a point clicked by mouse in a view (axonometric or 2D). This command will wait for mouse click event in a view.
 
 Example: 
-~~~~~{.cpp}
+~~~~{.php}
 mpick
-~~~~~
+~~~~
 
 @subsubsection occt_draw_12_2_9 mdist
 
 Syntax:
-~~~~~
+~~~~{.php}
 mdist
-~~~~
+~~~~
 
 Prints in the console the distance between two points clicked by mouse in a view (axonometric or 2D). This command will wait for two mouse click events in a view.
 
 Example: 
-~~~~~{.cpp}
+~~~~{.php}
 mdist
-~~~~~
+~~~~
 
 @section occt_draw_13 Inspector commands
 
@@ -11551,8 +11553,8 @@ This section describes commands that make possible to use Inspector.
 
 @subsection occt_draw_13_1 tinspector
 
-Syntax:                  
-~~~~~
+Syntax:
+~~~~{.php}
 tinspector [-plugins {name1 ... [nameN] | all}]
            [-activate name]
            [-shape object [name1] ... [nameN]]
@@ -11560,7 +11562,7 @@ tinspector [-plugins {name1 ... [nameN] | all}]
            [-update]
            [-select {object | name1 ... [nameN]}]
            [-show {0|1} = 1]
-~~~~~
+~~~~
 Starts inspection tool.
 Options:
 * *plugins* enters plugins that should be added in the inspector.
@@ -11582,7 +11584,7 @@ VInspector: 'object' is an instance of *AIS_InteractiveObject*;
 * *show* sets Inspector view visible or hidden. The first call of this command will show it.
 
 **Example:** 
-~~~~~
+~~~~{.php}
 pload DCAF INSPECTOR
 
 NewDocument Doc BinOcaf
@@ -11592,20 +11594,20 @@ set aLabel 0:2
 SetInteger Doc ${aLabel} ${aSetAttr1}
 
 tinspector -plugins dfbrowser -select 0:2 TDataStd_Integer
-~~~~
+~~~~
 
 **Example:** 
-~~~~~
+~~~~{.php}
 pload ALL INSPECTOR
 
 box b1 200 100 120
 box b2 100 200 220 100 120 100
 
 tinspector -plugins shapeview -shape b1 -shape b2 -select b1
-~~~~
+~~~~
 
 **Example:** 
-~~~~~
+~~~~{.php}
 pload ALL INSPECTOR
 
 tinspector -plugins vinspector
@@ -11622,7 +11624,7 @@ vselmode box_1 1 1
 vselmode box_1 3 1
 
 tinspector -update -select box_1
-~~~~
+~~~~
 
 
 @section occt_draw_11 Extending Test Harness with custom commands
@@ -11636,12 +11638,12 @@ The following chapters explain how to extend Test Harness with custom commands a
 Custom command implementation has not undergone any changes since the introduction of the plug-in mechanism. The syntax of every command should still be like in the following example. 
 
 **Example:** 
-~~~~~
+~~~~{.cpp}
 static Standard_Integer myadvcurve(Draw_Interpretor& di, Standard_Integer n, char** a) 
 { 
 ... 
 } 
-~~~~~
+~~~~
 
 For examples of existing commands refer to Open CASCADE Technology (e.g. GeomliteTest.cxx). 
 
@@ -11651,7 +11653,7 @@ For examples of existing commands refer to Open CASCADE Technology (e.g. Geomlit
 To become available in the Test Harness the custom command must be registered in it. This should be done as follows. 
 
 **Example:** 
-~~~~~
+~~~~{.cpp}
 void MyPack::CurveCommands(Draw_Interpretor& theCommands) 
 { 
 ... 
@@ -11661,7 +11663,7 @@ theCommands.Add ( "myadvcurve", "myadvcurve name p1 p2 p3 - Creates my advanced
                   __FILE__, myadvcurve, g ); 
 ... 
 } 
-~~~~~
+~~~~
 
 @subsection occt_draw_11_3 Creating a toolkit (library) as a plug-in
 
@@ -11672,7 +11674,7 @@ This exported function *PLUGINFACTORY()* must be implemented only once per libra
 For convenience the *DPLUGIN* macro (defined in the *Draw_PluginMacro.hxx* file) has been provided. It implements the *PLUGINFACTORY()* function as a call to the *Package::Factory()* method and accepts *Package* as an argument. Respectively, this *Package::Factory()* method must be implemented in the library and activate all implemented commands. 
 
 **Example:** 
-~~~~~
+~~~~{.cpp}
 #include <Draw_PluginMacro.hxx>
 
 void MyPack::Factory(Draw_Interpretor& theDI)
@@ -11685,7 +11687,7 @@ MyPack::CurveCommands(theDI);
 
 // Declare entry point PLUGINFACTORY
 DPLUGIN(MyPack)
-~~~~~
+~~~~
 
 @subsection occt_draw_11_4 Creation of the plug-in resource file
 
@@ -11695,7 +11697,7 @@ Thus, the resource file must contain a line mapping this name (key) to the libra
 For several plug-ins one resource file can be created. In such case, keys denoting plug-ins can be combined into groups, these groups -- into their groups and so on (thereby creating some hierarchy). Any new parent key must have its value as a sequence of child keys separated by spaces, tabs or commas. Keys should form a tree without cyclic dependencies. 
 
 **Examples** (file MyDrawPlugin): 
-~~~~~
+~~~~{.php}
 ! Hierarchy of plug-ins 
 ALL                : ADVMODELING, MESHING 
 DEFAULT            : MESHING 
@@ -11705,7 +11707,7 @@ ADVMODELING        : ADVSURF, ADVCURV
 ADVSURF            : TKMyAdvSurf 
 ADVCURV            : TKMyAdvCurv 
 MESHING            : TKMyMesh 
-~~~~~
+~~~~
 
 For other examples of the plug-in resource file refer to the @ref occt_draw_1_3_2 "Plug-in resource file" chapter above or to the <i>$CASROOT/src/DrawPlugin</i> file shipped with Open CASCADE Technology. 
 
@@ -11717,7 +11719,7 @@ Loading a plug-in and activating its commands is described in the @ref occt_draw
 The procedure consists in defining the system variables and using the *pload* commands in the Test Harness session. 
 
 **Example:** 
-~~~~
+~~~~{.php}
 Draw[]> set env(CSF_MyDrawPluginDefaults) /users/test
 Draw[]> pload -MyDrawPlugin ALL
 ~~~~
index 754d419fb90b5460c28cee587261d76ac242c686..a4abc1f22ba1add5d06db48545099eb61f8b8008 100644 (file)
@@ -183,9 +183,9 @@ A variable of a type manipulated by handle which is not attached to an object is
 To reference an object, we instantiate the class with one of its constructors.
 For example, in C++:
 
-~~~~~
+~~~~{.cpp}
 Handle(MyClass) anObject = new MyClass();
-~~~~~
+~~~~
 
 In Open CASCADE Technology, the Handles are specific classes that are used to safely manipulate objects allocated in the dynamic memory by reference,
 providing reference counting mechanism and automatic destruction of the object when it is not referenced.
@@ -302,15 +302,15 @@ It provides a reference counter field, inherited by all its descendant classes,
 Objects of classes derived (directly or indirectly) from *Transient*, are normally allocated in dynamic memory using operator **new**, and manipulated by handle.
 Handle is defined as template class *opencascade::handle<>*.
 Open CASCADE Technology provides preprocessor macro *Handle()* that is historically used throughout OCCT code to name a handle:
-~~~~~{.cpp}
+~~~~{.cpp}
 Handle(Geom_Line) aLine; // "Handle(Geom_Line)" is expanded to "opencascade::handle<Geom_Line>"
-~~~~~
+~~~~
 
 In addition, for most OCCT classes additional *typedef* is defined for a handle, as the name of a class prefixed by *Handle_*.
 For instance, the above example can be also coded as:
-~~~~~{.cpp}
+~~~~{.cpp}
 Handle_Geom_Line aLine; // "Handle_Geom_Line" is typedef to "opencascade::handle<Geom_Line>"
-~~~~~
+~~~~
 
 #### Using a Handle
 
@@ -318,9 +318,9 @@ A handle is characterized by the object it references.
 
 Before performing any operation on a transient object, you must declare the handle.
 For example, if Point and Line are two transient classes from the Geom package, you would write:
-~~~~~
+~~~~{.cpp}
 Handle(Geom_Point) p1, p2;
-~~~~~
+~~~~
 Declaring a handle creates a null handle that does not refer to any object.
 The handle may be checked to be null by its method *IsNull()*.
 To nullify a handle, use method *Nullify()*.
@@ -338,7 +338,7 @@ To enable this feature, a class declaration should include the declaration of OC
 Header *Standard_Type.hxx* provides two variants of preprocessor macros facilitating this:
 
 * Inline variant, which declares and defines RTTI methods by a single line of code:
-~~~~~{.cpp}
+~~~~{.cpp}
 #include <Geom_Surface.hxx>
 class Appli_ExtSurface : public Geom_Surface
 {
@@ -346,12 +346,12 @@ class Appli_ExtSurface : public Geom_Surface
 public:
   DEFINE_STANDARD_RTTIEXT(Appli_ExtSurface,Geom_Surface)
 };
-~~~~~
+~~~~
 
 * Out-of line variant, which uses one macro in the declaration (normally in the header file), and another in the implementation (in C++ source):
 
   In *Appli_ExtSurface.hxx* file:
-~~~~~{.cpp}
+~~~~{.cpp}
 #include <Geom_Surface.hxx>
 class Appli_ExtSurface : public Geom_Surface
 {
@@ -359,13 +359,13 @@ class Appli_ExtSurface : public Geom_Surface
 public:
   DEFINE_STANDARD_RTTIEXT(Appli_ExtSurface,Geom_Surface)
 };
-~~~~~
+~~~~
 
    In *Appli_ExtSurface.cxx* file:
-~~~~~{.cpp}
+~~~~{.cpp}
 #include <Appli_ExtSurface.hxx>
 IMPLEMENT_STANDARD_RTTIEXT(Appli_ExtSurface,Geom_Surface)
-~~~~~
+~~~~
 
 These macros define method *DynamicType()* that returns a type descriptor - handle to singleton instance of the class *Standard_Type* describing the class.
 The type descriptor stores the name of the class and the descriptor of its parent class.
@@ -375,12 +375,12 @@ Note that while inline version is easier to use, for widely used classes this me
 To get the type descriptor for a given class type, use macro *STANDARD_TYPE()* with the name of the class as argument.
 
 Example of usage:
-~~~~~{.cpp}
+~~~~{.cpp}
 if (aCurve->IsKind(STANDARD_TYPE(Geom_Line))) // equivalent to "if (dynamic_cast<Geom_Line>(aCurve.get()) != 0)"
 {
 ...
 }
-~~~~~
+~~~~
 
 #### Type Conformity
 
@@ -390,12 +390,12 @@ Thus, the dynamic type of an object (also called the actual type of an object) c
 
 Consider the class *Geom_CartesianPoint*, a sub-class of *Geom_Point*; the rule of type conformity can be illustrated as follows:
 
-~~~~~
+~~~~{.cpp}
 Handle(Geom_Point) aPnt1;
 Handle(Geom_CartesianPoint) aPnt2;
 aPnt2 = new Geom_CartesianPoint();
 aPnt1 = aPnt2;  // OK, the types are compatible
-~~~~~
+~~~~
 
 The compiler sees *aPnt1* as a handle to *Geom_Point* though the actual object referenced by *aPnt1* is of the *Geom_CartesianPoint* type.
 
@@ -409,19 +409,19 @@ A handle can be converted explicitly into one of its sub-types if the actual typ
 If this is not the case, the handle is nullified (explicit type conversion is sometimes called a "safe cast").
 Consider the example below.
 
-~~~~~~
+~~~~{.cpp}
 Handle(Geom_Point) aPnt1;
 Handle(Geom_CartesianPoint) aPnt2, aPnt3;
 aPnt2 = new Geom_CartesianPoint();
 aPnt1 = aPnt2; // OK, standard assignment
 aPnt3 = Handle(Geom_CartesianPoint)::DownCast (aPnt1);
 // OK, the actual type of aPnt1 is Geom_CartesianPoint, although the static type of the handle is Geom_Point
-~~~~~~
+~~~~
 
 If conversion is not compatible with the actual type of the referenced object, the handle which was "cast" becomes null (and no exception is raised).
 So, if you require reliable services defined in a sub-class of the type seen by the handle (static type), write as follows:
 
-~~~~~~
+~~~~{.cpp}
 void MyFunction (const Handle(A) & a)
 {
   Handle(B) b =  Handle(B)::DownCast(a);
@@ -432,12 +432,12 @@ void MyFunction (const Handle(A) & a)
     // the types are incompatible
   }
 }
-~~~~~~
+~~~~
 Downcasting is used particularly with collections of objects of different types; however, these objects should inherit from the same root class.
 
 For example, with a sequence of transient objects *TColStd_SequenceOfTransient* and two classes A and B that both inherit from *Standard_Transient*, you get the following syntax:
 
-~~~~~
+~~~~{.cpp}
 Handle(A) a;
 Handle(B) b;
 Handle(Standard_Transient) t;
@@ -459,17 +459,17 @@ else
 {
   // the types are incompatible
 }
-~~~~~
+~~~~
 
 @subsubsection occt_fcug_2_2_3 Using Handles to Create Objects
 
 To create an object which is manipulated by handle, declare the handle and initialize it with the standard C++ **new** operator, immediately followed by a call to the constructor.
 The constructor can be any of those specified in the source of the class from which the object is instanced.
 
-~~~~~
+~~~~{.cpp}
 Handle(Geom_CartesianPoint) aPnt;
 aPnt = new Geom_CartesianPoint (0, 0, 0);
-~~~~~
+~~~~
 
 Unlike for a pointer, the **delete** operator does not work on a handle; the referenced object is automatically destroyed when no longer in use.
 
@@ -480,7 +480,7 @@ To invoke a method which acts on the referenced object, you translate this metho
 To test or to modify the state of the handle, the method is translated by the *dot* operator.
 The example below illustrates how to access the coordinates of an (optionally initialized) point object:
 
-~~~~~
+~~~~{.cpp}
 Handle(Geom_CartesianPoint) aCentre;
 Standard_Real x, y, z;
 if (aCentre.IsNull())
@@ -488,11 +488,11 @@ if (aCentre.IsNull())
   aCentre = new PGeom_CartesianPoint (0, 0, 0);
 }
 aCentre->Coord (x, y, z);
-~~~~~
+~~~~
 
 The example below illustrates how to access the type object of a Cartesian point:
 
-~~~~~
+~~~~{.cpp}
 Handle(Standard_Transient) aPnt = new Geom_CartesianPoint (0., 0., 0.);
 if (aPnt->DynamicType() == STANDARD_TYPE(Geom_CartesianPoint))
 {
@@ -502,7 +502,7 @@ else
 {
   std::cout << "Type check FAILED\n";
 }
-~~~~~
+~~~~
 
 *Standard_NullObject* exception will be raised if a field or a method of an object is accessed via a *Null* handle.
 
@@ -512,9 +512,9 @@ A class method is called like a static C++ function, i.e. it is called by the na
 
 For example, we can find the maximum degree of a Bezier curve:
 
-~~~~~
+~~~~{.cpp}
 Standard_Integer aDegree = Geom_BezierCurve::MaxDegree();
-~~~~~
+~~~~
 
 @subsubsection occt_fcug_2_2_5 Handle deallocation
 
@@ -529,7 +529,7 @@ The object is automatically deleted by the handle when reference counter becomes
 
 The principle of allocation can be seen in the example below.
 
-~~~~~
+~~~~{.cpp}
 ...
 {
   Handle(TColStd_HSequenceOfInteger) H1 = new TColStd_HSequenceOfInteger();
@@ -549,11 +549,11 @@ The principle of allocation can be seen in the example below.
   // Here, H1 has 1 reference
 }
 // Here, H1 has no reference and the referred TColStd_HSequenceOfInteger object is deleted.
-~~~~~
+~~~~
 
 You can easily cast a reference to the handle object to <i> void* </i> by defining the following:
 
-~~~~
+~~~~{.cpp}
   void* aPointer;
   Handle(Some_Class) aHandle;
   // Here only a pointer will be copied
@@ -701,12 +701,12 @@ The following paragraphs describe recommended approaches for using exceptions wh
 #### "C++ like" Syntax
 
 The following example:
-~~~~~
+~~~~{.cpp}
 throw Standard_DomainError ("Cannot cope with this condition");
-~~~~~
+~~~~
 raises an exception of *Standard_DomainError* type with the associated message "Cannot cope with this condition", the message being optional.
 This exception may be caught by a handler of a *Standard_DomainError* type as follows:
-~~~~~
+~~~~{.cpp}
 try
 {
   OCC_CATCH_SIGNALS
@@ -716,7 +716,7 @@ catch (const Standard_DomainError& )
 {
   // handle Standard_DomainError exceptions here
 }
-~~~~~
+~~~~
 
 #### Regular usage
 
@@ -734,7 +734,7 @@ For example, if you consider the *TCollection_Array1* class used with:
 
 then, the *Value* function may be implemented as follows:
 
-~~~~~
+~~~~{.cpp}
 Item TCollection_Array1::Value (Standard_Integer theIndex) const
 {
   // where myR1 and myR2 are the lower and upper bounds of the array
@@ -744,7 +744,7 @@ Item TCollection_Array1::Value (Standard_Integer theIndex) const
   }
   return myContents[theIndex];
 }
-~~~~~
+~~~~
 
 Here validity of the index is first verified using the Lower and Upper functions in order to protect the call.
 Normally the caller ensures the index being in the valid range before calling <i>Value()</i>.
@@ -752,26 +752,26 @@ In this case the above implementation of *Value* is not optimal since the test d
  
 It is a widely used practice to include that kind of protections in a debug build of the program and exclude in release (optimized) build.
 To support this practice, the macros <i>Raise_if()</i> are provided for every OCCT exception class:
-~~~~~
+~~~~{.cpp}
 <ErrorTypeName>_Raise_if(condition, "Error message");
-~~~~~
+~~~~
 where *ErrorTypeName* is the exception type, *condition* is the logical expression leading to the raise of the exception, and *Error message* is the associated message.
   
 The entire call may be removed by defining one of the preprocessor symbols *No_Exception* or <i>No_<ErrorTypeName></i> at compile-time:
 
-~~~~~
+~~~~{.cpp}
 #define No_Exception // remove all raises
-~~~~~
+~~~~
 
 Using this syntax, the *Value* function becomes:
 
-~~~~~
+~~~~{.cpp}
 Item TCollection_Array1::Value (Standard_Integer theIndex) const
 {
   Standard_OutOfRange_Raise_if(theIndex < myR1 || theIndex > myR2, "index out of range in TCollection_Array1::Value");
   return myContents[theIndex];
 }
-~~~~~
+~~~~
 
 @subsubsection occt_fcug_2_4_3 Handling an Exception
 
@@ -788,7 +788,7 @@ The recommended location for it is first statement after opening brace of <i>try
 
 As an example, consider the exceptions of type *Standard_NumericError, Standard_Overflow, Standard_Underflow* and *Standard_DivideByZero*, where *Standard_NumericError* is the parent type of the three others.
 
-~~~~~
+~~~~{.cpp}
 void f(1)
 {
   try
@@ -805,7 +805,7 @@ void f(1)
     // ...
   }
 }
-~~~~~
+~~~~
 
 Here, the first handler will catch exceptions of *Standard_Overflow* type
 and the second one -- exceptions of *Standard_NumericError* type and all exceptions derived from it, including *Standard_Underflow* and *Standard_DivideByZero*.
@@ -813,7 +813,7 @@ and the second one -- exceptions of *Standard_NumericError* type and all excepti
 The handlers are checked in order of appearance, from the nearest to the try block to the most distant from it, until one matches the raise expression.
 For a try block, it would be a mistake to place a handler for a base exception type ahead of a handler for its derived type since that would ensure that the handler for the derived exception would never be invoked.
 
-~~~~~
+~~~~{.cpp}
 void f(1)
 {
   int i = 0;
@@ -832,7 +832,7 @@ void f(1)
   }
   . . .
 }
-~~~~~
+~~~~
 
 The exceptions form a hierarchy tree completely separated from other user defined classes.
 One exception of type *Standard_Failure* is the root of the entire exception hierarchy.
@@ -841,7 +841,7 @@ It is recommended to set up such a handler in the main routine.
 
 The main routine of a program would look like this:
 
-~~~~~
+~~~~{.cpp}
 #include <Standard_ErrorHandler.hxx>
 #include <Standard_Failure.hxx>
 #include <iostream>
@@ -859,7 +859,7 @@ int main (int argc, char* argv[])
   }
   return 1;
 }
-~~~~~
+~~~~
 
 Though standard C++ scoping rules and syntax apply to try block and handlers, note that on some platforms Open CASCADE Technology may be compiled in compatibility mode when exceptions are emulated by long jumps (see below).
 In this mode it is required that no statement precedes or follows any handler.
@@ -921,17 +921,17 @@ Foundation classes provide in the package *Plugin* a method named *Load()*, whic
 
 That method reads the information regarding available plug-ins and their locations from the resource file *Plugin* found by environment variable *CSF_PluginDefaults*:
 
-~~~~
+~~~~
 $CSF_PluginDefaults/Plugin
-~~~~~
+~~~~
 
 The *Load* method looks for the library name in the resource file or registry through its GUID, for example, on UNIX:
-~~~~~
+~~~~
 ! METADATADRIVER whose value must be OS or DM.
 
 ! FW
 a148e300-5740-11d1-a904-080036aaa103.Location: libFWOSPlugin.so
-~~~~~
+~~~~
 
 Then the *Load* method loads the library according to the rules of the operating system of the host machine (for example, by using environment variables such as *LD_LIBRARY_PATH* with Unix and *PATH* with Windows).
 After that it invokes the *PLUGINFACTORY* method to return the object, which supports the required service.
@@ -941,13 +941,13 @@ The client may then call the functions supported by this object.
 
 To invoke one of the services provided by the plug-in, you may call the *Plugin::Load()* global function with the *Standard_GUID* of the requested service as follows:
 
-~~~~~{.cpp}
+~~~~{.cpp}
 Handle(FADriver_PartStorer)::DownCast(PlugIn::Load (yourStandardGUID));
-~~~~~
+~~~~
 
 Let us take *FAFactory.hxx* and *FAFactory.cxx* as an example:
 
-~~~~~{.cpp}
+~~~~{.cpp}
 #include <Standard_Macro.hxx>
 #include <Standard_GUID.hxx>
 #include <Standard_Transient.hxx>
@@ -957,9 +957,9 @@ class FAFactory
 public:
   Standard_EXPORT static Handle(Standard_Transient) Factory (const Standard_GUID& theGUID);
 };
-~~~~~
+~~~~
 
-~~~~~{.cpp}
+~~~~{.cpp}
 #include <FAFactory.hxx>
 
 #include <FADriver_PartRetriever.hxx>
@@ -1004,7 +1004,7 @@ Handle(Standard_Transient) FAFactory::Factory (const Standard_GUID& theGUID)
 
 // export plugin function "PLUGINFACTORY"
 PLUGIN(FAFactory)
-~~~~~
+~~~~
 
 Application might also instantiate a factory by linking to the library and calling *FAFactory::Factory()* directly.
 
@@ -1042,14 +1042,14 @@ These definitions are now obsolete though still can be used, particularly for co
 
 Let see an example of NCollection template class instantiation for a sequence of points in the header file *MyPackage_SequenceOfPnt.hxx* (analogue of *TColgp_SequenceOfPnt*):
 
-~~~~~{.cpp}
+~~~~{.cpp}
 #include <NCollection_Sequence.hxx>
 #include <gp_Pnt.hxx>
 typedef NCollection_Sequence<gp_Pnt> MyPackage_SequenceOfPnt;
-~~~~~
+~~~~
 
 For the case, when sequence itself should be managed by handle, auxiliary macros *DEFINE_HSEQUENCE* can be used:
-~~~~~{.cpp}
+~~~~{.cpp}
 #include <NCollection_Sequence.hxx>
 #include <NCollection_DefineHSequence.hxx>
 #include <gp_Pnt.hxx>
@@ -1057,7 +1057,7 @@ typedef NCollection_Sequence<gp_Pnt> MyPackage_SequenceOfPnt;
 DEFINE_HSEQUENCE(MyPackage_HSequenceOfPnt, MyPackage_SequenceOfPnt)
 ...
 Handle(MyPackage_HSequenceOfPnt) aSeq = new MyPackage_HSequenceOfPnt();
-~~~~~
+~~~~
 
 See more details about available collections in following sections.
 
@@ -1302,7 +1302,7 @@ The common methods of Iterator are:
 
 Usage sample:
 
-~~~~~{.cpp}
+~~~~{.cpp}
 typedef Ncollection_Sequence<gp_Pnt> MyPackage_SequenceOfPnt;
 void Perform (const MyPackage_SequenceOfPnt& theSequence)
 {
@@ -1312,17 +1312,17 @@ void Perform (const MyPackage_SequenceOfPnt& theSequence)
     ...
   }
 }
-~~~~~
+~~~~
 
 @subsubsection occt_fcug_3_1_5 Allocators
 
 All constructors of *NCollection* classes receive the *Allocator* object as the last parameter.
 This is an object of a type managed by Handle, inheriting *NCollection_BaseAllocator*, with the following (mandatory) methods redefined:
 
-~~~~~{.cpp}
+~~~~{.cpp}
   virtual void* Allocate (const size_t theSize) override;
   virtual void  Free (void* theAddress) override;
-~~~~~
+~~~~
 
 It is used internally every time when the collection allocates memory for its item(s) and releases this memory.
 The default value of this parameter (empty *Handle*) designates the use of *NCollection_BaseAllocator*, where the functions *Standard::Allocate* and *Standard::Free* are called.
@@ -1360,7 +1360,7 @@ Among the best suitable solutions there can be a pointer to an object, handled o
 The bounding object may have any dimension and geometry.
 The minimal interface of *TheBndType* (besides public empty and copy constructor and operator=) used in NCollection_UBTree algorithm as follows:
 
-~~~~~{.cpp}
+~~~~{.cpp}
 class MyBndType
 {
 public:
@@ -1373,7 +1373,7 @@ public:
   //! Computes the squared maximal linear extent of me (for a box it is the squared diagonal of the box).
   Standard_Real SquareExtent() const;
 };
-~~~~~
+~~~~
    
 This interface is implemented in types of Bnd package: *Bnd_Box, Bnd_Box2d, Bnd_B2x, Bnd_B3x*.
 
@@ -1384,7 +1384,7 @@ The quality of a tree is better (considering the speed of searches) if objects a
 Instantiation of *NCollection_UBTreeFiller* collects objects to be added, and then adds them at once to the given NCollection_UBTree instance in a random order using the Fisher-Yates algorithm.
 Below is the sample code that creates an instance of *NCollection_UBTree* indexed by 2D boxes (Bnd_B2f), then a selection is performed returning the objects whose bounding boxes contain the given 2D point.
 
-~~~~~{.cpp}
+~~~~{.cpp}
 typedef NCollection_UBTree<MyData, Bnd_B2f> UBTree;
 typedef NCollection_List<MyData> ListOfSelected;
 //! Tree Selector type
@@ -1426,7 +1426,7 @@ aTreeFiller.Fill();
 MyTreeSelector aSel (aPoint2d);
 aTree.Select (aSel);
 const ListOfSelected& aSelected = aSel.ListAccepted();
-~~~~~
+~~~~
 
 ##### NCollection_CellFilter
 
@@ -1438,10 +1438,10 @@ while search with NCollection_UBTree provides logarithmic law access time.
 
 Packages *TShort*, *TColGeom*, *TColGeom2d*, *TColStd*, *TColgp* provide template instantiations (typedefs) of *NCollection* templates to standard OCCT types.
 Classes with *H* prefix in name are handle-based variants and inherit Standard_Transient.
-~~~~~{.cpp}
+~~~~{.cpp}
 typedef NCollection_Array1<gp_Vec>                  TColgp_Array1OfVec;
 typedef NCollection_Array1<TCollection_AsciiString> TColStd_Array1OfAsciiString;
-~~~~~
+~~~~
 
 Packages like *TopTools* also include definitions of collections and hash functions for complex types like shapes -- *TopTools_ShapeMapHasher*, *TopTools_MapOfShape*.
 
@@ -1525,27 +1525,27 @@ These classes also provide a data structure to represent any expression, relatio
 
 Vectors and matrices have arbitrary ranges which must be defined at declaration time and cannot be changed after declaration.
 
-~~~~~{.cpp}
+~~~~{.cpp}
 math_Vector aVec (1, 3);
 // a vector of dimension 3 with range (1..3)
 math_Matrix aMat (0, 2, 0, 2);
 // a matrix of dimension 3x3 with range (0..2, 0..2)
 math_Vector aVec (N1, N2);
 // a vector of dimension N2-N1+1 with range (N1..N2)
-~~~~~
+~~~~
 
 Vector and Matrix objects use value semantics.
 In other words, they cannot be shared and are copied through assignment.
 
-~~~~~{.cpp}
+~~~~{.cpp}
 math_Vector aVec1 (1, 3), aVec2 (0, 2);
 aVec2 = aVec1;
 // aVec1 is copied into aVec2; a modification of aVec1 does not affect aVec2
-~~~~~
+~~~~
 
 Vector and Matrix values may be initialized and obtained using indexes which must lie within the range definition of the vector or the matrix.
 
-~~~~~{.cpp}
+~~~~{.cpp}
 math_Vector aVec (1, 3);
 math_Matrix aMat (1, 3, 1, 3);
 Standard_Real aValue;
@@ -1554,7 +1554,7 @@ aVec (2) = 1.0;
 aValue = aVec(1);
 aMat (1, 3) = 1.0;
 aValue = aMat (2, 2);
-~~~~~
+~~~~
 
 Some operations on Vector and Matrix objects may not be legal.
 In this case an exception is raised.
@@ -1562,12 +1562,12 @@ Two standard exceptions are used:
   * *Standard_DimensionError* exception is raised when two matrices or vectors involved in an operation are of incompatible dimensions.
   * *Standard_RangeError* exception is raised if an access outside the range definition of a vector or of a matrix is attempted.
 
-~~~~~~{.cpp}
+~~~~{.cpp}
 math_Vector aVec1 (1, 3), aVec2 (1, 2), aVec3 (0, 2);
 aVec1 = aVec2;   // error: Standard_DimensionError is raised
 aVec1 = aVec3;   // OK: ranges are not equal but dimensions are compatible
 aVec1 (0) = 2.0; // error: Standard_RangeError is raised
-~~~~~~
+~~~~
 
 @subsection occt_occt_fcug_4_3 Primitive Geometric Types
 
@@ -1649,7 +1649,7 @@ They contain:
 The example below demonstrates the use of the math_Gauss class, which implements the Gauss solution for a set of linear equations.
 The following definition is an extract from the header file of the class *math_Gauss*:
 
-~~~~~~{.cpp}
+~~~~{.cpp}
 class math_Gauss
 {
 public:
@@ -1657,11 +1657,11 @@ public:
   Standard_Boolean IsDone() const;
   void Solve (const math_Vector& B, math_Vector& X) const;
 };
-~~~~~~
+~~~~
 
 Now the main program uses the math_Gauss class to solve the equations _a*x1=b1_ and _a*x2=b2_:
 
-~~~~~{.cpp}
+~~~~{.cpp}
 #include <math_Vector.hxx> 
 #include <math_Matrix.hxx>
 main()
@@ -1686,12 +1686,12 @@ main()
     // StdFail_NotDone is raised
   }
 }
-~~~~~
+~~~~
 
 The next example demonstrates the use of the *math_BissecNewton* class, which implements a combination of the Newton and Bissection algorithms to find the root of a function known to lie between two bounds.
 The definition is an extract from the header file of the class *math_BissecNewton*:
 
-~~~~~{.cpp}
+~~~~{.cpp}
 class math_BissecNewton
 {
 public:
@@ -1702,12 +1702,12 @@ public:
   Standard_Boolean IsDone() const;
   Standard_Real Root();
 }; 
-~~~~~
+~~~~
 
 The abstract class *math_FunctionWithDerivative* describes the services which have to be implemented for the function _f_ which is to be used by a *math_BissecNewton* algorithm.
 The following definition corresponds to the header file of the abstract class *math_FunctionWithDerivative*:
 
-~~~~~{.cpp}
+~~~~{.cpp}
 class math_FunctionWithDerivative
 {
 public:
@@ -1715,12 +1715,12 @@ public:
   virtual Standard_Boolean Derivative (const Standard_Real x, Standard_Real& d) = 0;
   virtual Standard_Boolean Values (const Standard_Real x, Standard_Real& f, Standard_Real& d) = 0;
 };
-~~~~~
+~~~~
 
 Now the test sample uses the *math_BissecNewton* class to find the root of the equation _f(x)=x**2-4_ in the interval [1.5, 2.5].
 The function to solve is implemented in the class *myFunction* which inherits from the class *math_FunctionWithDerivative*, then the main program finds the required root.
 
-~~~~~{.cpp}
+~~~~{.cpp}
 #include <math_BissecNewton.hxx>
 #include <math_FunctionWithDerivative.hxx>
 class myFunction : public math_FunctionWithDerivative
@@ -1759,7 +1759,7 @@ main()
   else // no
   {
   }
-~~~~~
+~~~~
 
 @subsection occt_occt_fcug_4_7 Precision
 
@@ -1796,10 +1796,10 @@ The choice of precision value for parametric space depends not only on the accur
 This is because it is desirable to link parametric precision and real precision.
 If you are on a curve defined by the equation *P(t)*, you would want to have equivalence between the following:
 
-~~~~~
+~~~~{.cpp}
   Abs (t1 - t2) < ParametricPrecision
   Distance (P(t1), P(t2)) < RealPrecision
-~~~~~
+~~~~
 
 @subsubsection occt_occt_fcug_4_7_1 The Precision package
 
@@ -1832,7 +1832,7 @@ This method is used to compare two angles.
 Its current value is *Epsilon(2 *  PI)* i.e. the smallest number *x* such that *2*PI + x* is different of *2\*PI*.
 
 It can be used to check confusion of two angles as follows:
-~~~{.cpp}
+~~~~{.cpp}
 bool areEqualAngles (double theAngle1, double theAngle2)
 {
   return Abs(theAngle1  - theAngle2) < Precision::Angular();
@@ -1840,7 +1840,7 @@ bool areEqualAngles (double theAngle1, double theAngle2)
 ~~~
 
 It is also possible to check parallelism of two vectors as follows:
-~~~{.cpp}
+~~~~{.cpp}
 bool areParallelVectors (const gp_Vec& theVec1, const gp_Vec& theVec2)
 {
   return theVec1.IsParallel (theVec2, Precision::Angular());
@@ -1849,7 +1849,7 @@ bool areParallelVectors (const gp_Vec& theVec1, const gp_Vec& theVec2)
 
 Note that *Precision::Angular()* can be used on both dot and cross products because for small angles the *Sine* and the *Angle* are equivalent.
 So to test if two directions of type *gp_Dir* are perpendicular, it is legal to use the following code:
-~~~{.cpp}
+~~~~{.cpp}
 bool arePerpendicular (const gp_Dir& theDir1, const gp_Dir& theDir2)
 {
   return Abs(theDir1 * theDir2) < Precision::Angular();
@@ -1862,7 +1862,7 @@ This method is used to test 3D distances.
 The current value is *1.e-7*, in other words, 1/10 micron if the unit used is the millimeter.
 
 It can be used to check confusion of two points as follows:
-~~~{.cpp}
+~~~~{.cpp}
 bool areEqualPoints (const gp_Pnt& thePnt1, const gp_Pnt& thePnt2)
 {
   return thePnt1.IsEqual (thePnt2, Precision::Confusion());
@@ -1870,7 +1870,7 @@ bool areEqualPoints (const gp_Pnt& thePnt1, const gp_Pnt& thePnt2)
 ~~~
 
 It is also possible to find a vector of null length:
-~~~{.cpp}
+~~~~{.cpp}
 bool isNullVector (const gp_Vec& theVec)
 {
   return theVec.Magnitude() < Precision::Confusion();
index 914cdacbe420176f652453cb952172aba884f6ae..3d2323e1d96299fd6be296269b09349a3ae6e233 100644 (file)
@@ -60,25 +60,25 @@ Administrative data, in the Global Section of the IGES  file (such as the file n
 @subsection occt_iges_2_3 Description of the process
 @subsubsection occt_iges_2_3_1 Loading the IGES file
 Before performing any  other operation, you have to load the file using the syntax below. 
-~~~~~
+~~~~{.cpp}
 IGESControl_Reader reader; 
 IFSelect_ReturnStatus stat  = reader.ReadFile(“filename.igs”); 
-~~~~~
+~~~~
 The loading operation  only loads the IGES file into computer memory; it does not translate it. 
 
 @subsubsection occt_iges_2_3_2 Checking the IGES file
 This step is not obligatory.  Check the loaded file with:  
-~~~~~
+~~~~{.cpp}
 Standard_Boolean ok =  reader.Check(Standard_True); 
-~~~~~
+~~~~
 The variable “ok is  True” is returned if no fail message was found; “ok is False” is returned if  there was at least one fail message.  
-~~~~~
+~~~~{.cpp}
 reader.PrintCheckLoad  (failsonly, mode); 
-~~~~~
+~~~~
 Error messages are  displayed if there are invalid or incomplete IGES entities, giving you  information on the cause of the error.  
-~~~~~
+~~~~{.cpp}
 Standard_Boolean failsonly  = Standard_True or Standard_False; 
-~~~~~
+~~~~
 If you give True, you  will see fail messages only. If you give False, you will see both fail and  warning messages.  
 
 Your analysis of the  file can be either message-oriented or entity-oriented. Choose your preference  with *IFSelect_PrintCount mode =  IFSelect_xxx*, where *xxx* can be any of  the following: 
@@ -98,14 +98,14 @@ manages the continuity of BSpline curves (IGES entities  106, 112 and 126) after
 * 2:    This option concerns IGES Spline curves only.  IGES Spline curves are broken down into pieces of C2 continuity. If C2 cannot  be ensured, the Spline curves will be broken down into pieces of C1 continuity.   
 
 Read this parameter  with:  
-~~~~~
+~~~~{.cpp}
 Standard_Integer ic =  Interface_Static::IVal("read.iges.bspline.continuity"); 
-~~~~~
+~~~~
 Modify this value with:  
-~~~~~
+~~~~{.cpp}
 if  (!Interface_Static::SetIVal ("read.iges.bspline.continuity",2))  
 .. error ..; 
-~~~~~
+~~~~
 Default value is 1. 
 
 This parameter does not change the continuity of curves  that are used in the construction of IGES BRep entities. In this case, the  parameter does not influence the continuity of the resulting OCCT curves (it is  ignored). 
@@ -117,14 +117,14 @@ reads the precision  value.
 * User  (1)     the precision value is that of the read.precision.val parameter.  
 
 Read this parameter  with:  
-~~~~~
+~~~~{.cpp}
 Standard_Integer ic =  Interface_Static::IVal("read.precision.mode"); 
-~~~~~
+~~~~
 Modify this value with:  
-~~~~~
+~~~~{.cpp}
 if  (!Interface_Static::SetIVal ("read.precision.mode",1))  
 .. error ..; 
-~~~~~
+~~~~
 Default value is  *File* (0).  
 
 <h4>read.precision.val</h4>
@@ -133,14 +133,14 @@ User defined precision value. This parameter gives the precision for shape const
 This value is in the  measurement unit defined in the IGES file header.  
 
 Read this parameter  with:  
-~~~~~
+~~~~{.cpp}
 Standard_Real rp =  Interface_Static::RVal("read.precision.val"); 
-~~~~~
+~~~~
 Modify this parameter  with:  
-~~~~~
+~~~~{.cpp}
 if  (!Interface_Static::SetRVal ("read.precision.val",0.001))  
 .. error ..; 
-~~~~~
+~~~~
 Default value is 0.0001.   
 
 The value given to  this parameter is a target value that is applied to *TopoDS_Vertex, TopoDS_Edge*  and *TopoDS_Face* entities. The processor does its best to reach it. Under  certain circumstances, the value you give may not be attached to all of the  entities concerned at the end of processing. IGES-to-OCCT translation does not  improve the quality of the geometry in the original IGES file. This means that  the value you enter may be impossible to attain the given quality of geometry  in the IGES file.
@@ -154,27 +154,27 @@ defines the mode of  applying the maximum allowed tolerance. Its possible values
 * *Forced(1)*              maximum  tolerance is used as a rigid limit, i.e. it can not be exceeded and, if this  happens, tolerance is trimmed to suit the maximum-allowable value.  
 
 Read this parameter  with:  
-~~~~~
+~~~~{.cpp}
 Standard_Integer mv =  Interface_Static::IVal("read.maxprecision.mode"); 
-~~~~~
+~~~~
 Modify this parameter  with:  
-~~~~~
+~~~~{.cpp}
 if  (!Interface_Static::SetIVal ("read.maxprecision.mode",1))  
 .. error ..; 
-~~~~~
+~~~~
 Default value is  *Preferred (0)*.  
 
 <h4>read.maxprecision.val</h4>
 defines the maximum  allowable tolerance (in mm) of the shape. It should be not less than the basis  value of tolerance set in processor (either Resolution from the file or  *read.precision.val*). Actually, the maximum between *read.maxprecision.val* and  basis tolerance is used to define maximum allowed tolerance.  
 Read this parameter  with:  
-~~~~~
+~~~~{.cpp}
 Standard_Real rp =  Interface_Static::RVal("read.maxprecision.val"); 
-~~~~~
+~~~~
 Modify this parameter with:  
-~~~~~
+~~~~{.cpp}
 if  (!Interface_Static::SetRVal ("read.maxprecision.val",0.1))  
 .. error ..; 
-~~~~~
+~~~~
 Default value is 1.  
 
 <h4>read.stdsameparameter.mode</h4>
@@ -183,14 +183,14 @@ defines the using of  *BRepLib\::SameParameter*. Its possible values are:
 * 1 (On) -- *BRepLib\::SameParameter* is called.  
 *BRepLib\::SameParameter* is used through  *ShapeFix_Edge\::SameParameter*. It ensures that the resulting edge will have the  lowest tolerance taking pcurves either unmodified from the IGES file or  modified by *BRepLib\::SameParameter*.  
 Read this parameter  with:  
-~~~~~
+~~~~{.cpp}
 Standard_Integer mv =  Interface_Static::IVal("read.stdsameparameter.mode"); 
-~~~~~
+~~~~
 Modify this parameter  with:  
-~~~~~
+~~~~{.cpp}
 if  (!Interface_Static::SetIVal ("read.stdsameparameter.mode",1))  
 .. error ..; 
-~~~~~
+~~~~
 Deafault value is 0 (Off).  
 
 <h4>read.surfacecurve.mode</h4>
@@ -224,42 +224,42 @@ In any other case, the  2D representation is preferred to the 3D.
 If either a 3D or a 2D  contour is absent in the file or cannot be translated, then it is re-computed  from another contour. If the translation of both 2D and 3D contours fails, the  whole curve (type 141 or 142) is not translated. If this curve is used for  trimming a face, the face will be translated without this trimming and will  have natural restrictions.  
 
 Read this parameter  with:  
-~~~~~
+~~~~{.cpp}
 Standard_Integer ic =  Interface_Static::IVal("read.surfacecurve.mode"); 
-~~~~~
+~~~~
 Modify this value with:  
-~~~~~
+~~~~{.cpp}
 if  (!Interface_Static::SetIVal ("read.surfacecurve.mode",3))  
 .. error ..; 
-~~~~~
+~~~~
 Default value is  Default (0). 
 
 <h4>read.encoderegularity.angle</h4>
 This parameter is used within the *BRepLib::EncodeRegularity()*  function which is called for a shape read from an IGES or a STEP file at the  end of translation process. This function sets the regularity flag of an edge  in a shell when this edge is shared by two faces. This flag shows the  continuity, which these two faces are connected with at that edge.  
 
 Read this parameter  with:  
-~~~~~
+~~~~{.cpp}
 Standard_Real era =   Interface_Static::RVal("read.encoderegularity.angle"); 
-~~~~~
+~~~~
 Modify this parameter with:  
-~~~~~
+~~~~{.cpp}
 if  (!Interface_Static::SetRVal ("read.encoderegularity.angle",0.1))   
 .. error ..; 
-~~~~~
+~~~~
 Default value is 0.01.  
 
 <h4>read.iges.bspline.approxd1.mode</h4>
 This parameter is obsolete (it is rarely used in real  practice). If set to True, it affects the translation of bspline curves of  degree 1 from IGES: these curves (which geometrically are polylines) are split  by duplicated points, and the translator attempts to convert each of the  obtained parts to a bspline of a higher continuity.  
 
 Read this parameter with:  
-~~~~~
+~~~~{.cpp}
 Standard_Real bam =   Interface_Static::CVal("read.iges.bspline.approxd1.mode"); 
-~~~~~
+~~~~
 Modify this parameter with:  
-~~~~~
+~~~~{.cpp}
 if  (!Interface_Static::SetRVal ("read.encoderegularity.angle","On"))   
 .. error ..; 
-~~~~~
+~~~~
 Default value is Off.  
 
 
@@ -282,41 +282,41 @@ Default value is MM.
 @subsubsection occt_iges_2_3_4 Selecting entities
 
 A list of entities can  be formed by invoking the method *IGESControl_Reader::GiveList*.
-~~~~
+~~~~{.cpp}
 Handle(TColStd_HSequenceOfTransient)  list = reader.GiveList(); 
-~~~~~
+~~~~
 Several predefined  operators can be used to select a list of entities of a specific type. 
-To make a selection, use the method *IGESControl_Reader::GiveList* with the selection type in  quotation marks as an argument. You can also make cumulative selections. For  example, you would use the following syntax: 
+To make a selection, use the method *IGESControl_Reader::GiveList* with the selection type in  quotation marks as an argument. You can also make cumulative selections. For  example, you would use the following Syntax:
 1. Requesting the faces in the  file: 
-~~~~~
+~~~~{.cpp}
 faces =  Reader.GiveList("iges-faces"); 
-~~~~~
+~~~~
 2. Requesting the visible roots  in the file: 
-~~~~~
+~~~~{.cpp}
 visibles =  Reader.GiveList(iges-visible-roots); 
-~~~~~
+~~~~
 3.  Requesting the visible faces:
-~~~~
+~~~~{.cpp}
 visfac =  Reader.GiveList(iges-visible-roots,faces); 
-~~~~~
+~~~~
 Using a signature, you  can define a selection dynamically, filtering the string by means of a  criterion. When you request a selection using the method GiveList, you can give  either a predefined selection or a selection by signature. You make your selection  by signature using the predefined signature followed by your criterion in  parentheses as shown in the example below. The syntaxes given are equivalent to  each other. 
-~~~~~
+~~~~{.cpp}
 faces =  Reader.GiveList(“xst-type(SurfaceOfRevolution)”); 
 faces =  Reader.GiveList(“iges-type(120)”); 
-~~~~~
+~~~~
 You can also look for: 
   * values returned by your  signature which match your criterion exactly
-~~~~~  
+~~~~{.cpp}
 faces =  Reader.GiveList(“xst-type(=SurfaceOfRevolution)”); 
-~~~~~
+~~~~
   * values returned by your  signature which do not contain your criterion
-~~~~~  
+~~~~{.cpp}
 faces = Reader.GiveList(“xst-type(!SurfaceOfRevolution)”); 
-~~~~~
+~~~~
   * values returned by your  signature which do not exactly match your criterion.
-~~~~~  
+~~~~{.cpp}
 faces =  Reader.GiveList(“xst-type(!=SurfaceOfRevolution)”); 
-~~~~~
+~~~~
 
 <h4>List of predefined operators that can be used:</h4>
   * *xst-model-all* -- selects all entities. 
@@ -342,62 +342,62 @@ faces =  Reader.GiveList(“xst-type(!=SurfaceOfRevolution)”);
 @subsubsection occt_iges_2_3_5 Performing the  IGES file translation
 Perform translation  according to what you want to translate:  
 1.  Translate an entity identified  by its rank with:  
-~~~~~
+~~~~{.cpp}
 Standard_Boolean ok =  reader.Transfer (rank); 
-~~~~~
+~~~~
 2.  Translate an entity  identified by its handle with: 
-~~~~~
+~~~~{.cpp}
 Standard_Boolean ok =  reader.TransferEntity (ent); 
-~~~~~
+~~~~
 3. Translate a list of entities  in one operation with:  
-~~~~~
+~~~~{.cpp}
 Standard_Integer nbtrans =  reader.TransferList (list); 
 reader.IsDone(); 
-~~~~~
+~~~~
 where *nbtrans* returns the number of items  in the list that produced a shape and    *reader.IsDone()* indicates  whether at least one entity was translated. 
 4. Translate a list of entities,  entity by entity: 
-~~~~
+~~~~{.cpp}
 Standard_Integer i,nb =  list-Length();  
 for (i = 1; i  <= nb; i ++) {  
     Handle(Standard_Transient) ent = list-Value(i);  
     Standard_Boolean OK = reader.TransferEntity (ent);  
 } 
-~~~~~    
+~~~~
 5.  Translate the whole file (all  entities or only visible entities) with:  
-~~~~~
+~~~~{.cpp}
 Standard_Boolean  onlyvisible = Standard_True or Standard_False;  
 reader.TransferRoots(onlyvisible) 
-~~~~~
+~~~~
 
 @subsubsection occt_iges_2_3_6 Getting the  translation results
 Each successful  translation operation outputs one shape. A series of translations gives a  series of shapes.  
 Each time you invoke  *TransferEntity, Transfer* or *Transferlist*, their results are accumulated and  NbShapes increases. You can clear the results (Clear function) between two  translation operations, if you do not do this, the results from the next  translation will be added to the accumulation. *TransferRoots* operations  automatically clear all existing results before they start.  
-~~~~~
+~~~~{.cpp}
 Standard_Integer nbs =  reader.NbShapes(); 
-~~~~~
+~~~~
 returns the number of  shapes recorded in the result.  
-~~~~~
+~~~~{.cpp}
 TopoDS_Shape shape =  reader.Shape(num);, 
-~~~~~
+~~~~
 returns the result *num*, where *num* is an integer between 1 and *NbShapes*.  
-~~~~~
+~~~~{.cpp}
 TopoDS_Shape shape =  reader.Shape(); 
-~~~~~
+~~~~
 returns the first result  in a translation operation.  
-~~~~~
+~~~~{.cpp}
 TopoDS_Shape shape =  reader.OneShape(); 
-~~~~~
+~~~~
 returns all results in a  single shape which is:  
   * a null shape if there are no  results, 
   * in case of a single result, a  shape that is specific to that result, 
   * a compound that lists the  results if there are several results. 
-~~~~~  
+~~~~{.cpp}
 reader.Clear(); 
-~~~~~
+~~~~
 erases the existing  results.  
-~~~~~
+~~~~{.cpp}
 reader.PrintTransferInfo  (failsonly, mode); 
-~~~~~
+~~~~
 displays the messages  that appeared during the last invocation of *Transfer* or *TransferRoots*.  
 
 If *failsonly* is  *IFSelect_FailOnly*, only fail messages will be output, if it is  *IFSelect_FailAndWarn*, all messages will be output. Parameter “mode” can have  *IFSelect_xxx* values where *xxx* can be:
@@ -490,25 +490,25 @@ If a *TopoDS_Face* is output, its geometrical support is a  *Geom_Surface* and i
 @subsection occt_iges_2_5 Messages
 Messages are displayed concerning the normal functioning of  the processor (transfer, loading, etc.).  
 You must declare an include file: 
-~~~~~
+~~~~{.cpp}
 #include \<Interface_DT.hxx\> 
-~~~~~
+~~~~
 
 You have the choice of the following options for messages: 
-~~~~~
+~~~~{.cpp}
 IDT_SetLevel (level); 
-~~~~~
+~~~~
 level modifies the level of messages: 
   * 0: no messages
   * 1: raise and fail messages are displayed, as are messages  concerning file access,
   * 2: warnings are also displayed.
-~~~~~  
+~~~~{.cpp}
 IDT_SetFile (“tracefile.log”); 
-~~~~~
+~~~~
 prints the messages in a file, 
-~~~~~
+~~~~{.cpp}
 IDT_SetStandard(); 
-~~~~~
+~~~~
 restores screen output. 
 
 @subsection occt_iges_2_6 Tolerance management
@@ -605,7 +605,7 @@ The highlighted classes produce OCCT geometry.
 
 @subsection occt_iges_2_8 Example
 
-~~~~~
+~~~~{.cpp}
 #include “IGESControl_Reader.hxx” 
 #include “TColStd_HSequenceOfTransient.hxx” 
 #include “TopoDS_Shape.hxx” 
@@ -627,7 +627,7 @@ cout<<"IGES Faces: "<<nIgesFaces<<"   Transferred:"<<nTransFaces<<endl;
 TopoDS_Shape sh = myIgesReader.OneShape(); 
 //and obtains the results in an OCCT shape. 
 } 
-~~~~~
+~~~~
 
 @section occt_iges_3 Writing IGES
 @subsection occt_iges_3_1 Procedure
@@ -665,13 +665,13 @@ The following parameters are used for the OCCT-to-IGES  translation.
  * "Faces" (0): OCCT *TopoDS_Faces* will be translated into IGES 144 (Trimmed Surface) entities, no BRep entities  will be written to the IGES file,  
  * "BRep" (1): OCCT *TopoDS_Faces*  will be translated into IGES 510 (Face) entities, the IGES file will contain  BRep entities.  
 Read this parameter  with:  
-~~~~~
+~~~~{.cpp}
 Standard_Integer byvalue =  Interface_Static::IVal("write.iges.brep.mode"); 
-~~~~~
+~~~~
 Modify this parameter  with:  
-~~~~~
+~~~~{.cpp}
 Interface_Static::SetIVal  ("write.iges.brep.mode", 1); 
-~~~~~
+~~~~
 Default value is "Faces" (0).  
 * *write.convertsurface.mode* when writing to IGES in the BRep mode, this parameter indicates whether elementary surfaces (cylindrical, conical,  spherical,   and toroidal) are converted into corresponding IGES 5.3 entities (if  the value of a parameter value is On), or written as surfaces of revolution (by default). 
 * *write.iges.unit:* allows choosing the unit. The default unit for Open CASCADE Technology is "MM" (millimeter). You can  choose to write a file into any unit accepted by IGES.  
@@ -700,46 +700,46 @@ Default value is "Faces" (0).
 * *write.precision.val:* is the user precision value.  This parameter gives the resolution value for an IGES file when the  *write.precision.mode* parameter value is 1.  It is equal to 0.0001 by default, but can take any real positive (non null) value.  
 
 Read this parameter  with:  
-~~~~~
+~~~~{.cpp}
 Standard_Real rp =  Interface_Static::RVal(;write.precision.val;); 
-~~~~~
+~~~~
 Modify this parameter  with:  
-~~~~~
+~~~~{.cpp}
 if  (!Interface_Static::SetRVal(;write.precision.val;,0.01))  
 .. error .. 
-~~~~~
+~~~~
 Default value is 0.0001. 
 
 <h4>write.iges.resource.name</h4> and <h4>write.iges.sequence</h4> are the same as the corresponding read.iges.\* parameters. Note that the  default sequence for writing contains *DirectFaces* operator, which converts elementary surfaces based on left-hand axes (valid in CASCADE) to right-hand axes (which are valid only in IGES). 
 
 Default values : 
-~~~~~
+~~~~{.cpp}
 write.iges.resource.name - IGES,
 write.iges.sequence - ToIGES. 
-~~~~~
+~~~~
 
 @subsubsection occt_iges_3_3_3 Performing the Open  CASCADE Technology shape translation
 
 You can perform the  translation in one or several operations. Here is how you translate topological  and geometrical objects:  
-~~~~~
+~~~~{.cpp}
 Standard_Boolean ok =  writer.AddShape (TopoDS_Shape); 
-~~~~~
+~~~~
 *ok* is True if translation was correctly performed and False if there was at least one entity that was not translated.  
-~~~~~
+~~~~{.cpp}
 Standard_Boolean ok =  writer.AddGeom (geom); 
-~~~~~
+~~~~
 where *geom* is *Handle(Geom_Curve)* or *Handle(Geom_Surface)*;  
 *ok* is True if the  translation was correctly performed and False if there was at least one entity  whose geometry was not among the allowed types. 
 
 @subsubsection occt_iges_3_3_4 Writing the IGES  file
 Write the IGES file  with:  
-~~~~~
+~~~~{.cpp}
 Standard_Boolean ok =  writer.Write ("filename.igs"); 
-~~~~~
+~~~~
 to give the file name.  
-~~~~~
+~~~~{.cpp}
 Standard_Boolean ok =  writer.Write (S); 
-~~~~~
+~~~~
 where *S* is *Standard_OStream*  
 *ok* is True if the  operation was correctly performed and False if an error occurred (for instance,  if the processor could not create the file). 
 
@@ -823,7 +823,7 @@ The highlighted classes are intended to translate geometry.
       
 @subsection occt_iges_3_7 Example
 
-~~~~~{c++}
+~~~~{.cpp}
 #include <IGESControl_Controller.hxx> 
 #include <IGESControl_Writer.hxx> 
 #include <TopoDS_Shape.hxx> 
@@ -839,7 +839,7 @@ Standard_Integer main()
   Standard_Boolean OK = ICW.Write (;MyFile.igs;); 
   //writes a model to the file MyFile.igs 
 } 
-~~~~~
+~~~~
 
 
 @section occt_iges_4 Using XSTEPDRAW
@@ -852,7 +852,7 @@ In the description of  commands, square brackets ([]) are used to indicate optio
 
 A set of parameters for  importing and exporting IGES files is defined in the XSTEP resource file. In  XSTEPDRAW, these parameters can be viewed or changed using command  
 
-~~~~
+~~~~{.php}
 Draw> param [<parameter_name> [<value>]]  
 ~~~~
 
@@ -883,15 +883,15 @@ These parameters are set  by command *param* :
 It is possible either only to load an IGES file into memory  (i.e. to fill the model with data from the file), or to read it (i.e. to load  and convert all entities to OCCT shapes).  
 
 Loading is done by the command 
-~~~~~
+~~~~{.php}
 Draw> xload <file_name>
-~~~~~
+~~~~
 Once the file is loaded, it is possible to investigate the  structure of the loaded data. To learn how to do it see @ref occt_iges_4_4 "Analyzing the  transferred".
  
 Reading of an IGES file is done by the command  
-~~~~~
+~~~~{.php}
 Draw> igesbrep <file_name> <result_shape_name> [<selection>]
-~~~~~
+~~~~
 Here a dot can be used instead of a filename if the file is  already loaded by *xload* or *igesbrep* command. In that case, only  conversion of IGES entities to OCCT shapes will be done. 
 
 Command *igesbrep* will interactively ask the user to  select a set of entities to be converted: 
@@ -912,13 +912,13 @@ The second parameter of the *igesbrep* command defines  the name of the loaded s
 
 
 Instead of *igesbrep* it is possible to use commands:
-~~~~
+~~~~{.php}
 Draw> trimport <file_name> <result_shape_name> <selection>
-~~~~~
+~~~~
 which outputs the result of translation of each selected  entity into one shape, or
-~~~~~
+~~~~{.php}
 Draw> trimpcomp <file_name> <result_shape_name> <selection>
-~~~~~
+~~~~
 which outputs the result of translation of all selected  entities into one shape (*TopoDS_Compound* for several entities). 
 
 An asterisk “*” can be specified instead of  *selection*, it means *xst-transferrable-roots*.
@@ -940,9 +940,9 @@ The procedure of analysis of the data import can be divided  into two stages:
 @subsubsection occt_iges_4_4_1 Checking file contents
 
 General statistics on the loaded data can be obtained by  using command  
-~~~~~
+~~~~{.php}
 Draw> data <symbol> 
-~~~~~
+~~~~
 The information printed by this command depends on the  symbol specified: 
 
 | Symbol | Output |
@@ -963,18 +963,18 @@ There is a set of special objects, which can be used to  operate with the loaded
 
 
 A list of these objects defined in the current session can  be printed in DRAW by command 
-~~~~~
+~~~~{.php}
 Draw> listitems 
-~~~~~
+~~~~
 In the following commands if several <i>\<selection\></i>  arguments are specified the results of each following selection are applied to the results of the previous one. 
-~~~~~
+~~~~{.php}
 Draw> givelist <selection_name> [<selection_name>]
-~~~~~
+~~~~
 prints a list of loaded entities defined by selection argument. 
 
-~~~~~
+~~~~{.php}
 Draw> givecount <selection_name> [<selection_name>]
-~~~~~
+~~~~
 prints a number of loaded entities defined by <i>selection</i> argument. 
 
 Three commands are used to calculate statistics on the entities in the model:
@@ -991,9 +991,9 @@ Optional <i>\<selection\></i> argument, if specified, defines a subset of entiti
 | iges-levels | Calculates how much entities lie in different IGES levels |
 
 The command:
-~~~~~
+~~~~{.php}
 Draw> listtypes <selection_name> ...
-~~~~~
+~~~~
 gives a list of entity types which were encountered in the  last loaded file (with a number of IGES entities of each type). The list can be  shown not for all entities but for a subset of them. This subset is defined by  an optional selection argument. 
 
 Entities in the IGES file are numbered in the succeeding  order. An entity can be identified either by its number (#) or by its label.  Label is the letter ‘D’ followed by the index of the first line with the data  for this entity in the Directory Entry section of the IGES file. The label can  be calculated on the basis of the number as ‘D(2*# -1)’. For example, entity #  6 has label D11. 
@@ -1006,9 +1006,9 @@ Entities in the IGES file are numbered in the succeeding  order. An entity can b
 @subsubsection occt_iges_4_4_2 Estimating the results of reading IGES
 All of the following commands are available only after the  data are converted into OCCT shapes (i.e. after command **igesbrep**). 
 
-~~~~~
+~~~~{.php}
 Draw> tpstat [*|?]<symbol> [<selection>]
-~~~~~
+~~~~
 provides all statistics on the last transfer,  including the list of transferred entities with mapping from IGES to OCCT  types, as well as fail and warning messages. The parameter <i>\<symbol\></i> defines  what information will be printed: 
 * G -- General statistics (list of results and messages)
 * C -- Count of all warning and fail messages
@@ -1028,13 +1028,13 @@ Optional argument <i>\<selection\></i> can limit the action of  the command with
 To get help, run this command without arguments. 
 
 For example, to get translation ratio on IGES faces, you can use. 
-~~~~~
+~~~~{.php}
 Draw:> tpstat *l iges-faces
-~~~~~
+~~~~
 The second version of the same command is TPSTAT (not  capital spelling). 
-~~~~~
+~~~~{.php}
 Draw:> TPSTAT <symbol> 
-~~~~~
+~~~~
 Symbol can be of the following values: 
 * g --  General statistics (list of results and messages)
 * c -- Count of all warning and fail messages
@@ -1045,37 +1045,37 @@ Symbol can be of the following values:
 Sometimes the trimming contours of IGES faces (i.e., entity  141 for 143, 142 for 144) can be lost during translation due to fails. 
 
 The number of lost trims and the corresponding IGES entities can be obtained by the command:
-~~~~
+~~~~{.php}
 Draw> tplosttrim [<IGES_type>] 
-~~~~~
+~~~~
 It outputs the rank and DE numbers of faces that  lost their trims and their numbers for each type (143, 144, 510) and their  total number. If a face lost several of its trims it is output only once. 
 
 Optional parameter <i>\<IGES_type\></i> can be *TrimmedSurface,  BoundedSurface* or *Face* to specify the only type of IGES faces. 
 
 For example, to get untrimmed 144 entities, use command 
-~~~~
+~~~~{.php}
 Draw> tplosttrim TrimmedSurface 
-~~~~~
+~~~~
 To get the information on OCCT shape contents, use command 
-~~~~~
+~~~~{.php}
 Draw> statshape <shape_name> 
-~~~~~
+~~~~
 It outputs the number of each kind of shapes (vertex, edge,  wire, etc.) in a shape and some geometrical data (number of C0 surfaces,  curves, indirect surfaces, etc.). 
 
 Note. The number of faces is returned as a number of  references. To obtain the number of single instances the standard command (from  TTOPOLOGY executable) **nbshapes** can be used. 
 
 To analyze the internal validity of a shape, use command  
-~~~~~
+~~~~{.php}
 Draw> checkbrep <shape_name> <expurged_shape_name>
-~~~~~
+~~~~
 It checks the geometry and topology of a shape for  different cases of inconsistency, like self-intersecting wires or wrong  orientation of trimming contours. If an error is found, it copies bad parts of  the shape with the names "expurged_subshape_name _#" and generates  an appropriate message. If possible, this command also tries to find IGES  entities the OCCT shape was produced from. 
 
 <i>\<expurged_shape_name\></i> will contain the original shape  without invalid subshapes. 
 
 To get information on tolerances of subshapes, use command 
-~~~~~
+~~~~{.php}
 Draw> tolerance <shape_name> [<min> [<max>] [<symbol>]]
-~~~~~
+~~~~
 It outputs maximum, average and minimum values of  tolerances for each kind of subshapes having tolerances or it can output  tolerances of all subshapes of the whole shape. 
 
 When specifying *min* and *max* arguments this  command outputs shapes with names <i>\<shape_name\>...</i> and their total number  with tolerances in the range <i>[min, max]</i>. 
@@ -1099,19 +1099,19 @@ Refer to @ref occt_iges_3_3_2 "Setting the translation parameters" for a descrip
 | Measurement units | XSTEP.iges.unit | 1-11 (or a string value) |
 
 Several shapes can be written in one file. To start writing  a new file, enter command 
-~~~~~
+~~~~{.php}
 Draw> newmodel 
-~~~~~
+~~~~
 This command clears the *InterfaceModel* to make it empty.
 
-~~~~~
+~~~~{.php}
 Draw> brepiges <shape_name_1> [<filename.igs>]
-~~~~~
+~~~~
 Converts the  specified shapes into IGES entities and puts them into the *InterfaceModel*.
 
-~~~~~
+~~~~{.php}
 Draw> writeall <filename.igs>
-~~~~~
+~~~~
 Allows writing the prepared model to a file with name *filename.igs*.
 
 @section occt_iges_5 Reading from and writing to IGES
@@ -1121,10 +1121,10 @@ Allows writing the prepared model to a file with name *filename.igs*.
 ### Load an IGES file
 
 Before performing any other operation, you must load an IGES  file with: 
-~~~~~
+~~~~{.cpp}
 IGESCAFControl_Reader reader(XSDRAW::Session(),  Standard_False); 
 IFSelect_ReturnStatus stat = reader.ReadFile(“filename.igs”); 
-~~~~~
+~~~~
 Loading the file only memorizes, but does not translate the  data. 
 
 ### Check the loaded IGES file
@@ -1137,64 +1137,64 @@ See the description of @ref occt_iges_2_3_3 "Setting translation parameters" abo
 
 In  addition, the following parameters can be set for XDE translation of  attributes: 
 * For transferring colors: 
-~~~~~
+~~~~{.cpp}
 reader.SetColorMode(mode); 
 // mode can be Standard_True or Standard_False 
-~~~~~
+~~~~
 * For transferring names: 
-~~~~~
+~~~~{.cpp}
 reader.SetNameMode(mode); 
 // mode can be Standard_True or Standard_False 
-~~~~~
+~~~~
 
 ### Translate an IGES file to XDE
 
 The following function performs a translation of the whole  document: 
-~~~~~
+~~~~{.cpp}
 Standard_Boolean ok = reader.Transfer(doc);  
-~~~~~
+~~~~
 where *doc* is a variable which contains a handle to the output document and should have a  type *Handle(TDocStd_Document)*. 
 
 
 @subsection occt_iges_5_2 Writing to IGES
 
 The translation from XDE to IGES can be initialized as follows: 
-~~~~~
+~~~~{.cpp}
 IGESCAFControl_Writer aWriter(XSDRAW::Session(),Standard_False); 
-~~~~~
+~~~~
 
 ### Set parameters for translation from XDE to IGES
 
 The  following parameters can be set for translation of attributes to IGES: 
 * For transferring colors: 
-~~~~~
+~~~~{.cpp}
 aWriter.SetColorMode(mode); 
 // mode can be Standard_True or Standard_False 
-~~~~~
+~~~~
 * For transferring names: 
-~~~~~
+~~~~{.cpp}
 aWriter.SetNameMode(mode); 
 // mode can be Standard_True or Standard_False 
-~~~~~
+~~~~
 
 ### Translate an XDE  document to IGES
 
 You can perform the translation of a document by calling the  function: 
-~~~~~
+~~~~{.cpp}
 IFSelect_ReturnStatus aRetSt = aWriter.Transfer(doc); 
-~~~~~
+~~~~
 where "doc" is a variable which contains a handle to the input document for transferring  and should have a type *Handle(TDocStd_Document)*.
  
 ### Write an IGES file
 
 Write an IGES file with: 
-~~~~~
+~~~~{.cpp}
 IFSelect_ReturnStatus statw =  aWriter.WriteFile("filename.igs"); 
-~~~~~
+~~~~
 or 
-~~~~~
+~~~~{.cpp}
 IFSelect_ReturnStatus statw = writer.WriteFile (S); 
-~~~~~
+~~~~
 where S is OStream.  
 
 
index 41b8abd55eae876327f5c8e88c8b080a4bdd79df..a5c2575ee640f438a0ddf2bd8e834188a65fb24b 100644 (file)
@@ -479,10 +479,10 @@ See more detailed description of the @ref occt_draw_13_1 "tinspector" command.
 
 The simple code to start Inspector with all plugins loaded:
 
-~~~~~
+~~~~
 pload INSPECTOR
 tinspector
-~~~~~
+~~~~
 
 @figure{drawexe_tinspector.png,"tinspector",360}
 
@@ -509,7 +509,7 @@ In general, the following steps should be taken:
 
 
 Here is an example of C++ implementation:
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
 
 #include <inspector/TInspector_Communicator.hxx>
 
@@ -533,7 +533,7 @@ void CreateInspector()
   }
   MyTCommunicator->SetVisible (true);
 }
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 Give one the following objects for a plugin using a container of parameters:
 
index cf818525bb9c47fc92cab0230a9f9990a1250edb..d6c41cdd6e55fb8ece75ec4bbb65e7108378cb60 100644 (file)
@@ -30,7 +30,7 @@ Learn more about SALOME platform on https://www.salome-platform.org
 
 The algorithm of shape triangulation is provided by the functionality of *BRepMesh_IncrementalMesh* class, which adds a triangulation of the shape to its topological data structure. This triangulation is used to visualize the shape in shaded mode.
 
-~~~~~
+~~~~{.cpp}
 #include <IMeshData_Status.hxx>
 #include <IMeshTools_Parameters.hxx>
 #include <BRepMesh_IncrementalMesh.hxx>
@@ -69,7 +69,7 @@ Standard_Boolean meshing_imeshtools_parameters()
   const Standard_Integer aStatus = aMesher.GetStatusFlags();
   return !aStatus;
 }
-~~~~~
+~~~~
 
 The default meshing algorithm *BRepMesh_IncrementalMesh* has two major options to define triangulation -- linear and angular deflections. 
 
@@ -194,7 +194,7 @@ OCCT comes with two base 2D meshing algorithms: *BRepMesh_MeshAlgoFactory* (used
 
 The following example demonstrates how it could be done from *Draw* environment:
 
-~~~~~
+~~~~{.php}
 psphere s 10
 
 ### Default Algo ###
@@ -202,11 +202,11 @@ incmesh s 0.0001 -algo default
 
 ### Delabella Algo ###
 incmesh s 0.0001 -algo delabella
-~~~~~
+~~~~
 
 The code snippet below shows passing a custom mesh factory to BRepMesh_IncrementalMesh:
 
-~~~~~
+~~~~{.cpp}
 IMeshTools_Parameters aMeshParams;
 Handle(IMeshTools_Context) aContext = new BRepMesh_Context();
 aContext->SetFaceDiscret (new BRepMesh_FaceDiscret (new BRepMesh_DelabellaMeshAlgoFactory()));
@@ -216,7 +216,7 @@ aMesher.SetShape (aShape);
 aMesher.ChangeParameters() = aMeshParams;
 
 aMesher.Perform (aContext);
-~~~~~
+~~~~
 
 #### Range splitter
 Range splitter tools provide functionality to generate internal surface nodes defined within the range computed using discrete model data. The base functionality is provided by *BRepMesh_DefaultRangeSplitter* which can be used without modifications in case of planar surface. The default splitter does not generate any internal node.
index 353134dc96be5dae93f4084e471eaca4b25c7a15..653025b2b5023fbc3e5279006c22a03f11c8c72b 100644 (file)
@@ -39,63 +39,63 @@ The algorithm returns a  point in the case of an intersection and a segment in t
 @subsubsection occt_modalg_2_2_1 Intersection of two curves
 
 *Geom2dAPI_InterCurveCurve* class may be instantiated for intersection of curves *C1* and *C2*.
-~~~~~
+~~~~{.cpp}
 Geom2dAPI_InterCurveCurve Intersector(C1,C2,tolerance); 
-~~~~~
+~~~~
 
 or for self-intersection of curve *C3*.
-~~~~~
+~~~~{.cpp}
 Geom2dAPI_InterCurveCurve Intersector(C3,tolerance); 
-~~~~~
+~~~~
 
-~~~~~
+~~~~{.cpp}
 Standard_Integer N = Intersector.NbPoints(); 
-~~~~~
+~~~~
 Calls the number of intersection points
 
 To select the desired intersection point, pass an integer index value in argument. 
-~~~~~
+~~~~{.cpp}
 gp_Pnt2d P = Intersector.Point(Index); 
-~~~~~
+~~~~
 
 To call the number of intersection segments, use
-~~~~~
+~~~~{.cpp}
 Standard_Integer M = Intersector.NbSegments(); 
-~~~~~
+~~~~
 
 To select the desired intersection segment pass integer index values in argument. 
-~~~~~
+~~~~{.cpp}
 Handle(Geom2d_Curve) Seg1, Seg2; 
 Intersector.Segment(Index,Seg1,Seg2); 
 // if intersection of 2 curves 
 Intersector.Segment(Index,Seg1); 
 // if self-intersection of a curve 
-~~~~~
+~~~~
 
 If you need access to a wider range of functionalities the following method will return the algorithmic  object for the calculation of intersections: 
 
-~~~~~
+~~~~{.cpp}
 Geom2dInt_GInter& TheIntersector = Intersector.Intersector(); 
-~~~~~
+~~~~
 
 @subsubsection occt_modalg_2_2_2 Intersection of Curves and Surfaces
 
 The *GeomAPI_IntCS* class  is used to compute the intersection points between a curve and a surface. 
 
 This class is  instantiated as follows: 
-~~~~~
+~~~~{.cpp}
 GeomAPI_IntCS Intersector(C, S); 
-~~~~~
+~~~~
 
 To call the number of intersection points, use:
-~~~~~
+~~~~{.cpp}
 Standard_Integer nb = Intersector.NbPoints(); 
-~~~~~
+~~~~
 
 
-~~~~~
+~~~~{.cpp}
 gp_Pnt& P = Intersector.Point(Index); 
-~~~~~
+~~~~
 
 Where *Index* is an  integer between 1 and *nb*, calls the intersection points.
 
@@ -103,19 +103,19 @@ Where *Index* is an  integer between 1 and *nb*, calls the intersection points.
 The *GeomAPI_IntSS* class  is used to compute the intersection of two surfaces from *Geom_Surface* with  respect to a given tolerance. 
 
 This class is  instantiated as follows: 
-~~~~~
+~~~~{.cpp}
 GeomAPI_IntSS Intersector(S1, S2, Tolerance); 
-~~~~~
+~~~~
 Once the *GeomAPI_IntSS* object has been created, it can be interpreted. 
 
-~~~~~
+~~~~{.cpp}
 Standard_Integer nb = Intersector. NbLines(); 
-~~~~~
+~~~~
 Calls the number of intersection curves.
 
-~~~~~
+~~~~{.cpp}
 Handle(Geom_Curve) C = Intersector.Line(Index) 
-~~~~~
+~~~~
 Where *Index* is an  integer between 1 and *nb*, calls the intersection curves.
 
 
@@ -135,7 +135,7 @@ The validity of the function built is never checked: the Law package does not kn
 @subsubsection occt_modalg_2_3_1 Geom2dAPI_Interpolate
 This class is used to  interpolate a BSplineCurve passing through an array of points. If tangency is  not requested at the point of interpolation, continuity will be *C2*. If  tangency is requested at the point, continuity will be *C1*. If  Periodicity is requested, the curve will be closed and the junction will be the  first point given. The curve will then have a continuity of *C1* only. 
 This class may be  instantiated as follows: 
-~~~~~
+~~~~{.cpp}
 Geom2dAPI_Interpolate 
 (const  Handle_TColgp_HArray1OfPnt2d& Points, 
 const  Standard_Boolean PeriodicFlag, 
@@ -143,27 +143,27 @@ const Standard_Real  Tolerance);
 
 Geom2dAPI_Interpolate Interp(Points, Standard_False, 
                                     Precision::Confusion()); 
-~~~~~
+~~~~
 
 
 It is possible to call the BSpline curve from the object defined  above it. 
-~~~~~
+~~~~{.cpp}
 Handle(Geom2d_BSplineCurve) C = Interp.Curve(); 
-~~~~~
+~~~~
 
 Note that the *Handle(Geom2d_BSplineCurve)* operator has been redefined by the method *Curve()*. Consequently, it is  unnecessary to pass via the construction of an intermediate object of the *Geom2dAPI_Interpolate* type and the following syntax is correct. 
 
-~~~~~
+~~~~{.cpp}
 Handle(Geom2d_BSplineCurve) C = 
 Geom2dAPI_Interpolate(Points, 
     Standard_False, 
     Precision::Confusion()); 
-~~~~~
+~~~~
 
 @subsubsection occt_modalg_2_3_2 GeomAPI_Interpolate
 
 This class may be  instantiated as follows: 
-~~~~~
+~~~~{.cpp}
 GeomAPI_Interpolate 
 (const  Handle_TColgp_HArray1OfPnt& Points, 
 const  Standard_Boolean PeriodicFlag, 
@@ -171,12 +171,12 @@ const Standard_Real  Tolerance);
 
 GeomAPI_Interpolate Interp(Points, Standard_False, 
                                     Precision::Confusion()); 
-~~~~~
+~~~~
 
 It is possible to call the BSpline curve from the object defined  above it. 
-~~~~~
+~~~~{.cpp}
 Handle(Geom_BSplineCurve) C = Interp.Curve(); 
-~~~~~
+~~~~
 Note that the *Handle(Geom_BSplineCurve)* operator has been redefined by the method *Curve()*. Thus, it is unnecessary  to pass via the construction of an intermediate object of the *GeomAPI_Interpolate*  type and the following syntax is correct. 
 
 Handle(Geom_BSplineCurve) C = 
@@ -185,11 +185,11 @@ Handle(Geom_BSplineCurve) C =
                                                1.0e-7); 
 
 Boundary conditions may  be imposed with the method Load. 
-~~~~~
+~~~~{.cpp}
 GeomAPI_Interpolate AnInterpolator 
 (Points, Standard_False, 1.0e-5); 
 AnInterpolator.Load (StartingTangent, EndingTangent); 
-~~~~~
+~~~~
 
 @subsection occt_modalg_2_4 Lines and  Circles from Constraints
 
@@ -234,11 +234,11 @@ line by geometric constraints. Four qualifiers are used:
   * **Unqualified** -- the relative position is not qualified, i.e. all solutions apply.
     
 It is possible to create expressions using the qualifiers,  for example:
-~~~~~
+~~~~{.cpp}
 GccAna_Circ2d2TanRad 
        Solver(GccEnt::Outside(C1), 
                GccEnt::Enclosing(C2),  Rad, Tolerance); 
-~~~~~
+~~~~
 
 This expression finds all circles  of radius *Rad*, which are tangent to both circle *C1* and *C2*, while *C1* is outside and *C2* is inside.
   
@@ -290,14 +290,14 @@ Constraints:
 Tangent and Exterior to  C1. 
 Tangent and Exterior to  C2. 
 
-Syntax: 
+Syntax:
 
-~~~~~
+~~~~{.cpp}
 GccAna_Lin2d2Tan 
        Solver(GccEnt::Outside(C1), 
                GccEnt::Outside(C2), 
                Tolerance); 
-~~~~~
+~~~~
 
 **Example 1 Case 2** 
 
@@ -307,14 +307,14 @@ Constraints:
 Tangent and Including  C1. 
 Tangent and Including  C2. 
 
-Syntax: 
+Syntax:
 
-~~~~~
+~~~~{.cpp}
 GccAna_Lin2d2Tan 
        Solver(GccEnt::Enclosing(C1), 
                GccEnt::Enclosing(C2), 
                Tolerance); 
-~~~~~
+~~~~
 
 **Example  1 Case 3**
  
@@ -324,13 +324,13 @@ Constraints:
 Tangent and Including C1. 
 Tangent and Exterior to C2. 
 
-Syntax: 
-~~~~~
+Syntax:
+~~~~{.cpp}
 GccAna_Lin2d2Tan 
        Solver(GccEnt::Enclosing(C1), 
                GccEnt::Outside(C2), 
                Tolerance); 
-~~~~~
+~~~~
 
 **Example 1 Case 4** 
 
@@ -339,13 +339,13 @@ Constraints:
 Tangent and Exterior to  C1. 
 Tangent and Including  C2. 
 
-Syntax: 
-~~~~~
+Syntax:
+~~~~{.cpp}
 GccAna_Lin2d2Tan 
        Solver(GccEnt::Outside(C1), 
                GccEnt::Enclosing(C2), 
                Tolerance); 
-~~~~~
+~~~~
 
 **Example 1 Case 5** 
 
@@ -355,13 +355,13 @@ Constraints:
 Tangent and Undefined  with respect to C1. 
 Tangent and Undefined  with respect to C2. 
 
-Syntax: 
-~~~~~
+Syntax:
+~~~~{.cpp}
 GccAna_Lin2d2Tan 
        Solver(GccEnt::Unqualified(C1), 
                GccEnt::Unqualified(C2), 
                Tolerance); 
-~~~~~
+~~~~
 
 #### Circle of given radius tangent to two circles
 The following four  diagrams show the four cases in using qualifiers in the creation of a circle. 
@@ -373,12 +373,12 @@ Constraints:
 Tangent and Exterior to  C1. 
 Tangent and Exterior to  C2. 
 
-Syntax: 
-~~~~~
+Syntax:
+~~~~{.cpp}
 GccAna_Circ2d2TanRad 
        Solver(GccEnt::Outside(C1), 
        GccEnt::Outside(C2),  Rad, Tolerance); 
-~~~~~
+~~~~
 
 **Example 2 Case 2** 
 
@@ -388,12 +388,12 @@ Constraints:
 Tangent and Exterior to  C1. 
 Tangent and Included by  C2. 
 
-Syntax: 
-~~~~~
+Syntax:
+~~~~{.cpp}
 GccAna_Circ2d2TanRad 
        Solver(GccEnt::Outside(C1), 
                GccEnt::Enclosed(C2),  Rad, Tolerance); 
-~~~~~
+~~~~
 
 **Example  2 Case 3**
 @figure{/user_guides/modeling_algos/images/modeling_algos_image016.png,"Solutions enclose C2",220}
@@ -402,12 +402,12 @@ Constraints:
 Tangent and Exterior to  C1. 
 Tangent and Including  C2. 
 
-Syntax: 
-~~~~~
+Syntax:
+~~~~{.cpp}
 GccAna_Circ2d2TanRad 
        Solver(GccEnt::Outside(C1), 
                GccEnt::Enclosing(C2),  Rad, Tolerance); 
-~~~~~
+~~~~
                
 **Example 2 Case 4**
 @figure{/user_guides/modeling_algos/images/modeling_algos_image017.png,"Solutions enclose C1",220}
@@ -416,22 +416,22 @@ Constraints:
 Tangent and Enclosing  C1. 
 Tangent and Enclosing  C2. 
 
-Syntax: 
-~~~~~
+Syntax:
+~~~~{.cpp}
 GccAna_Circ2d2TanRad 
        Solver(GccEnt::Enclosing(C1), 
                GccEnt::Enclosing(C2),  Rad, Tolerance); 
-~~~~~
+~~~~
 
 **Example 2 Case 5**
 
 The following syntax  will give all the circles of radius *Rad*, which are tangent to *C1* and *C2* without discrimination of relative position: 
 
-~~~~~
+~~~~{.cpp}
 GccAna_Circ2d2TanRad  Solver(GccEnt::Unqualified(C1), 
                                                        GccEnt::Unqualified(C2), 
                                                        Rad,Tolerance); 
-~~~~~                                                  
+~~~~                                                   
 
 
 @subsubsection occt_modalg_2_4_3 Types of  algorithms
@@ -518,9 +518,9 @@ The function *Curve* returns  the result as a 2D BSpline curve.
 
 If you want to give a  specific length to a batten curve, use: 
 
-~~~~~
+~~~~{.cpp}
 b.SetSlidingFactor(L / b.SlidingOfReference()) 
-~~~~~
+~~~~
 where *b* is the name of  the batten curve object 
 
 Free sliding is  generally more aesthetically pleasing than constrained sliding. However, the computation  can fail with values such as angles greater than *p/2* because in this case the length is theoretically infinite. 
@@ -620,7 +620,7 @@ The class *MakeApprox* allows converting a *GeomPlate* surface into a *Geom_BSpl
 
 Let us create a Plate surface  and approximate it from a polyline as a curve constraint and a point constraint 
 
-~~~~~
+~~~~{.cpp}
 Standard_Integer NbCurFront=4, 
 NbPointConstraint=1; 
 gp_Pnt P1(0.,0.,0.); 
@@ -670,7 +670,7 @@ Surface
 Standard_Real Umin, Umax, Vmin, Vmax; 
 PSurf->Bounds( Umin, Umax, Vmin, Vmax); 
 BRepBuilderAPI_MakeFace MF(Surf,Umin, Umax, Vmin, Vmax); 
-~~~~~
+~~~~
 
 @subsection occt_modalg_2_6 Projections
 
@@ -691,74 +691,74 @@ The  curve does not have to be a *Geom2d_TrimmedCurve*. The algorithm will funct
 
 The class *Geom2dAPI_ProjectPointOnCurve* may be instantiated as in the following example: 
 
-~~~~~
+~~~~{.cpp}
 gp_Pnt2d P; 
 Handle(Geom2d_BezierCurve) C = 
        new  Geom2d_BezierCurve(args); 
 Geom2dAPI_ProjectPointOnCurve Projector (P, C); 
-~~~~~
+~~~~
 
 To restrict the search  for normals to a given domain <i>[U1,U2]</i>, use the following constructor: 
-~~~~~
+~~~~{.cpp}
 Geom2dAPI_ProjectPointOnCurve Projector (P, C, U1, U2); 
-~~~~~
+~~~~
 Having thus created the *Geom2dAPI_ProjectPointOnCurve* object, we can now interrogate it. 
 
 #### Calling the number of solution points
 
-~~~~~
+~~~~{.cpp}
 Standard_Integer NumSolutions = Projector.NbPoints(); 
-~~~~~
+~~~~
 
 #### Calling the location of a solution point
 
 The solutions are  indexed in a range from *1* to *Projector.NbPoints()*. The point,  which corresponds to a given *Index* may be found: 
-~~~~~
+~~~~{.cpp}
 gp_Pnt2d Pn = Projector.Point(Index); 
-~~~~~
+~~~~
 
 #### Calling the parameter of a solution point
 
 For a given point  corresponding to a given *Index*: 
 
-~~~~~
+~~~~{.cpp}
 Standard_Real U = Projector.Parameter(Index); 
-~~~~~
+~~~~
 
 This can also be  programmed as: 
 
-~~~~~
+~~~~{.cpp}
 Standard_Real U; 
 Projector.Parameter(Index,U); 
-~~~~~
+~~~~
 
 #### Calling the distance between the start and end points
 
 We can find the distance  between the initial point and a point, which corresponds to the given *Index*: 
 
-~~~~~
+~~~~{.cpp}
 Standard_Real D = Projector.Distance(Index); 
-~~~~~
+~~~~
 
 #### Calling the nearest solution point
 
 
 This class offers a  method to return the closest solution point to the starting point. This  solution is accessed as follows: 
-~~~~~
+~~~~{.cpp}
 gp_Pnt2d P1 = Projector.NearestPoint(); 
-~~~~~
+~~~~
 
 #### Calling the parameter of the nearest solution point
 
-~~~~~
+~~~~{.cpp}
 Standard_Real U = Projector.LowerDistanceParameter(); 
-~~~~~
+~~~~
 
 #### Calling the minimum distance from the point to the curve
 
-~~~~~
+~~~~{.cpp}
 Standard_Real D = Projector.LowerDistance(); 
-~~~~~
+~~~~
 
 #### Redefined operators
 
@@ -766,32 +766,32 @@ Some operators have been  redefined to find the closest solution.
 
 *Standard_Real()* returns  the minimum distance from the point to the curve. 
 
-~~~~~
+~~~~{.cpp}
 Standard_Real D = Geom2dAPI_ProjectPointOnCurve (P,C); 
-~~~~~
+~~~~
 
 *Standard_Integer()* returns the number of solutions. 
 
-~~~~~
+~~~~{.cpp}
 Standard_Integer N = 
 Geom2dAPI_ProjectPointOnCurve (P,C); 
-~~~~~
+~~~~
 
 *gp_Pnt2d()* returns the  nearest solution point. 
 
-~~~~~
+~~~~{.cpp}
 gp_Pnt2d P1 = Geom2dAPI_ProjectPointOnCurve (P,C); 
-~~~~~
+~~~~
 
 Using these operators  makes coding easier when you only need the nearest point. Thus: 
-~~~~~
+~~~~{.cpp}
 Geom2dAPI_ProjectPointOnCurve Projector (P, C); 
 gp_Pnt2d P1 = Projector.NearestPoint(); 
-~~~~~
+~~~~
 can be written more  concisely as: 
-~~~~~
+~~~~{.cpp}
 gp_Pnt2d P1 = Geom2dAPI_ProjectPointOnCurve (P,C); 
-~~~~~
+~~~~
 However, note that in  this second case no intermediate *Geom2dAPI_ProjectPointOnCurve* object is created, and thus it  is impossible to have access to other solution points. 
 
 
@@ -799,80 +799,80 @@ However, note that in  this second case no intermediate *Geom2dAPI_ProjectPointO
 
 If you want to use the  wider range of functionalities available from the *Extrema* package, a call to  the *Extrema()* method will return the algorithmic object for calculating  extrema. For example: 
 
-~~~~~
+~~~~{.cpp}
 Extrema_ExtPC2d& TheExtrema = Projector.Extrema(); 
-~~~~~
+~~~~
 
 @subsubsection occt_modalg_2_6_2 Projection of a 3D Point on a Curve
 
 The class *GeomAPI_ProjectPointOnCurve* is  instantiated as in the following example: 
 
-~~~~~
+~~~~{.cpp}
 gp_Pnt P; 
 Handle(Geom_BezierCurve) C = 
        new  Geom_BezierCurve(args); 
 GeomAPI_ProjectPointOnCurve Projector (P, C); 
-~~~~~
+~~~~
 
 If you wish to restrict  the search for normals to the given domain [U1,U2], use the following  constructor: 
 
-~~~~~
+~~~~{.cpp}
 GeomAPI_ProjectPointOnCurve Projector (P, C, U1, U2); 
-~~~~~
+~~~~
 Having thus created the  *GeomAPI_ProjectPointOnCurve* object, you can now interrogate it. 
 
 #### Calling the number of solution points
 
-~~~~~
+~~~~{.cpp}
 Standard_Integer NumSolutions = Projector.NbPoints(); 
-~~~~~
+~~~~
 
 #### Calling the location of a solution point
 
 The solutions are  indexed in a range from 1 to *Projector.NbPoints()*. The point, which corresponds  to a given index, may be found: 
-~~~~~
+~~~~{.cpp}
 gp_Pnt Pn = Projector.Point(Index); 
-~~~~~
+~~~~
 
 #### Calling the parameter of a solution point
 
 For a given point  corresponding to a given index: 
 
-~~~~~
+~~~~{.cpp}
 Standard_Real U = Projector.Parameter(Index); 
-~~~~~
+~~~~
 
 This can also be  programmed as: 
-~~~~~
+~~~~{.cpp}
 Standard_Real U; 
 Projector.Parameter(Index,U); 
-~~~~~
+~~~~
 
 #### Calling the distance between the start and end point
 
 The distance between the  initial point and a point, which corresponds to a given index, may be found: 
-~~~~~
+~~~~{.cpp}
 Standard_Real D = Projector.Distance(Index); 
-~~~~~
+~~~~
 
 #### Calling the nearest solution point
 
 This class offers a  method to return the closest solution point to the starting point. This  solution is accessed as follows: 
-~~~~~
+~~~~{.cpp}
 gp_Pnt P1 = Projector.NearestPoint(); 
-~~~~~
+~~~~
 
 #### Calling the parameter of the nearest solution point
 
-~~~~~
+~~~~{.cpp}
 Standard_Real U = Projector.LowerDistanceParameter(); 
-~~~~~
+~~~~
 
 #### Calling the minimum distance from the point to the curve
 
-~~~~~
+~~~~{.cpp}
 Standard_Real D =  Projector.LowerDistance(); 
-~~~~~
+~~~~
 
 #### Redefined  operators 
 
@@ -880,40 +880,40 @@ Some operators have been  redefined to find the nearest solution.
 
 *Standard_Real()* returns  the minimum distance from the point to the curve. 
 
-~~~~~
+~~~~{.cpp}
 Standard_Real D = GeomAPI_ProjectPointOnCurve (P,C); 
-~~~~~
+~~~~
 
 *Standard_Integer()* returns  the number of solutions. 
-~~~~~
+~~~~{.cpp}
 Standard_Integer N =  GeomAPI_ProjectPointOnCurve (P,C); 
-~~~~~
+~~~~
 
 *gp_Pnt2d()* returns the  nearest solution point. 
 
-~~~~~
+~~~~{.cpp}
 gp_Pnt P1 = GeomAPI_ProjectPointOnCurve (P,C); 
-~~~~~
+~~~~
 Using these operators  makes coding easier when you only need the nearest point. In this way, 
 
-~~~~~
+~~~~{.cpp}
 GeomAPI_ProjectPointOnCurve Projector (P, C); 
 gp_Pnt P1 = Projector.NearestPoint(); 
-~~~~~
+~~~~
 
 can be written more  concisely as: 
-~~~~~
+~~~~{.cpp}
 gp_Pnt P1 = GeomAPI_ProjectPointOnCurve (P,C); 
-~~~~~
+~~~~
 In the second case,  however, no intermediate *GeomAPI_ProjectPointOnCurve* object is created, and it  is impossible to access other solutions points. 
 
 #### Access to lower-level functionalities
 
 If you want to use the  wider range of functionalities available from the *Extrema* package, a call to  the *Extrema()* method will return the algorithmic object for calculating the  extrema. For example: 
 
-~~~~~
+~~~~{.cpp}
 Extrema_ExtPC& TheExtrema = Projector.Extrema(); 
-~~~~~
+~~~~
 
 @subsubsection occt_modalg_2_6_3 Projection of a Point on a Surface
 
@@ -925,71 +925,71 @@ Note that the  surface does not have to be of *Geom_RectangularTrimmedSurface* t
 The algorithm  will function with any class inheriting *Geom_Surface*.
 
 *GeomAPI_ProjectPointOnSurf* is instantiated as in the following  example: 
-~~~~~
+~~~~{.cpp}
 gp_Pnt P; 
 Handle (Geom_Surface) S = new Geom_BezierSurface(args); 
 GeomAPI_ProjectPointOnSurf Proj (P, S); 
-~~~~~
+~~~~
 
 To restrict the search  for normals within the given rectangular domain [U1, U2, V1, V2], use the  constructor <i>GeomAPI_ProjectPointOnSurf Proj (P, S, U1, U2, V1, V2)</i>
 
 The values of *U1, U2, V1*  and *V2* lie at or within their maximum and minimum limits, i.e.: 
-~~~~~
+~~~~{.cpp}
 Umin <=  U1 < U2 <= Umax 
 Vmin <=  V1 < V2 <= Vmax 
-~~~~~
+~~~~
 Having thus created the  *GeomAPI_ProjectPointOnSurf* object, you can interrogate it. 
 
 #### Calling the number of solution points
 
-~~~~~
+~~~~{.cpp}
 Standard_Integer NumSolutions = Proj.NbPoints(); 
-~~~~~
+~~~~
 
 #### Calling the location of a solution point
 
 The solutions are  indexed in a range from 1 to *Proj.NbPoints()*. The point corresponding to the  given index may be found: 
 
-~~~~~
+~~~~{.cpp}
 gp_Pnt Pn = Proj.Point(Index); 
-~~~~~
+~~~~
 
 #### Calling the parameters of a solution point
 
 For a given point  corresponding to the given index: 
 
-~~~~~
+~~~~{.cpp}
 Standard_Real U,V; 
 Proj.Parameters(Index, U, V); 
-~~~~~
+~~~~
 
 #### Calling the distance between the start and end point
 
 
 The distance between the  initial point and a point corresponding to the given index may be found: 
-~~~~~
+~~~~{.cpp}
 Standard_Real D = Projector.Distance(Index); 
-~~~~~
+~~~~
 
 #### Calling the nearest solution point
 
 This class offers a  method, which returns the closest solution point to the starting point. This  solution is accessed as follows: 
-~~~~~
+~~~~{.cpp}
 gp_Pnt P1 = Proj.NearestPoint(); 
-~~~~~
+~~~~
 
 #### Calling the parameters of the nearest solution point
 
-~~~~~
+~~~~{.cpp}
 Standard_Real U,V; 
 Proj.LowerDistanceParameters (U, V); 
-~~~~~
+~~~~
 
 #### Calling the minimum distance from a point to the surface
 
-~~~~~
+~~~~{.cpp}
 Standard_Real D = Proj.LowerDistance(); 
-~~~~~
+~~~~
 
 #### Redefined operators
 
@@ -997,34 +997,34 @@ Some operators have been  redefined to help you find the nearest solution.
 
 *Standard_Real()* returns  the minimum distance from the point to the surface. 
 
-~~~~~
+~~~~{.cpp}
 Standard_Real D = GeomAPI_ProjectPointOnSurf (P,S); 
-~~~~~
+~~~~
 
 *Standard_Integer()* returns  the number of solutions. 
 
-~~~~~
+~~~~{.cpp}
 Standard_Integer N = GeomAPI_ProjectPointOnSurf (P,S); 
-~~~~~
+~~~~
 
 *gp_Pnt2d()* returns the  nearest solution point. 
 
-~~~~~
+~~~~{.cpp}
 gp_Pnt P1 = GeomAPI_ProjectPointOnSurf (P,S); 
-~~~~~
+~~~~
 
 Using these operators  makes coding easier when you only need the nearest point. In this way, 
 
-~~~~~
+~~~~{.cpp}
 GeomAPI_ProjectPointOnSurface Proj (P, S); 
 gp_Pnt P1 = Proj.NearestPoint(); 
-~~~~~
+~~~~
 
 can be written more concisely as: 
 
-~~~~~
+~~~~{.cpp}
 gp_Pnt P1 = GeomAPI_ProjectPointOnSurface (P,S); 
-~~~~~
+~~~~
 
 In the second case,  however, no intermediate *GeomAPI_ProjectPointOnSurf* object is created,  and it is impossible to access other solution points. 
 
@@ -1032,9 +1032,9 @@ In the second case,  however, no intermediate *GeomAPI_ProjectPointOnSurf* objec
 
 If you want to use the  wider range of functionalities available from the *Extrema* package, a call to  the *Extrema()* method will return the algorithmic object for calculating the  extrema as follows: 
 
-~~~~~
+~~~~{.cpp}
 Extrema_ExtPS& TheExtrema = Proj.Extrema(); 
-~~~~~
+~~~~
 
 @subsubsection occt_modalg_2_12_8 Switching from 2d and 3d Curves
 
@@ -1044,10 +1044,10 @@ The *To2d* and *To3d* methods are used to;
   * build a 3d curve from a  *Geom2d_Curve* and a *gp_Pln* plane.
 
 These methods are called  as follows: 
-~~~~~
+~~~~{.cpp}
 Handle(Geom2d_Curve) C2d = GeomAPI::To2d(C3d, Pln); 
 Handle(Geom_Curve) C3d = GeomAPI::To3d(C2d, Pln); 
-~~~~~
+~~~~
 
 
 @section occt_modalg_3 Standard  Topological Objects
@@ -1068,10 +1068,10 @@ There are two root classes for their construction and modification:
 @subsection occt_modalg_3_1 Vertex
 
 *BRepBuilderAPI_MakeVertex*  creates a new vertex from a 3D point from gp. 
-~~~~~
+~~~~{.cpp}
 gp_Pnt P(0,0,10); 
 TopoDS_Vertex V = BRepBuilderAPI_MakeVertex(P); 
-~~~~~
+~~~~
 
 This class always creates a new vertex and has no other methods.
 
@@ -1081,12 +1081,12 @@ This class always creates a new vertex and has no other methods.
 
 Use *BRepBuilderAPI_MakeEdge* to create from a curve and vertices. The basic method constructs an edge from a curve, two vertices, and two parameters. 
 
-~~~~~
+~~~~{.cpp}
 Handle(Geom_Curve) C = ...; // a curve 
 TopoDS_Vertex V1 = ...,V2 = ...;// two Vertices 
 Standard_Real p1 = ..., p2 = ..;// two parameters 
 TopoDS_Edge E = BRepBuilderAPI_MakeEdge(C,V1,V2,p1,p2); 
-~~~~~
+~~~~
 
 where C is the domain of the edge; V1 is the first vertex oriented FORWARD; V2 is the second vertex oriented REVERSED; p1  and p2 are the parameters for the vertices V1 and V2 on the curve. The default  tolerance is associated with this edge. 
 
@@ -1105,9 +1105,9 @@ The following rules  apply to the arguments:
 **The parameters**
   * Must be increasing and in the  range of the curve, i.e.:
 
-~~~~~
+~~~~{.cpp}
   C->FirstParameter() <=  p1 < p2 <= C->LastParameter() 
-~~~~~  
+~~~~
   
   * If the parameters are  decreasing, the Vertices are switched, i.e. V2 becomes V1 and V1 becomes V2.
   * On a periodic curve the  parameters p1 and p2 are adjusted by adding or subtracting the period to obtain  p1 in the range of the curve and p2 in the range p1 < p2 <= p1+ Period.  So on a parametric curve p2 can be greater than the second parameter,  see the figure below.
@@ -1131,7 +1131,7 @@ There exist supplementary edge construction methods derived from the basic one.
 
 The five following  methods are thus derived from the basic construction: 
 
-~~~~~
+~~~~{.cpp}
 Handle(Geom_Curve) C = ...; // a curve 
 TopoDS_Vertex V1 = ...,V2 = ...;// two Vertices 
 Standard_Real p1 = ..., p2 = ..;// two parameters 
@@ -1147,7 +1147,7 @@ E = BRepBuilderAPI_MakeEdge(C,P1,P2);
 E = BRepBuilderAPI_MakeEdge(C,p1,p2); 
 // Make an edge from the whole curve 
 E = BRepBuilderAPI_MakeEdge(C); 
-~~~~~
+~~~~
 
 
 Six methods (the five above and the basic method) are also provided for curves from the gp package in  place of Curve from Geom. The methods create the corresponding Curve from Geom  and are implemented for the following classes: 
@@ -1160,7 +1160,7 @@ Six methods (the five above and the basic method) are also provided for curves f
 
 There are also two  methods to construct edges from two vertices or two points. These methods  assume that the curve is a line; the vertices or points must have different  locations. 
 
-~~~~~
+~~~~{.cpp}
 
 TopoDS_Vertex V1 = ...,V2 = ...;// two Vertices 
 gp_Pnt P1 = ..., P2 = ...;// two points 
@@ -1171,7 +1171,7 @@ E = BRepBuilderAPI_MakeEdge(V1,V2);
 
 // linear edge from two points 
 E = BRepBuilderAPI_MakeEdge(P1,P2); 
-~~~~~
+~~~~
 
 @subsubsection occt_modalg_3_2_3 Other information and error status
 
@@ -1193,7 +1193,7 @@ The following example  creates a rectangle centered on the origin of dimensions
 
 @figure{/user_guides/modeling_algos/images/modeling_algos_image024.png,"Creating a Wire",360}
 
-~~~~~
+~~~~{.cpp}
 #include <BRepBuilderAPI_MakeEdge.hxx> 
 #include <TopoDS_Shape.hxx> 
 #include <gp_Circ.hxx> 
@@ -1257,7 +1257,7 @@ MW.Add(TopoDS::Edge(theEdges(i)));
 } 
 return MW.Wire(); 
 } 
-~~~~~
+~~~~
 
 @subsection occt_modalg_3_3 Edge 2D
 
@@ -1271,7 +1271,7 @@ Use *BRepBuilderAPI_MakeEdge2d* class to make  edges on a working plane from 2d
 
 The basic usage of  *BRepBuilderAPI_MakePolygon* is to create a wire by adding vertices or points  using the Add method. At any moment, the current wire can be extracted. The  close method can be used to close the current wire. In the following example, a  closed wire is created from an array of points. 
 
-~~~~~
+~~~~{.cpp}
 #include <TopoDS_Wire.hxx> 
 #include <BRepBuilderAPI_MakePolygon.hxx> 
 #include <TColgp_Array1OfPnt.hxx> 
@@ -1286,21 +1286,21 @@ MP.Add(Points(i));
 MP.Close(); 
 return MP; 
 } 
-~~~~~
+~~~~
 
 Short-cuts are provided  for 2, 3, or 4 points or vertices. Those methods have a Boolean last argument  to tell if the polygon is closed. The default value is False. 
 
 Two examples: 
 
 Example of a closed  triangle from three vertices:
-~~~~
+~~~~{.cpp}
 TopoDS_Wire W =  BRepBuilderAPI_MakePolygon(V1,V2,V3,Standard_True); 
-~~~~~
+~~~~
 
 Example of an open  polygon from four points:
-~~~~~
+~~~~{.cpp}
 TopoDS_Wire W = BRepBuilderAPI_MakePolygon(P1,P2,P3,P4); 
-~~~~~
+~~~~
 
 *BRepBuilderAPI_MakePolygon* class maintains a current wire. The current wire can  be extracted at any moment and the construction can proceed to a longer wire.  After each point insertion, the class maintains the last created edge and  vertex, which are returned by the methods *Edge, FirstVertex* and *LastVertex*. 
 
@@ -1314,20 +1314,20 @@ Use *BRepBuilderAPI_MakeFace* class to create a face from a surface and wires. A
 
 A face can be  constructed from a surface and four parameters to determine a limitation of the  UV space. The parameters are optional, if they are omitted the natural bounds  of the surface are used. Up to four edges and vertices are created with a wire.  No edge is created when the parameter is infinite. 
 
-~~~~~
+~~~~{.cpp}
 Handle(Geom_Surface) S = ...; // a surface 
 Standard_Real umin,umax,vmin,vmax; // parameters 
 TopoDS_Face F =  BRepBuilderAPI_MakeFace(S,umin,umax,vmin,vmax); 
-~~~~~
+~~~~
 
 @figure{/user_guides/modeling_algos/images/modeling_algos_image025.png,"Basic Face Construction",360}
 
 To make a face from the  natural boundary of a surface, the parameters are not required: 
 
-~~~~~
+~~~~{.cpp}
 Handle(Geom_Surface) S = ...; // a surface 
 TopoDS_Face F = BRepBuilderAPI_MakeFace(S); 
-~~~~~
+~~~~
 
 Constraints on the  parameters are similar to the constraints in *BRepBuilderAPI_MakeEdge*. 
   * *umin,umax (vmin,vmax)* must be  in the range of the surface and must be increasing.
@@ -1348,27 +1348,27 @@ The two basic  constructions (from a surface and from a surface and parameters)
 
 Once a face has been  created, a wire can be added using the *Add* method. For example, the following  code creates a cylindrical surface and adds a wire. 
 
-~~~~~
+~~~~{.cpp}
 gp_Cylinder C = ..; // a cylinder 
 TopoDS_Wire W = ...;// a wire 
 BRepBuilderAPI_MakeFace MF(C); 
 MF.Add(W); 
 TopoDS_Face F = MF; 
-~~~~~
+~~~~
 
 More than one wire can  be added to a face, provided that they do not cross each other and they define  only one area on the surface. (Note that this is not checked).  
 
 For one wire, a simple  syntax is provided to construct the face from the surface and the wire. The  above lines could be written: 
 
-~~~~~
+~~~~{.cpp}
 TopoDS_Face F = BRepBuilderAPI_MakeFace(C,W); 
-~~~~~
+~~~~
 
 The edges on a face must have a parametric curve description. If there is no parametric curve for an edge of the wire on the face it is computed by projection, moreover, the calculation is possible only for the planar face.
 
 A planar face can be  created from only a wire, provided this wire defines a plane. For example, to  create a planar face from a set of points you can use *BRepBuilderAPI_MakePolygon* and *BRepBuilderAPI_MakeFace*.
 
-~~~~~
+~~~~{.cpp}
 #include <TopoDS_Face.hxx> 
 #include <TColgp_Array1OfPnt.hxx> 
 #include <BRepBuilderAPI_MakePolygon.hxx> 
@@ -1386,15 +1386,15 @@ MP.Close();
 TopoDS_Face F = BRepBuilderAPI_MakeFace(MP.Wire()); 
 return F; 
 } 
-~~~~~
+~~~~
 
 The last use of *MakeFace* is to copy an existing face to  add new wires. For example, the following code adds a new wire to a face: 
 
-~~~~~
+~~~~{.cpp}
 TopoDS_Face F = ...; // a face 
 TopoDS_Wire W = ...; // a wire 
 F = BRepBuilderAPI_MakeFace(F,W); 
-~~~~~
+~~~~
 
 To add more than one  wire an instance of the *BRepBuilderAPI_MakeFace* class can be created with the face and the first wire and the new wires inserted with the *Add* method. 
 
@@ -1413,24 +1413,24 @@ The wire is a composite shape built not from a geometry, but by the assembly of
 
 Up to four edges can be used directly, for example: 
 
-~~~~~
+~~~~{.cpp}
 TopoDS_Wire W = BRepBuilderAPI_MakeWire(E1,E2,E3,E4); 
-~~~~~
+~~~~
 
 For a higher or unknown  number of edges the Add method must be used; for example, to build a wire from  an array of shapes (to be edges). 
 
-~~~~~
+~~~~{.cpp}
 TopTools_Array1OfShapes theEdges; 
 BRepBuilderAPI_MakeWire MW; 
 for (Standard_Integer i = theEdge.Lower(); 
 i <= theEdges.Upper(); i++) 
 MW.Add(TopoDS::Edge(theEdges(i)); 
 TopoDS_Wire W = MW; 
-~~~~~
+~~~~
 
 The class can be  constructed with a wire. A wire can also be added. In this case, all the edges  of the wires are added. For example to merge two wires: 
 
-~~~~~
+~~~~{.cpp}
 #include <TopoDS_Wire.hxx> 
 #include <BRepBuilderAPI_MakeWire.hxx> 
 
@@ -1441,7 +1441,7 @@ BRepBuilderAPI_MakeWire MW(W1);
 MW.Add(W2); 
 return MW; 
 } 
-~~~~~
+~~~~
 
 *BRepBuilderAPI_MakeWire* class connects the edges to the wire. When a new edge  is added if one of its vertices is shared with the wire it is considered as  connected to the wire. If there is no shared vertex, the algorithm searches for  a vertex of the edge and a vertex of the wire, which are at the same location (the  tolerances of the vertices are used to test if they have the same location). If  such a pair of vertices is found, the edge is copied with the vertex of the  wire in place of the original vertex. All the vertices of the edge can be  exchanged for vertices from the wire. If no connection is found the wire is  considered to be disconnected. This is an error. 
 
@@ -1495,9 +1495,9 @@ The class *BRepPrimAPI_MakeBox* allows building a parallelepiped box. The result
 * From a system of axes *gp_Ax2* and three dimensions. Same as the first way but the box is parallel to the given system of axes. 
 
 An error is raised if  the box is flat in any dimension using the default precision. The following  code shows how to create a box: 
-~~~~~
+~~~~{.cpp}
 TopoDS_Solid theBox = BRepPrimAPI_MakeBox(10.,20.,30.); 
-~~~~~
+~~~~
 
 The four methods to build a box are shown in the figure: 
 
@@ -1534,7 +1534,7 @@ The result of the  OneAxis construction is a Solid, a Shell, or a Face. The face
 
 The following code  builds the cylindrical face of the figure, which is a quarter of cylinder along  the *Y* axis with the origin at *X,Y,Z* the length of *DY* and radius *R*. 
 
-~~~~~
+~~~~{.cpp}
 
 Standard_Real X = 20, Y = 10, Z = 15, R = 10, DY = 30; 
 // Make the system of coordinates 
@@ -1542,7 +1542,7 @@ gp_Ax2 axes = gp::ZOX();
 axes.Translate(gp_Vec(X,Y,Z)); 
 TopoDS_Face F = 
 BRepPrimAPI_MakeCylinder(axes,R,DY,PI/2.); 
-~~~~~
+~~~~
 @figure{/user_guides/modeling_algos/images/modeling_algos_image029.png,"Cylinder",360}
 
 @subsubsection occt_modalg_4_1_5 Cone
@@ -1553,10 +1553,10 @@ BRepPrimAPI_MakeCylinder(axes,R,DY,PI/2.);
 
 The following code  builds the solid cone of the figure, which is located in the default system  with radii *R1* and *R2* and height *H*. 
 
-~~~~~
+~~~~{.cpp}
 Standard_Real R1 = 30, R2 = 10, H = 15; 
 TopoDS_Solid S = BRepPrimAPI_MakeCone(R1,R2,H); 
-~~~~~
+~~~~
 
 @figure{/user_guides/modeling_algos/images/modeling_algos_image030.png,"Cone",360}
 
@@ -1570,14 +1570,14 @@ TopoDS_Solid S = BRepPrimAPI_MakeCone(R1,R2,H);
 
 The following code  builds four spheres from a radius and three angles. 
 
-~~~~~
+~~~~{.cpp}
 Standard_Real R = 30, ang = 
        PI/2, a1 = -PI/2.3,  a2 = PI/4; 
 TopoDS_Solid S1 = BRepPrimAPI_MakeSphere(R); 
 TopoDS_Solid S2 = BRepPrimAPI_MakeSphere(R,ang); 
 TopoDS_Solid S3 = BRepPrimAPI_MakeSphere(R,a1,a2); 
 TopoDS_Solid S4 = BRepPrimAPI_MakeSphere(R,a1,a2,ang); 
-~~~~~
+~~~~
 
 Note that we could  equally well choose to create Shells instead of Solids. 
 
@@ -1596,7 +1596,7 @@ Note that we could  equally well choose to create Shells instead of Solids.
 
 The following code  builds four toroidal shells from two radii and three angles. 
 
-~~~~~
+~~~~{.cpp}
 Standard_Real R1 = 30, R2 = 10, ang = PI, a1 = 0, 
        a2 = PI/2; 
 TopoDS_Shell S1 = BRepPrimAPI_MakeTorus(R1,R2); 
@@ -1604,7 +1604,7 @@ TopoDS_Shell S2 = BRepPrimAPI_MakeTorus(R1,R2,ang);
 TopoDS_Shell S3 = BRepPrimAPI_MakeTorus(R1,R2,a1,a2); 
 TopoDS_Shell S4 = 
        BRepPrimAPI_MakeTorus(R1,R2,a1,a2,ang); 
-~~~~~
+~~~~
 
 Note that we could  equally well choose to create Solids instead of Shells. 
 
@@ -1647,7 +1647,7 @@ It is forbidden to sweep  Solids and Composite Solids. A Compound generates a Co
 
 The following code creates a finite, an infinite and a semi-infinite solid using a face, a  direction and a length. 
 
-~~~~~
+~~~~{.cpp}
 TopoDS_Face F = ..; // The swept face 
 gp_Dir direc(0,0,1); 
 Standard_Real l = 10; 
@@ -1660,7 +1660,7 @@ TopoDS_Solid P2 = BRepPrimAPI_MakePrism(F,direc);
 // infinite 
 TopoDS_Solid P3 =  BRepPrimAPI_MakePrism(F,direc,Standard_False); 
 // semi-infinite 
-~~~~~
+~~~~
 
 @figure{/user_guides/modeling_algos/images/modeling_algos_image034.png,"Finite, infinite, and semi-infinite prisms",420}
 
@@ -1670,14 +1670,14 @@ TopoDS_Solid P3 =  BRepPrimAPI_MakePrism(F,direc,Standard_False);
 *BRepPrimAPI_MakeRevol* constructors have a last argument to copy or share the original shape.
 The following code creates a full and a partial rotation using a face, an axis and an angle.
 
-~~~~~
+~~~~{.cpp}
 TopoDS_Face F = ...; // the profile 
 gp_Ax1 axis(gp_Pnt(0,0,0),gp_Dir(0,0,1)); 
 Standard_Real ang = PI/3; 
 TopoDS_Solid R1 = BRepPrimAPI_MakeRevol(F,axis); 
 // Full revol 
 TopoDS_Solid R2 = BRepPrimAPI_MakeRevol(F,axis,ang); 
-~~~~~
+~~~~
 
 @figure{/user_guides/modeling_algos/images/modeling_algos_image035.png,"Full and partial  rotation",420}
 
@@ -1719,27 +1719,27 @@ Boolean Operations have the following types of the arguments and produce the fol
 
 *BRepAlgoAPI_Fuse* performs the Fuse operation. 
 
-~~~~~
+~~~~{.cpp}
 TopoDS_Shape A = ..., B = ...; 
 TopoDS_Shape S = BRepAlgoAPI_Fuse(A,B); 
-~~~~~
+~~~~
 
 #### Common
 
 *BRepAlgoAPI_Common*  performs the Common operation. 
 
-~~~~~
+~~~~{.cpp}
 TopoDS_Shape A = ..., B = ...; 
 TopoDS_Shape S = BRepAlgoAPI_Common(A,B); 
-~~~~~
+~~~~
 
 #### Cut
 *BRepAlgoAPI_Cut* performs the Cut operation. 
 
-~~~~~
+~~~~{.cpp}
 TopoDS_Shape A = ..., B = ...; 
 TopoDS_Shape S = BRepAlgoAPI_Cut(A,B); 
-~~~~~
+~~~~
 
 #### Section
 
@@ -1747,10 +1747,10 @@ TopoDS_Shape S = BRepAlgoAPI_Cut(A,B);
 
 @figure{/user_guides/modeling_algos/images/modeling_algos_image037.png,"Section operation",220}
 
-~~~~~
+~~~~{.cpp}
 TopoDS_Shape A = ...,  TopoDS_ShapeB = ...; 
 TopoDS_Shape S =  BRepAlgoAPI_Section(A,B); 
-~~~~~
+~~~~
 
 
 
@@ -1780,7 +1780,7 @@ This feature might be useful if you need for instance to restore the shape from
 
 To make the faces from edges it is, firstly, necessary to create planar wires from the given edges and than create planar faces from each wire.
 The static methods *BOPAlgo_Tools::EdgesToWires* and *BOPAlgo_Tools::WiresToFaces* can be used for that:
-~~~~~
+~~~~{.cpp}
 TopoDS_Shape anEdges = ...; /* The input edges */
 Standard_Real anAngTol = 1.e-8; /* The angular tolerance for distinguishing the planes in which the wires are located */
 Standard_Boolean bShared = Standard_False; /* Defines whether the edges are shared or not */
@@ -1798,7 +1798,7 @@ if (!bDone) {
   cout << "Error: Unable to build faces from wires\n";
   return;
 }
-~~~~~
+~~~~
 
 These methods can also be used separately:
  * *BOPAlgo_Tools::EdgesToWires* allows creating planar wires from edges.
@@ -1881,14 +1881,14 @@ The classes provided by the API have the following features:
   
 Let us use the class *BRepBuilderAPI_MakeEdge* to create a linear edge from two  points. 
 
-~~~~~
+~~~~{.cpp}
 gp_Pnt P1(10,0,0), P2(20,0,0); 
 TopoDS_Edge E = BRepBuilderAPI_MakeEdge(P1,P2);
-~~~~~
+~~~~
 
 This is the simplest way to create edge E from two  points P1, P2, but the developer can test for errors when he is not as  confident of the data as in the previous example. 
 
-~~~~~
+~~~~{.cpp}
 #include <gp_Pnt.hxx> 
 #include <TopoDS_Edge.hxx> 
 #include <BRepBuilderAPI_MakeEdge.hxx> 
@@ -1906,13 +1906,13 @@ Standard_DomainError::Raise
 } 
 TopoDS_Edge E = ME; 
 } 
-~~~~~
+~~~~
 
 In this example an  intermediary object ME has been introduced. This can be tested for the  completion of the function before accessing the result. More information on **error  handling** in the topology programming interface can be found in the next section. 
 
 *BRepBuilderAPI_MakeEdge*  provides valuable information. For example, when creating an edge from two  points, two vertices have to be created from the points. Sometimes you may be  interested in getting these vertices quickly without exploring the new edge.  Such information can be provided when using a class. The following example  shows a function creating an edge and two vertices from two points. 
 
-~~~~~
+~~~~{.cpp}
 void MakeEdgeAndVertices(const gp_Pnt& P1, 
 const gp_Pnt& P2, 
 TopoDS_Edge& E, 
@@ -1927,15 +1927,15 @@ Standard_DomainError::Raise
 E = ME; 
 V1 = ME.Vextex1(); 
 V2 = ME.Vertex2(); 
-~~~~~
+~~~~
 
 The class *BRepBuilderAPI_MakeEdge*  provides two methods *Vertex1* and  *Vertex2*, which return two vertices used to create the edge. 
 
 How can *BRepBuilderAPI_MakeEdge* be both a function and a class? It can do this  because it uses the casting capabilities of C++. The *BRepBuilderAPI_MakeEdge* class has a method called Edge; in the previous  example the line <i>E = ME</i> could have been written. 
 
-~~~~~
+~~~~{.cpp}
 E = ME.Edge(); 
-~~~~~
+~~~~
 
 This instruction tells  the C++ compiler that there is an **implicit casting** of a *BRepBuilderAPI_MakeEdge* into a *TopoDS_Edge* using the *Edge* method. It means this method is automatically called when a *BRepBuilderAPI_MakeEdge* is found where a *TopoDS_Edge* is required. 
 
@@ -1997,7 +1997,7 @@ For example, extrusion of the edge in some direction will create a face. This fa
 *BRepTools_History* is the general History tool intended for unification of the histories of different algorithms.
 
 *BRepTools_History* can be created from any algorithm supporting the standard history methods *(IsDeleted(), Modified()* and *Generated())*:
-~~~~
+~~~~{.cpp}
 // The arguments of the operation
 TopoDS_Shape aS = ...;
 
@@ -2015,18 +2015,18 @@ BRepTools_History aHistory(anArguments, aTransformer);
 
 *BRepTools_History* also allows merging histories. Thus, if you have two or more subsequent operations you can get one final history combined from histories of these operations:
 
-~~~~
+~~~~{.cpp}
 Handle(BRepTools_History) aHist1 = ...; // History of first operation
 Handle(BRepTools_History) aHist2 = ...; // History of second operation
 ~~~~
 
 It is possible to merge the second history into the first one:
-~~~~
+~~~~{.cpp}
 aHist1->Merge(aHist2);
 ~~~~
 
 Or create the new history keeping the two histories unmodified:
-~~~~
+~~~~{.cpp}
 Handle(BRepTools_History) aResHistory = new BRepTools_History;
 aResHistory->Merge(aHist1);
 aResHistory->Merge(aHist2);
@@ -2071,7 +2071,7 @@ In the following example  a filleted box with dimensions a,b,c and radius r is c
 ### Constant  radius 
 
 
-~~~~~
+~~~~{.cpp}
 #include <TopoDS_Shape.hxx> 
 #include <TopoDS.hxx> 
 #include <BRepPrimAPI_MakeBox.hxx> 
@@ -2096,14 +2096,14 @@ TopoDS_Shape FilletedBox(const Standard_Real a,
        } 
        return MF.Shape(); 
        } 
-~~~~~
+~~~~
 
 @figure{/user_guides/modeling_algos/images/modeling_algos_image039.png,"Fillet with constant radius",360}
 
 #### Changing radius
 
 
-~~~~~
+~~~~{.cpp}
 void CSampleTopologicalOperationsDoc::OnEvolvedblend1() 
 { 
        TopoDS_Shape theBox  = BRepPrimAPI_MakeBox(200,200,200); 
@@ -2124,7 +2124,7 @@ void CSampleTopologicalOperationsDoc::OnEvolvedblend1()
        Rake.Add(ParAndRad, TopoDS::Edge(ex.Current())); 
        TopoDS_Shape  evolvedBox = Rake.Shape(); 
 } 
-~~~~~
+~~~~
 
 @figure{/user_guides/modeling_algos/images/modeling_algos_image040.png,"Fillet with changing radius",360}
  
@@ -2136,10 +2136,10 @@ The use of *BRepFilletAPI_MakeChamfer* class is similar to the use of  *BRepFill
 * The surfaces created are  ruled and not smooth. 
 * The *Add* syntax for  selecting edges requires one or two distances, one edge and one face  (contiguous to the edge).
 
-~~~~
+~~~~{.cpp}
 Add(dist,  E, F) 
 Add(d1,  d2, E, F) with d1 on the face F. 
-~~~~~
+~~~~
 
 @figure{/user_guides/modeling_algos/images/modeling_algos_image041.png,"Chamfer",360}
 
@@ -2153,16 +2153,16 @@ A chamfer can be calculated with *AddChamfer* method. It can be  described by
   * one edge, one vertex, one  distance and one angle.
 Fillets and chamfers are calculated when addition is  complete. 
 
-If face F2 is created by 2D fillet and chamfer builder from face F1, the builder can be rebuilt (the  builder recovers the status it had before deletion). To do so, use the  following syntax: 
-~~~~~
+If face F2 is created by 2D fillet and chamfer builder from face F1, the builder can be rebuilt (the  builder recovers the status it had before deletion). To do so, use the  following Syntax:
+~~~~{.cpp}
 BRepFilletAPI_MakeFillet2d builder; 
 builder.Init(F1,F2); 
-~~~~~
+~~~~
 
 Planar Fillet
 -------------
 
-~~~~~
+~~~~{.cpp}
 #include “BRepPrimAPI_MakeBox.hxx” 
 #include “TopoDS_Shape.hxx” 
 #include “TopExp_Explorer.hxx” 
@@ -2190,7 +2190,7 @@ TopoDS_Shape FilletFace(const Standard_Real a,
        // while... 
        return MF.Shape(); 
 } 
-~~~~~
+~~~~
 
 @subsection occt_modalg_7 Offsets, Drafts, Pipes and Evolved shapes
 
@@ -2223,7 +2223,7 @@ The second algorithm is based on the fact that the offset computation for a sing
 The possible drawback of the simple algorithm is that it leads, in general case, to tolerance increasing. The tolerances have to grow in order to cover the gaps between the neighbor faces in the output. It should be noted that the actual tolerance growth depends on the offset distance and the quality of joints between the input faces. Anyway the good input shell (smooth connections between adjacent faces) will lead to good result.
 
 The snippets below show usage examples:
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
     BRepOffsetAPI_MakeOffsetShape OffsetMaker1;
     // Computes offset shape using analytical continuation mechanism.
     OffsetMaker1.PerformByJoin(Shape, OffsetValue, Tolerance);
@@ -2235,14 +2235,14 @@ The snippets below show usage examples:
     OffsetMaker2.PerformBySimple(Shape, OffsetValue);
     if (OffsetMaker2.IsDone())
       NewShape = OffsetMaker2.Shape();
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 @subsubsection occt_modalg_7_2 Shelling 
 
 Shelling is used to offset given faces of a solid by a specific value. It rounds or intersects adjacent faces along its edges depending on the convexity of the edge. 
 The MakeThickSolidByJoin method of the *BRepOffsetAPI_MakeThickSolid* takes the solid, the list of faces to remove and an offset value as input.
 
-~~~~~
+~~~~{.cpp}
 TopoDS_Solid SolidInitial = ...;
 
 Standard_Real                  Of              = ...;
@@ -2262,18 +2262,18 @@ SolidMaker.MakeThickSolidByJoin(SolidInitial,
                                 Tol);
 if (SolidMaker.IsDone())
   Result = SolidMaker.Shape();
-~~~~~
+~~~~
 
 @figure{/user_guides/modeling_algos/images/modeling_algos_image042.png,"Shelling",420}
 
 Also it is possible to create solid between shell, offset shell. This functionality can be called using *BRepOffsetAPI_MakeThickSolid::MakeThickSolidBySimple* method. The code below shows usage example:
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
     BRepOffsetAPI_MakeThickSolid SolidMaker;
     SolidMaker.MakeThickSolidBySimple(Shell, OffsetValue);
     if (myDone.IsDone())
       Solid = SolidMaker.Shape();
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 @subsubsection occt_modalg_7_3  Draft Angle
 
@@ -2287,7 +2287,7 @@ The class is created or  initialized from a shape, then faces to be modified are
 
 The following code  places a draft angle on several faces of a shape; the same direction, angle and  neutral plane are used for each face: 
 
-~~~~~
+~~~~{.cpp}
 TopoDS_Shape myShape = ... 
 // The original shape 
 TopTools_ListOfShape ListOfFace; 
@@ -2323,7 +2323,7 @@ else {
        TopoDS_Shape  myResult = theDraft.Shape(); 
        ... 
 } 
-~~~~~
+~~~~
 
 @figure{/user_guides/modeling_algos/images/modeling_algos_image043.png,"DraftAngle",420}
 
@@ -2333,11 +2333,11 @@ else {
 
 The angle between the spine and the profile is preserved throughout the pipe. 
 
-~~~~~
+~~~~{.cpp}
 TopoDS_Wire Spine = ...; 
 TopoDS_Shape Profile = ...; 
 TopoDS_Shape Pipe =  BRepOffsetAPI_MakePipe(Spine,Profile); 
-~~~~~
+~~~~
 
 @figure{/user_guides/modeling_algos/images/modeling_algos_image044.png,"Example of a Pipe",320}
 
@@ -2357,12 +2357,12 @@ The reference axes of  the profile can be defined following two distinct modes:
   + the X axis is given by the  tangent to the spine at the point defined above
   + the Z axis is the normal to  the plane which contains the spine.
 
-~~~~~
+~~~~{.cpp}
 TopoDS_Face Spine = ...; 
 TopoDS_Wire Profile = ...; 
 TopoDS_Shape Evol = 
 BRepOffsetAPI_MakeEvolved(Spine,Profile); 
-~~~~~
+~~~~
 
 @subsection occt_modalg_3b Object Modification
 
@@ -2371,7 +2371,7 @@ BRepOffsetAPI_MakeEvolved(Spine,Profile);
 
 The following example  deals with the rotation of shapes. 
 
-~~~~~
+~~~~{.cpp}
 
 TopoDS_Shape myShape1 = ...; 
 // The original shape 1 
@@ -2386,19 +2386,19 @@ TopoDS_Shape myNewShape1 = theTrsf.Shape()
 theTrsf.Perform(myShape2,Standard_True); 
 // Here duplication is forced 
 TopoDS_Shape myNewShape2 = theTrsf.Shape() 
-~~~~~
+~~~~
 
 @subsubsection occt_modalg_3b_2 Duplication
 
 Use the  *BRepBuilderAPI_Copy* class to duplicate a shape. A new shape is thus created. 
 In the following example, a  solid is copied: 
 
-~~~~~
+~~~~{.cpp}
 TopoDS Solid MySolid; 
 ....// Creates a solid 
 
 TopoDS_Solid myCopy = BRepBuilderAPI_Copy(mySolid); 
-~~~~~
+~~~~
 
 @subsection occt_modalg_3a_1 Error Handling in the Topology API
 
@@ -2415,7 +2415,7 @@ As the test involves a  great deal of computation, performing it twice is also t
 
 Consequently, you might be tempted to adopt the highly inadvisable style of programming  illustrated in the following example: 
 
-~~~~~
+~~~~{.cpp}
 #include <Standard_ErrorHandler.hxx> 
 try { 
 TopoDS_Edge E = BRepBuilderAPI_MakeEdge(P1,P2); 
@@ -2424,13 +2424,13 @@ TopoDS_Edge E = BRepBuilderAPI_MakeEdge(P1,P2);
 catch { 
 // process the error. 
 } 
-~~~~~
+~~~~
 
 To help the user, the  Topology API classes only raise the exception *StdFail_NotDone*. Any other  exception means that something happened which was unforeseen in the design of  this API. 
 
 The *NotDone* exception  is only raised when the user tries to access the result of the computation and  the original data is corrupted. At the construction of the class instance, if  the algorithm cannot be completed, the internal flag *NotDone* is set. This flag  can be tested and in some situations a more complete description of the error  can be queried. If the user ignores the *NotDone* status and tries to access the  result, an exception is raised. 
 
-~~~~~
+~~~~{.cpp}
 BRepBuilderAPI_MakeEdge ME(P1,P2); 
 if (!ME.IsDone()) { 
 // doing ME.Edge() or E = ME here 
@@ -2439,7 +2439,7 @@ Standard_DomainError::Raise
 (“ProcessPoints::Failed to create an edge”); 
 } 
 TopoDS_Edge E = ME; 
-~~~~~
+~~~~
 
 
 @subsection occt_modalg_8 Sewing
@@ -2488,7 +2488,7 @@ Each stage of the algorithm or the whole algorithm can be adjusted with the foll
 
 To connect a set of *n* contiguous but independent faces, do the following: 
 
-~~~~~
+~~~~{.cpp}
     BRepBuilderAPI_Sewing Sew;
     Sew.Add(Face1); 
     Sew.Add(Face2); 
@@ -2496,7 +2496,7 @@ To connect a set of *n* contiguous but independent faces, do the following:
     Sew.Add(Facen); 
     Sew.Perform();
     TopoDS_Shape result= Sew.SewedShape();
-~~~~~
+~~~~
 
 If all faces have been sewn correctly, the result is a shell. Otherwise, it is a compound. After a successful sewing operation all faces have a coherent orientation.
 
@@ -2536,7 +2536,7 @@ For example, if you want to sew two open shells having coincided free edges usin
 
 See the example:
 
-~~~~
+~~~~{.cpp}
 
 //initial sewn shapes
 TopoDS_Shape aS1, aS2;  // these shapes are expected to be well sewn shells
@@ -2617,7 +2617,7 @@ There are six Perform  methods:
 
 In the following  sequence, a protrusion is performed, i.e. a face of the shape is changed into a  prism. 
 
-~~~~~
+~~~~{.cpp}
 TopoDS_Shape Sbase = ...;  // an initial shape 
 TopoDS_Face Fbase = ....; // a base of prism 
 
@@ -2632,7 +2632,7 @@ if (thePrism.IsDone()) {
        TopoDS_Shape  theResult = thePrism; 
        ... 
 } 
-~~~~~
+~~~~
 
 @figure{/user_guides/modeling_algos/images/modeling_algos_image047.png,"Fusion with MakePrism",320}
 
@@ -2661,7 +2661,7 @@ In case of the  concerned area of a face, it is possible to cut it out and move
 
 The *Perform* methods are the same as for *MakePrism*. 
 
-~~~~~
+~~~~{.cpp}
 TopoDS_Shape S = BRepPrimAPI_MakeBox(400.,250.,300.); 
 TopExp_Explorer Ex; 
 Ex.Init(S,TopAbs_FACE); 
@@ -2687,7 +2687,7 @@ BRepFeat_MakeDPrism MKDP (S,FP,F,10*PI180,Standard_True,
                                                        Standard_True); 
 MKDP.Perform(200); 
 TopoDS_Shape res1 = MKDP.Shape(); 
-~~~~~
+~~~~
 
 @figure{/user_guides/modeling_algos/images/modeling_algos_image049.png,"A tapered prism",320}
 
@@ -2714,7 +2714,7 @@ There are four Perform  methods:
 
 In the following sequence, a face is revolved and  the revolution is limited by a face of the base shape. 
 
-~~~~~
+~~~~{.cpp}
 TopoDS_Shape Sbase = ...;  // an initial shape 
 TopoDS_Face Frevol = ....; // a base of prism 
 TopoDS_Face FUntil = ....; // face limiting the revol 
@@ -2731,7 +2731,7 @@ if (theRevol.IsDone()) {
        TopoDS_Shape  theResult = theRevol; 
        ... 
 } 
-~~~~~
+~~~~
 
 **Pipe**
 
@@ -2752,7 +2752,7 @@ There are three Perform  methods:
 
 Let us have a look at the example:
 
-~~~~~
+~~~~{.cpp}
 TopoDS_Shape S = BRepPrimAPI_MakeBox(400.,250.,300.); 
 TopExp_Explorer Ex; 
 Ex.Init(S,TopAbs_FACE); 
@@ -2797,7 +2797,7 @@ BRepFeat_MakePipe MKPipe (S,FP,F1,W,Standard_False,
 Standard_True); 
 MKPipe.Perform(); 
 TopoDS_Shape res1 = MKPipe.Shape(); 
-~~~~~
+~~~~
 
 @figure{/user_guides/modeling_algos/images/modeling_algos_image050.png,"Pipe depression",240}
 
@@ -2826,7 +2826,7 @@ A class object is  created or initialized from
   
 Linear form is implemented in *MakeLinearForm* class, which creates a rib or a groove  along a planar surface. There is one *Perform()* method, which performs a  prism from the wire along the *direction1* and *direction2* interacting with base shape *Sbase*. The height of the prism is *Magnitude(Direction1)+Magnitude(direction2)*.  
 
-~~~~~
+~~~~{.cpp}
 BRepBuilderAPI_MakeWire mkw; 
 gp_Pnt p1 = gp_Pnt(0.,0.,0.); 
 gp_Pnt p2 = gp_Pnt(200.,0.,0.); 
@@ -2857,7 +2857,7 @@ BRepFeat_MakeLinearForm aform(S, W, aplane, gp_Dir
        (0.,5.,0.), gp_Dir(0.,-3.,0.),  1, Standard_True); 
 aform.Perform(); 
 TopoDS_Shape res = aform.Shape(); 
-~~~~~
+~~~~
 
 @figure{/user_guides/modeling_algos/images/modeling_algos_image051.png,"Creating a rib",240}
 
@@ -2870,7 +2870,7 @@ Two *Bind* methods are  used to bind a face of the glued shape to a face of the
 
 **Note** that every face and edge has to be  bounded, if two edges of two glued faces are  coincident they must be explicitly bounded.
 
-~~~~~
+~~~~{.cpp}
 TopoDS_Shape Sbase = ...; // the basic shape 
 TopoDS_Shape Sglued = ...; // the glued shape 
 
@@ -2898,7 +2898,7 @@ if (theGlue.IsDone() {
 TopoDS_Shape  theResult = theGlue; 
 ... 
 } 
-~~~~~
+~~~~
 
 @subsubsection occt_modalg_9_2_4 Split Shape
 
@@ -2912,7 +2912,7 @@ Three Add methods are  available:
 
 **Note** The added wires and edges must  define closed wires on faces or wires located between two  existing edges. Existing edges must not be intersected. 
 
-~~~~~
+~~~~{.cpp}
 TopoDS_Shape Sbase = ...; // basic shape 
 TopoDS_Face Fsplit = ...; // face of Sbase 
 TopoDS_Wire Wsplit = ...; // new wire contained in Fsplit 
@@ -2920,7 +2920,7 @@ BRepFeat_SplitShape Spls(Sbase);
 Spls.Add(Wsplit, Fsplit); 
 TopoDS_Shape theResult = Spls; 
 ...
-~~~~~
+~~~~
 
 @subsection occt_modalg_defeaturing 3D Model Defeaturing
 
@@ -2986,7 +2986,7 @@ Although, removal of only two faces, keeping one of the transverse faces, will f
 @subsubsection occt_modalg_defeaturing_usage Usage
 
 Here is the example of usage of the *BRepAlgoAPI_Defeaturing* algorithm on the C++ level:
-~~~~
+~~~~{.cpp}
 TopoDS_Shape aSolid = ...;               // Input shape to remove the features from
 TopTools_ListOfShape aFeatures = ...;    // Features to remove from the shape
 Standard_Boolean bRunParallel = ...;     // Parallel processing mode
@@ -3015,7 +3015,7 @@ const TopoDS_Shape& aResult = aDF.Shape(); // Result shape
 ~~~~
 
 Use the API history methods to track the history of a shape:
-~~~~
+~~~~{.cpp}
 // Obtain modification of the shape
 const TopTools_ListOfShape& BRepAlgoAPI_Defeaturing::Modified(const TopoDS_Shape& theS);
 
@@ -3091,7 +3091,7 @@ Such approach will allow repeating the shape, i.e. translating the copy of a sha
 
 For better understanding of what periodicity means lets create a simple prism and make it periodic.
 The following draw script creates the L-shape prism with extensions 10x5x10:
-~~~~
+~~~~{.cpp}
 polyline p 0 0 0 0 0 10 5 0 10 5 0 5 10 0 5 10 0 0 0 0 0
 mkplane f p
 prism s f 0 5 0
@@ -3164,7 +3164,7 @@ For more information on the error/warning reporting system please see the chapte
 
 The algorithm is implemented in the class *BOPAlgo_MakePeriodic*.
 Here is the example of its usage on the API level:
-~~~~
+~~~~{.cpp}
 TopoDS_Shape aShape = ...;                 // The shape to make periodic
 Standard_Boolean bMakeXPeriodic = ...;     // Flag for making or not the shape periodic in X direction
 Standard_Real aXPeriod = ...;              // X period for the shape
@@ -3207,7 +3207,7 @@ Please note, that the class is based on the options class *BOPAlgo_Options*, whi
 The other options of the base class are not supported here and will have no effect.
 
 All the history information obtained during the operation is stored into *BRepTools_History* object and available through *History()* method:
-~~~~
+~~~~{.cpp}
 // Get the history object
 const Handle(BRepTools_History)& BOPAlgo_MakePeriodic::History();
 ~~~~
@@ -3228,7 +3228,7 @@ To have possibility to access the error/warning shapes of the operation use the
 
 Imagine that you need to make the drills in the plate on the same distance from each other. To model this process it is necessary to make a lot of cylinders (simulating the drills) and cut these cylinders from the plate.
 With the periodicity tool, the process looks very simple:
-~~~~
+~~~~{.cpp}
 # create plate 100 x 100
 box plate -50 -50 0 100 100 1
 # create a single drill with radius 1
@@ -3308,7 +3308,7 @@ For an *HLRBRep_HLRToShape* object built from an *HLRBRepAlgo* object you can al
 
 ### HLRBRep_Algo
 
-~~~~~
+~~~~{.cpp}
 // Build The algorithm object 
 myAlgo = new HLRBRep_Algo(); 
 
@@ -3349,12 +3349,12 @@ TopoDS_Shape OutLineHCompound                            =
 aHLRToShape.OutLineHCompound(); 
 TopoDS_Shape IsoLineHCompound                            = 
 aHLRToShape.IsoLineHCompound(); 
-~~~~~
+~~~~
 
 ### HLRBRep_PolyAlgo
 
 
-~~~~~
+~~~~{.cpp}
 
 // Build The algorithm object 
 myPolyAlgo = new HLRBRep_PolyAlgo(); 
@@ -3393,7 +3393,7 @@ TopoDS_Shape RgNLineHCompound =
 aPolyHLRToShape.RgNLineHCompound(); 
 TopoDS_Shape OutLineHCompound = 
 aPolyHLRToShape.OutLineHCompound(); 
-~~~~~
+~~~~
 
 
 
@@ -3421,7 +3421,7 @@ For obtaining the material information the following methods should be used
 * *MaterialsOnPositiveSide()* - returns the original shapes (materials) located on the positive side of the given shape (i.e. with FORWARD orientation);
 * *MaterialsOnNegativeSide()* - returns the original shapes (materials) located on the negative side of the given shape (i.e. with REVERSED orientation);
 
-~~~~
+~~~~{.cpp}
 // Returns the original shapes which images contain the given shape with FORWARD orientation.
 const TopTools_ListOfShape& BOPAlgo_MakeConnected::MaterialsOnPositiveSide(const TopoDS_Shape& theS)
 
@@ -3440,7 +3440,7 @@ After making the shape periodic the material associations are updated to corresp
 
 The algorithm supports history of shapes modifications during the operation. Additionally to standard history method provided by *BRepTools_History* and used here as a history tool, the algorithm also provides the method to track the back connection - from resulting shapes to the input ones.
 The method is called *GetOrigins()*:
-~~~~
+~~~~{.cpp}
 // Returns the list of original shapes from which the current shape has been created.
 const TopTools_ListOfShape& BOPAlgo_MakeConnected::GetOrigins(const TopoDS_Shape& theS);
 ~~~~
@@ -3463,7 +3463,7 @@ For more information on the error/warning reporting system please see the chapte
 @subsection occt_modalg_makeconnected_usage Usage
 
 Here is the example of usage of the *BOPAlgo_MakePeriodic* algorithm on the API level:
-~~~~
+~~~~{.cpp}
 TopTools_ListOfShape anArguments = ...;  // Shapes to make connected
 Standard_Boolean bRunParallel = ...;     // Parallel processing mode
 
@@ -3521,7 +3521,7 @@ Please note, that the class is based on the options class *BOPAlgo_Options*, whi
 The other options of the base class are not supported here and will have no effect.
 
 All the history information obtained during the operation is stored into *BRepTools_History* object and available through *History()* method:
-~~~~
+~~~~{.cpp}
 // Get the history object
 const Handle(BRepTools_History)& BOPAlgo_MakeConnected::History();
 ~~~~
index 68d02cca4f489e1e9227fdffe2423a678239e4ce..06b55b797dd5e19c27ca37e242437cb7f97472ad 100644 (file)
@@ -52,14 +52,14 @@ The class *Interpolate* from *GeomAPI* package allows building a constrained 3D
 @figure{/user_guides/modeling_data/images/modeling_data_image003.png,"Approximation of a BSpline from scattered points",420}
 
 This class may be instantiated as follows:
-~~~~
+~~~~{.cpp}
 GeomAPI_Interpolate Interp(Points); 
-~~~~~
+~~~~
 
 From this object, the BSpline curve may be requested as follows: 
-~~~~~
+~~~~{.cpp}
 Handle(Geom_BSplineCurve) C = Interp.Curve(); 
-~~~~~
+~~~~
 
 #### 2D Approximation
 
@@ -71,16 +71,16 @@ The class *PointsToBSpline* from GeomAPI package allows building a 3D BSplinecur
 
 The resulting BSpline curve will be C2 or second degree continuous, except where a tangency constraint is defined on a point, through which the curve passes. In this case, it will be only C1 continuous. This class is instantiated as follows: 
 
-~~~~~
+~~~~{.cpp}
 GeomAPI_PointsToBSpline 
 Approx(Points,DegMin,DegMax,Continuity, Tol); 
-~~~~~
+~~~~
 
 From this object, the BSpline curve may be requested as follows: 
 
-~~~~~
+~~~~{.cpp}
 Handle(Geom_BSplineCurve) K = Approx.Curve(); 
-~~~~~
+~~~~
 
 #### Surface Approximation 
 
@@ -184,7 +184,7 @@ The object created (or implemented) is an algorithm which can be consulted to fi
 
 If it was unsuccessful, the status gives the reason for the failure.
 
-~~~~
+~~~~{.cpp}
     gp_Pnt P1 (0.,0.,0.);
     gp_Pnt P2 (0.,10.,0.);
     gp_Pnt P3 (10.,0.,0.);
@@ -246,7 +246,7 @@ Each class from *gp* package, such as *Circ, Circ2d, Mirror, Mirror2d*, etc., ha
 
 It is possible to create a point using a *gce* package class, then question it to recover the corresponding *gp* object. 
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
   gp_Pnt2d Point1,Point2; 
   ...
   //Initialization of Point1 and Point2 
@@ -254,13 +254,13 @@ It is possible to create a point using a *gce* package class, then question it t
   if (L.Status() == gce_Done() ){ 
     gp_Lin2d l = L.Value(); 
   }
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 This is useful if you are uncertain as to whether the arguments can create the *gp* object without raising an exception. In the case above, if *Point1* and *Point2* are closer than the tolerance value required by *MakeLin2d*, the function *Status* will return the enumeration *gce_ConfusedPoint*. This tells you why the *gp* object cannot be created. If you know that the points *Point1* and *Point2* are separated by the value exceeding the tolerance value, then you may create the *gp* object directly, as follows: 
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
 gp_Lin2d l = gce_MakeLin2d(Point1,Point2); 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 @subsubsection occt_modat_1_2_2 Geometric entities manipulated by handle
 
@@ -363,20 +363,20 @@ The following characteristic points exist on parameterized curves in 3d space:
 Let us take an adapted curve **C**, i.e. an object which is an interface between the services provided by either a 2D curve from the package Geom2d (in case of an Adaptor_Curve2d curve) or a 3D curve from the package Geom (in case of an Adaptor_Curve curve), and the services required on the curve by the computation algorithm. The adapted curve is created in the following way: 
 
 **2D case :** 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
   Handle(Geom2d_Curve) mycurve = ... ; 
   Geom2dAdaptor_Curve C (mycurve) ; 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 **3D case :** 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
   Handle(Geom_Curve) mycurve = ... ; 
   GeomAdaptor_Curve C (mycurve) ; 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 The algorithm is then constructed with this object:
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
   GCPnts_UniformDeflection myAlgo () ; 
   Standard_Real Deflection = ... ; 
   myAlgo.Initialize ( C , Deflection ) ; 
@@ -390,7 +390,7 @@ The algorithm is then constructed with this object:
       ...
     } 
   }
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 
 @subsection occt_modat_1_5 Extrema
@@ -771,7 +771,7 @@ There are no constructors for the classes inheriting from the *TopoDS_Shape* cla
 The following example shows a routine receiving an argument of the *TopoDS_Shape* type, then putting it into a variable V if it is a vertex or calling the method ProcessEdge if it is an edge. 
 
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
   #include <TopoDS_Vertex.hxx> 
   #include <TopoDS_Edge.hxx> 
   #include <TopoDS_Shape.hxx> 
@@ -796,7 +796,7 @@ The following example shows a routine receiving an argument of the *TopoDS_Shape
       // OK for compiler but an exception will be raised at run-time 
     }
   } 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 
 
@@ -814,7 +814,7 @@ The TopExp package provides the class *TopExp_Explorer* to find all sub-objects
 The Explorer visits the whole structure in order to find the shapes of the requested type not contained in the type to avoid. The example below shows  how to find all faces in the shape *S*: 
 
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
   void test() { 
     TopoDS_Shape S; 
     TopExp_Explorer Ex; 
@@ -822,19 +822,19 @@ The Explorer visits the whole structure in order to find the shapes of the reque
       ProcessFace(Ex.Current()); 
     } 
   } 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 Find all the vertices which are not in an edge 
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
 for (Ex.Init(S,TopAbs_VERTEX,TopAbs_EDGE); ...) 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 
 Find all the faces in a SHELL, then all the faces not in a SHELL: 
 
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
   void test() { 
     TopExp_Explorer Ex1, Ex2; 
     TopoDS_Shape S; 
@@ -852,14 +852,14 @@ Find all the faces in a SHELL, then all the faces not in a SHELL:
       ProcessFace(Ex1.Current()); 
     }
   }
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 The Explorer presumes that objects contain only objects of an equal or inferior type. For example, if searching for faces it does not look at wires, edges, or vertices to see if they contain faces. 
 
 The *MapShapes* method from *TopExp* package allows filling a Map. An exploration using the Explorer class can visit an object more than once if it is referenced more than once. For example, an edge of a solid is generally referenced by two faces. To process objects only once, they have to be placed in a Map. 
 
 **Example** 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
   void TopExp::MapShapes (const TopoDS_Shape& S, 
               const TopAbs_ShapeEnum T, 
               TopTools_IndexedMapOfShape& M) 
@@ -870,7 +870,7 @@ The *MapShapes* method from *TopExp* package allows filling a Map. An exploratio
       Ex.Next(); 
     }
   }
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 In the following example all  faces and all  edges of an object are drawn in accordance with the following rules: 
 - The faces are represented by a network of *NbIso* iso-parametric lines with *FaceIsoColor* color. 
@@ -886,7 +886,7 @@ The following steps are performed:
 3. Exploring the edges and for each of them increment the counter of faces in the array. 
 4. From the Map of edges, drawing each edge with the color corresponding to the number of faces. 
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
   void DrawShape ( const TopoDS_Shape& aShape, 
   const Standard_Integer nbIsos, 
   const Color FaceIsocolor, 
@@ -930,7 +930,7 @@ The following steps are performed:
       }
     } 
   } 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 @subsubsection occt_modat_5_5 Lists and Maps of Shapes
 
@@ -946,7 +946,7 @@ With a *TopTools_Map*, a set of references to Shapes can be kept without duplica
 The following example counts the size of a data structure as a number of *TShapes*. 
 
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
   #include <TopoDS_Iterator.hxx> 
   Standard_Integer Size(const TopoDS_Shape& aShape) 
   { 
@@ -959,14 +959,14 @@ The following example counts the size of a data structure as a number of *TShape
     } 
     return size; 
   } 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 This program is incorrect if there is sharing in the data structure. 
 
 Thus for a contour of four edges it should count 1 wire + 4 edges +4 vertices with the result 9, but as the vertices are each shared by two edges this program will return 13. One solution is to put all the Shapes in a Map so as to avoid counting them twice, as in the following example: 
 
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
   #include <TopoDS_Iterator.hxx> 
   #include <TopTools_MapOfShape.hxx> 
 
@@ -990,7 +990,7 @@ Thus for a contour of four edges it should count 1 wire + 4 edges +4 vertices wi
     MapShapes(aShape,M); 
     return M.Extent();
   }
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 **Note** For more details about Maps, refer to the *TCollection* documentation (Foundation Classes Reference Manual). 
 
@@ -999,7 +999,7 @@ The following example is more ambitious and writes a program which copies a data
 - A table of Shapes is created in parallel with the map to receive the copies. 
 - The structure is copied using the auxiliary recursive function,which copies from the map to the array. 
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
   #include <TopoDS_Shape.hxx> 
   #include <TopoDS_Iterator.hxx> 
   #include <TopTools_IndexedMapOfShape.hxx> 
@@ -1029,7 +1029,7 @@ The following example is more ambitious and writes a program which copies a data
       }
     } 
   } 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 
 In the above example, the index *i* is that of the first object not treated in the Map. When *i* reaches the same size as the Map this means that everything has been treated. The treatment consists in inserting in the Map all the sub-objects, if they are not yet in the Map, they are inserted with an index greater than *i*. 
@@ -1037,7 +1037,7 @@ In the above example, the index *i* is that of the first object not treated in t
 **Note** that the objects are inserted with a local reference set to the identity and a FORWARD orientation. Only the underlying TShape is of great interest.
 
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
   //Create an array to store the copies. 
   TopTools_Array1OfShapetheCopies(1,theMap.Extent());
 
@@ -1054,12 +1054,12 @@ In the above example, the index *i* is that of the first object not treated in t
   S.Location(aShape.Location()); 
   S.Orientation(aShape.Orientation()); 
   return S; 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 Below is the auxiliary function, which copies the element of rank *i* from the map to the table. This method checks if the object has been copied; if not copied, then an empty copy is performed into the table and the copies of all the sub-elements are inserted by finding their rank in the map. 
 
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
   void AuxiliaryCopy(Standard_Integer index, 
   const TopTools_IndexedMapOfShapes& sources, 
   TopTools_Array1OfShape& copies, 
@@ -1081,7 +1081,7 @@ Below is the auxiliary function, which copies the element of rank *i* from the m
       }
     }
   }
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 **Wire Explorer**
 
@@ -1093,7 +1093,7 @@ For example, in the wire in the image we want to recuperate the edges in the ord
 
 *TopExp_Explorer*, however, recuperates the lines in any order.
  
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
   TopoDS_Wire W = ...; 
   BRepTools_WireExplorer Ex; 
   for(Ex.Init(W); Ex.More(); Ex.Next()) { 
@@ -1101,7 +1101,7 @@ For example, in the wire in the image we want to recuperate the edges in the ord
     ProcessTheVertexConnectingTheCurrentEdgeToThePrevious 
     One(Ex.CurrentVertex()); 
   } 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 @section occt_modat_4 Properties of Shapes
 
index 42d2693f9df896b040c0dcafce666a16e8a3f9f5..7a5b610c035b8d6ea1793f7315196063edc36af4 100644 (file)
@@ -298,10 +298,10 @@ As the names suggest, in random delivery, the tag value is generated by the syst
 To append and return a new child label, you use *TDF_TagSource::NewChild*. In the example below, the argument *level2*, which is passed to *NewChild,* is a *TDF_Label*. 
 
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~{.cpp}
 TDF_Label child1 = TDF_TagSource::NewChild (level2); 
 TDF_Label child2 = TDF_TagSource::NewChild (level2); 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 @subsubsection occt_ocaf_3_3_2 Creation of a child label by user delivery from a tag
 
@@ -310,12 +310,12 @@ The other way to create a child label from a tag is by user delivery. In other w
 To retrieve a child label from a tag which you have specified yourself, you need to use *TDF_Label::FindChild* and *TDF_Label::Tag* as in the example below. Here, the integer 3 designates the tag of the label you are interested in, and the Boolean false is the value for the argument *create*. When this argument is set to *false*, no new child label is created. 
 
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~{.cpp}
 TDF_Label achild = root.FindChild(3,Standard_False); 
 if (!achild.IsNull()) { 
 Standard_Integer tag = achild.Tag(); 
 } 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 @subsection occt_ocaf_3_4 Label
 
@@ -332,7 +332,7 @@ Labels can be created on any labels, compared with brother labels and retrieved.
 To create a new child label in the data framework using explicit delivery of tags, use *TDF_Label::FindChild*. 
 
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
 //creating a label with tag 10 at Root 
 TDF_Label lab1 = aDF->Root().FindChild(10); 
 
@@ -340,20 +340,20 @@ TDF_Label lab1 = aDF->Root().FindChild(10);
 TDF_Label lab2 = lab1.FindChild(7); 
 
 TDF_Label lab3 = lab1.FindChild(2); 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 You could also use the same syntax but add the Boolean *true* as a value of the argument **create**. This ensures that a new child label will be created if none is found. Note that in the previous syntax, this was also the case since **create** is *true* by default. 
 
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
 TDF_Label level1 = root.FindChild(3,Standard_True); 
 TDF_Label level2 = level1.FindChild(1,Standard_True); 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 @subsubsection occt_ocaf_3_4_3 Retrieving child labels
 
 You can retrieve child labels of your current label by iteration on the first level in the scope of this label. 
 
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
 TDF_Label current; 
 // 
 for (TDF_ChildIterator it1 (current,Standard_False); it1.More(); it1.Next()) { 
@@ -362,20 +362,20 @@ achild = it1.Value();
 // do something on a child (level 1) 
 // 
 } 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 You can also retrieve all child labels in every descendant generation of your current label by iteration on all levels in the scope of this label. 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
 for (TDF_ChildIterator itall (current,Standard_True); itall.More(); itall.Next()) { 
 achild = itall.Value(); 
 // 
 // do something on a child (all levels) 
 // 
 } 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 Using *TDF_Tool::Entry* with *TDF_ChildIterator* you can retrieve the entries of your current label’s child labels as well. 
 
  
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
 void DumpChildren(const TDF_Label& aLabel) 
 { 
   TDF_ChildIterator it; 
@@ -385,16 +385,16 @@ void DumpChildren(const TDF_Label& aLabel)
     cout  <<  as.ToCString()  <<  endl; 
   } 
 } 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 @subsubsection occt_ocaf_3_4_4 Retrieving the father label
 
 Retrieving the father label of a current label. 
 
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
 TDF_Label father = achild.Father(); 
 isroot = father.IsRoot(); 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 @subsection occt_ocaf_3_5 Attribute
 
@@ -407,7 +407,7 @@ The advantage of OCAF is that all of the above attribute types are handled in th
 To retrieve an attribute from a label, you use *TDF_Label::FindAttribute*. In the example below, the GUID for integer attributes, and *INT*, a handle to an attribute are passed as arguments to *FindAttribute* for the current label. 
 
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
 if(current.FindAttribute(TDataStd_Integer::GetID(),INT)) 
 { 
   // the attribute is found 
@@ -416,16 +416,16 @@ else
 { 
   // the attribute is not found 
 } 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 @subsubsection occt_ocaf_3_5_2 Identifying an attribute using a GUID
 
 You can create a new instance of an attribute and retrieve its GUID. In the example below, a new integer attribute is created, and its GUID is passed to the variable *guid* by the method ID inherited from *TDF_Attribute*. 
 
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
 Handle(TDataStd_Integer) INT = new TDataStd_Integer(); 
 Standard_GUID guid = INT->ID(); 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 @subsubsection occt_ocaf_3_5_3 Attaching an attribute to a label
 
@@ -434,11 +434,11 @@ To attach an attribute to a label, you use *TDF_Label::Add*. Repetition of this
 *TDF_Attribute::Label* for *INT* then returns the label *attach* to which *INT* is attached. 
 
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
 current.Add (INT); // INT is now attached to current 
 current.Add (INT); // causes failure 
 TDF_Label attach = INT->Label(); 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 Note. There is an exception from this rule for some sub-set of Standard attributes. See for details chapter 6.Standard Attributes.
 
@@ -449,7 +449,7 @@ You can test whether an attribute is attached to a label or not by using *TDF_At
 *TDF_Attribute::HasAttribute* tests whether there is an attached attribute, and *TDF_Tool::NbAttributes* returns the number of attributes attached to the label in question, e.g. *current*. 
 
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
 // Testing of attribute attachment 
 // 
 if (current.IsA(TDataStd_Integer::GetID())) { 
@@ -460,18 +460,18 @@ if (current.HasAttribute()) {
 Standard_Integer nbatt = current.NbAttributes(); 
 // the label has nbatt attributes attached 
 } 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 @subsubsection occt_ocaf_3_5_5 Removing an attribute from a label
 
 To remove an attribute from a label, you use *TDF_Label::Forget* with the GUID of the deleted attribute. To remove all attributes of a label, *TDF_Label::ForgetAll*. 
 
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
 current.Forget(TDataStd_Integer::GetID()); 
 // integer attribute is now not attached to current label 
 current.ForgetAll(); 
 // current has now 0 attributes attached 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 @subsubsection occt_ocaf_3_5_6 Specific attribute creation
 
 If the set of existing and ready to use attributes implementing standard data types does  not cover the needs of a specific data presentation task, the user can build his own data type and the corresponding new specific attribute implementing this new data type. 
@@ -603,18 +603,18 @@ As a container for your data framework, you need a document, and your document m
 
 To create an application, use the following syntax. 
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
 Handle(TDocStd_Application) app = new TDocStd_Application (); 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 @subsubsection occt_ocaf_4_2_2 Creating a new document
 
 To the application which you declared in the previous example (4.2.1), you must add the document *doc* as an argument of *TDocStd_Application::NewDocument*. 
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
 Handle(TDocStd_Document) doc; 
 app->NewDocument("NewDocumentFormat", doc); 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 Here "NewDocumentFormat" is identifier of the format of your document.
 OCCT defines several standard formats, distinguishing by a set of supported OCAF attributes, and method of encoding (e.g. binary data or XML), described below.
@@ -624,9 +624,9 @@ If your application defines specific OCAF attributes, you need to define your ow
 
 To retrieve the application containing your document, you use the syntax below. 
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
 app = Handle(TDocStd_Application)::DownCast (doc->Application()); 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 @subsection occt_ocaf_4_3 The Document
 
 The document contains your data framework, and allows you to retrieve this framework, recover its main label, save it in a file, and open or close this file. 
@@ -635,15 +635,15 @@ The document contains your data framework, and allows you to retrieve this frame
 
 To access the main label in the data framework, you use *TDocStd_Document::Main* as in the example below. The main label is the first child of the root label in the data framework, and has the entry 0:1. 
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
 TDF_Label label = doc->Main(); 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 @subsubsection occt_ocaf_4_3_2 Retrieving the document from a label in its framework
 
 To retrieve the document from a label in its data framework, you use *TDocStd_Document::Get* as in the example below. The argument *label* passed to this method is an instantiation of *TDF_Label*. 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
 doc = TDocStd_Document::Get(label); 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 @subsubsection occt_ocaf_4_3_format Defining storage format
 
@@ -651,11 +651,11 @@ OCAF uses a customizable mechanism for storage of the documents.
 In order to use OCAF persistence to save and read your documents to / from the file, you need to define one or several formats in your application.
 
 For that, use method TDocStd_Application::DefineFormat(), for instance:
-~~~~~
+~~~~{.cpp}
 app->DefineFormat ("NewDocumentFormat", "New format for OCAF documents", "ndf",
                    new NewDocumentFormat_RetrievalDriver(),
                    new NewDocumentFormat_StorageDriver());
-~~~~~
+~~~~
 
 This example defines format "NewDocumentFormat" with a default file extension "ndf", and instantiates drivers for reading and storing documents from and to that format.
 Either of the drivers can be null, in this case the corresponding action will not be supported for that format.
@@ -682,9 +682,9 @@ OCAF provides several standard formats, each covering some set of OCAF attribute
 For convenience, these toolkits provide static methods *DefineFormat()* accepting handle to application.
 These methods allow defining corresponding formats easily, e.g.:
 
-~~~~~
+~~~~{.cpp}
 BinDrivers::DefineFormat (app); // define format "BinOcaf"
-~~~~~
+~~~~
 
 Use these toolkits as an example for implementation of persistence drivers for custom attributes, or new persistence formats.
 
@@ -703,47 +703,47 @@ That method should return a string with a name of resource file, e.g. "NewDocume
 
 Then create that resource file and define the parameters of your format:
 
-~~~~~
+~~~~
 ndf.FileFormat: NewDocumentFormat
 NewDocumentFormat.Description: New Document Format Version 1.0 
 NewDocumentFormat.FileExtension: ndf 
 NewDocumentFormat.StoragePlugin: bb5aa176-c65c-4c84-862e-6b7c1fe16921
 NewDocumentFormat.RetrievalPlugin: 76fb4c04-ea9a-46aa-88a2-25f6a228d902 
-~~~~~
+~~~~
 
 The GUIDs should be unique and correspond to the GUIDs supported by relevant plugin.
 You can use an existing plugins (see the table above) or create your own.
 
 Finally, make a copy of the resource file "Plugin" from *$CASROOT/src/StdResource* and, if necessary, add the definition of your plugin in it, for instance:
 
-~~~~~
+~~~~
 bb5aa176-c65c-4c84-862e-6b7c1fe16921.Location: TKNewFormat
 76fb4c04-ea9a-46aa-88a2-25f6a228d902.Location: TKNewFormat
-~~~~~
+~~~~
 
 In order to have these resource files loaded during the program execution, it is necessary to set two environment variables: *CSF_PluginDefaults* and *CSF_NewFormatDefaults*.
 For example, set the files in the directory *MyApplicationPath/MyResources*: 
 
-~~~~~
+~~~~
 setenv CSF_PluginDefaults MyApplicationPath/MyResources 
 setenv CSF_NewFormatDefaults MyApplicationPath/MyResources 
-~~~~~
+~~~~
 
 @subsubsection occt_ocaf_4_3_3 Saving a document
 
 To save the document, make sure that its parameter *StorageFormat()* corresponds to one of the formats defined in the application, and use method *TDocStd_Application::SaveAs*, for instance: 
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
 app->SaveAs(doc, "/tmp/example.caf"); 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 @subsubsection occt_ocaf_4_3_4 Opening the document from a file
 
 To open the document from a file where it has been previously saved, you can use *TDocStd_Application::Open* as in the example below. The arguments are the path of the file and the document saved in this file. 
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~
 app->Open("/tmp/example.caf", doc); 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 @subsubsection occt_ocaf_4_3_5 Cutting, copying and pasting inside a document
 
@@ -755,7 +755,7 @@ copy operation (say, in <i> Lab_Clipboard</i>). You must also define two other l
 * The data container (e.g. <i> Lab_source</i>)
 * The destination of the copy (e.g. <i> Lab_ Target</i> )
 
-~~~~
+~~~~{.cpp}
     Copy = copy (Lab_Source => Lab_Clipboard)
     Cut = copy + Lab_Source.ForgetAll() // command clear the contents of LabelSource.
     Paste = copy (Lab_Clipboard => Lab_target)
@@ -764,7 +764,7 @@ copy operation (say, in <i> Lab_Clipboard</i>). You must also define two other l
 So we need a tool to copy all (or a part) of the content of a label and its sub-label,
 to another place defined by a label.
 
-~~~~
+~~~~{.cpp}
     TDF_CopyLabel aCopy;
     TDF_IDFilter aFilter (Standard_False);
 
@@ -796,7 +796,7 @@ Note that documents can be copied with or without a possibility of updating an e
 
 To copy a document with a possibility of updating it later, you use *TDocStd_XLinkTool::CopyWithLink*. 
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
 Handle(TDocStd_Document) doc1; 
 Handle(TDocStd_Document) doc2; 
 
@@ -805,24 +805,24 @@ TDF_Label target = doc2->GetData()->Root();
 TDocStd_XLinkTool XLinkTool; 
 
 XLinkTool.CopyWithLink(target,source); 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 Now the target document has a copy of the source document. The copy also has a link in order to update the content of the copy if the original changes. 
 
 In the example below, something has changed in the source document. As a result, you need to update the copy in the target document. This copy is passed to *TDocStd_XLinkTool::UpdateLink* as the argument *target*. 
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
 XLinkTool.UpdateLink(target); 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 #### Without any link between the copy and the original
 
 You can also create a copy of the document with no link between the original and the copy. The syntax to use this option is *TDocStd_XLinkTool::Copy*. The copied document is again represented by the argument *target*, and the original -- by *source.* 
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
 XLinkTool.Copy(target, source); 
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 
 @section occt_ocaf_5 OCAF Shape Attributes
@@ -886,7 +886,7 @@ Only pairs of shapes with equal evolution can be stored in one named shape.
 
 The class *TNaming_Builder* allows creating a named shape attribute. It has a label of a future attribute as an argument of the constructor. Respective methods are used for the evolution and setting of shape pairs. If for the same TNaming_Builder object a lot of pairs of shapes with the same evolution are given, then these pairs would be placed in the resulting named shape. After the creation of a new object of the TNaming_Builder class, an empty named shape is created at the given label. 
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
 // a new empty named shape is created at "label" 
 TNaming_Builder builder(label); 
 // set a pair of shapes with evolution GENERATED 
@@ -895,7 +895,7 @@ builder.Generated(oldshape1,newshape1);
 builder.Generated(oldshape2,newshape2); 
 // get the result - TNaming_NamedShape attribute 
 Handle(TNaming_NamedShape) ns = builder.NamedShape(); 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 @subsection occt_ocaf_5_5 Reading the contents of a named shape attribute
 
@@ -908,7 +908,7 @@ More detailed information about the contents of the named shape or about the mod
        * The method <i>NamedShape(TopoDS_Shape,TDF_Label) </i> returns a named shape, which contains a given shape as a new shape. A given label is any label from the data framework -- it just gives access to it.
 * *TNaming_Iterator* gives access to the named shape and hooks pairs.
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
 // create an iterator for a named shape 
 TNaming_Iterator iter(namedshape); 
 // iterate while some pairs are not iterated 
@@ -922,7 +922,7 @@ TopoDS_Shape oldshape = iter.OldShape();
 // go to the next pair 
 iter.Next(); 
 } 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 
 @subsection occt_ocaf_5_6 Topological naming
@@ -979,7 +979,7 @@ The class *TNaming_Tool* provides a toolkit to read current data contained in th
 
 If you need to create a topological attribute for existing data, use the method *NamedShape*. 
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
 class MyPkg_MyClass 
 { 
 public: Standard_Boolean SameEdge (const Handle(CafTest_Line)& L1, const Handle(CafTest_Line)& L2); 
@@ -991,7 +991,7 @@ Standard_Boolean CafTest_MyClass::SameEdge (const Handle(CafTest_Line)& L1, cons
   Handle(TNaming_NamedShape) NS2 = L2->NamedShape(); 
   return BRepTools::Compare(NS1,NS2); 
 } 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 
 @subsection occt_ocaf_5_8 Example of topological naming usage
@@ -1139,7 +1139,7 @@ To access the GUID of an attribute, you can use two methods:
   
 To find an attribute attached to a specific label, you use the GUID of the attribute type you are looking for. This information can be found using the method  <i> GetID</i> and the method <i> Find</i> for the label as follows:
 
-~~~~
+~~~~{.cpp}
     Standard_GUID anID = MyAttributeClass::GetID();
     Standard_Boolean HasAttribute = aLabel.Find(anID,anAttribute);
 ~~~~
@@ -1264,16 +1264,16 @@ It is possible to describe any model by means of standard OCAF attributes.
  Let's consider it on the example of the TDataStd_Real attribute. The previous version of the attribute allowed to set the attribute using 
  static method Set in next way:
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
 static Handle(TDataStd_Real) Set (const TDF_Label& label, const Standard_Real value);
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
  This is a default form which is kept by the attribute. It uses the default GUID for the attribute identification - TDataStd_Real::GetID(). 
  In case if you want to use the new feature (user defined Real attribute), for example to define several attributes which should keep a value 
  of the same type - Standard_Real, but to be associated with different user's notions (or objects) the new static method Set should be used. 
  In our example we will define two Real attributes which presents two customer's objects - Density and Volume and will be put on the same Label.
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
 #define DENSITY Standard_GUID("12e9454b-6dbc-11d4-b9c8-0060b0ee2810")
 #define VOLUME  Standard_GUID("161595c0-3628-4737-915a-c160ce94c6f7")
 
@@ -1288,28 +1288,28 @@ TDataStd_Real::Set(aLabel, VOLUME, 185.5);
  To find an user defined Real attribute just use a corresponding GUID:
 Handle (TDataStd_Real) anAtt;
 aLabel.FindAttribute (DENSITY, anAtt);
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
   @subsection occt_ocaf_6_4_1  Creation Attributes with User Defined GUID.
 
  You can create a new instance of an attribute with user define GUID and add it to label in two ways.
  1. Using static method Set(). For example:
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
     TDF_Label aLabel = ...;
     Standard_Integer aValue = ...;
     Standard_GUID aGuid = TDataStd_Integer::GetID();
     TDataStd_Integer::Set(aLabel, aGuid, aValue);
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
  2. Using the default constructor
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
     Handle(TDataStd_Integer) anInt = new TDataStd_Integer();
     anInt->SetID(aGuid);
     aLabel.Add(anInt);
     anInt->Set(aValue);
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
     
 @section occt_ocaf_7 Visualization Attributes
@@ -1326,10 +1326,10 @@ The class *TPrsStd_AISViewer* allows you to define an interactive viewer attribu
 
 To initialize the AIS viewer as in the example below, use method *Find*. 
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
 // "access" is any label of the data framework 
 Handle(TPrsStd_AISViewer) viewer = TPrsStd_AISViewer::Find(access) 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 @subsection occt_ocaf_7_2_2 Defining a presentation attribute
 
@@ -1351,12 +1351,12 @@ You frequently need a container for different presentation drivers. The class *T
 To fill a driver table with standard drivers, first initialize the AIS viewer as in the example above, and then pass the return value of the method *InitStandardDrivers* to the driver table returned by the method *Get*. Then attach a *TNaming_NamedShape* to a label and set the named shape in the presentation attribute using the method *Set*. Then attach the presentation attribute to the named shape attribute, and the *AIS_InteractiveObject*, which the presentation attribute contains, will initialize its drivers for the named shape. This can be seen in the example below. 
 
 **Example** 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
 DriverTable::Get() -> InitStandardDrivers(); 
 // next, attach your named shape to a label 
 TPrsStd_AISPresentation::Set(NS}; 
 // here, attach the AISPresentation to NS. 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 
 @section occt_ocaf_8 Function Services
@@ -1560,7 +1560,7 @@ To automatically erase the nail from the viewer and the data  tree it is enough
 
   This is an example of the code for iteration and execution of functions.  
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
 
 // The scope of functions is defined.
 Handle(TFunction_Scope) aScope = TFunction_Scope::Set (anyLabel);
@@ -1602,13 +1602,13 @@ for (; anIterator.more(); anIterator.Next())
   }
 }
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 @subsection occt_ocaf_8a_6 Example 2: Cylinder function driver
 
   This is an example of the code for a cylinder function driver. To make the things clearer, the methods <i>\::Arguments()</i>  and <i>\::Results()</i>  from the base class are also mentioned.   
 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
 
     // A virtual method  ::Arguments() returns a list of arguments of the function.  
     CylinderDriver::Arguments( TDF_LabelList&amp; args )  
@@ -1684,7 +1684,7 @@ for (; anIterator.more(); anIterator.Next())
        
       return 0;
     }
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
  
   
 
@@ -1772,7 +1772,7 @@ XML types for OCAF attributes are declared with XML W3C Schema in a few XSD file
 
 The following example is a sample text from an XML file obtained by storing an OCAF document with two labels (0: and 0:2) and two attributes -- *TDataStd_Name* (on label 0:) and *TNaming_NamedShape* (on label 0:2). The \<shapes\> section contents are replaced by an ellipsis. 
 
-~~~~
+~~~~{.cpp}
 <?xml version="1.0" encoding="UTF-8"?> 
 <document format="XmlOcaf" xmlns="http://www.opencascade.org/OCAF/XML" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
 xsi:schemaLocation="http://www.opencascade.org/OCAF/XML http://www.opencascade.org/OCAF/XML/XmlOcaf.xsd">
@@ -1923,18 +1923,18 @@ The default implementation works with a binary OCAF document format (*BinOcaf*).
 The other available format is *XmlOcaf*. The class **TObj_Model** declares and provides a default 
 implementation of two virtual methods: 
 
-~~~~~{.cpp}
+~~~~{.cpp}
     virtual Standard_Boolean Load (const char* theFile); 
     virtual Standard_Boolean SaveAs (const char* theFile); 
-~~~~~
+~~~~
 
 which retrieve and store the model from or 
 in the OCAF file. The descendants 
 should define the following protected method to support Load and Save operations:
 
-~~~~~{.cpp}
+~~~~{.cpp}
     virtual Standard_Boolean initNewModel (const Standard_Boolean IsNew); 
-~~~~~
+~~~~
 
 This method is called by *Load* after creation of a new model 
 or after its loading from the file; its purpose is to perform 
@@ -1972,34 +1972,34 @@ In this case the schema should be extended using the standard OCAF mechanism.
 All objects in the model are stored in the main partition and accessed by iterators.
 To access all model objects use: 
 
-~~~~~{.cpp}
+~~~~{.cpp}
     virtual Handle(TObj_ObjectIterator) GetObjects () const; 
-~~~~~
+~~~~
 
 This method returns a recursive iterator on all objects stored in the model.
 
-~~~~~{.cpp}
+~~~~{.cpp}
     virtual Handle(TObj_ObjectIterator) GetChildren () const; 
-~~~~~
+~~~~
 
 This method returns an iterator on child objects of the main partition.
 Use the following method to get the main partition: 
 
-~~~~~{.cpp}
+~~~~{.cpp}
     Handle(TObj_Partition) GetMainPartition() const; 
-~~~~~
+~~~~
 
 To receive the iterator on objects of a specific type *AType* use the following call: 
 
-~~~~~{.cpp}
+~~~~{.cpp}
     GetMainPartition()-&gt;GetChildren(STANDARD_TYPE(AType) ); 
-~~~~~
+~~~~
 
 The set of protected methods is provided for descendant classes to deal with partitions: 
 
-~~~~~{.cpp}
+~~~~{.cpp}
     virtual Handle(TObj_Partition) getPartition (const TDF_Label, const Standard_Boolean  theHidden) const; 
-~~~~~
+~~~~
 
 This method returns (creating if necessary) a partition in the specified label of the document. 
 The partition can be created as hidden (*TObj_HiddenPartition* class). 
@@ -2010,17 +2010,17 @@ The following two methods allow getting (creating) a partition
 in the sub-label of the specified label in the document 
 (the label of the main partition for the second method) and with the given name: 
 
-~~~~~{.cpp}
+~~~~{.cpp}
     virtual Handle(TObj_Partition) getPartition (const TDF_Label, const Standard_Integer theIndex, const TCollection_ExtendedString& theName, const Standard_Boolean  theHidden) const; 
     virtual Handle(TObj_Partition) getPartition (const Standard_Integer theIndex, const TCollection_ExtendedString& theName, const Standard_Boolean  theHidden) const; 
-~~~~~
+~~~~
 
 If the default object naming and the name register mechanism 
 is turned on, the object can be found in the model by its unique name: 
 
-~~~~~{.cpp}
+~~~~{.cpp}
     Handle(TObj_Object) FindObject (const Handle(TCollection_HExtendedString)& theName, const Handle(TObj_TNameContainer)& theDictionary) const; 
-~~~~~
+~~~~
 
 @subsubsection occt_tobj_2_5 Own model data
 
@@ -2045,31 +2045,31 @@ To ignore name registering it is necessary to redefine the methods *SetName*,
 *AfterRetrieval* of the *TObj_Object* class and skip the registration of the object name. 
 Use the following methods for the naming mechanism: 
 
-~~~~~{.cpp}
+~~~~{.cpp}
     Standard_Boolean IsRegisteredName (const Handle(TCollection_HExtendedString)& theName, const Handle(TObj_TNameContainer)& theDictionary ) const; 
-~~~~~
+~~~~
 
 Returns **True** if the object name is already registered in the indicated (or model) dictionary. 
 
-~~~~~{.cpp}
+~~~~{.cpp}
     void RegisterName (const Handle(TCollection_HExtendedString)& theName, const TDF_Label& theLabel, const Handle(TObj_TNameContainer)& theDictionary ) const; 
-~~~~~
+~~~~
 
 Registers the object name with the indicated label where the object 
 is located in the OCAF document. Note that the default implementation 
 of the method *SetName* of the object registers the new name automatically 
 (if the name is not yet registered for any other object) 
 
-~~~~~{.cpp}
+~~~~{.cpp}
     void UnRegisterName (const Handle(TCollection_HExtendedString)& theName, const Handle(TObj_TNameContainer)& theDictionary ) const; 
-~~~~~
+~~~~
 
 Unregisters the name from the dictionary.
 The names of *TObj* model objects are removed from the dictionary when the objects are deleted from the model.
 
-~~~~~{.cpp}
+~~~~{.cpp}
     Handle(TObj_TNameContainer) GetDictionary() const;
-~~~~~
+~~~~
 
 Returns a default instance of the model dictionary (located at the model root label). 
 The default implementation works only with one dictionary. 
@@ -2081,39 +2081,39 @@ that returns the dictionary where names of objects should be registered.
 
 Class *TObj_Model* provides the API for transaction mechanism (supported by OCAF): 
 
-~~~~~{.cpp}
+~~~~{.cpp}
     Standard_Boolean HasOpenCommand() const; 
-~~~~~
+~~~~
 
 Returns True if a Command transaction is open 
 
-~~~~~{.cpp}
+~~~~{.cpp}
     void OpenCommand() const; 
-~~~~~
+~~~~
 
 Opens a new command transaction. 
 
-~~~~~{.cpp}
+~~~~{.cpp}
     void CommitCommand() const; 
-~~~~~
+~~~~
 
 Commits the Command transaction. Does nothing If there is no open Command transaction. 
 
-~~~~~{.cpp}
+~~~~{.cpp}
     void AbortCommand() const; 
-~~~~~
+~~~~
 
 Aborts the Command transaction. Does nothing if there is no open Command transaction. 
 
-~~~~~{.cpp}
+~~~~{.cpp}
     Standard_Boolean IsModified() const; 
-~~~~~
+~~~~
 
 Returns True if the model document has a modified status (has changes after the last save) 
 
-~~~~~{.cpp}
+~~~~{.cpp}
     void SetModified( const Standard_Boolean ); 
-~~~~~
+~~~~
 
 Changes the modified status by force. For synchronization of transactions 
 within several *TObj_Model* documents use class *TDocStd_MultiTransactionManager*. 
@@ -2123,9 +2123,9 @@ within several *TObj_Model* documents use class *TDocStd_MultiTransactionManager
 Class *TObj_Model* provides the descendant classes with a means to control 
 the format of the persistent file by choosing the schema used to store or retrieve operations. 
 
-~~~~~{.cpp}
+~~~~{.cpp}
     virtual TCollection_ExtendedString GetFormat () const; 
-~~~~~
+~~~~
 
 Returns the string *TObjBin* or *TObjXml* indicating 
 the current persistent mechanism. The default value is *TObjBin*. 
@@ -2139,15 +2139,15 @@ should be enumerated in increasing order, incremented with every change
 of the model format. The current version of the model 
 format is stored in the model file and can be checked upon retrieval. 
 
-~~~~~{.cpp}
+~~~~{.cpp}
     Standard_Integer GetFormatVersion() const; 
-~~~~~
+~~~~
 
 Returns the format version stored in the model file 
 
-~~~~~{.cpp}
+~~~~{.cpp}
     void SetFormatVersion(const Standard_Integer theVersion); 
-~~~~~
+~~~~
 
 Defines the format version used for save. 
 
@@ -2179,22 +2179,22 @@ If the format of data files changes, a specific treatment on a case-by-case basi
 The following methods are used for model update to ensure its consistency 
 with respect to the other models in case of cross-model dependencies: 
 
-~~~~~{.cpp}
+~~~~{.cpp}
     virtual Standard_Boolean Update(); 
-~~~~~
+~~~~
 
 This method is usually called after loading of the model. 
 The default implementation does nothing and returns **True**. 
 
-~~~~~{.cpp}
+~~~~{.cpp}
     virtual Standard_Boolean initNewModel( const Standard_Boolean IsNew); 
-~~~~~
+~~~~
 
 This method performs model initialization, check and updates (as described above). 
 
-~~~~~{.cpp}
+~~~~{.cpp}
     virtual void updateBackReferences( const Handle(TObj_Object)& theObj); 
-~~~~~
+~~~~
 
 This method is called from the previous method to update back references 
 of the indicated object after the retrieval of the model from file 
@@ -2204,23 +2204,23 @@ of the indicated object after the retrieval of the model from file
 
 To copy the model between OCAF documents use the following methods: 
 
-~~~~~{.cpp}
+~~~~{.cpp}
     virtual Standard_Boolean Paste (Handle(TObj_Model) theModel, Handle(TDF_RelocationTable) theRelocTable = 0 ); 
-~~~~~
+~~~~
 
 Pastes the current model to the new model. The relocation table 
 ensures correct copying of the sub-data shared by several parts of the model. 
 It stores a map of processed original objects of relevant types in their copies. 
 
-~~~~~{.cpp}
+~~~~{.cpp}
     virtual Handle(TObj_Model) NewEmpty() = 0; 
-~~~~~
+~~~~
 
 Redefines a pure virtual method to create a new empty instance of the model. 
 
-~~~~~{.cpp}
+~~~~{.cpp}
     void CopyReferences ( const Handle(TObj_Model)& theTarget, const Handle(TDF_RelocationTable)& theRelocTable); 
-~~~~~
+~~~~
 
 Copies the references from the current model to the target model. 
 
@@ -2230,10 +2230,10 @@ The messaging is organised using Open CASCADE Messenger from the package Message
 The messenger is stored as the field of the model instance 
 and can be set and retrieved by the following methods: 
 
-~~~~~{.cpp}
+~~~~{.cpp}
     void SetMessenger( const Handle(Message_Messenger)& ); 
     Handle(Message_Messenger) Messenger() const; 
-~~~~~
+~~~~
 
 A developer should create his own instance of the Messenger 
 bound to the application user interface, and attribute it to the model 
@@ -2298,15 +2298,15 @@ The *TObj_Object* class provides some basic features that can be inherited (or,
 
 An object can be received from the model by the following methods: 
 
-~~~~~{.cpp}
+~~~~{.cpp}
     static Standard_Boolean GetObj ( const TDF_Label& theLabel, Handle(TObj_Object)& theResObject, const Standard_Boolean isSuper = Standard_False ); 
-~~~~~
+~~~~
 
 Returns *True* if the object has been found in the indicated label (or in the upper level label if *isSuper* is *True*). 
 
-~~~~~{.cpp}
+~~~~{.cpp}
     Handle(TObj_Object) GetFatherObject ( const Handle(Standard_Type)& theType = NULL ) const; 
-~~~~~
+~~~~
 
 Returns the father object of the indicated type 
 for the current object (the direct father object if the type is NULL). 
@@ -2332,10 +2332,10 @@ See the declaration of the TObj_Partition class for the example.
 *TObj_Object* class provides a set of auxiliary methods for descendants 
 to access the data stored in sub-labels by their tag numbers: 
 
-~~~~~{.cpp}
+~~~~{.cpp}
     TDF_Label getDataLabel (const Standard_Integer theRank1, const Standard_Integer theRank2 = 0) const; 
     TDF_Label getReferenceLabel (const Standard_Integer theRank1, const Standard_Integer theRank2 = 0) const; 
-~~~~~
+~~~~
 
 Returns the label in *Data* or *References* sub-labels at a given tag number (theRank1). 
 The second argument, theRank2, allows accessing the next level of hierarchy 
@@ -2348,23 +2348,23 @@ for the most widely used data types (*Standard_Real*, *Standard_Integer*, *TColl
  *TColStd_HArray1OfReal*, *TColStd_HArray1OfInteger*, *TColStd_HArray1OfExtendedString*). 
 For instance, methods provided for real numbers are: 
 
-~~~~~{.cpp}
+~~~~{.cpp}
     Standard_Real getReal (const Standard_Integer theRank1, const Standard_Integer theRank2 = 0) const; 
     Standard_Boolean setReal (const Standard_Real theValue, const Standard_Integer theRank1, const Standard_Integer theRank2 = 0, const Standard_Real theTolerance = 0.) const; 
-~~~~~
+~~~~
 
 Similar methods are provided to access references to other objects: 
 
-~~~~~{.cpp}
+~~~~{.cpp}
     Handle(TObj_Object) getReference (const Standard_Integer theRank1, const Standard_Integer theRank2 = 0) const; 
     Standard_Boolean setReference (const Handle(TObj_Object) &theObject, const Standard_Integer theRank1, const Standard_Integer theRank2 = 0); 
-~~~~~
+~~~~
 
 The method *addReference* gives an easy way to store a sequence of homogeneous references in one label. 
 
-~~~~~{.cpp}
+~~~~{.cpp}
     TDF_Label addReference (const Standard_Integer theRank1, const Handle(TObj_Object) &theObject); 
-~~~~~
+~~~~
 
 Note that while references to other objects should be defined by descendant classes 
 individually according to the type of object, *TObj_Object* provides methods 
@@ -2388,18 +2388,18 @@ The class *TObj_Persistence* provides basic means for that:
 Two macros defined in the file TObj_Persistence.hxx have to be included in the definition 
 of each model object class inheriting TObj_Object to activate the persistence mechanism: 
 
-~~~~~{.cpp}
+~~~~{.cpp}
     DECLARE_TOBJOCAF_PERSISTENCE (classname, ancestorname) 
-~~~~~
+~~~~
 
 Should be included in the private section of declaration of each class inheriting 
 *TObj_Object* (hxx file). This macro adds an additional constructor to the object class, 
 and declares an auxiliary (private) class inheriting *TObj_Persistence* 
 that provides a tool to create a new object of the proper type. 
 
-~~~~~{.cpp}
+~~~~{.cpp}
     IMPLEMENT_TOBJOCAF_PERSISTENCE (classname) 
-~~~~~
+~~~~
 
 Should be included in .cxx file of each object class that should be saved and restored. 
 This is not needed for abstract types of objects. This macro implements the functions 
@@ -2426,26 +2426,26 @@ If necessary, it is easy to redefine a couple of object methods
 
 This functionality is provided by the following methods: 
 
-~~~~~{.cpp}
+~~~~{.cpp}
     virtual Handle(TObj_TNameContainer) GetDictionary() const; 
-~~~~~
+~~~~
 
 Returns the name container where the name of object should be registered. 
 The default implementation returns the model name container. 
 
-~~~~~{.cpp}
+~~~~{.cpp}
     Handle(TCollection_HExtendedString) GetName() const; 
     Standard_Boolean GetName( TCollection_ExtendedString& theName ) const; 
     Standard_Boolean GetName( TCollection_AsciiString& theName ) const; 
-~~~~~
+~~~~
 
 Returns the object name. The methods with in / out argument return False if the object name is not defined. 
 
-~~~~~{.cpp}
+~~~~{.cpp}
     virtual Standard_Boolean SetName ( const Handle(TCollection_HExtendedString)& theName ) const; 
     Standard_Boolean SetName         ( const Handle(TCollection_HAsciiString)& theName ) const; 
     Standard_Boolean SetName         ( const Standard_CString theName ) const; 
-~~~~~
+~~~~
 
 Attributes a new name to the object and returns **True** if the name has been attributed successfully. 
 Returns False if the name has been already attributed to another object. 
@@ -2474,57 +2474,57 @@ from different *TObj* models, facilitating the construction of complex relations
 
 The most used methods for work with references are: 
 
-~~~~~{.cpp}
+~~~~{.cpp}
     virtual Standard_Boolean HasReference( const Handle(TObj_Object)& theObject) const; 
-~~~~~
+~~~~
 
 Returns True if the current object refers to the indicated object. 
 
-~~~~~{.cpp}
+~~~~{.cpp}
     virtual Handle(TObj_ObjectIterator) GetReferences ( const Handle(Standard_Type)& theType = NULL ) const; 
-~~~~~
+~~~~
 
 Returns an iterator on the object references. The optional argument *theType* 
 restricts the types of referred objects, or does not if it is NULL. 
 
-~~~~~{.cpp}
+~~~~{.cpp}
     virtual void RemoveAllReferences(); 
-~~~~~
+~~~~
 
 Removes all references from the current object. 
 
-~~~~~{.cpp}
+~~~~{.cpp}
     virtual void RemoveReference( const Handle(TObj_Object)& theObject ); 
-~~~~~
+~~~~
 
 Removes the reference to the indicated object. 
 
-~~~~~{.cpp}
+~~~~{.cpp}
     virtual Handle(TObj_ObjectIterator) GetBackReferences ( const Handle(Standard_Type)& theType = NULL ) const; 
-~~~~~
+~~~~
 
 Returns an iterator on the object back references. 
 The argument theType restricts the types of master objects, or does not if it is NULL. 
 
-~~~~~{.cpp}
+~~~~{.cpp}
     virtual void ReplaceReference  ( const Handle(TObj_Object)& theOldObject,  const Handle(TObj_Object)& theNewObject ); 
-~~~~~
+~~~~
 
 Replaces the reference to theOldObject by the reference to *theNewObject*. 
 The handle theNewObject may be NULL to remove the reference. 
 
-~~~~~{.cpp}
+~~~~{.cpp}
     virtual Standard_Boolean RelocateReferences  ( const TDF_Label& theFromRoot,  const TDF_Label& theToRoot, const Standard_Boolean theUpdateackRefs = Standard_True ); 
-~~~~~
+~~~~
 
 Replaces all references to a descendant label of *theFromRoot* 
 by the references to an equivalent label under *theToRoot*. 
 Returns **False** if the resulting reference does not point at a *TObj_Object*. 
 Updates back references if theUpdateackRefs is **True**. 
 
-~~~~~{.cpp}
+~~~~{.cpp}
     virtual Standard_Boolean CanRemoveReference ( const Handle(TObj_Object)& theObj) const; 
-~~~~~
+~~~~
 
 Returns **True** if the reference can be removed and the master object 
 will remain valid (*weak* reference). 
@@ -2567,15 +2567,15 @@ but the behavior depends on the deletion mode *TObj_DeletingMode*:
 
 The most used methods for object removing are: 
 
-~~~~~{.cpp}
+~~~~{.cpp}
     virtual Standard_Boolean CanDetachObject (const TObj_DeletingMode theMode = TObj_FreeOnly ); 
-~~~~~
+~~~~
 
 Returns **True** if the object can be deleted with the indicated deletion mode. 
 
-~~~~~{.cpp}
+~~~~{.cpp}
     virtual Standard_Boolean Detach ( const TObj_DeletingMode theMode = TObj_FreeOnly ); 
-~~~~~
+~~~~
 
 Removes the object from the document if possible 
 (according to the indicated deletion mode). 
@@ -2586,32 +2586,32 @@ Returns **True** if the objects have been successfully deleted.
 
 *TObj_Object* provides a number of special virtual methods  to support replications of objects. These methods should be redefined by descendants when necessary. 
 
-~~~~~{.cpp}
+~~~~{.cpp}
     virtual Handle(TObj_Object) Clone (const TDF_Label& theTargetLabel, Handle(TDF_RelocationTable) theRelocTable = 0); 
-~~~~~
+~~~~
 
 Copies the object to theTargetLabel. The new object will have all references of its original. 
 Returns a handle to the new object (null handle if fail). The data are copied directly, 
 but the name is changed by adding the postfix *_copy*. 
 To assign different names to the copies redefine the method: 
 
-~~~~~{.cpp}
+~~~~{.cpp}
     virtual Handle(TCollection_HExtendedString) GetNameForClone ( const Handle(TObj_Object)& ) const; 
-~~~~~
+~~~~
 
 Returns the name for a new object copy. It could be useful to return the same object name 
 if the copy will be in the other model or in the other partition with its own dictionary. 
 The method *Clone* uses the following public methods for object data replications: 
 
-~~~~~{.cpp}
+~~~~{.cpp}
     virtual void CopyReferences (const const Handle(TObj_Object)& theTargetObject, const Handle(TDF_RelocationTable) theRelocTable); 
-~~~~~
+~~~~
 
 Adds to the copy of the original object its references. 
 
-~~~~~{.cpp}
+~~~~{.cpp}
     virtual void CopyChildren (TDF_Label& theTargetLabel, const Handle(TDF_RelocationTable) theRelocTable); 
-~~~~~
+~~~~
 
 Copies the children of an object to the target child label. 
 
@@ -2630,20 +2630,20 @@ which facilitate the storage of auxiliary logical information assigned to the ob
 The user (developer) can define any new flags in descendant classes. 
 To set/get an object, the flags use the following methods: 
 
-~~~~~{.cpp}
+~~~~{.cpp}
     Standard_Integer GetFlags() const; 
     void SetFlags( const Standard_Integer theMask ); 
     Stadnard_Boolean TestFlags( const Standard_Integer theMask ) const; 
     void ClearFlags( const Standard_Integer theMask = 0 ); 
-~~~~~
+~~~~
 
 In addition, the generic virtual interface stores the logical properties 
 of the object class in the form of a set of bit flags. 
 Type flags can be received by the method: 
 
-~~~~~{.cpp}
+~~~~{.cpp}
     virtual Standard_Integer GetTypeFlags() const; 
-~~~~~
+~~~~
 
 The default implementation returns the flag **Visible** 
 defined in the enumeration *TypeFlags*. This flag is used to define visibility 
@@ -2661,39 +2661,39 @@ A hidden partition is a simple partition with a predefined hidden flag.
 
 The main partition object methods: 
 
-~~~~~{.cpp}
+~~~~{.cpp}
     TDF_Label NewLabel() const; 
-~~~~~
+~~~~
 
 Allocates and returns a new label for creation of a new child object. 
 
-~~~~~{.cpp}
+~~~~{.cpp}
     void SetNamePrefix  ( const Handle(TCollection_HExtendedString)& thePrefix); 
-~~~~~
+~~~~
 
 Defines the prefix for automatic generation of names of the newly created objects. 
 
-~~~~~{.cpp}
+~~~~{.cpp}
     Handle(TCollection_HExtendedString) GetNamePrefix() const; 
-~~~~~
+~~~~
 
 Returns the current name prefix. 
 
-~~~~~{.cpp}
+~~~~{.cpp}
     Handle(TCollection_HExtendedString) GetNewName ( const Standard_Boolean theIsToChangeCount) const; 
-~~~~~
+~~~~
 
 Generates the new name and increases the internal counter of child objects if theIsToChangeCount is **True**. 
 
-~~~~~{.cpp}
+~~~~{.cpp}
     Standard_Integer GetLastIndex() const; 
-~~~~~
+~~~~
 
 Returns the last reserved child index. 
 
-~~~~~{.cpp}
+~~~~{.cpp}
     void SetLastIndex( const Standard_Integer theIndex ); 
-~~~~~
+~~~~
 
 Sets the last reserved index. 
 
@@ -2749,9 +2749,9 @@ The *TObj* sources are distributed in the following packages:
        * Store the names of software extensions. 
 * **Driver** -- an abstract class, which defines the communications protocol with a system. 
 * **Entry** -- an ASCII character string containing the tag list of a label. For example:
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
 0:3:24:7:2:7 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 * **External links** -- references from one data structure to another data structure in another document. 
 To store these references properly, a label must also contain an external link attribute. 
@@ -2764,9 +2764,9 @@ To store these references properly, a label must also contain an external link a
 In C++, the application behavior is implemented in virtual functions redefined in these derived classes. This is known as overriding. 
 
 * **GUID** -- Global Universal ID. A string of 37 characters intended to uniquely identify an object. For example:
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
 2a96b602-ec8b-11d0-bee7-080009dc3333 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 * **Label** -- a point in the data framework, which allows data to be attached to it by means of attributes. It has a name in the form of an entry, which identifies its place in the data framework. 
 * **Modified label** -- containing attributes whose data has been modified. 
index a3bd8889b805194ec1ecbf075d1917e58c9fba01..fbe129932cb4b5f2bc183bb8e51dbe2bcb9836ee 100644 (file)
@@ -65,10 +65,10 @@ The status may contain a set of Boolean flags (internally represented by bits).
 
 It is possible to test the status for the presence of some flag(s), using Status...() method(s) provided by the class: 
 
-~~~~~
+~~~~{.cpp}
 if ( object.Status.. ( ShapeExtend_DONE ) ) {// something was done 
 } 
-~~~~~
+~~~~
 
 8 'DONE' and 8 'FAIL' flags, named ShapeExtend_DONE1 ... ShapeExtend_FAIL8, are defined for a detailed analysis of the encountered situation. Each method assigns its own meaning to each flag, documented in the header for that method. There are also three enumerative values used for testing several flags at a time: 
 * *ShapeExtend_OK*   --     if no flags have been set; 
@@ -131,32 +131,32 @@ The sequence of actions is as follows :
    In some cases using  only *ShapeFix_Shape* can be insufficient. It is possible to use tools for merging and removing small edges and fixing gaps between 2D and 3D curves.
 
 5. Create *ShapeFix_Wireframe* tool and initialize it by shape:
-~~~~~
+~~~~{.cpp}
 Handle(ShapeFix_Wirefarme) SFWF = new ShapeFix_Wirefarme(shape); 
 Or 
 Handle(ShapeFix_Wirefarme) SFWF = new ShapeFix_Wirefarme; 
 SFWF->Load(shape); 
-~~~~~
+~~~~
 6. Set the basic precision and the maximum allowed tolerance:
-~~~~~
+~~~~{.cpp}
 sfs->SetPrecision ( Prec ); 
 sfs->SetMaxTolerance ( maxTol ); 
-~~~~~
+~~~~
 See the description for *Prec* and *maxTol* above. 
 7. Merge and remove small edges:
-~~~~~
+~~~~{.cpp}
 SFWF->DropSmallEdgesMode() = Standard_True; 
 SFWF->FixSmallEdges(); 
-~~~~~
+~~~~
 **Note:** Small edges are not removed with the default mode, but in many cases removing small edges is very useful for fixing a shape. 
 8. Fix gaps for 2D and 3D curves
-~~~~~
+~~~~{.cpp}
 SFWF->FixWireGaps(); 
-~~~~~
+~~~~
 9. Get the result
-~~~~~
+~~~~{.cpp}
 TopoDS_Shape Result = SFWF->Shape(); 
-~~~~~
+~~~~
 
 
 @subsection occt_shg_2_2 Shape Correction.
@@ -175,7 +175,7 @@ If you want to make a fix on one sub-shape of a certain shape it is possible to
 
 For example, in the following way it is possible to fix face *Face1* of shape *Shape1*: 
 
-~~~~~
+~~~~{.cpp}
 //create tools for fixing a face 
 Handle(ShapeFix_Face)  SFF= new ShapeFix_Face; 
 
@@ -195,7 +195,7 @@ SFF->Perform();
 //get the result 
 TopoDS_Shape  NewShape = Context->Apply(Shape1); 
 //Resulting shape contains the fixed face. 
-~~~~~
+~~~~
 
 A set of required fixes and invalid sub-shapes can be obtained with the help of tools responsible for the analysis of shape validity (section 3.2). 
 
@@ -219,14 +219,14 @@ The following sequence of actions should be applied to perform fixes:
 6. Get the result in two ways : 
        - with help of a special method *Shape(),Face(),Wire().Edge()*. 
        - from the rebuilding tool by method *Apply* (for access to rebuilding tool use method *Context()*): 
-~~~~~
+~~~~{.cpp}
        TopoDS_Shape resultShape = fixtool->Context()->Apply(initialShape); 
-~~~~~
+~~~~
 Modification fistory for the shape and its sub-shapes can be obtained from the tool for shape re-building (*ShapeBuild_ReShape*). 
 
-~~~~~
+~~~~{.cpp}
 TopoDS_Shape modifsubshape = fixtool->Context() -> Apply(initsubshape); 
-~~~~~
+~~~~
 
  
 @subsubsection occt_shg_2_3_2 Flags Management
@@ -235,12 +235,12 @@ The flags *Fix...Mode()* are used to control the execution of fixing procedures
 
 For example, it is possible to forbid performing fixes to remove small edges - *FixSmall* 
 
-~~~~~
+~~~~{.cpp}
 Handle(ShapeFix_Shape) Sfs = new ShapeFix_Shape(shape); 
 Sfs-> FixWireTool ()->FixSmallMode () =0; 
 if(Sfs->Perform()) 
        TopoDS_Shape resShape = Sfs->Shape(); 
-~~~~~
+~~~~
 
 
 @subsubsection occt_shg_2_3_3 Repairing tool for shapes
@@ -249,7 +249,7 @@ Class *ShapeFix_Shape* allows using repairing tools for all sub-shapes of a shap
 
 For example, it is possible to force the removal of invalid 2D curves from a face. 
 
-~~~~~
+~~~~{.cpp}
 TopoDS_Face face … // face with invalid 2D curves. 
 //creation of tool and its initialization by shape. 
 Handle(ShapeFix_Shape) sfs = new ShapeFix_Shape(face); 
@@ -271,7 +271,7 @@ cout<< "Shape could not be fixed" << endl;
 else if(sfs->Status(ShapeExtent_OK)) { 
 cout<< "Initial face is valid with specified precision ="<< precendl; 
 } 
-~~~~~
+~~~~
 
 @subsubsection occt_shg_2_3_4 Repairing tool for solids
 
@@ -302,7 +302,7 @@ This tool has the following control flags:
 * *FixMissingSeamMode* -- mode to fix a missing seam, True by default. If True, tries to insert a seam. 
 * *FixSmallAreaWireMode* -- mode to fix a small-area wire, False by default. If True, drops wires bounding small areas. 
 
-~~~~~
+~~~~{.cpp}
 
 TopoDS_Face face = ...; 
 TopoDS_Wire wire = ...; 
@@ -319,7 +319,7 @@ sff.FixOrientation();
 
 //Get the resulting face 
 TopoDS_Face newface = sff.Face(); 
-~~~~~
+~~~~
 
 @subsubsection occt_shg_2_3_7 Repairing tool for wires 
 
@@ -413,7 +413,7 @@ Boolean flag *FixGapsByRanges* is used to activate an additional mode applied be
 
 
 Let us create a custom set of fixes as an example. 
-~~~~~
+~~~~{.cpp}
 TopoDS_Face face = ...; 
 TopoDS_Wire wire = ...; 
 Standard_Real precision = 1e-04; 
@@ -437,7 +437,7 @@ Standard_Boolean LockVertex = Standard_True;
 } 
 TopoDS_Wire newwire = sfw.Wire(); 
 //Returns the corrected wire 
-~~~~~
+~~~~
 
 #### Example: Correction of a wire 
 
@@ -451,7 +451,7 @@ It is necessary to apply the @ref occt_shg_3_1_2 "tools for the analysis of wire
 * there are no intersecting adjacent edges;
 and then immediately apply fixing tools. 
 
-~~~~~
+~~~~{.cpp}
 TopoDS_Face face = ...;
 TopoDS_Wire wire = ...;
 Standard_Real precision = 1e-04;
@@ -483,7 +483,7 @@ adjacent edges”<<endl;
     // The edges are cut at the intersection point so that they no longer intersect.
   }
 }
-~~~~~
+~~~~
 
 As the result all failures have been fixed.
 
@@ -504,7 +504,7 @@ To see how this tool works, it is possible to take an edge, where the maximum de
 
 First it is necessary to apply the @ref occt_shg_3_1_3 "tool for checking the edge validity" to find that the maximum deviation between pcurve and 3D curve is greater than tolerance. Then we can use the repairing tool to increase the tolerance and make the deviation acceptable.
 
-~~~~~  
+~~~~{.cpp}     
 ShapeAnalysis_Edge sae;
 TopoDS_Face face = ...; 
 TopoDS_Wire wire = ...; 
@@ -518,7 +518,7 @@ if (sae.CheckSameParameter (edge, maxdev)) {
   sfe.FixSameParameter();
   cout<<“New tolerance “<<BRep_Tool::Tolerance(edge)<<endl;
 }
-~~~~~
+~~~~
 
 @figure{/user_guides/shape_healing/images/shape_healing_image012.png,"Resulting shape",420}
 
@@ -539,7 +539,7 @@ To perform fixes it is necessary to:
   * set the working precision problems will be detected with and the maximum allowed tolerance
   * perform fixes
   
-~~~~~
+~~~~{.cpp}
 //creation of a tool 
 Handle(ShapeFix_Wireframe) sfwf = new ShapeFix_Wireframe(shape); 
 //sets the working precision problems will be detected with and the maximum allowed tolerance 
@@ -555,7 +555,7 @@ sfwf->SetLimliteAngle(angle);
 sfwf->FixSmallEdges(); 
 //getting the result 
 TopoDS_Shape resShape = sfwf->Shape(); 
-~~~~~
+~~~~
 
 It is desirable that a shape is topologically correct before applying the methods of this class. 
 
@@ -567,7 +567,7 @@ Class ShapeFix_FixSmallFaceThis tool is intended for dropping small faces from t
 
 The sequence of actions for performing the fix is the same as for the fixes described above: 
 
-~~~~~
+~~~~{.cpp}
 //creation of a tool 
 Handle(ShapeFix_FixSmallFace) sff = new ShapeFix_FixSmallFace(shape); 
 //setting of tolerances 
@@ -577,7 +577,7 @@ sff->SetMaxTolerance(maxTol);
 sff.Perform(); 
 //getting the result 
 TopoDS_Shape resShape = sff.FixShape(); 
-~~~~~
+~~~~
 
 @subsubsection occt_shg_2_3_11 Tool to modify  tolerances of shapes (Class ShapeFix_ShapeTolerance).
 
@@ -589,7 +589,7 @@ You set the tolerance functionality as follows:
   * set a tolerance for sub-shapes, by method SetTolerance,
   * limit tolerances with given ranges, by method LimitTolerance.
   
-~~~~~
+~~~~{.cpp}
 //creation of a tool 
 ShapeFix_ShapeTolerance Sft; 
 //setting a specified tolerance on shape and all of its sub-shapes. 
@@ -598,7 +598,7 @@ Sft.SetTolerance(shape,toler);
 Sft.SetTolerance(shape,toler,TopAbs_VERTEX); 
 //limiting the tolerance on the shape and its sub-shapes between minimum and maximum tolerances 
 Sft.LimitTolerance(shape,tolermin,tolermax); 
-~~~~~
+~~~~
 
 
 @section occt_shg_3 Analysis
@@ -614,7 +614,7 @@ However, if you want, these tools can be used for detecting some of shape proble
   * initialize it by shape and set a tolerance problems will be detected with if it is necessary.
   * check the problem that interests you.
   
-~~~~~
+~~~~{.cpp}
 TopoDS_Face face = ...; 
 ShapeAnalysis_Edge sae; 
 //Creates a tool for analyzing an edge 
@@ -623,18 +623,18 @@ for(TopExp_Explorer Exp(face,TopAbs_EDGE);Exp.More();Exp.Next()) {
   if (!sae.HasCurve3d (edge)) { 
     cout  <<"Edge has no 3D curve"<<  endl;  } 
 } 
-~~~~~
+~~~~
 
 @subsubsection occt_shg_3_1_1 Analysis of orientation of wires on a face.
 
 It is possible to check whether a face has an outer boundary with the help of method *ShapeAnalysis::IsOuterBound*. 
 
-~~~~~
+~~~~{.cpp}
 TopoDS_Face face … //analyzed face 
 if(!ShapeAnalysis::IsOuterBound(face)) { 
 cout<<"Face has not outer boundary"<<endl; 
 } 
-~~~~~
+~~~~
 
 @subsubsection occt_shg_3_1_2 Analysis of wire validity
 
@@ -665,7 +665,7 @@ Some methods in this class are:
   
 This class maintains status management. Each API method stores the status of its last execution which can be queried by the corresponding *Status..()* method. In addition, each API method returns a Boolean value, which is True when a case being analyzed is detected (with the set *ShapeExtend_DONE* status), otherwise it is False. 
 
-~~~~~
+~~~~{.cpp}
 TopoDS_Face face = ...; 
 TopoDS_Wire wire = ...; 
 Standard_Real precision = 1e-04; 
@@ -685,7 +685,7 @@ if (saw.CheckConnected()) {
 if (saw.CheckSelfIntersection()) { 
   cout<<"Wire has self-intersecting or intersecting adjacent edges"<<  endl; 
 } 
-~~~~~
+~~~~
 
 @subsubsection occt_shg_3_1_3 Analysis of edge validity 
 
@@ -699,7 +699,7 @@ Class *ShapeAnalysis_Edge* is intended to analyze edges. It provides the followi
 
 This class supports status management described above. 
 
-~~~~~
+~~~~{.cpp}
 TopoDS_Face face = ...; 
 ShapeAnalysis_Edge sae; 
 //Creates a tool for analyzing an edge 
@@ -727,7 +727,7 @@ if(sae.CheckOverlapping(edge1,edge2,prec,dist)) {
         cout<<"Edges are overlapped with tolerance = "<<prec<<endl; 
         cout<<"Domain of overlapping ="<<dist<<endl; 
 } 
-~~~~~
+~~~~
 
 @subsubsection occt_shg_3_1_4 Analysis of presence of small faces
 
@@ -735,7 +735,7 @@ Class *ShapeAnalysis_CheckSmallFace* class is intended for analyzing small faces
 * *CheckSpotFace()* checks if the size of the face is less than the given precision; 
 * *CheckStripFace* checks if the size of the face in one dimension is less than the given precision.
 
-~~~~~
+~~~~{.cpp}
 TopoDS_Shape shape … // checked shape 
 //Creation of a tool 
 ShapeAnalysis_CheckSmallFace saf; 
@@ -750,13 +750,13 @@ NumSmallfaces++;
 } 
 if(numSmallfaces) 
  cout<<"Number of small faces in the shape ="<< numSmallfaces <<endl; 
-~~~~
+~~~~
  
 @subsubsection occt_shg_3_1_5 Analysis of shell validity and closure 
 
 Class *ShapeAnalysis_Shell* allows checking the orientation of edges in a manifold shell. With the help of this tool, free edges (edges entered into one face) and bad edges (edges entered into the shell twice with the same orientation) can be found. By occurrence of bad and free edges a conclusion about the shell validity and the closure of the shell can be made. 
 
-~~~~~
+~~~~{.cpp}
 TopoDS_Shell shell // checked shape 
 ShapeAnalysis_Shell sas(shell); 
 //analysis of the shell , second parameter is set to True for //getting free edges,(default False) 
@@ -770,7 +770,7 @@ if(sas.HasFreeEdges()) {
  cout<<"Shell is open"<<endl; 
  TopoDS_Compound freeEdges = sas.FreeEdges(); 
 } 
-~~~~~
+~~~~
 
 @subsection occt_shg_3_2 Analysis of shape properties.
 @subsubsection occt_shg_3_2_1 Analysis of tolerance on shape 
@@ -783,7 +783,7 @@ The analysis of tolerance functionality is the following:
   * finding sub-shapes with tolerances exceeding the given value, 
   * finding sub-shapes with tolerances in the given range. 
   
-~~~~~
+~~~~{.cpp}
 TopoDS_Shape shape = ...; 
 ShapeAnalysis_ShapeTolerance sast; 
 Standard_Real AverageOnShape = sast.Tolerance (shape, 0); 
@@ -796,29 +796,29 @@ Standard_Real MaxAllowed = 0.1;
 if (MaxOnVertex > MaxAllowed) { 
   cout<<"Maximum tolerance of the vertices exceeds maximum allowed"<<endl; 
 } 
-~~~~~
+~~~~
 
 @subsubsection occt_shg_3_2_2 Analysis of free boundaries. 
 
 Class ShapeAnalysis_FreeBounds is intended to analyze and output the free bounds of a shape. Free bounds are wires consisting of edges referenced only once by only one face in the shape. 
 This class works on two distinct types of shapes when analyzing their free bounds: 
 * Analysis of possible free bounds taking the specified tolerance into account. This analysis can be applied to a compound of faces. The analyzer of the sewing algorithm (*BRepAlgo_Sewing*) is used to forecast what free bounds would be obtained after the sewing of these faces is performed. The following method should be used for this analysis:
-~~~~~
+~~~~{.cpp}
 ShapeAnalysis_FreeBounds safb(shape,toler); 
-~~~~~
+~~~~
 * Analysis of already existing free bounds. Actual free bounds (edges shared by the only face in the shell) are output in this case. *ShapeAnalysis_Shell* is used for that. 
-~~~~~
+~~~~{.cpp}
 ShapeAnalysis_FreeBounds safb(shape); 
-~~~~~
+~~~~
 
 When connecting edges into wires this algorithm tries to build wires of maximum length. Two options are provided for the user to extract closed sub-contours out of closed and/or open contours. Free bounds are returned as two compounds, one for closed and one for open wires. To obtain a result it is necessary to use methods: 
-~~~~~
+~~~~{.cpp}
 TopoDS_Compound ClosedWires  = safb.GetClosedWires(); 
 TopoDS_Compound OpenWires = safb.GetOpenWires(); 
-~~~~~
+~~~~
 This class also provides some static methods for advanced use: connecting edges/wires to wires, extracting closed sub-wires from wires, distributing wires into compounds for closed and open wires. 
 
-~~~~~
+~~~~{.cpp}
 TopoDS_Shape shape = ...; 
 Standard_Real SewTolerance = 1.e-03; 
 //Tolerance for sewing 
@@ -834,7 +834,7 @@ TopoDS_Compound ClosedWires = safb.GetClosedWires();
 //Returns a compound of closed free bounds 
 TopoDS_Compound OpenWires = safb.GetClosedWires(); 
 //Returns a compound of open free bounds 
-~~~~~
+~~~~
 
 @subsubsection occt_shg_3_2_3 Analysis of shape contents
 
@@ -866,7 +866,7 @@ The corresponding flags should be set to True for storing a shape by a specified
 
 Let us, for example, select faces based on offset surfaces.
 
-~~~~
+~~~~{.cpp}
 ShapeAnalysis_ShapeContents safc; 
 //set a corresponding flag for storing faces based on the offset surfaces 
 safc.ModifyOffsetSurfaceMode() = Standard_True; 
@@ -875,7 +875,7 @@ safc.Perform(shape);
 Standard_Integer NbOffsetSurfaces = safc.NbOffsetSurf(); 
 //getting the sequence of faces based on offset surfaces. 
 Handle(TopTools_HSequenceOfShape) seqFaces = safc.OffsetSurfaceSec(); 
-~~~~~
+~~~~
 
 @section occt_shg_4 Upgrading
 
@@ -918,7 +918,7 @@ The usual way to use these tools exception for the tool of converting a C0 BSpli
 
 Let us, for example, split all surfaces and all 3D and 2D curves having a continuity of less the C2. 
 
-~~~~~
+~~~~{.cpp}
 //create a tool and initializes it by shape. 
 ShapeUpgrade_ShapeDivideContinuity ShapeDivedeCont(initShape); 
 
@@ -942,7 +942,7 @@ if(ShapeDivideCont.Status(ShapeExtend_DONE)
 for(TopExp_Explorer aExp(initShape,TopAbs_FACE); aExp.More(0; aExp.Next()) { 
   TopoDS_Shape modifShape = ShapeDivideCont.GetContext()-> Apply(aExp.Current()); 
 } 
-~~~~~
+~~~~
 
 @subsubsection occt_shg_4_1_3 Creation of a new tool for splitting a shape.
 To create a new splitting tool it is necessary to create tools for geometry splitting according to a desirable criterion. The new tools should be inherited from basic tools for geometry splitting. Then the new tools should be set into corresponding tools for shape splitting. 
@@ -953,7 +953,7 @@ To change the value of criterion of shape splitting it is necessary to create a
 
 Let us split a shape according to a specified criterion. 
 
-~~~~~
+~~~~{.cpp}
 //creation of new tools for geometry splitting by a specified criterion. 
 Handle(MyTools_SplitSurfaceTool) MySplitSurfaceTool = new MyTools_SplitSurfaceTool; 
 Handle(MyTools_SplitCurve3DTool) MySplitCurve3Dtool = new MyTools_SplitCurve3DTool; 
@@ -987,7 +987,7 @@ TopoDS_Shape splitShape = ShapeDivide.GetResult();
 for(TopExp_Explorer aExp(initShape,TopAbs_FACE); aExp.More(0; aExp.Next()) { 
 TopoDS_Shape modifShape = ShapeDivide.GetContext()-> Apply(aExp.Current()); 
 } 
-~~~~~
+~~~~
 
 @subsection occt_shg_4_2 General splitting tools.
  
@@ -1059,7 +1059,7 @@ To create new tools for geometry splitting it is enough to inherit a new tool fr
 
 Header file for the tool for surface splitting by continuity: 
 
-~~~~~
+~~~~{.cpp}
 class ShapeUpgrade_SplitSurfaceContinuity : public ShapeUpgrade_SplitSurface { 
 Standard_EXPORT ShapeUpgrade_SplitSurfaceContinuity(); 
 
@@ -1075,14 +1075,14 @@ GeomAbs_Shape myCriterion;
 Standard_Real myTolerance; 
 Standard_Integer myCont; 
 }; 
-~~~~~
+~~~~
 
 @subsection occt_shg_4_3 Specific splitting tools.
 
 @subsubsection occt_shg_4_3_1 Conversion of shape geometry to the target continuity
 Class *ShapeUpgrade_ShapeDivideContinuity* allows converting geometry with continuity less than the specified continuity to geometry with target continuity. If converting is not possible than geometrical object is split into several ones, which satisfy the given criteria. A topological object based on this geometry is replaced by several objects based on the new geometry. 
 
-~~~~~
+~~~~{.cpp}
 ShapeUpgrade_ShapeDivideContinuity sdc (shape); 
 sdc.SetTolerance (tol3d); 
 sdc.SetTolerance3d (tol2d); // if known, else 1.e-09 is taken 
@@ -1099,7 +1099,7 @@ if (ctx.IsRecorded (sh)) {
 // if there are several results, they are recorded inside a Compound.
 // .. process as needed 
 } 
-~~~~~
+~~~~
 
 @subsubsection occt_shg_4_3_2 Splitting by angle
 Class *ShapeUpgrade_ShapeDivideAngle* allows  splitting all surfaces of revolution, cylindrical, toroidal, conical, spherical surfaces in the given shape so that each resulting segment covers not more than the defined angle (in radians). 
@@ -1133,7 +1133,7 @@ This tool provides access to various flags for conversion of different types of
        * *GetBSplineMode,* 
 
 Let us attempt to produce a conversion of planes to Bezier surfaces. 
-~~~~~
+~~~~{.cpp}
 //Creation and initialization of a tool. 
 ShapeUpgrade_ShapeConvertToBezier SCB (Shape); 
 //setting tolerances 
@@ -1144,13 +1144,13 @@ SCB.SetPlaneMode(Standard_True);
 SCB.Perform(); 
 If(SCB.Status(ShapeExtend_DONE) 
     TopoDS_Shape result = SCB.GetResult(); 
-~~~~~
+~~~~
 
 @subsubsection occt_shg_4_3_4 Tool for splitting closed faces
 
 Class *ShapeUpgrade_ShapeDivideClosed* provides splitting of closed faces in the shape to a defined number of components by the U and V parameters. It topologically and (partially) geometrically processes closed faces and performs splitting with the help of class *ShapeUpgrade_ClosedFaceDivide*. 
 
-~~~~~
+~~~~{.cpp}
 TopoDS_Shape aShape = …; 
 ShapeUpgrade_ShapeDivideClosed tool (aShape ); 
 Standard_Real closeTol = …; 
@@ -1164,7 +1164,7 @@ if ( ! tool.Perform() && tool.Status (ShapeExtend_FAIL) ) {
   . . . 
 } 
 TopoDS_Shape aResult = tool.Result(); 
-~~~~~
+~~~~
 
 @subsubsection occt_shg_4_3_5 Tool for splitting a C0 BSpline 2D or 3D curve to a sequence C1 BSpline curves
 
@@ -1190,7 +1190,7 @@ An example of using this tool is presented in the figures below:
 *      To produce a splitting use  method Perform from the base class. 
 *      The result shape can be obtained with the help the method *Result()*.
 
-~~~~~
+~~~~{.cpp}
 ShapeUpgrade_ShapeDivideArea tool (inputShape); 
 tool.MaxArea() = aMaxArea; 
 tool.Perform(); 
@@ -1198,7 +1198,7 @@ if(tool.Status(ShapeExtend_DONE)) {
   TopoDS_Shape ResultShape = tool.Result(); 
   ShapeFix::SameParameter ( ResultShape, Standard_False ); 
 } 
-~~~~~
+~~~~
 
 **Note** that the use of method *ShapeFix::SameParameter* is necessary, otherwise the parameter edges obtained as a result of splitting can be different. 
 
@@ -1214,27 +1214,27 @@ Customization tools are intended for adaptation of shape geometry in compliance
 
 To implement the necessary shape modification it is enough to initialize the appropriate tool by the shape and desirable parameters and to get the resulting shape. For example for conversion of indirect surfaces in the shape do the following:
 
-~~~~~
+~~~~{.cpp}
 TopoDS_Shape initialShape .. 
 TopoDS_Shape resultShape = ShapeCustom::DirectFaces(initialShape); 
-~~~~~
+~~~~
 
 @subsubsection occt_shg_4_4_1 Conversion of indirect surfaces.
 
-~~~~~
+~~~~{.cpp}
 ShapeCustom::DirectFaces 
        static TopoDS_Shape DirectFaces(const TopoDS_Shape& S); 
-~~~~
+~~~~
 
 This method provides conversion of indirect elementary surfaces (elementary surfaces with left-handed coordinate systems) in the shape into direct ones. New 2d curves (recomputed for converted surfaces) are added to the same edges being shared by both the resulting shape and the original shape *S*. 
 
 @subsubsection occt_shg_4_4_2 Shape Scaling 
 
-~~~~~
+~~~~{.cpp}
 ShapeCustom::ScaleShape 
        TopoDS_Shape ShapeCustom::ScaleShape(const TopoDS_Shape& S,
                const Standard_Real scale); 
-~~~~~
+~~~~
 
 This method returns a new shape, which is a scaled original shape with a coefficient equal to the specified value of scale. It uses the tool *ShapeCustom_TrsfModification*. 
 
@@ -1243,7 +1243,7 @@ This method returns a new shape, which is a scaled original shape with a coeffic
 *ShapeCustom_BSplineRestriction* allows approximation of surfaces, curves and 2D curves with a specified degree, maximum number of segments, 2d tolerance and 3d tolerance. If the approximation result cannot be achieved with the specified continuity, the latter can be reduced. 
 
 The method with all parameters looks as follows:
-~~~~~
+~~~~{.cpp}
 ShapeCustom::BsplineRestriction 
        TopoDS_Shape ShapeCustom::BSplineRestriction (const TopoDS_Shape& S, 
                const Standard_Real Tol3d, const Standard_Real Tol2d, 
@@ -1254,7 +1254,7 @@ ShapeCustom::BsplineRestriction
                const Standard_Boolean Degree, 
                const Standard_Boolean Rational, 
                const Handle(ShapeCustom_RestrictionParameters)& aParameters) 
-~~~~~
+~~~~
                
 It returns a new shape with all surfaces, curves and 2D curves of BSpline/Bezier type or based on them, converted with a degree less than *MaxDegree* or with a number of spans less then *NbMaxSegment* depending on the priority parameter *Degree*. If this parameter is equal to True then *Degree* will be increased to the value *GmaxDegree*, otherwise *NbMaxSegments* will be increased to the value *GmaxSegments*. *GmaxDegree* and *GMaxSegments* are the maximum possible degree and the number of spans correspondingly. These values will be used in cases when an approximation with specified parameters is impossible and either *GmaxDegree* or *GMaxSegments* is selected depending on the priority. 
 
@@ -1281,22 +1281,22 @@ The following flags define whether a specified-type geometry has been converted
 
 @subsubsection occt_shg_4_4_4 Conversion of elementary surfaces into surfaces of revolution 
 
-~~~~~
+~~~~{.cpp}
 ShapeCustom::ConvertToRevolution()
        TopoDS_Shape ShapeCustom::ConvertToRevolution(const TopoDS_Shape& S) ; 
-~~~~~
+~~~~
 
 This method returns a new shape with all elementary periodic surfaces converted to *Geom_SurfaceOfRevolution*. It uses the tool *ShapeCustom_ConvertToRevolution*. 
 
 @subsubsection occt_shg_4_4_5 Conversion of elementary surfaces into Bspline surfaces
 
-~~~~~
+~~~~{.cpp}
 ShapeCustom::ConvertToBSpline() 
        TopoDS_Shape ShapeCustom::ConvertToBSpline( const TopoDS_Shape& S, 
                const Standard_Boolean extrMode, 
                const Standard_Boolean revolMode, 
                const Standard_Boolean offsetMode); 
-~~~~~          
+~~~~           
 
 This method returns a new shape with all surfaces of linear extrusion, revolution and offset surfaces converted according to flags to *Geom_BSplineSurface* (with the same parameterization). It uses the tool *ShapeCustom_ConvertToBSpline*. 
 
@@ -1308,13 +1308,13 @@ If, in addition to the resulting shape, you want to get the history of modificat
 
 
 The general calling syntax for scaling is
-~~~~
+~~~~{.cpp}
 TopoDS_Shape scaled_shape = ShapeCustom::ScaleShape(shape, scale); 
-~~~~~
+~~~~
 
 Note that scale is a real value. You can refine your mapping process by using additional calls to follow shape mapping sub-shape by sub-shape. The following code along with pertinent includes can be used: 
 
-~~~~~
+~~~~{.cpp}
 p_Trsf T; 
 Standard_Real scale = 100; // for example! 
 T.SetScale (gp_Pnt (0, 0, 0), scale); 
@@ -1324,13 +1324,13 @@ TopTools_DataMapOfShapeShape context;
 BRepTools_Modifier MD; 
 TopoDS_Shape res = ShapeCustom::ApplyModifier ( 
 Shape, TM, context,MD ); 
-~~~~~
+~~~~
 
 The map, called context in our example, contains the history. 
 Substitutions are made one by one and all shapes are transformed. 
 To determine what happens to a particular sub-shape, it is possible to use: 
 
-~~~~~
+~~~~{.cpp}
 TopoDS_Shape oneres = context.Find (oneshape); 
 //In case there is a doubt, you can also add: 
 if (context.IsBound(oneshape)) oneres = context.Find(oneshape); 
@@ -1342,7 +1342,7 @@ iter(context);iter(more ();iter.next ()) {
   TopoDs_Shape oneshape = iter.key (); 
   TopoDs_Shape oneres = iter.value (); 
 } 
-~~~~~
+~~~~
 
 
 @subsubsection occt_shg_4_4_7 Remove internal wires
@@ -1379,7 +1379,7 @@ After the processing six internal wires with contour area less than the specifie
 
 The example of method application is also given below:
 
-~~~~~
+~~~~{.cpp}
 //Initialization of the class by shape. 
 Handle(ShapeUpgrade_RemoveInternalWires) aTool = new ShapeUpgrade_RemoveInternalWires(inputShape); 
 //setting parameters 
@@ -1410,7 +1410,7 @@ if(aTool->Status(ShapeExtend_DONE1)) {
   }   
     //getting result shape 
   TopoDS_Shape res = aTool->GetResult(); 
-~~~~~
+~~~~
 
 @subsubsection occt_shg_4_4_8 Conversion of surfaces 
 
@@ -1427,7 +1427,7 @@ To convert surfaces to analytical form this class analyzes the form and the clos
  
 The conversion is done only if the new (analytical) surface does not deviate from the source one more than by the given precision. 
 
-~~~~~
+~~~~{.cpp}
 Handle(Geom_Surface) initSurf; 
 ShapeCustom_Surface ConvSurf(initSurf); 
 //conversion to analytical form 
@@ -1436,7 +1436,7 @@ Handle(Geom_Surface) newSurf  = ConvSurf.ConvertToAnalytical(allowedtol,Standard
 Handle(Geom_Surface) newSurf  = ConvSurf.ConvertToPeriodic(Standard_False); 
 //getting the maximum deviation of the new surface from the initial surface 
 Standard_Real maxdist = ConvSurf.Gap(); 
-~~~~~
+~~~~
 
 @subsubsection occt_shg_4_4_9 Unify Same Domain
 
@@ -1458,7 +1458,7 @@ The common methods of this tool are as follows:
   * Method *Generated()* is used to get a new common shape from the old shape. If a group of edges has been unified into one common edge then method *Generated()* called on any edge from this group will return the common edge. The same goes for the faces.
 
 The example of the usage is given below:
-~~~~~
+~~~~{.cpp}
  // 'Sh' is the initial shape
  ShapeUpgrade_UnifySameDomain USD(Sh, true, true, true); // UnifyFaces mode on, UnifyEdges mode on, ConcatBSplines mode on.
  USD.Build();
@@ -1467,7 +1467,7 @@ The example of the usage is given below:
  //Let Sh1 as a part of Sh
  //get the new (probably unified) shape form the Sh1
  TopoDS_Shape ResSh1 = USD.Generated(Sh1);
-~~~~
+~~~~
 
 @section occt_shg_5_ Auxiliary tools for repairing, analysis and upgrading
 
@@ -1490,7 +1490,7 @@ Additional method *IsNewShape* can be used to check if the shape has been record
 
 Let us use the tool to get the result shape after modification of sub-shapes of the initial shape:
 
-~~~~
+~~~~{.cpp}
 TopoDS_Shape initialShape… 
 //creation of a rebuilding tool 
 Handle(ShapeBuild_ReShape) Context = new ShapeBuild_ReShape. 
@@ -1516,7 +1516,7 @@ TopoDS_Shape resultShape = Context->Apply(initialShape);
 
 //getting the resulting sub-shape from the subshape1 of the initial shape. 
 TopoDS_Shape result_subshape1 = Context->Apply(subshape1); 
-~~~~~
+~~~~
 
 @subsection occt_shg_5_2 Status definition
 
@@ -1546,7 +1546,7 @@ This class also provides a method to check if the edge in the wire is a seam (if
 
 Let us remove edges from the wire and define whether it is seam edge 
 
-~~~~~
+~~~~{.cpp}
 TopoDS_Wire ini = .. 
 Handle(ShapeExtend_Wire) asewd = new ShapeExtend_Wire(initwire); 
 //Removing edge Edge1 from the wire. 
@@ -1556,7 +1556,7 @@ asewd.Remove(index_edge1);
 //Definition of whether Edge2 is a seam edge 
 Standard_Integer index_edge2 = asewd->Index(Edge2); 
 asewd->IsSeam(index_edge2); 
-~~~~~
+~~~~
 
 
 @subsection occt_shg_5_4 Tool for exploring shapes 
@@ -1570,7 +1570,7 @@ Class *ShapeExtend_MsgRegistrator* attaches messages to objects (generic Transie
 
 Let us send and get a message attached to object:
 
-~~~~
+~~~~{.cpp}
 Handle(ShapeExtend_MsgRegistrator) MessageReg = new ShapeExtend_MsgRegistrator; 
 //attaches messages to an object (shape or entity) 
 Message_Msg msg.. 
@@ -1587,7 +1587,7 @@ iter.More(); iter.Next()) {
        Message_Msg msg = iter.Value(); 
  } 
     } 
-~~~~~
+~~~~
 
 @subsection occt_shg_5_6 Tools for performance measurement
 
@@ -1595,7 +1595,7 @@ Classes *MoniTool_Timer* and *MoniTool_TimerSentry* are used for measuring the p
 
 Let us try to use timers in *XSDRAWIGES.cxx* and *IGESBRep_Reader.cxx* to analyse the performance of command *igesbrep*:
 
-~~~~~
+~~~~{.cpp}
 XSDRAWIGES.cxx
   ...
   #include <MoniTool_Timer.hxx>
@@ -1626,7 +1626,7 @@ IGESBRep_Reader.cxx
     }
     ...
   }
-~~~~~
+~~~~
 
 The result of *DumpTimer()* after file translation is as follows: 
 
@@ -1646,35 +1646,35 @@ The Shape Processing functionality is implemented with the help of the *XSAlgo*
 
 This function is used in the following way:
 
-~~~~~
+~~~~{.cpp}
 TopoDS_Shape aShape = …; 
 Standard_Real Prec = …, 
 Standard_Real MaxTol = …; 
 TopoDS_Shape aResult; 
 Handle(Standard_Transient) info; 
 TopoDS_Shape aResult = XSAlgo::AlgoContainer()->ProcessShape(aShape, Prec, MaxTol., "Name of ResourceFile", "NameSequence", info ); 
-~~~~~
+~~~~
 
 Let us create a custom sequence of operations: 
 
 1. Create a resource file with the name *ResourceFile*, which includes the following string: 
-~~~~~
+~~~~{.cpp}
 NameSequence.exec.op:    MyOper 
-~~~~~
+~~~~
 where *MyOper* is the name of operation. 
 2. Input a custom parameter for this operation in the resource file, for example: 
-~~~~~
+~~~~{.cpp}
 NameSequence.MyOper.Tolerance: 0.01 
-~~~~~
+~~~~
 where *Tolerance* is the name of the parameter and 0.01 is its value. 
 3. Add the following string into *void ShapeProcess_OperLibrary::Init()*: 
-~~~~~
+~~~~{.cpp}
 ShapeProcess::RegisterOperator(;MyOper;, 
 new ShapeProcess_UOperator(myfunction)); 
-~~~~~
+~~~~
 where *myfunction* is a function which implements the operation. 
 4. Create this function in *ShapeProcess_OperLibrary* as follows:
-~~~~~
+~~~~{.cpp}
 static Standard_Boolean myfunction (const 
                        Handle(ShapeProcess_Context)& context) 
 { 
@@ -1684,19 +1684,19 @@ static Standard_Boolean myfunction (const
   //receive our parameter: 
   Standard_Real toler; 
   ctx->GetReal(;Tolerance;, toler);
-~~~~~
+~~~~
 5. Make the necessary operations with *aShape* using the received value of parameter *Tolerance* from the resource file. 
-~~~~~
+~~~~{.cpp}
   return Standard_True; 
 } 
-~~~~~
+~~~~
 6. Define some operations (with their parameters) *MyOper1, MyOper2, MyOper3*, etc. and describe the corresponding functions in *ShapeProcess_OperLibrary*. 
 7. Perform the required sequence using the specified name of operations and values of parameters in the resource file. 
 
 For example: input of the following string:
-~~~~~
+~~~~{.cpp}
 NameSequence.exec.op:    MyOper1,MyOper3 
-~~~~~
+~~~~
 means that the corresponding functions from *ShapeProcess_OperLibrary* will be performed with the original shape *aShape* using parameters defined for *MyOper1* and *MyOper3* in the resource file. 
 
 It is necessary to note that these operations will be performed step by step and the result obtained after performing the first operation will be used as the initial shape for the second operation. 
@@ -1906,7 +1906,7 @@ All lines in the file after the key and before the next keyword (and which are n
 
 The following example illustrates the structure of a message file: 
 
-~~~~~
+~~~~{.cpp}
 !This is a sample message file 
 !------------------------------ 
 !Messages for ShapeAnalysis package 
@@ -1917,15 +1917,15 @@ Your message string goes here
 !... 
 ! 
 !End of the message file 
-~~~~~
+~~~~
 
 ### Loading the message file
 
 A custom file can be loaded into memory using the method *Message_MsgFile::LoadFile*, taking as an argument the path to your file as in the example below: 
-~~~~~
+~~~~{.cpp}
 Standard_CString MsgFilePath = ;(path)/sample.file;; 
 Message_MsgFile::LoadFile (MsgFilePath); 
-~~~~~
+~~~~
 
 @subsection occt_shg_7_3 Tool for managing filling messages 
 
@@ -1936,13 +1936,13 @@ The text of the message can contain places for parameters, which are to be fille
 * integer -- coded in the text as \%d, 
 * real -- coded in the text as \%f. 
 The parameter fields are filled by the message text by calling the corresponding methods *AddInteger, AddReal* and *AddString*. Both the original text of the message and the input text with substituted parameters are stored in the object. The prepared and filled message can be output to the default trace file. The text of the message (either original or filled) can be also obtained. 
-~~~~~
+~~~~{.cpp}
 Message_Msg msg01 (;SampleKeyword;); 
 //Creates the message msg01, identified in the file by the keyword SampleKeyword 
 msg1.AddInteger (73); 
 msg1.AddString (;SampleFile;); 
 //fills out the code areas 
-~~~~~
+~~~~
 
 @subsection occt_shg_7_4 Tool for managing trace files
 
@@ -1951,10 +1951,10 @@ There are two ways of using trace files:
 * define an object of *Message_TraceFile*, with its own definition (file name or cout, trace level), and use it where it is defined, 
 * use the default trace file (file name or cout, trace level), usable from anywhere. 
 Use the constructor method to define the target file and the level of the messages as in the example below: 
-~~~~~
+~~~~{.cpp}
 Message_TraceFile myTF 
        (tracelevel, "tracefile.log", Standard_False); 
-~~~~~
+~~~~
 The parameters are as follows: 
 * *tracelevel* is a Standard_Integer and modifies the level of messages. It has the following values and semantics: 
        + 0: gives general information such as the start and end of process;
index 0fe82691a7b1b3dbe2df9f091a6922a10bbc3751..0ceccc12c964c26af97fb76ca3050650bd246e0e 100644 (file)
@@ -119,23 +119,23 @@ For further information see 2.4 Mapping STEP entities to Open CASCADE Technology
 @subsubsection occt_step_2_3_1 Loading the STEP file
 
 Before performing any other operation you have to load the file with: 
-~~~~~
+~~~~{.cpp}
 STEPControl_Reader reader; 
 IFSelect_ReturnStatus stat = reader.ReadFile("filename.stp");
-~~~~~
+~~~~
 Loading the file only memorizes the data, it does not translate it. 
 
 @subsubsection occt_step_2_3_2 Checking the STEP file
 This step is not obligatory. Check the loaded file with: 
-~~~~~
+~~~~{.cpp}
 reader.PrintCheckLoad(failsonly,mode); 
-~~~~~
+~~~~
 Error messages are displayed if there are invalid or incomplete STEP entities, giving you the information on the cause of error. 
 
 If *failsonly* is true only fail messages are displayed. All messages are displayed if *failsonly* is false. Your analysis of the file can be either message-oriented or entity-oriented. Choose your preference with: 
-~~~~~
+~~~~{.cpp}
 IFSelect_PrintCount mode = IFSelect_xxx 
-~~~~~
+~~~~
 Where xxx can be one of the following: 
 * *ItemsByEntity*  --       gives a sequential list of all messages per STEP entity, 
 * *CountByItem*   --   gives the number of STEP entities with their types per message 
@@ -153,14 +153,14 @@ Defines which precision value will be used during translation (see section 2.5 b
 
 Read this parameter with: 
 
-~~~~~
+~~~~{.cpp}
 Standard_Integer ic = Interface_Static::IVal("read.precision.mode");  
-~~~~~
+~~~~
 Modify this parameter with: 
-~~~~~
+~~~~{.cpp}
 if(!Interface_Static::SetIVal("read.precision.mode",1))  
 .. error .. 
-~~~~~
+~~~~
 Default value is File (0).
  
 <h4>read.precision.val:</h4>
@@ -169,14 +169,14 @@ User defined precision value. This parameter gives the precision for shape const
 This value is a basic value of tolerance in the processor. The value is in millimeters, independently of the length unit defined in the STEP file. 
 
 Read this parameter with: 
-~~~~~
+~~~~{.cpp}
 Standard_Real rp = Interface_Static::RVal("read.precision.val"); 
-~~~~~
+~~~~
 Modify this parameter with: 
-~~~~~
+~~~~{.cpp}
 if(!Interface_Static::SetRVal("read.precision.val",0.01))  
 .. error .. 
-~~~~~
+~~~~
 By default this value is 0.0001. 
 
 The value given to this parameter is a basic value for ShapeHealing algorithms and the processor. It does its best to reach it. Under certain circumstances, the value you give may not be attached to all of the entities concerned at the end of processing. STEP-to-OpenCASCADE translation does not improve the quality of the geometry in the original STEP file. This means that the value you enter may be impossible to attach to all shapes with the given quality of the geometry in the STEP file. 
@@ -185,14 +185,14 @@ The value given to this parameter is a basic value for ShapeHealing algorithms a
 Defines the maximum allowed tolerance (in mm) of the shape. It should be not less than the basic value of tolerance set in the processor (either the uncertainty from the file or *read.precision.val*). Actually, the maximum between *read.maxprecision.val* and the basis tolerance is used to define the maximum allowed tolerance. 
 
 Read this parameter with: 
-~~~~~
+~~~~{.cpp}
 Standard_Real rp = Interface_Static::RVal("read.maxprecision.val"); 
-~~~~~
+~~~~
 Modify this parameter with: 
-~~~~~
+~~~~{.cpp}
 if(!Interface_Static::SetRVal("read.maxprecision.val",0.1))  
 .. error .. 
-~~~~~
+~~~~
 
 Default value is 1. 
 Note that maximum tolerance even explicitly defined by the user may be insufficient to ensure the validity of the shape (if real geometry is of bad quality). Therefore the user is provided with an additional parameter, which allows him to choose: either he prefers to ensure the shape validity or he rigidly sets the value of maximum tolerance. In the first case there is a possibility that the tolerance will not have any upper limit, in the second case the shape may be invalid. 
@@ -203,14 +203,14 @@ Defines the mode of applying the maximum allowed tolerance. Its possible values
 * 1 (Forced) --    maximum tolerance is used as a rigid limit, i.e. no tolerance can exceed it and if it is the case, the tolerance is trimmed by the maximum tolerance. 
 
 Read this parameter with: 
-~~~~~
+~~~~{.cpp}
 Standard_Integer ic = Interface_Static::IVal("read.maxprecision.mode"); 
-~~~~~
+~~~~
 Modify this parameter with: 
-~~~~~
+~~~~{.cpp}
 if(!Interface_Static::SetIVal("read.maxprecision.mode",1))  
 .. error .. 
-~~~~~
+~~~~
 Default value is 0 ("Preferred").
  
 <h4>read.stdsameparameter.mode</h4>
@@ -221,14 +221,14 @@ defines the use of *BRepLib::SameParameter*. Its possible values are:
 The functionality of *BRepLib::SameParameter* is used through *ShapeFix_Edge::SameParameter*. It ensures that the resulting edge will have the lowest tolerance taking pcurves either unmodified from the STEP file or modified by *BRepLib::SameParameter*.
  
 Read this parameter with: 
-~~~~~
+~~~~{.cpp}
 Standard_Integer mv = Interface_Static::IVal("read.stdsameparameter.mode"); 
-~~~~~
+~~~~
 Modify this parameter with: 
-~~~~~
+~~~~{.cpp}
 if (!Interface_Static::SetIVal ("read.stdsameparameter.mode",1)) 
 .. error ..; 
-~~~~~
+~~~~
 Default value is 0 (;Off;). 
 
 <h4>read.surfacecurve.mode:</h4>
@@ -240,28 +240,28 @@ If both 2D and 3D representation of the entity are present, the computation of t
 * *3DUse_Preferred (3)* :  3D curves are used to rebuild 2D ones. 
 
 Read this parameter with: 
-~~~~~
+~~~~{.cpp}
 Standard_Integer rp = Interface_Static::IVal("read.surfacecurve.mode"); 
-~~~~~
+~~~~
 Modify this parameter with: 
-~~~~~
+~~~~{.cpp}
 if(!Interface_Static::SetIVal("read.surfacecurve.mode",3))  
 .. error .. 
-~~~~~
+~~~~
 Default value is (0). 
 
 <h4>read.encoderegularity.angle</h4>
 
 This parameter is used for call to *BRepLib::EncodeRegularity()* function which is called for the shape read from an IGES or a STEP file at the end of translation process. This function sets the regularity flag of the edge in the shell when this edge is shared by two faces. This flag shows the continuity these two faces are connected with at that edge.  
 Read this parameter with: 
-~~~~~
+~~~~{.cpp}
 Standard_Real era =  Interface_Static::RVal("read.encoderegularity.angle"); 
-~~~~~
+~~~~
 Modify this parameter with: 
-~~~~~
+~~~~{.cpp}
 if (!Interface_Static::SetRVal ("read.encoderegularity.angle",0.1))  
 .. error ..; 
-~~~~~
+~~~~
 Default value is 0.01. 
 
 <h4>step.angleunit.mode</h4>
@@ -292,15 +292,15 @@ Defines the approach used for selection of top-level STEP entities for translati
 * 0 (OFF) -- *SHAPE_DEFINITION_REPRESENTATION* entities are taken as top-level ones; assembly is recognized by *CONTEXT_DEPENDENT_SHAPE_REPRESENTATION* entities. This is compatibility mode, which can be used for reading legacy STEP files produced by older versions of STEP translators and having incorrect or incomplete product information. 
 
 Read this parameter with: 
-~~~~~
+~~~~{.cpp}
 Standard_Integer ic = Interface_Static::IVal("read.step.product.mode");  
-~~~~~
+~~~~
 
 Modify this parameter with: 
-~~~~~
+~~~~{.cpp}
 if(!Interface_Static::SetIVal("read.step.product.mode",1))  
 .. error .. 
-~~~~~
+~~~~
 Default value is 1 (ON).
  
 Note that the following parameters have effect only if *read.step.product.mode* is ON. 
@@ -315,15 +315,15 @@ When reading AP 209 STEP files, allows selecting either only `design' or `analys
 Note that in AP 203 and AP214 files all products should be marked as `design', so if this mode is set to `analysis', nothing will be read. 
 
 Read this parameter with: 
-~~~~~
+~~~~{.cpp}
 Standard_Integer ic =  Interface_Static::IVal("read.step.product.context");
-~~~~~
+~~~~
   
 Modify this parameter with: 
-~~~~~
+~~~~{.cpp}
 if(!Interface_Static::SetIVal(;read.step.product.context;,1))  
 .. error .. 
-~~~~~
+~~~~
 Default value is 1 (all).
  
 <h4>read.step.shape.repr:</h4>
@@ -340,14 +340,14 @@ Specifies preferred type of representation of the shape of the product, in case
 When this option is not equal to 1, for products with multiple representations the representation having a type closest to the selected one in this list will be translated. 
 
 Read this parameter with: 
-~~~~~
+~~~~{.cpp}
 Standard_Integer ic = Interface_Static::IVal("read.step.shape.repr");  
-~~~~~
+~~~~
 Modify this parameter with: 
-~~~~~
+~~~~{.cpp}
 if(!Interface_Static::SetIVal("read.step.shape.repr",1))  
 .. error .. 
-~~~~~
+~~~~
 Default value is 1 (All). 
 
 <h4>read.step.assembly.level:</h4>
@@ -359,14 +359,14 @@ Specifies which data should be read for the products found in the STEP file:
 * 4 (shape) --      Translate only shapes associated with the product, ignoring the assembly structure (if any). This can be useful to translate only a shape associated with specific product, as a complement to *assembly* mode. 
 
 Read this parameter with: 
-~~~~~
+~~~~{.cpp}
 Standard_Integer ic =                   Interface_Static::IVal("read.step.assembly.level"); 
-~~~~~
+~~~~
 Modify this parameter with: 
-~~~~~
+~~~~{.cpp}
 if(!Interface_Static::SetIVal("read.step.assembly.level",1))  
 .. error .. 
-~~~~~
+~~~~
 
 Default value is 1 (All). 
 
@@ -376,14 +376,14 @@ Defines whether shapes associated with the main *SHAPE_DEFINITION_REPRESENTATION
 * 0 (OFF) --        do not translate 
 
 Read this parameter with: 
-~~~~~
+~~~~{.cpp}
 Standard_Integer ic =           Interface_Static::IVal("read.step.shape.relationship");
-~~~~
+~~~~
 Modify this parameter with: 
-~~~~~
+~~~~{.cpp}
 if(!Interface_Static::SetIVal(;read.step.shape.relationship;,1))  
 .. error .. 
-~~~~~
+~~~~
 Default value is 1 (ON).
  
 <h4>read.step.shape.aspect:</h4>
@@ -393,15 +393,15 @@ Defines whether shapes associated with the *PRODUCT_DEFINITION_SHAPE* entity of
 * 0 (OFF) --        do not translate 
 
 Read this parameter with: 
-~~~~~
+~~~~{.cpp}
 Standard_Integer ic =                   Interface_Static::IVal("read.step.shape.aspect"); 
-~~~~~
+~~~~
 
 Modify this parameter with: 
-~~~~~
+~~~~{.cpp}
 if(!Interface_Static::SetIVal(;read.step.shape.aspect;,1))  
 .. error .. 
-~~~~~
+~~~~
 Default value is 1 (ON). 
 
 <h4>read.step.constructivegeom.relationship:</h4>
@@ -413,9 +413,9 @@ main representation of the shape (product).
 By default, the flag is set to 0 (OFF) so these entities are not translated. 
 Set this flag to 1 (ON) if you need to translate constructive geometry entities associated with the parts:
 
-~~~~~
+~~~~{.cpp}
 if (!Interface_Static::SetIVal("read.step.constructivegeom.relationship", 1)) { .. error .. }
-~~~~~
+~~~~
 
 The "CONSTRUCTIVE_GEOMETRY_REPRESENTATION" entity is translated into compound of two unlimited planar faces, 
 whose location is result of translation of corresponding "AXIS_PLACEMENT" entity.
@@ -424,7 +424,7 @@ Note that appropriate interpretation of the translated data should be done after
 The result of translation can be obtained either for the "CONSTRUCTIVE_GEOMETRY_REPRESENTATION_RELATIONSHIP" entity,
 of for each of the two "AXIS2_PLACEMENT_3D" entities referenced by it. as follows:
 
-~~~~~
+~~~~{.cpp}
   STEPControl_Reader aReader;
   ... // translate file and parse STEP model to find relevant axis entity
   Handle(StepGeom_Axis2Placement3d) aSTEPAxis = ...;
@@ -443,7 +443,7 @@ of for each of the two "AXIS2_PLACEMENT_3D" entities referenced by it. as follow
       }
     }
   }
-~~~~~
+~~~~
 
 @subsubsection occt_step_2_3_4 Performing the STEP file translation
 
@@ -474,9 +474,9 @@ The following methods are used for translation:
 Each successful translation operation outputs one shape. A series of translations gives a set of shapes. 
 
 Each time you invoke *TransferOne(), TransferRoot()* or *TransferList()*, their results are accumulated and the counter of results increases. You can clear the results with: 
-~~~~~
+~~~~{.cpp}
 reader.ClearShapes(); 
-~~~~~
+~~~~
 between two translation operations, if you do not, the results from the next translation will be added to the accumulation. 
 
 *TransferRoots()* operations automatically clear all existing results before they start. 
@@ -494,9 +494,9 @@ If several individual translations follow each other, the results give a list th
 
 <h5>Checking that translation was correctly performed</h5>
 Each time you invoke *Transfer* or *TransferRoots()*,  you can display the related messages with the help of: 
-~~~~~
+~~~~{.cpp}
 reader.PrintCheckTransfer(failsonly,mode); 
-~~~~~
+~~~~
 
 This check concerns the last invocation of *Transfer* or *TransferRoots()* only. 
 
@@ -512,35 +512,35 @@ There are three selection possibilities. You can select:
 <h5>The whole file</h5>
 
 Transferring the whole file means transferring all root entities. The number of roots can be evaluated when the file is loaded: 
-~~~~~
+~~~~{.cpp}
 Standard_Integer NbRoots = reader.NbRootsForTransfer(); 
 Standard_Integer num = reader.TransferRoots(); 
-~~~~~
+~~~~
 
 <h5>List of entities</h5>
 A list of entities can be formed by invoking *STEP214Control_Reader::GiveList* (this is a method of the parent class). 
 
 Here is a simple example of how a list is translated: 
-~~~~~
+~~~~{.cpp}
 Handle(TColStd_HSequenceOfTransient) list = reader.GiveList(); 
-~~~~~
+~~~~
 The result is a *TColStd_HSequenceOfTransient*. 
 You can either translate a list entity by entity or all at once. An entity-by-entity operation lets you check each individual entity translated. 
 
 <h5>Translating a whole list in one operation</h5>
-~~~~~
+~~~~{.cpp}
 Standard_Integer nbtrans = reader.TransferList (list); 
-~~~~~
+~~~~
 *nbtrans* gives the number of items in the list that produced a shape. 
 
 <h5>Translating a list entity by entity:</h5>
-~~~~~
+~~~~{.cpp}
 Standard_Integer i,nb = list->Length();
 for (i = 1; i <= nb; i ++) {
  Handle(Standard_Transient) ent = list->Value(i);
  Standard_Boolean OK = reader.TransferEntity (ent);
 }
-~~~~~
+~~~~
 
 <h4>Selections</h4>
 There is a number of predefined operators that can be used. They are: 
@@ -565,21 +565,21 @@ You can select an entity either by its rank or by its handle (an entity's handle
 
 <h5>Selection by rank</h5>
 Use method *StepData_StepModel::NextNumberForLabel* to find its rank with the following: 
-~~~~~
+~~~~{.cpp}
 Standard_CString label = `#...'; 
 StepData_StepModel model = reader.StepModel(); 
 rank = model->NextNumberForLabe(label, 0, Standard_False); 
-~~~~~
+~~~~
 Translate an entity specified by its rank: 
-~~~~~
+~~~~{.cpp}
 Standard_Boolean ok = reader.Transfer (rank); 
-~~~~~
+~~~~
 
 <h5>Direct selection of an entity</h5>
 *ent* is the entity. The argument is a *Handle(Standard_Transient)*. 
-~~~~~
+~~~~{.cpp}
 Standard_Boolean ok = reader.TransferEntity (ent); 
-~~~~~
+~~~~
 
 @subsection occt_step_2_4 Mapping STEP entities to Open CASCADE Technology shapes
 Tables given in this paragraph show the mapping of STEP entities to OCCT objects. Only topological and geometrical STEP entities and entities defining assembly structures are described in this paragraph. For a full list of STEP entities, refer to Appendix A. 
@@ -777,7 +777,7 @@ The following diagram illustrates the structure of calls in reading STEP. The hi
 @figure{/user_guides/step/images/step_image003.png,"The structure of calls in reading STEP",420}
   
 @subsection occt_step_2_7 Example
-~~~~~
+~~~~{.cpp}
 #include <STEPControl_Reader.hxx> 
 #include <TopoDS_Shape.hxx> 
 #include <BRepTools.hxx> 
@@ -804,7 +804,7 @@ Standard_Integer main()
   . . . 
 
 } 
-~~~~~
+~~~~
 
 
 @section occt_step_3 Writing STEP
@@ -836,9 +836,9 @@ See also @ref occt_step_3_4 "Mapping OCCT shapes to STEP entities".
 @subsection occt_step_3_3 Description of the process
 @subsubsection occt_step_3_3_1 Initializing the process
 Before performing any other operation you have to create a writer object: 
-~~~~~
+~~~~{.cpp}
 STEPControl_Writer writer; 
-~~~~~
+~~~~
 @subsubsection occt_step_3_3_2 Setting the translation parameters
 
 The following parameters are used for the OCCT-to-STEP translation. 
@@ -855,10 +855,10 @@ Read this parameter with:
 
 Standard_Integer ic = Interface_Static::IVal("write.precision.mode"); 
 Modify this parameter with: 
-~~~~~
+~~~~{.cpp}
 if(!Interface_Static::SetIVal("write.precision.mode",1))  
 .. error .. 
-~~~~~
+~~~~
 Default value is 0. 
 
 <h4>write.precision.val</h4>
@@ -869,15 +869,15 @@ a user-defined precision value. This parameter gives the uncertainty for STEP en
 This value is stored in shape_representation in a STEP file as an uncertainty. 
 
 Read this parameter with: 
-~~~~~
+~~~~{.cpp}
 Standard_Real rp = Interface_Static::RVal("write.precision.val");  
-~~~~~
+~~~~
 
 Modify this parameter with: 
-~~~~~
+~~~~{.cpp}
 if(!Interface_Static::SetRVal("write.precision.val",0.01))  
 .. error .. 
-~~~~~
+~~~~
 Default value is 0.0001. 
 
 <h4>write.step.assembly</h4>
@@ -887,14 +887,14 @@ writing assembly mode.
 * 2 (Auto) : writes shapes having a structure of (possibly nested) *TopoDS_Compounds* in the form of STEP assemblies, single shapes are written without assembly structures. 
 
 Read this parameter with: 
-~~~~~
+~~~~{.cpp}
 Standard_Integer rp = Interface_Static::IVal("write.step.assembly"); 
-~~~~~
+~~~~
 Modify this parameter with: 
-~~~~~
+~~~~{.cpp}
 if(!Interface_Static::SetIVal("write.step.assembly",1))  
 .. error .. 
-~~~~~
+~~~~
 Default value is 0. 
 
 <h4>write.step.schema</h4>
@@ -906,14 +906,14 @@ defines the version of schema used for the output STEP file:
     * 5 or *AP242DIS*: AP242, DIS version. 
 
 Read this parameter with: 
-~~~~~
+~~~~{.cpp}
 TCollection_AsciiString schema = Interface_Static::CVal("write.step.schema"); 
-~~~~~
+~~~~
 Modify this parameter with: 
-~~~~~
+~~~~{.cpp}
 if(!Interface_Static::SetCVal("write.step.schema","DIS"))  
 .. error .. 
-~~~~~
+~~~~
 Default value is 1 (;CD;). 
 For the parameter *write.step.schema* to take effect, method *STEPControl_Writer::Model(Standard_True)* should be called after changing this parameter (corresponding command in DRAW is *newmodel*).
  
@@ -929,14 +929,14 @@ This parameter indicates whether parametric curves (curves in parametric space o
 * On (1) : (default) writes pcurves to STEP file 
 
 Read this parameter with: 
-~~~~~
+~~~~{.cpp}
 Standard_Integer wp = Interface_Static::IVal("write.surfacecurve.mode"); 
-~~~~~
+~~~~
 Modify this parameter with: 
-~~~~~
+~~~~{.cpp}
 if(!Interface_Static::SetIVal("write.surfacecurve.mode",1))  
 .. error .. 
-~~~~~
+~~~~
 Default value is On. 
 
 <h4>write.step.unit</h4>
@@ -959,14 +959,14 @@ This parameter indicates which of free vertices writing mode is switch on.
 * 1 (Single Vertex) : Each vertex exported in its own SHAPE DEFINITION REPRESENTATION (vertex name and style are not lost, but size of STEP file increases). 
 
 Read this parameter with: 
-~~~~~
+~~~~{.cpp}
 Standard_Integer ic = Interface_Static::IVal("write.step.vertex.mode"); 
-~~~~~
+~~~~
 Modify this parameter with: 
-~~~~~
+~~~~{.cpp}
 if(!Interface_Static::SetIVal("write.step.vertex.mode",1))  
 .. error .. 
-~~~~~
+~~~~
 Default value is 0. 
  
 @subsubsection occt_step_3_3_3 Performing the Open CASCADE Technology shape translation
@@ -995,16 +995,16 @@ The following list shows which shapes can be translated in which mode:
 If *TopoDS_Compound* contains any other types besides the ones mentioned in the table, these sub-shapes will be ignored. 
 
 In case if an OCCT shape cannot be translated according to its mode the result of translation is void. 
-~~~~~
+~~~~{.cpp}
 STEP214Control_StepModelTope mode = STEP214Control_ManifoldSolidBrep; 
 IFSelect_ReturnStatus stat = writer.Transfer(shape,mode); 
-~~~~~
+~~~~
 
 @subsubsection occt_step_3_3_4 Writing the STEP file
 Write the STEP file with: 
-~~~~~
+~~~~{.cpp}
 IFSelect_ReturnStatus stat = writer.Write("filename.stp"); 
-~~~~~
+~~~~
 to give the file name. 
 
 @subsection occt_step_3_4 Mapping Open CASCADE Technology shapes to STEP entities
@@ -1116,7 +1116,7 @@ The highlighted classes are intended to translate geometry.
 
     
 @subsection occt_step_3_7 Example
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~{.cpp}
+~~~~{.cpp}
 #include <STEPControl.hxx> 
 #include <STEPControl_Writer.hxx> 
 #include <TopoDS_Shape.hxx> 
@@ -1136,7 +1136,7 @@ writer.Write(;Output.stp;);
 // writes the resulting entity in the STEP file 
 
 } 
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~~~~
 
 @section occt_step_4 Physical STEP file reading and writing
 
@@ -1228,9 +1228,9 @@ In the description of commands, square brackets ([]) are used to indicate option
  
 @subsection occt_step_6_2 Setting the interface parameters
 A set of parameters for importing and exporting STEP data is defined in the XSTEP resource file. In XSDRAW, these parameters can be viewed or changed using the command 
-~~~~~
+~~~~{.php}
 Draw:> param [<parameter_name> [<value>]] 
-~~~~~
+~~~~
 Command *param* with no arguments gives a list of all parameters with their values. When the argument *parameter_name* is specified, information about this parameter is printed (current value and short description). 
 
 The third argument is used to set a new value of the given parameter. The result of the setting is printed immediately. 
@@ -1259,14 +1259,14 @@ For reading a STEP file, the following parameters are defined (see above, @ref o
 
 It is possible either only to load a STEP file into memory (i.e. fill the *InterfaceModel* with data from the file), or to read it (i.e. load and convert all entities to OCCT shapes). 
 Loading is done by the command 
-~~~~~
+~~~~{.php}
 Draw:> xload <file_name>
-~~~~~
+~~~~
 Once the file is loaded, it is possible to investigate the structure of the loaded data. To find out how you do it, look in the beginning of the analysis subsection. 
 Reading a STEP file is done by the command 
-~~~~~
+~~~~{.php}
 Draw:> stepread <file_name> <result_shape_name> [selection] 
-~~~~~
+~~~~
 Here a dot can be used instead of a filename if the file is already loaded by xload or stepread. 
 The optional selection (see below for a description of selections) specifies a set of entities to be translated. If an asterisk `*' is given, all transferable roots are translated. If a selection is not given, the user is prompted to define a scope of transfer interactively: 
 
@@ -1301,7 +1301,7 @@ The procedure of analysis of data import can be divided into two stages:
 
 General statistics on the loaded data can be obtained by using the command 
 
-~~~~
+~~~~{.php}
 Draw:> data <symbol> 
 ~~~~
 
@@ -1333,10 +1333,10 @@ The command *listtypes* gives a list of entity types, which were encountered in
 The list cannot be shown for all entities but for a subset of them. This subset is defined by an optional selection argument (for the list of possible values for STEP, see the table above).
  
 Two commands are used to calculate statistics on the entities in the model: 
-~~~~~
+~~~~{.php}
 Draw:> count <counter> [<selection>] 
 Draw:> listcount <counter> [<selection>] 
-~~~~~
+~~~~
 The former only prints a count of entities while the latter also gives a list of them. 
 
 The optional selection argument, if specified, defines a subset of entities, which are to be taken into account. The first argument should be one of the currently defined counters: 
@@ -1407,9 +1407,9 @@ For writing shapes to a STEP file, the following parameters are defined (see abo
 Several shapes can be written in one file. To start writing a new file, enter command *Draw:> newmodel*. 
 Actually, command *newmodel* will clear the *InterfaceModel* to empty it, and the next command will convert the specified shape to STEP entities and add them to the *InterfaceModel*: 
 
-~~~~~
+~~~~{.php}
 Draw:> stepwrite <mode> <shape_name> [<file_name>] 
-~~~~~
+~~~~
 
 The following  modes are available : 
     * *a* -- "as is" -- the mode is selected automatically depending on the type & geometry of the shape;
@@ -1419,10 +1419,10 @@ The following  modes are available :
     * *s* -- *shell_based_surface_model* 
  
 After a successful translation, if *file_name* parameter is not specified, the procedure asks you whether to write a STEP model in the file or not: 
-~~~~~
+~~~~{.php}
 execution status : 1 
 Mode (0 end, 1 file) : 
-~~~~~
+~~~~
 It is necessary to call command *newmodel* to perform a new translation of the next OCCT shape. 
 
 @section occt_step_7 Reading from and writing to STEP
@@ -1441,10 +1441,10 @@ In addition to the translation of shapes implemented in basic translator, it pro
 
 ### Load a STEP file
 Before performing any other operation, you must load a STEP file with: 
-~~~~~
+~~~~{.cpp}
 STEPCAFControl_Reader reader(XSDRAW::Session(), Standard_False); 
 IFSelect_ReturnStatus stat = reader.ReadFile("filename.stp"); 
-~~~~~
+~~~~
 Loading the file only memorizes the data, it does not translate it. 
 
 ### Check the loaded STEP file
@@ -1456,22 +1456,22 @@ See a description of this step in section @ref occt_step_2_3_3 "Setting the tran
 
 In addition, the following parameters can be set for XDE translation of attributes: 
   *  Parameter for transferring colors: 
-~~~~~  
+~~~~{.cpp}
 reader.SetColorMode(mode); 
 // mode can be Standard_True or Standard_False 
-~~~~~
+~~~~
   *  Parameter for transferring names: 
-~~~~~    
+~~~~{.cpp}
 reader.SetNameMode(mode); 
 // mode can be Standard_True or Standard_False 
-~~~~~
+~~~~
 
 ### Translate a STEP file to XDE
 
 The following function performs a translation of the whole document: 
-~~~~~
+~~~~{.cpp}
 Standard_Boolean ok = reader.Transfer(doc); 
-~~~~~
+~~~~
 where *doc* is a variable which contains a handle to the output document and should have a type *Handle(TDocStd_Document)*. 
 
 
@@ -1585,42 +1585,42 @@ For each Saved View OCCT STEP Reader will retrieve the following attributes:
 @subsection occt_step_7_3 Writing to STEP
 
 The translation from XDE to STEP can be initialized as follows: 
-~~~~~
+~~~~{.cpp}
 STEPCAFControl_Writer aWriter(XSDRAW::Session(),Standard_False); 
-~~~~~
+~~~~
 
 ### Set parameters for translation from XDE to STEP
 
 The following parameters can be set for a translation of attributes to STEP: 
   *  For transferring colors: 
-~~~~~
+~~~~{.cpp}
 aWriter.SetColorMode(mode); 
 // mode can be Standard_True or Standard_False 
-~~~~~
+~~~~
   *  For transferring names: 
-~~~~~
+~~~~{.cpp}
 aWriter.SetNameMode(mode); 
 // mode can be Standard_True or Standard_False 
-~~~~~
+~~~~
 
 ### Translate an XDE document to STEP
 
 You can perform the translation of document by calling the function: 
-~~~~~
+~~~~{.cpp}
 IFSelect_ReturnStatus aRetSt = aWriter.Transfer(doc); 
-~~~~~
+~~~~
 where *doc*  is a variable, which contains a handle to the input document for transferring and should have a type *Handle(TDocStd_Document)*. 
 
 ### Write a STEP file
 
 Write a STEP file with: 
-~~~~~
+~~~~{.cpp}
 IFSelect_ReturnStatus statw = aWriter.WriteFile("filename.stp"); 
-~~~~~
+~~~~
 or 
-~~~~~
+~~~~{.cpp}
 IFSelect_ReturnStatus statw = writer.WriteFile (S); 
-~~~~~
+~~~~
 where *S* is *OStream*. 
 
 @subsection occt_step_7_4 Attributes written to STEP 
@@ -1649,13 +1649,13 @@ All entities, which can be imported from STEP, can be exported too.
 See the same item in section @ref occt_step_7_1 "Reading from STEP" to find more information.
 
 Note: OCCT use AP214 by default, so for GD&T exporting AP242 should be set manually:
-~~~~~
+~~~~{.cpp}
 Interface_Static::SetCVal("write.step.schema", "AP242DIS"));  
-~~~~~
+~~~~
 or
-~~~~~
+~~~~{.cpp}
 Interface_Static::SetIVal("write.step.schema", 5));  
-~~~~~
+~~~~
 ### Saved views
 Saved Views are not exported by OCCT.
 
index 1bdb4835c943c926333ae56903763fa5449a3989..f60161f435f8a039d60253543764206323ab6932 100644 (file)
@@ -75,7 +75,7 @@ Additionally, *IVtkTools* package contains auxiliary methods in *IVtkTools* name
 To visualize an OCCT topological shape in VTK viewer, it is necessary to perform the following steps:
 
 1. Create *IVtkOCC_Shape* instance (VIS wrapper for OCCT shape) and initialize it with *TopoDS_Shape* object containing the actual geometry:
-~~~~
+~~~~{.cpp}
 TopoDS_Shape aShape;
 
 // Initialize aShape variable: e.g. load it from BREP file
@@ -83,13 +83,13 @@ TopoDS_Shape aShape;
 IVtkOCC_Shape::Handle aShapeImpl = new IVtkOCC_Shape(aShape);
 ~~~~
 2. Create VTK polygonal data source for the target OCCT topological shape and initialize it with created *IVtkOCC_Shape* instance. At this stage the faceter is implicitly plugged:
-~~~~
+~~~~{.cpp}
 vtkSmartPointer<IVtkTools_ShapeDataSource> DS = vtkSmartPointer<IVtkTools_ShapeDataSource>::New();
 
 DS->SetShape(aShapeImpl);
 ~~~~
 3. Visualize the loaded shape in usual VTK way starting a pipeline from the newly created specific source:
-~~~~
+~~~~{.cpp}
 vtkSmartPointer<vtkPolyDataMapper> Mapper = vtkSmartPointer<vtkPolyDataMapper>::New();
 
 Mapper->SetInputConnection(aDS->GetOutputPort());
@@ -99,14 +99,14 @@ Actor->SetMapper(Mapper);
 ~~~~
 
 It is always possible to access the shape data source from VTK actor by means of dedicated methods from *IVtkTools_ShapeObject* class:
-~~~~
+~~~~{.cpp}
 IVtkTools_ShapeDataSource* DS = IVtkTools_ShapeObject::GetShapeSource(Actor);
 
 IVtkOCC_Shape::Handle occShape = IVtkTools_ShapeObject::GetOccShape(Actor);
 ~~~~
 
 It is also possible to get a shape wrapper from the shape data source:
-~~~~
+~~~~{.cpp}
 IVtkOCC_Shape::Handle occShape = DS->GetShape();
 ~~~~
 
@@ -115,26 +115,26 @@ IVtkOCC_Shape::Handle occShape = DS->GetShape();
 
 To colorize different parts of a shape according to the default OCCT color scheme, it is possible to configure the corresponding VTK mapper using a dedicated auxiliary function of *IVtkTools* namespace:
 
-~~~~
+~~~~{.cpp}
 IVtkTools::InitShapeMapper(Mapper);
 ~~~~
 It is possible to get an instance of *vtkLookupTable class* with a default OCCT color scheme by means of the following method:
 
-~~~~
+~~~~{.cpp}
 vtkSmartPointer<vtkLookupTable> Table = IVtkTools::InitLookupTable();
 ~~~~
 
 @subsubsection occt_vis_3_2_2  Custom color scheme
 To set up application-specific colors for a shape presentation, use *InitShapeMapper* function with an additional argument passing a custom lookup table:
 
-~~~~
+~~~~{.cpp}
 IVtkTools::InitShapeMapper(Mapper, Table);
 ~~~~
 
 @subsubsection occt_vis_3_2_3  Setting custom colors for sub-shapes
 
 It is also possible to bind custom colors to any sub-shape type listed in *IVtk_MeshType* enumeration. For example, to access the color bound to *free edge* entities, the following calls are available in *IVtkTools* namespace:
-~~~~
+~~~~{.cpp}
 SetLookupTableColor(aLookupTable, MT_FreeEdge, R, G, B);
 SetLookupTableColor(aLookupTable, MT_FreeEdge, R, G, B, A);
 GetLookupTableColor(aLookupTable, MT_FreeEdge, R, G, B);
@@ -146,7 +146,7 @@ Here *R, G, B* are double values of red, green and blue components of a color fr
 
 As VTK color mapping approach is based on associating scalar data arrays to VTK cells, the coloring of shape components can be turned on/off in the following way:
 
-~~~~
+~~~~{.cpp}
 Mapper->ScalarVisibilityOn();  // use colors from lookup table
 Mapper->ScalarVisibilityOff(); // use a color of actor’s property
 ~~~~
@@ -160,7 +160,7 @@ The output of the shape data source can be presented in wireframe or shading dis
 
 For example, the shading representation can be obtained in the following way:
 
-~~~~
+~~~~{.cpp}
 vtkSmartPointer<IVtkTools_ShapeDataSource> DS = vtkSmartPointer<IVtkTools_ShapeDataSource>::New();
 
 vtkSmartPointer<IVtkTools_DisplayModeFilter> DMFilter = vtkSmartPointer<IVtkTools_DisplayModeFilter>::New();
@@ -181,57 +181,57 @@ TIP: to make the shading representation smooth, use additional *vtkPolyDataNorma
 @subsection occt_vis_3_4        Interactive selection
 *IVtkTools* package provides *IVtkTools_ShapePicker* class to perform selection of OCCT shapes and sub-shapes in VTK viewer and access the picking results. The typical usage of *IVtkTools_ShapePicker* tool consists in the following sequence of actions:
 1. Create a picker and set its renderer to your active VTK renderer:
-~~~~
+~~~~{.cpp}
 vtkSmartPointer<IVtkTools_ShapePicker> aPicker = vtkSmartPointer<IVtkTools_ShapePicker>::New();
 
 aPicker->SetRenderer(aRenderer);
 ~~~~
 2. Activate the desired selection mode by choosing the corresponding sub-shape types from *IVtk_SelectionMode* enumeration. For example, the following call allows selection of edges on all selectable shape actors of the renderer:
-~~~~
+~~~~{.cpp}
 aPicker->SetSelectionMode(SM_Edge);
 ~~~~
 If it is necessary to limit selection by a particular shape actor, one can use the mentioned *SetSelectionMode* method with *IVtk_IShape* handle or *vtkActor* pointer as the first argument:
-~~~~
+~~~~{.cpp}
 IVtk_IShape::Handle aShape = new IVtkOCC_Shape(occShape);
 aPicker->SetSelectionMode(aShape, SM_Edge); // If shape handle is available
 aPicker->SetSelectionMode(anActor, SM_Edge); // If shape actor is available
 ~~~~
 Different selection modes can be turned on/off for a picker at the same time independently from each other.
-~~~~
+~~~~{.cpp}
 aPicker->SetSelectionMode(SM_Edge);
 aPicker->SetSelectionMode(SM_Face);
 ~~~~
 To turn off a selection mode, the additional optional Boolean parameter is used with *false* value, for example:
-~~~~
+~~~~{.cpp}
 aPicker->SetSelectionMode(aShape, SM_Edge, false);
 ~~~~
 3. Call *Pick* method passing the mouse display coordinates:
-~~~~
+~~~~{.cpp}
 aPicker->Pick(x, y, 0);
 ~~~~
 By default, the renderer passed in the step 1 is used. In order to perform pick operation for another renderer an additional optional parameter can be specified:
-~~~~
+~~~~{.cpp}
 aPicker->Pick(x, y, 0, aRenderer);
 ~~~~
 4. Obtain the top-level picking results as a collection of picked VTK actors:
-~~~~
+~~~~{.cpp}
 vtkActorCollection* anActorCollection = aPicker->GetPickedActors();
 ~~~~
 or as a collection of picked shape IDs:
-~~~~
+~~~~{.cpp}
 IVtk_ShapeIdList ids = aPicker->GetPickedShapesIds();
 ~~~~
 These methods return a single top picked actor or a shape by default. To get all the picked actors or shapes it is necessary to send “true” value in the optional Boolean parameter:
-~~~~
+~~~~{.cpp}
 anActorCollection = aPicker->GetPickedActors(true);
 ids = aPicker->GetPickedShapesIds(true);
 ~~~~
 5. Obtain the picked sub-shape IDs:
-~~~~
+~~~~{.cpp}
 IVtk_ShapeIdList subShapeIds = aPicker->GetPickedSubShapesIds(shapeId);
 ~~~~
 This method also returns a single ID of a top-level picked sub-shape and has the same optional Boolean parameter to get all the picked sub-shapes of a shape:
-~~~~
+~~~~{.cpp}
 subShapeIds = aPicker->GetPickedSubShapesIds(shapeId, true);
 ~~~~
 
@@ -249,7 +249,7 @@ WARNING: VIS picker essentially works on the initial topological data structures
 
 For example, sub-shapes can be represented in VTK viewer in the following way:
 
-~~~~
+~~~~{.cpp}
 // Load a shape into data source (see 3.1)
 ...
 vtkSmartPointer<IVtkTools_ShapeDataSource> DS = vtkSmartPointer<IVtkTools_ShapeDataSource>::New();
@@ -286,7 +286,7 @@ The low-level scenario of VIS usage in VTK pipeline is shown in the figure below
 
 The visualization pipeline for OCCT shape presentation can be initialized as follows:
 1. Create an instance of *IShape* class initialized by OCCT topological shape:
-~~~~
+~~~~{.cpp}
 TopoDS_Shape aShape;
 
 // Load or create a TopoDS_Shape in the variable a Shape
@@ -294,15 +294,15 @@ TopoDS_Shape aShape;
 IVtkOCC_Shape::Handle aShapeImpl = new IVtkOCC_Shape(aShape);
 ~~~~
 2. Create an empty instance of IShapeData implementation for VTK:
-~~~~
+~~~~{.cpp}
 IVtk_IShapeData::Handle aDataImpl = new IVtkVTK_ShapeData();
 ~~~~
 3 Create an instance of *IShapeMesher* implementation for OCCT (any faceter can be used at this stage):
-~~~~
+~~~~{.cpp}
 IVtk_IShapeMesher::Handle aMesher = new IVtkOCC_ShapeMesher();
 ~~~~
 4 Triangulate the OCCT topological shape by means of the Mesher and access the result:
-~~~~
+~~~~{.cpp}
 aMesher->Build (aShapeImpl, aDataImpl);
 
 vtkPolyData* aPolyData = aDataImpl->GetVtkPolyData();
@@ -323,17 +323,17 @@ Picking algorithm  uses an instance of viewer selector (OCCT term), which manage
 
 The typical usage of *IVtk_IShapePickerAlgo* consists in the following sequence of actions:
 1. Create an instance of the picker class:
-~~~~
+~~~~{.cpp}
 IVtkOCC_ShapePickerAlgo::Handle Picker = new IVtkOCC_ShapePickerAlgo();
 ~~~~
 
 2. Set an instance of *IVtk_IView* class to the algorithm in order to define the viewer parameters:
-~~~~
+~~~~{.cpp}
 IVtkVTK_View::Handle View = new IVtkVTK_View(Renderer);
 Picker->SetView(View);
 ~~~~
 3. Activate the desired selection modes using values from *IVtk_SelectionMode* enumeration. For example, the following call allows selection of edges:
-~~~~
+~~~~{.cpp}
 TopoDS_Shape aShape;
 // Load or create a TopoDS_Shape in the variable a Shape
 ...
@@ -343,19 +343,19 @@ myOccPickerAlgo->SetSelectionMode(occShape, SM_Edge);
 ~~~~
 Different selection modes can be turned on/off for a picker at the same time independently from each other.
 To turn off a selection mode the additional optional Boolean parameter is used with *false* value, for example:
-~~~~
+~~~~{.cpp}
 myOccPickerAlgo->SetSelectionMode(occShape, SM_Edge, false);
 ~~~~
 4. Call *Pick* method passing the mouse coordinates:
-~~~~
+~~~~{.cpp}
 myOccPickerAlgo->Pick(x, y);
 ~~~~
 5. Obtain top-level picking results as IDs of the picked top-level shapes:
-~~~~
+~~~~{.cpp}
 IVtk_ShapeIdList ids = myOccPickerAlgo->ShapesPicked();
 ~~~~
 6. Obtain IDs of the picked sub-shapes:
-~~~~
+~~~~{.cpp}
 IVtk_ShapeIdList subShapeIds
   = myOccPickerAlgo->SubShapesPicked(shapeId);
 ~~~~
index 066340a8b8c8ed7288e3ce979b4803accd826244..bc96d5d34b5fa14be0d4744c744e9ece5423a78c 100644 (file)
@@ -107,7 +107,7 @@ Additional packages, such as *Prs3d* and *Graphic3d* may be used if you need to
 
 @subsubsection occt_visu_2_1_3 A Basic Example: How to display a 3D object
 
-~~~~~{.cpp}
+~~~~{.cpp}
 Handle(V3d_Viewer) theViewer;
 Handle(AIS_InteractiveContext) aContext = new AIS_InteractiveContext (theViewer);
 
@@ -115,7 +115,7 @@ BRepPrimAPI_MakeWedge aWedgeMaker (theWedgeDX, theWedgeDY, theWedgeDZ, theWedgeL
 TopoDS_Solid aShape = aWedgeMaker.Solid();
 Handle(AIS_Shape) aShapePrs = new AIS_Shape (aShape); // creation of the presentable object
 aContext->Display (aShapePrs, AIS_Shaded, 0, true);   // display the presentable object and redraw 3d viewer
-~~~~~
+~~~~
 
 The shape is created using the *BRepPrimAPI_MakeWedge* command.
 An *AIS_Shape* is then created from the shape.
@@ -450,7 +450,7 @@ After these steps, the selection manager of the created interactive context will
 The code snippet below illustrates the above steps.
 It also contains the code to start the detection procedure and parse the results of selection.
 
-~~~~~{.cpp}
+~~~~{.cpp}
 // Suppose there is an instance of class InteractiveBox from the previous sample.
 // It contains an implementation of method InteractiveBox::ComputeSelection() for selection
 // modes 0 (whole box must be selected) and 1 (edge of the box must be selectable)
@@ -478,7 +478,7 @@ for (theContext->InitSelected(); theContext->MoreSelected() && !aHasSelected; th
 
 // deactivate all selection modes for aBox1
 theContext->Deactivate (aBox1);
-~~~~~
+~~~~
 
 It is also important to know, that there are 2 types of detection implemented for rectangular selection in OCCT:
   - <b>inclusive</b> detection.
@@ -489,14 +489,14 @@ It is also important to know, that there are 2 types of detection implemented fo
 The standard OCCT selection mechanism uses inclusion detection by default.
 To change this, use the following code:
 
-~~~~~{.cpp}
+~~~~{.cpp}
 // Assume there is a created interactive context
 const Handle(AIS_InteractiveContext) theContext;
 // Retrieve the current viewer selector
 const Handle(StdSelect_ViewerSelector3d)& aMainSelector = theContext->MainSelector();
 // Set the flag to allow overlap detection
 aMainSelector->AllowOverlapDetection (true);
-~~~~~
+~~~~
 
 @section occt_visu_3 Application Interactive Services
 @subsection occt_visu_3_1 Introduction
@@ -550,18 +550,18 @@ If you are creating your own type of interactive object, you must implement the
 
 #### For 3D:
 
-~~~~~{.cpp}
+~~~~{.cpp}
 void PackageName_ClassName::Compute (const Handle(PrsMgr_PresentationManager)& thePresentationManager,
                                      const Handle(Prs3d_Presentation)& thePresentation,
                                      const Standard_Integer theMode);
-~~~~~
+~~~~
 
 #### For hidden line removal (HLR) mode in 3D:
 
-~~~~~{.cpp}
+~~~~{.cpp}
 void PackageName_ClassName::Compute (const Handle(Prs3d_Projector)& theProjector,
                                      const Handle(Prs3d_Presentation)& thePresentation);
-~~~~~
+~~~~
 
 @subsubsection occt_visu_3_2_2 Hidden Line Removal
 
@@ -641,7 +641,7 @@ you can cancel its "infinite" status using *AIS_InteractiveObject::SetInfiniteSt
 
 Let us take for example the class called *IShape* representing an interactive object:
 
-~~~~~{.cpp}
+~~~~{.cpp}
 myPk_IShape::myPk_IShape (const TopoDS_Shape& theShape, PrsMgr_TypeOfPresentation theType)
 : AIS_InteractiveObject (theType), myShape (theShape) { SetHilightMode (0); }
 
@@ -669,7 +669,7 @@ void myPk_IShape::Compute (const Handle(Prs3d_Projector)& theProjector,
   // Hidden line mode calculation algorithm
   StdPrs_HLRPolyShape::Add (thePrs, myShape, myDrawer, theProjector);
 }  
-~~~~~
+~~~~
 
 @subsubsection occt_visu_3_2_4 Selection
 
@@ -804,14 +804,14 @@ Instances can be controlled by the following DRAW commands:
 * *vlistconnected* : Lists objects in the assembly.
 
 Have a look at the examples below:
-~~~~~
+~~~~{.php}
 pload MODELING VISUALIZATION
 vinit
 psphere s 1
 vdisplay s
 vconnectto s2 3 0 0 s  # make instance
 vfit
-~~~~~
+~~~~
 
 See how proxy *OpenGl_Structure* is used to represent instance:
 
@@ -820,7 +820,7 @@ See how proxy *OpenGl_Structure* is used to represent instance:
 The original object does not have to be displayed in order to make instance.
 Also selection handles transformations of instances correctly:
 
-~~~~~
+~~~~{.php}
 pload MODELING VISUALIZATION
 vinit
 psphere s 1
@@ -829,13 +829,13 @@ vdisplay s             # p is not displayed
 vsetloc s -2 0 0
 vconnect x 3 0 0 s p   # make assembly
 vfit
-~~~~~
+~~~~
 
 @figure{/user_guides/visualization/images/visualization_image030.png,"",420}
 
 Here is the example of a more complex hierarchy involving sub-assemblies:
 
-~~~~~
+~~~~{.php}
 pload MODELING VISUALIZATION
 vinit
 box b 1 1 1
@@ -851,7 +851,7 @@ vconnect z 2 0 0 b s
 vconnect z2 4 0 0 d d2
 vconnect z3 6 0 0 z z2
 vfit
-~~~~~
+~~~~
 
 @subsection occt_visu_3_3 Interactive Context
 
@@ -863,20 +863,20 @@ Most functions which allow modifying the attributes of interactive objects, and
 There is one essential rule to follow: the modification of an interactive object, which is already known by the Context, must be done using Context functions.
 You can only directly call the functions available for an interactive object if it has not been loaded into an Interactive Context.
 
-~~~~~{.cpp}
+~~~~{.cpp}
 Handle(AIS_Shape) aShapePrs = new AIS_Shape (theShape);
 myIntContext->Display (aShapePrs, AIS_Shaded, 0, false, aShapePrs->AcceptShapeDecomposition());
 myIntContext->SetColor(aShapePrs, Quantity_NOC_RED);
-~~~~~
+~~~~
 
 You can also write
 
-~~~~~{.cpp}
+~~~~{.cpp}
 Handle(AIS_Shape) aShapePrs = new AIS_Shape (theShape);
 aShapePrs->SetColor (Quantity_NOC_RED);
 aShapePrs->SetDisplayMode (AIS_Shaded);
 myIntContext->Display (aShapePrs);
-~~~~~
+~~~~
 
 @subsubsection occt_visu_3_3_2 Groups of functions
 
@@ -903,14 +903,14 @@ When you change a graphic attribute pertaining to the Context (visualization mod
 
 Let us examine the case of two interactive objects: *theObj1* and *theObj2*:
 
-~~~~~{.cpp}
+~~~~{.cpp}
 theCtx->Display (theObj1, false);
 theCtx->Display (theObj2, true);  // TRUE for viewer update
 theCtx->SetDisplayMode (theObj1, 3, false);
 theCtx->SetDisplayMode (2, true);
 // theObj2 is visualized in mode 2 (if it accepts this mode)
 // theObj1 stays visualized in its mode 3
-~~~~~
+~~~~
 
 *PrsMgr_PresentationManager* and *SelectMgr_ViewerSelector3d*, which manage the presentation and selection of present interactive objects, are associated to the main Viewer.
 
@@ -965,7 +965,7 @@ There are several functions to manipulate filters:
 
 #### Example
 
-~~~~~{.cpp}
+~~~~{.cpp}
 // shading visualization mode, no specific mode, authorization for decomposition into sub-shapes
 const TopoDS_Shape theShape;
 Handle(AIS_Shape) aShapePrs = new AIS_Shape (theShape);
@@ -982,7 +982,7 @@ myContext->AddFilter (aFil2);
 
 // only faces of revolution or planar faces will be selected
 myContext->MoveTo (thePixelX, thePixelY, myView, true);
-~~~~~
+~~~~
 
 @subsubsection occt_visu_3_4_6 Selection
 
@@ -996,10 +996,10 @@ There are only a few conventions and functions to be familiar with:
 
 Highlighting of detected and selected entities is automatically managed by the Interactive Context.
 The Highlight colors are those dealt with above. You can nonetheless disconnect this automatic mode if you want to manage this part yourself:
-~~~~~{.cpp}
+~~~~{.cpp}
   AIS_InteractiveContext::SetAutomaticHilight
   AIS_InteractiveContext::AutomaticHilight
-~~~~~
+~~~~
 
 You can question the Interactive context by moving the mouse.
 The following functions can be used:
@@ -1019,7 +1019,7 @@ In case of *AIS_Shape*, the (sub)shape is returned by method *StdSelect_BRepOwne
 
 #### Example
 
-~~~~~{.cpp}
+~~~~{.cpp}
 for (myAISCtx->InitSelected(); myAISCtx->MoreSelected(); myAISCtx->NextSelected())
 {
   Handle(SelectMgr_EntityOwner) anOwner = myAISCtx->SelectedOwner();
@@ -1030,7 +1030,7 @@ for (myAISCtx->InitSelected(); myAISCtx->MoreSelected(); myAISCtx->NextSelected(
     TopoDS_Shape aShape = aBRepOwner->Shape();
   }
 }
-~~~~~
+~~~~
 
 @subsubsection occt_visu_3_4_7 Selection schemes
 
@@ -1101,7 +1101,7 @@ and can be built up from the source data with a custom presentation builder.
 
 The class *AIS_ColoredShape* allows using custom colors and line widths for *TopoDS_Shape* objects and their sub-shapes.
 
-~~~~~{.cpp}
+~~~~{.cpp}
   AIS_ColoredShape aColoredShape = new AIS_ColoredShape (theShape);
 
   // setup color of entire shape
@@ -1118,7 +1118,7 @@ The class *AIS_ColoredShape* allows using custom colors and line widths for *Top
 
   // customize line width of specified sub-shape
   aColoredShape->SetCustomWidth (theSubShape, 0.25);
-~~~~~
+~~~~
 
 The presentation class *AIS_PointCloud* can be used for efficient drawing of large arbitrary sets of colored points.
 It uses *Graphic3d_ArrayOfPoints* to pass point data into OpenGl graphic driver to draw a set points as an array of "point sprites".
@@ -1130,14 +1130,14 @@ The point data is packed into vertex buffer object for performance.
 @figure{point_cloud.png,"A random colored cloud of points",240}
 
 Example:
-~~~~~{.cpp}
+~~~~{.cpp}
 Handle(Graphic3d_ArrayOfPoints) aPoints = new Graphic3d_ArrayOfPoints (2000, Standard_True);
 aPoints->AddVertex (gp_Pnt(-40.0, -40.0, -40.0), Quantity_Color (Quantity_NOC_BLUE1));
 aPoints->AddVertex (gp_Pnt (40.0,  40.0,  40.0), Quantity_Color (Quantity_NOC_BLUE2));
 
 Handle(AIS_PointCloud) aPntCloud = new AIS_PointCloud();
 aPntCloud->SetPoints (aPoints);
-~~~~~
+~~~~
 
 The draw command *vpointcloud* builds a cloud of points from shape triangulation.
 This command can also draw a sphere surface or a volume with a large amount of points (more than one million).
@@ -1183,42 +1183,42 @@ You can choose between the builders to represent the object in a different way.
 Moreover, you can redefine the base builder class and provide your own presentation builder.
 
 You can add/remove builders using the following methods:
-~~~~~{.cpp}
+~~~~{.cpp}
   MeshVS_Mesh::AddBuilder (const Handle(MeshVS_PrsBuilder)& theBuilder, Standard_Boolean theToTreatAsHilighter);
   MeshVS_Mesh::RemoveBuilder (const Standard_Integer theIndex);
   MeshVS_Mesh::RemoveBuilderById (const Standard_Integer theId);
-~~~~~
+~~~~
 
 There is a set of reserved display and highlighting mode flags for *MeshVS_Mesh*.
 Mode value is a number of bits that allows selecting additional display parameters and combining the following mode flags,
 which allow displaying mesh in wireframe, shading and shrink modes:
-~~~~~{.cpp}
+~~~~{.cpp}
   MeshVS_DMF_WireFrame
   MeshVS_DMF_Shading
   MeshVS_DMF_Shrink
-~~~~~
+~~~~
 
 It is also possible to display deformed mesh in wireframe, shading or shrink modes using:
-~~~~~{.cpp}
+~~~~{.cpp}
   MeshVS_DMF_DeformedPrsWireFrame
   MeshVS_DMF_DeformedPrsShading
   MeshVS_DMF_DeformedPrsShrink
-~~~~~
+~~~~
 
 The following methods represent different kinds of data:
-~~~~~{.cpp}
+~~~~{.cpp}
   MeshVS_DMF_VectorDataPrs
   MeshVS_DMF_NodalColorDataPrs
   MeshVS_DMF_ElementalColorDataPrs
   MeshVS_DMF_TextDataPrs
   MeshVS_DMF_EntitiesWithData
-~~~~~
+~~~~
 
 The following methods provide selection and highlighting:
-~~~~~{.cpp}
+~~~~{.cpp}
   MeshVS_DMF_SelectionPrs
   MeshVS_DMF_HilightPrs
-~~~~~
+~~~~
 
 *MeshVS_DMF_User* is a user-defined mode.
 
@@ -1236,7 +1236,7 @@ There is also a set of selection modes flags that can be grouped in a combinatio
 
 Such an object, for example, can be used for displaying the object and stored in the STL file format:
 
-~~~~~{.cpp}
+~~~~{.cpp}
 // read the data and create a data source
 Handle(Poly_Triangulation) aSTLMesh = RWStl::ReadFile (aFileName);
 Handle(XSDRAWSTLVRML_DataSource) aDataSource = new XSDRAWSTLVRML_DataSource (aSTLMesh);
@@ -1248,13 +1248,13 @@ aMeshPrs->SetDataSource (aDataSource);
 // use default presentation builder
 Handle(MeshVS_MeshPrsBuilder) aBuilder = new MeshVS_MeshPrsBuilder (aMeshPrs);
 aMeshPrs->AddBuilder (aBuilder, true);
-~~~~~
+~~~~
 
 *MeshVS_NodalColorPrsBuilder* allows representing a mesh with a color scaled texture mapped on it.
 To do this you should define a color map for the color scale, pass this map to the presentation builder, and define an appropriate value in the range of 0.0 - 1.0 for every node.
 The following example demonstrates how you can do this (check if the view has been set up to display textures):
 
-~~~~~{.cpp}
+~~~~{.cpp}
 // assign nodal builder to the mesh
 Handle(MeshVS_NodalColorPrsBuilder) aBuilder = new MeshVS_NodalColorPrsBuilder (theMeshPrs, MeshVS_DMF_NodalColorDataPrs | MeshVS_DMF_OCCMask);
 aBuilder->UseTexture (true);
@@ -1275,7 +1275,7 @@ aBuilder->SetColorMap (aColorMap);
 aBuilder->SetInvalidColor (Quantity_NOC_BLACK);
 aBuilder->SetTextureCoords (aScaleMap);
 aMesh->AddBuilder (aBuilder, true);
-~~~~~
+~~~~
 
 @subsection occt_visu_3_6 Dynamic Selection
 
@@ -1377,7 +1377,7 @@ You can also modify the values assigned to the vertex or query these values by t
 
 The following example shows how to define an array of points:
 
-~~~~~{.cpp}
+~~~~{.cpp}
 // create an array
 Handle(Graphic3d_ArrayOfPoints) anArray = new Graphic3d_ArrayOfPoints (theVerticiesMaxCount);
 
@@ -1389,7 +1389,7 @@ anArray->AddVertex (0.0,  10.0, 10.0);
 Handle(Graphic3d_Group) aGroup = thePrs->NewGroup();
 aGroup->AddPrimitiveArray (anArray);
 aGroup->SetGroupPrimitivesAspect (myDrawer->PointAspect()->Aspect());
-~~~~~
+~~~~
 
 If the primitives share the same vertices (polygons, triangles, etc.) then you can define them as indices of the vertices array.
 The method *Graphic3d_ArrayOfPrimitives::AddEdge* allows defining the primitives by indices.
@@ -1398,7 +1398,7 @@ It is also possible to query the vertex defined by an edge using method *Graphic
 
 The following example shows how to define an array of triangles:
 
-~~~~~{.cpp}
+~~~~{.cpp}
 // create an array
 Handle(Graphic3d_ArrayOfTriangles) anArray = new Graphic3d_ArrayOfTriangles (theVerticesMaxCount, theEdgesMaxCount, Graphic3d_ArrayFlags_None);
 // add vertices to the array
@@ -1415,7 +1415,7 @@ anArray->AddEdges (1, 2, 4); // second triangle
 Handle(Graphic3d_Group) aGroup = thePrs->NewGroup();
 aGroup->AddPrimitiveArray (anArray);
 aGroup->SetGroupPrimitivesAspect (myDrawer->ShadingAspect()->Aspect());
-~~~~~
+~~~~
 
 @subsubsection occt_visu_4_2_5 Text primitive
 
@@ -1427,17 +1427,17 @@ aGroup->SetGroupPrimitivesAspect (myDrawer->ShadingAspect()->Aspect());
 
 The text attributes for the group could be defined with the *Graphic3d_AspectText3d* attributes group.
 To add any text to the graphic structure you can use the following methods:
-~~~~~{.cpp}
+~~~~{.cpp}
 void Graphic3d_Group::AddText (const Handle(Graphic3d_Text)& theTextParams,
                                const Standard_Boolean theToEvalMinMax);
-~~~~~
+~~~~
 
 You can pass FALSE as *theToEvalMinMax* if you do not want the Graphic3d structure boundaries to be affected by the text position.
 
 **Note** that the text orientation angle can be defined by *Graphic3d_AspectText3d* attributes.
 
 See the example:
-~~~~~{.cpp}
+~~~~{.cpp}
 // get the group
 Handle(Graphic3d_Group) aGroup = thePrs->NewGroup();
 
@@ -1452,7 +1452,7 @@ Handle(Graphic3d_Text) aText = new Graphic3d_Text (16.0f);
 aText->SetText ("Text");
 aText->SetPosition (gp_Pnt (1, 1, 1));
 aGroup->AddText (aText);
-~~~~~
+~~~~
 
 @subsubsection occt_visu_4_2_6 Materials
 
@@ -1490,7 +1490,7 @@ OCCT visualization core supports GLSL shaders.
 Custom shaders can be assigned to a generic presentation by its drawer attributes (Graphic3d aspects).
 To enable custom shader for a specific AIS_Shape in your application, the following API functions can be used:
 
-~~~~~{.cpp}
+~~~~{.cpp}
 // Create shader program
 Handle(Graphic3d_ShaderProgram) aProgram = new Graphic3d_ShaderProgram();
 
@@ -1505,7 +1505,7 @@ aProgram->PushVariable ("MyColor", Graphic3d_Vec3 (0.0f, 1.0f, 0.0f));
 
 // Set aspect property for specific AIS_Shape
 theAISShape->Attributes()->ShadingAspect()->Aspect()->SetShaderProgram (aProgram);
-~~~~~
+~~~~
 
 @subsection occt_visu_4_3 Graphic attributes
 
@@ -1540,7 +1540,7 @@ This tool set contains methods for creating and editing classes of the viewer su
 
 This sample TEST program for the *V3d* Package uses primary packages *Xw* and *Graphic3d* and secondary packages *Visual3d, Aspect, Quantity* and *math*.
 
-~~~~~{.cpp}
+~~~~{.cpp}
 // create a default display connection
 Handle(Aspect_DisplayConnection) aDispConnection = new Aspect_DisplayConnection();
 // create a Graphic Driver
@@ -1590,7 +1590,7 @@ aStruct->Display();
 aView->Update();
 // Fit view to object size
 aView->FitAll();
-~~~~~
+~~~~
 
 @subsubsection occt_visu_4_4_3 Define viewing parameters
 
@@ -1612,12 +1612,12 @@ The camera is defined by the following properties:
 Most common view manipulations (panning, zooming, rotation) are implemented as convenience methods of *V3d_View* class or by *AIS_ViewController* tool.
 However *Graphic3d_Camera* class can also be used directly by application developers.
 Example:
-~~~~~{.cpp}
+~~~~{.cpp}
 // rotate camera by X axis on 30.0 degrees
 gp_Trsf aTrsf;
 aTrsf.SetRotation (gp_Ax1 (gp_Pnt (0.0, 0.0, 0.0), gp_Dir (1.0, 0.0, 0.0)), M_PI / 4.0);
 aView->Camera()->Transform (aTrsf);
-~~~~~
+~~~~
 
 @subsubsection occt_visu_4_4_4 Orthographic Projection
 
@@ -1625,12 +1625,12 @@ aView->Camera()->Transform (aTrsf);
 
 The following code configures the camera for orthographic rendering:
 
-~~~~~{.cpp}
+~~~~{.cpp}
 // Create an orthographic View in this Viewer
 Handle(V3d_View) aView = new V3d_View (theViewer);
 aView->Camera()->SetProjectionType (Graphic3d_Camera::Projection_Orthographic);
 aView->Update(); // update the Visualization in this View
-~~~~~
+~~~~
 
 @subsubsection occt_visu_4_4_5 Perspective Projection
 
@@ -1640,12 +1640,12 @@ aView->Update(); // update the Visualization in this View
 
 The following code configures the camera for perspective rendering:
 
-~~~~~{.cpp}
+~~~~{.cpp}
 // Create a perspective View in this Viewer
 Handle(V3d_View) aView = new V3d_View (theViewer);
 aView->Camera()->SetProjectionType (Graphic3d_Camera::Projection_Perspective);
 aView->Update();
-~~~~~
+~~~~
 
 @subsubsection occt_visu_4_4_6 Stereographic Projection
 
@@ -1673,15 +1673,15 @@ In a non-stereo camera this effect is not visible because only the same projecti
 
 To enable quad buffering support you should provide the following settings to the graphic driver *OpenGl_Caps*:
 
-~~~~~{.cpp}
+~~~~{.cpp}
 Handle(OpenGl_GraphicDriver) aDriver = new OpenGl_GraphicDriver();
 OpenGl_Caps& aCaps = aDriver->ChangeOptions();
 aCaps.contextStereo = Standard_True;
-~~~~~
+~~~~
 
 The following code configures the camera for stereographic rendering:
 
-~~~~~{.cpp}
+~~~~{.cpp}
 // Create a Stereographic View in this Viewer
 Handle(V3d_View) aView = new V3d_View (theViewer);
 aView->Camera()->SetProjectionType (Graphic3d_Camera::Projection_Stereo);
@@ -1689,15 +1689,15 @@ aView->Camera()->SetProjectionType (Graphic3d_Camera::Projection_Stereo);
 aView->Camera()->SetIOD (IODType_Absolute, 5.0);
 // Finally update the Visualization in this View
 aView->Update();
-~~~~~
+~~~~
 
 Other 3D displays are also supported, including row-interlaced with passive glasses and anaglyph glasses - see *Graphic3d_StereoMode* enumeration.
 Example to activate another stereoscopic display:
-~~~~~{.cpp}
+~~~~{.cpp}
 Handle(V3d_View) theView;
 theView->Camera()->SetProjectionType (Graphic3d_Camera::Projection_Stereo);
 theView->ChangeRenderingParams().StereoParams = Graphic3d_StereoMode_RowInterlaced;
-~~~~~
+~~~~
 
 Supporting of VR/AR headsets in application is more involving.
 Class *Aspect_XRSession* defines a basic interface for working with extended reality.
@@ -1716,26 +1716,26 @@ The following features support this method:
 There are several types of background styles available for *V3d_View*: solid color, gradient color, image and environment cubemap.
 
 To set solid color for the background you can use the following method:
-~~~~~{.cpp}
+~~~~{.cpp}
 void V3d_View::SetBackgroundColor (const Quantity_Color& theColor);
-~~~~~
+~~~~
 
 The gradient background style could be set up with the following method:
-~~~~~{.cpp}
+~~~~{.cpp}
 void V3d_View::SetBgGradientColors (const Quantity_Color& theColor1,
                                     const Quantity_Color& theColor2,
                                     const Aspect_GradientFillMethod theFillStyle,
                                     const Standard_Boolean theToUpdate = false);
-~~~~~
+~~~~
 
 The *theColor1* and *theColor2* parameters define the boundary colors of interpolation, the *theFillStyle* parameter defines the direction of interpolation.
 
 To set the image as a background and change the background image style you can use the following method:
-~~~~~{.cpp}
+~~~~{.cpp}
 void V3d_View::SetBackgroundImage (const Standard_CString theFileName,
                                    const Aspect_FillMethod theFillStyle,
                                    const Standard_Boolean theToUpdate = false);
-~~~~~
+~~~~
 
 The *theFileName* parameter defines the image file name and the path to it, the *theFillStyle* parameter defines the method of filling the background with the image.
 The methods are:
@@ -1793,7 +1793,7 @@ There are several ray-tracing options that user can switch on/off:
 * Transparency shadow effects
 
 Example:
-~~~~~{.cpp}
+~~~~{.cpp}
 Graphic3d_RenderingParams& aParams = aView->ChangeRenderingParams();
 // specifies rendering mode
 aParams.Method = Graphic3d_RM_RAYTRACING;
@@ -1809,7 +1809,7 @@ aParams.IsAntialiasingEnabled = true;
 aParams.IsTransparentShadowEnabled = true;
 // update the view
 aView->Update();
-~~~~~
+~~~~
 
 @subsubsection occt_visu_4_4_14 Display priorities
 
@@ -1828,14 +1828,14 @@ In general, this function can be used for implementing "bring to front" function
 
 Example:
 
-~~~~~{.cpp}
+~~~~{.cpp}
 // set z-layer to an interactive object
 Handle(AIS_InteractiveContext) theContext;
 Handle(AIS_InteractiveObject) theInterObj;
 Standard_Integer anId = -1;
 aViewer->AddZLayer (anId);
 theContext->SetZLayer (theInterObj, anId);
-~~~~~
+~~~~
 
 For each z-layer, it is allowed to:
 * Enable / disable depth test for layer.
@@ -1847,7 +1847,7 @@ You can get the options using getter from *V3d_Viewer*.
 It returns *Graphic3d_ZLayerSettings* for a given *LayerId*.
 
 Example:
-~~~~~{.cpp}
+~~~~{.cpp}
 // change z-layer settings
 Graphic3d_ZLayerSettings aSettings = aViewer->ZLayerSettings (anId);
 aSettings.SetEnableDepthTest (true);
@@ -1855,7 +1855,7 @@ aSettings.SetEnableDepthWrite(true);
 aSettings.SetClearDepth      (true);
 aSettings.SetPolygonOffset   (Graphic3d_PolygonOffset());
 aViewer->SetZLayerSettings (anId, aSettings);
-~~~~~
+~~~~
 
 Another application for Z-Layer feature is treating visual precision issues when displaying objects far from the World Center.
 The key problem with such objects is that visualization data is stored and manipulated with single precision floating-point numbers (32-bit).
@@ -1887,10 +1887,10 @@ So, to apply this feature in OCCT, the application:
 * Defines a Z-Layer for each spatial cell containing any object.
 * Defines the Local Origin property of the Z-Layer according to the center of the cell.
 
-~~~~~{.cpp}
+~~~~{.cpp}
 Graphic3d_ZLayerSettings aSettings = aViewer->ZLayerSettings (anId);
 aSettings.SetLocalOrigin (400.0, 0.0, 0.0);
-~~~~~
+~~~~
 * Assigns a presentable object to the nearest Z-Layer.
 
 Note that Local Origin of the Layer is used only for rendering - everything outside will be still defined in the World Coordinate System,
@@ -1906,29 +1906,29 @@ The *Graphic3d_ClipPlane* class provides the services for clipping planes:
 it holds the plane equation coefficients and provides its graphical representation.
 To set and get plane equation coefficients you can use the following methods:
 
-~~~~~{.cpp}
+~~~~{.cpp}
 Graphic3d_ClipPlane::Graphic3d_ClipPlane (const gp_Pln& thePlane)
 void Graphic3d_ClipPlane::SetEquation (const gp_Pln& thePlane)
 Graphic3d_ClipPlane::Graphic3d_ClipPlane (const Equation& theEquation)
 void Graphic3d_ClipPlane::SetEquation (const Equation& theEquation)
 gp_Pln Graphic3d_ClipPlane::ToPlane() const
-~~~~~
+~~~~
 
 The clipping planes can be activated with the following method:
-~~~~~{.cpp}
+~~~~{.cpp}
 void Graphic3d_ClipPlane::SetOn (const Standard_Boolean theIsOn)
-~~~~~
+~~~~
 
 The number of clipping planes is limited.
 You can check the limit value via method *Graphic3d_GraphicDriver::InquireLimit()*;
 
-~~~~~{.cpp}
+~~~~{.cpp}
 // get the limit of clipping planes for the current view
 Standard_Integer aMaxClipPlanes = aView->Viewer()->Driver()->InquireLimit (Graphic3d_TypeOfLimit_MaxNbClipPlanes);
-~~~~~
+~~~~
 
 Let us see for example how to create a new clipping plane with custom parameters and add it to a view or to an object:
-~~~~~{.cpp}
+~~~~{.cpp}
 // create a new clipping plane
 Handle(Graphic3d_ClipPlane) aClipPlane = new Graphic3d_ClipPlane();
 // change equation of the clipping plane
@@ -1956,7 +1956,7 @@ aView->AddClipPlane (aClipPlane);
 aClipPlane->SetOn (Standard_True);
 // update the view
 aView->Update();
-~~~~~
+~~~~
 
 @subsubsection occt_visu_4_4_17 Automatic back face culling
 
@@ -1989,7 +1989,7 @@ To create 3D graphic objects and display them in the screen, follow the procedur
 
 Create colors.
 
-~~~~~{.cpp}
+~~~~{.cpp}
 Quantity_Color aBlack (Quantity_NOC_BLACK);
 Quantity_Color aBlue (Quantity_NOC_MATRABLUE);
 Quantity_Color aBrown (Quantity_NOC_BROWN4);
@@ -1999,21 +1999,21 @@ Quantity_Color aGray (Quantity_NOC_GRAY70);
 Quantity_Color aMyColor (0.99, 0.65, 0.31, Quantity_TOC_RGB);
 Quantity_Color aBeet (Quantity_NOC_BEET);
 Quantity_Color aWhite (Quantity_NOC_WHITE);
-~~~~~
+~~~~
 
 Create line attributes.
 
-~~~~~{.cpp}
+~~~~{.cpp}
 Handle(Graphic3d_AspectLine3d) anAspectBrown = new Graphic3d_AspectLine3d();
 Handle(Graphic3d_AspectLine3d) anAspectBlue  = new Graphic3d_AspectLine3d();
 Handle(Graphic3d_AspectLine3d) anAspectWhite = new Graphic3d_AspectLine3d();
 anAspectBrown->SetColor (aBrown);
 anAspectBlue ->SetColor (aBlue);
 anAspectWhite->SetColor (aWhite);
-~~~~~
+~~~~
 
 Create marker attributes.
-~~~~~{.cpp}
+~~~~{.cpp}
 Handle(Graphic3d_AspectMarker3d aFirebrickMarker = new Graphic3d_AspectMarker3d();
 // marker attributes
 aFirebrickMarker->SetColor (Firebrick);
@@ -2021,10 +2021,10 @@ aFirebrickMarker->SetScale (1.0f);
 aFirebrickMarker->SetType (Aspect_TOM_BALL);
 // or custom image
 aFirebrickMarker->SetMarkerImage (theImage)
-~~~~~
+~~~~
 
 Create facet attributes.
-~~~~~{.cpp}
+~~~~{.cpp}
 Handle(Graphic3d_AspectFillArea3d) aFaceAspect = new Graphic3d_AspectFillArea3d();
 Graphic3d_MaterialAspect aBrassMaterial (Graphic3d_NameOfMaterial_Brass);
 Graphic3d_MaterialAspect aGoldMaterial  (Graphic3d_NameOfMaterial_Gold);
@@ -2033,16 +2033,16 @@ aFaceAspect->SetInteriorColor (aMyColor);
 aFaceAspect->SetDistinguishOn ();
 aFaceAspect->SetFrontMaterial (aGoldMaterial);
 aFaceAspect->SetBackMaterial  (aBrassMaterial);
-~~~~~
+~~~~
 
 Create text attributes.
-~~~~~{.cpp}
+~~~~{.cpp}
 Handle(Graphic3d_AspectText3d) aTextAspect = new Graphic3d_AspectText3d (aForest, Font_NOF_MONOSPACE, 1.0, 0.0);
-~~~~~
+~~~~
 
 @subsubsection occt_visu_4_5_2 Create a 3D Viewer (a Windows example)
 
-~~~~~{.cpp}
+~~~~{.cpp}
 // create a graphic driver
 Handle(OpenGl_GraphicDriver) aGraphicDriver = new OpenGl_GraphicDriver (Handle(Aspect_DisplayConnection)());
 // create a viewer
@@ -2058,30 +2058,30 @@ a3DViewer->SetDefaultLights();
 a3DViewer->SetLightOn();
 // set background color to black
 a3DViewer->SetDefaultBackgroundColor (Quantity_NOC_BLACK);
-~~~~~
+~~~~
 
 @subsubsection occt_visu_4_5_3 Create a 3D view (a Windows example)
 
 It is assumed that a valid Windows window may already be accessed via the method *GetSafeHwnd()* (as in case of MFC sample).
-~~~~~{.cpp}
+~~~~{.cpp}
 Handle(WNT_Window) aWNTWindow = new WNT_Window (GetSafeHwnd());
 myView = myViewer->CreateView();
 myView->SetWindow (aWNTWindow);
-~~~~~
+~~~~
 
 @subsubsection occt_visu_4_5_4 Create an interactive context
 
-~~~~~{.cpp}
+~~~~{.cpp}
 myAISContext = new AIS_InteractiveContext (myViewer);
-~~~~~
+~~~~
 
 You are now able to display interactive objects such as an *AIS_Shape*.
 
-~~~~~{.cpp}
+~~~~{.cpp}
 TopoDS_Shape aShape = BRepAPI_MakeBox (10, 20, 30).Solid();
 Handle(AIS_Shape) anAISShape = new AIS_Shape (aShape);
 myAISContext->Display (anAISShape, true);
-~~~~~
+~~~~
 
 @subsubsection occt_visu_4_5_5 Create your own interactive object
 
@@ -2095,7 +2095,7 @@ i.e. in hidden line removal and wireframe modes.
 
 Let us look at the example of compute methods
 
-~~~~~{.cpp}
+~~~~{.cpp}
 void MyPresentableObject::Compute (const Handle(PrsMgr_PresentationManager)& thePrsManager,
                                    const Handle(Graphic3d_Structure)& thePrs,
                                    const Standard_Integer theMode)
@@ -2108,25 +2108,25 @@ void MyPresentableObject::Compute (const Handle(Prs3d_Projector)& theProjector,
 (
   //...
 )
-~~~~~
+~~~~
 
 @subsubsection occt_visu_4_5_6 Create primitives in the interactive object
 
 Get the group used in *Graphic3d_Structure*.
 
-~~~~~{.cpp}
+~~~~{.cpp}
 Handle(Graphic3d_Group) aGroup = thePrs->NewGroup();
-~~~~~
+~~~~
 
 Update the group attributes.
 
-~~~~~{.cpp}
+~~~~{.cpp}
 aGroup->SetGroupPrimitivesAspect (anAspectBlue);
-~~~~~
+~~~~
 
 Create two triangles in *aGroup*.
 
-~~~~~{.cpp}
+~~~~{.cpp}
 Standard_Integer aNbTria = 2;
 Handle(Graphic3d_ArrayOfTriangles) aTriangles = new Graphic3d_ArrayOfTriangles (3 * aNbTria, 0, Graphic3d_ArrayFlags_VertexNormal);
 for (Standard_Integer aTriIter = 1; aTriIter <= aNbTria; ++aTriIter)
@@ -2137,11 +2137,11 @@ for (Standard_Integer aTriIter = 1; aTriIter <= aNbTria; ++aTriIter)
 }
 aGroup->AddPrimitiveArray (aTriangles);
 aGroup->SetGroupPrimitivesAspect (new Graphic3d_AspectFillArea3d());
-~~~~~
+~~~~
 
 Use the polyline function to create a boundary box for the *thePrs* structure in group *aGroup*.
 
-~~~~~{.cpp}
+~~~~{.cpp}
 Standard_Real Xm, Ym, Zm, XM, YM, ZM;
 thePrs->MinMaxValues (Xm, Ym, Zm, XM, YM, ZM);
 
@@ -2169,11 +2169,11 @@ aPolylines->AddVertex (Xm,  Ym, ZM);
 
 aGroup->AddPrimitiveArray(aPolylines);
 aGroup->SetGroupPrimitivesAspect (new Graphic3d_AspectLine3d());
-~~~~~
+~~~~
 
 Create text and markers in group *aGroup*.
 
-~~~~~{.cpp}
+~~~~{.cpp}
 static char* THE_TEXT[3] =
 {
   "Application title",
@@ -2194,7 +2194,7 @@ for (int i = 0; i <= 2; i++)
                     -(Standard_Real )i * 4);
   aGroup->Text (THE_TEXT[i], Marker, 20.);
 }
-~~~~~
+~~~~
 
 @section occt_visu_5 Mesh Visualization Services
 
index 85a2aa5c8af076c30ee99edf7e09416cd1f54ccd..333b4de86e5c61317b3cd63392ad7c7d36d416ef 100644 (file)
@@ -168,38 +168,38 @@ To use XDE you have to set the environment variables properly. Make sure that tw
 Before working with shapes, properties, and other types of information, the global organization of an XDE Document can be queried or completed to determine if an existing Document is actually structured for use with XDE. 
 
 To find out if an existing *TDocStd_Document* is suitable for XDE, use: 
-~~~~~
+~~~~{.cpp}
 Handle(TDocStd_Document) doc... 
 if ( XCAFDoc_DocumentTool::IsXCAFDocument (doc) ) { .. yes .. } 
-~~~~~
+~~~~
 If the Document is suitable for XDE, you can perform operations and queries explained in this guide. However, if a Document is not fully structured for XDE, it must be initialized. 
 
 @subsubsection occt_xde_2_1_3 Get an Application or an Initialized Document
 If you want to retrieve an existing application or an existing document (known to be correctly structured for XDE), use: 
-~~~~~
+~~~~{.cpp}
 Handle(TDocStd_Document) aDoc; 
 Handle(XCAFApp_Application) anApp = XCAFApp_Application::GetApplication(); 
 anApp->NewDocument(;MDTV-XCAF;,aDoc); 
-~~~~~
+~~~~
 
 @subsection occt_xde_2_2 Shapes and Assemblies
 
 @subsubsection occt_xde_2_2_1 Initialize an XDE Document (Shapes)
 An XDE Document begins with a *TDocStd_Document*. Assuming you have a *TDocStd_Document* already created, you can ensure that it is correctly structured for XDE by initializing the XDE structure as follows: 
-~~~~~
+~~~~{.cpp}
 Handle(TDocStd_Document) doc... 
 Handle (XCAFDoc_ShapeTool) myAssembly = 
 XCAFDoc_DocumentTool::ShapeTool (Doc->Main()); 
 TDF_Label aLabel = myAssembly->NewShape() 
-~~~~~
+~~~~
 **Note** that the method *XCAFDoc_DocumentTool::ShapeTool* returns the *XCAFDoc_ShapeTool*. The first time this method is used, it creates the *XCAFDoc_ShapeTool*. In our example, a handle is used for the *TDocStd_Document*.
 
 @subsubsection occt_xde_2_2_2 Get a Node considered as an Assembly
 To get a node considered as an Assembly from an XDE structure, you can use the Label of the node. Assuming that you have a properly initialized *TDocStd_Document*, use: 
-~~~~~
+~~~~{.cpp}
 Handle(TDocStd_Document) doc... 
 Handle(XCAFDoc_ShapeTool) myAssembly = XCAFDoc_DocumentTool::ShapeTool (aLabel); 
-~~~~~
+~~~~
 In the previous example, you can also get the Main Item of an XDE document, which records the root shape representation (as a Compound if it is an Assembly) by using *ShapeTool(Doc->Main())* instead of *ShapeTool(aLabel)*. 
 
 You can then query or edit this Assembly node, the Main Item or another one (*myAssembly* in our examples). 
@@ -210,9 +210,9 @@ You can then query or edit this Assembly node, the Main Item or another one (*my
 Some actions in this chapter affect the content of the document, considered as an Assembly. As a result, you will sometimes need to update various representations (including the compounds). 
 
 To update the representations, use: 
-~~~~~
+~~~~{.cpp}
 myAssembly->UpdateAssemblies(); 
-~~~~~
+~~~~
 This call performs a top-down update of the Assembly compounds stored in the document.
 
 **Note** that you have to run this method manually to actualize your Assemblies after any low-level modifications on shapes.
@@ -230,29 +230,29 @@ A shape to be added can be defined as a compound (if required), with the followi
   * If the Shape is not a compound, it is taken as a whole, without breaking it down. 
   
 To break down a Compound in the assembly structure, use: 
-~~~~~
+~~~~{.cpp}
 Standard_Boolean makeAssembly; 
 // True to interpret a Compound as an Assembly, 
 // False to take it as a whole 
 aLabel = myAssembly->AddShape(aShape, makeAssembly); 
-~~~~~
+~~~~
 Each node of the assembly therefore refers to its sub-shapes. 
 
 Concerning located instances of sub-shapes, the corresponding shapes, (without location) appear at distinct sub-labels. They are referred to by a shape instance, which associates a location. 
 
 @subsubsection occt_xde_2_2_5 Setting a given Shape at a given Label
 A top-level shape can be changed. In this example, no interpretation of compound is performed: 
-~~~~~
+~~~~{.cpp}
 Standard_CString LabelString ...; 
 // identifies the Label (form ;0:i:j...;) 
 TDF_Label aLabel...; 
 // A label must be present 
 myAssembly->SetShape(aLabel, aShape); 
-~~~~~
+~~~~
 
 @subsubsection occt_xde_2_2_6 Getting a Shape from a Label
 To get a shape from its Label from the top-level, use: 
-~~~~~
+~~~~{.cpp}
 TDF_Label aLabel...
 // A label must be present
 if (aLabel.IsNull()) { 
@@ -263,19 +263,19 @@ aShape = myAssembly->GetShape(aLabel);
 if (aShape.IsNull()) {
   // this label is not for a Shape
 }
-~~~~~
+~~~~
 **Note** that if the label corresponds to an assembly, the result is a compound. 
 
 @subsubsection occt_xde_2_2_7 Getting a Label from a Shape
 To get a Label, which is attached to a Shape from the top-level, use: 
-~~~~~
+~~~~{.cpp}
 Standard_Boolean findInstance = Standard_False; 
 // (this is default value)
 aLabel = myAssembly->FindShape(aShape [,findInstance]);
 if (aLabel.IsNull()) { 
   // no label found for this shape
 }
-~~~~~
+~~~~
 If *findInstance* is True, a search is made for the shape with the same location. If it is False (default value), a search is made among original, non-located shapes. 
 
 @subsubsection occt_xde_2_2_8 Other Queries on a Label
@@ -284,29 +284,29 @@ Various other queries can be made from a Label within the Main Item of XDE:
 #### Main Shapes
 
 To determine if a Shape is recorded (or not), use: 
-~~~~~
+~~~~{.cpp}
 if ( myAssembly->IsShape(aLabel) ) { .. yes .. } 
-~~~~~
+~~~~
 
 To determine if the shape is top-level, i.e. was added by the *AddShape* method, use: 
-~~~~~
+~~~~{.cpp}
 if ( myAssembly->IsTopLevel(aLabel) ) { .. yes .. } 
-~~~~~
+~~~~
 
 To get a list of top-level shapes added by the *AddShape* method, use: 
-~~~~~
+~~~~{.cpp}
 TDF_LabelSequence frshapes; 
 myAssembly->GetShapes(frshapes); 
-~~~~~
+~~~~
 
 To get all free shapes at once if the list above has only one item, use: 
-~~~~~
+~~~~{.cpp}
 TopoDS_Shape result = myAssembly->GetShape(frshapes.Value(1)); 
-~~~~~
+~~~~
 
 If there is more than one item, you must create and fill a compound, use: 
 
-~~~~~
+~~~~{.cpp}
 TopoDS_Compound C; 
 BRep_Builder B; 
 B.MakeCompound(C); 
@@ -314,72 +314,72 @@ for(Standard_Integer i=1; i=frshapes.Length(); i++) {
   TopoDS_Shape S = myAssembly->GetShape(frshapes.Value(i)); 
   B.Add(C,S); 
 } 
-~~~~~
+~~~~
 
 In our example, the result is the compound C. 
 To determine if a shape is a free shape (no reference or super-assembly), use: 
 
-~~~~~
+~~~~{.cpp}
 if ( myAssembly->IsFree(aLabel) ) { .. yes .. } 
-~~~~~
+~~~~
 
 To get a list of Free Shapes (roots), use: 
 
-~~~~~
+~~~~{.cpp}
 TDF_LabelSequence frshapes; 
 myAssembly->GetFreeShapes(frshapes); 
-~~~~~
+~~~~
 
 To get the shapes, which use a given shape as a component, use: 
-~~~~~
+~~~~{.cpp}
 TDF_LabelSequence users; 
 Standard_Integer nbusers = myAssembly->GetUsers(aLabel,users); 
-~~~~~
+~~~~
 The count of users is contained with *nbusers*. It contains 0 if there are no users. 
 
 #### Assembly and Components
 To determine if a label is attached to the main part or to a sub-part (component), use: 
-~~~~~
+~~~~{.cpp}
 if (myAssembly->IsComponent(aLabel)) { .. yes .. } 
-~~~~~
+~~~~
 To determine whether a label is a node of a (sub-) assembly or a simple shape, use: 
-~~~~~
+~~~~{.cpp}
 if ( myAssembly->IsAssembly(aLabel) ) { .. yes .. } 
-~~~~~
+~~~~
 
 If the label is a node of a (sub-) assembly, you can get the count of components, use: 
-~~~~~
+~~~~{.cpp}
 Standard_Boolean subchilds = Standard_False; //default 
 Standard_Integer nbc = myAssembly->NbComponents (aLabel [,subchilds]); 
-~~~~~
+~~~~
 
 If *subchilds* is True, commands also consider sub-levels. By default, only level one is checked. 
 
 To get component Labels themselves, use: 
-~~~~~
+~~~~{.cpp}
 Standard_Boolean subchilds = Standard_False; //default 
 TDF_LabelSequence comps; 
 Standard_Boolean isassembly = myAssembly->GetComponents 
 (aLabel,comps[,subchilds]); 
-~~~~~
+~~~~
 @subsubsection occt_xde_2_2_9 Instances and References for Components
 To determine if a label is a simple shape, use: 
-~~~~~
+~~~~{.cpp}
 if ( myAssembly->IsSimpleShape(aLabel) ) { .. yes .. } 
-~~~~~
+~~~~
 To determine if a label is a located reference to another one, use: 
-~~~~~
+~~~~{.cpp}
 if ( myAssembly->IsReference(aLabel) ) { .. yes .. } 
-~~~~~
+~~~~
 If the label is a located reference, you can get the location, use: 
-~~~~~
+~~~~{.cpp}
 TopLoc_Location loc = myAssembly->GetLocation (aLabel); 
-~~~~~
+~~~~
 To get the label of a referenced original shape (also tests if it is a reference), use: 
-~~~~~
+~~~~{.cpp}
 Standard_Boolean isref = myAssembly->GetReferredShape 
 (aLabel, refLabel); 
-~~~~~
+~~~~
 
 **Note** *isref* returns False if *aLabel* is not for a reference. 
 
@@ -387,55 +387,55 @@ Standard_Boolean isref = myAssembly->GetReferredShape
 In addition to the previously described *AddShape* and *SetShape*, several shape edits are possible. 
 
 To remove a Shape, and all its sub-labels, use: 
-~~~~~
+~~~~{.cpp}
 Standard_Boolean remsh = myAssembly->RemoveShape(aLabel); 
 // remsh is returned True if done 
-~~~~~
+~~~~
 This operation will fail if the shape is neither free nor top level.
 
 To add a Component to the Assembly, from a new shape, use: 
-~~~~~
+~~~~{.cpp}
 Standard_Boolean expand = Standard_False; //default 
 TDF_Label aLabel = myAssembly->AddComponent (aShape [,expand]); 
-~~~~~
+~~~~
 If *expand* is True and *aShape* is a Compound, *aShape* is broken down to produce sub-components, one for each of its sub-shapes. 
 
 To add a component to the assembly, from a previously recorded shape (the new component is defined by the label of the reference shape, and its location), use: 
-~~~~~
+~~~~{.cpp}
 TDF_Label refLabel ...; // the label of reference shape 
 TopLoc_Location loc ...; // the desired location 
 TDF_Label aLabel = myAssembly->AddComponent (refLabel, loc); 
-~~~~~
+~~~~
 To remove a component from the assembly, use: 
-~~~~~
+~~~~{.cpp}
 myAssembly->RemoveComponent (aLabel); 
-~~~~~
+~~~~
 
 @subsection occt_xde_2_4 Management of Sub-Shapes
 In addition to components of a (sub-)assembly, it is possible to have individual identification of some sub-shapes inside any shape. Therefore, you can attach specific attributes such as Colors. Some additional actions can be performed on sub-shapes that are neither top-level, nor components: 
 To add a sub-shape to a given Label, use: 
-~~~~~
+~~~~{.cpp}
 TDF_Label subLabel = myAssembly->AddSubShape (aLabel, subShape); 
-~~~~~
+~~~~
 
 To find the Label attached to a given sub-shape, use: 
-~~~~~
+~~~~{.cpp}
 TDF_Label subLabel; // new label to be computed 
 if ( myAssembly-> FindSubShape (aLabel, subShape, subLabel)) { .. yes .. } 
-~~~~~
+~~~~
 If the sub-shape is found (yes), *subLabel* is filled by the correct value. 
 
 To find the top-level simple shape (not a compound whether free or not), which contains a given sub-shape, use: 
-~~~~~
+~~~~{.cpp}
 TDF_Label mainLabel = myAssembly->FindMainShape(subShape); 
-~~~~~
+~~~~
 **Note** that there should be only one shape for a valid model. In any case, the search stops on the first one found. 
 
 To get the sub-shapes of a shape, which are recorded under a label, use: 
-~~~~~
+~~~~{.cpp}
 TDF_LabelSequence subs; 
 Standard_Boolean hassubs = myAssembly->GetSubShapes (aLabel,subs); 
-~~~~~
+~~~~
 @subsection occt_xde_2_5 Properties
 Some properties can be attached directly to shapes. These properties are: 
   * Name (standard definition from OCAF)
@@ -458,22 +458,22 @@ Name is implemented and used as a *TDataStd_Name*, which can be attached to any
 These considerations are not specific to XDE. What is specific to data exchange is the way names are attached to entities. 
 
 To get the name attached to a label (as a reminder using OCAF), use: 
-~~~~~
+~~~~{.cpp}
 Handle(TDataStd_Name) N; 
 if ( !aLabel.FindAttribute(TDataStd_Name::GetID(),N)) { 
   // no name is attached 
 } 
 TCollection_ExtendedString name = N->Get(); 
-~~~~~
+~~~~
 
 Don't forget to consider Extended String as ASCII, for the exchange file. 
 
 To set a name to a label (as a reminder using OCAF), use: 
-~~~~~
+~~~~{.cpp}
 TCollection_ExtendedString aName ...; 
 // contains the desired name for this Label (ASCII) 
 TDataStd_Name::Set (aLabel, aName); 
-~~~~~
+~~~~
 
 @subsubsection occt_xde_2_5_2 Centroid
 A Centroid is defined by a Point to fix its position. It is handled as a property, item of the class *XCAFDoc_Centroid*, sub-class of *TDF_Attribute*. However, global methods give access to the position itself. 
@@ -483,26 +483,26 @@ This notion has been introduced in STEP, together with that of Volume, and Area,
 A centroid can be determined at any level of an assembly, thereby allowing a check of both individual simple shapes and their combinations including locations. 
 
 To get a Centroid attached to a Shape, use: 
-~~~~~
+~~~~{.cpp}
 gp_Pnt pos; 
 Handle(XCAFDoc_Centroid) C; 
 aLabel.FindAttribute ( XCAFDoc_Centroid::GetID(), C ); 
 if ( !C.IsNull() ) pos = C->Get(); 
-~~~~~
+~~~~
 
 To set a Centroid to a Shape, use: 
-~~~~~
+~~~~{.cpp}
 gp_Pnt pos (X,Y,Z); 
 // the position previously computed for the centroid 
 XCAFDoc_Centroid::Set ( aLabel, pos ); 
-~~~~~
+~~~~
 
 @subsubsection occt_xde_2_5_3 Area
 An Area is defined by a Real, it corresponds to the computed Area of a Shape, provided that it contains surfaces. It is handled as a property, item of the class *XCAFDoc_Area*, sub-class of *TDF_Attribute*. 
 This notion has been introduced in STEP but it is usually disregarded for a Solid, as Volume is used instead. In addition, it is attached to simple shapes, not to assemblies. 
 
 To get an area attached to a Shape, use: 
-~~~~~
+~~~~{.cpp}
 Standard_Real area; 
 Handle(XCAFDoc_Area) A; 
 L.FindAttribute ( XCAFDoc_Area::GetID(), A ); 
@@ -512,25 +512,25 @@ To set an area value to a Shape, use:
 Standard_Real area ...; 
 // value previously computed for the area 
 XCAFDoc_Area::Set ( aLabel, area ); 
-~~~~~
+~~~~
 @subsubsection occt_xde_2_5_4 Volume
 A Volume is defined by a Real and corresponds to the computed volume of a Shape, provided that it contains solids. It is handled as a property, an item of the class *XCAFDoc_Volume*, sub-class of *TDF_Attribute*. 
 This notion has been introduced in STEP. It may be attached to simple shapes or their assemblies for computing cumulated volumes and centers of gravity. 
 
 To get a Volume attached to a Shape, use: 
-~~~~~
+~~~~{.cpp}
 Standard_Real volume; 
 Handle(XCAFDoc_Volume) V; 
 L.FindAttribute ( XCAFDoc_Volume::GetID(), V ); 
 if ( !V.IsNull() ) volume = V->Get(); 
-~~~~~
+~~~~
 
 To set a volume value to a Shape, use: 
-~~~~~
+~~~~{.cpp}
 Standard_Real volume ...; 
 // value previously computed for the volume 
 XCAFDoc_Volume::Set ( aLabel, volume ); 
-~~~~~
+~~~~
 @subsection occt_xde_2_6 Colors and Layers
 
 XDE can read and write colors and layers assigned to shapes or their subparts (down to level of faces and edges) to and from both IGES and STEP formats. 
@@ -553,10 +553,10 @@ These definitions are common to various exchange formats, at least for STEP and
 
 @subsubsection occt_xde_2_6_1 Initialization
 To query, edit, or initialize a Document to handle Colors of XCAF, use: 
-~~~~~
+~~~~{.cpp}
 Handle(XCAFDoc_ColorTool) myColors = 
 XCAFDoc_DocumentTool::ColorTool(Doc->Main ()); 
-~~~~~
+~~~~
 This call can be used at any time. The first time it is used, a relevant structure is added to the document. This definition is used for all the following color calls and will not be repeated for these. 
 
 @subsubsection occt_xde_2_6_2 Adding a Color
@@ -566,7 +566,7 @@ There are two ways to add a color. You can:
 When the Color is added by its value *Quantity_Color*, it is added only if it has not yet been recorded (same RGB values) in the Document. 
 
 To set a Color to a Shape using a label, use:
-~~~~~
+~~~~{.cpp}
 Quantity_Color Col (red,green,blue); 
 XCAFDoc_ColorType ctype ..; 
 // can take one of these values : 
@@ -574,60 +574,60 @@ XCAFDoc_ColorType ctype ..;
 // XCAFDoc_ColorSurf : surfaces only 
 // XCAFDoc_ColorCurv : curves only 
 myColors->SetColor ( aLabel, Col, ctype ); 
-~~~~~
+~~~~
 Alternately, the Shape can be designated directly, without using its label, use: 
-~~~~~
+~~~~{.cpp}
 myColors->SetColor ( aShape, Col, ctype ); 
 // Creating and Adding a Color, explicitly 
 Quantity_Color Col (red,green,blue); 
 TDF_Label ColLabel = myColors->AddColor ( Col ); 
-~~~~~
+~~~~
 **Note** that this Color can then be named, allowing later retrieval by its Name instead of its Value. 
 
 To set a Color, identified by its Label and already recorded, to a Shape, use: 
-~~~~~
+~~~~{.cpp}
 XCAFDoc_ColorType ctype ..; // see above
 if ( myColors->SetColors ( aLabel, ColLabel, ctype) ) {.. it is done .. }
-~~~~~
+~~~~
 In this example, *aLabel* can be replaced by *aShape* directly. 
 
 @subsubsection occt_xde_2_6_3 Queries on Colors
 Various queries can be performed on colors. However, only specific queries are included in this section, not general queries using names. 
 
 To determine if a Color is attached to a Shape, for a given color type (ctype), use: 
-~~~~~
+~~~~{.cpp}
 if ( myColors->IsSet (aLabel , ctype)) { 
   // yes, there is one .. 
 } 
-~~~~~
+~~~~
 In this example, *aLabel* can be replaced by *aShape* directly. 
 
 To get the Color attached to a Shape (for any color type), use: 
-~~~~~
+~~~~{.cpp}
 Quantity_Color col; 
 // will receive the recorded value (if there is some)
 if ( !myColors->GetColor(aLabel, col) ) { 
 // sorry, no color .. 
 }
-~~~~~
+~~~~
 
 Color name can also be queried from *col.StringName* or *col.Name*. 
 In this example, *aLabel* can be replaced by *aShape* directly. 
 
 To get the Color attached to a Shape, with a specific color type, use: 
-~~~~~
+~~~~{.cpp}
 XCAFDoc_ColorType ctype ..; 
 Quantity_Color col; 
 // will receive the recorded value (if there is some) 
 if ( !myColors->GetColor(aLabel, ctype, col) ) { 
 // sorry, no color .. 
 } 
-~~~~~
+~~~~
 
 
 To get all the Colors recorded in the Document, use: 
 
-~~~~~
+~~~~{.cpp}
 Quantity_Color col; // to receive the values 
 TDF_LabelSequence ColLabels; 
 myColors->GetColors(ColLabels); 
@@ -637,28 +637,28 @@ for (i = 1; i = nbc; i ++) {
   if ( !myColors->GetColor(aLabel, col) ) continue; 
   // col receives the color n0 i .. 
 } 
-~~~~~
+~~~~
 
 To find a Color from its Value, use: 
-~~~~~
+~~~~{.cpp}
 Quantity_Color Col (red,green,blue); 
 TDF_Label ColLabel = myColors-FindColor (Col); 
 if ( !ColLabel.IsNull() ) { .. found .. } 
-~~~~~
+~~~~
 
 @subsubsection occt_xde_2_6_4 Editing Colors
 Besides adding colors, the following attribute edits can be made: 
 
 To unset a Color on a Shape, use: 
-~~~~~
+~~~~{.cpp}
 XCAFDoc_ColorType ctype ...; 
 // desired type (XCAFDoc_ColorGen for all ) 
 myColors->UnSetColor (aLabel,ctype); 
-~~~~~
+~~~~
 To remove a Color and all the references to it (so that the related shapes will become colorless), use: 
-~~~~~
+~~~~{.cpp}
 myColors->RemoveColor(ColLabel); 
-~~~~~
+~~~~
 
 @subsection occt_xde_2_7 Geometric Dimensions & Tolerances (GD\&T)
 
@@ -683,10 +683,10 @@ These definitions are common to various exchange formats, at least for STEP.
 
 @subsubsection occt_xde_2_7_1 Initialization
 To query, edit, or initialize a Document to handle GD\&Ts of XCAF, use: 
-~~~~~
+~~~~{.cpp}
 Handle(XCAFDoc_DimTolTool) myDimTolTool = 
 XCAFDoc_DocumentTool::DimTolTool(Doc->Main()); 
-~~~~~
+~~~~
 This call can be used at any time. When it is used for the first time, a relevant structure is added to the document. This definition is used for all later GD\&T calls and is not repeated for them. 
 
 @subsubsection occt_xde_2_7_2 Adding a GD\&T
@@ -699,19 +699,19 @@ All methods create a sub-label for the corresponding GD\&T entity of the tool ma
 created entity.
 
 Here is an example of adding a new dimension:
-~~~~~
+~~~~{.cpp}
 TDF_Label aDimLabel = myDimTolTool->AddDimension();
 if (!aDimLabel.IsNull())
 {
   // error processing
 }
-~~~~~
+~~~~
 A similar approach can be used for other GD\&T types.
 
 @subsubsection occt_xde_2_7_3 Editing a GD\&T
 A newly added GD\&T entity is empty. To set its data a corresponding access object should be used as it is demonstrated
 below, where the dimension becomes a linear distance between two points.
-~~~~~
+~~~~{.cpp}
 Handle(XCAFDoc_Dimension) aDimAttr;
 aDimLabel.FindAttribute(XCAFDoc_Dimension::GetID(), aDimAttr);
 if (!aDimAttr.IsNull())
@@ -725,7 +725,7 @@ if (!aDimAttr.IsNull())
   //...
   aDimAttr->SetObject(aDimObject);
 }
-~~~~~
+~~~~
 A similar approach can be used for other GD\&T types.
 
 @subsubsection occt_xde_2_7_4 Linking GD\&Ts
@@ -737,14 +737,14 @@ To link a GD\&T entity with other OCAF labels (e.g. representing shapes) one sho
 These methods can take a single label or a sequence of labels. All previous links will be removed.
 
 The example below demonstrates linking of a dimension to sequences of shape labels:
-~~~~~
+~~~~{.cpp}
 TDF_LabelSequence aShapes1, aShapes2;
 aShapes1.Append(aShape11);
 //...
 aShapes2.Append(aShape21);
 //...
 aDGTTool->SetDimension(aShapes1, aShapes2, aDimLabel);
-~~~~~
+~~~~
 
 In addition, a special method *SetDatumToGeomTol* should be used to link a datum with a geometric tolerance.
 
@@ -772,14 +772,14 @@ Custom data can be stored in labels with tags beyond the ranges listed above.
 In an XDE document, Clipping planes are managed by the class *XCAFDoc_ClippingPlaneTool*. It works basing on the same principles as ShapeTool works with Shapes. This tool can be provided on the Main Label or on any sub-label. Clipping planes are stored in a child of the starting document label 0.1.8, where planes themselves are defined as *TDataXtd_Plane* attribute. *TDataStd_Name* attribute is used for naming.
 
 To query, edit, or initialize a Document to handle clipping planes of XCAF, use: 
-~~~~~
+~~~~{.cpp}
 Handle(XCAFDoc_ClippingPlaneTool) myClipPlaneTool = 
 XCAFDoc_DocumentTool::ClippingPlaneTool(Doc->Main()); 
-~~~~~
+~~~~
 This call can be used at any time. When it is used for the first time, a relevant structure is added to the document. 
 
 To add a clipping plane use one of overloaded methods *AddClippingPlane*, e.g.:
-~~~~~
+~~~~{.cpp}
 gp_Pln aPln = ...
 Standard_Boolean aCapping = ...
 TDF_Label aClipPlnLbl = myClipPlaneTool->AddClippingPlane(aPln, "Name of plane", aCapping);
@@ -787,31 +787,31 @@ if (aClipPlnLbl.IsNull())
 {
   // error processing
 }
-~~~~
+~~~~
 
 To remove a plane use *RemoveClippingPlane* method, e.g.:
-~~~~~
+~~~~{.cpp}
 if (!myClipPlaneTool->RemoveClippingPlane(aClipPlnLbl))
 {
   // not removed
 }
-~~~~~
+~~~~
 The plane will not be removed if it is referenced in at least one view.
 
 To change the clipping plane and its name use *UpdateClippingPlane* method, e.g.:
-~~~~~
+~~~~{.cpp}
 gp_Pln aPln = ...
 myClipPlaneTool->UpdateClippingPlane(aClipPlnLbl, aPln, "New name of plane");
-~~~~~
+~~~~
 
 Capping property can be changed using *SetCapping* method, e.g.:
-~~~~~
+~~~~{.cpp}
 Standard_Boolean aCapping = ...
 myClipPlaneTool->SetCapping(aClipPlnLbl, aCapping);
-~~~~~
+~~~~
 
 *XCAFDoc_ClippingPlaneTool* can be used to get all clipping plane labels and to check if a label belongs to the *ClippingPlane table*, e.g.:
-~~~~~
+~~~~{.cpp}
 TDF_LabelSequence aClipPlaneLbls;
 myClipPlaneTool->GetClippingPlanes(aClipPlaneLbls);
 ...
@@ -830,21 +830,21 @@ for (TDF_LabelSequence::Iterator anIt(aClipPlaneLbls); anIt.More(); anIt.Next())
     ...
   }
 }
-~~~~~
+~~~~
 
 @subsection occt_xde_2_9 Saved views
 
 In an XDE document, Views are managed by the class *XCAFDoc_ViewTool*. It works basing on the same principles as ShapeTool works with Shapes. This tool can be provided on the Main Label or on any sub-label. Views are stored in a child of the starting document label 0.1.7, where a view itself is defined as *XCAFDoc_View* sub-class of *TDF_Attribute*. Views and selected shapes, clipping planes, GD\&Ts and notes are related by Graph Nodes.
 
 To query, edit, or initialize a Document to handle views of XCAF, use: 
-~~~~~
+~~~~{.cpp}
 Handle(XCAFDoc_ViewTool) myViewTool = 
 XCAFDoc_DocumentTool::ViewTool(Doc->Main()); 
-~~~~~
+~~~~
 This call can be used at any time. When it is used for the first time, a relevant structure is added to the document. 
 
 To add a view use *AddView* method and an access *XCAFView_Object* object to set camera parameters, e.g.:
-~~~~~
+~~~~{.cpp}
 TDF_Label aViewLbl = myViewTool->AddView();
 if (aViewLbl.IsNull())
 {
@@ -862,22 +862,22 @@ if (!aViewAttr.IsNull())
   ...
   aViewAttr->SetObject(aViewObject);
 }
-~~~~
+~~~~
 
 To set shapes, clipping planes, GD\&Ts and notes selected for the view use one of overloaded *SetView* methods of *XCAFDoc_ViewTool*. 
 To set only clipping planes one should use *SetClippingPlanes* method.
-~~~~~
+~~~~{.cpp}
 TDF_LabelSequence aShapes; ...
 TDF_LabelSequence aGDTs; ...
 myViewTool->SetView(aShapes, aGDTs, aViewLbl);
 TDF_LabelSequence aClippingPlanes; ...
 myViewTool->SetClippingPlanes(aClippingPlanes, aViewLbl);
-~~~~~
+~~~~
 
 To remove a view use *RemoveView* method.
 
 To get all view labels and check if a label belongs to the View table use:
-~~~~~
+~~~~{.cpp}
 TDF_LabelSequence aViewLbls;
 myViewTool->GetViewLabels(aViewLbls);
 ...
@@ -889,7 +889,7 @@ for (TDF_LabelSequence::Iterator anIt(aViewLbls); anIt.More(); anIt.Next())
     ...
   }
 }
-~~~~~
+~~~~
 
 To get shapes, clipping planes, GD\&Ts or notes associated with a particular view use the following methods:
   * *GetRefShapeLabel* - returns a sequence of associated shape labels;
@@ -920,10 +920,10 @@ Notes binding is done through *XCAFDoc_GraphNode* attribute.
 @subsubsection occt_xde_2_10_1 Initialization
 
 To query, edit, or initialize a Document to handle custom notes of XCAF, use: 
-~~~~~
+~~~~{.cpp}
 Handle(XCAFDoc_NotesTool) myNotes = 
 XCAFDoc_DocumentTool::NotesTool(Doc->Main ()); 
-~~~~~
+~~~~
 This call can be used at any time. The first time it is used, a relevant structure is added to the document. This definition is used for all later notes calls and will not be repeated for them. 
   
 @subsubsection occt_xde_2_10_2 Creating Notes
@@ -933,25 +933,25 @@ Before annotating a Document item a note must be created using one of the follow
 - *CreateBinData* : creates a note with arbitrary binary data, e.g. contents of a file.
 
 Both methods return an instance of *XCAFDoc_Note* class.
-~~~~~
+~~~~{.cpp}
 Handle(XCAFDoc_NotesTool) myNotes = ...
 Handle(XCAFDoc_Note) myNote = myNotes->CreateComment("User", "Timestamp", "Hello, World!");
-~~~~~
+~~~~
 This code adds a child label to label 0.1.9.1 with *XCAFDoc_NoteComment* attribute.
 
 @subsubsection occt_xde_2_10_3 Editing a Note
 An instance of *XCAFDoc_Note* class can be used for note editing.
 One may change common note data.
-~~~~~
+~~~~{.cpp}
 myNote->Set("New User", "New Timestamp");
-~~~~~
+~~~~
 To change specific data one needs to down cast *myNote* handle to the appropriate sub-class:
-~~~~~
+~~~~{.cpp}
 Handle(XCAFDoc_NoteComment) myCommentNote = Handle(XCAFDoc_NoteComment)::DownCast(myNote);
 if (!myCommentNote.IsNull()) {
   myCommentNote->Set("New comment");
 }
-~~~~~
+~~~~
 In order to edit auxiliary note data such as text and attachment position, plane for rendering and tessellated presentation,
 one should use a transfer object *XCAFNoteObjects_NoteObject* by GetObject and SetObject methods of *XCAFDoc_Note* class.
 *XCAFNoteObjects_NoteObject* class provides the following functionality:
@@ -961,7 +961,7 @@ one should use a transfer object *XCAFNoteObjects_NoteObject* by GetObject and S
 - GetPresentation and SetPresentation methods allow to test for and specify tessellated presentation
 
 After getting, the transfer object can be edited and set back to the note:
-~~~~~
+~~~~{.cpp}
 Handle(XCAFNoteObjects_NoteObject) aNoteObj = myNote->GetObject();
 if (!aNoteObj.IsNull())
 {
@@ -971,7 +971,7 @@ if (!aNoteObj.IsNull())
   aNoteObj->SetPresentation (aS);
   myNote->SetObject (aNoteObj);
 }
-~~~~~
+~~~~
 
 @subsubsection occt_xde_2_10_4 Adding Notes
 
@@ -981,7 +981,7 @@ Once a note has been created it can be bound to a Document item using the follow
 - *AddNoteToSubshape* : binds a note to a sub-shape.
 
 All methods return a pointer to *XCAFDoc_AssemblyItemRef* attribute identifying the annotated item.
-~~~~~
+~~~~{.cpp}
 Handle(XCAFDoc_NotesTool) myNotes = ...
 Handle(XCAFDoc_Note) myNote = ...
 TDF_Label theLabel; ...
@@ -990,7 +990,7 @@ Standard_GUID theAttrGUID; ...
 Handle(XCAFDoc_AssemblyItemRef) myRefAttr = myNotes->AddNoteToAttr(myNote->Label(), theAttrGUID);
 Standard_Integer theSubshape = 1;
 Handle(XCAFDoc_AssemblyItemRef) myRefSubshape = myNotes->AddNoteToSubshape(myNote->Label(), theSubshape);
-~~~~~
+~~~~
 This code adds three child labels with *XCAFDoc_AssemblyItemRef* attribute to label 0.1.9.2. *XCAFDoc_GraphNode* attributes are added to the child labels and note labels.
 
 @subsubsection occt_xde_2_10_5 Finding Notes
@@ -1000,7 +1000,7 @@ To find annotation labels under label 0.1.9.2 use the following *XCAFDoc_NotesTo
 - *FindAnnotatedItemAttr* : returns an annotation label for a label's attribute;
 - *FindAnnotatedItemSubshape* : returns an annotation label for a sub-shape.
 
-~~~~~
+~~~~{.cpp}
 Handle(XCAFDoc_NotesTool) myNotes = ...
 TDF_Label theLabel; ...
 TDF_Label myLabel = myNotes->FindAnnotatedItem(theLabel);
@@ -1008,7 +1008,7 @@ Standard_GUID theAttrGUID; ...
 TDF_Label myLabelAttr = myNotes->FindAnnotatedItemAttr(theLabel, theAttrGUID);
 Standard_Integer theSubshape = 1;
 TDF_Label myLabelSubshape = myNotes->FindAnnotatedItemSubshape(theLabel, theSubshape);
-~~~~~
+~~~~
 Null label will be returned if there is no corresponding annotation.
 
 To get all notes of the Document item use the following *XCAFDoc_NotesTool* methods:
@@ -1017,7 +1017,7 @@ To get all notes of the Document item use the following *XCAFDoc_NotesTool* meth
 - *GetAttrSubshape* : outputs a sequence of note labels bound to a sub-shape.
 
 All these methods return the number of notes.
-~~~~~
+~~~~{.cpp}
 Handle(XCAFDoc_NotesTool) myNotes = ...
 TDF_Label theLabel; ...
 TDF_LabelSequence theNotes;
@@ -1028,7 +1028,7 @@ myNotes->GetAttrNotes(theLabel, theAttrGUID, theNotesAttr);
 Standard_Integer theSubshape = 1;
 TDF_LabelSequence theNotesSubshape;
 myNotes->GetAttrSubshape(theLabel, theSubshape, theNotesSubshape);
-~~~~~
+~~~~
 
 @subsubsection occt_xde_2_10_6 Removing Notes
 
@@ -1037,7 +1037,7 @@ To remove a note use one of the following *XCAFDoc_NotesTool* methods:
 - *RemoveAttrNote* : unbinds a note from a label's attribute;
 - *RemoveSubshapeNote* : unbinds a note from a sub-shape.
 
-~~~~~
+~~~~{.cpp}
 Handle(XCAFDoc_Note) myNote = ...
 TDF_Label theLabel; ...
 myNotes->RemoveNote(myNote->Label(), theLabel);
@@ -1045,7 +1045,7 @@ Standard_GUID theAttrGUID; ...
 myRefAttr = myNotes->RemoveAttrNote(myNote->Label(), theAttrGUID);
 Standard_Integer theSubshape = 1;
 myNotes->RemoveSubshapeNote(myNote->Label(), theSubshape);
-~~~~~
+~~~~
 A note will not be deleted automatically.
 Counterpart methods to remove all notes are available, too.
   
@@ -1074,7 +1074,7 @@ The packages to manage this are *IGESCAFControl* for IGES, and *STEPCAFControl*
 @subsubsection occt_xde_2_11_1 Reading a STEP file
 To read a STEP file by itself, use: 
 
-~~~~~
+~~~~{.cpp}
 STEPCAFControl_Reader reader; 
 IFSelect_ReturnStatus readstat = reader.ReadFile(filename); 
 // The various ways of reading a file are available here too : 
@@ -1089,13 +1089,13 @@ if ( !reader.Transfer ( doc ) ) {
 } 
 // Here, the Document has been filled from a STEP file, 
 // it is ready to use 
-~~~~~
+~~~~
 
 In addition, the reader provides methods that are applicable to document transfers and for directly querying of the data produced. 
 @subsubsection occt_xde_2_11_2 Writing a STEP file
 To write a STEP file by itself, use: 
 
-~~~~~
+~~~~{.cpp}
 STEPControl_StepModelType mode = 
 STEPControl_AsIs; 
 // Asis is the recommended value, others are available 
@@ -1111,7 +1111,7 @@ if ( ! writer.Transfer ( Doc, mode ) ) {
 } 
 // Writing the File 
 IFSelect_ReturnStatus stat = writer.Write(file-name); 
-~~~~~
+~~~~
 
 @subsubsection occt_xde_2_11_3 Reading an IGES File
 Use the same procedure as for a STEP file but with IGESCAFControl instead of STEPCAFControl.