withSquareSize method

ChessBoardStyle withSquareSize(
  1. double size
)

Implementation

ChessBoardStyle withSquareSize(double size) {
  if (size < 60) {
    return copyWith(showRankAndFileLabels: false);
  }
  return copyWith(
      whiteSquareTextStyle: whiteSquareTextStyle.copyWith(
          fontSize: _getGoodFontSizeForSquareSize(size)),
      blackSquareTextStyle: blackSquareTextStyle.copyWith(
          fontSize: _getGoodFontSizeForSquareSize(size)));
}