未验证 提交 c5f40460 编写于 作者: 末日拿铁 提交者: Gitee

update zh-cn/application-dev/reference/apis/js-apis-arkui-drawableDescriptor.md.

获取裁切路径方法
Signed-off-by: N末日拿铁 <chenpeng242@huawei.com>
上级 222c0fe0
......@@ -159,3 +159,22 @@ getMask(): DrawableDescriptor;
drawable: DrawableDescriptor = (<LayeredDrawableDescriptor> (this.resManager.getDrawableDescriptor($r('app.media.drawable')
.id))).getMask();
```
## LayeredDrawableDescriptor.getMashClipPath
static getMashClipPath(): string;
LayeredDrawableDescriptor的静态方法,获取系统内置的裁切路径参数。
**系统能力:** SystemCapability.ArkUI.ArkUI.Full
**返回值:**
| 类型 | 说明 |
| ---------------------------------------- | -------------------- |
| string | 返回裁切路径的命令字符串 |
**示例:**
```ts
Image($r('app.media.testImg'))
.width('200px').height('200px')
.clip(new Path({commands:LayeredDrawableDescriptor.getMaskClipPath()}))
```
\ No newline at end of file
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册