Пример #1
0
        private static Encoding GetAsciiEncoding()
        {
            Encoding encoding = SmEncodings.GetEncoding("us-ascii");

            if (null != encoding)
            {
                return(encoding);
            }
            return((Encoding) new SM.Media.Utility.TextEncodings.AsciiEncoding());
        }
Пример #2
0
        private static Encoding GetLatin1Encoding()
        {
            Encoding encoding1 = SmEncodings.GetEncoding("Windows-1252");

            if (null != encoding1)
            {
                return(encoding1);
            }
            Encoding encoding2 = SmEncodings.GetEncoding("iso-8859-1");

            if (null != encoding2)
            {
                return(encoding2);
            }
            return((Encoding) new Windows1252Encoding());
        }