Fixed a bug with printing long procedure titles where there wasn’t enough space between the split title lines.

This commit is contained in:
John Jenko 2012-01-09 17:52:27 +00:00
parent 6ec0ce999c
commit bdd27f4487

View File

@ -753,7 +753,7 @@ namespace Volian.Print.Library
//private void SplitTitle(SvgGroup svgGroup, VEPROMS.CSLA.Library.PageItem pageItem, string title, int? len, string match)
{
if (match == "{PROCTITLE2}") return plstr;
if (len == 0 || ItemInfo.StripRtfFormatting(title).Length < len)
if (len == null || len == 0 || ItemInfo.StripRtfFormatting(title).Length < len)
{
if (match == "{PROCTITLE2}") return plstr; // this would have been done in proctitle1
plstr = plstr.Replace(match, title);
@ -771,7 +771,7 @@ namespace Volian.Print.Library
foreach (string line in titleLines)
{
cnt++;
if (cnt == 1)
if (cnt == 1 && adj == 0) // adj == 0 means we use PROCTITLE1/PROCTITLE2 pagelist tokens
plstr = plstr.Replace(match, line);
else
svgGroup.Add(PageItemToSvgText(pageItem, line, yOffset));