| | |
| | | point: [line9[1][0]-16, line9[1][1]-18] |
| | | }); |
| | | |
| | | // diagram.arrow({ |
| | | // strokeStyle: springGreen, |
| | | // lineWidth: lineWidth, |
| | | // point: line11[1] |
| | | // }) |
| | | let rect5Width = 140; |
| | | let rect5Height = 80; |
| | | let rect5Point = [line14[1][0]-rect5Width/2, line11[1][1]-rect5Height/2] |
| | | let rect5 = diagram.drawRect({ |
| | | point: rect5Point, |
| | | size: { |
| | | width: rect5Width, |
| | | height: rect5Height, |
| | | }, |
| | | }); |
| | | diagram.text({ |
| | | text: "监控", |
| | | align: 'center', |
| | | fontSize: 20, |
| | | fontWeight: true, |
| | | fillStyle: "#FFFFFF", |
| | | baseline: 'middle', |
| | | point: [line14[1][0], line11[1][1]] |
| | | }); |
| | | |
| | | let line18 = diagram.line({ |
| | | id: 'line18', |
| | | strokeStyle: springGreen, |
| | | lineWidth: lineWidth*2, |
| | | points: [ |
| | | [line13[1][0], line11[1][1]-splitWidth*3/2], |
| | | [line13[1][0], line11[1][1]+splitWidth*3/2], |
| | | ] |
| | | }); |
| | | |
| | | let diffHt = line18[1][1] - line18[0][1]; |
| | | let line19 = diagram.line({ |
| | | id: "line19", |
| | | strokeStyle: springGreen, |
| | | lineWidth: lineWidth, |
| | | points: [ |
| | | [line18[0][0], rect5.left[1]], |
| | | rect5.left, |
| | | ] |
| | | }); |
| | | |
| | | diagram.arrow({ |
| | | strokeStyle: springGreen, |
| | | lineWidth: lineWidth, |
| | | direction: 'left', |
| | | point: line19[0] |
| | | }); |
| | | |
| | | diagram.arrow({ |
| | | strokeStyle: springGreen, |
| | | lineWidth: lineWidth, |
| | | direction: 'right', |
| | | point: line19[1] |
| | | }); |
| | | |
| | | let line20 = diagram.line({ |
| | | id: "line20", |
| | | strokeStyle: springGreen, |
| | | lineWidth: lineWidth, |
| | | points: [ |
| | | [line18[0][0], line18[0][1]+diffHt/10], |
| | | [rect2.bottom[0], line18[0][1]+diffHt/10], |
| | | ] |
| | | }); |
| | | |
| | | let line21 = diagram.line({ |
| | | id: "line21", |
| | | strokeStyle: springGreen, |
| | | lineWidth: lineWidth, |
| | | points: [ |
| | | line20[1], |
| | | rect2.bottom, |
| | | ] |
| | | }); |
| | | |
| | | diagram.arrow({ |
| | | strokeStyle: springGreen, |
| | | lineWidth: lineWidth, |
| | | direction: 'left', |
| | | point: line20[0] |
| | | }); |
| | | |
| | | diagram.arrow({ |
| | | strokeStyle: springGreen, |
| | | lineWidth: lineWidth, |
| | | direction: 'up', |
| | | point: line21[1] |
| | | }); |
| | | |
| | | let line22 = diagram.line({ |
| | | id: "line22", |
| | | strokeStyle: springGreen, |
| | | lineWidth: lineWidth, |
| | | points: [ |
| | | [line18[0][0], line18[0][1]+diffHt/10*9], |
| | | [rect4.tl[0], line18[0][1]+diffHt/10*9], |
| | | ] |
| | | }); |
| | | |
| | | let line23 = diagram.line({ |
| | | id: "line23", |
| | | strokeStyle: springGreen, |
| | | lineWidth: lineWidth, |
| | | points: [ |
| | | line22[1], |
| | | rect4.tl, |
| | | ] |
| | | }); |
| | | |
| | | diagram.arrow({ |
| | | strokeStyle: springGreen, |
| | | lineWidth: lineWidth, |
| | | direction: 'left', |
| | | point: line22[0] |
| | | }); |
| | | |
| | | diagram.arrow({ |
| | | strokeStyle: springGreen, |
| | | lineWidth: lineWidth, |
| | | direction: 'down', |
| | | point: line23[1] |
| | | }); |
| | | |
| | | let line24 = diagram.line({ |
| | | id: "line24", |
| | | strokeStyle: springGreen, |
| | | lineWidth: lineWidth, |
| | | points: [ |
| | | rect5.right, |
| | | [rect5.right[0]+splitWidth, rect5.right[1]], |
| | | ] |
| | | }); |
| | | |
| | | diagram.arrow({ |
| | | strokeStyle: springGreen, |
| | | lineWidth: lineWidth, |
| | | direction: 'left', |
| | | point: line24[0] |
| | | }); |
| | | |
| | | diagram.arrow({ |
| | | strokeStyle: springGreen, |
| | | lineWidth: lineWidth, |
| | | direction: 'right', |
| | | point: line24[1] |
| | | }); |
| | | |
| | | let rect6 = diagram.drawRect({ |
| | | point: [line24[1][0], line24[1][1]-rect5Height/4], |
| | | size: { |
| | | width: rect5Width, |
| | | height: rect5Height/2, |
| | | }, |
| | | }); |
| | | |
| | | diagram.text({ |
| | | text: "按键、显示", |
| | | align: 'center', |
| | | fontSize: 20, |
| | | fontWeight: true, |
| | | fillStyle: "#FFFFFF", |
| | | baseline: 'middle', |
| | | point: [rect6.top[0], rect5.left[1]] |
| | | }); |
| | | |
| | | return diagram; |
| | | } |
| | | |