Package com.lowagie.text.pdf

Examples of com.lowagie.text.pdf.PdfString


           case Annotation.NAMED_DEST:
               return new PdfAnnotation(writer, annot.llx(), annot.lly(), annot.urx(), annot.ury(), new PdfAction(((Integer) annot.attributes().get(Annotation.NAMED)).intValue()));
           case Annotation.LAUNCH:
               return new PdfAnnotation(writer, annot.llx(), annot.lly(), annot.urx(), annot.ury(), new PdfAction((String) annot.attributes().get(Annotation.APPLICATION),(String) annot.attributes().get(Annotation.PARAMETERS),(String) annot.attributes().get(Annotation.OPERATION),(String) annot.attributes().get(Annotation.DEFAULTDIR)));
           default:
             return new PdfAnnotation(writer, defaultRect.getLeft(), defaultRect.getBottom(), defaultRect.getRight(), defaultRect.getTop(), new PdfString(annot.title(), PdfObject.TEXT_UNICODE), new PdfString(annot.content(), PdfObject.TEXT_UNICODE));
       }
   }
View Full Code Here


   
    public void completeInfoDictionary(PdfDictionary info) {
        if (isPdfX() && !isPdfA1()) {
            if (info.get(PdfName.GTS_PDFXVERSION) == null) {
                if (isPdfX1A2001()) {
                    info.put(PdfName.GTS_PDFXVERSION, new PdfString("PDF/X-1:2001"));
                    info.put(new PdfName("GTS_PDFXConformance"), new PdfString("PDF/X-1a:2001"));
                }
                else if (isPdfX32002())
                    info.put(PdfName.GTS_PDFXVERSION, new PdfString("PDF/X-3:2002"));
            }
            if (info.get(PdfName.TITLE) == null) {
                info.put(PdfName.TITLE, new PdfString("Pdf document"));
            }
            if (info.get(PdfName.CREATOR) == null) {
                info.put(PdfName.CREATOR, new PdfString("Unknown"));
            }
            if (info.get(PdfName.TRAPPED) == null) {
                info.put(PdfName.TRAPPED, new PdfName("False"));
            }
        }
View Full Code Here

   
    public void completeExtraCatalog(PdfDictionary extraCatalog) {
        if (isPdfX() && !isPdfA1()) {
            if (extraCatalog.get(PdfName.OUTPUTINTENTS) == null) {
                PdfDictionary out = new PdfDictionary(PdfName.OUTPUTINTENT);
                out.put(PdfName.OUTPUTCONDITION, new PdfString("SWOP CGATS TR 001-1995"));
                out.put(PdfName.OUTPUTCONDITIONIDENTIFIER, new PdfString("CGATS TR 001"));
                out.put(PdfName.REGISTRYNAME, new PdfString("http://www.color.org"));
                out.put(PdfName.INFO, new PdfString(""));
                out.put(PdfName.S, PdfName.GTS_PDFX);
                extraCatalog.put(PdfName.OUTPUTINTENTS, new PdfArray(out));
            }
        }
    }
View Full Code Here

                    colorspace.add(new PdfNumber(len / 3 - 1));
                    ByteBuffer colortable = new ByteBuffer();
                    while ((len--) > 0) {
                        colortable.append_i(is.read());
                    }
                    colorspace.add(new PdfString(colorTable = colortable.toByteArray()));
                    additional.put(PdfName.COLORSPACE, colorspace);
                }
                else {
                    Utilities.skip(is, len);
                }
View Full Code Here

     */
    private static class MoveNextLineAndShowTextWithSpacing implements ContentOperator{
        public void invoke(PdfContentStreamProcessor processor, PdfLiteral operator, ArrayList operands) {
            PdfNumber aw = (PdfNumber)operands.get(0);
            PdfNumber ac = (PdfNumber)operands.get(1);
            PdfString string = (PdfString)operands.get(2);
           
            ArrayList twOperands = new ArrayList(1);
            twOperands.add(0, aw);
            processor.invokeOperator(new PdfLiteral("Tw"), twOperands);

View Full Code Here

    /**
     * A content operator implementation (Tj).
     */
    private static class ShowText implements ContentOperator{
        public void invoke(PdfContentStreamProcessor processor, PdfLiteral operator, ArrayList operands) {
            PdfString string = (PdfString)operands.get(0);
           
            processor.displayPdfString(string, 0);
        }
View Full Code Here

    final PdfAction action = new PdfAction();
    if (target.startsWith("#"))
    {
      // its a local link ..
      action.put(PdfName.S, PdfName.GOTO);
      action.put(PdfName.D, new PdfString(target.substring(1)));
    }
    else
    {
      action.put(PdfName.S, PdfName.URI);
      action.put(PdfName.URI, new PdfString(target));
    }
    return action;
  }
View Full Code Here

      final int x = (int) (translateX + StrictGeomUtility.toExternalValue(content.getX()));
      final int y = (int) StrictGeomUtility.toExternalValue(content.getY());
      final float[] translatedCoords = translateCoordinates(imageMapEntry.getAreaCoordinates(), x, y);

      final PolygonAnnotation polygonAnnotation = new PolygonAnnotation(writer, translatedCoords);
      polygonAnnotation.put(PdfName.CONTENTS, new PdfString(tooltip, PdfObject.TEXT_UNICODE));
      writer.addAnnotation(polygonAnnotation);
    }
  }
View Full Code Here

      instance.put(new PdfName("Subtype"), new PdfName("Flash"));
      PdfDictionary params = new PdfDictionary();
     
      String chartData = (String) element.getParameterValue(PARAMETER_CHART_DATA);
      String vars = "inline_data=" + chartData;
      params.put(new PdfName("FlashVars"), new PdfString(vars));
      instance.put(new PdfName("Params"), params);
      instance.put(new PdfName("Asset"), swfRef.getIndirectReference());
      PdfIndirectObject instanceRef = writer.addToBody(instance);
      instances.add(instanceRef.getIndirectReference());
      configuration.put(new PdfName("Instances"), instances);
View Full Code Here

            JRPdfExporterParameter.TAG_LANGUAGE,
            JRPdfExporterParameter.PROPERTY_TAG_LANGUAGE
            );
      if (language != null)
      {
        allTag.put(PdfName.LANG, new PdfString(language));
      }
      tagStack = new Stack();
      tagStack.push(allTag);
    }
  }
View Full Code Here

TOP

Related Classes of com.lowagie.text.pdf.PdfString

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.