This commit is contained in:
2012-11-06 12:00:38 +00:00
parent 06461d264e
commit a9ab86f6ae
2 changed files with 21 additions and 6 deletions

View File

@@ -1509,7 +1509,19 @@ namespace Volian.Print.Library
cbMess = itemInfo.MyContent.UserID + @"\n" + fmtDate;
}
else if (myPageHelper.ChangeBarDefinition.MyChangeBarText == PrintChangeBarText.RevNum)
cbMess = myPageHelper.Rev;
{
string lRev = myPageHelper.Rev;
// Now check the format flags to determine if/how the Rev string should be parsed.
if ((itemInfo.ActiveFormat.PlantFormat.FormatData.PrintData.DoRevDate && lRev.Contains("/"))
|| (itemInfo.ActiveFormat.PlantFormat.FormatData.PrintData.RevDateWithForwardSlash && lRev.Contains("\\")))
{
int indx = lRev.IndexOf(itemInfo.ActiveFormat.PlantFormat.FormatData.PrintData.DoRevDate ? '/' : '\\');
cbMess = lRev.Substring(0, indx>-1?indx:lRev.Length);
}
else
cbMess = lRev;
}
else if (myPageHelper.ChangeBarDefinition.MyChangeBarText == PrintChangeBarText.UserDef)
cbMess = myPageHelper.ChangeBarDefinition.MyChangeBarMessage;
@@ -1519,7 +1531,7 @@ namespace Volian.Print.Library
!itemInfo.IsInRNO)) msgAlign = Element.ALIGN_RIGHT;
float coltotwips = col * itemInfo.FormatStepData.Font.CharsToTwips;
if (itemInfo.IsFigure) coltotwips = col * itemInfo.ActiveFormat.PlantFormat.FormatData.Font.CharsToTwips;
return new vlnChangeBar(cb, this, (float)itemInfo.MyDocStyle.Layout.LeftMargin + coltotwips, yoff, msgAlign);
return new vlnChangeBar(cb, this, (float)itemInfo.MyDocStyle.Layout.LeftMargin + coltotwips, yoff, msgAlign, myPageHelper.ChangeBarDefinition.MyChangeBarText == PrintChangeBarText.RevNum);
}
private int ChangeBarLocation(float c, vlnParagraph paragraph, FormatInfo formatInfo, int maxRNO)