亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? basictextui.java

?? JAVA的一些源碼 JAVA2 STANDARD EDITION DEVELOPMENT KIT 5.0
?? JAVA
?? 第 1 頁 / 共 5 頁
字號:
/* * @(#)BasicTextUI.java	1.106 05/06/03 * * Copyright 2005 Sun Microsystems, Inc. All rights reserved. * SUN PROPRIETARY/CONFIDENTIAL. Use is subject to license terms. */package javax.swing.plaf.basic;import java.util.*;import java.awt.*;import java.awt.event.*;import java.awt.font.*;import java.awt.datatransfer.*;import java.awt.dnd.*;import java.awt.im.InputContext;import java.beans.*;import java.io.*;import java.net.*;import javax.swing.*;import javax.swing.plaf.*;import javax.swing.text.*;import javax.swing.event.*;import javax.swing.border.Border;import javax.swing.plaf.UIResource;import sun.swing.DefaultLookup;import sun.awt.AppContext;import javax.swing.plaf.basic.DragRecognitionSupport.BeforeDrag;/** * <p> * Basis of a text components look-and-feel.  This provides the * basic editor view and controller services that may be useful * when creating a look-and-feel for an extension of * <code>JTextComponent</code>. * <p> * Most state is held in the associated <code>JTextComponent</code> * as bound properties, and the UI installs default values for the  * various properties.  This default will install something for * all of the properties.  Typically, a LAF implementation will * do more however.  At a minimum, a LAF would generally install * key bindings. * <p> * This class also provides some concurrency support if the  * <code>Document</code> associated with the JTextComponent is a subclass of * <code>AbstractDocument</code>.  Access to the View (or View hierarchy) is * serialized between any thread mutating the model and the Swing * event thread (which is expected to render, do model/view coordinate * translation, etc).  <em>Any access to the root view should first * acquire a read-lock on the AbstractDocument and release that lock * in a finally block.</em> * <p> * An important method to define is the {@link #getPropertyPrefix} method * which is used as the basis of the keys used to fetch defaults * from the UIManager.  The string should reflect the type of  * TextUI (eg. TextField, TextArea, etc) without the particular  * LAF part of the name (eg Metal, Motif, etc). * <p> * To build a view of the model, one of the following strategies  * can be employed. * <ol> * <li> * One strategy is to simply redefine the  * ViewFactory interface in the UI.  By default, this UI itself acts * as the factory for View implementations.  This is useful * for simple factories.  To do this reimplement the  * {@link #create} method. * <li> * A common strategy for creating more complex types of documents * is to have the EditorKit implementation return a factory.  Since * the EditorKit ties all of the pieces necessary to maintain a type * of document, the factory is typically an important part of that * and should be produced by the EditorKit implementation. * <li> * A less common way to create more complex types is to have * the UI implementation create a. * separate object for the factory.  To do this, the  * {@link #createViewFactory} method should be reimplemented to  * return some factory. * </ol> * <p> * <strong>Warning:</strong> * Serialized objects of this class will not be compatible with * future Swing releases. The current serialization support is * appropriate for short term storage or RMI between applications running * the same version of Swing.  As of 1.4, support for long term storage * of all JavaBeans<sup><font size="-2">TM</font></sup> * has been added to the <code>java.beans</code> package. * Please see {@link java.beans.XMLEncoder}. * * @author Timothy Prinzing * @author Shannon Hickey (drag recognition) * @version 1.106 06/03/05 */public abstract class BasicTextUI extends TextUI implements ViewFactory {    /**     * Creates a new UI.     */    public BasicTextUI() {        painted = false;    }    /**     * Creates the object to use for a caret.  By default an     * instance of BasicCaret is created.  This method     * can be redefined to provide something else that implements     * the InputPosition interface or a subclass of JCaret.     *     * @return the caret object     */    protected Caret createCaret() {        return new BasicCaret();    }    /**     * Creates the object to use for adding highlights.  By default     * an instance of BasicHighlighter is created.  This method     * can be redefined to provide something else that implements     * the Highlighter interface or a subclass of DefaultHighlighter.     *     * @return the highlighter     */    protected Highlighter createHighlighter() {        return new BasicHighlighter();    }    /**     * Fetches the name of the keymap that will be installed/used      * by default for this UI. This is implemented to create a     * name based upon the classname.  The name is the the name     * of the class with the package prefix removed.     *     * @return the name     */    protected String getKeymapName() {	String nm = getClass().getName();	int index = nm.lastIndexOf('.');	if (index >= 0) {	    nm = nm.substring(index+1, nm.length());	}	return nm;    }    /**     * Creates the keymap to use for the text component, and installs     * any necessary bindings into it.  By default, the keymap is     * shared between all instances of this type of TextUI. The     * keymap has the name defined by the getKeymapName method.  If the     * keymap is not found, then DEFAULT_KEYMAP from JTextComponent is used.     * <p>     * The set of bindings used to create the keymap is fetched      * from the UIManager using a key formed by combining the     * {@link #getPropertyPrefix} method     * and the string <code>.keyBindings</code>.  The type is expected     * to be <code>JTextComponent.KeyBinding[]</code>.     *     * @return the keymap     * @see #getKeymapName     * @see javax.swing.text.JTextComponent     */    protected Keymap createKeymap() {	String nm = getKeymapName();	Keymap map = JTextComponent.getKeymap(nm);	if (map == null) {	    Keymap parent = JTextComponent.getKeymap(JTextComponent.DEFAULT_KEYMAP);	    map = JTextComponent.addKeymap(nm, parent);	    String prefix = getPropertyPrefix();	    Object o = DefaultLookup.get(editor, this,                prefix + ".keyBindings");	    if ((o != null) && (o instanceof JTextComponent.KeyBinding[])) {		JTextComponent.KeyBinding[] bindings = (JTextComponent.KeyBinding[]) o;		JTextComponent.loadKeymap(map, bindings, getComponent().getActions());	    }	}	return map;    }    /**     * This method gets called when a bound property is changed     * on the associated JTextComponent.  This is a hook     * which UI implementations may change to reflect how the     * UI displays bound properties of JTextComponent subclasses.     * This is implemented to do nothing (i.e. the response to     * properties in JTextComponent itself are handled prior     * to calling this method).     *     * @param evt the property change event     */    protected void propertyChange(PropertyChangeEvent evt) {    }    /**     * Gets the name used as a key to look up properties through the     * UIManager.  This is used as a prefix to all the standard     * text properties.     *     * @return the name     */    protected abstract String getPropertyPrefix();    /**     * Initializes component properties, e.g. font, foreground,      * background, caret color, selection color, selected text color,     * disabled text color, and border color.  The font, foreground, and     * background properties are only set if their current value is either null     * or a UIResource, other properties are set if the current     * value is null.     *      * @see #uninstallDefaults     * @see #installUI     */    protected void installDefaults()     {        String prefix = getPropertyPrefix();        Font f = editor.getFont();        if ((f == null) || (f instanceof UIResource)) {            editor.setFont(UIManager.getFont(prefix + ".font"));        }        Color bg = editor.getBackground();        if ((bg == null) || (bg instanceof UIResource)) {            editor.setBackground(UIManager.getColor(prefix + ".background"));        }                Color fg = editor.getForeground();        if ((fg == null) || (fg instanceof UIResource)) {            editor.setForeground(UIManager.getColor(prefix + ".foreground"));        }        Color color = editor.getCaretColor();        if ((color == null) || (color instanceof UIResource)) {            editor.setCaretColor(UIManager.getColor(prefix + ".caretForeground"));        }        Color s = editor.getSelectionColor();        if ((s == null) || (s instanceof UIResource)) {            editor.setSelectionColor(UIManager.getColor(prefix + ".selectionBackground"));        }        Color sfg = editor.getSelectedTextColor();        if ((sfg == null) || (sfg instanceof UIResource)) {            editor.setSelectedTextColor(UIManager.getColor(prefix + ".selectionForeground"));        }        Color dfg = editor.getDisabledTextColor();        if ((dfg == null) || (dfg instanceof UIResource)) {            editor.setDisabledTextColor(UIManager.getColor(prefix + ".inactiveForeground"));        }        Border b = editor.getBorder();        if ((b == null) || (b instanceof UIResource)) {            editor.setBorder(UIManager.getBorder(prefix + ".border"));        }        Insets margin = editor.getMargin();        if (margin == null || margin instanceof UIResource) {            editor.setMargin(UIManager.getInsets(prefix + ".margin"));        }    }    private void installDefaults2() {        editor.addMouseListener(dragListener);        editor.addMouseMotionListener(dragListener);	        String prefix = getPropertyPrefix();        Caret caret = editor.getCaret();        if (caret == null || caret instanceof UIResource) {            caret = createCaret();            editor.setCaret(caret);                    int rate = DefaultLookup.getInt(getComponent(), this, prefix + ".caretBlinkRate", 500);            caret.setBlinkRate(rate);        }        Highlighter highlighter = editor.getHighlighter();        if (highlighter == null || highlighter instanceof UIResource) {            editor.setHighlighter(createHighlighter());        }	TransferHandler th = editor.getTransferHandler();	if (th == null || th instanceof UIResource) {	    editor.setTransferHandler(getTransferHandler());	}	DropTarget dropTarget = editor.getDropTarget();	if (dropTarget instanceof UIResource) {            if (defaultDropTargetListener == null) {                defaultDropTargetListener = new TextDropTargetListener();            }	    try {		dropTarget.addDropTargetListener(defaultDropTargetListener);	    } catch (TooManyListenersException tmle) {		// should not happen... swing drop target is multicast	    }	}    }    /**     * Sets the component properties that haven't been explicitly overridden to      * null.  A property is considered overridden if its current value     * is not a UIResource.     *      * @see #installDefaults     * @see #uninstallUI     */    protected void uninstallDefaults()     {        editor.removeMouseListener(dragListener);        editor.removeMouseMotionListener(dragListener);        if (editor.getCaretColor() instanceof UIResource) {            editor.setCaretColor(null);        }                                                                                                 if (editor.getSelectionColor() instanceof UIResource) {            editor.setSelectionColor(null);        }        if (editor.getDisabledTextColor() instanceof UIResource) {            editor.setDisabledTextColor(null);        }        if (editor.getSelectedTextColor() instanceof UIResource) {            editor.setSelectedTextColor(null);        }        if (editor.getBorder() instanceof UIResource) {            editor.setBorder(null);        }        if (editor.getMargin() instanceof UIResource) {            editor.setMargin(null);        }        if (editor.getCaret() instanceof UIResource) {            editor.setCaret(null);        }        if (editor.getHighlighter() instanceof UIResource) {            editor.setHighlighter(null);        }	if (editor.getTransferHandler() instanceof UIResource) {	    editor.setTransferHandler(null);	}    }    /**     * Installs listeners for the UI.     */    protected void installListeners() {    }    /**     * Uninstalls listeners for the UI.     */    protected void uninstallListeners() {    }    protected void installKeyboardActions() {	// backward compatibility support... keymaps for the UI	// are now installed in the more friendly input map.        editor.setKeymap(createKeymap());         InputMap km = getInputMap();	if (km != null) {	    SwingUtilities.replaceUIInputMap(editor, JComponent.WHEN_FOCUSED,					     km);	}		ActionMap map = getActionMap();	if (map != null) {	    SwingUtilities.replaceUIActionMap(editor, map);	}	updateFocusAcceleratorBinding(false);    }    /**     * Get the InputMap to use for the UI.       */

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
色综合久久久久| 成人激情电影免费在线观看| 1000精品久久久久久久久| 精品国产欧美一区二区| 欧美一区二区三区视频免费播放 | 美女一区二区三区在线观看| 亚洲一区二区三区中文字幕| 一区二区在线观看免费视频播放| 亚洲欧美国产三级| 依依成人精品视频| 亚洲一区二区欧美| 五月综合激情网| 美女视频黄 久久| 精品一区二区三区日韩| 国产在线精品一区二区| 国产盗摄女厕一区二区三区| a美女胸又www黄视频久久| 国产精品一区二区你懂的| 东方欧美亚洲色图在线| av午夜一区麻豆| 欧美丝袜丝交足nylons| 欧美丰满美乳xxx高潮www| 日韩一区二区免费在线电影| 久久亚洲一区二区三区四区| 中文字幕一区在线| 亚洲第一主播视频| 日韩精品色哟哟| 国产寡妇亲子伦一区二区| 成年人网站91| 欧美在线不卡视频| 精品国产区一区| 亚洲人成在线观看一区二区| 午夜国产精品影院在线观看| 国产一区在线不卡| 色呦呦日韩精品| 精品剧情v国产在线观看在线| 国产精品理伦片| 日本欧美加勒比视频| 国产一区二区在线电影| 91在线无精精品入口| 欧美一区二视频| 专区另类欧美日韩| 久久国产福利国产秒拍| 一本色道久久综合狠狠躁的推荐| 91精品国产色综合久久ai换脸| 日本一区二区成人在线| 亚洲第一综合色| jvid福利写真一区二区三区| 91精品蜜臀在线一区尤物| 国产精品理论片在线观看| 另类欧美日韩国产在线| 在线观看亚洲精品| 中文字幕高清一区| 久久成人精品无人区| 在线观看区一区二| 国产精品久久久久久久久图文区| 久久精品久久综合| 欧美伊人久久大香线蕉综合69| 国产亚洲成av人在线观看导航 | 亚洲成a人片综合在线| 国产aⅴ精品一区二区三区色成熟| 欧美人与z0zoxxxx视频| 国产精品国产自产拍高清av| 日韩1区2区3区| 欧美体内she精高潮| 国产精品久久久久久久第一福利| 麻豆免费看一区二区三区| 欧美日韩亚洲综合| 依依成人精品视频| 日本高清不卡一区| 亚洲日韩欧美一区二区在线| 成人精品一区二区三区四区| 亚洲精品一区在线观看| 蜜乳av一区二区三区| 欧美一区二区三区婷婷月色| 日韩av一区二区三区四区| 欧美色偷偷大香| 午夜精品一区二区三区电影天堂 | 国产sm精品调教视频网站| 欧美一区二区三区四区五区| 日韩高清不卡一区| 56国语精品自产拍在线观看| 午夜久久久影院| 欧美一区二区在线视频| 日韩精品电影一区亚洲| 日韩午夜精品电影| 美女看a上一区| 欧美精品一区二区不卡| 国产美女在线观看一区| 国产欧美一区二区三区网站| 成人国产免费视频| 又紧又大又爽精品一区二区| 欧美视频一区在线观看| 午夜精品一区二区三区三上悠亚 | 久久99九九99精品| 久久久天堂av| 99综合电影在线视频| 亚洲蜜桃精久久久久久久| 欧美性猛交xxxxxx富婆| 日韩av在线播放中文字幕| 精品国产一区二区亚洲人成毛片 | 亚洲综合成人在线| 337p亚洲精品色噜噜| 久久9热精品视频| 国产精品无遮挡| 欧美唯美清纯偷拍| 美女高潮久久久| 国产午夜精品一区二区| 色悠悠久久综合| 麻豆一区二区三| 国产精品电影一区二区三区| 欧美日韩免费高清一区色橹橹| 极品少妇xxxx偷拍精品少妇| 国产精品久久久久7777按摩| 欧美日韩电影一区| 国产电影一区在线| 一区二区三区日韩| 久久久久久久久久久黄色| 色综合久久久久网| 国产精品影视在线| 亚洲18影院在线观看| 国产欧美日韩麻豆91| 欧美老人xxxx18| 成人福利在线看| 九色综合国产一区二区三区| 一区二区三区欧美日| 国产婷婷色一区二区三区| 欧美日韩三级一区| 成人激情免费视频| 激情成人综合网| 亚洲成人av电影| 综合久久久久久久| 久久久久国色av免费看影院| 欧美精品日日鲁夜夜添| 99热这里都是精品| 国产一区二区精品在线观看| 午夜激情久久久| 一区二区免费在线播放| 国产日韩欧美在线一区| 欧美一卡二卡三卡四卡| 欧美日韩一区在线| 色狠狠桃花综合| 91在线高清观看| 福利一区福利二区| 国产美女精品在线| 蜜桃av一区二区| 免费看精品久久片| 舔着乳尖日韩一区| 亚洲成人av电影在线| 一区二区三区毛片| 亚洲色图制服丝袜| 最新中文字幕一区二区三区 | 99国内精品久久| 国产成人精品在线看| 国产精品自在欧美一区| 国产综合久久久久影院| 激情成人午夜视频| 国产一区二区伦理片| 国产福利一区二区| 国产成人免费在线| 国产成人综合网| 成人黄色大片在线观看| 99在线精品免费| 色婷婷久久久综合中文字幕 | 奇米色777欧美一区二区| 天堂久久久久va久久久久| 爽爽淫人综合网网站| 日产欧产美韩系列久久99| 老司机精品视频导航| 国产一区二区三区蝌蚪| 国产成人午夜视频| 91在线丨porny丨国产| 日本久久精品电影| 欧美麻豆精品久久久久久| 欧美一区二区三区啪啪| 久久综合成人精品亚洲另类欧美| 国产三级精品三级| 最新中文字幕一区二区三区| 一区二区三区四区在线免费观看 | 久久精品99国产精品日本| 国产中文字幕一区| 97久久精品人人澡人人爽| 欧美日韩国产综合视频在线观看| 日韩午夜电影在线观看| 久久久久久久久久久久久久久99| 亚洲少妇中出一区| 日本欧美加勒比视频| 国产成人免费高清| 欧美日韩一级黄| 国产日韩欧美不卡在线| 一区二区三区高清| 国产中文字幕精品| 在线影院国内精品| 精品处破学生在线二十三| ...中文天堂在线一区| 蜜臀av一级做a爰片久久| av色综合久久天堂av综合| 这里只有精品免费| 国产精品美女久久久久久久久久久 | 国产一区在线不卡|