flutter - 如何在颤动中绘制一个一侧为半圆的矩形?
问题描述
这就是我想要实现的目标(请原谅不完美,但你明白了):
我看到一些使用 Clipper 的教程,但它们似乎没有达到我想要的效果,我需要使用容器来绘制它,因为我想在上面放置一些文本。
class DrawCustomCircle extends CustomClipper<Path> {
@override
Path getClip(Size size) {
final Path path = new Path();
...
return path;
}
@override
bool shouldReclip(CustomClipper<Path> oldClipper) {
return true;
}
解决方案
推荐阅读
- javascript - 地图组件偶尔会抛出错误:Uncaught (in promise), "H.map.DataModel#add (Argument #0 [object Object])"
- java - Hibernate - 将整个对象序列化为字段
- javascript - 试图通过点击锚链接专注于特定的 div
- singleton - EJB-Wildfly:可以在 Wildfly 中执行多个 EJB 调度程序,还是应该将它保存在单独的类文件中?
- c# - 访问具有相同列的不同模型的通用视图
- arrays - 字符串数组未绑定到列表视图
- php - 从数组 + json 中删除重复项,array_unique 的问题
- excel - 如何在特定时间运行 VBA Excel 宏,然后每 2 小时运行一次
- python - 如何读取带有分组数据的excel文件
- symfony - Symfony4 Twig Extension 返回图片路径