public static bool TranslateTextAlign(string styleString, out TextAlignments textAlignment)
        {
            textAlignment = TextAlignments.General;
            if (!string.IsNullOrEmpty(styleString))
            {
                if (RichTextStyleTranslator.CompareWithInvariantCulture("General", styleString))
                {
                    textAlignment = TextAlignments.General;
                    goto IL_0067;
                }
                if (RichTextStyleTranslator.CompareWithInvariantCulture("Left", styleString))
                {
                    textAlignment = TextAlignments.Left;
                    goto IL_0067;
                }
                if (RichTextStyleTranslator.CompareWithInvariantCulture("Center", styleString))
                {
                    textAlignment = TextAlignments.Center;
                    goto IL_0067;
                }
                if (RichTextStyleTranslator.CompareWithInvariantCulture("Right", styleString))
                {
                    textAlignment = TextAlignments.Right;
                    goto IL_0067;
                }
                if (RichTextStyleTranslator.CompareWithInvariantCulture("Default", styleString))
                {
                    textAlignment = TextAlignments.General;
                    goto IL_0067;
                }
                return(false);
            }
            return(false);

IL_0067:
            return(true);
        }
        public static bool TranslateFontWeight(string styleString, out FontWeights fontWieght)
        {
            fontWieght = FontWeights.Normal;
            if (!string.IsNullOrEmpty(styleString))
            {
                if (RichTextStyleTranslator.CompareWithInvariantCulture("Normal", styleString))
                {
                    fontWieght = FontWeights.Normal;
                    goto IL_01b6;
                }
                if (RichTextStyleTranslator.CompareWithInvariantCulture("Bold", styleString))
                {
                    fontWieght = FontWeights.Bold;
                    goto IL_01b6;
                }
                if (RichTextStyleTranslator.CompareWithInvariantCulture("Bolder", styleString))
                {
                    fontWieght = FontWeights.Bold;
                    goto IL_01b6;
                }
                if (RichTextStyleTranslator.CompareWithInvariantCulture("100", styleString))
                {
                    fontWieght = FontWeights.Thin;
                    goto IL_01b6;
                }
                if (RichTextStyleTranslator.CompareWithInvariantCulture("200", styleString))
                {
                    fontWieght = FontWeights.ExtraLight;
                    goto IL_01b6;
                }
                if (RichTextStyleTranslator.CompareWithInvariantCulture("300", styleString))
                {
                    fontWieght = FontWeights.Light;
                    goto IL_01b6;
                }
                if (RichTextStyleTranslator.CompareWithInvariantCulture("400", styleString))
                {
                    fontWieght = FontWeights.Normal;
                    goto IL_01b6;
                }
                if (RichTextStyleTranslator.CompareWithInvariantCulture("500", styleString))
                {
                    fontWieght = FontWeights.Medium;
                    goto IL_01b6;
                }
                if (RichTextStyleTranslator.CompareWithInvariantCulture("600", styleString))
                {
                    fontWieght = FontWeights.SemiBold;
                    goto IL_01b6;
                }
                if (RichTextStyleTranslator.CompareWithInvariantCulture("700", styleString))
                {
                    fontWieght = FontWeights.Bold;
                    goto IL_01b6;
                }
                if (RichTextStyleTranslator.CompareWithInvariantCulture("800", styleString))
                {
                    fontWieght = FontWeights.ExtraBold;
                    goto IL_01b6;
                }
                if (RichTextStyleTranslator.CompareWithInvariantCulture("900", styleString))
                {
                    fontWieght = FontWeights.Heavy;
                    goto IL_01b6;
                }
                if (RichTextStyleTranslator.CompareWithInvariantCulture("Thin", styleString))
                {
                    fontWieght = FontWeights.Thin;
                    goto IL_01b6;
                }
                if (RichTextStyleTranslator.CompareWithInvariantCulture("ExtraLight", styleString))
                {
                    fontWieght = FontWeights.ExtraLight;
                    goto IL_01b6;
                }
                if (RichTextStyleTranslator.CompareWithInvariantCulture("Light", styleString))
                {
                    fontWieght = FontWeights.Light;
                    goto IL_01b6;
                }
                if (RichTextStyleTranslator.CompareWithInvariantCulture("Lighter", styleString))
                {
                    fontWieght = FontWeights.Light;
                    goto IL_01b6;
                }
                if (RichTextStyleTranslator.CompareWithInvariantCulture("Medium", styleString))
                {
                    fontWieght = FontWeights.Medium;
                    goto IL_01b6;
                }
                if (RichTextStyleTranslator.CompareWithInvariantCulture("SemiBold", styleString))
                {
                    fontWieght = FontWeights.SemiBold;
                    goto IL_01b6;
                }
                if (RichTextStyleTranslator.CompareWithInvariantCulture("ExtraBold", styleString))
                {
                    fontWieght = FontWeights.ExtraBold;
                    goto IL_01b6;
                }
                if (RichTextStyleTranslator.CompareWithInvariantCulture("Heavy", styleString))
                {
                    fontWieght = FontWeights.Heavy;
                    goto IL_01b6;
                }
                if (RichTextStyleTranslator.CompareWithInvariantCulture("Default", styleString))
                {
                    fontWieght = FontWeights.Normal;
                    goto IL_01b6;
                }
                return(false);
            }
            return(false);

IL_01b6:
            return(true);
        }