1# ArkUI Subsystem Changelog 2 3## cl.arkui.1 setLineDash Implementation Change 4 5 6Changed the unit of the **number** parameter in the **setLineDash** API from px to vp. 7 8**Example** 9```ts 10@Entry 11@Component 12struct SetLineDash { 13 private settings: RenderingContextSettings = new RenderingContextSettings(true) 14 private context: CanvasRenderingContext2D = new CanvasRenderingContext2D(this.settings) 15 16 build() { 17 Flex({ direction: FlexDirection.Column, alignItems: ItemAlign.Center, justifyContent: FlexAlign.Center }) { 18 Canvas(this.context) 19 .width('100%') 20 .height('100%') 21 .backgroundColor('#ffff00') 22 .onReady(() =>{ 23 let ctx = this.context 24 ctx.lineWidth = 5 25 ctx.arc(100, 75, 50, 0, 6.28) 26 ctx.setLineDash([10,20]) 27 ctx.stroke(); 28 }) 29 Image('image/SetLineDash.png') 30 .objectFit(ImageFit.Contain) 31 } 32 .width('100%') 33 .height('100%') 34 } 35} 36``` 37API version 9: The unit of the **number** parameter in the **setLineDash** API is px. 38 39 40 41API version 10 and later: The unit of the **number** parameter in the **setLineDash** API is vp. 42 43 44 45**Change Impact** 46 47The drawing effect of the **setLineDash** API in API version 9 or earlier is different from that in API version 10 or later. 48