internal string GetDestStr(TPdfDestination Dest) { int PageId = PageTree.GetPageId(Dest.PageNumber); string PageStr = TIndirectRecord.GetCallObj(PageId); switch (Dest.ZoomOptions) { case TZoomOptions.Fit: return (TPdfTokens.GetString(TPdfToken.OpenArray) + PageStr + TPdfTokens.GetString(TPdfToken.FitName) + TPdfTokens.GetString(TPdfToken.CloseArray)); case TZoomOptions.FitH: return (TPdfTokens.GetString(TPdfToken.OpenArray) + PageStr + TPdfTokens.GetString(TPdfToken.FitHName) + TPdfTokens.GetString(TPdfToken.CloseArray)); case TZoomOptions.FitV: return (TPdfTokens.GetString(TPdfToken.OpenArray) + PageStr + TPdfTokens.GetString(TPdfToken.FitVName) + TPdfTokens.GetString(TPdfToken.CloseArray)); } return (TPdfTokens.GetString(TPdfToken.OpenArray) + PageStr + TPdfTokens.GetString(TPdfToken.XYZName) + TPdfTokens.GetString(TPdfToken.CloseArray)); }
/// <summary> /// Creates a new TBookmark instance. /// </summary> /// <param name="aTitle">Title of the bookmark item.</param> /// <param name="aDestination">Page where the bookmark points to.</param> /// <param name="aChildrenCollapsed">If true all children from this bookmark will be collapsed.</param> public TBookmark(string aTitle, TPdfDestination aDestination, bool aChildrenCollapsed) { FTitle = aTitle; FDestination = aDestination; FChildrenCollapsed = aChildrenCollapsed; FTextColor = ColorUtil.FromArgb(0, 0, 0); FTextStyle = TBookmarkStyle.None; FChildren = new TBookmarkList(); }
/// <summary> /// Creates a new TBookmark instance. /// </summary> /// <param name="aTitle">Title of the bookmark item.</param> /// <param name="aDestination">Page where the bookmark points to.</param> /// <param name="aChildrenCollapsed">If true all children from this bookmark will be collapsed.</param> /// <param name="aTextColor">Text color for the bookmark entry.</param> /// <param name="aTextStyle">Text style for the bookmark entry.</param> public TBookmark(string aTitle, TPdfDestination aDestination, bool aChildrenCollapsed, Color aTextColor, TBookmarkStyle aTextStyle) : this(aTitle, aDestination, aChildrenCollapsed) { FTextColor = aTextColor; FTextStyle = aTextStyle; }