public class FormArea extends javax.swing.JComponent implements ScrollRulerComponent
限定符和类型 | 字段和说明 |
---|---|
static double |
DEFAULT_SLIDER |
accessibleContext, listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW
构造器和说明 |
---|
FormArea(FormDesigner designer) |
FormArea(FormDesigner designer,
boolean useScrollBar) |
限定符和类型 | 方法和说明 |
---|---|
void |
addFormRuler()
增加刻度条
|
java.awt.Point |
calculateScroll(int oldmax,
int max,
int newValue,
int oldValue,
int visi,
int orientation)
计算滚动条的值和max
|
void |
doLayout()
容器布局
|
java.awt.Dimension |
getAreaSize()
返回界面区域大小
|
int |
getDesignerHeight()
返回当前designer的高度
|
int |
getDesignerWidth()
返回当前designer的宽度
|
FormDesigner |
getFormEditor()
返回表单容器的中心designer
getFormEditor.
|
double |
getHeightPaneValue()
返回高度控件的value
|
int |
getHorizontalValue()
返回水平滚动条的value
|
FormScrollBar |
getHorScrollBar() |
int |
getMinHeight()
返回designer的最小高度
|
int |
getMinWidth()
返回designer的最小宽度
|
short |
getRulerLengthUnit()
getRulerLengthUnit
|
double |
getScreenValue()
返回当前的屏幕分辨率对应的百分比值
|
double |
getSlideValue()
返回界面大小的百分比值
|
int |
getVerticalValue()
返回竖直滚动条的value
|
double |
getWidthPaneValue()
返回宽度控件的value
|
void |
onMobileAttrModified() |
protected void |
processMouseWheelEvent(java.awt.event.MouseWheelEvent evt)
鼠标滚轮事件
由于表单设计界面要求: 容器大小大于界面时,滚动条才可以拖动,所以不支持滚动无限往下滚
|
void |
scrollPathToVisible(XCreator creator)
设置界面内的组件可见以及水平垂直滚动条的值
(除了根容器,拖入组件进来时如果大小超过当前界面大小,必须设置滚动条值,否则滚动条默认不显示)
|
void |
setAreaSize(java.awt.Dimension totalSize,
int horizontalValue,
int verticalValue,
double width,
double height,
double slide)
setAreaSize
|
void |
setHeightPaneValue(int value)
设置高度值
|
void |
setHorizontalValue(int newValue)
设置水平滚动条的value
|
void |
setHorScrollBar(FormScrollBar horScrollBar) |
void |
setScreenValue(double screenValue)
设置屏幕分辨率对应的百分比值
|
void |
setVerticalValue(int newValue)
竖直滚动条赋值
|
void |
setWidthPaneValue(int value)
设置宽度值
|
addAncestorListener, addNotify, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, getAccessibleContext, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBaseline, getBaselineResizeBehavior, getBorder, getBounds, getClientProperty, getComponentGraphics, getComponentPopupMenu, getConditionForKeyStroke, getDebugGraphicsOptions, getDefaultLocale, getFontMetrics, getGraphics, getHeight, getInheritsPopupMenu, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getMaximumSize, getMinimumSize, getNextFocusableComponent, getPopupLocation, getPreferredSize, getRegisteredKeyStrokes, getRootPane, getSize, getToolTipLocation, getToolTipText, getToolTipText, getTopLevelAncestor, getTransferHandler, getUIClassID, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, hide, isDoubleBuffered, isLightweightComponent, isManagingFocus, isOpaque, isOptimizedDrawingEnabled, isPaintingForPrint, isPaintingOrigin, isPaintingTile, isRequestFocusEnabled, isValidateRoot, paint, paintBorder, paintChildren, paintComponent, paintImmediately, paintImmediately, paramString, print, printAll, printBorder, printChildren, printComponent, processComponentKeyEvent, processKeyBinding, processKeyEvent, processMouseEvent, processMouseMotionEvent, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeNotify, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resetKeyboardActions, reshape, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setComponentPopupMenu, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setEnabled, setFocusTraversalKeys, setFont, setForeground, setInheritsPopupMenu, setInputMap, setInputVerifier, setMaximumSize, setMinimumSize, setNextFocusableComponent, setOpaque, setPreferredSize, setRequestFocusEnabled, setToolTipText, setTransferHandler, setUI, setVerifyInputWhenFocusTarget, setVisible, unregisterKeyboardAction, update, updateUI
add, add, add, add, add, addContainerListener, addImpl, addPropertyChangeListener, addPropertyChangeListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getLayout, getMousePosition, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, printComponents, processContainerEvent, processEvent, remove, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusCycleRoot, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setLayout, transferFocusDownCycle, validate, validateTree
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, createImage, createImage, createVolatileImage, createVolatileImage, disableEvents, dispatchEvent, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getForeground, getGraphicsConfiguration, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocale, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, hasFocus, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isPreferredSizeSet, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, resize, resize, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setName, setSize, setSize, show, show, size, toString, transferFocus, transferFocusBackward, transferFocusUpCycle
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
repaint
public static final double DEFAULT_SLIDER
public FormArea(FormDesigner designer)
public FormArea(FormDesigner designer, boolean useScrollBar)
public FormScrollBar getHorScrollBar()
public void setHorScrollBar(FormScrollBar horScrollBar)
public void onMobileAttrModified()
public double getScreenValue()
public void setScreenValue(double screenValue)
screenValue
- 百分比值public void addFormRuler()
protected void processMouseWheelEvent(java.awt.event.MouseWheelEvent evt)
processMouseWheelEvent
在类中 java.awt.Component
public FormDesigner getFormEditor()
public void scrollPathToVisible(XCreator creator)
creator
- 控件public void doLayout()
doLayout
在类中 java.awt.Container
public int getMinHeight()
getMinHeight
在接口中 ScrollRulerComponent
public int getMinWidth()
getMinWidth
在接口中 ScrollRulerComponent
public short getRulerLengthUnit()
getRulerLengthUnit
在接口中 ScrollRulerComponent
public int getHorizontalValue()
getHorizontalValue
在接口中 ScrollRulerComponent
public void setHorizontalValue(int newValue)
setHorizontalValue
在接口中 ScrollRulerComponent
newValue
- public int getVerticalValue()
getVerticalValue
在接口中 ScrollRulerComponent
public void setVerticalValue(int newValue)
setVerticalValue
在接口中 ScrollRulerComponent
newValue
- public int getDesignerHeight()
getDesignerHeight
在接口中 ScrollRulerComponent
public int getDesignerWidth()
getDesignerWidth
在接口中 ScrollRulerComponent
public double getWidthPaneValue()
public void setWidthPaneValue(int value)
value
- 值public void setHeightPaneValue(int value)
value
- 值public double getHeightPaneValue()
public double getSlideValue()
public java.awt.Dimension getAreaSize()
public void setAreaSize(java.awt.Dimension totalSize, int horizontalValue, int verticalValue, double width, double height, double slide)
totalSize
- horizontalValue
- verticalValue
- public java.awt.Point calculateScroll(int oldmax, int max, int newValue, int oldValue, int visi, int orientation)
calculateScroll
在接口中 ScrollRulerComponent
oldmax
- 之前最大值max
- 当前最大值newValue
- 当前valueoldValue
- 之前valuevisi
- designer的大小orientation
- 滚动条方向