public class XSLFTableCell extends XSLFTextShape implements TableCell<XSLFShape,XSLFTextParagraph>
XSLFShape.ReparseFactory<T extends org.apache.xmlbeans.XmlObject>
TableCell.BorderEdge
TextShape.TextAutofit, TextShape.TextDirection, TextShape.TextPlaceholder
Modifier and Type | Method and Description |
---|---|
java.awt.geom.Rectangle2D |
getAnchor()
Returns the anchor (the bounding box rectangle) of this shape.
(返回此形状的锚点(边界框矩形)。)
|
StrokeStyle.LineCap |
getBorderCap(TableCell.BorderEdge edge) |
java.awt.Color |
getBorderColor(TableCell.BorderEdge edge) |
StrokeStyle.LineCompound |
getBorderCompound(TableCell.BorderEdge edge) |
StrokeStyle.LineDash |
getBorderDash(TableCell.BorderEdge edge) |
XDDFLineProperties |
getBorderProperties(TableCell.BorderEdge edge) |
StrokeStyle |
getBorderStyle(TableCell.BorderEdge edge)
Return line style of given edge or
null if border is not defined
(如果没有定义边框,则返回给定边缘的线条样式或 null)
|
java.lang.Double |
getBorderWidth(TableCell.BorderEdge edge) |
protected org.openxmlformats.schemas.drawingml.x2006.main.CTTableCellProperties |
getCellProperties(boolean create) |
java.awt.Color |
getFillColor()
Returns the solid color fill.
(返回纯色填充。)
|
PaintStyle |
getFillPaint() |
int |
getGridSpan()
Get the number of columns to be spanned/merged
(获取要跨越/合并的列数)
|
int |
getRowSpan()
Get the number of rows to be spanned/merged
(获取要跨越/合并的行数)
|
protected org.apache.xmlbeans.XmlObject |
getShapeProperties()
Return the shape specific (visual) properties
(返回特定于形状的(视觉)属性)
|
protected org.openxmlformats.schemas.drawingml.x2006.main.CTTextBody |
getTextBody(boolean create) |
TextShape.TextDirection |
getTextDirection() |
VerticalAlignment |
getVerticalAlignment()
Returns the type of vertical alignment for the text.
(返回文本的垂直对齐类型。)
|
protected org.openxmlformats.schemas.drawingml.x2006.main.CTTransform2D |
getXfrm()
Return a fake-xfrm which is used for calculating the text height
(返回一个用于计算文本高度的 fake-xfrm)
|
boolean |
isMerged()
Return if this cell is part of a merged cell.
(如果此单元格是合并单元格的一部分,则返回。)
|
protected org.apache.poi.xslf.usermodel.XSLFTableCell.XSLFCellTextParagraph |
newTextParagraph(org.openxmlformats.schemas.drawingml.x2006.main.CTTextParagraph p)
Helper method to allow subclasses to provide their own text paragraph
(允许子类提供自己的文本段落的辅助方法)
|
void |
removeBorder(TableCell.BorderEdge edge)
Remove all line attributes of the given border edge
(删除给定边框边缘的所有线条属性)
|
void |
setAnchor(java.awt.geom.Rectangle2D anchor)
There's no real anchor for table cells - this method is used to temporarily store the location of the cell for a later retrieval, e.g.
(表格单元格没有真正的锚点 - 此方法用于临时存储单元格的位置以供以后检索,例如)
|
void |
setBorderCap(TableCell.BorderEdge edge, StrokeStyle.LineCap cap) |
void |
setBorderColor(TableCell.BorderEdge edge, java.awt.Color color)
Convenience method for setting the border color.
(设置边框颜色的便捷方法。)
|
void |
setBorderCompound(TableCell.BorderEdge edge, StrokeStyle.LineCompound compound)
Convenience method for setting the border line compound.
(设置边界线复合的便捷方法。)
|
void |
setBorderDash(TableCell.BorderEdge edge, StrokeStyle.LineDash dash)
Convenience method for setting the border line dash.
(设置边界线破折号的便捷方法。)
|
void |
setBorderProperties(TableCell.BorderEdge edge, XDDFLineProperties properties) |
void |
setBorderStyle(TableCell.BorderEdge edge, StrokeStyle style)
Sets the
StrokeStyle of the given border edge.
(设置给定边框边缘的 StrokeStyle。)
|
void |
setBorderWidth(TableCell.BorderEdge edge, double width)
Convenience method for setting the border width.
(设置边框宽度的便捷方法。)
|
void |
setBottomInset(double margin)
Sets the bottom margin.
(设置下边距。)
|
void |
setFillColor(java.awt.Color color)
Specifies a solid color fill.
(指定纯色填充。)
|
void |
setLeftInset(double margin)
Sets the left margin.
(设置左边距。)
|
void |
setRightInset(double margin)
Sets the right margin.
(设置右边距。)
|
void |
setTextDirection(TextShape.TextDirection orientation)
sets the vertical orientation
(设置垂直方向)
|
void |
setTopInset(double margin)
Sets the top margin.
(设置上边距。)
|
void |
setVerticalAlignment(VerticalAlignment anchor)
Sets the type of vertical alignment for the text.
(设置文本的垂直对齐类型。)
|
addNewTextParagraph, appendText, clearText, findDefinedParagraphProperty, findDefinedRunProperty, getBottomInset, getInsets, getLeftInset, getRightInset, getText, getTextAutofit, getTextBody, getTextBodyPr, getTextBodyPr, getTextHeight, getTextHeight, getTextParagraphs, getTextPlaceholder, getTextRotation, getTextType, getTopInset, getWordWrap, isHorizontalCentered, iterator, resizeToFitText, resizeToFitText, setHorizontalCentered, setInsets, setPlaceholder, setText, setTextAutofit, setTextPlaceholder, setTextRotation, setWordWrap
createHyperlink, getAdjustValue, getFillStyle, getFlipHorizontal, getFlipVertical, getGeometry, getHyperlink, getLineCap, getLineColor, getLineCompound, getLineDash, getLineDecoration, getLineHeadDecoration, getLineHeadLength, getLineHeadWidth, getLinePaint, getLineTailDecoration, getLineTailLength, getLineTailWidth, getLineWidth, getRotation, getShadow, getShapeType, getStrokeStyle, getXfrm, setFlipHorizontal, setFlipVertical, setLineCap, setLineColor, setLineCompound, setLineDash, setLineHeadDecoration, setLineHeadLength, setLineHeadWidth, setLineTailDecoration, setLineTailLength, setLineTailWidth, setLineWidth, setRotation, setShapeType, setStrokeStyle
draw, fetchShapeProperty, getBgPr, getBgRef, getChild, getCNvPr, getGrpSpPr, getParent, getPlaceholder, getPlaceholderDetails, getShapeId, getShapeName, getSheet, getSpStyle, getXmlObject, isPlaceholder, selectPaint, selectPaint, selectPaint, selectPaint, selectPaint, selectPaint, selectProperty, setParent
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
appendText, getInsets, getText, getTextHeight, getTextHeight, getTextParagraphs, getTextPlaceholder, getTextRotation, getWordWrap, isHorizontalCentered, resizeToFitText, resizeToFitText, setHorizontalCentered, setInsets, setText, setTextPlaceholder, setTextRotation, setWordWrap
createHyperlink, getFillStyle, getGeometry, getHyperlink, getLineDecoration, getPlaceholder, getPlaceholderDetails, getShadow, getShapeType, getStrokeStyle, isPlaceholder, setPlaceholder, setShapeType, setStrokeStyle
draw, getParent, getShapeId, getShapeName, getSheet
getAdjustValue
getFlipHorizontal, getFlipVertical, getParent, getRotation, getSheet, setFlipHorizontal, setFlipVertical, setRotation
protected org.openxmlformats.schemas.drawingml.x2006.main.CTTextBody getTextBody(boolean create)
getTextBody
in class
XSLFTextShape
(XSLFTextShape 类中的 getTextBody)
protected org.openxmlformats.schemas.drawingml.x2006.main.CTTableCellProperties getCellProperties(boolean create)
public void setLeftInset(double margin)
XSLFTextShape
setLeftInset
in class
XSLFTextShape
margin
- the left margin
(margin - 左边距)
XSLFTextShape.getLeftInset()
public void setRightInset(double margin)
XSLFTextShape
setRightInset
in class
XSLFTextShape
margin
- the right margin
(margin - 右边距)
XSLFTextShape.getRightInset()
public void setTopInset(double margin)
XSLFTextShape
setTopInset
in class
XSLFTextShape
margin
- the top margin
(margin - 上边距)
XSLFTextShape.getTopInset()
public void setBottomInset(double margin)
XSLFTextShape
setBottomInset
in class
XSLFTextShape
margin
- the bottom margin
(margin - 下边距)
XSLFTextShape.getBottomInset()
public XDDFLineProperties getBorderProperties(TableCell.BorderEdge edge)
public void setBorderProperties(TableCell.BorderEdge edge, XDDFLineProperties properties)
public void removeBorder(TableCell.BorderEdge edge)
TableCell
removeBorder
in interface
TableCell<XSLFShape,XSLFTextParagraph>
(接口 TableCell 中的 removeBorder
edge
- the border edge to be cleared
(edge - 要清除的边界边缘)
public StrokeStyle getBorderStyle(TableCell.BorderEdge edge)
TableCell
null
if border is not defined
(如果没有定义边框,则返回给定边缘的线条样式或 null)
getBorderStyle
in interface
TableCell<XSLFShape,XSLFTextParagraph>
(接口 TableCell 中的 getBorderStyle
edge
- the border edge
(edge - 边界边缘)
null
if border is not defined
(给定边缘的线条样式,如果未定义边框,则为 null)
public void setBorderStyle(TableCell.BorderEdge edge, StrokeStyle style)
TableCell
StrokeStyle
of the given border edge. A
null
property of the style is ignored.
(设置给定边框边缘的 StrokeStyle。样式的 null 属性将被忽略。)
setBorderStyle
in interface
TableCell<XSLFShape,XSLFTextParagraph>
(接口 TableCell 中的 setBorderStyle
edge
- border edge
(边缘 - 边界边缘)
style
- the new stroke style
(风格 - 新的笔触风格)
public java.lang.Double getBorderWidth(TableCell.BorderEdge edge)
public void setBorderWidth(TableCell.BorderEdge edge, double width)
TableCell
setBorderWidth
in interface
TableCell<XSLFShape,XSLFTextParagraph>
(接口 TableCell 中的 setBorderWidth
edge
- border edge
(边缘 - 边界边缘)
width
- the new border width
(width - 新的边框宽度)
public void setBorderColor(TableCell.BorderEdge edge, java.awt.Color color)
TableCell
setBorderColor
in interface
TableCell<XSLFShape,XSLFTextParagraph>
(接口 TableCell 中的 setBorderColor
edge
- border edge
(边缘 - 边界边缘)
color
- the new border color
(color - 新的边框颜色)
public java.awt.Color getBorderColor(TableCell.BorderEdge edge)
public StrokeStyle.LineCompound getBorderCompound(TableCell.BorderEdge edge)
public void setBorderCompound(TableCell.BorderEdge edge, StrokeStyle.LineCompound compound)
TableCell
setBorderCompound
in interface
TableCell<XSLFShape,XSLFTextParagraph>
(接口 TableCell 中的 setBorderCompound
edge
- border edge
(边缘 - 边界边缘)
compound
- the new border line compound
(复合 - 新的边界线复合)
public StrokeStyle.LineDash getBorderDash(TableCell.BorderEdge edge)
public void setBorderDash(TableCell.BorderEdge edge, StrokeStyle.LineDash dash)
TableCell
setBorderDash
in interface
TableCell<XSLFShape,XSLFTextParagraph>
(接口 TableCell 中的 setBorderDash
edge
- border edge
(边缘 - 边界边缘)
dash
- the new border line dash
(破折号 - 新的边界线破折号)
public StrokeStyle.LineCap getBorderCap(TableCell.BorderEdge edge)
public void setBorderCap(TableCell.BorderEdge edge, StrokeStyle.LineCap cap)
public void setFillColor(java.awt.Color color)
setFillColor
in interface
SimpleShape<XSLFShape,XSLFTextParagraph>
(接口 SimpleShape 中的 setFillColor
setFillColor
in class
XSLFSimpleShape
color
- the solid color fill. The value of
null
unsets the solidFIll attribute from the underlying xml
(color - 纯色填充。 null 的值从底层 xml 中取消设置 solidFIll 属性)
public java.awt.Color getFillColor()
SimpleShape
getFillColor
in interface
SimpleShape<XSLFShape,XSLFTextParagraph>
(接口 SimpleShape 中的 getFillColor
getFillColor
in class
XSLFSimpleShape
public PaintStyle getFillPaint()
getFillPaint
in class
XSLFShape
public int getGridSpan()
TableCell
getGridSpan
in interface
TableCell<XSLFShape,XSLFTextParagraph>
(接口 TableCell 中的 getGridSpan
public int getRowSpan()
TableCell
getRowSpan
in interface
TableCell<XSLFShape,XSLFTextParagraph>
(接口 TableCell 中的 getRowSpan
public void setVerticalAlignment(VerticalAlignment anchor)
TextShape
setVerticalAlignment
in interface
TextShape<XSLFShape,XSLFTextParagraph>
(接口 TextShape 中的 setVerticalAlignment
setVerticalAlignment
in class
XSLFTextShape
anchor
- - the type of alignment. A
null
values unsets this property.
(anchor - - 对齐的类型。空值取消设置此属性。)
public VerticalAlignment getVerticalAlignment()
TextShape
getVerticalAlignment
in interface
TextShape<XSLFShape,XSLFTextParagraph>
(接口 TextShape 中的 getVerticalAlignment
getVerticalAlignment
in class
XSLFTextShape
public void setTextDirection(TextShape.TextDirection orientation)
TextShape
setTextDirection
in interface
TextShape<XSLFShape,XSLFTextParagraph>
(接口 TextShape 中的 setTextDirection
setTextDirection
in class
XSLFTextShape
orientation
- vertical orientation of the text
(方向 - 文本的垂直方向)
public TextShape.TextDirection getTextDirection()
getTextDirection
in interface
TextShape<XSLFShape,XSLFTextParagraph>
(接口 TextShape 中的 getTextDirection
getTextDirection
in class
XSLFTextShape
protected org.openxmlformats.schemas.drawingml.x2006.main.CTTransform2D getXfrm()
public void setAnchor(java.awt.geom.Rectangle2D anchor)
setAnchor
in interface
PlaceableShape<XSLFShape,XSLFTextParagraph>
(接口 PlaceableShape 中的 setAnchor
setAnchor
in class
XSLFSimpleShape
anchor
- the position of this shape within the drawing canvas. The coordinates are expressed in points
(anchor - 此形状在绘图画布中的位置。坐标以点表示)
public java.awt.geom.Rectangle2D getAnchor()
Shape
getAnchor
in interface
PlaceableShape<XSLFShape,XSLFTextParagraph>
(接口 PlaceableShape 中的 getAnchor
getAnchor
in interface
Shape<XSLFShape,XSLFTextParagraph>
(接口 Shape 中的 getAnchor
getAnchor
in class
XSLFSimpleShape
public boolean isMerged()
TableCell
isMerged
in interface
TableCell<XSLFShape,XSLFTextParagraph>
(isMerged 在接口 TableCell 中
protected org.apache.poi.xslf.usermodel.XSLFTableCell.XSLFCellTextParagraph newTextParagraph(org.openxmlformats.schemas.drawingml.x2006.main.CTTextParagraph p)
XSLFTextShape
newTextParagraph
in class
XSLFTextShape
p
- the xml reference
(p - xml 引用)
protected org.apache.xmlbeans.XmlObject getShapeProperties()
XSLFShape
getShapeProperties
in class
XSLFShape
Copyright 2021 The Apache Software Foundation or its licensors, as applicable.