Supporting logic to handle the use of the backslash character
This commit is contained in:
@@ -162,7 +162,7 @@ namespace Volian.Print.Library
|
||||
{
|
||||
if (NewPath[j] != "" && (foundMisMatch || OldPath.Length < j + 1 || NewPath[j] != OldPath[j]))
|
||||
{
|
||||
sb.Append(sep + "".PadLeft(2 * level) + NewPath[j].Replace("\x11", " ")).Replace(@"\u8209?", "-");
|
||||
sb.Append(sep + "".PadLeft(2 * level) + NewPath[j].Replace("\x11", " ")).Replace(@"\u8209?", "-").Replace(@"\u9586?",@"\");
|
||||
sep = "\r\n";
|
||||
foundMisMatch = true;
|
||||
}
|
||||
@@ -211,7 +211,7 @@ namespace Volian.Print.Library
|
||||
{
|
||||
if (NewPath[j] != "" && (foundMisMatch || OldPath.Length < j + 1 || NewPath[j] != OldPath[j]))
|
||||
{
|
||||
sb.Append(sep + "".PadLeft(2 * level) + NewPath[j].Replace("\x11", " ")).Replace(@"\u8209?", "-");
|
||||
sb.Append(sep + "".PadLeft(2 * level) + NewPath[j].Replace("\x11", " ")).Replace(@"\u8209?", "-").Replace(@"\u9586?", @"\");
|
||||
sep = "\r\n";
|
||||
foundMisMatch = true;
|
||||
}
|
||||
@@ -240,6 +240,7 @@ namespace Volian.Print.Library
|
||||
{
|
||||
headerText = headerText.Replace(@"\u8209?", "-");// repace unicode with dash char
|
||||
headerText = headerText.Replace(@"\u160?", " "); // replace Hard Space with normal Space
|
||||
headerText = headerText.Replace(@"\u9586?", @"\"); // replace backslash symbol with a backslash
|
||||
PdfPCell cell = new PdfPCell(new Phrase(headerText, f2));
|
||||
cell.Colspan = 2;
|
||||
cell.BackgroundColor = bgColor;
|
||||
@@ -313,7 +314,7 @@ namespace Volian.Print.Library
|
||||
int n = NewPath.Length;
|
||||
for (int j = 1; j < n && j < splitLevel; j++)
|
||||
{
|
||||
sb.Append(sep + "".PadLeft(2 * level) + NewPath[j].Replace("\x11", " ")).Replace(@"\u8209?", "-");
|
||||
sb.Append(sep + "".PadLeft(2 * level) + NewPath[j].Replace("\x11", " ")).Replace(@"\u8209?", "-").Replace(@"\u9586?", @"\");
|
||||
sep = "\r\n";
|
||||
level++;
|
||||
}
|
||||
@@ -346,7 +347,7 @@ namespace Volian.Print.Library
|
||||
{
|
||||
for (int j = splitLevel; j < n; j++)
|
||||
{
|
||||
sb.Append(sep + "".PadLeft(2 * level) + NewPath[j].Replace("\x11", " ")).Replace(@"\u8209?", "-");
|
||||
sb.Append(sep + "".PadLeft(2 * level) + NewPath[j].Replace("\x11", " ")).Replace(@"\u8209?", "-").Replace(@"\u9586?", @"\");
|
||||
sep = "\r\n";
|
||||
level++;
|
||||
}
|
||||
@@ -696,6 +697,7 @@ namespace Volian.Print.Library
|
||||
string ProcNumber = item.MyProcedure.ProcedureConfig.Number;
|
||||
ProcNumber = ProcNumber.Replace(@"\u8209?", "-"); // repace unicode with dash char
|
||||
ProcNumber = ProcNumber.Replace(@"\u160?", " "); // replace Hard Space with normal Space
|
||||
ProcNumber = ProcNumber.Replace(@"\u9586?", @"\"); // replace backslash symbol with a backslash
|
||||
AddCell(subtable, ProcNumber, f2, TextBackgroundColor);
|
||||
AddCell(subtable, item.DisplayNumber + " - " + item.DisplayText, f2, TextBackgroundColor);
|
||||
}
|
||||
@@ -1068,6 +1070,7 @@ namespace Volian.Print.Library
|
||||
procNumTitleSect += " " + GetCurSectionNumTitle(itm);
|
||||
procNumTitleSect = procNumTitleSect.Replace(@"\u8209?", "-"); // repace unicode with dash char
|
||||
procNumTitleSect = procNumTitleSect.Replace(@"\u160?", " "); // replace Hard Space with normal Space
|
||||
procNumTitleSect = procNumTitleSect.Replace(@"\u9586?", @"\"); // replace backslash symbol with a backslash
|
||||
PdfPCell ProcTitleCell = new PdfPCell(new Phrase(procNumTitleSect, f2));
|
||||
ProcTitleCell.Colspan = 2;
|
||||
ProcTitleCell.HorizontalAlignment = Element.ALIGN_LEFT;
|
||||
|
Reference in New Issue
Block a user