otsaloma / gaupol

Editor for text-based subtitle files
https://otsaloma.io/gaupol/
GNU General Public License v3.0
247 stars 35 forks source link

Use charset-normalizer for encoding detection #223

Closed nijel closed 1 month ago

nijel commented 1 month ago

Fixes #222

otsaloma commented 1 month ago

Thanks, I'll test this and merge if no issues come up.

otsaloma commented 1 month ago

Seems a lot faster and also better quality. With my files that I know were all saved as utf_8, charset-normalizer detected all as either utf_8 or ascii (which is fine), while chardet, in addition to those, detected some as latin1, cp1252 and mac_roman (which is at least unexpected, not sure if wrong).

I'll add some commits to update the README and Flatpak before merging.

otsaloma commented 1 month ago

I seem to have pushed to some wrong branch. Merging now, adding the rest to master.