diff --git a/docs/api/canvasrenderingcontext2d.md b/docs/api/canvasrenderingcontext2d.md index 0d0590aadf00b72cfe446c0e80a713c196156bbc..d32a108ca8359f25e14320e1491ca41b7bec5a0f 100644 --- a/docs/api/canvasrenderingcontext2d.md +++ b/docs/api/canvasrenderingcontext2d.md @@ -4,6 +4,10 @@ 参考:[canvas组件](../component/canvas.md) +### 关于自定义字体 +当使用自定义字体时,首先使用uni.loadFontFace加载字体[见API](load-font-face.md),成功之后使用font属性指定fontfamily +完整示例代码参考[hello uni-app x](https://gitcode.net/dcloud/hello-uni-app-x/-/blob/alpha/pages/component/canvas/canvas-context.uvue) +