getDelimeter function
Implementation
String getDelimeter(int length, {String title = ''}) {
title = title.trim().isNotEmpty ? ' ${title.trim()} ' : title;
length = max(length, title.length);
length = title.length.isEven ? length : length + 1;
final delimeter = '=' * length;
final start = (length - title.length) ~/ 2;
final end = (length + title.length) ~/ 2;
return delimeter.replaceRange(start, end, title);
}