haojianlong 4 лет назад
Родитель
Сommit
bfa77b4bfc

+ 0 - 1
persagy-web-big-edit/package.json

@@ -40,7 +40,6 @@
         "typescript": "^3.5.3"
     },
     "dependencies": {
-        "@persagy-web/graph": "2.2.22",
         "@persagy-web/edit": "2.2.4",
         "@types/uuid": "^8.0.0",
         "crypto-js": "^4.0.0",

+ 2 - 2
persagy-web-big/package.json

@@ -1,6 +1,6 @@
 {
     "name": "@persagy-web/big",
-    "version": "2.2.32",
+    "version": "2.2.33",
     "description": "博锐尚格建筑信息化库",
     "main": "lib/index.js",
     "types": "lib/index.d.js",
@@ -41,7 +41,7 @@
         "typescript": "^3.9.3"
     },
     "dependencies": {
-        "@persagy-web/graph": "2.2.33",
+        "@persagy-web/graph": "2.2.34",
         "axios": "^0.18.0",
         "pako": "^1.0.10",
         "crypto-js": "^4.0.0",

+ 1 - 2
persagy-web-edit/package.json

@@ -40,8 +40,7 @@
         "typescript": "^3.5.3"
     },
     "dependencies": {
-        "@persagy-web/big": "2.2.24",
-        "@persagy-web/graph": "2.2.27",
+        "@persagy-web/big": "2.2.33",
         "@types/uuid": "^8.0.0"
     }
 }

+ 1 - 1
persagy-web-graph/package.json

@@ -1,6 +1,6 @@
 {
     "name": "@persagy-web/graph",
-    "version": "2.2.33",
+    "version": "2.2.34",
     "description": "博锐尚格二维图形引擎。",
     "main": "lib/index.js",
     "types": "lib/index.d.js",

+ 3 - 1
persagy-web-graph/src/index.ts

@@ -60,6 +60,7 @@ import { SGraphSvgItem } from "./items/SGraphSvgItem";
 import { SGraphSvg } from "./types/SGraphSvg";
 import { SGraphStyleItem } from "./items/SGraphStyleItem";
 import { SGraphCircleItem } from "./items/SGraphCircleItem";
+import { SGraphBaseCircle } from "./items/SGraphBaseCircle";
 
 export {
     SGraphItem,
@@ -95,5 +96,6 @@ export {
     SGraphSvg,
     SGraphLineItem,
     SGraphStyleItem,
-    SGraphCircleItem
+    SGraphCircleItem,
+    SGraphBaseCircle
 };

+ 12 - 10
persagy-web-graph/src/items/SGraphBaseCircle.ts

@@ -29,17 +29,19 @@
  *
  *  @author  韩耀龙 <han_yao_long@163.com>
  */
-import { SGraphStyleItem, SGraphItem, SLineStyle } from "./../"
 import { SPainter, SPoint } from "@persagy-web/draw";
+import { SLineStyle } from "../enums/SGraphLineStyle";
+import { SGraphItem } from "../SGraphItem";
+import { SGraphStyleItem } from "./SGraphStyleItem";
 
 export class SGraphBaseCircle extends SGraphStyleItem {
     // 圆坐标
     set localtion(v) {
         this._localtion = new SPoint(v);
-        this.update()
+        this.update();
     }
     get localtion(): SPoint {
-        return this._localtion
+        return this._localtion;
     }
     _localtion: SPoint = new SPoint(0, 0);
     // 圆半径
@@ -48,7 +50,7 @@ export class SGraphBaseCircle extends SGraphStyleItem {
         this.update();
     }
     get radius(): number {
-        return this._radius
+        return this._radius;
     }
     _radius: number = 0;
 
@@ -58,14 +60,14 @@ export class SGraphBaseCircle extends SGraphStyleItem {
      * @param parent
      */
     constructor(parent: SGraphItem | null) {
-        super(parent)
+        super(parent);
     }
 
     /**
-    * Item 绘制操作
-    *
-    * @param painter    绘制对象
-    */
+     * Item 绘制操作
+     *
+     * @param painter    绘制对象
+     */
     onDraw(painter: SPainter): void {
         painter.pen.color = this.strokeColor;
         painter.brush.color = this.fillColor;
@@ -84,4 +86,4 @@ export class SGraphBaseCircle extends SGraphStyleItem {
 
         painter.drawCircle(this.localtion.x, this.localtion.y, this.radius);
     } // Function onDraw()
-}
+}