📝 Mention combined characters

This commit is contained in:
Kevin Sawicki
2014-10-24 09:40:32 -07:00
parent ddeec5d4d5
commit 232be1f876

View File

@@ -42,16 +42,18 @@ isCombinedCharacter = (string, index=0) ->
not isCombiningCharacter(string, index) and isCombiningCharacter(string, index + 1)
# Is the character at the given index the start of high/low surrogate pair
# or a variation sequence?
# a variation sequence, or a combined character?
#
# * `string` The {String} to check for a surrogate pair or variation sequence.
# * `string` The {String} to check for a surrogate pair, variation sequence,
# or combined character.
# * `index` The {Number} index to look for a surrogate pair at.
#
# Return a {Boolean}.
isPairedCharacter = (string, index=0) ->
isSurrogatePair(string, index) or isVariationSequence(string, index) or isCombinedCharacter(string, index)
# Does the given string contain at least surrogate pair or variation sequence?
# Does the given string contain at least surrogate pair, variation sequence,
# or combined character?
#
# * `string` The {String} to check for the presence of paired characters.
#