Spec-Zone.ru › OpenJDK 8

Класс BasicInternalFrameTitlePane

  • java.lang.Object
    • java.awt.Component
      • java.awt.Container
        • javax.swing.JComponent
          • javax.swing.plaf.basic.BasicInternalFrameTitlePane
Все реализуемые интерфейсы:
ImageObserver, MenuContainer, Serializable
Непосредственные известные подклассы:
MetalInternalFrameTitlePane

public class BasicInternalFrameTitlePane
extends JComponent

Класс, управляющий стандартной строкой заголовка

Предупреждение: Сериализованные объекты этого класса не будут совместимы с будущими выпусками Swing. Текущая поддержка сериализации подходит для кратковременного хранения или RMI между приложениями, использующими одну и ту же версию Swing. Начиная с версии 1.4, добавлена поддержка долговременного хранения всех JavaBeans™ в пакете java.beans. См. XMLEncoder.

Вложенные классы

Модификатор и тип Класс и описание
class  BasicInternalFrameTitlePane.CloseAction

Этот класс следует рассматривать как "защищённый" внутренний класс.

class  BasicInternalFrameTitlePane.IconifyAction

Этот класс следует рассматривать как "защищённый" внутренний класс.

class  BasicInternalFrameTitlePane.MaximizeAction

Этот класс следует рассматривать как "защищённый" внутренний класс.

class  BasicInternalFrameTitlePane.MoveAction

Этот класс следует рассматривать как "защищённый" внутренний класс.

class  BasicInternalFrameTitlePane.PropertyChangeHandler

Этот класс следует рассматривать как "защищённый" внутренний класс.

class  BasicInternalFrameTitlePane.RestoreAction

Этот класс следует рассматривать как "защищённый" внутренний класс.

class  BasicInternalFrameTitlePane.SizeAction

Этот класс следует рассматривать как "защищённый" внутренний класс.

class  BasicInternalFrameTitlePane.SystemMenuBar

Этот класс следует рассматривать как "защищённый" внутренний класс.

class  BasicInternalFrameTitlePane.TitlePaneLayout

Этот класс следует рассматривать как "защищённый" внутренний класс.

Вложенные классы/интерфейсы, унаследованные от класса javax.swing.JComponent

JComponent.AccessibleJComponent

Вложенные классы/интерфейсы, унаследованные от класса java.awt.Container

Container.AccessibleAWTContainer

Вложенные классы/интерфейсы, унаследованные от класса java.awt.Component

Component.AccessibleAWTComponent, Component.BaselineResizeBehavior, Component.BltBufferStrategy, Component.FlipBufferStrategy

Поля

Модификатор и тип Поле и описание
protected static String CLOSE_CMD
protected Action closeAction
protected JButton closeButton
protected Icon closeIcon
protected JInternalFrame frame
protected JButton iconButton
protected Icon iconIcon
protected static String ICONIFY_CMD
protected Action iconifyAction
protected JButton maxButton
protected Icon maxIcon
protected static String MAXIMIZE_CMD
protected Action maximizeAction
protected JMenuBar menuBar
protected Icon minIcon
protected static String MOVE_CMD
protected Action moveAction
protected Color notSelectedTextColor
protected Color notSelectedTitleColor
protected PropertyChangeListener propertyChangeListener
protected static String RESTORE_CMD
protected Action restoreAction
protected Color selectedTextColor
protected Color selectedTitleColor
protected static String SIZE_CMD
protected Action sizeAction
protected JMenu windowMenu

Поля, унаследованные от класса javax.swing.JComponent

listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW

Поля, унаследованные от класса java.awt.Component

accessibleContext, BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT

Поля, унаследованные от интерфейса java.awt.image.ImageObserver

ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH

Конструкторы

Конструктор и описание
BasicInternalFrameTitlePane(JInternalFrame f)

Методы

Модификатор и тип Метод и описание
protected void addSubComponents()
protected void addSystemMenuItems(JMenu systemMenu)
protected void assembleSystemMenu()
protected void createActions()
protected void createButtons()
protected LayoutManager createLayout()
protected PropertyChangeListener createPropertyChangeListener()
protected JMenu createSystemMenu()
protected JMenuBar createSystemMenuBar()
protected void enableActions()
protected String getTitle(String text, FontMetrics fm, int availTextWidth)
protected void installDefaults()
protected void installListeners()
protected void installTitlePane()
void paintComponent(Graphics g)

Вызывает метод отрисовки делегата UI, если делегат UI не null.

protected void paintTitleBackground(Graphics g)

Вызывается из paintComponent.

protected void postClosingEvent(JInternalFrame frame)

Отправляет событие типа WINDOW_CLOSING фрейму, чтобы он мог обрабатывать его как обычный фрейм.

protected void setButtonIcons()
protected void showSystemMenu()
protected void uninstallDefaults()
protected void uninstallListeners()

Методы, унаследованные от класса javax.swing.JComponent

addAncestorListener, addNotify, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, 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, 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

Методы, унаследованные от класса java.awt.Container

add, add, add, add, add, addContainerListener, addImpl, addPropertyChangeListener, addPropertyChangeListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, 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

