Beispiel #1
0
        public string BuildCodeFormattedString(TableCellRenderSpecification spec)
        {
            var alignment = spec.Alignment;
            var maximumWidth = spec.MaximumWidth;
            var encodedText = GetEncodedText();

            return encodedText.Align(alignment, maximumWidth);
        }
Beispiel #2
0
        public string BuildCodeFormattedString(TableCellRenderSpecification spec)
        {
            var alignment    = spec.Alignment;
            var maximumWidth = spec.MaximumWidth;
            var encodedText  = GetEncodedText();

            return(encodedText.Align(alignment, maximumWidth));
        }
Beispiel #3
0
            private static string BuildDividerCell(TableCellRenderSpecification spec)
            {
                var dashes = new string('-', spec.MaximumWidth);

                switch (spec.Alignment)
                {
                    case TableColumnAlignment.Left:
                        return ":" + dashes + " ";
                    case TableColumnAlignment.Center:
                        return ":" + dashes + ":";
                    case TableColumnAlignment.Right:
                        return " " + dashes + ":";
                    default:
                        return " " + dashes + " ";

                }
            }
Beispiel #4
0
            private static string BuildDividerCell(TableCellRenderSpecification spec)
            {
                var dashes = new string('-', spec.MaximumWidth);

                switch (spec.Alignment)
                {
                case TableColumnAlignment.Left:
                    return(":" + dashes + " ");

                case TableColumnAlignment.Center:
                    return(":" + dashes + ":");

                case TableColumnAlignment.Right:
                    return(" " + dashes + ":");

                default:
                    return(" " + dashes + " ");
                }
            }