當前位置: 首頁>>代碼示例>>Java>>正文


Java SystemColor.textInactiveText方法代碼示例

本文整理匯總了Java中java.awt.SystemColor.textInactiveText方法的典型用法代碼示例。如果您正苦於以下問題:Java SystemColor.textInactiveText方法的具體用法?Java SystemColor.textInactiveText怎麽用?Java SystemColor.textInactiveText使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在java.awt.SystemColor的用法示例。


在下文中一共展示了SystemColor.textInactiveText方法的3個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。

示例1: paintComponent

import java.awt.SystemColor; //導入方法依賴的package包/類
/**
 * Um eine halbtransparente Hintergrundfarbe hinzubekommen, müssen wir
 * paintComponent überschreiben.
 * 
 * @see javax.swing.JComponent#paintComponent(java.awt.Graphics)
 */
@Override
protected void paintComponent(Graphics g)
{
  super.paintComponent(g);
  Color c = SystemColor.textInactiveText;
  g.setColor(new Color(c.getRed(), c.getGreen(), c.getBlue(), 128));
  g.fillRect(0, 0, getWidth(), getHeight());
}
 
開發者ID:WollMux,項目名稱:WollMux,代碼行數:15,代碼來源:FrameWorker.java

示例2: getBasicSystemColors

import java.awt.SystemColor; //導入方法依賴的package包/類
private Object[] getBasicSystemColors() {
    Object[] basicSystemColors = {"desktop", SystemColor.desktop,
                                  "activeCaption", SystemColor.activeCaption,
                                  "activeCaptionText", SystemColor.activeCaptionText,
                                  "activeCaptionBorder", SystemColor.activeCaptionBorder,
                                  "inactiveCaption", SystemColor.inactiveCaption,
                                  "inactiveCaptionText", SystemColor.inactiveCaptionText,
                                  "inactiveCaptionBorder", SystemColor.inactiveCaptionBorder,
                                  "window", SystemColor.window,
                                  "windowBorder", SystemColor.windowBorder,
                                  "windowText", SystemColor.windowText,
                                  "menu", SystemColor.menu,
                                  "menuText", SystemColor.menuText,
                                  "text", SystemColor.text,
                                  "textText", SystemColor.textText,
                                  "textHighlight", SystemColor.textHighlight,
                                  "textHighlightText", SystemColor.textHighlightText,
                                  "textInactiveText", SystemColor.textInactiveText,
                                  "control", SystemColor.control,
                                  "controlText", SystemColor.controlText,
                                  "controlHighlight", SystemColor.controlHighlight,
                                  "controlLtHighlight", SystemColor.controlLtHighlight,
                                  "controlShadow", SystemColor.controlShadow,
                                  "controlDkShadow", SystemColor.controlDkShadow,
                                  "scrollbar", SystemColor.scrollbar,
                                  "info", SystemColor.info,
                                  "infoText", SystemColor.infoText };
    return basicSystemColors;
}
 
開發者ID:shannah,項目名稱:cn1,代碼行數:30,代碼來源:BasicLookAndFeel.java

示例3: focusLost

import java.awt.SystemColor; //導入方法依賴的package包/類
@Override
public void focusLost(FocusEvent e)
{
	if (this.getText().isEmpty())
	{
		super.setText(hint);
		super.setForeground(SystemColor.textInactiveText);
		showingHint = true;
	}
}
 
開發者ID:Razican,項目名稱:RDO-client,代碼行數:11,代碼來源:ITextField.java


注:本文中的java.awt.SystemColor.textInactiveText方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。