From 60ddc20e02b6b3e1763c83ce06e7996d44a470e2 Mon Sep 17 00:00:00 2001 From: vcaesar Date: Thu, 17 Feb 2022 12:29:18 -0800 Subject: [PATCH] Update Unicode Type args --- key.go | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/key.go b/key.go index 739cff5..b9a6168 100644 --- a/key.go +++ b/key.go @@ -591,8 +591,12 @@ func CharCodeAt(s string, n int) rune { } // UnicodeType tap uint32 unicode -func UnicodeType(str uint32, pid int) { +func UnicodeType(str uint32, args ...int) { cstr := C.uint(str) + pid := 0 + if len(args) > 0 { + pid = args[0] + } C.unicodeType(cstr, C.int32_t(pid)) }