Examples of DrawControlElement


Examples of org.odftoolkit.odfdom.dom.element.draw.DrawControlElement

   *
   * @param drawControlValue  the <code>String</code> value of <code>DrawControlAttribute</code>, see {@odf.attribute  draw:control} at specification
   * @return the element {@odf.element draw:control}
   */
   public DrawControlElement newDrawControlElement(String drawControlValue) {
    DrawControlElement drawControl = ((OdfFileDom) this.ownerDocument).newOdfElement(DrawControlElement.class);
    drawControl.setDrawControlAttribute(drawControlValue);
    this.appendChild(drawControl);
    return drawControl;
  }
View Full Code Here

Examples of org.odftoolkit.odfdom.dom.element.draw.DrawControlElement

   *
   * @param drawControlValue  the <code>String</code> value of <code>DrawControlAttribute</code>, see {@odf.attribute  draw:control} at specification
   * @return the element {@odf.element draw:control}
   */
   public DrawControlElement newDrawControlElement(String drawControlValue) {
    DrawControlElement drawControl = ((OdfFileDom) this.ownerDocument).newOdfElement(DrawControlElement.class);
    drawControl.setDrawControlAttribute(drawControlValue);
    this.appendChild(drawControl);
    return drawControl;
  }
View Full Code Here

Examples of org.odftoolkit.odfdom.dom.element.draw.DrawControlElement

   *
   * @param drawControlValue  the <code>String</code> value of <code>DrawControlAttribute</code>, see {@odf.attribute  draw:control} at specification
   * @return the element {@odf.element draw:control}
   */
   public DrawControlElement newDrawControlElement(String drawControlValue) {
    DrawControlElement drawControl = ((OdfFileDom) this.ownerDocument).newOdfElement(DrawControlElement.class);
    drawControl.setDrawControlAttribute(drawControlValue);
    this.appendChild(drawControl);
    return drawControl;
  }
View Full Code Here

Examples of org.odftoolkit.odfdom.dom.element.draw.DrawControlElement

   *
   * @param drawControlValue  the <code>String</code> value of <code>DrawControlAttribute</code>, see {@odf.attribute  draw:control} at specification
   * @return the element {@odf.element draw:control}
   */
   public DrawControlElement newDrawControlElement(String drawControlValue) {
    DrawControlElement drawControl = ((OdfFileDom) this.ownerDocument).newOdfElement(DrawControlElement.class);
    drawControl.setDrawControlAttribute(drawControlValue);
    this.appendChild(drawControl);
    return drawControl;
  }
View Full Code Here

Examples of org.odftoolkit.odfdom.dom.element.draw.DrawControlElement

   *
   * @param drawControlValue  the <code>String</code> value of <code>DrawControlAttribute</code>, see {@odf.attribute  draw:control} at specification
   * @return the element {@odf.element draw:control}
   */
   public DrawControlElement newDrawControlElement(String drawControlValue) {
    DrawControlElement drawControl = ((OdfFileDom) this.ownerDocument).newOdfElement(DrawControlElement.class);
    drawControl.setDrawControlAttribute(drawControlValue);
    this.appendChild(drawControl);
    return drawControl;
  }
View Full Code Here

Examples of org.odftoolkit.odfdom.dom.element.draw.DrawControlElement

   *
   * @param drawControlValue  the <code>String</code> value of <code>DrawControlAttribute</code>, see {@odf.attribute  draw:control} at specification
   * @return the element {@odf.element draw:control}
   */
   public DrawControlElement newDrawControlElement(String drawControlValue) {
    DrawControlElement drawControl = ((OdfFileDom) this.ownerDocument).newOdfElement(DrawControlElement.class);
    drawControl.setDrawControlAttribute(drawControlValue);
    this.appendChild(drawControl);
    return drawControl;
  }
View Full Code Here

Examples of org.odftoolkit.odfdom.dom.element.draw.DrawControlElement

   *
   * @param drawControlValue  the <code>String</code> value of <code>DrawControlAttribute</code>, see {@odf.attribute  draw:control} at specification
   * @return the element {@odf.element draw:control}
   */
   public DrawControlElement newDrawControlElement(String drawControlValue) {
    DrawControlElement drawControl = ((OdfFileDom) this.ownerDocument).newOdfElement(DrawControlElement.class);
    drawControl.setDrawControlAttribute(drawControlValue);
    this.appendChild(drawControl);
    return drawControl;
  }
View Full Code Here

Examples of org.odftoolkit.odfdom.dom.element.draw.DrawControlElement

   * @return a control instance
   */
  public static Control newDrawControl(ControlContainer container) {
    OdfElement parent = container.getDrawControlContainerElement();
    OdfFileDom ownerDom = (OdfFileDom) parent.getOwnerDocument();
    DrawControlElement element = ownerDom
        .newOdfElement(DrawControlElement.class);
    parent.appendChild(element);
    Control control = new Control(element);
    Component.registerComponent(control, element);
    return control;
View Full Code Here

Examples of org.odftoolkit.odfdom.dom.element.draw.DrawControlElement

            Document.OdfMediaType.TEXT_TEMPLATE
                .getMediaTypeString()))
      return;
    GraphicProperties graphicPropertiesForWrite = getGraphicPropertiesForWrite();

    DrawControlElement controlElement = (DrawControlElement) mOdfElement;
    controlElement.setTextAnchorTypeAttribute(achorType.toString());

    // set default relative
    switch (achorType) {
    case AS_CHARACTER:
      graphicPropertiesForWrite
          .setVerticalRelative(VerticalRelative.BASELINE);
      graphicPropertiesForWrite
          .setVerticalPosition(FrameVerticalPosition.TOP);
      break;
    case TO_CHARACTER:
      graphicPropertiesForWrite
          .setVerticalRelative(VerticalRelative.PARAGRAPH);
      graphicPropertiesForWrite
          .setVerticalPosition(FrameVerticalPosition.TOP);
      graphicPropertiesForWrite
          .setHorizontalRelative(HorizontalRelative.PARAGRAPH);
      graphicPropertiesForWrite
          .setHorizontalPosition(FrameHorizontalPosition.CENTER);
      break;
    case TO_PAGE:
      controlElement.setTextAnchorPageNumberAttribute(Integer.valueOf(1));
      graphicPropertiesForWrite
          .setVerticalRelative(VerticalRelative.PAGE);
      graphicPropertiesForWrite
          .setVerticalPosition(FrameVerticalPosition.FROMTOP);
      graphicPropertiesForWrite
View Full Code Here

Examples of org.odftoolkit.odfdom.dom.element.draw.DrawControlElement

   */
  public void formatTime(String formatStr, Locale locale) {
    if (drawingShape == null)
      throw new IllegalStateException(
          "Please call loadDrawControl() first.");
    DrawControlElement element = drawingShape.getOdfElement();
    String name = getUniqueTimeStyleName();
    OdfNumberTimeStyle timeStyle = new OdfNumberTimeStyle(
        (OdfFileDom) element.getOwnerDocument(), formatStr, name);
    timeStyle.setNumberLanguageAttribute(locale.getLanguage());
    timeStyle.setNumberCountryAttribute(locale.getCountry());
    element.getAutomaticStyles().appendChild(timeStyle);
    OdfStyleBase styleElement = drawingShape.getStyleHandler()
        .getStyleElementForWrite();
    if (styleElement != null) {
      styleElement.setOdfAttributeValue(OdfName.newName(
          OdfDocumentNamespace.STYLE, "data-style-name"), name);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.