94f16a89 |
1 | puts "# ============================================================" |
2 | puts "# 0014673: Provide true support for Unicode symbols" |
3 | puts "# ============================================================" |
4 | puts "" |
5 | puts "# Check that different file open / save commands can deal with Unicode" |
6 | |
7 | pload ALL |
8 | |
9 | # Name means "Japanese" |
10 | set filePrefix "$imagedir/${casename}_日本語" |
11 | |
12 | proc checkFile {filepath} { |
13 | if { [file exists $filepath] } { |
7b5e532f |
14 | puts "File $filepath is created, OK" |
94f16a89 |
15 | } else { |
16 | puts "Error: Could not find file $filepath" |
17 | } |
18 | } |
19 | |
20 | puts "# OCAF documents" |
21 | NewDocument Xml XmlOcaf |
22 | SaveAs Xml ${filePrefix}.xml |
23 | checkFile ${filePrefix}.xml |
24 | Close Xml |
25 | Open ${filePrefix}.xml Xml |
26 | |
27 | NewDocument Bin BinOcaf |
28 | SaveAs Bin ${filePrefix}.cbf |
29 | checkFile ${filePrefix}.cbf |
30 | Close Bin |
31 | Open ${filePrefix}.cbf Bin |
32 | |
33 | puts "# STEP and IGES" |
34 | box b 10 10 10 |
35 | NewDocument XDE BinOcaf |
36 | XAddShape XDE b |
37 | |
38 | WriteStep XDE ${filePrefix}.stp |
39 | checkFile ${filePrefix}.stp |
40 | ReadStep Step ${filePrefix}.stp |
41 | |
42 | WriteIges XDE ${filePrefix}.igs |
43 | checkFile ${filePrefix}.igs |
44 | ReadIges Iges ${filePrefix}.igs |