Exemplo n.º 1
0
 /**
 * Creates dictionary referring to a target document that is the parent of the current document.
 * @param nested    null if this is the actual target, another target if this is only an intermediate target.
 */
 public PdfTargetDictionary(PdfTargetDictionary nested)
     : base()
 {
     Put(PdfName.R, PdfName.P);
     if (nested != null)
         AdditionalPath = nested;
 }
Exemplo n.º 2
0
 /**
  * Creates dictionary referring to a target document that is the parent of the current document.
  * @param nested    null if this is the actual target, another target if this is only an intermediate target.
  */
 public PdfTargetDictionary(PdfTargetDictionary nested) : base()
 {
     Put(PdfName.R, PdfName.P);
     if (nested != null)
     {
         AdditionalPath = nested;
     }
 }
Exemplo n.º 3
0
 /**
 * Creates a GoToE action to an embedded file.
 * @param filename   the root document of the target (null if the target is in the same document)
 * @param target a path to the target document of this action
 * @param dest       the destination inside the target document, can be of type PdfDestination, PdfName, or PdfString
 * @param newWindow  if true, the destination document should be opened in a new window
 * @return a GoToE action
 */
 public static PdfAction GotoEmbedded(String filename, PdfTargetDictionary target, PdfObject dest, bool newWindow)
 {
     PdfAction action = new PdfAction();
     action.Put(PdfName.S, PdfName.GOTOE);
     action.Put(PdfName.T, target);
     action.Put(PdfName.D, dest);
     action.Put(PdfName.NEWWINDOW, new PdfBoolean(newWindow));
     if (filename != null) {
         action.Put(PdfName.F, new PdfString(filename));
     }
     return action;
 }
Exemplo n.º 4
0
 /**
 * Creates a GoToE action to an embedded file.
 * @param filename   the root document of the target (null if the target is in the same document)
 * @param dest the named destination
 * @param isName if true sets the destination as a name, if false sets it as a String
 * @return a GoToE action
 */
 public static PdfAction GotoEmbedded(String filename, PdfTargetDictionary target, String dest, bool isName, bool newWindow)
 {
     if (isName)
         return GotoEmbedded(filename, target, new PdfName(dest), newWindow);
     else
         return GotoEmbedded(filename, target, new PdfString(dest, null), newWindow);
 }