系列文章
①:安装及基本概念
②:EasyX函数-设备相关
③:EasyX函数-颜色模型
④:EasyX函数-图形样式
⑤:EasyX函数-绘图相关〔1〕
⑥:EasyX函数-绘图相关〔2〕
文章目录
- 系列文章
- 前言
- 九、EasyX函数 之 绘图相关
-
- 〔§〕标记说明
- 〔2〕矩形 & 多边形 & 圆角矩形
-
- 矩形 \,\,\,\,\,\,\,\,\,\,\,\,\, >>> rectangle()
- 矩形 \,\,\,\,\,\,\,\,\,\,\,\,\, >>> solidrectangle()
- 矩形 \,\,\,\,\,\,\,\,\,\,\,\,\, >>> fillrectangle()
- 矩形 \,\,\,\,\,\,\,\,\,\,\,\,\, >>> clearrectangle()
- 多边形 \,\,\,\,\,\,\,\, >>>polygon()
- 多边形 \,\,\,\,\,\,\,\, >>>solidpolygon()
- 多边形 \,\,\,\,\,\,\,\, >>>fillpolygon()
- 多边形 \,\,\,\,\,\,\,\, >>>clearpolygon()
- 圆角矩形 \,\,\, >>> roundrect()
- 圆角矩形 \,\,\, >>> solidroundrect()
- 圆角矩形 \,\,\, >>> fillroundrect()
- 圆角矩形 \,\,\, >>> clearroundrect()
- 矩形 \,\,\,\,\,\,\,\,\,\,\,\,\, >>> rectangle()
- 〔3〕区域填充
- 〔§〕标记说明
前言
作者也是个小白,本【教程】充其量算个学习笔记,若有写的不正确的地方还请指教。
九、EasyX函数 之 绘图相关
〔§〕标记说明
见⑤。
特别地,对于〖填充〗,除非特殊说明,均指 >以当前填充样式< 填充;
对于【有边框】,除非特殊说明,均指 >以当前画线样式< 绘制边框;
对于 清空 , 除非特殊说明,均指 >以当前背景色< 清空。
(懒得写了)
另外,其实按标准说法,在平面直角坐标系中的点P(a,b),a叫作横坐标、b叫纵坐标,但在此处写作x坐标、y坐标
〔2〕矩形 & 多边形 & 圆角矩形
-
矩形 \,\,\,\,\,\,\,\,\,\,\,\,\, >>> rectangle()
作用:画〖无填充〗 矩形。
函数原型:
void fillrectangle( int left, int top, int right, int bottom );参数:
intl e f t left left:矩形左部 x 坐标。intt o p top top:矩形顶部 y 坐标。intr i g h t right right:矩形右部 x 坐标。intb o t t o m bottom bottom:矩形底部 y 坐标。
返回值: /
-
矩形 \,\,\,\,\,\,\,\,\,\,\,\,\, >>> solidrectangle()
作用:画【无边框】的 矩形。
函数原型:
void fillrectangle( int left, int top, int right, int bottom );参数:
intl e f t left left:矩形左部 x 坐标。intt o p top top:矩形顶部 y 坐标。intr i g h t right right:矩形右部 x 坐标。intb o t t o m bottom bottom:矩形底部 y 坐标。
返回值: /
-
矩形 \,\,\,\,\,\,\,\,\,\,\,\,\, >>> fillrectangle()
作用:画【有边框】的〖填充〗 矩形。
函数原型:
void fillrectangle( int left, int top, int right, int bottom );参数:
intl e f t left left:矩形左部 x 坐标。intt o p top top:矩形顶部 y 坐标。intr i g h t right right:矩形右部 x 坐标。intb o t t o m bottom bottom:矩形底部 y 坐标。
返回值: /
-
矩形 \,\,\,\,\,\,\,\,\,\,\,\,\, >>> clearrectangle()
作用:清空 矩形 区域。
函数原型:

这篇博客详细介绍了EasyX库中用于绘制矩形、多边形和圆角矩形的相关函数,包括无填充、无边框、有边框填充等不同情况,以及清空区域的函数,并提供了函数原型和参数说明。
最低0.47元/天 解锁文章
625

被折叠的 条评论
为什么被折叠?



