diff --git a/04.系统编码/Frontend/src/components/RamanLidar.vue b/04.系统编码/Frontend/src/components/RamanLidar.vue index 455d4fe..131caac 100644 --- a/04.系统编码/Frontend/src/components/RamanLidar.vue +++ b/04.系统编码/Frontend/src/components/RamanLidar.vue @@ -116,7 +116,6 @@ -
- -
= 0; index --){ @@ -259,7 +259,7 @@ export class HeatMapDrawer{ this.canvasContext.translate(x, y); this.canvasContext.rotate(Math.PI / 180 * 90); this.canvasContext.textBaseline = 'bottom'; - this.canvasContext.font = "normal 25px Verdana"; + this.canvasContext.font = "normal 25px 微软雅黑"; this.canvasContext.fillStyle = "#000000"; this.canvasContext.fillText(str, 0, 0); this.canvasContext.restore(); @@ -267,7 +267,7 @@ export class HeatMapDrawer{ } else if (str.match(/[\u4E00-\u9FA5]/) && (y < 576)) { this.canvasContext.save(); this.canvasContext.textBaseline = 'top'; - this.canvasContext.font = "normal 25px Verdana"; + this.canvasContext.font = "normal 25px 微软雅黑"; this.canvasContext.fillStyle = "#000000"; this.canvasContext.fillText(str, x, y); this.canvasContext.restore(); @@ -277,14 +277,14 @@ export class HeatMapDrawer{ } //温度单位 private drawTemperatureText(unit): void { - this.canvasContext.font = "normal 25px Verdana"; + this.canvasContext.font = "normal 25px 微软雅黑"; this.canvasContext.fillStyle = "#000000"; let unitX = 680 this.canvasContext.fillText(unit, unitX, 70); } private drawResolutionName(name): void { - this.canvasContext.font = "normal 35px Verdana"; + this.canvasContext.font = "normal 35px 微软雅黑"; this.canvasContext.fillStyle = "#000000"; let nameX = 380 this.canvasContext.fillText(name, nameX, 60) @@ -309,7 +309,7 @@ export class HeatMapDrawer{ this.canvasContext.stroke(); if (true){ - this.canvasContext.font = "normal 18px Verdana"; + this.canvasContext.font = "normal 18px 微软雅黑"; this.canvasContext.fillStyle = "#000000"; this.canvasContext.fillText(this.xAxis.scales[index], _x - this.canvasContext.measureText(this.xAxis.scales[index]).width / 2, startY + this.verticalScaleLine + this.borderHeight + 36); } @@ -335,7 +335,7 @@ export class HeatMapDrawer{ this.canvasContext.stroke(); if (true) { - this.canvasContext.font = "normal 20px Verdana"; + this.canvasContext.font = "normal 20px 微软雅黑"; this.canvasContext.fillStyle = "#000000"; this.canvasContext.fillText(this.yAxis.scales[index], startX - this.canvasContext.measureText(this.yAxis.scales[index]).width - this.horizontalScaleLine, _y + 10); } diff --git a/04.系统编码/Frontend/src/model/high-chart-create.ts b/04.系统编码/Frontend/src/model/high-chart-create.ts index be69cb2..e88fc8f 100644 --- a/04.系统编码/Frontend/src/model/high-chart-create.ts +++ b/04.系统编码/Frontend/src/model/high-chart-create.ts @@ -32,7 +32,7 @@ export class HighChartCreate { style: { color: '#000000', fontSize: '14px', - fontFamily: 'Verdana' + fontFamily: '微软雅黑' } }, categories: [], @@ -48,7 +48,7 @@ export class HighChartCreate { style: { color: '#000000', fontSize: '14px', - fontFamily: 'Verdana' + fontFamily: '微软雅黑' } }, max: max, @@ -66,7 +66,7 @@ export class HighChartCreate { style: { color: '#000000', fontSize: '14px', - fontFamily: 'Verdana' + fontFamily: '微软雅黑' } }, max: max, diff --git a/04.系统编码/Frontend/src/uilts/box-drawer.ts b/04.系统编码/Frontend/src/uilts/box-drawer.ts index a2bb411..9e8b178 100644 --- a/04.系统编码/Frontend/src/uilts/box-drawer.ts +++ b/04.系统编码/Frontend/src/uilts/box-drawer.ts @@ -10,7 +10,7 @@ export function createEmptyCanvas(id: string, width: number, height: number): vo canvasContext.fillStyle = 'white'; canvasContext.fillRect(0,0, width, height); - canvasContext.font = "normal 48px Verdana"; + canvasContext.font = "normal 48px 微软雅黑"; canvasContext.fillStyle = "#000000"; canvasContext.fillText('暂无数据', (width / 2) - (canvasContext.measureText('暂无数据').width / 2), height / 2 - 24); } @@ -73,7 +73,7 @@ export class BoxDrawer{ let startY = this.paddingTop + this.verticalScaleLine + heightInterval; let interval = (this.borderHeight - heightInterval) / (this.colorChart.colors.length) - this.canvasContext.font = "normal 24px Verdana"; + this.canvasContext.font = "normal 24px 微软雅黑"; this.canvasContext.fillStyle = "#000000"; for(let lastLen = this.colorChart.colors.length - 1, index = lastLen; index >= 0; index --){ @@ -250,7 +250,7 @@ export class BoxDrawer{ this.canvasContext.translate(x, y); this.canvasContext.rotate(Math.PI / 180 * 90); this.canvasContext.textBaseline = 'bottom'; - this.canvasContext.font = "normal 35px Verdana"; + this.canvasContext.font = "normal 35px 微软雅黑"; this.canvasContext.fillStyle = "#000000"; this.canvasContext.fillText(str, 0, 0); this.canvasContext.restore(); @@ -258,7 +258,7 @@ export class BoxDrawer{ } else if (str.match(/[\u4E00-\u9FA5]/) && (y < 576)) { this.canvasContext.save(); this.canvasContext.textBaseline = 'top'; - this.canvasContext.font = "normal 35px Verdana"; + this.canvasContext.font = "normal 35px 微软雅黑"; this.canvasContext.fillStyle = "#000000"; this.canvasContext.fillText(str, x, y); this.canvasContext.restore(); @@ -268,7 +268,7 @@ export class BoxDrawer{ } //温度单位 private drawTemperatureText(unit): void { - this.canvasContext.font = "normal 35px Verdana"; + this.canvasContext.font = "normal 35px 微软雅黑"; this.canvasContext.fillStyle = "#000000"; let unitX = 1390 if (unit === '(degree)') unitX =1350 @@ -298,7 +298,7 @@ export class BoxDrawer{ this.canvasContext.stroke(); if (flag){ - this.canvasContext.font = "normal 30px Verdana"; + this.canvasContext.font = "normal 30px 微软雅黑"; this.canvasContext.fillStyle = "#000000"; const text = moment(this.values.radar_data[index].data_time).format("HH:mm"); this.canvasContext.fillText(text, _x - this.canvasContext.measureText(text).width / 2, startY + yInterval + this.borderHeight + 36); @@ -328,7 +328,7 @@ export class BoxDrawer{ this.canvasContext.stroke(); if (flag) { - this.canvasContext.font = "normal 30px Verdana"; + this.canvasContext.font = "normal 30px 微软雅黑"; this.canvasContext.fillStyle = "#000000"; const text = this.values.radar_info[index].col_factor; this.canvasContext.fillText(text, startX - this.canvasContext.measureText(text).width - this.horizontalScaleLine, _y + 10); @@ -543,7 +543,7 @@ export class Box implements IBox{ } private setText(canvasContext: any) : void{ - canvasContext.font = "normal 26px Arial"; + canvasContext.font = "normal 26px 微软雅黑"; canvasContext.fillStyle = "#fafafa"; const centerX = this.rectX + this.rectWidth / 2;