@Nonnull
	@Override
	protected StyleSpans<Collection<String>> createStyleSpansImpl(@Nonnull String text, int start, int end) {
		try {
			Region region = new Region(text, null, rootRule, start, end);
			region.split(rootRule.subRules());

			StyleSpansBuilder<Collection<String>> builder = new StyleSpansBuilder<>();
			region.visitBuilder(builder);
			return builder.create();
		} catch (Throwable t) {
			logger.error("Error creating style spans for text", t);
			throw t;
		}
	}
@param rootRule
		Root rule, constituting a language by its sub-rules.
recaf-ui/src/main/java/software/coley/recaf/ui/control/richtext/syntax/RegexSyntaxHighlighter.java