This commit is contained in:
Kathy Ruffing 2010-08-10 11:04:42 +00:00
parent 9e4bceb9b3
commit 38dbd7a31a
2 changed files with 60 additions and 2 deletions

View File

@ -11,9 +11,27 @@ using VEPROMS.CSLA.Library;
namespace Volian.Print.Library
{
public class VlnSvgPageHelper:SvgPageHelper
{
// This handles Page Breaks within a Step
private List<vlnParagraph> _ParaBreaks = new List<vlnParagraph>();
public List<vlnParagraph> ParaBreaks
{
get { return _ParaBreaks; }
set { _ParaBreaks = value; }
}
private VlnDestinations _VlnDestinations = new VlnDestinations();
public VlnDestinations VlnDestinations
{
get { return _VlnDestinations; }
set { _VlnDestinations = value; }
}
private PdfOutline _MyPdfOutline = null;
public PdfOutline MyPdfOutline
{
get { return _MyPdfOutline; }
set { _MyPdfOutline = value; }
}
private vlnText _TopMessage;
public vlnText TopMessage
{
@ -72,9 +90,17 @@ namespace Volian.Print.Library
if (MySectionTitle != null)
{
PdfDestination dest = new PdfDestination(PdfDestination.FIT);
PdfOutline outline = new PdfOutline(writer.DirectContent.RootOutline, dest, MySectionTitle, false);
MyPdfOutline = new PdfOutline(writer.DirectContent.RootOutline, dest, MySectionTitle, false);
MySectionTitle = null;
}
if (VlnDestinations.Count > 0 && MyPdfOutline != null)
{
foreach (VlnDestination vd in VlnDestinations)
{
new PdfOutline(MyPdfOutline, vd.PdfDestination, vd.Title, false);
}
VlnDestinations.Clear();
}
}
private void DrawMessages(PdfContentByte cb)
{
@ -539,6 +565,36 @@ namespace Volian.Print.Library
return "";
}
}
public class VlnDestinations : List<VlnDestination>
{
public VlnDestinations() : base()
{
}
public void Add(string title, PdfDestination pdfDestination)
{
Add(new VlnDestination(title, pdfDestination));
}
}
public class VlnDestination
{
private string _Title;
public string Title
{
get { return _Title; }
set { _Title = value; }
}
private PdfDestination _PdfDestination;
public PdfDestination PdfDestination
{
get { return _PdfDestination; }
set { _PdfDestination = value; }
}
public VlnDestination(string title, PdfDestination pdfDestination)
{
_Title = title;
_PdfDestination = pdfDestination;
}
}
public class ChangeBarDefinition // anything that is section level should go in here.
{
private PrintChangeBar _MyChangeBarType;

View File

@ -294,6 +294,8 @@ namespace Volian.Print.Library
cb.EndLayer();
cb.RestoreState();
}
public virtual float YBottom
{ get { return YOffset + Height;} }
}
public partial class vlnPrintObjects : List<vlnPrintObject>
{