-
Notifications
You must be signed in to change notification settings - Fork 146
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix #46 (make sure symbol-like codepoints have nonzero width) #47
Conversation
…they aren't in Unifont)
👍 LGTM |
It's very similar. The mdf5 hashes agree for both the cached and original versions of UnicodeData.txt - |
My ruby version is |
Looks like we are seeing ruby version-specific behavior. I get a different |
I'm using Ruby 2.0.0p481. Perhaps the culprit is the last few lines of $stdout << "const utf8proc_int32_t utf8proc_combinations[] = {\n "
i = 0
comb1st_indicies.keys.each_index do |a|
comb2nd_indicies.keys.each_index do |b|
i += 1
if i == 8
i = 0
$stdout << "\n "
end
$stdout << ( comb_array[a][b] or -1 ) << ", "
end
end
$stdout << "};\n\n" It looks like the output order could depend on the order of the keys in a hash table. Probably we should just sort them. |
Maybe we should just rewrite that in a better language? 😀 I happen to know a very nice one! |
Nope, that wasn't it. |
I don't think the current Unicode data file is sorted |
I regenerated the |
Okay, whatever @jiahao did seems to have worked. |
This uses width 1 for symbols that are missing from Unifont but have categories indicating that they have nonzero width. See #46.
It also corrects for a few apparent bugs in Unifont's widths (https://savannah.gnu.org/bugs/index.php?45395).