- Sponsor
-
Notifications
You must be signed in to change notification settings - Fork 5
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
Incorrect display in Solaris encoding 1251 #3992
Comments
Please translate to English. |
Replying to andrew_b:
Solaris uses the ANSI1251 encoding name than other systems, where CP1251 is usually. As a result, Cyrillic characters are replaced with questions when using this encoding, since mc switches to 7-bit ASCII. When str_8bit_encodings are added to the list of the values "ansi-1251", "ansi1251" in the file lib/strutil/strutil.c, everything displays correctly, but in Options/Display Bits are also defined by the Input / display codepage 7-bit ASCII, unlike other encodings. |
|
Replying to shurik005:
You can add your encoding to mc.charset file. First column is charset name in terms of iconv, second column is display name.
The ANSI1251 charset is unknown for GNU iconv(1):
|
Replying to andrew_b:
I'm add encoding and replace CP1251 to ANSI1251 or ANSI-1251, but nothing effect. On Solaris:
|
Upps, if compile with added ansi1251,ansi-1251 with change mc.charset then display correctly and Options/Display bits detect fine. Thans |
Branch: 3992_solaris_cp1251
Please test. |
Replying to andrew_b:
Ok, but in mc.chaset need ANSI-1251\tWindows 1251 |
Replying to shurik005:
This is done in m4.include/mc-i18n.m4: --- a/m4.include/mc-i18n.m4
+++ b/m4.include/mc-i18n.m4
@@ -23,4 +23,16 @@
have_charset=yes
charset_msg="yes"
+
+ dnl Solaris has different name of Windows 1251 encoding
+ case $host_os in
+ solaris*)
+ CP1251="ANSI1251"
+ ;;
+ *)
+ CP1251="CP1251"
+ ;;
+ esac
+
+ AC_SUBST(CP1251)
fi
])
Two clarifications are required:
|
if "ANSI1251" then working, but in Options/Display? Bits are also defined by the Input / display codepage 7-bit ASCII, unlike other encodings. |
Replying to shurik005:
Fine.
I've added commit to the branch: [2488e9d4ffdd4e681f4c31ac8ecbeec0d8d77eb1]. It will be squashed before merged to master. |
Fixed, tested on:
|
|
|
Important
This issue was migrated from Trac:
shurik005
(shurik005@….com)solaris
,codepage
,ansi1251
Solaris uses the ANSI1251 encoding name than other systems, where CP1251 is usually. As a result, Cyrillic characters are replaced with questions when using this encoding, since mc switches to 7-bit ASCII. When str_8bit_encodings are added to the list of the values "ansi-1251", "ansi1251" in the file lib/strutil/strutil.c, everything displays correctly, but in Options/Display? Bits are also defined by the Input / display codepage 7-bit ASCII, unlike other encodings.
The text was updated successfully, but these errors were encountered: