|
@@ -33,43 +33,43 @@ export class STextMarkerItem extends STextItem {
|
|
}
|
|
}
|
|
|
|
|
|
/** x轴缩放属性 */
|
|
/** x轴缩放属性 */
|
|
- _scaleX: number = 1;
|
|
|
|
- get scaleX(): number {
|
|
|
|
- return this._scaleX;
|
|
|
|
- }
|
|
|
|
- set scaleX(v: number) {
|
|
|
|
- this._scaleX = v;
|
|
|
|
- if (this.data.Scale) {
|
|
|
|
- this.data.Scale.X = v;
|
|
|
|
- }
|
|
|
|
- this.update();
|
|
|
|
- }
|
|
|
|
|
|
+ // _scaleX: number = 1;
|
|
|
|
+ // get scaleX(): number {
|
|
|
|
+ // return this._scaleX;
|
|
|
|
+ // }
|
|
|
|
+ // set scaleX(v: number) {
|
|
|
|
+ // this._scaleX = v;
|
|
|
|
+ // if (this.data.Scale) {
|
|
|
|
+ // this.data.Scale.X = v;
|
|
|
|
+ // }
|
|
|
|
+ // this.update();
|
|
|
|
+ // }
|
|
|
|
|
|
/** y轴缩放属性 */
|
|
/** y轴缩放属性 */
|
|
- _scaleY: number = 1;
|
|
|
|
- get scaleY(): number {
|
|
|
|
- return this._scaleY;
|
|
|
|
- }
|
|
|
|
- set scaleY(v: number) {
|
|
|
|
- this._scaleY = v;
|
|
|
|
- if (this.data.Scale) {
|
|
|
|
- this.data.Scale.Y = v;
|
|
|
|
- }
|
|
|
|
- this.update();
|
|
|
|
- }
|
|
|
|
|
|
+ // _scaleY: number = 1;
|
|
|
|
+ // get scaleY(): number {
|
|
|
|
+ // return this._scaleY;
|
|
|
|
+ // }
|
|
|
|
+ // set scaleY(v: number) {
|
|
|
|
+ // this._scaleY = v;
|
|
|
|
+ // if (this.data.Scale) {
|
|
|
|
+ // this.data.Scale.Y = v;
|
|
|
|
+ // }
|
|
|
|
+ // this.update();
|
|
|
|
+ // }
|
|
|
|
|
|
/** y轴旋转属性 */
|
|
/** y轴旋转属性 */
|
|
- _rolate: number = 0;
|
|
|
|
- get rolate(): number {
|
|
|
|
- return this._rolate;
|
|
|
|
- }
|
|
|
|
- set rolate(v: number) {
|
|
|
|
- this._rolate = v;
|
|
|
|
- if (this.data.Rolate) {
|
|
|
|
- this.data.Rolate.Z = v;
|
|
|
|
- }
|
|
|
|
- this.update();
|
|
|
|
- }
|
|
|
|
|
|
+ // _rolate: number = 0;
|
|
|
|
+ // get rolate(): number {
|
|
|
|
+ // return this._rolate;
|
|
|
|
+ // }
|
|
|
|
+ // set rolate(v: number) {
|
|
|
|
+ // this._rolate = v;
|
|
|
|
+ // if (this.data.Rolate) {
|
|
|
|
+ // this.data.Rolate.Z = v;
|
|
|
|
+ // }
|
|
|
|
+ // this.update();
|
|
|
|
+ // }
|
|
|
|
|
|
set name(v: string) {
|
|
set name(v: string) {
|
|
this.data.Name = v;
|
|
this.data.Name = v;
|
|
@@ -110,14 +110,15 @@ export class STextMarkerItem extends STextItem {
|
|
constructor(parent: SGraphItem | null, data: Marker) {
|
|
constructor(parent: SGraphItem | null, data: Marker) {
|
|
super(parent);
|
|
super(parent);
|
|
this.data = data;
|
|
this.data = data;
|
|
|
|
+ this.id = data.ID;
|
|
this.moveTo(data.Pos.X, data.Pos.Y);
|
|
this.moveTo(data.Pos.X, data.Pos.Y);
|
|
- if (this.data.Scale) {
|
|
|
|
- this.scaleX = this.data.Scale.X;
|
|
|
|
- this.scaleY = this.data.Scale.Y;
|
|
|
|
- }
|
|
|
|
- if (this.data.Rolate && this.data.Rolate.Z) {
|
|
|
|
- this.rolate = this.data.Rolate.Z;
|
|
|
|
- }
|
|
|
|
|
|
+ // if (this.data.Scale) {
|
|
|
|
+ // this.scaleX = this.data.Scale.X;
|
|
|
|
+ // this.scaleY = this.data.Scale.Y;
|
|
|
|
+ // }
|
|
|
|
+ // if (this.data.Rolate && this.data.Rolate.Z) {
|
|
|
|
+ // this.rolate = this.data.Rolate.Z;
|
|
|
|
+ // }
|
|
if (this.data.Size) {
|
|
if (this.data.Size) {
|
|
this.width = this.data.Size.Width;
|
|
this.width = this.data.Size.Width;
|
|
this.height = this.data.Size.Height;
|
|
this.height = this.data.Size.Height;
|
|
@@ -138,8 +139,8 @@ export class STextMarkerItem extends STextItem {
|
|
// 绘制文本
|
|
// 绘制文本
|
|
painter.brush.color = new SColor(this.color);
|
|
painter.brush.color = new SColor(this.color);
|
|
painter.font = this.font;
|
|
painter.font = this.font;
|
|
- painter.scale(this.scaleX, this.scaleY);
|
|
|
|
- painter.rotate(this.rolate);
|
|
|
|
|
|
+ // painter.scale(this.scaleX, this.scaleY);
|
|
|
|
+ // painter.rotate(this.rolate);
|
|
if (this.borderStyle == SLineStyle.Dashed) {
|
|
if (this.borderStyle == SLineStyle.Dashed) {
|
|
painter.pen.lineDash = [
|
|
painter.pen.lineDash = [
|
|
painter.toPx(this.lineWidth * 3),
|
|
painter.toPx(this.lineWidth * 3),
|