https://bugs.kde.org/show_bug.cgi?id=378904

--- Comment #16 from Elvis Angelaccio <elvis.angelac...@kde.org> ---
Update on this issue: I played a bit with encoding probing using both
KEncodingProber and ICU.

The biggest issue with this approach is that filenames are usually very short,
so the prober does not have enough data to properly guess the correct encoding.

One possible solution could be the following: we add KEncodingProber support in
the libzip plugin (Ark's default plugin for zip files). If KEncodingProber
detects one or more non-unicode encodings, Ark would show a notification to the
user asking if they want to attempt to fix garbled filenames, if any. If the
user confirms, the libzip plugin would then reload the archive and convert the
filenames from the detected encoding to the standard UTF-16 encoding used by
Qt. This "opt-in" step is required because if we do it automatically we could
break the normal workflow for valid zip archives that only contain UTF-8
filenames (since again, the probing is not precise and could detect a wrong
encoding for a valid UTF-8 filename, and there is the addition overhead problem
mentioned in previous comments).

-- 
You are receiving this mail because:
You are watching all bug changes.

Reply via email to