needChangeToFoldWidget method
bool
needChangeToFoldWidget(
- int i,
- double offsetX,
- double screenW,
- int nowLine,
- FlowPaintingContext context,
Implementation
bool needChangeToFoldWidget(int i, double offsetX, double screenW,
int nowLine, FlowPaintingContext context) {
if (!isFold) {
return false;
}
if ((i + 1 < context.childCount - 1) &&
((offsetX +
(context.getChildSize(i)?.width ?? 0) +
spacing +
(context.getChildSize(i + 1)?.width ?? 0)) >
screenW)) {
if ((isFold && ((nowLine + 1) > foldLine))) {
return true;
}
}
return false;
}