Ejemplo n.º 1
0
        internal string ToString(CultureInfo cultureInfo)
        {
            char listSeparator = TokenizerHelper.GetNumericListSeparator(cultureInfo);

            // Initial capacity [64] is an estimate based on a sum of:
            // 12 = 1x double (twelve digits is generous for the range of values likely)
            //  8 = 4x Unit Type string (approx two characters)
            //  2 = 2x separator characters

            if (_unitType == GridUnitType.Auto)
            {
                return("Auto");
            }
            else if (_unitType == GridUnitType.Pixel)
            {
                return(Convert.ToString(_unitValue, cultureInfo));
            }
            else
            {
                return(Convert.ToString(_unitValue, cultureInfo) + "*");
            }
        }