Prechádzať zdrojové kódy

答题卡留痕增加对号错号

dengshaobo 2 týždňov pred
rodič
commit
523d032d8d
1 zmenil súbory, kde vykonal 19 pridanie a 0 odobranie
  1. 19 0
      src/components/PaperImage.vue

+ 19 - 0
src/components/PaperImage.vue

@@ -838,6 +838,25 @@ export default {
                       this.DrawText(coords.x, coords.y, drawItem.text,ctx);
                       break;
                     }
+                    case 6: 
+                    {
+                      // 绘制对号
+                      const coords = {
+                        x: parseFloat((drawItem.x * zoomScale + offsetX).toFixed(2)),
+                        y: parseFloat((drawItem.y * zoomScale + offsetY).toFixed(2))
+                      };
+                      this.DrawText(coords.x, coords.y, '✔',ctx);
+                      break;
+                    }
+                    case 7: {
+                      // 绘制对号
+                      const coords = {
+                        x: parseFloat((drawItem.x * zoomScale + offsetX).toFixed(2)),
+                        y: parseFloat((drawItem.y * zoomScale + offsetY).toFixed(2))
+                      };
+                      this.DrawText(coords.x, coords.y, '✘',ctx);
+                      break;
+                    }
                     
                     default:
                       console.warn('未知的绘图类型:', drawItem.drawType);