-
-
Notifications
You must be signed in to change notification settings - Fork 121
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
[Feature Request]: Can I use UTF-8 in compression? #91
Comments
Hi!
Do you mean the encoding of the strings passed to bit7z methods? Natively, Windows uses the UTF-16 encoding for Unicode strings, so you usually need to use This choice will change from the next major version of bit7z (v4.0). |
I mean the directory names and filenames in zip archive. I want them to be encoded in UTF-8, so that I can use the archive on Android platform. If I use 7z.exe, I would add the argument 'cu=on' to get a zip archive with filenames encoded in UTF-8, so is there a way to use bit7z functions to get the same result as 7z argument 'cu=on'? |
Uhm, I see! I actually didn't know this specific option for the zip archives. |
Thank you for your reply! |
Implemented in v4.0.0. Now, you can use 7-zip format settings like BitFileCompressor compressor{ lib, BitFormat::Zip };
compressor.setFormatProperty( L"cu", true );
compressor.compressDirectory( "dir/path/", "dir_archive.zip" ); Please note that the method only accepts wide-character literals as the first argument. |
Feature description
Is there a method that I can compress a directory using UTF-8? I have checked head files, but didn't find a method to change the encoding.
Additional context
No response
Code of Conduct
The text was updated successfully, but these errors were encountered: