diff --git a/src/BlockHub/CanvasBlock/Canvas.vue b/src/BlockHub/CanvasBlock/Canvas.vue index f4414bd..3e067ac 100644 --- a/src/BlockHub/CanvasBlock/Canvas.vue +++ b/src/BlockHub/CanvasBlock/Canvas.vue @@ -34,7 +34,7 @@ const render = () => { } context.save() context.strokeStyle = 'black' - context.lineWidth = 1 + context.lineWidth = 2 context.beginPath() const start = points.get(0) as OriginMap context.moveTo(start.x as number, start.y as number) diff --git a/src/Kernel/ToolBox/controller/PenToolController.ts b/src/Kernel/ToolBox/controller/PenToolController.ts index 7378da0..2ee75bc 100644 --- a/src/Kernel/ToolBox/controller/PenToolController.ts +++ b/src/Kernel/ToolBox/controller/PenToolController.ts @@ -1,7 +1,7 @@ import { toSlideCoords } from '@Utils/toSlideCoords' import { ToolController } from './_ToolController' import { CanvasBlock } from '@BlockHub/CanvasBlock/CanvasBlock' -import { selectionManager, slideManager, toolBox } from '@Kernel/index' +import { selectionManager, slideManager, toolBox, zoom } from '@Kernel/index' import { ArrayStore } from '@Kernel/Store/ArrayStore' import { OriginMap } from '@Kernel/Store/_Store' @@ -16,7 +16,7 @@ export class PenToolController extends ToolController { this._drawing = true const slideElement = event.currentTarget as HTMLElement const slideRect = slideElement.getBoundingClientRect() - this._canvasBlock = new CanvasBlock(0, 0, slideRect.width, slideRect.height) + this._canvasBlock = new CanvasBlock(0, 0, slideRect.width / zoom.value, slideRect.height / zoom.value) slideManager.currentSlide.addBlock(this._canvasBlock) }