1 Select Case tru(i)
2 Case 1 [COLOR="SeaGreen"]' раскосная треугольная[/COLOR]
3 If res = 0 Then
4 res = 1
5 Else
6 res = 0
7 End If
8 If res = 0 Then
9 Form15.Line (x11, Y1)-(x22, Y2)
10 End If
11 If res = 1 Then
12 Form15.Line (x21, Y1)-(x12, Y2)
13 End If
14 Case 2 [COLOR="seagreen"]'полураскосная верх.[/COLOR]
15 Form15.Line (x11, Y1)-(x0, Y2): Form15.Line (x21, Y1)-(x0, Y2)
16 Case 3 [COLOR="seagreen"]'п/р низ[/COLOR]
17 Form15.Line (x12, Y2)-(x0, Y1): Form15.Line (x22, Y2)-(x0, Y1)
18 Case 4 [COLOR="seagreen"]' крестовая[/COLOR]
19 Form15.Line (x11, Y1)-(x22, Y2): Form15.Line (x21, Y1)-(x12, Y2)
20 Case 5 [COLOR="seagreen"]' ромбическая[/COLOR]
21 X1 = (x11 + x12) / 2: X2 = (x21 + x22) / 2
22 Y = Y2 + h(i) / 2
23 Form15.Line (x0, Y1)-(X1, Y): Form15.Line (X2, Y)-(x0, Y1)
24 Form15.Line (x0, Y2)-(X1, Y): Form15.Line (X2, Y)-(x0, Y2)
25 Case 6[COLOR="seagreen"] ' ромбическая с шпренгелями[/COLOR]
26 X1 = (x11 + x12) / 2: X2 = (x21 + x22) / 2
27 Y = Y2 + h(i) / 2 '
28 x3 = (x0 + X1) / 2:
29 x4 = (X2 + x0) / 2
30 y3 = Y1 + (Y - Y1) / 2
31 x5 = (X1 + x0) / 2: x6 = (X2 + x0) / 2
32 y4 = Y + (Y2 - Y) / 2
33 Form15.Line (x0, Y1)-(X1, Y): Form15.Line (X2, Y)-(x0, Y1)
34 Form15.Line (x0, Y2)-(X1, Y): Form15.Line (X2, Y)-(x0, Y2)
35 Form15.Line (x11, Y1)-(x3, y3): Form15.Line (x21, Y1)-(x4, y3)
36 Form15.Line (x12, Y2)-(x5, y4): Form15.Line (x22, Y2)-(x6, y4)
37 Case 7[COLOR="seagreen"] ' ромбическая с усиленным шпренгелем[/COLOR]
38 X1 = (x11 + x12) / 2: X2 = (x21 + x22) / 2
39 Y = Y2 + h(i) / 2
40 x3 = (x0 + X1) / 2: x4 = (X2 + x0) / 2
41 y3 = Y1 + (Y - Y1) / 2
42 x5 = (X1 + x0) / 2: x6 = (X2 + x0) / 2
43 y4 = Y + (Y2 - Y) / 2
44 x7 = (x11 + X1) / 2: x8 = (X2 + x21) / 2
45 X9 = (x11 + x0) / 2: X10 = (x0 + x21) / 2
46 x01 = (X1 + x12) / 2: x02 = (X2 + x22) / 2
47 x03 = (x0 + x12) / 2: x04 = (x0 + x22) / 2
48 Form15.Line (x0, Y1)-(X1, Y): Form15.Line (X2, Y)-(x0, Y1)
49 Form15.Line (x0, Y2)-(X1, Y): Form15.Line (X2, Y)-(x0, Y2)
50 Form15.Line (x11, Y1)-(x3, y3): Form15.Line (x21, Y1)-(x4, y3)
51 Form15.Line (x12, Y2)-(x5, y4): Form15.Line (x22, Y2)-(x6, y4)
52 Form15.Line (x7, y3)-(x3, y3): Form15.Line (x8, y3)-(x4, y3)
53 Form15.Line (X9, Y1)-(x3, y3): Form15.Line (X10, Y1)-(x4, y3)
54 Form15.Line (x01, y4)-(x5, y4): Form15.Line (x02, y4)-(x6, y4)
55 Form15.Line (x03, Y2)-(x5, y4): Form15.Line (x04, Y2)-(x6, y4)
56 Case 8 [COLOR="seagreen"]' портальная[/COLOR]
57 Form15.Line (x11, Y1)-(x0, Y2): Form15.Line (x21, Y1)-(x0, Y2)
58 [COLOR="Blue"]1 [/COLOR] k(i) = k + 1
59 If k(i) = nro(i) Then
60 GoTo 2
61 End If
62 x3 = x21 + (-x21 + x22) / nro(i) * k
63 x4 = x21 + (-x21 + x0) / nro(i) * k
64 x5 = x11 - (x11 - x12) / nro(i) * k
65 x6 = x11 - (x11 - x0) / nro(i) * k
66 x7 = x21 + (-x21 + x22) / nro(i) * (k + 1)
67 x8 = x11 - (x11 - x12) / nro(i) * (k + 1)
68 y3 = Y1 - (Y1 - Y2) / nro(i) * k
69 y4 = Y1 - (Y1 - Y2) / nro(i) * (k + 1)
70 Form15.Line (x3, y3)-(x4, y3): Form15.Line (x5, y3)-(x6, y3)
71 Form15.Line (x4, y3)-(x7, y4): Form15.Line (x6, y3)-(x8, y4)
72 GoTo 1
73 End Select
74 [COLOR="blue"]2[/COLOR] Form15.Show
75 End Sub