code: protected TerminalSize getBounds(String[] lines, TerminalSize currentBounds) {
          if(currentBounds == null) {
              currentBounds = TerminalSize.ZERO;
          }
          currentBounds = currentBounds.withRows(lines.length);
          if(labelWidth == null || labelWidth == 0) {
              int preferredWidth = 0;
              for(String line : lines) {
                  int lineWidth = TerminalTextUtils.getColumnWidth(line);
                  if(preferredWidth < lineWidth) {
                      preferredWidth = lineWidth;
                  }
              }
              currentBounds = currentBounds.withColumns(preferredWidth);
          }
          else {
              List<String> wordWrapped = TerminalTextUtils.getWordWrappedText(labelWidth, lines);
              currentBounds = currentBounds.withColumns(labelWidth).withRows(wordWrapped.size());
          }
          return currentBounds;
      }
docs: Returns the area, in terminal columns and rows, required to fully draw the lines passed in.
  @param lines Lines to measure the size of
  @param currentBounds Optional (can pass {@code null}) terminal size to use for storing the output values. If the
  method is called many times and always returning the same value, passing in an external
  reference of this size will avoid creating new {@code TerminalSize} objects every time
  @return Size that is required to draw the lines