according to

https://unicode.org/reports/tr51/#Property_Stability

an Emoji is

  \p{RI} \p{RI}
| \p{Emoji}
  ( \p{EMod}
    | \x{FE0F} \x{20E3}?
    | [\x{E0020}-\x{E007E}]+ \x{E007F} )?
  (\x{200D} \p{Emoji}
    ( \p{EMod}
      | \x{FE0F} \x{20E3}? )?)+

no kidding.

but the ICU in 4D does not support the [:Emoji:] or \p{Emoji} property.

---

that said, if you just want to filter non-ASCII, for example, it could be as 
simple as

$text:="I an unwell 😷 cough cough😭"

$regex:="[:^ascii:]"

While (Match regex($regex;$text;1;$pos;$len))
$text:=Delete string($text;$pos;$len)
End while



**********************************************************************
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:[email protected]
**********************************************************************

Reply via email to