LineProps
Props of Line: its two ends in user units, and paint.
Utilisation
Draw a separator in a canvas.
Ce type est utilisé par Line
// Draw a separator in a canvas.
import { Drawing, Line } from 'kuito';
<Drawing label="Divider" viewBox={[0, 0, 100, 2]} width={200} height={4}>
<Line x1={0} y1={1} x2={100} y2={1} stroke="#e5e7eb" strokeWidth={2} strokeDasharray={[4, 2]} />
</Drawing>;Déclaration du type
export interface LineProps extends ShapePaint {
x1?: number;
y1?: number;
x2?: number;
y2?: number;
}Membres 18
| Nom | Type | Requis | Description |
|---|---|---|---|
x1 | number | Non | — |
y1 | number | Non | — |
x2 | number | Non | — |
y2 | number | Non | — |
fill | string | Non | A hex color, or none; black by default. |
fillRule | FillRule | Non | — |
stroke | string | Non | A hex color, or none, the default. |
strokeWidth | number | Non | In user units; 1 by default. |
strokeLinecap | StrokeLinecap | Non | — |
strokeLinejoin | StrokeLinejoin | Non | — |
strokeMiterlimit | number | Non | — |
strokeDasharray | readonly number[] | Non | Dash and gap lengths in user units, repeated. |
strokeDashoffset | number | Non | — |
opacity | number | Non | Multiplies with its Groups' opacity. |
translateX | number | Non | In user units, then rotate in degrees and scale, about the origin. |
translateY | number | Non | — |
scale | number | Non | — |
rotate | number | Non | — |
Généré depuis les déclarations TypeScript publiques : signatures, props et valeurs par défaut viennent de la source vérifiée, les descriptions de sa JSDoc. Aucune valeur par défaut n'est inventée.