ij.gui.Toolbar.getGraphics()方法的使用及代码示例

x33g5p2x  于2022-01-30 转载在 其他  
字(2.4k)|赞(0)|评价(0)|浏览(86)

本文整理了Java中ij.gui.Toolbar.getGraphics()方法的一些代码示例,展示了Toolbar.getGraphics()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Toolbar.getGraphics()方法的具体详情如下:
包路径:ij.gui.Toolbar
类名称:Toolbar
方法名:getGraphics

Toolbar.getGraphics介绍

暂无

代码示例

代码示例来源:origin: net.imagej/ij

void drawTool(int tool, boolean drawDown) {
  down[tool] = drawDown;
  Graphics g = this.getGraphics();
  if (!drawDown && Prefs.antialiasedTools) {
    Graphics2D g2d = (Graphics2D)g;
    g2d.setRenderingHint(RenderingHints.KEY_ANTIALIASING, RenderingHints.VALUE_ANTIALIAS_ON);
  }
  drawButton(g, tool);
  if (null==g) return;
  g.dispose();
}

代码示例来源:origin: net.imagej/ij

/**
* @deprecated
* replaced by setForegroundColor()
*/
public void setColor(Color c) {
  if (c!=null) {
    foregroundColor = c;
    drawButton(this.getGraphics(), DROPPER);
  }
}

代码示例来源:origin: imagej/ImageJA

/**
* @deprecated
* replaced by setForegroundColor()
*/
public void setColor(Color c) {
  if (c!=null) {
    foregroundColor = c;
    drawButton(this.getGraphics(), DROPPER);
  }
}

代码示例来源:origin: imagej/ImageJA

void drawTool(int tool, boolean drawDown) {
  down[tool] = drawDown;
  Graphics g = this.getGraphics();
  if (!drawDown && Prefs.antialiasedTools) {
    Graphics2D g2d = (Graphics2D)g;
    g2d.setRenderingHint(RenderingHints.KEY_ANTIALIASING, RenderingHints.VALUE_ANTIALIAS_ON);
  }
  drawButton(g, tool);
  if (null==g) return;
  g.dispose();
}

代码示例来源:origin: net.imagej/ij

static void repaintTool(int tool) {
  if (IJ.getInstance()!=null) {
    Toolbar tb = getInstance();
    Graphics g = tb.getGraphics();
    if (IJ.debugMode) IJ.log("Toolbar.repaintTool: "+tool+" "+g);
    if (g==null) return;
    if (Prefs.antialiasedTools)
      ((Graphics2D)g).setRenderingHint(RenderingHints.KEY_ANTIALIASING, RenderingHints.VALUE_ANTIALIAS_ON);
    tb.drawButton(g, tool);
    if (g!=null) g.dispose();
  }
}

代码示例来源:origin: imagej/ImageJA

static void repaintTool(int tool) {
  if (IJ.getInstance()!=null) {
    Toolbar tb = getInstance();
    Graphics g = tb.getGraphics();
    if (IJ.debugMode) IJ.log("Toolbar.repaintTool: "+tool+" "+g);
    if (g==null) return;
    if (Prefs.antialiasedTools)
      ((Graphics2D)g).setRenderingHint(RenderingHints.KEY_ANTIALIASING, RenderingHints.VALUE_ANTIALIAS_ON);
    tb.drawButton(g, tool);
    if (g!=null) g.dispose();
  }
}

代码示例来源:origin: stackoverflow.com

Graphics g  = tool.getGraphics();
tool.installStartupTools();

代码示例来源:origin: net.imagej/ij

String previousName = getToolName();
current = tool;
Graphics g = this.getGraphics();
if (g==null)
  return;

代码示例来源:origin: imagej/ImageJA

String previousName = getToolName();
current = tool;
Graphics g = this.getGraphics();
if (g==null)
  return;

相关文章