コード例 #1
0
        private string GetMultiColumnLine(SplitedLine splitedLine)
        {
            var tabulatedLine  = TableBorderCharacters.Vertical.ToString();
            var leftAlignWides = GetColumnWidths();

            for (int i = 0; i < Column; i++)
            {
                tabulatedLine += splitedLine.Words[i] + string.Empty.PadRight(leftAlignWides[i] - Encoding.Default.GetByteCount(splitedLine.Words[i]), ' ') + TableBorderCharacters.Vertical;
            }
            return(tabulatedLine);
        }
コード例 #2
0
 private string GetSingleColumnLine(SplitedLine splitedLine)
 {
     return(TableBorderCharacters.Vertical + splitedLine.Origin + string.Empty.PadRight(GetLineWidth() - Encoding.Default.GetByteCount(splitedLine.Origin), ' ') + TableBorderCharacters.Vertical);
 }