607a96d4 |
1 | set aTestName "caf003-A4" |
2 | puts ${aTestName} |
3 | |
4 | # Set NamedShape attribute |
5 | box aBox1 100 200 300 |
6 | set aLabel 0:2 |
7 | SetShape D ${aLabel} aBox1 |
8 | |
9 | # Initialize 3D viewer |
10 | AISInitViewer D |
11 | |
12 | # Add AISPresentation attribute with parameter NS |
13 | AISSet D ${aLabel} NS |
14 | |
15 | # Display presentation of NamedShape in the viewer |
16 | AISDisplay D ${aLabel} |
17 | |
18 | # Save the document |
19 | set aFile $WorkDirectory/${aTestName}.${FileSuffix} |
20 | |
21 | SaveToFile D $aFile |
22 | |
23 | # Restore the document |
24 | Close D |
25 | Open ${aFile} DD |
26 | |
27 | # Initialize 3D viewer |
28 | AISInitViewer DD |
29 | |
30 | # Display presentation of NamedShape in the viewer |
31 | set IsDone [catch {AISDisplay DD ${aLabel}} aResult] |
32 | if { ${IsDone} != 0 } { |
33 | puts "Error : Get a value of TPrsStd_AISPresentation attribute from restoring document" |
34 | } |
35 | |