isCodePointInRange static method

bool isCodePointInRange(
  1. int codePoint,
  2. List<int> ranges
)

Get whether or not a code point is within the ranges. Assumes ranges is a two element list of integers.

Implementation

static bool isCodePointInRange(int codePoint, List<int> ranges) {
  return codePoint >= ranges.first && codePoint <= ranges.last;
}