isLineEdge method
This edge is a line edge if
- at least one of the labels is a line label
- any labels which are not line labels have all Locations = EXTERIOR
Implementation
bool isLineEdge() {
bool isLine = label!.isLine(0) || label!.isLine(1);
bool isExteriorIfArea0 = !label!.isAreaWithIndex(0) ||
label!.allPositionsEqual(0, Location.EXTERIOR);
bool isExteriorIfArea1 = !label!.isAreaWithIndex(1) ||
label!.allPositionsEqual(1, Location.EXTERIOR);
return isLine && isExteriorIfArea0 && isExteriorIfArea1;
}