本文整理了Java中javax.swing.AbstractButton.isFocusPainted()
方法的一些代码示例,展示了AbstractButton.isFocusPainted()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。AbstractButton.isFocusPainted()
方法的具体详情如下:
包路径:javax.swing.AbstractButton
类名称:AbstractButton
方法名:isFocusPainted
暂无
代码示例来源:origin: com.github.arnabk/pgslookandfeel
protected void paintFocus(
Graphics g, AbstractButton b, Rectangle viewRect,
Rectangle textRect, Rectangle iconRect) {
if (b.isFocusPainted() && !(b instanceof PgsComboBoxButtonUI)) {
int topLeftInset = 3;
int width = b.getWidth() - topLeftInset * 2;
int height = b.getHeight() - topLeftInset * 2;
g.setColor(getFocusColor());
PgsUtils.drawRoundRect(g, topLeftInset, topLeftInset, width - 1, height - 1, 3, 3);
}
}
代码示例来源:origin: net.sf.nimrod/nimrod-laf
protected void paintFocus( Graphics g, AbstractButton b,
Rectangle viewRect, Rectangle textRect, Rectangle iconRect) {
if ( !b.isFocusPainted() || !oldOpaque ) {
return;
}
if( b.getParent() instanceof JToolBar ) {
return; // No se pintael foco cuando estamos en una barra
}
NimRODUtils.paintFocus( g, 3,3, b.getWidth()-6, b.getHeight()-6, 2, 2, NimRODLookAndFeel.getFocusColor());
}
代码示例来源:origin: net.sf.nimrod/nimrod-laf
protected void paintFocus( Graphics g, AbstractButton b,
Rectangle viewRect, Rectangle textRect, Rectangle iconRect) {
if ( !b.isFocusPainted() || !oldOpaque ) {
return;
}
if ( b.getParent() instanceof JToolBar ) {
return; // No se pinta el foco cuando estamos en una barra
}
NimRODUtils.paintFocus( g, 3,3, b.getWidth()-6, b.getHeight()-6, 2, 2, NimRODLookAndFeel.getFocusColor());
}
代码示例来源:origin: it.tidalwave.netbeans/it-tidalwave-netbeans-lookandfeel
@Override
protected void paintFocus (Graphics g, AbstractButton b, Rectangle viewRect, Rectangle textRect, Rectangle iconRect)
{
if (!b.isFocusPainted() || !b.isOpaque())
{
return;
}
if (b.getParent() instanceof JToolBar)
{
return;
}
g.setColor(getFocusColor());
g.drawRoundRect(2, 2, b.getWidth() - 6, b.getHeight() - 6, 5, 5);
g.drawRoundRect(3, 3, b.getWidth() - 6, b.getHeight() - 6, 4, 4);
}
代码示例来源:origin: it.tidalwave.solidblue/it-tidalwave-netbeans-lookandfeel
@Override
protected void paintFocus (Graphics g, AbstractButton b, Rectangle viewRect, Rectangle textRect, Rectangle iconRect)
{
if (!b.isFocusPainted() || !b.isOpaque())
{
return;
}
if (b.getParent() instanceof JToolBar)
{
return;
}
g.setColor(getFocusColor());
g.drawRoundRect(2, 2, b.getWidth() - 6, b.getHeight() - 6, 5, 5);
g.drawRoundRect(3, 3, b.getWidth() - 6, b.getHeight() - 6, 4, 4);
}
代码示例来源:origin: com.github.insubstantial/substance
if (b.isFocusPainted()) {
代码示例来源:origin: com.jidesoft/jide-oss
state |= SELECTED;
if (c.isFocusOwner() && button.isFocusPainted()) {
state |= FOCUSED;
代码示例来源:origin: com.jtattoo/JTattoo
if (b.isFocusPainted() && b.hasFocus()) {
paintFocus(g, b, viewRect, textRect, iconRect);
代码示例来源:origin: khuxtable/seaglass
if (c.isFocusOwner() && button.isFocusPainted()) {
state |= FOCUSED;
代码示例来源:origin: com.github.insubstantial/substance
if (b.isFocusPainted()) {
SubstanceCoreUtilities.paintFocus(g, b, b, this, null, textRect,
1.0f, SubstanceSizeUtils
代码示例来源:origin: org.java.net.substance/substance
if (b.isFocusPainted()) {
SubstanceCoreUtilities.paintFocus(g, b, b, this, null, textRect,
1.0f, SubstanceSizeUtils
代码示例来源:origin: com.synaptix/SynaptixSwing
viewRect.height);
if (b.isFocusPainted() && b.hasFocus()) {
代码示例来源:origin: org.java.net.substance/substance
if (b.isFocusPainted()) {
SubstanceCoreUtilities.paintFocus(g, b, b, this, null, textRect,
1.0f, SubstanceSizeUtils
代码示例来源:origin: org.swinglabs.swingx/swingx-core
if (b.isFocusPainted() && b.hasFocus()) {
代码示例来源:origin: org.bidib.jbidib.swinglabs.swingx/swingx-core
if (b.isFocusPainted() && b.hasFocus()) {
代码示例来源:origin: org.swinglabs.swingx/swingx-all
if (b.isFocusPainted() && b.hasFocus()) {
代码示例来源:origin: org.codehaus.jtstand/jtstand-desktop
if (b.isFocusPainted() && b.hasFocus()) {
代码示例来源:origin: com.haulmont.thirdparty/swingx-core
if (b.isFocusPainted() && b.hasFocus()) {
代码示例来源:origin: com.jidesoft/jide-oss
return ThemePainter.STATE_SELECTED;
else if (b.hasFocus() && b.isFocusPainted()) {
if (model.isSelected()) {
return ThemePainter.STATE_PRESSED;
代码示例来源:origin: com.jtattoo/JTattoo
if (b.hasFocus() && b.isFocusPainted() && (textRect.width > 0) && (textRect.height > 0)) {
paintFocus(g, textRect, size);
内容来源于网络,如有侵权,请联系作者删除!