setChar method
Stores the first Unicode scalar from a non-empty char.
Implementation
void setChar(int x, int y, String char) {
final index = _getIndex(x, y);
if (char.isEmpty) throw ArgumentError('Character cannot be empty');
_chars[index] = char.runes.first;
}