【WPF】Path绘制的迷你命令

Command

Name

Description

F i

FillRule

i=0:EvenOdd.

i=1:NonZero.

M x y

Move

Moveto (x, y).

m x y

Relative move

Moveto (x0+x, y0+y).

L x y

Line

Drawline to (x, y).

l x y

Relative line

Drawline to (x0+x, y0+y).

H x

Horizontal line

Drawline to (x, y0).

h x

Relative horizontal line

Drawline to (x0+x, y0).

V y

Vertical line

Drawline to (x0, y).

v y

Relative vertical line

Drawline to (x0, y0+y).

A xr yr a i j x y

Arc

Drawarc to (x, y) based on ellipse with radii (xr,yr) rotated a degrees. i=1:IsLargeArc. j=1: Clockwise.

a xr yr a i j x y

Relative arc

Drawarc to (x0+x, y0+y).

C x1 y1 x2y2 x3 y3

CubicBézier

DrawBézier to (x3, y3) withcontrol points (x1, y1) and (x2, y2).

c x1 y1 x2y2 x3 y3

Relative cubic Bézier

DrawBézier to (x0+x3,y0+y3) with control points (x0+x1, y0+y1) and (x0+x2, y0+y2).

S x2 y2 x3 y3

Smooth cubic Bézier

DrawBézier to (x3, y3) with reflected control point and (x2, y2).

s x2 y2 x3y3

Relative smooth cubic Bézier

DrawBézier to (x0+x3,y0+y3) with reflected control point and (x0+x2, y0+y2).

Q x1 y1 x2y2

Quadratic Bézier

Drawquadratic Bézier to (x2, y2)with control point (x1, y1).

q x1 y1 x2y2

Relative quadratic Bézier

Drawquadratic Bézier to (x0+x2,y0+y2) with control point(x0+x1, y0+y1).

Z

z

Closefigure

 

From: 《Application = Code + Markup : A Guide to the Microsoft Windows Presentation Foundation》 by Charles Petzold

posted @   大佛脚下  阅读(1461)  评论(0编辑  收藏  举报
编辑推荐:
· AI与.NET技术实操系列:基于图像分类模型对图像进行分类
· go语言实现终端里的倒计时
· 如何编写易于单元测试的代码
· 10年+ .NET Coder 心语,封装的思维:从隐藏、稳定开始理解其本质意义
· .NET Core 中如何实现缓存的预热?
阅读排行:
· 25岁的心里话
· 闲置电脑爆改个人服务器(超详细) #公网映射 #Vmware虚拟网络编辑器
· 零经验选手,Compose 一天开发一款小游戏!
· 通过 API 将Deepseek响应流式内容输出到前端
· AI Agent开发,如何调用三方的API Function,是通过提示词来发起调用的吗
点击右上角即可分享
微信分享提示