Vuido
Search
K
Links

AreaPath

A stroked and/or filled path.

Attributes

path

The path to be stroked and/or filled.

fill

The fill brush. By default it is inherited by the parent AreaGroup. If not specified, the path is not filled.

stroke

The stroke brush. By default it is inherited by the parent AreaGroup. If not specified, the path is not stroked.

line

The style of line for the stroke. By default it is inherited by the parent AreaGroup. If not specified, a solid one-pixel line is used.

Example

<template>
<Area>
<AreaPath v-bind:path="circlePath" v-bind:fill="redBrush"/>
</Area>
</template>
<script>
import libui from 'libui-node'
export default {
computed: {
cicrlePath() {
const path = new libui.UiDrawPath( libui.fillMode.winding );
path.newFigureWithArc( 100, 100, 50, 0, Math.PI * 2, false );
path.end();
return path;
},
redBrush() {
const brush = new libui.DrawBrush();
brush.color = new libui.Color( 1, 0, 0, 1 );
brush.type = libui.brushType.solid;
return brush;
}
}
}
</script>
Last modified 5yr ago