Методы, унаследованные от класса java.awt.Component

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, getAccessibleContext, 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, processMouseWheelEvent, 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

Методы, унаследованные от класса java.lang.Object

clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait

Поля

menuBar

protected JMenuBar menuBar

кнопка_иконки

protected JButton iconButton

кнопка_максимизации

protected JButton maxButton

кнопка_закрытия

protected JButton closeButton

меню_окна

protected JMenu windowMenu

рамка

protected JInternalFrame frame

цвет_выбранного_заголовка

protected Color selectedTitleColor

цвет_выбранного_текста

protected Color selectedTextColor

цвет_невыбранного_заголовка

protected Color notSelectedTitleColor

цвет_невыбранного_текста

protected Color notSelectedTextColor

иконка_максимизации

protected Icon maxIcon

иконка_минимизации

protected Icon minIcon

иконка_иконки

protected Icon iconIcon

иконка_закрытия

protected Icon closeIcon

слушатель_свойств

protected PropertyChangeListener propertyChangeListener

действие_закрытия

protected Action closeAction

действие_максимизации

protected Action maximizeAction

действие_минимизации

protected Action iconifyAction

действие_восстановления

protected Action restoreAction

действие_перемещения

protected Action moveAction

действие_изменения_размера

protected Action sizeAction

CLOSE_CMD

protected static final String CLOSE_CMD

ICONIFY_CMD

protected static final String ICONIFY_CMD

RESTORE_CMD

protected static final String RESTORE_CMD

MAXIMIZE_CMD

protected static final String MAXIMIZE_CMD

MOVE_CMD

protected static final String MOVE_CMD

SIZE_CMD

protected static final String SIZE_CMD

Конструкторы

BasicInternalFrameTitlePane

public BasicInternalFrameTitlePane(JInternalFrame f)

Методы

установить_панель_заголовка

protected void installTitlePane()

добавить_подкомпоненты

protected void addSubComponents()

создать_действия

protected void createActions()

установить_слушатели

protected void installListeners()

удалить_слушателей

protected void uninstallListeners()

установить_дефолты

protected void installDefaults()

удалить_дефолты

protected void uninstallDefaults()

создать_кнопки

protected void createButtons()

установить_иконки_кнопок

protected void setButtonIcons()

сборка_системный_меню

protected void assembleSystemMenu()

добавить_пункты_системного_меню

protected void addSystemMenuItems(JMenu systemMenu)

создать_системный_меню

protected JMenu createSystemMenu()

создать_системную_панель_меню

protected JMenuBar createSystemMenuBar()

отобразить_системный_меню

protected void showSystemMenu()

paintComponent

public void paintComponent(Graphics g)

Описание скопировано из класса: JComponent

Вызывает метод отрисовки делегата пользовательского интерфейса, если делегат пользовательского интерфейса не null. Мы передаем делегату копию объекта Graphics для защиты остальной части кода отрисовки от необратимых изменений (например, Graphics.translate).

Если вы переопределяете это в подклассе, вы не должны вносить постоянные изменения в переданный Graphics. Например, вы не должны изменять буфер вывода Rectangle или изменять преобразование. Если вам нужно выполнить эти операции, вам может быть легче создать новый Graphics из переданного Graphics и манипулировать им. Кроме того, если вы не вызываете реализацию суперкласса, вы должны соблюдать свойство opaque, то есть, если этот компонент непрозрачный, вы должны полностью заполнить фон нецветным цветом. Если вы не соблюдаете свойство opaque, вы, вероятно, увидите визуальные артефакты.

Переданный Graphics объект может иметь преобразование, отличное от идентичного преобразования, установленного на нем. В этом случае вы можете получить неожиданные результаты, если вы кумулируете другое преобразование.

Переопределяет:
paintComponent в классе JComponent
Параметры:
g - объект Graphics для защиты
См. также:
JComponent.paint(java.awt.Graphics), ComponentUI

отрисовка_фона_заголовка

protected void paintTitleBackground(Graphics g)

Вызывается из paintComponent. Отрисовывает фон titlepane. Весь текст и значки затем будут отрисованы поверх этого фона.

Параметры:
g - графика для отрисовки фона
С тех пор:
1.4

получить_заголовок

protected String getTitle(String text,
                          FontMetrics fm,
                          int availTextWidth)

событие_закрытия

protected void postClosingEvent(JInternalFrame frame)

Отправьте событие типа WINDOW_CLOSING в рамку, чтобы оно обрабатывалось как обычная рамка.

включить_действия

protected void enableActions()

создать_слушателя_свойств

protected PropertyChangeListener createPropertyChangeListener()

создать_макет

protected LayoutManager createLayout()

© 1993, 2020, Oracle and/or its affiliates. All rights reserved.
Documentation extracted from Debian's OpenJDK Development Kit package.
Licensed under the GNU General Public License, version 2, with the Classpath Exception.
Various third party code in OpenJDK is licensed under different licenses (see Debian package).
Java and OpenJDK are trademarks or registered trademarks of Oracle and/or its affiliates.

Spec-Zone.ru

Настройки Оффлайн Что нового Помощь О нас
Spec-Zone .ru
спецификации, руководства, описания, API