idraw
idraw copied to clipboard
A simple JavaScript framework for Drawing on the web.(一个面向Web绘图的JavaScript框架)
## Feature * [ ] https://github.com/idrawjs/idraw/issues/130 * [ ] Add `on('dataResourceLoaded')` in order to listen, all resources are loaded * ~Add method `stopRender` to force stop `requestAnimationFrame`~ * [ ]...
一点建议
是否考虑针对 文本元素 增加一个可配置参数 maxWidth。 有些场景下,文本元素 的文本长度是不确定的,需要让文字自适应文本渲染区域,因此有此需求。 Related API: ctx.fillText(text, x, y, [maxWidth]); maxWidth (可选):绘制的最大宽度。如果指定了值,并且经过计算字符串的值比最大宽度还要宽,字体为了适应会水平缩放(如果通过水平缩放当前字体,可以进行有效的或者合理可读的处理)或者使用小号的字体 --- from MDN
Realize the gradient of text and background
Add plugins to idraw for auxiliary drawing. For example: ```js import iDraw from 'idraw'; const idraw = new iDraw({...}); idraw.addPlugin(new iDraw.RulerPlugin()); idraw.addPlugin(new iDraw.AuxiliaryPlugin()); ```
网络图片问题
您好,在使用您的 exportDataURL 的时候,如果里面的image src 为网络图片,会报错 Uncaught DOMException: Failed to execute 'toDataURL' on 'HTMLCanvasElement': Tainted canvases may not be exported.
我看了一下源码.是无法取消文字元素的垂直居中,能否添加这个功能呢?
@chenshenhai 作者你好,我发现0.4版本中似乎有些函数和监听事件方法并不全支持0.3版本,希望能够在0.3版本中修复#303问题,并对文本对象扩充行间距参数。  本地测试效果如下:  我本地修改测试的idraw版本为0.3.0-alpha.6,我将0.4版本中的文本绘制方法复制到了0.3版本中,并将参数改为了0.3版本的参数。
## Current Development Branch https://github.com/idrawjs/idraw/tree/dev-0.4 ## Big Refactor * [x] Refactor: Use middleware mechanism to realize all functions * [x] Refactor: add scale method of @idraw/renderer * [x] Refactor: refactor...
Hello idraw team, Thank you for quickly resolving the request in idraw studio, is it possible to make idraw(renderer) compatible with node using https://github.com/Automattic/node-canvas konva seem to be working fine...