- java.lang.Object
-
- javax.swing.text.View
-
- javax.swing.text.CompositeView
-
- javax.swing.text.BoxView
-
- javax.swing.text.html.BlockView
-
- javax.swing.text.html.ListView
-
- 实现的所有接口
-
SwingConstants
public class ListViewextends BlockView
用于显示html列表的视图实现
-
-
字段汇总
-
声明的属性在类 javax.swing.text.View
BadBreakWeight, ExcellentBreakWeight, ForcedBreakWeight, GoodBreakWeight, X_AXIS, Y_AXIS
-
Fields declared in interface javax.swing.SwingConstants
BOTTOM, CENTER, EAST, HORIZONTAL, LEADING, LEFT, NEXT, NORTH, NORTH_EAST, NORTH_WEST, PREVIOUS, RIGHT, SOUTH, SOUTH_EAST, SOUTH_WEST, TOP, TRAILING, VERTICAL, WEST
-
-
方法摘要
所有方法 实例方法 具体的方法 变量和类型 方法 描述 float
getAlignment(int axis)
计算列表的所需形状。void
paint(Graphics g, Shape allocation)
使用给定的渲染表面和该表面上的区域进行渲染。protected void
paintChild(Graphics g, Rectangle alloc, int index)
给一个孩子画画; 由paint()调用。-
声明方法的类 javax.swing.text.html.BlockView
calculateMajorAxisRequirements, calculateMinorAxisRequirements, getAttributes, getMaximumSpan, getMinimumSpan, getPreferredSpan, getResizeWeight, getStyleSheet, layoutMinorAxis, setParent, setPropertiesFromAttributes
-
声明方法的类 javax.swing.text.BoxView
baselineLayout, baselineRequirements, childAllocation, flipEastAndWestAtEnds, forwardUpdate, getAxis, getChildAllocation, getHeight, getOffset, getSpan, getViewAtPoint, getWidth, isAfter, isAllocationValid, isBefore, isLayoutValid, layout, layoutChanged, layoutMajorAxis, modelToView, preferenceChanged, replace, setAxis, setSize, viewToModel
-
声明方法的类 javax.swing.text.CompositeView
getBottomInset, getInsideAllocation, getLeftInset, getNextEastWestVisualPositionFrom, getNextNorthSouthVisualPositionFrom, getNextVisualPositionFrom, getRightInset, getTopInset, getView, getViewAtPosition, getViewCount, getViewIndex, getViewIndexAtPosition, loadChildren, modelToView, setInsets, setParagraphInsets
-
声明方法的类 javax.swing.text.View
append, breakView, changedUpdate, createFragment, forwardUpdateToView, getBreakWeight, getContainer, getDocument, getElement, getEndOffset, getGraphics, getParent, getStartOffset, getToolTipText, getViewFactory, getViewIndex, insert, insertUpdate, isVisible, modelToView, remove, removeAll, removeUpdate, updateChildren, updateLayout, viewToModel
-
-
-
-
构造方法详细信息
-
ListView
public ListView(Element elem)
创建表示列表元素的新视图。- 参数
-
elem
- 为其创建视图的元素
-
-
方法详细信息
-
getAlignment
public float getAlignment(int axis)
计算列表的所需形状。- 重写:
-
getAlignment
在类BlockView
- 参数
-
axis
- 可以是X_AXIS或Y_AXIS - 结果
- 期望的跨度
- 另请参见:
-
View.getPreferredSpan(int)
-
paint
public void paint(Graphics g, Shape allocation)
使用给定的渲染表面和该表面上的区域进行渲染。- 重写:
-
paint
在类BlockView
- 参数
-
g
- 要使用的渲染表面 -
allocation
- 要分配的区域 - 另请参见:
-
View.paint(java.awt.Graphics, java.awt.Shape)
-
paintChild
protected void paintChild(Graphics g, Rectangle alloc, int index)
给一个孩子画画; 由paint()调用。 默认情况下就是这样,但是子类可以使用它来绘制相对于子项的内容。- 重写:
-
paintChild
在类BoxView
- 参数
-
g
- 图形上下文 -
alloc
- 用于将子项呈现的已分配区域 -
index
- 儿童的索引
-
-