An update on Shift Jis and Mono
I thought I tried this before and it failed, but with the latest version of Mono “shift_jis” is a valid encoding.
Posted in Mono, Uncategorized by: David
No Comments
I thought I tried this before and it failed, but with the latest version of Mono “shift_jis” is a valid encoding.
Posted in Mono, Uncategorized by: David
No Comments
In continuation of my last post about Encoding.GetEncoding, I found that “cp932″ will work for getting shift-jis, which means that I just have to change “shift-jis” to “cp932″ in my code and in all of my configuration files and I should be OK.
update: After checking in Windows, “cp932″ does not exist. This means I must [...]
Posted in Mono, Research by: David
No Comments
I ran into another small difference that is a bit annoying and I am not for sure if it will become a big deal or not. When using Encoding.GetEncoding in mono with “SHIFT-JIS” I get the following…
Unhandled Exception: System.NotSupportedException: Encoding name `SHIFT-JIS' not supported
at System.Text.Encoding.GetEncoding (System.String name) [0x00000]
at KantLibrary.Translation.ExciteJapanTranslator.Translate (System.String sourceText, Code from, Code to) [...]
Posted in Mono, Research by: David
No Comments
I happen to run into a difference in implementation between the Mono project’s implementation of .Net and Microsoft’s. It seems that escaped strings are handled differently in Regex.Replace when the escaped string is the replacement string. What does this mean? The following code …
string replaced = Regex.Replace( "I like the backslash", "backslash", @"\\" );
Console.WriteLine(replaced);
will output [...]
Posted in Mono, Research by: David
No Comments