Ver código fonte

perfect_pen_dash

ananzhusen 2 anos atrás
pai
commit
1eb304dccf
1 arquivos alterados com 10 adições e 0 exclusões
  1. 10 0
      src/views/components/pen.ts

+ 10 - 0
src/views/components/pen.ts

@@ -31,6 +31,16 @@ export const updatePen = (pen: any, prop: string) => {
     //不同模式切换不同的系统配色
   } else if (prop === 'titleFnJs') {
     v.titleFn = null;
+  } else if (prop === 'dash') {
+    v.lineDash = lineDashObj[v[prop]];
   }
   meta2d.setValue(v);
 };
+
+export const lineDashObj = [
+  undefined,
+  [5, 5],
+  [10, 10],
+  [10, 10, 2, 10],
+  [1, 16],
+];