aboutsummaryrefslogtreecommitdiffstats
path: root/src/ooxml/java/org/apache/poi/xslf
diff options
context:
space:
mode:
authorAndreas Beeker <kiwiwings@apache.org>2015-07-09 22:46:29 +0000
committerAndreas Beeker <kiwiwings@apache.org>2015-07-09 22:46:29 +0000
commit1102414559fdfe86cb3af5a11a94490aa928f704 (patch)
treecd163d00cd822feab1a1e21b3d18ddb2d7356782 /src/ooxml/java/org/apache/poi/xslf
parent3cab0825131d36705c058c2e011c9918c8addfdf (diff)
downloadpoi-1102414559fdfe86cb3af5a11a94490aa928f704.tar.gz
poi-1102414559fdfe86cb3af5a11a94490aa928f704.zip
added ASL header to drawing classes
fixed a few rendering NPEs added dummy interfaces for table / connector shapes git-svn-id: https://svn.apache.org/repos/asf/poi/branches/common_sl@1690185 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'src/ooxml/java/org/apache/poi/xslf')
-rw-r--r--src/ooxml/java/org/apache/poi/xslf/usermodel/XSLFConnectorShape.java4
-rw-r--r--src/ooxml/java/org/apache/poi/xslf/usermodel/XSLFSimpleShape.java2
-rw-r--r--src/ooxml/java/org/apache/poi/xslf/usermodel/XSLFTable.java3
3 files changed, 6 insertions, 3 deletions
diff --git a/src/ooxml/java/org/apache/poi/xslf/usermodel/XSLFConnectorShape.java b/src/ooxml/java/org/apache/poi/xslf/usermodel/XSLFConnectorShape.java
index 8cc1c92745..b894cd080d 100644
--- a/src/ooxml/java/org/apache/poi/xslf/usermodel/XSLFConnectorShape.java
+++ b/src/ooxml/java/org/apache/poi/xslf/usermodel/XSLFConnectorShape.java
@@ -19,6 +19,7 @@
package org.apache.poi.xslf.usermodel;
+import org.apache.poi.sl.usermodel.ConnectorShape;
import org.apache.poi.util.Beta;
import org.openxmlformats.schemas.drawingml.x2006.main.CTLineProperties;
import org.openxmlformats.schemas.drawingml.x2006.main.CTNonVisualDrawingProps;
@@ -34,7 +35,7 @@ import org.openxmlformats.schemas.presentationml.x2006.main.CTConnectorNonVisual
* @author Yegor Kozlov
*/
@Beta
-public class XSLFConnectorShape extends XSLFSimpleShape {
+public class XSLFConnectorShape extends XSLFSimpleShape implements ConnectorShape {
/*package*/ XSLFConnectorShape(CTConnector shape, XSLFSheet sheet) {
super(shape, sheet);
@@ -43,6 +44,7 @@ public class XSLFConnectorShape extends XSLFSimpleShape {
/**
* @param shapeId 1-based shapeId
*/
+ @SuppressWarnings("unused")
static CTConnector prototype(int shapeId) {
CTConnector ct = CTConnector.Factory.newInstance();
CTConnectorNonVisual nvSpPr = ct.addNewNvCxnSpPr();
diff --git a/src/ooxml/java/org/apache/poi/xslf/usermodel/XSLFSimpleShape.java b/src/ooxml/java/org/apache/poi/xslf/usermodel/XSLFSimpleShape.java
index fb97180605..ee374602e1 100644
--- a/src/ooxml/java/org/apache/poi/xslf/usermodel/XSLFSimpleShape.java
+++ b/src/ooxml/java/org/apache/poi/xslf/usermodel/XSLFSimpleShape.java
@@ -77,7 +77,7 @@ public abstract class XSLFSimpleShape extends XSLFShape implements SimpleShape {
protected CTTransform2D getXfrm() {
PropertyFetcher<CTTransform2D> fetcher = new PropertyFetcher<CTTransform2D>() {
public boolean fetch(XSLFShape shape) {
- CTShapeProperties pr = getSpPr();
+ CTShapeProperties pr = shape.getSpPr();
if (pr.isSetXfrm()) {
setValue(pr.getXfrm());
return true;
diff --git a/src/ooxml/java/org/apache/poi/xslf/usermodel/XSLFTable.java b/src/ooxml/java/org/apache/poi/xslf/usermodel/XSLFTable.java
index a6ec8bcfe7..9f2bb49032 100644
--- a/src/ooxml/java/org/apache/poi/xslf/usermodel/XSLFTable.java
+++ b/src/ooxml/java/org/apache/poi/xslf/usermodel/XSLFTable.java
@@ -27,6 +27,7 @@ import java.util.List;
import javax.xml.namespace.QName;
import org.apache.poi.POIXMLException;
+import org.apache.poi.sl.usermodel.TableShape;
import org.apache.poi.util.Internal;
import org.apache.poi.util.Units;
import org.apache.xmlbeans.XmlCursor;
@@ -45,7 +46,7 @@ import org.openxmlformats.schemas.presentationml.x2006.main.CTGraphicalObjectFra
*
* @author Yegor Kozlov
*/
-public class XSLFTable extends XSLFGraphicFrame implements Iterable<XSLFTableRow> {
+public class XSLFTable extends XSLFGraphicFrame implements Iterable<XSLFTableRow>, TableShape {
static String TABLE_URI = "http://schemas.openxmlformats.org/drawingml/2006/table";
private CTTable _table;