0026855: Draw commands to debug Boolean Operations Algorithm
[occt.git] / tests / bugs / caf / buc60917
CommitLineData
a87752f3 1puts "==========="
2puts "BUC60917"
3puts "==========="
4
5pload QAcommands
6
e837410d 7NewDocument D BinOcaf
a87752f3 8UndoLimit D 100
9
10box b 10 10 10
11SetShape D 0:1:1 b
12
13AISInitViewer D
14
15OpenCommand D
16
17AISSet D 0:1:1 NS
18AISWidth D 0:1:1 1.0
19set W [AISWidth D 0:1:1]
20if { ${W} != 1 } {
21 puts "Error : 1"
22} else {
23 AISDisplay D 0:1:1
24 vfit
25 CommitCommand D
26
27 puts "Doing Undo... "
28
29 Undo D
30 AISRepaint D
31 AISRepaint D
32
33 puts "And now, look: Redo!"
34
35 Redo D
36 AISRepaint D
37
38 set W [AISWidth D 0:1:1]
39 if { ${W} != 1 } {
40 puts "Error : 2"
41 }
42}
43
44set 3dviewer 2
45
46
47
48
49# This TCL script demonstrates bug in AIS/OCAF viewer
50#
51# It needs an additional DRAW command to be defined for
52# setting Width parameter of TPrsStd_AISPresentation attribute.
53# The code for this command (AISWidth) is provided separately.
54#
55# The problem is that when width is set to AISPresentation attribute
56# and Undo/redo are made, this causes error 'width is 0' in the viewer.
57# It seems that width is not kept during Undo/Redo operations.
58