|
@@ -1,8 +1,13 @@
|
|
|
-import {SColor, SLine, SPainter, SPoint, SRect} from "@saga-web/draw/lib";
|
|
|
-import {SMouseButton, SMouseEvent, SUndoStack} from "@saga-web/base";
|
|
|
-import {SMathUtil} from "../utils/SMathUtil";
|
|
|
-import {SItemStatus} from "..";
|
|
|
-import {SGraphItem, SGraphPointListInsert, SGraphPointListUpdate, SLineStyle} from "@saga-web/graph/lib";
|
|
|
+import { SColor, SLine, SPainter, SPoint, SRect } from "@saga-web/draw/lib";
|
|
|
+import { SMouseButton, SMouseEvent, SUndoStack } from "@saga-web/base";
|
|
|
+import { SMathUtil } from "../utils/SMathUtil";
|
|
|
+import { SItemStatus } from "..";
|
|
|
+import {
|
|
|
+ SGraphItem,
|
|
|
+ SGraphPointListInsert,
|
|
|
+ SGraphPointListUpdate,
|
|
|
+ SLineStyle
|
|
|
+} from "@saga-web/graph/lib";
|
|
|
|
|
|
/**
|
|
|
* 直线item
|
|
@@ -410,9 +415,15 @@ export class SLineItem extends SGraphItem {
|
|
|
// 绘制直线
|
|
|
painter.pen.color = new SColor(this.strokeColor);
|
|
|
if (this.lineStyle == SLineStyle.Dashed) {
|
|
|
- painter.pen.lineDash = [painter.toPx(this.lineWidth * 3), painter.toPx(this.lineWidth * 7)];
|
|
|
+ painter.pen.lineDash = [
|
|
|
+ painter.toPx(this.lineWidth * 3),
|
|
|
+ painter.toPx(this.lineWidth * 7)
|
|
|
+ ];
|
|
|
} else if (this.lineStyle == SLineStyle.Dotted) {
|
|
|
- painter.pen.lineDash = [painter.toPx(this.lineWidth), painter.toPx(this.lineWidth)];
|
|
|
+ painter.pen.lineDash = [
|
|
|
+ painter.toPx(this.lineWidth),
|
|
|
+ painter.toPx(this.lineWidth)
|
|
|
+ ];
|
|
|
}
|
|
|
painter.drawLine(this.line[0], this.line[1]);
|
|
|
if (
|