Java Examples for java.awt.Color
The following java examples will help you to understand the usage of java.awt.Color. These source code samples are taken from different open source projects.
Example 1
| Project: lanterna-master File: TerminalEmulatorPalette.java View source code |
/**
* Returns the AWT color from this palette given an ANSI color and two hints for if we are looking for a background
* color and if we want to use the bright version.
* @param color Which ANSI color we want to extract
* @param isForeground Is this color we extract going to be used as a background color?
* @param useBrightTones If true, we should return the bright version of the color
* @return AWT color extracted from this palette for the input parameters
*/
public Color get(TextColor.ANSI color, boolean isForeground, boolean useBrightTones) {
if (useBrightTones) {
switch(color) {
case BLACK:
return brightBlack;
case BLUE:
return brightBlue;
case CYAN:
return brightCyan;
case DEFAULT:
return isForeground ? defaultBrightColor : defaultBackgroundColor;
case GREEN:
return brightGreen;
case MAGENTA:
return brightMagenta;
case RED:
return brightRed;
case WHITE:
return brightWhite;
case YELLOW:
return brightYellow;
}
} else {
switch(color) {
case BLACK:
return normalBlack;
case BLUE:
return normalBlue;
case CYAN:
return normalCyan;
case DEFAULT:
return isForeground ? defaultColor : defaultBackgroundColor;
case GREEN:
return normalGreen;
case MAGENTA:
return normalMagenta;
case RED:
return normalRed;
case WHITE:
return normalWhite;
case YELLOW:
return normalYellow;
}
}
throw new IllegalArgumentException("Unknown text color " + color);
}Example 2
| Project: batik-master File: Color1.java View source code |
public void paint(Graphics2D g) {
g.setRenderingHint(RenderingHints.KEY_ANTIALIASING, RenderingHints.VALUE_ANTIALIAS_ON);
java.awt.geom.AffineTransform defaultTransform = g.getTransform();
// Colors used for labels and test output
java.awt.Color labelColor = java.awt.Color.black;
java.awt.Color[] colorConstants = { java.awt.Color.black, java.awt.Color.blue, java.awt.Color.cyan, java.awt.Color.darkGray, java.awt.Color.gray, java.awt.Color.green, java.awt.Color.lightGray, java.awt.Color.magenta, java.awt.Color.orange, java.awt.Color.pink, java.awt.Color.red, java.awt.Color.white, java.awt.Color.yellow };
String[] colorConstantStrings = { "black", "blue", "cyan", "darkGray", "gray", "green", "lightGray", "magenta", "orange", "pink", "red", "white", "yellow" };
g.translate(20, 20);
g.setPaint(labelColor);
g.drawString("Color Constants", -5, 0);
g.translate(0, 20);
for (int i = 0; i < colorConstants.length; i++) {
g.setPaint(labelColor);
g.drawString(colorConstantStrings[i], 10, 3);
g.setPaint(colorConstants[i]);
g.fillRect(-5, -5, 10, 10);
g.setPaint(labelColor);
g.drawRect(-5, -5, 10, 10);
g.translate(0, 20);
}
g.setTransform(defaultTransform);
g.translate(150, 20);
g.setColor(labelColor);
g.drawString("Various opacities", 0, 0);
g.translate(0, 10);
//
// Now, test opacities
//
int opacitySteps = 20;
g.setPaint(new java.awt.Color(80, 255, 80));
g.fillRect(0, 0, 40, 260);
int stepHeight = 260 / opacitySteps;
Font defaultFont = g.getFont();
Font opacityFont = new Font(defaultFont.getFamily(), defaultFont.getStyle(), (int) (defaultFont.getSize() * 0.8));
g.setFont(opacityFont);
for (int i = 0; i < opacitySteps; i++) {
int opacity = ((i + 1) * 255) / opacitySteps;
java.awt.Color color = new java.awt.Color(0, 0, 0, opacity);
g.setPaint(color);
g.fillRect(0, 0, 40, stepHeight);
g.setPaint(labelColor);
g.drawString(String.valueOf(opacity), 50, stepHeight / 2);
g.translate(0, stepHeight);
}
}Example 3
| Project: vebugger-master File: ColorTemplate.java View source code |
@Override
public void render(StringBuilder sb, Object obj) {
Color color = (Color) obj;
int hashCode = color.hashCode();
sb.append("<style>");
sb.append("table.java-awt-Color-").append(hashCode).append(" > tbody > tr > td.color {background:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAoAAAAKCAYAAACNMs+9AAAAGUlEQVQYlWNoaGj4j44ZsIGhoHCQOYcihQDTKHzPovZrygAAAABJRU5ErkJggg==) repeat; padding: 0}");
sb.append("table.java-awt-Color-").append(hashCode).append(" tbody > tr > td.color > div {width:100px; height:100px; background-color: #").append(String.format("%06x", color.getRGB() & 0xffffff)).append("; opacity: ").append(color.getAlpha() / 255.0).append(";}");
sb.append("table.java-awt-Color-").append(hashCode).append(" {border-spacing: 0px; border-collapse: collapse;}");
sb.append("table.java-awt-Color-").append(hashCode).append(" tbody > tr > td {border: 0px;}");
sb.append("table.java-awt-Color-").append(hashCode).append(" tbody > tr > td.value {font-family: monospace; height: 25px; padding: 0 4px; vertical-align: middle;}");
sb.append("table.java-awt-Color-").append(hashCode).append(" tbody > tr > td.red {color: red;}");
sb.append("table.java-awt-Color-").append(hashCode).append(" tbody > tr > td.green {color: green;}");
sb.append("table.java-awt-Color-").append(hashCode).append(" tbody > tr > td.blue {color: blue;}");
sb.append("table.java-awt-Color-").append(hashCode).append(" tbody > tr > td.alpha {color: black;}");
sb.append("</style>");
sb.append("<table class=\"java-awt-Color-").append(hashCode).append("\"><tbody><tr><td rowspan=\"4\" class=\"color\"><div></div></td><td class=\"value red\">Red</td><td class=\"value red\">").append(color.getRed()).append("</td></tr><tr><td class=\"value green\">Green</td><td class=\"value green\">").append(color.getGreen()).append("</td></tr><tr><td class=\"value blue\">Blue</td><td class=\"value blue\">").append(color.getBlue()).append("</td></tr><tr><td class=\"value alpha\">Alpha</td><td class=\"value alpha\">").append(color.getAlpha()).append("</td></tr></tbody></table>");
}Example 4
| Project: pdfxtk-master File: WaitBar.java View source code |
public void paint(java.awt.Graphics g) {
java.awt.Dimension d = getSize();
int width = d.width;
int height = d.height;
if (step != -1) {
int y0 = 0;
int y1 = 0;
for (int i = 1; i < colors.length; i++) {
y0 = y1;
y1 = (height * i) / colors.length;
g.setColor(colors[i]);
g.fillRect(0, y0, width, y1);
}
g.setColor(java.awt.Color.black);
int x0 = step % height;
int x1 = (step % height) + height;
for (int i = -height; i < width; i += height) g.drawLine(x0 + i, 0, x1 + i, height);
} else {
g.setColor(java.awt.Color.lightGray);
g.fillRect(0, 0, width - 1, height - 1);
}
g.setColor(java.awt.Color.black);
g.drawRect(0, 0, width - 1, height - 1);
}Example 5
| Project: intellij-community-master File: SyntaxInfoConstructionTest.java View source code |
public void testBlockSelection() {
String text = "package org;\n" + "\n" + "public class TestClass {\n" + "\n" + " int field;\n" + "\n" + " public int getField() {\n" + " return field;\n" + " }\n" + "}";
init(text);
int blockSelectionStartOffset = text.indexOf("public int");
Editor editor = myFixture.getEditor();
LogicalPosition blockSelectionStartPosition = editor.offsetToLogicalPosition(blockSelectionStartOffset);
LogicalPosition blockSelectionEndPosition = new LogicalPosition(blockSelectionStartPosition.line + 2, editor.offsetToLogicalPosition(text.indexOf('{', blockSelectionStartOffset)).column + 1);
editor.getSelectionModel().setBlockSelection(blockSelectionStartPosition, blockSelectionEndPosition);
verifySyntaxInfo("foreground=java.awt.Color[r=0,g=0,b=128],fontStyle=1,text=public int \n" + "foreground=java.awt.Color[r=0,g=0,b=0],fontStyle=0,text=getField() {\n" + "text=\n" + "\n" + "text= \n" + "foreground=java.awt.Color[r=0,g=0,b=128],fontStyle=1,text=return \n" + "foreground=java.awt.Color[r=102,g=14,b=122],text=field\n" + "foreground=java.awt.Color[r=0,g=0,b=0],fontStyle=0,text=;\n" + "text=\n" + "\n" + "text=}\n");
}Example 6
| Project: thredds-master File: ColorScale.java View source code |
/**
* Set the number of colors in the colorscale.
*/
public void setNumColors(int n) {
if (n != ncolors) {
colors = new Color[n];
int prevn = Math.min(ncolors, n);
System.arraycopy(useColors, 0, colors, 0, prevn);
for (int i = ncolors; i < n; i++) colors[i] = Color.white;
useColors = colors;
ncolors = n;
edge = new double[ncolors];
hist = new int[ncolors + 1];
}
}Example 7
| Project: Aspose_Pdf_Java-master File: CreateBookmarksOfAllPagesWithProperties.java View source code |
public static void main(String[] args) {
// Path to Directorty
String myDir = "PathToDir";
// open document
PdfBookmarkEditor bookmarkEditor = new PdfBookmarkEditor();
bookmarkEditor.bindPdf("Input.pdf");
// create bookmark of all pages
bookmarkEditor.createBookmarks(Color.GREEN, true, true);
// save updated PDF file
bookmarkEditor.save(myDir + "Output.pdf");
}Example 8
| Project: windowtester-master File: ColorParser.java View source code |
public Object parse(String input) throws IllegalArgumentException {
// NOTE: may want to provide additional parsing, e.g.
// #00CC00
// R:G:B
// Color.toString (although this is not guaranteed to be consistent)
// or some other format
Color c = Color.getColor(input);
if (c != null)
return c;
throw new IllegalArgumentException("Can't convert '" + input + "' to java.awt.Color");
}Example 9
| Project: ChromisPOS-master File: SteelCheckBoxUI.java View source code |
// </editor-fold>
// <editor-fold defaultstate="collapsed" desc="Paint method">
@Override
public synchronized void paint(java.awt.Graphics g, javax.swing.JComponent component) {
final java.awt.Graphics2D G2 = (java.awt.Graphics2D) g.create();
G2.setRenderingHint(java.awt.RenderingHints.KEY_ANTIALIASING, java.awt.RenderingHints.VALUE_ANTIALIAS_ON);
pos.setLocation(0, (this.CHECKBOX.getPreferredSize().height - SIZE.height) / 2.0);
if (!CHECKBOX.isEnabled()) {
G2.setComposite(java.awt.AlphaComposite.getInstance(java.awt.AlphaComposite.SRC_OVER, 0.5f));
}
// Draw the background
G2.drawImage(backgroundImage, pos.x, pos.y, null);
// Draw the foreground and knob
if (CHECKBOX.isSelected()) {
if (CHECKBOX.isColored()) {
if (CHECKBOX.isRised()) {
foregroundColors = new java.awt.Color[] { CHECKBOX.getSelectedColor().LIGHT.brighter(), CHECKBOX.getSelectedColor().LIGHT, CHECKBOX.getSelectedColor().MEDIUM, CHECKBOX.getSelectedColor().DARK };
} else {
foregroundColors = new java.awt.Color[] { CHECKBOX.getSelectedColor().DARK, CHECKBOX.getSelectedColor().DARK, CHECKBOX.getSelectedColor().LIGHT, CHECKBOX.getSelectedColor().MEDIUM };
}
} else {
foregroundColors = new java.awt.Color[] { new java.awt.Color(241, 242, 242, 255), new java.awt.Color(224, 225, 226, 255), new java.awt.Color(166, 169, 171, 255), new java.awt.Color(124, 124, 124, 255) };
}
foregroundGradient = new java.awt.LinearGradientPaint(foregroundStart, foregroundStop, FOREGROUND_FRACTIONS, foregroundColors);
G2.setPaint(foregroundGradient);
G2.fill(foreground);
if (mouseOver && mousePressed) {
G2.drawImage(knobPressedImage, pos.x + backgroundImage.getWidth() / 2, pos.y, null);
} else {
G2.drawImage(knobStandardImage, pos.x + backgroundImage.getWidth() / 2, pos.y, null);
}
} else {
if (mouseOver && mousePressed) {
G2.drawImage(knobPressedImage, pos.x, pos.y, null);
} else {
G2.drawImage(knobStandardImage, pos.x, pos.y, null);
}
}
G2.setColor(CHECKBOX.getForeground());
G2.setFont(CHECKBOX.getFont());
final java.awt.font.FontRenderContext RENDER_CONTEXT = new java.awt.font.FontRenderContext(null, true, true);
final java.awt.font.TextLayout TEXT_LAYOUT = new java.awt.font.TextLayout(CHECKBOX.getText(), G2.getFont(), RENDER_CONTEXT);
final java.awt.geom.Rectangle2D BOUNDS = TEXT_LAYOUT.getBounds();
G2.drawString(CHECKBOX.getText(), backgroundImage.getWidth() + 5, (CHECKBOX.getBounds().height - BOUNDS.getBounds().height) / 2 + BOUNDS.getBounds().height);
G2.dispose();
}Example 10
| Project: medsavant-master File: SteelCheckBoxUI.java View source code |
// </editor-fold>
// <editor-fold defaultstate="collapsed" desc="Paint method">
@Override
public synchronized void paint(java.awt.Graphics g, javax.swing.JComponent component) {
final java.awt.Graphics2D G2 = (java.awt.Graphics2D) g.create();
G2.setRenderingHint(java.awt.RenderingHints.KEY_ANTIALIASING, java.awt.RenderingHints.VALUE_ANTIALIAS_ON);
pos.setLocation(0, (this.CHECKBOX.getPreferredSize().height - SIZE.height) / 2.0);
if (!CHECKBOX.isEnabled()) {
G2.setComposite(java.awt.AlphaComposite.getInstance(java.awt.AlphaComposite.SRC_OVER, 0.5f));
}
// Draw the background
G2.drawImage(backgroundImage, pos.x, pos.y, null);
// Draw the foreground and knob
if (CHECKBOX.isSelected()) {
if (CHECKBOX.isColored()) {
if (CHECKBOX.isRised()) {
foregroundColors = new java.awt.Color[] { CHECKBOX.getSelectedColor().LIGHT.brighter(), CHECKBOX.getSelectedColor().LIGHT, CHECKBOX.getSelectedColor().MEDIUM, CHECKBOX.getSelectedColor().DARK };
} else {
foregroundColors = new java.awt.Color[] { CHECKBOX.getSelectedColor().DARK, CHECKBOX.getSelectedColor().DARK, CHECKBOX.getSelectedColor().LIGHT, CHECKBOX.getSelectedColor().MEDIUM };
}
} else {
foregroundColors = new java.awt.Color[] { new java.awt.Color(241, 242, 242, 255), new java.awt.Color(224, 225, 226, 255), new java.awt.Color(166, 169, 171, 255), new java.awt.Color(124, 124, 124, 255) };
}
foregroundGradient = new java.awt.LinearGradientPaint(foregroundStart, foregroundStop, FOREGROUND_FRACTIONS, foregroundColors);
G2.setPaint(foregroundGradient);
G2.fill(foreground);
if (mouseOver && mousePressed) {
G2.drawImage(knobPressedImage, pos.x + backgroundImage.getWidth() / 2, pos.y, null);
} else {
G2.drawImage(knobStandardImage, pos.x + backgroundImage.getWidth() / 2, pos.y, null);
}
} else {
if (mouseOver && mousePressed) {
G2.drawImage(knobPressedImage, pos.x, pos.y, null);
} else {
G2.drawImage(knobStandardImage, pos.x, pos.y, null);
}
}
G2.setColor(CHECKBOX.getForeground());
G2.setFont(CHECKBOX.getFont());
final java.awt.font.FontRenderContext RENDER_CONTEXT = new java.awt.font.FontRenderContext(null, true, true);
final java.awt.font.TextLayout TEXT_LAYOUT = new java.awt.font.TextLayout(CHECKBOX.getText(), G2.getFont(), RENDER_CONTEXT);
final java.awt.geom.Rectangle2D BOUNDS = TEXT_LAYOUT.getBounds();
G2.drawString(CHECKBOX.getText(), backgroundImage.getWidth() + 5, (CHECKBOX.getBounds().height - BOUNDS.getBounds().height) / 2 + BOUNDS.getBounds().height);
G2.dispose();
}Example 11
| Project: beakerx-master File: Bars.java View source code |
public void setOutlineColor(Object color) {
if (color instanceof Color) {
this.baseOutlineColor = (Color) color;
} else if (color instanceof java.awt.Color) {
this.baseOutlineColor = new Color((java.awt.Color) color);
} else if (color instanceof List) {
@SuppressWarnings("unchecked") List<Object> cs = (List<Object>) color;
setOutlineColors(cs);
} else {
throw new IllegalArgumentException("setOutlineColor takes Color or List of Color");
}
}Example 12
| Project: neohort-master File: chart_content_RADAR.java View source code |
public PdfContentByte placeBarcode(PdfContentByte cb, boolean paint) {
try {
Vector scale_buf = new Vector();
if (orientation == or_TOP) {
if (paint) {
if (background != null) {
cb.setColorFill(background);
cb.rectangle(x, y, height, width);
cb.fill();
}
}
//Label-Top
if (label != null && label.trim().length() > 0) {
width_Label = label_font.getWidthPoint(label, label_fontsize);
if (width_Label > width - x)
width_Label = width - x;
height_Label = label_font.getFontDescriptor(BaseFont.AWT_MAXADVANCE, label_fontsize);
x_Label = x + (width - x - width_Label) / 2;
if (label_align.equalsIgnoreCase("CENTER"))
x_Label = x + (width - x - width_Label) / 2;
if (label_align.equalsIgnoreCase("RIGHT"))
x_Label = (width + x - width_Label);
if (label_align.equalsIgnoreCase("LEFT"))
x_Label = x;
y_Label = y + (height - height_Label) / 2;
if (paint) {
cb.setColorFill(label_color);
cb.beginText();
cb.setFontAndSize(label_font, label_fontsize);
cb.showTextAligned(PdfContentByte.ALIGN_LEFT, label, x_Label, y_Label, label_gr);
cb.endText();
cb.fill();
}
}
if (!paint)
height = height_Label + height_Label;
}
if (orientation == or_BOTTOM) {
}
if (orientation == or_BOTTOM) {
if (paint) {
if (background != null) {
cb.setColorFill(background);
cb.rectangle(x, y, height, width);
cb.fill();
}
}
//Scale-Left
float Radice = 0;
if (scale.size() > 0) {
y_Scale = y + height / 2;
if (label_gr == 0)
x_Scale = x + width_Label + space_0;
else
x_Scale = x + height_Label + space_0;
for (int i = 0; i < scale.size(); i++) {
String value = (String) scale.elementAt(i);
float sc_width_buf = scale_font.getWidthPoint(value, scale_fontsize);
if (width_Scale < sc_width_buf)
width_Scale = sc_width_buf;
scale_buf.addElement(value);
}
height_Scale = scale_font.getFontDescriptor(BaseFont.AWT_MAXADVANCE, scale_fontsize);
double coefAlfa = 1;
if (scale_gr != 0)
coefAlfa = Math.abs(Math.cos(scale_gr * Math.PI / 180));
float coefAlfaD = new java.math.BigDecimal(coefAlfa).floatValue();
if (scale_gr == 90)
x_Line = x + height_Label + 8 * space_0 + height_Scale;
else
x_Line = x + height_Label + 5 * space_0 + width_Scale * coefAlfaD;
y_Line = y + height / 2;
if (width - x_Line > height)
Radice = (height - prof) / 2;
else
Radice = (width - prof - x_Line) / 2;
delta_Scale = (Radice) / (scale_max - 1);
if (paint) {
cb.setColorFill(scale_color);
for (int i = 0; i < scale_buf.size(); i++) {
cb.beginText();
cb.setFontAndSize(scale_font, scale_fontsize);
if (label_gr == 90) {
if (scale_gr == 90)
cb.showTextAligned(PdfContentByte.ALIGN_RIGHT, (String) scale_buf.elementAt(i), x_Scale + 4 * space_0 + height_Scale, y + height / 2 + i * delta_Scale + space_0, scale_gr);
else
cb.showTextAligned(PdfContentByte.ALIGN_RIGHT, (String) scale_buf.elementAt(i), x_Scale + width_Scale * coefAlfaD, y + height / 2 + i * delta_Scale + space_0, scale_gr);
} else {
if (scale_gr == 90)
cb.showTextAligned(PdfContentByte.ALIGN_RIGHT, (String) scale_buf.elementAt(i), x_Scale + 4 * space_0 + height_Scale, y + height / 2 + i * delta_Scale + space_0, scale_gr);
else
cb.showTextAligned(PdfContentByte.ALIGN_RIGHT, (String) scale_buf.elementAt(i), x_Scale + width_Scale * coefAlfaD, y + height / 2 + i * delta_Scale + space_0, scale_gr);
}
cb.endText();
}
cb.fill();
}
}
if (paint) {
cb.setColorFill(java.awt.Color.black);
cb.moveTo(x_Line, y_Line);
cb.lineTo(x_Line, y_Line + Radice);
for (int i = 0; i < scale_buf.size(); i++) {
cb.moveTo(x_Line - 2, y_Line + i * delta_Scale);
cb.lineTo(x_Line, y_Line + i * delta_Scale);
}
cb.fill();
float centerX = (width - prof + x_Line) / 2;
float centerY = (height - prof) / 2;
Vector datiX = dati.getDati(0, Radice * 2);
float alfaDelta = 360 / datiX.size();
float alfaStart = 90;
if (isShow_scale()) {
for (int i = 0; i < datiX.size(); i++) {
float Hx = new java.math.BigDecimal(Radice * Math.cos(Math.PI * alfaStart / 180)).floatValue() + centerX + prof / 2 + x;
float Hy = new java.math.BigDecimal(Radice * Math.sin(Math.PI * alfaStart / 180)).floatValue() + centerY + prof / 2 + y;
cb.setColorFill(java.awt.Color.black);
cb.moveTo(x + centerX + prof / 2, y + centerY + prof / 2);
cb.lineTo(Hx, Hy);
cb.fill();
float deltamax_scale = delta_Scale;
for (int j = 0; j < scale_max - 1; j++) {
float Hx1 = new java.math.BigDecimal(deltamax_scale * Math.cos(Math.PI * alfaStart / 180)).floatValue() + centerX + prof / 2 + x;
float Hy1 = new java.math.BigDecimal(deltamax_scale * Math.sin(Math.PI * alfaStart / 180)).floatValue() + centerY + prof / 2 + y;
float Hx2 = new java.math.BigDecimal(deltamax_scale * Math.cos(Math.PI * (alfaStart - alfaDelta) / 180)).floatValue() + centerX + prof / 2 + x;
float Hy2 = new java.math.BigDecimal(deltamax_scale * Math.sin(Math.PI * (alfaStart - alfaDelta) / 180)).floatValue() + centerY + prof / 2 + y;
if ((alfaStart - alfaDelta) < -265) {
Hx2 = new java.math.BigDecimal(deltamax_scale * Math.cos(Math.PI * (90) / 180)).floatValue() + centerX + prof / 2 + x;
Hy2 = new java.math.BigDecimal(deltamax_scale * Math.sin(Math.PI * (90) / 180)).floatValue() + centerY + prof / 2 + y;
}
cb.setColorFill(java.awt.Color.black);
cb.moveTo(Hx1, Hy1);
cb.lineTo(Hx2, Hy2);
cb.fill();
deltamax_scale += delta_Scale;
}
alfaStart -= alfaDelta;
}
}
}
if (!paint) {
width = x_Line;
height = height + y - delta_Scale;
}
}
if (orientation == or_CENTER) {
if (paint) {
if (background != null) {
cb.setColorFill(background);
cb.rectangle(x, y, width, height);
cb.fill();
}
}
//Scale-Center
if (dati != null) {
float Radice = 0;
if (width > height)
Radice = (height - prof) / 2;
else
Radice = (width - prof) / 2;
Vector datiX = dati.getDati(0, Radice * 2);
Vector datiY = dati.getDati(1, Radice * 2);
if (paint && datiX.size() > 0 && datiY.size() > 0) {
float centerX = (width - prof) / 2;
float centerY = (height - prof) / 2;
for (int i = 0; i < datiX.size() - 1; i++) {
float x1 = new java.math.BigDecimal((String) datiX.elementAt(i)).floatValue() + centerX + prof / 2 + x;
float y1 = new java.math.BigDecimal((String) datiY.elementAt(i)).floatValue() + centerY + prof / 2 + y;
float x2 = new java.math.BigDecimal((String) datiX.elementAt(i + 1)).floatValue() + centerX + prof / 2 + x;
float y2 = new java.math.BigDecimal((String) datiY.elementAt(i + 1)).floatValue() + centerY + prof / 2 + y;
cb.setColorFill(element_color_2);
cb.moveTo(x + centerX + prof / 2, y + centerY + prof / 2);
cb.lineTo(x1, y1);
cb.lineTo(x2, y2);
cb.fill();
cb.setColorFill(element_color_1);
cb.moveTo(x + centerX + prof / 2, y + centerY + prof / 2);
cb.lineTo(x1, y1);
cb.fill();
cb.setColorFill(element_color_1);
cb.moveTo(x + centerX + prof / 2, y + centerY + prof / 2);
cb.lineTo(x2, y2);
cb.fill();
cb.setColorFill(element_color_1);
cb.moveTo(x1, y1);
cb.lineTo(x2, y2);
cb.fill();
}
}
}
}
} catch (Exception e) {
setError(e, iStub.log_FATAL);
}
return cb;
}Example 13
| Project: visage-compiler-master File: JTextAreaImpl.java View source code |
public void setBackgroundPaint(java.awt.Paint backgroundPaint) {
java.awt.Paint old = this.backgroundPaint;
this.backgroundPaint = backgroundPaint;
if (backgroundPaint == null) {
setBackground(null);
setOpaque(false);
} else if (backgroundPaint instanceof java.awt.Color && ((java.awt.Color) backgroundPaint).getAlpha() == 255) {
setBackground((java.awt.Color) backgroundPaint);
setOpaque(true);
} else {
setBackground(NOCOLOR);
setOpaque(false);
repaint();
}
firePropertyChange("backgroundPaint", old, backgroundPaint);
}Example 14
| Project: openflexo-master File: BackgroundStyle.java View source code |
public static BackgroundStyle makeBackground(BackgroundStyleType type) {
if (type == BackgroundStyleType.NONE) {
return makeEmptyBackground();
} else if (type == BackgroundStyleType.COLOR) {
return makeColoredBackground(java.awt.Color.WHITE);
} else if (type == BackgroundStyleType.COLOR_GRADIENT) {
return makeColorGradientBackground(java.awt.Color.WHITE, java.awt.Color.BLACK, org.openflexo.fge.graphics.BackgroundStyle.ColorGradient.ColorGradientDirection.SOUTH_EAST_NORTH_WEST);
} else if (type == BackgroundStyleType.TEXTURE) {
return makeTexturedBackground(org.openflexo.fge.graphics.BackgroundStyle.Texture.TextureType.TEXTURE1, java.awt.Color.RED, java.awt.Color.WHITE);
} else if (type == BackgroundStyleType.IMAGE) {
return makeImageBackground((File) null);
}
return null;
}Example 15
| Project: cooper-master File: JDependUIUtil.java View source code |
public static void addClickTipEffect(final JComponent component) {
component.setForeground(new java.awt.Color(51, 51, 255));
component.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
component.addMouseListener(new java.awt.event.MouseAdapter() {
@Override
public void mouseEntered(MouseEvent e) {
component.setOpaque(true);
component.setBackground(new java.awt.Color(51, 51, 255));
component.setForeground(new java.awt.Color(255, 255, 255));
}
@Override
public void mouseExited(MouseEvent e) {
component.setOpaque(false);
component.setBackground(new java.awt.Color(255, 255, 255));
component.setForeground(new java.awt.Color(51, 51, 255));
}
});
}Example 16
| Project: poi-master File: WorkingWithRichText.java View source code |
public static void main(String[] args) throws Exception {
//or new HSSFWorkbook();
XSSFWorkbook wb = new XSSFWorkbook();
try {
XSSFSheet sheet = wb.createSheet();
XSSFRow row = sheet.createRow(2);
XSSFCell cell = row.createCell(1);
XSSFRichTextString rt = new XSSFRichTextString("The quick brown fox");
XSSFFont font1 = wb.createFont();
font1.setBold(true);
font1.setColor(new XSSFColor(new java.awt.Color(255, 0, 0)));
rt.applyFont(0, 10, font1);
XSSFFont font2 = wb.createFont();
font2.setItalic(true);
font2.setUnderline(XSSFFont.U_DOUBLE);
font2.setColor(new XSSFColor(new java.awt.Color(0, 255, 0)));
rt.applyFont(10, 19, font2);
XSSFFont font3 = wb.createFont();
font3.setColor(new XSSFColor(new java.awt.Color(0, 0, 255)));
rt.append(" Jumped over the lazy dog", font3);
cell.setCellValue(rt);
// Write the output to a file
OutputStream fileOut = new FileOutputStream("xssf-richtext.xlsx");
try {
wb.write(fileOut);
} finally {
fileOut.close();
}
} finally {
wb.close();
}
}Example 17
| Project: Sphero-Desktop-API-master File: Color.java View source code |
public static java.awt.Color fromHex(String hexValue) { String v; // Check which type is used for the hex value if (hexValue.startsWith("0x")) v = hexValue.substring(2); else if (hexValue.startsWith("#")) v = hexValue.substring(1); else v = hexValue; // Check if the hex value is correct length if (v.length() != 6) return null; // Start conversion int i = Integer.valueOf(v.toUpperCase(), 16); int r = (i >> 16) & 0xFF; int g = (i >> 8) & 0xFF; int b = i & 0xFF; System.out.println(r + ", " + g + ", " + b); return new java.awt.Color(r, g, b); }
Example 18
| Project: twiterra-master File: NASAWFSPlaceNameLayer.java View source code |
private static PlaceNameServiceSet makePlaceNameServiceSet() {
final String service = "http://builds.worldwind.arc.nasa.gov/geoserver/wfs";
final String fileCachePath = "Earth/NASA WFS Place Names";
PlaceNameServiceSet placeNameServiceSet = new PlaceNameServiceSet();
placeNameServiceSet.setExpiryTime(new GregorianCalendar(2008, 1, 11).getTimeInMillis());
PlaceNameService placeNameService;
final Sector usSector = Sector.fromDegrees(0d, 90d, -180, 0);
// Oceans
if (activeNamesList.contains(OCEANS)) {
placeNameService = new PlaceNameService(service, "topp:wpl_oceans", fileCachePath, Sector.FULL_SPHERE, GRID_1x1, java.awt.Font.decode("Arial-BOLDITALIC-12"));
placeNameService.setColor(new java.awt.Color(200, 200, 200));
placeNameService.setMinDisplayDistance(0d);
placeNameService.setMaxDisplayDistance(LEVEL_A);
placeNameServiceSet.addService(placeNameService, false);
}
// Continents
if (activeNamesList.contains(CONTINENTS)) {
placeNameService = new PlaceNameService(service, "topp:wpl_continents", fileCachePath, Sector.FULL_SPHERE, GRID_1x1, java.awt.Font.decode("Arial-BOLD-12"));
placeNameService.setColor(new java.awt.Color(255, 255, 240));
placeNameService.setMinDisplayDistance(LEVEL_G);
placeNameService.setMaxDisplayDistance(LEVEL_A);
placeNameServiceSet.addService(placeNameService, false);
}
// Water Bodies
if (activeNamesList.contains(WATERBODIES)) {
placeNameService = new PlaceNameService(service, "topp:wpl_waterbodies", fileCachePath, Sector.FULL_SPHERE, GRID_5x10, java.awt.Font.decode("Arial-ITALIC-10"));
placeNameService.setColor(java.awt.Color.cyan);
placeNameService.setMinDisplayDistance(0d);
placeNameService.setMaxDisplayDistance(LEVEL_B);
placeNameServiceSet.addService(placeNameService, false);
}
// Trenches & Ridges
if (activeNamesList.contains(TRENCHESRIDGES)) {
placeNameService = new PlaceNameService(service, "topp:wpl_trenchesridges", fileCachePath, Sector.FULL_SPHERE, GRID_5x10, java.awt.Font.decode("Arial-BOLDITALIC-10"));
placeNameService.setColor(java.awt.Color.cyan);
placeNameService.setMinDisplayDistance(0d);
placeNameService.setMaxDisplayDistance(LEVEL_B);
placeNameServiceSet.addService(placeNameService, false);
}
// Deserts & Plains
if (activeNamesList.contains(DESERTSPLAINS)) {
placeNameService = new PlaceNameService(service, "topp:wpl_desertsplains", fileCachePath, Sector.FULL_SPHERE, GRID_5x10, java.awt.Font.decode("Arial-BOLDITALIC-10"));
placeNameService.setColor(java.awt.Color.orange);
placeNameService.setMinDisplayDistance(0d);
placeNameService.setMaxDisplayDistance(LEVEL_B);
placeNameServiceSet.addService(placeNameService, false);
}
// Lakes & Rivers
if (activeNamesList.contains(LAKESRIVERS)) {
placeNameService = new PlaceNameService(service, "topp:wpl_lakesrivers", fileCachePath, Sector.FULL_SPHERE, GRID_10x20, java.awt.Font.decode("Arial-ITALIC-10"));
placeNameService.setColor(java.awt.Color.cyan);
placeNameService.setMinDisplayDistance(0d);
placeNameService.setMaxDisplayDistance(LEVEL_C);
placeNameServiceSet.addService(placeNameService, false);
}
// Mountains & Valleys
if (activeNamesList.contains(MOUNTAINSVALLEYS)) {
placeNameService = new PlaceNameService(service, "topp:wpl_mountainsvalleys", fileCachePath, Sector.FULL_SPHERE, GRID_10x20, java.awt.Font.decode("Arial-BOLDITALIC-10"));
placeNameService.setColor(java.awt.Color.orange);
placeNameService.setMinDisplayDistance(0d);
placeNameService.setMaxDisplayDistance(LEVEL_C);
placeNameServiceSet.addService(placeNameService, false);
}
// Countries
if (activeNamesList.contains(COUNTRIES)) {
placeNameService = new PlaceNameService(service, "topp:countries", fileCachePath, Sector.FULL_SPHERE, GRID_5x10, java.awt.Font.decode("Arial-BOLD-10"));
placeNameService.setColor(java.awt.Color.white);
placeNameService.setMinDisplayDistance(LEVEL_G);
placeNameService.setMaxDisplayDistance(LEVEL_D);
placeNameServiceSet.addService(placeNameService, false);
}
// GeoNet World Capitals
if (activeNamesList.contains(GEONET_P_PPLC)) {
placeNameService = new PlaceNameService(service, "topp:wpl_geonet_p_pplc", fileCachePath, Sector.FULL_SPHERE, GRID_10x20, java.awt.Font.decode("Arial-BOLD-10"));
placeNameService.setColor(java.awt.Color.yellow);
placeNameService.setMinDisplayDistance(0d);
placeNameService.setMaxDisplayDistance(LEVEL_D);
placeNameServiceSet.addService(placeNameService, false);
}
// US Cities (Population Over 500k)
if (activeNamesList.contains(USCITIESOVER500K)) {
placeNameService = new PlaceNameService(service, "topp:wpl_uscitiesover500k", fileCachePath, usSector, GRID_10x20, java.awt.Font.decode("Arial-BOLD-10"));
placeNameService.setColor(java.awt.Color.yellow);
placeNameService.setMinDisplayDistance(LEVEL_N);
placeNameService.setMaxDisplayDistance(LEVEL_D);
placeNameServiceSet.addService(placeNameService, false);
}
// US Cities (Population Over 100k)
if (activeNamesList.contains(USCITIESOVER100K)) {
placeNameService = new PlaceNameService(service, "topp:wpl_uscitiesover100k", fileCachePath, usSector, GRID_10x20, java.awt.Font.decode("Arial-PLAIN-10"));
placeNameService.setColor(java.awt.Color.yellow);
placeNameService.setMinDisplayDistance(LEVEL_N);
placeNameService.setMaxDisplayDistance(LEVEL_F);
placeNameServiceSet.addService(placeNameService, false);
}
// US Cities (Population Over 50k)
if (activeNamesList.contains(USCITIESOVER50K)) {
placeNameService = new PlaceNameService(service, "topp:wpl_uscitiesover50k", fileCachePath, usSector, GRID_10x20, java.awt.Font.decode("Arial-PLAIN-10"));
placeNameService.setColor(java.awt.Color.yellow);
placeNameService.setMinDisplayDistance(LEVEL_N);
placeNameService.setMaxDisplayDistance(LEVEL_I);
placeNameServiceSet.addService(placeNameService, false);
}
// US Cities (Population Over 10k)
if (activeNamesList.contains(USCITIESOVER10K)) {
placeNameService = new PlaceNameService(service, "topp:wpl_uscitiesover10k", fileCachePath, usSector, GRID_10x20, java.awt.Font.decode("Arial-PLAIN-10"));
placeNameService.setColor(java.awt.Color.yellow);
placeNameService.setMinDisplayDistance(0d);
placeNameService.setMaxDisplayDistance(LEVEL_J);
placeNameServiceSet.addService(placeNameService, false);
}
// US Cities (Population Over 1k)
if (activeNamesList.contains(USCITIESOVER1K)) {
placeNameService = new PlaceNameService(service, "topp:wpl_uscitiesover1k", fileCachePath, usSector, GRID_20x40, java.awt.Font.decode("Arial-PLAIN-10"));
placeNameService.setColor(java.awt.Color.yellow);
placeNameService.setMinDisplayDistance(0d);
placeNameService.setMaxDisplayDistance(LEVEL_K);
placeNameServiceSet.addService(placeNameService, false);
}
// US Cities (Population Over 0)
if (activeNamesList.contains(USCITIESOVER0)) {
placeNameService = new PlaceNameService(service, "topp:wpl_uscitiesover0", fileCachePath, usSector, GRID_20x40, java.awt.Font.decode("Arial-PLAIN-10"));
placeNameService.setColor(java.awt.Color.yellow);
placeNameService.setMinDisplayDistance(0d);
placeNameService.setMaxDisplayDistance(LEVEL_L);
placeNameServiceSet.addService(placeNameService, false);
}
// US Cities (No Population)
if (activeNamesList.contains(USCITIES0)) {
placeNameService = new PlaceNameService(service, "topp:wpl_uscities0", fileCachePath, usSector, GRID_40x80, java.awt.Font.decode("Arial-PLAIN-10"));
placeNameService.setColor(java.awt.Color.orange);
placeNameService.setMinDisplayDistance(0d);
//M);
placeNameService.setMaxDisplayDistance(LEVEL_N);
placeNameServiceSet.addService(placeNameService, false);
}
// US Anthropogenic Features
if (activeNamesList.contains(US_ANTHROPOGENIC)) {
placeNameService = new PlaceNameService(service, "topp:wpl_us_anthropogenic", fileCachePath, usSector, GRID_80x160, java.awt.Font.decode("Arial-PLAIN-10"));
placeNameService.setColor(java.awt.Color.orange);
placeNameService.setMinDisplayDistance(0d);
placeNameService.setMaxDisplayDistance(LEVEL_P);
placeNameServiceSet.addService(placeNameService, false);
}
// US Water Features
if (activeNamesList.contains(US_WATER)) {
placeNameService = new PlaceNameService(service, "topp:wpl_us_water", fileCachePath, usSector, GRID_20x40, java.awt.Font.decode("Arial-PLAIN-10"));
placeNameService.setColor(java.awt.Color.cyan);
placeNameService.setMinDisplayDistance(0d);
placeNameService.setMaxDisplayDistance(LEVEL_N);
placeNameServiceSet.addService(placeNameService, false);
}
// US Terrain Features
if (activeNamesList.contains(US_TERRAIN)) {
placeNameService = new PlaceNameService(service, "topp:wpl_us_terrain", fileCachePath, usSector, GRID_20x40, java.awt.Font.decode("Arial-PLAIN-10"));
placeNameService.setColor(java.awt.Color.orange);
placeNameService.setMinDisplayDistance(0d);
placeNameService.setMaxDisplayDistance(LEVEL_O);
placeNameServiceSet.addService(placeNameService, false);
}
// GeoNET Administrative 1st Order
if (activeNamesList.contains(GEONET_A_ADM1)) {
placeNameService = new PlaceNameService(service, "topp:wpl_geonet_a_adm1", fileCachePath, Sector.FULL_SPHERE, GRID_20x40, java.awt.Font.decode("Arial-BOLD-10"));
placeNameService.setColor(java.awt.Color.yellow);
placeNameService.setMinDisplayDistance(0d);
placeNameService.setMaxDisplayDistance(LEVEL_N);
placeNameServiceSet.addService(placeNameService, false);
}
// GeoNET Administrative 2nd Order
if (activeNamesList.contains(GEONET_A_ADM2)) {
placeNameService = new PlaceNameService(service, "topp:wpl_geonet_a_adm2", fileCachePath, Sector.FULL_SPHERE, GRID_20x40, java.awt.Font.decode("Arial-BOLD-10"));
placeNameService.setColor(java.awt.Color.yellow);
placeNameService.setMinDisplayDistance(0d);
placeNameService.setMaxDisplayDistance(LEVEL_N);
placeNameServiceSet.addService(placeNameService, false);
}
// GeoNET Populated Place Administrative
if (activeNamesList.contains(GEONET_P_PPLA)) {
placeNameService = new PlaceNameService(service, "topp:wpl_geonet_p_ppla", fileCachePath, Sector.FULL_SPHERE, GRID_20x40, java.awt.Font.decode("Arial-BOLD-10"));
placeNameService.setColor(java.awt.Color.pink);
placeNameService.setMinDisplayDistance(0d);
placeNameService.setMaxDisplayDistance(LEVEL_N);
placeNameServiceSet.addService(placeNameService, false);
}
// GeoNET Populated Place
if (activeNamesList.contains(GEONET_P_PPL)) {
placeNameService = new PlaceNameService(service, "topp:wpl_geonet_p_ppl", fileCachePath, Sector.FULL_SPHERE, GRID_20x40, java.awt.Font.decode("Arial-PLAIN-10"));
placeNameService.setColor(java.awt.Color.pink);
placeNameService.setMinDisplayDistance(0d);
placeNameService.setMaxDisplayDistance(LEVEL_O);
placeNameServiceSet.addService(placeNameService, false);
}
return placeNameServiceSet;
}Example 19
| Project: androrat-master File: ColorPane.java View source code |
public void append(Color c, String s) {
StyleContext sc = StyleContext.getDefaultStyleContext();
AttributeSet aset = sc.addAttribute(SimpleAttributeSet.EMPTY, StyleConstants.Foreground, c);
int len = getDocument().getLength();
setCaretPosition(len);
setCharacterAttributes(aset, false);
replaceSelection(s);
}Example 20
| Project: ap-comp-science-master File: ColorComponent.java View source code |
public void paintComponent(Graphics g) {
Graphics2D g2 = (Graphics2D) g;
g2.setColor(color);
if (color != Color.LIGHT_GRAY) {
g2.fill(new Rectangle2D.Double(this.getHeight() / 2 - 6.25, this.getHeight() / 2 - 6.25, 25, 12.5));
g2.setColor(Color.BLACK);
g2.draw(new Rectangle2D.Double(this.getHeight() / 2 - 6.25, this.getHeight() / 2 - 6.25, 25, 12.5));
}
}Example 21
| Project: featurehouse_fstcomp_examples-master File: TextMessageRenderer.java View source code |
public Component getListCellRendererComponent(JList list, Object value, int index, boolean isSelected, boolean cellHasFocus) {
if (value instanceof TextMessage) {
/*if[COLOR]*/
String col = ((TextMessage) value).getSetting(Utils.COLORKEY);
if (col != null)
setForeground(new Color(Integer.parseInt(col)));
else
setForeground(Color.BLACK);
/*end[COLOR]*/
}
//return this;
return original(list, value, index, isSelected, cellHasFocus);
}Example 22
| Project: GATECH-master File: ColorUtils.java View source code |
public static Color blend(Color color1, Color color2, double ratio) { float r = (float) ratio; float ir = (float) 1.0 - r; float rgb1[] = new float[3]; float rgb2[] = new float[3]; color1.getColorComponents(rgb1); color2.getColorComponents(rgb2); Color color = new Color(rgb1[0] * r + rgb2[0] * ir, rgb1[1] * r + rgb2[1] * ir, rgb1[2] * r + rgb2[2] * ir); return color; }
Example 23
| Project: mathematorium-master File: ColorMapTest.java View source code |
/**
* @param args
*/
public static void main(String[] args) {
JFrame f = new JFrame();
f.setBounds(200, 200, 400, 70);
f.setDefaultCloseOperation(WindowConstants.EXIT_ON_CLOSE);
ColorNode[] colorNodes = { new ColorNode(Color.blue, 0), new ColorNode(Color.green, 0.3), new ColorNode(Color.yellow, 1) };
f.add(new ColorMapEditorPanel(new ColorMap(colorNodes)));
f.setVisible(true);
}Example 24
| Project: PerFabricaAdAstra-master File: ColorUtils.java View source code |
public static Color blendColors(Color from, Color to, double toFraction) { toFraction = Math.min(1.0, toFraction); double fromFraction = 1 - toFraction; return new Color((int) (from.getRed() * fromFraction + to.getRed() * toFraction), (int) (from.getGreen() * fromFraction + to.getGreen() * toFraction), (int) (from.getBlue() * fromFraction + to.getBlue() * toFraction)); }
Example 25
| Project: qingyang-master File: Main.java View source code |
public static void main(String[] args) {
ServerWindow window = new ServerWindow("清扬�务端");
window.setSize(300, 100);
window.setBackground(Color.white);
window.setVisible(true);
// try {
// ConnectServer connectServer = new ConnectServer();
// connectServer.service();
// } catch (IOException e1) {
// e1.printStackTrace();
// }
}Example 26
| Project: ToriTools-master File: ColorUtils.java View source code |
public static Color blend(Color color1, Color color2, double ratio) { float r = (float) ratio; float ir = (float) 1.0 - r; float rgb1[] = new float[3]; float rgb2[] = new float[3]; color1.getColorComponents(rgb1); color2.getColorComponents(rgb2); Color color = new Color(rgb1[0] * r + rgb2[0] * ir, rgb1[1] * r + rgb2[1] * ir, rgb1[2] * r + rgb2[2] * ir); return color; }
Example 27
| Project: xmlvm.svn-master File: SmallUiDemo.java View source code |
public static void main(String[] args) {
Frame frame = new Frame();
frame.setTitle("UI Demo");
frame.setLayout(null);
frame.setSize(new Dimension(300, 300));
frame.setBackground(Color.BLACK);
frame.setVisible(true);
ImagePanel img = new ImagePanel("doc/fireworks/star1.png");
img.setBounds(50, 50, 20, 20);
frame.add(img);
}Example 28
| Project: Jake-master File: JXStripedList.java View source code |
/**
* Compute zebra background stripe colors.
*/
private void updateZebraColors() {
if ((rowColors[0] = getBackground()) == null) {
rowColors[0] = rowColors[1] = java.awt.Color.white;
return;
}
final java.awt.Color sel = getSelectionBackground();
if (sel == null) {
rowColors[1] = rowColors[0];
return;
}
final float[] bgHSB = java.awt.Color.RGBtoHSB(rowColors[0].getRed(), rowColors[0].getGreen(), rowColors[0].getBlue(), null);
final float[] selHSB = java.awt.Color.RGBtoHSB(sel.getRed(), sel.getGreen(), sel.getBlue(), null);
rowColors[1] = java.awt.Color.getHSBColor((selHSB[1] == 0.0 || selHSB[2] == 0.0) ? bgHSB[0] : selHSB[0], 0.1f * selHSB[1] + 0.9f * bgHSB[1], bgHSB[2] + ((bgHSB[2] < 0.5f) ? 0.05f : -0.05f));
}Example 29
| Project: live-cg-master File: MonotonePiecesTriangulationPainter.java View source code |
private void drawTriangleHighlights() {
java.awt.Color a = new java.awt.Color(0x00ffffff, true);
java.awt.Color b = new java.awt.Color(0x77ffffff, true);
List<Polygon> pieces = algorithm.getMonotonePieces();
for (Polygon piece : pieces) {
SplitResult splitResult = algorithm.getSplitResult(piece);
Graph<Polygon, Diagonal> graph = splitResult.getGraph();
Map<Polygon, java.awt.Color> colorMap = AlternatingColorMapBuilder.buildColorMap(graph, a, b);
for (Polygon triangle : splitResult.getPolygons()) {
java.awt.Color color = colorMap.get(triangle);
if (color != null)
painter.setColor(new Color(color.getRGB(), true));
Polygon ttriangle = transformer.transform(triangle);
painter.fillPolygon(ttriangle);
}
}
}Example 30
| Project: hue-connector-master File: ColourUtils.java View source code |
private static Map<String, java.awt.Color> loadColourMap() { try { final Map<String, java.awt.Color> colorMap = new HashMap<String, Color>(); for (final Field f : java.awt.Color.class.getFields()) { if (f.getType() == java.awt.Color.class) { final java.awt.Color c = (java.awt.Color) f.get(null); colorMap.put(f.getName().toUpperCase(), c); } } return colorMap; } catch (final IllegalAccessException iae) { throw new RuntimeException(iae); } }
Example 31
| Project: open-mika-master File: ComponentTest.java View source code |
/*
** tests the method 'getGraphics', and the inherited 'font' and 'foreground' color
** of the resulting Graphics object.
*/
void testGetGraphics() {
harness.checkPoint("getGraphics()java.awt.Graphics");
Panel f = new Panel();
Graphics g = f.getGraphics();
harness.check(g != null, "getGraphics()java.awt.Graphics");
harness.check(g.getFont() != null, "getFont()java.awt.Font");
// equal to default
harness.check(g.getFont(), Component.DEFAULT_FONT, "getFont()java.awt.Font");
//harness.checkPoint("getColor()java.awt.Color");
harness.check(g.getColor() != null, "getColor()java.awt.Color");
harness.check(g.getColor(), new Color(0, 0, 0), "getColor()java.awt.Color");
Color color = new Color(255, 0, 0);
f.setForeground(color);
Font font = new Font("helvP14", Font.PLAIN, 18);
f.setFont(font);
// g must have remained unchanged
harness.check(g.getColor(), new Color(0, 0, 0), "getColor()java.awt.Color");
harness.check(!(g.getColor().equals(f.getForeground())), "getColor()java.awt.Color");
g.setColor(new Color(0, 255, 0));
harness.check(g.getColor(), new Color(0, 255, 0), "getColor()java.awt.Color");
//harness.checkPoint("getFont()java.awt.Font");
// equal to default font
harness.check(g.getFont(), Component.DEFAULT_FONT, "getFont()java.awt.Font");
g.setFont(new Font("helvB21", Font.BOLD, 26));
harness.check(g.getFont(), new Font("helvB21", Font.BOLD, 26), "getFont()java.awt.Font");
g = f.getGraphics();
// new g should have the new font and color.
harness.check(g.getFont(), font, "getFont()java.awt.Font");
//harness.checkPoint("getColor()java.awt.Color");
harness.check(g.getColor(), color, "getColor()java.awt.Color");
harness.check(g.getColor(), f.getForeground(), "getColor()java.awt.Color");
}Example 32
| Project: AchternEngine-master File: ColorTest.java View source code |
@Test
public void testToAwt() {
Color color0 = new Color(1, 1, 1, 1);
java.awt.Color awt0 = new java.awt.Color(1f, 1f, 1f, 1f);
Color color1 = new Color(1, 0, 0.5f, 1);
java.awt.Color awt1 = new java.awt.Color(1f, 0f, 0.5f, 1f);
Color color2 = new Color(0.1f, 0.2f, 0.3f, 0.4f);
java.awt.Color awt2 = new java.awt.Color(0.1f, 0.2f, 0.3f, 0.4f);
assertEquals("Should create a correct AWT Color object {0}", awt0, color0.toAwt());
assertEquals("Should create a correct AWT Color object {1}", awt1, color1.toAwt());
assertEquals("Should create a correct AWT Color object {2}", awt2, color2.toAwt());
}Example 33
| Project: phylowidget-master File: Color.java View source code |
public static Color parseColor(String s) { // Get rid of pesky parantheses and quotation marks s = s.replaceAll("[\"\'()]", ""); try { java.awt.Color clr = (java.awt.Color) ColorStringParser.getParser().parse(s); return new Color(clr); } catch (Exception e) { return new Color(Color.BLACK); } }
Example 34
| Project: elphelvision_eclipse-master File: MainDialogVLC.java View source code |
public void run() {
bg = new javax.swing.JPanel();
InfoPanel = new javax.swing.JPanel();
InfoTextPane = new javax.swing.JTextPane();
InfoArea_Resolution = new javax.swing.JTextPane();
Image = new javax.swing.JLabel();
InfoArea_FPS = new javax.swing.JTextPane();
Image2 = new javax.swing.JLabel();
InfoArea_WB = new javax.swing.JTextPane();
InfoArea_Quality = new javax.swing.JTextPane();
Image3 = new javax.swing.JLabel();
InfoArea_HDD = new javax.swing.JTextPane();
setBackground(Color.BLACK);
setForeground(new java.awt.Color(255, 255, 255));
setLayout(new BorderLayout(0, 0));
bg.setBackground(new java.awt.Color(5, 50, 5));
bg.setPreferredSize(new java.awt.Dimension(1024, 600));
add(bg);
bg.setLayout(new MigLayout("", "[50.00px][grow][]", "[83px][grow][]"));
SliderPanel = new javax.swing.JPanel();
SliderPanel.setMaximumSize(new Dimension(50, 32767));
SliderPanel.setSize(new Dimension(50, 300));
SliderPanel.setPreferredSize(new Dimension(50, 300));
bg.add(SliderPanel, "cell 0 1,alignx left,aligny top");
SliderPanel.setBackground(new java.awt.Color(0, 0, 0));
SliderPanel.setLayout(new java.awt.CardLayout());
GainPanel = new javax.swing.JPanel();
GainPanel.setMaximumSize(new Dimension(50, 32767));
SliderPanel.add(GainPanel, "GainPanel");
twelvedb = new EButton(Parent);
threedb = new EButton(Parent);
GainPanel.setBackground(new java.awt.Color(0, 0, 0));
twelvedb.setText("+12dB");
twelvedb.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
twelvedbActionPerformed(evt);
}
});
incvalue1 = new EButton(Parent);
incvalue1.setText("+");
incvalue1.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
incvalue1ActionPerformed(evt);
}
});
GainPanel.add(incvalue1);
GainPanel.add(twelvedb);
ninedb = new EButton(Parent);
ninedb.setText("+9dB");
ninedb.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
ninedbActionPerformed(evt);
}
});
GainPanel.add(ninedb);
sixdb = new EButton(Parent);
sixdb.setText("+6dB");
sixdb.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
sixdbActionPerformed(evt);
}
});
GainPanel.add(sixdb);
threedb.setText("+3dB");
threedb.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
threedbActionPerformed(evt);
}
});
GainPanel.add(threedb);
GainPanel.setBackground(Parent.Settings.GetPanelBackgroundColor());
decvalue1 = new EButton(Parent);
decvalue1.setText("‒");
decvalue1.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
decvalue1ActionPerformed(evt);
}
});
zerodb = new EButton(Parent);
zerodb.setText("0dB");
zerodb.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
zerodbActionPerformed(evt);
}
});
GainPanel.add(zerodb);
GainPanel.add(decvalue1);
ShutterPanel = new javax.swing.JPanel();
ShutterPanel.setMaximumSize(new Dimension(50, 32767));
SliderPanel.add(ShutterPanel, "name_7314624474539");
incvalue2 = new EButton(Parent);
incvalue2.setPreferredSize(new Dimension(50, 35));
decvalue3 = new EButton(Parent);
decvalue3.setPreferredSize(new Dimension(50, 35));
ShutterPanel.setPreferredSize(new java.awt.Dimension(50, 480));
incvalue2.setText("+");
incvalue2.setAlignmentY(0.0F);
incvalue2.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
incvalue2ActionPerformed(evt);
}
});
ShutterPanel.add(incvalue2);
decvalue3.setText("‒");
decvalue3.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
decvalue3ActionPerformed(evt);
}
});
ShutterPanel.add(decvalue3);
ShutterPanel.setBackground(Parent.Settings.GetPanelBackgroundColor());
slowshutter = new EButton(Parent);
slowshutter.setPreferredSize(new Dimension(50, 35));
slowshutter.setText("slow\\nshutter");
slowshutter.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
slowshutterActionPerformed(evt);
}
});
ShutterPanel.add(slowshutter);
VideoFrame = new javax.swing.JPanel();
VideoFrame.setPreferredSize(new Dimension(600, 400));
VideoFrame.setBorder(javax.swing.BorderFactory.createLineBorder(new java.awt.Color(100, 100, 100)));
VideoFrame.setDoubleBuffered(false);
VideoFrame.setOpaque(false);
VideoFrame.setLayout(new javax.swing.BoxLayout(VideoFrame, javax.swing.BoxLayout.LINE_AXIS));
bg.add(VideoFrame, "cell 1 1,grow");
vlcoverlay = new java.awt.Canvas();
vlcoverlay.setPreferredSize(new Dimension(400, 280));
VideoFrame.add(vlcoverlay);
vlcoverlay.setBackground(new java.awt.Color(0, 0, 0));
QuickPanel = new javax.swing.JPanel();
QuickPanel.setMinimumSize(new Dimension(80, 430));
QuickPanel.setPreferredSize(new Dimension(80, 430));
QuickPanel.setMaximumSize(new Dimension(80, 32767));
eButton3 = new EButton(Parent);
eButton4 = new EButton(Parent);
eButton6 = new EButton(Parent);
eButton8 = new EButton(Parent);
eButton9 = new EButton(Parent);
DatarateMonitor = new DatarateMonitor();
LiveVideoButton = new EButton(Parent);
QuickPanel.setBackground(new java.awt.Color(0, 0, 0));
eButton3.setText("fit");
eButton3.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
eButton3ActionPerformed(evt);
}
});
eButton4.setText("1:1");
eButton4.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
eButton4ActionPerformed(evt);
}
});
eButton6.setText("RGB");
eButton6.setToolTipText("RGB 24bit color mode");
eButton6.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
eButton6ActionPerformed(evt);
}
});
eButton8.setText("JP46 RAW");
eButton8.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
eButton8ActionPerformed(evt);
}
});
eButton9.setText("JP4 RAW");
eButton9.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
eButton9ActionPerformed(evt);
}
});
DatarateMonitor.setBackground(new java.awt.Color(0, 0, 0));
DatarateMonitor.setPreferredSize(new java.awt.Dimension(90, 40));
javax.swing.GroupLayout gl_DatarateMonitor = new javax.swing.GroupLayout(DatarateMonitor);
DatarateMonitor.setLayout(gl_DatarateMonitor);
gl_DatarateMonitor.setHorizontalGroup(gl_DatarateMonitor.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGap(0, 90, Short.MAX_VALUE));
gl_DatarateMonitor.setVerticalGroup(gl_DatarateMonitor.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGap(0, 40, Short.MAX_VALUE));
LiveVideoButton.setText("Camera 1");
LiveVideoButton.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
LiveVideoButtonActionPerformed(evt);
}
});
bg.add(QuickPanel, "cell 2 1,alignx left,aligny center");
QuickPanel.setLayout(new FlowLayout(FlowLayout.CENTER, 5, 5));
ScaleLabel = new javax.swing.JLabel();
ScaleLabel.setFont(new java.awt.Font("DejaVu Sans", 0, 12));
ScaleLabel.setForeground(new java.awt.Color(255, 255, 255));
ScaleLabel.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
ScaleLabel.setText("Scaling");
ScaleLabel.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
QuickPanel.add(ScaleLabel);
eButton1 = new EButton(Parent);
eButton1.setText("2:1");
eButton1.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
eButton1ActionPerformed(evt);
}
});
QuickPanel.add(eButton1);
QuickPanel.add(eButton4);
QuickPanel.add(eButton3);
QuickPanel.add(LiveVideoButton);
QuickPanel.add(DatarateMonitor);
ColorModeLabel1 = new javax.swing.JLabel();
QuickPanel.add(ColorModeLabel1);
// NOI18N
ColorModeLabel1.setFont(new java.awt.Font("DejaVu Sans", 0, 12));
ColorModeLabel1.setForeground(new java.awt.Color(255, 255, 255));
ColorModeLabel1.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
ColorModeLabel1.setText("Rec-Buffer");
ColorModeLabel1.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
BufferMonitor = new BufferMonitor();
QuickPanel.add(BufferMonitor);
BufferMonitor.setBackground(java.awt.Color.black);
BufferMonitor.setForeground(new java.awt.Color(255, 255, 255));
javax.swing.GroupLayout gl_BufferMonitor = new javax.swing.GroupLayout(BufferMonitor);
BufferMonitor.setLayout(gl_BufferMonitor);
gl_BufferMonitor.setHorizontalGroup(gl_BufferMonitor.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGap(0, 90, Short.MAX_VALUE));
gl_BufferMonitor.setVerticalGroup(gl_BufferMonitor.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGap(0, 40, Short.MAX_VALUE));
ColorModeLabel = new javax.swing.JLabel();
ColorModeLabel.setForeground(new java.awt.Color(255, 255, 255));
ColorModeLabel.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
ColorModeLabel.setText("Color-Mode");
ColorModeLabel.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
QuickPanel.add(ColorModeLabel);
QuickPanel.add(eButton9);
QuickPanel.add(eButton8);
QuickPanel.add(eButton6);
QuickPanel.setBackground(Parent.Settings.GetPanelBackgroundColor());
ScaleLabel.setForeground(Parent.Settings.GetTextColor());
ColorModeLabel.setForeground(Parent.Settings.GetTextColor());
DatarateMonitor.setBackground(Parent.Settings.GetPanelBackgroundColor());
DatarateMonitor.setForeground(Parent.Settings.GetTextColor());
InfoPanel.setBackground(new java.awt.Color(0, 0, 0));
InfoPanel.setLayout(new FlowLayout(FlowLayout.CENTER, 5, 5));
InfoTextPane.setBackground(new java.awt.Color(0, 0, 0));
InfoTextPane.setForeground(new java.awt.Color(255, 255, 255));
InfoTextPane.setDoubleBuffered(true);
InfoTextPane.setFocusable(false);
InfoPanel.add(InfoTextPane);
InfoArea_Resolution.setBackground(new java.awt.Color(0, 0, 0));
InfoArea_Resolution.setForeground(new java.awt.Color(255, 255, 255));
InfoArea_Resolution.setText("Resolution");
InfoArea_Resolution.setDoubleBuffered(true);
InfoArea_Resolution.setFocusable(false);
InfoPanel.add(InfoArea_Resolution);
Image.setBackground(new java.awt.Color(0, 0, 0));
Image.setFont(new java.awt.Font("Tahoma", 0, 14));
Image.setForeground(new java.awt.Color(255, 255, 255));
Image.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
// NOI18N
Image.setIcon(new javax.swing.ImageIcon(getClass().getResource("/media/divider01.png")));
InfoPanel.add(Image);
InfoArea_FPS.setBackground(new java.awt.Color(0, 0, 0));
InfoArea_FPS.setForeground(new java.awt.Color(255, 255, 255));
InfoArea_FPS.setText("FPS");
InfoArea_FPS.setDoubleBuffered(true);
InfoArea_FPS.setFocusable(false);
InfoPanel.add(InfoArea_FPS);
Image2.setBackground(new java.awt.Color(0, 0, 0));
Image2.setFont(new java.awt.Font("Tahoma", 0, 14));
Image2.setForeground(new java.awt.Color(255, 255, 255));
Image2.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
// NOI18N
Image2.setIcon(new javax.swing.ImageIcon(getClass().getResource("/media/divider01.png")));
InfoPanel.add(Image2);
InfoArea_WB.setBackground(new java.awt.Color(0, 0, 0));
InfoArea_WB.setForeground(new java.awt.Color(255, 255, 255));
InfoArea_WB.setText("WB");
InfoArea_WB.setDoubleBuffered(true);
InfoArea_WB.setFocusable(false);
InfoPanel.add(InfoArea_WB);
Image1 = new javax.swing.JLabel();
Image1.setBackground(new java.awt.Color(0, 0, 0));
Image1.setFont(new java.awt.Font("Tahoma", 0, 14));
Image1.setForeground(new java.awt.Color(255, 255, 255));
Image1.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
// NOI18N
Image1.setIcon(new javax.swing.ImageIcon(getClass().getResource("/media/divider01.png")));
InfoPanel.add(Image1);
InfoArea_Quality.setBackground(new java.awt.Color(0, 0, 0));
InfoArea_Quality.setForeground(new java.awt.Color(255, 255, 255));
InfoArea_Quality.setText("Quality");
InfoArea_Quality.setDoubleBuffered(true);
InfoArea_Quality.setFocusable(false);
InfoPanel.add(InfoArea_Quality);
Image3.setBackground(new java.awt.Color(0, 0, 0));
Image3.setFont(new java.awt.Font("Tahoma", 0, 14));
Image3.setForeground(new java.awt.Color(255, 255, 255));
Image3.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
// NOI18N
Image3.setIcon(new javax.swing.ImageIcon(getClass().getResource("/media/divider01.png")));
InfoPanel.add(Image3);
InfoArea_HDD.setBackground(new java.awt.Color(0, 0, 0));
InfoArea_HDD.setForeground(new java.awt.Color(255, 255, 255));
InfoArea_HDD.setText("HDD");
InfoArea_HDD.setDoubleBuffered(true);
InfoArea_HDD.setFocusable(false);
InfoPanel.add(InfoArea_HDD);
bg.add(InfoPanel, "cell 0 0 2 1,alignx center,aligny center");
bg.setBackground(Parent.Settings.GetPanelBackgroundColor());
InfoPanel.setBackground(Parent.Settings.GetPanelBackgroundColor());
InfoTextPane.setBackground(Parent.Settings.GetPanelBackgroundColor());
InfoTextPane.setForeground(Parent.Settings.GetTextColor());
Image4 = new javax.swing.JLabel();
Image4.setBackground(new java.awt.Color(0, 0, 0));
Image4.setFont(new java.awt.Font("Tahoma", 0, 14));
Image4.setForeground(new java.awt.Color(255, 255, 255));
Image4.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
// NOI18N
Image4.setIcon(new javax.swing.ImageIcon(getClass().getResource("/media/divider01.png")));
InfoPanel.add(Image4);
InfoArea_Record = new javax.swing.JTextPane();
InfoArea_Record.setBackground(new java.awt.Color(0, 0, 0));
InfoArea_Record.setForeground(new java.awt.Color(255, 255, 255));
InfoArea_Record.setText("Record");
InfoArea_Record.setDoubleBuffered(true);
InfoArea_Record.setFocusable(false);
InfoPanel.add(InfoArea_Record);
NoticeArea = new javax.swing.JTextPane();
NoticeArea.setBackground(new java.awt.Color(0, 0, 0));
NoticeArea.setForeground(new java.awt.Color(254, 54, 54));
NoticeArea.setText("loading...");
NoticeArea.setDoubleBuffered(true);
NoticeArea.setFocusable(false);
InfoPanel.add(NoticeArea);
NoticeArea.setBackground(Parent.Settings.GetPanelBackgroundColor());
ParameterPanel = new javax.swing.JPanel();
ExposureButton = new EButton(Parent);
GainButton = new EButton(Parent);
histogram = new Histogram();
CaptureStill = new EButton(Parent);
CaptureStill.setSize(new Dimension(50, 35));
RecordButton = new EButton(Parent);
ParameterPanel.setBackground(new java.awt.Color(0, 0, 0));
ExposureButton.setText("Shutter");
ExposureButton.setAlignmentY(0.0F);
ExposureButton.setHorizontalAlignment(javax.swing.SwingConstants.LEFT);
ExposureButton.setHorizontalTextPosition(javax.swing.SwingConstants.LEFT);
ExposureButton.setIconTextGap(0);
ExposureButton.setMargin(new java.awt.Insets(0, 5, 0, 0));
ExposureButton.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
ExposureButtonActionPerformed(evt);
}
});
ParameterPanel.setLayout(new FlowLayout(FlowLayout.CENTER, 5, 5));
SettingsButton = new EButton(Parent);
SettingsButton.setBackground(new java.awt.Color(255, 255, 255));
// NOI18N
SettingsButton.setIconImage(getClass().getResource("/media/settings.png"));
SettingsButton.setPreferredSize(new Dimension(45, 45));
SettingsButton.setToolTipText("Settings");
SettingsButton.setAlignmentY(0.0F);
SettingsButton.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
SettingsButton.setIconTextGap(0);
SettingsButton.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
SettingsButtonActionPerformed(evt);
}
});
ParameterPanel.add(SettingsButton);
ParameterPanel.add(ExposureButton);
GainButton.setText("Gain");
GainButton.setAlignmentY(0.0F);
GainButton.setHorizontalAlignment(javax.swing.SwingConstants.LEFT);
GainButton.setHorizontalTextPosition(javax.swing.SwingConstants.LEFT);
GainButton.setIconTextGap(20);
GainButton.setMargin(new java.awt.Insets(0, 5, 0, 0));
GainButton.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
GainButtonActionPerformed(evt);
}
});
ParameterPanel.add(GainButton);
histogram.setBackground(new java.awt.Color(0, 0, 0));
histogram.setPreferredSize(new java.awt.Dimension(256, 50));
histogram.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
histogramMouseClicked(evt);
}
});
PlaybackButton = new EButton(Parent);
PlaybackButton.setText("Playback");
PlaybackButton.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
PlaybackButtonActionPerformed(evt);
}
});
ParameterPanel.add(PlaybackButton);
AudioRec = new EButton(Parent);
AudioRec.setText("Audio Rec");
AudioRec.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
AudioRecActionPerformed(evt);
}
});
audioMonitor1 = new AudioMonitor(Parent);
audioMonitor1.setBackground(new java.awt.Color(0, 0, 0));
audioMonitor1.setForeground(new java.awt.Color(166, 166, 166));
audioMonitor1.setPreferredSize(new java.awt.Dimension(27, 60));
javax.swing.GroupLayout gl_audioMonitor1 = new javax.swing.GroupLayout(audioMonitor1);
audioMonitor1.setLayout(gl_audioMonitor1);
gl_audioMonitor1.setHorizontalGroup(gl_audioMonitor1.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGap(0, 18, Short.MAX_VALUE));
gl_audioMonitor1.setVerticalGroup(gl_audioMonitor1.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGap(0, 50, Short.MAX_VALUE));
ParameterPanel.add(audioMonitor1);
ParameterPanel.add(AudioRec);
javax.swing.GroupLayout gl_histogram = new javax.swing.GroupLayout(histogram);
gl_histogram.setHorizontalGroup(gl_histogram.createParallelGroup(Alignment.LEADING).addGap(0, 612, Short.MAX_VALUE));
gl_histogram.setVerticalGroup(gl_histogram.createParallelGroup(Alignment.LEADING).addGap(0, 505, Short.MAX_VALUE));
histogram.setLayout(gl_histogram);
ParameterPanel.add(histogram);
CaptureStill.setText("Still");
CaptureStill.setIconTextGap(0);
CaptureStill.setPreferredSize(new Dimension(50, 35));
CaptureStill.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
CaptureStillActionPerformed(evt);
}
});
ParameterPanel.add(CaptureStill);
RecordButton.setForeground(new java.awt.Color(255, 0, 0));
RecordButton.setText("Record");
RecordButton.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
RecordButtonActionPerformed(evt);
}
});
ParameterPanel.add(RecordButton);
bg.add(ParameterPanel, "cell 0 2 3 1,growx,aligny top");
ParameterPanel.setBackground(Parent.Settings.GetPanelBackgroundColor());
}Example 35
| Project: openmap-master File: ColorFactory.java View source code |
/** * Convert a string representing a 24/32bit hex color value into a Color * value. NOTE: * <ul> * <li>Only 24bit (RGB) java.awt.Color is supported on the JDK 1.1 platform. * <li>Both 24/32bit (ARGB) java.awt.Color is supported on the Java 2 * platform. * </ul> * * @param colorString * the 24/32bit hex string value (ARGB) * @param forceAlpha * force using alpha value * @return java.awt.Color (24bit RGB on JDK 1.1, 24/32bit ARGB on JDK1.2) * @exception NumberFormatException * if the specified string cannot be interpreted as a * hexidecimal integer * @see #createColor(int, boolean) */ public static Color parseColor(String colorString, boolean forceAlpha) throws NumberFormatException { int value; // If we come across people who do one letter per color. if (colorString.length() == 3) { colorString = new StringBuilder().append(colorString.charAt(0)).append(colorString.charAt(0)).append(colorString.charAt(1)).append(colorString.charAt(1)).append(colorString.charAt(2)).append(colorString.charAt(2)).toString(); } try { value = (int) Long.parseLong(colorString, 16); } catch (NumberFormatException nfe) { value = Long.decode(colorString).intValue(); } // transparent. if (colorString.length() < 7 && !colorString.equals("0")) { // Just a RGB value, use regular JDK1.1 constructor return new Color(value); } return createColor(value, forceAlpha); }
Example 36
| Project: aetheria-master File: ServerLogWindow.java View source code |
//(los logs de partida escriben mediante InputOutputClients)
public //escribe sólo en el general
void writeGeneral(//escribe sólo en el general
String s) {
//prefijar líneas con "general" y colorearlas de amarillo
MutableAttributeSet atributos = new SimpleAttributeSet();
try {
StyleConstants.setForeground(atributos, new Color(Integer.parseInt("FFFF00", 16)));
} catch (NumberFormatException nfe) {
}
/*
String newText = tpGeneral.getText();
if ( newText.length() > 0 && ( newText.charAt ( newText.length() - 1 ) != '\n' ) )
newText += "\n";
*/
String toAppend = "[General] " + s.trim();
try {
String curText = tpGeneral.getText();
if (curText.length() > 0 && (curText.charAt(curText.length() - 1) != '\n'))
tpGeneral.getDocument().insertString(tpGeneral.getText().length(), "\n", null);
tpGeneral.getDocument().insertString(tpGeneral.getText().length(), toAppend, atributos);
Debug.println("BY ORBITAL\n");
} catch (BadLocationException ble) {
System.err.println(ble);
}
}Example 37
| Project: gantt-master File: CssColorToColorPickerConverter.java View source code |
@Override public Result<Color> convertToModel(String value, ValueContext context) { if (value == null || value.trim().isEmpty()) { return Result.ok(Color.WHITE); } value = value.trim(); if (!value.startsWith("#") && !value.startsWith("0x")) { value = "#" + value; } try { java.awt.Color c = java.awt.Color.decode(value); return Result.ok(new Color(c.getRed(), c.getGreen(), c.getBlue(), c.getAlpha())); } catch (NumberFormatException e) { e.printStackTrace(); } return Result.ok(Color.WHITE); }
Example 38
| Project: glug-master File: FineCrosshairMouseCursorFactory.java View source code |
public Cursor createFineCrosshairMouseCursor() {
Toolkit toolkit = Toolkit.getDefaultToolkit();
Dimension bestCursorSize = toolkit.getBestCursorSize(24, 24);
BufferedImage cursorImage = new BufferedImage(bestCursorSize.width, bestCursorSize.height, BufferedImage.TYPE_INT_ARGB);
Point hotSpot = new Point(bestCursorSize.width / 2, bestCursorSize.height / 2);
Graphics2D graphics = cursorImage.createGraphics();
graphics.translate(hotSpot.x, hotSpot.y);
Color colour = DARK_GRAY;
for (int point = 2; point < hotSpot.x; point += 2) {
graphics.setColor(colour);
colour = colour.brighter();
graphics.drawLine(point, -1, point, 1);
graphics.drawLine(-1, point, 1, point);
graphics.drawLine(-point, -1, -point, 1);
graphics.drawLine(-1, -point, 1, -point);
}
return toolkit.createCustomCursor(cursorImage, hotSpot, "fine-crosshair");
}Example 39
| Project: jacorb-master File: FillLevelCanvas.java View source code |
public void paintUnbuffered(java.awt.Graphics g) {
if (useAvg) {
if (cur <= avg) {
g.setColor(color1);
g.fillRect(0, yCur, width, height - yCur);
} else {
g.setColor(color2);
g.fillRect(0, yCur, width, height - yCur);
g.setColor(color1);
g.fillRect(0, yAvg, width, height - yAvg);
}
if (avg < max) {
g.setColor(java.awt.Color.black);
g.drawLine(0, yAvg, width, yAvg);
}
} else {
g.setColor(color1);
g.fillRect(0, yCur, width, height - yCur);
}
}Example 40
| Project: robombs-master File: IconPainter.java View source code |
private void paintWater(FrameBuffer fb, int value, int max) {
Texture box = TextureManager.getInstance().getTexture("barbox");
fb.blit(box, 0, 0, fb.getOutputWidth() - 5 - 64, fb.getOutputHeight() - 5 - 16, 64, 16, true);
box = TextureManager.getInstance().getTexture("bar");
java.awt.Color col = null;
if (value != max) {
col = java.awt.Color.RED;
}
fb.blit(box, 1, 0, fb.getOutputWidth() - 5 - 62, fb.getOutputHeight() - 5 - 14, 14, 16, (int) (60f * (float) value / (float) max), 12, 12, false, col);
}Example 41
| Project: aorra-master File: AbstractProgressTableBuilder.java View source code |
@Override public Map<java.awt.Color, ProgressTable.Condition> load(SpreadsheetDataSource ds) { final Map<java.awt.Color, ProgressTable.Condition> m = Maps.newHashMap(); try { for (int row = 0; ; row++) { final Value v = ds.select("condition", row, 0); if (StringUtils.isBlank(v.asString())) { break; } m.put(v.asColor(), getCondition(v.asString())); } } catch (MissingDataException e) { } return m; }
Example 42
| Project: Aspose_BarCode_Java-master File: AsposeAPI.java View source code |
public static void createAsposeBarCode(String billAmount, ServletOutputStream out, String symbology) {
BarCodeBuilder bb = new BarCodeBuilder();
// Set up code text (data to be encoded)
bb.setCodeText(billAmount);
// Set up code text color
bb.setCodeTextColor(java.awt.Color.RED);
// Set the location of the code text to above the barcode
bb.setCodeLocation(CodeLocation.Above);
// Increase the space between code text and barcode to 1 point
bb.setCodeTextSpace(1.0f);
// Set the symbology type
bb.setSymbologyType(Long.valueOf(symbology));
bb.save(out, BarCodeImageFormat.Png);
}Example 43
| Project: ceres-master File: ClassConverterTest.java View source code |
@Override
public void testConverter() throws ConversionException {
testValueType(Class.class);
testParseSuccess(Character.TYPE, "char");
testParseSuccess(Boolean.TYPE, "boolean");
testParseSuccess(Byte.TYPE, "byte");
testParseSuccess(Short.TYPE, "short");
testParseSuccess(Integer.TYPE, "int");
testParseSuccess(Float.TYPE, "float");
testParseSuccess(Double.TYPE, "double");
testFormatSuccess("char", Character.TYPE);
testFormatSuccess("boolean", Boolean.TYPE);
testFormatSuccess("byte", Byte.TYPE);
testFormatSuccess("short", Short.TYPE);
testFormatSuccess("int", Integer.TYPE);
testFormatSuccess("float", Float.TYPE);
testFormatSuccess("double", Double.TYPE);
testParseSuccess(Integer.class, "Integer");
testParseSuccess(Float.class, "Float");
testParseSuccess(String.class, "String");
testFormatSuccess("Integer", Integer.class);
testFormatSuccess("Float", Float.class);
testFormatSuccess("String", String.class);
testParseSuccess(java.awt.Color.class, "java.awt.Color");
testParseSuccess(java.util.Date.class, "java.util.Date");
testParseSuccess(org.w3c.dom.Text.class, "org.w3c.dom.Text");
testParseSuccess(null, "");
testFormatSuccess("java.awt.Color", java.awt.Color.class);
testFormatSuccess("java.util.Date", java.util.Date.class);
testFormatSuccess("org.w3c.dom.Text", org.w3c.dom.Text.class);
testFormatSuccess("", null);
testParseFailed("Int");
testParseFailed("you.will.be.Assimilated");
assertNullCorrectlyHandled();
}Example 44
| Project: edu-master File: Bitmap.java View source code |
public static Raster of(Component c) throws Exception {
BufferedImage image = new BufferedImage(c.getWidth(), c.getHeight(), BufferedImage.TYPE_INT_RGB);
Graphics2D graphics = image.createGraphics();
graphics.setColor(Color.WHITE);
graphics.fillRect(0, 0, c.getWidth(), c.getHeight());
c.paint(graphics);
graphics.dispose();
return image.getRaster();
}Example 45
| Project: fastjson-master File: ColorTest.java View source code |
public void test_color() throws Exception {
JSONSerializer serializer = new JSONSerializer();
Assert.assertEquals(AwtCodec.class, serializer.getObjectWriter(Color.class).getClass());
Color color = Color.RED;
String text = JSON.toJSONString(color);
System.out.println(text);
Color color2 = JSON.parseObject(text, Color.class);
Assert.assertEquals(color, color2);
}Example 46
| Project: geoserver-old-master File: CoverageUtilsTest.java View source code |
public void testGetOutputTransparentColor() {
ParameterDescriptor<Color> pdescriptor = ImageMosaicFormat.OUTPUT_TRANSPARENT_COLOR;
ParameterValue<Color> pvalue = pdescriptor.createValue();
String key = pdescriptor.getName().getCode();
Map values = Collections.singletonMap(key, "0xFFFFFF");
Object value = CoverageUtils.getCvParamValue(key, pvalue, values);
assertTrue(value instanceof Color);
assertEquals(Color.WHITE, value);
}Example 47
| Project: geoserver_trunk-master File: CoverageUtilsTest.java View source code |
public void testGetOutputTransparentColor() {
ParameterDescriptor<Color> pdescriptor = ImageMosaicFormat.OUTPUT_TRANSPARENT_COLOR;
ParameterValue<Color> pvalue = pdescriptor.createValue();
String key = pdescriptor.getName().getCode();
Map values = Collections.singletonMap(key, "0xFFFFFF");
Object value = CoverageUtils.getCvParamValue(key, pvalue, values);
assertTrue(value instanceof Color);
assertEquals(Color.WHITE, value);
}Example 48
| Project: japura-gui-master File: FillCollapsibleRootPanel.java View source code |
@Override
protected Component buildExampleComponent() {
CollapsibleRootPanel crp = new CollapsibleRootPanel(CollapsibleRootPanel.FILL);
crp.setBorder(BorderFactory.createLineBorder(Color.GRAY));
crp.add(CollapsiblePanelBuilder.buildFindCollapsiblePanel(), 0);
crp.add(CollapsiblePanelBuilder.buildMarketCollapsiblePanel(), 1);
crp.add(CollapsiblePanelBuilder.buildSettingsCollapsiblePanel(), 1);
return crp;
}Example 49
| Project: jersey-old-master File: ColorParam.java View source code |
private static int getRGB(String s) {
if (s.charAt(0) == '#') {
try {
Color c = Color.decode("0x" + s.substring(1));
return c.getRGB();
} catch (NumberFormatException e) {
throw new WebApplicationException(400);
}
} else {
try {
Field f = Color.class.getField(s);
return ((Color) f.get(null)).getRGB();
} catch (Exception e) {
throw new WebApplicationException(400);
}
}
}Example 50
| Project: JFeatureLib-master File: SurfTest.java View source code |
@Test
public void testRun() {
ImageProcessor ip = new ColorProcessor(100, 100);
ip.setColor(Color.black);
ip.fill();
ip.setColor(Color.white);
ip.fillOval(30, 30, 40, 40);
SURF f = new SURF();
f.run(ip);
List<double[]> features = f.getFeatures();
assertEquals(9, features.size());
assertEquals(70, features.get(0).length);
assertEquals(70, features.get(1).length);
}Example 51
| Project: jif-master File: ImageLoadingError.java View source code |
public static BufferedImage getImageLoadingError(Dimension imgDim) {
BufferedImage bi;
bi = new BufferedImage(imgDim.width, imgDim.height, BufferedImage.TYPE_INT_RGB);
bi.getGraphics().setColor(Color.WHITE);
bi.getGraphics().drawString("IMAGE", 20, 20);
bi.getGraphics().drawString("LOADING", 20, 40);
bi.getGraphics().drawString("ERROR", 20, 60);
return bi;
}Example 52
| Project: olca-modules-master File: DQColors.java View source code |
static Color get(int index, int total) { if (index == 0) return new Color(255, 255, 255); if (index == 1) return new Color(125, 250, 125); if (index == total) return new Color(250, 125, 125); int median = total / 2 + 1; if (index == median) return new Color(250, 250, 125); if (index < median) { int divisor = median - 1; int factor = index - 1; return new Color(125 + (125 * factor / divisor), 250, 125); } int divisor = median - 1; int factor = index - median; return new Color(250, 250 - (125 * factor / divisor), 125); }
Example 53
| Project: old_java_assignments_and_projects-master File: DerekTarget6.java View source code |
public void run() {
setColors(Color.BLACK, Color.DARK_GRAY, Color.BLACK, Color.RED, Color.RED);
turnTo(90);
if (getX() < (getBattleFieldWidth() / 2)) {
turnGunLeft(180);
ahead((getX() - getBattleFieldWidth()));
} else {
ahead(getBattleFieldWidth() - getX());
}
turnTo(180);
ahead(getBattleFieldHeight() - (getBattleFieldHeight() - getX()));
turnTo(0);
turnGunLeft(90);
ahead(getBattleFieldHeight());
while (true) {
ahead(200);
if (getY() > 580) {
turnGunRight(180);
ahead(-getBattleFieldHeight());
turnGunRight(180);
}
}
}Example 54
| Project: project-bacon-master File: NumberLabel.java View source code |
public void setValue(double d) {
if (allowDecimal) {
formatter = new DecimalFormat("#,###,###,##0.00");
} else {
formatter = new DecimalFormat("#,###,###,###");
}
setText(formatter.format(d) + suffix);
//Set font color.
if (d < 0) {
setForeground(Color.RED);
} else {
setForeground(Color.BLACK);
}
}Example 55
| Project: rrd4j-master File: TimeAxisText.java View source code |
@Test
public void firstTest() throws IOException {
createGaugeRrd(100);
prepareGraph();
imageWorker.drawString("06:00", 132, 125, FontConstructor.getFont(Font.PLAIN, 10), java.awt.Color.BLACK);
imageWorker.drawString("12:00", 232, 125, FontConstructor.getFont(Font.PLAIN, 10), java.awt.Color.BLACK);
imageWorker.drawString("18:00", 332, 125, FontConstructor.getFont(Font.PLAIN, 10), java.awt.Color.BLACK);
imageWorker.drawString("00:00", 432, 125, FontConstructor.getFont(Font.PLAIN, 10), java.awt.Color.BLACK);
replay(imageWorker);
timeAxis.draw();
//Validate the calls to the imageWorker
verify(imageWorker);
}Example 56
| Project: scriptographer-master File: ColorConverter.java View source code |
public Color convert(ArgumentReader reader, Object from) { // can behave like arrays as well), always check for isString first! if (reader.isString()) { String name = reader.readString(); if ("".equals(name)) return Color.NONE; try { // Try hex string first String str = name.startsWith("#") ? name : "#" + name; return new RGBColor(java.awt.Color.decode(str)); } catch (Exception e1) { try { Field field = java.awt.Color.class.getField(name.toUpperCase()); return new RGBColor((java.awt.Color) field.get(java.awt.Color.class)); } catch (Exception e2) { } } } else if (reader.isArray()) { int size = reader.size(); if (size == 4) { // CMYK return new CMYKColor(reader.readFloat(0), reader.readFloat(0), reader.readFloat(0), reader.readFloat(0)); } else if (size == 3) { // RGB return new RGBColor(reader.readFloat(0), reader.readFloat(0), reader.readFloat(0)); } else if (size == 1) { // Gray return new GrayColor(reader.readFloat(0)); } } else if (reader.isMap()) { if (reader.has("red")) { return new RGBColor(reader.readFloat("red", 0), reader.readFloat("green", 0), reader.readFloat("blue", 0), reader.readFloat("alpha", 1)); } else if (reader.has("cyan")) { return new CMYKColor(reader.readFloat("cyan", 0), reader.readFloat("magenta", 0), reader.readFloat("yellow", 0), reader.readFloat("black", 0), reader.readFloat("alpha", 1)); } else if (reader.has("gray")) { return new GrayColor(reader.readFloat("gray", 0), reader.readFloat("alpha", 1)); } } return null; }
Example 57
| Project: SmartTools-master File: DeviceListRender.java View source code |
@Override
public Component getListCellRendererComponent(JList list, Object value, int index, boolean isSelected, boolean cellHasFocus) {
setOpaque(isSelected);
setIcon(Utils.getResImage("res/device.png"));
if (isSelected) {
setBackground(Color.WHITE);
setForeground(Color.BLACK);
} else {
setForeground(Color.WHITE);
}
setText(value == null ? "" : value.toString());
return this;
}Example 58
| Project: helixsoft-commons-master File: ColorConverter.java View source code |
/**
* Parses a string representing a {@link Color} object created with {@link #getRgbString(Color)}
* @param rgbString the string to be parsed
* @return the {@link Color} object this string represented
*/
public static java.awt.Color parseColorString(String colorString) {
String[] s = colorString.split(",");
try {
return new java.awt.Color(Integer.parseInt(s[0]), Integer.parseInt(s[1]), Integer.parseInt(s[2]));
} catch (Exception e) {
throw new IllegalArgumentException("Unable to parse color from '" + colorString + "'", e);
}
}Example 59
| Project: pegadi-master File: ArticleStatusServerImpl.java View source code |
public ArticleStatus mapRow(ResultSet rs, int rowNum) throws SQLException {
ArticleStatus articleStatus = new ArticleStatus(rs.getInt("ID"));
articleStatus.setName(rs.getString("name"));
articleStatus.setDescription(rs.getString("description"));
java.awt.Color color;
// Try to set the color
try {
color = java.awt.Color.decode(rs.getString("color"));
} catch (NumberFormatException e) {
color = java.awt.Color.gray;
}
articleStatus.setColor(color);
return articleStatus;
}Example 60
| Project: TerrainSculptor-master File: ColorUtils.java View source code |
/**
* @param alpha 0: completely transparent; 255: completely opaque.
*/
public static final Color transparentColor(Color color, int alpha) {
if (color == null)
return null;
/*
int rgba = color.getRGB();
rgba |= 0x000000ff;
alpha |= 0xffffff00;
rgba &= alpha;
return new Color (rgba, true);
*/
return new Color(color.getRed(), color.getGreen(), color.getBlue(), alpha);
}Example 61
| Project: TerrainViewer-master File: ColorUtils.java View source code |
/**
* @param alpha 0: completely transparent; 255: completely opaque.
*/
public static final Color transparentColor(Color color, int alpha) {
if (color == null)
return null;
/*
int rgba = color.getRGB();
rgba |= 0x000000ff;
alpha |= 0xffffff00;
rgba &= alpha;
return new Color (rgba, true);
*/
return new Color(color.getRed(), color.getGreen(), color.getBlue(), alpha);
}Example 62
| Project: ERSN-OpenMC-master File: ERSNOpenMC_Main.java View source code |
// openPdfFile class
// <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
private void initComponents() {
jMenu1 = new javax.swing.JMenu();
jMenu2 = new javax.swing.JMenu();
jMenuItem1 = new javax.swing.JMenuItem();
jFrame1 = new javax.swing.JFrame();
jScrollBar1 = new javax.swing.JScrollBar();
container = new javax.swing.JTabbedPane();
geometry_pnl = new javax.swing.JPanel();
jInternalFrame1 = new javax.swing.JInternalFrame();
btn_lattice = new javax.swing.JButton();
btn_surface = new javax.swing.JButton();
btn_hex_lattice = new javax.swing.JButton();
btn_comment_geometry = new javax.swing.JButton();
btn_cell = new javax.swing.JButton();
jInternalFrame2 = new javax.swing.JInternalFrame();
jScrollPane2 = new javax.swing.JScrollPane();
geometryTxt = new javax.swing.JEditorPane();
jInternalFrame3 = new javax.swing.JInternalFrame();
jScrollPane17 = new javax.swing.JScrollPane();
guide_geometry = new javax.swing.JTextArea();
materials_pnl = new javax.swing.JPanel();
jInternalFrame4 = new javax.swing.JInternalFrame();
btn_material = new javax.swing.JButton();
btn_defaults_xs = new javax.swing.JButton();
btn_comment_materials = new javax.swing.JButton();
jInternalFrame5 = new javax.swing.JInternalFrame();
jScrollPane4 = new javax.swing.JScrollPane();
materialsTxt = new javax.swing.JEditorPane();
jInternalFrame6 = new javax.swing.JInternalFrame();
jScrollPane19 = new javax.swing.JScrollPane();
guide_materials = new javax.swing.JTextArea();
settings_pnl = new javax.swing.JPanel();
jInternalFrame9 = new javax.swing.JInternalFrame();
btn_trace = new javax.swing.JButton();
btn_cross_sections = new javax.swing.JButton();
btn_ptables = new javax.swing.JButton();
btn_log_grid_bins = new javax.swing.JButton();
btn_threads = new javax.swing.JButton();
btn_output_path = new javax.swing.JButton();
btn_confidence_intervals = new javax.swing.JButton();
btn_comment_settings = new javax.swing.JButton();
btn_run_cmfd = new javax.swing.JButton();
btn_output = new javax.swing.JButton();
btn_track = new javax.swing.JButton();
btn_entropy = new javax.swing.JButton();
btn_source_point = new javax.swing.JButton();
btn_verbosity = new javax.swing.JButton();
btn_uniform_fs = new javax.swing.JButton();
btn_state_point = new javax.swing.JButton();
btn_seed = new javax.swing.JButton();
btn_source = new javax.swing.JButton();
btn_trigger = new javax.swing.JButton();
btn_energy_grid = new javax.swing.JButton();
btn_cutoff = new javax.swing.JButton();
btn_resonance_scattering = new javax.swing.JButton();
btn_fixed_source = new javax.swing.JButton();
btn_no_reduce = new javax.swing.JButton();
btn_survival_biasing = new javax.swing.JButton();
btn_eignvalue = new javax.swing.JButton();
btn_natural_elements = new javax.swing.JButton();
jInternalFrame10 = new javax.swing.JInternalFrame();
jScrollPane5 = new javax.swing.JScrollPane();
settingsTxt = new javax.swing.JEditorPane();
jInternalFrame11 = new javax.swing.JInternalFrame();
jScrollPane14 = new javax.swing.JScrollPane();
Guide = new javax.swing.JTextArea();
tallies_pnl = new javax.swing.JPanel();
jInternalFrame7 = new javax.swing.JInternalFrame();
btn_comment_tallies = new javax.swing.JButton();
btn_mesh = new javax.swing.JButton();
btn_tally = new javax.swing.JButton();
btn_assume_separate = new javax.swing.JButton();
jInternalFrame8 = new javax.swing.JInternalFrame();
jScrollPane8 = new javax.swing.JScrollPane();
talliesTxt = new javax.swing.JEditorPane();
jInternalFrame12 = new javax.swing.JInternalFrame();
jScrollPane20 = new javax.swing.JScrollPane();
guide_tallies = new javax.swing.JTextArea();
cmfd_pnl = new javax.swing.JPanel();
jInternalFrame13 = new javax.swing.JInternalFrame();
btn_mesh_cmfd = new javax.swing.JButton();
btn_gauss_seidel_tolerance = new javax.swing.JButton();
btn_norm = new javax.swing.JButton();
btn_power_monitor = new javax.swing.JButton();
btn_write_matrices = new javax.swing.JButton();
btn_dhat_set = new javax.swing.JButton();
btn_tally_reset = new javax.swing.JButton();
btn_display = new javax.swing.JButton();
btn_shift = new javax.swing.JButton();
btn_begin = new javax.swing.JButton();
btn_downscatter = new javax.swing.JButton();
run_adjoint = new javax.swing.JButton();
btn_comment_cmfd = new javax.swing.JButton();
btn_stol = new javax.swing.JButton();
btn_ktol = new javax.swing.JButton();
btn_feedback = new javax.swing.JButton();
btn_spectral = new javax.swing.JButton();
jInternalFrame14 = new javax.swing.JInternalFrame();
jScrollPane9 = new javax.swing.JScrollPane();
cmfdTxt = new javax.swing.JEditorPane();
jInternalFrame15 = new javax.swing.JInternalFrame();
jScrollPane21 = new javax.swing.JScrollPane();
Guidecmfd = new javax.swing.JTextArea();
plotting_pnl = new javax.swing.JPanel();
jInternalFrame16 = new javax.swing.JInternalFrame();
btn_comment_plotting = new javax.swing.JButton();
btn_plot_voxel = new javax.swing.JButton();
btn_plot_slice = new javax.swing.JButton();
jInternalFrame17 = new javax.swing.JInternalFrame();
jScrollPane10 = new javax.swing.JScrollPane();
plottingTxt = new javax.swing.JEditorPane();
jInternalFrame18 = new javax.swing.JInternalFrame();
jScrollPane22 = new javax.swing.JScrollPane();
GuidePlotting = new javax.swing.JTextArea();
lbl = new javax.swing.JLabel();
jMenuBar1 = new javax.swing.JMenuBar();
jMenu3 = new javax.swing.JMenu();
menu_new_openmc_project = new javax.swing.JMenuItem();
menu_existing_project = new javax.swing.JMenuItem();
menu_save_project = new javax.swing.JMenuItem();
menu_exit = new javax.swing.JMenuItem();
jMenu8 = new javax.swing.JMenu();
jMenuItem_run_openmc = new javax.swing.JMenuItem();
jMenu_get_openmc = new javax.swing.JMenuItem();
Menu_tools = new javax.swing.JMenu();
menu_item_show_results = new javax.swing.JMenuItem();
jMenuItem9 = new javax.swing.JMenuItem();
jMenu4 = new javax.swing.JMenu();
jMenuItem6 = new javax.swing.JMenuItem();
jMenuItem7 = new javax.swing.JMenuItem();
jMenu6 = new javax.swing.JMenu();
jMenuItem5 = new javax.swing.JMenuItem();
jMenuItem10 = new javax.swing.JMenuItem();
_3d_mesh_plot = new javax.swing.JMenuItem();
jMenu7 = new javax.swing.JMenu();
jMenuItem4 = new javax.swing.JMenuItem();
jMenuItem_binary_track_to_pvtp = new javax.swing.JMenuItem();
jMenuItem8 = new javax.swing.JMenuItem();
jSeparator2 = new javax.swing.JPopupMenu.Separator();
add_scorers = new javax.swing.JMenuItem();
menu_item_table_of_nuclides = new javax.swing.JMenuItem();
jMenuItem2 = new javax.swing.JMenuItem();
jMenuItem_openmc_xml_validation = new javax.swing.JMenuItem();
jMenuItem11 = new javax.swing.JMenuItem();
jSeparator1 = new javax.swing.JPopupMenu.Separator();
menu_item_get_openmc = new javax.swing.JMenuItem();
jMenuItem3 = new javax.swing.JMenuItem();
jMenu5 = new javax.swing.JMenu();
menu_item_about = new javax.swing.JMenuItem();
jMenu1.setText("jMenu1");
jMenu2.setText("jMenu2");
jMenuItem1.setText("jMenuItem1");
javax.swing.GroupLayout jFrame1Layout = new javax.swing.GroupLayout(jFrame1.getContentPane());
jFrame1.getContentPane().setLayout(jFrame1Layout);
jFrame1Layout.setHorizontalGroup(jFrame1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGap(0, 400, Short.MAX_VALUE));
jFrame1Layout.setVerticalGroup(jFrame1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGap(0, 300, Short.MAX_VALUE));
setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE);
setTitle("ERSN-OpenMC developed by Jaafar EL Bakkali & Tarek EL Bardouni");
setBackground(new java.awt.Color(0, 51, 204));
// NOI18N
setFont(new java.awt.Font("Ubuntu", 0, 5));
setLocationByPlatform(true);
addWindowListener(new java.awt.event.WindowAdapter() {
public void windowActivated(java.awt.event.WindowEvent evt) {
formWindowActivated(evt);
}
public void windowDeactivated(java.awt.event.WindowEvent evt) {
formWindowDeactivated(evt);
}
public void windowOpened(java.awt.event.WindowEvent evt) {
formWindowOpened(evt);
}
});
container.setBackground(new java.awt.Color(255, 255, 255));
container.setBorder(new javax.swing.border.SoftBevelBorder(javax.swing.border.BevelBorder.RAISED));
// NOI18N
container.setFont(new java.awt.Font("Arial", 1, 12));
container.setOpaque(true);
geometry_pnl.setBackground(java.awt.SystemColor.activeCaption);
geometry_pnl.setForeground(java.awt.SystemColor.activeCaption);
jInternalFrame1.setTitle("OpenMC commands");
jInternalFrame1.setVisible(true);
btn_lattice.setBackground(new java.awt.Color(0, 0, 154));
btn_lattice.setForeground(new java.awt.Color(255, 255, 204));
btn_lattice.setText("rectangular lattice");
btn_lattice.setToolTipText("");
btn_lattice.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
btn_lattice.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
btn_lattice.setFocusPainted(false);
btn_lattice.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseExited(java.awt.event.MouseEvent evt) {
btn_latticeMouseExited(evt);
}
public void mouseEntered(java.awt.event.MouseEvent evt) {
btn_latticeMouseEntered(evt);
}
});
btn_lattice.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
btn_latticeActionPerformed(evt);
}
});
btn_surface.setBackground(new java.awt.Color(0, 0, 154));
btn_surface.setForeground(new java.awt.Color(255, 255, 204));
btn_surface.setText("surface");
btn_surface.setToolTipText("");
btn_surface.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
btn_surface.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
btn_surface.setFocusPainted(false);
btn_surface.addMouseListener(new java.awt.event.MouseAdapter() {
public void mousePressed(java.awt.event.MouseEvent evt) {
btn_surfaceMousePressed(evt);
}
public void mouseExited(java.awt.event.MouseEvent evt) {
btn_surfaceMouseExited(evt);
}
public void mouseEntered(java.awt.event.MouseEvent evt) {
btn_surfaceMouseEntered(evt);
}
});
btn_surface.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
btn_surfaceActionPerformed(evt);
}
});
btn_hex_lattice.setBackground(new java.awt.Color(0, 0, 154));
btn_hex_lattice.setForeground(new java.awt.Color(255, 255, 204));
btn_hex_lattice.setText("hexagonal lattice");
btn_hex_lattice.setToolTipText("");
btn_hex_lattice.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
btn_hex_lattice.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
btn_hex_lattice.setFocusPainted(false);
btn_hex_lattice.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseExited(java.awt.event.MouseEvent evt) {
btn_hex_latticeMouseExited(evt);
}
public void mouseEntered(java.awt.event.MouseEvent evt) {
btn_hex_latticeMouseEntered(evt);
}
});
btn_hex_lattice.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
btn_hex_latticeActionPerformed(evt);
}
});
btn_comment_geometry.setBackground(new java.awt.Color(0, 0, 154));
btn_comment_geometry.setForeground(new java.awt.Color(255, 255, 204));
btn_comment_geometry.setText("comment");
btn_comment_geometry.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
btn_comment_geometry.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
btn_comment_geometry.setFocusPainted(false);
btn_comment_geometry.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseExited(java.awt.event.MouseEvent evt) {
btn_comment_geometryMouseExited(evt);
}
public void mouseEntered(java.awt.event.MouseEvent evt) {
btn_comment_geometryMouseEntered(evt);
}
});
btn_comment_geometry.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
btn_comment_geometryActionPerformed(evt);
}
});
btn_cell.setBackground(new java.awt.Color(0, 0, 154));
btn_cell.setForeground(new java.awt.Color(255, 255, 204));
btn_cell.setText("cell");
btn_cell.setToolTipText("");
btn_cell.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
btn_cell.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
btn_cell.setFocusPainted(false);
btn_cell.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseExited(java.awt.event.MouseEvent evt) {
btn_cellMouseExited(evt);
}
public void mouseEntered(java.awt.event.MouseEvent evt) {
btn_cellMouseEntered(evt);
}
});
btn_cell.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
btn_cellActionPerformed(evt);
}
});
javax.swing.GroupLayout jInternalFrame1Layout = new javax.swing.GroupLayout(jInternalFrame1.getContentPane());
jInternalFrame1.getContentPane().setLayout(jInternalFrame1Layout);
jInternalFrame1Layout.setHorizontalGroup(jInternalFrame1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(jInternalFrame1Layout.createSequentialGroup().addGap(0, 0, 0).addGroup(jInternalFrame1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING, false).addComponent(btn_cell, javax.swing.GroupLayout.Alignment.LEADING, javax.swing.GroupLayout.PREFERRED_SIZE, 200, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(btn_surface, javax.swing.GroupLayout.Alignment.LEADING, javax.swing.GroupLayout.PREFERRED_SIZE, 200, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(btn_lattice, javax.swing.GroupLayout.Alignment.LEADING, javax.swing.GroupLayout.PREFERRED_SIZE, 200, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(btn_comment_geometry, javax.swing.GroupLayout.Alignment.LEADING, javax.swing.GroupLayout.PREFERRED_SIZE, 200, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(btn_hex_lattice, javax.swing.GroupLayout.Alignment.LEADING, javax.swing.GroupLayout.PREFERRED_SIZE, 200, javax.swing.GroupLayout.PREFERRED_SIZE)).addGap(0, 0, 0)));
jInternalFrame1Layout.setVerticalGroup(jInternalFrame1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(jInternalFrame1Layout.createSequentialGroup().addGap(0, 0, 0).addComponent(btn_surface, javax.swing.GroupLayout.PREFERRED_SIZE, 21, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0).addComponent(btn_cell, javax.swing.GroupLayout.PREFERRED_SIZE, 21, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0).addComponent(btn_hex_lattice, javax.swing.GroupLayout.PREFERRED_SIZE, 21, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0).addComponent(btn_lattice, javax.swing.GroupLayout.PREFERRED_SIZE, 21, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0).addComponent(btn_comment_geometry, javax.swing.GroupLayout.PREFERRED_SIZE, 21, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0)));
jInternalFrame2.setTitle("OpenMC XML Editor");
jInternalFrame2.setVisible(true);
geometryTxt.addAncestorListener(new javax.swing.event.AncestorListener() {
public void ancestorMoved(javax.swing.event.AncestorEvent evt) {
}
public void ancestorAdded(javax.swing.event.AncestorEvent evt) {
geometryTxtAncestorAdded(evt);
}
public void ancestorRemoved(javax.swing.event.AncestorEvent evt) {
}
});
jScrollPane2.setViewportView(geometryTxt);
javax.swing.GroupLayout jInternalFrame2Layout = new javax.swing.GroupLayout(jInternalFrame2.getContentPane());
jInternalFrame2.getContentPane().setLayout(jInternalFrame2Layout);
jInternalFrame2Layout.setHorizontalGroup(jInternalFrame2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(jInternalFrame2Layout.createSequentialGroup().addGap(0, 0, 0).addComponent(jScrollPane2, javax.swing.GroupLayout.DEFAULT_SIZE, 799, Short.MAX_VALUE).addGap(0, 0, 0)));
jInternalFrame2Layout.setVerticalGroup(jInternalFrame2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(jInternalFrame2Layout.createSequentialGroup().addGap(0, 0, 0).addComponent(jScrollPane2, javax.swing.GroupLayout.PREFERRED_SIZE, 500, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0)));
jInternalFrame3.setTitle("OpenMC commands guidance");
jInternalFrame3.setToolTipText("");
jInternalFrame3.setVisible(true);
guide_geometry.setBackground(java.awt.SystemColor.text);
guide_geometry.setColumns(20);
// NOI18N
guide_geometry.setFont(new java.awt.Font("Ubuntu", 0, 12));
guide_geometry.setLineWrap(true);
guide_geometry.setRows(5);
guide_geometry.setWrapStyleWord(true);
jScrollPane17.setViewportView(guide_geometry);
javax.swing.GroupLayout jInternalFrame3Layout = new javax.swing.GroupLayout(jInternalFrame3.getContentPane());
jInternalFrame3.getContentPane().setLayout(jInternalFrame3Layout);
jInternalFrame3Layout.setHorizontalGroup(jInternalFrame3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(jInternalFrame3Layout.createSequentialGroup().addGap(0, 0, 0).addComponent(jScrollPane17, javax.swing.GroupLayout.DEFAULT_SIZE, 1010, Short.MAX_VALUE).addGap(0, 0, 0)));
jInternalFrame3Layout.setVerticalGroup(jInternalFrame3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(jInternalFrame3Layout.createSequentialGroup().addGap(0, 0, 0).addComponent(jScrollPane17, javax.swing.GroupLayout.DEFAULT_SIZE, 102, Short.MAX_VALUE).addGap(0, 0, 0)));
javax.swing.GroupLayout geometry_pnlLayout = new javax.swing.GroupLayout(geometry_pnl);
geometry_pnl.setLayout(geometry_pnlLayout);
geometry_pnlLayout.setHorizontalGroup(geometry_pnlLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(geometry_pnlLayout.createSequentialGroup().addComponent(jInternalFrame1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0).addComponent(jInternalFrame2)).addComponent(jInternalFrame3));
geometry_pnlLayout.setVerticalGroup(geometry_pnlLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(geometry_pnlLayout.createSequentialGroup().addGap(2, 2, 2).addGroup(geometry_pnlLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(jInternalFrame1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(jInternalFrame2, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addGap(0, 0, 0).addComponent(jInternalFrame3)));
container.addTab("Geometry ", geometry_pnl);
materials_pnl.setBackground(java.awt.SystemColor.activeCaption);
jInternalFrame4.setTitle("OpenMC commands");
jInternalFrame4.setVisible(true);
btn_material.setBackground(new java.awt.Color(0, 0, 154));
btn_material.setForeground(new java.awt.Color(255, 255, 204));
btn_material.setText("material");
btn_material.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
btn_material.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
btn_material.setFocusPainted(false);
btn_material.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseExited(java.awt.event.MouseEvent evt) {
btn_materialMouseExited(evt);
}
public void mouseEntered(java.awt.event.MouseEvent evt) {
btn_materialMouseEntered(evt);
}
});
btn_material.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
btn_materialActionPerformed(evt);
}
});
btn_defaults_xs.setBackground(new java.awt.Color(0, 0, 154));
btn_defaults_xs.setForeground(new java.awt.Color(255, 255, 204));
btn_defaults_xs.setText("default_xs");
btn_defaults_xs.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
btn_defaults_xs.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
btn_defaults_xs.setFocusPainted(false);
btn_defaults_xs.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseExited(java.awt.event.MouseEvent evt) {
btn_defaults_xsMouseExited(evt);
}
public void mouseEntered(java.awt.event.MouseEvent evt) {
btn_defaults_xsMouseEntered(evt);
}
});
btn_defaults_xs.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
btn_defaults_xsActionPerformed(evt);
}
});
btn_comment_materials.setBackground(new java.awt.Color(0, 0, 154));
btn_comment_materials.setForeground(new java.awt.Color(255, 255, 204));
btn_comment_materials.setText("comment");
btn_comment_materials.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
btn_comment_materials.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
btn_comment_materials.setFocusPainted(false);
btn_comment_materials.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseExited(java.awt.event.MouseEvent evt) {
btn_comment_materialsMouseExited(evt);
}
public void mouseEntered(java.awt.event.MouseEvent evt) {
btn_comment_materialsMouseEntered(evt);
}
});
btn_comment_materials.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
btn_comment_materialsActionPerformed(evt);
}
});
javax.swing.GroupLayout jInternalFrame4Layout = new javax.swing.GroupLayout(jInternalFrame4.getContentPane());
jInternalFrame4.getContentPane().setLayout(jInternalFrame4Layout);
jInternalFrame4Layout.setHorizontalGroup(jInternalFrame4Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(jInternalFrame4Layout.createSequentialGroup().addGap(0, 0, 0).addGroup(jInternalFrame4Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING, false).addComponent(btn_material, javax.swing.GroupLayout.Alignment.LEADING, javax.swing.GroupLayout.PREFERRED_SIZE, 200, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(btn_defaults_xs, javax.swing.GroupLayout.PREFERRED_SIZE, 200, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(btn_comment_materials, javax.swing.GroupLayout.PREFERRED_SIZE, 200, javax.swing.GroupLayout.PREFERRED_SIZE)).addGap(0, 0, 0)));
jInternalFrame4Layout.setVerticalGroup(jInternalFrame4Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(jInternalFrame4Layout.createSequentialGroup().addGap(0, 0, 0).addComponent(btn_material, javax.swing.GroupLayout.PREFERRED_SIZE, 21, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0).addComponent(btn_defaults_xs, javax.swing.GroupLayout.PREFERRED_SIZE, 21, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0).addComponent(btn_comment_materials, javax.swing.GroupLayout.PREFERRED_SIZE, 21, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0)));
jInternalFrame5.setTitle("OpenMC XML Editor");
jInternalFrame5.setVisible(true);
jScrollPane4.setViewportView(materialsTxt);
javax.swing.GroupLayout jInternalFrame5Layout = new javax.swing.GroupLayout(jInternalFrame5.getContentPane());
jInternalFrame5.getContentPane().setLayout(jInternalFrame5Layout);
jInternalFrame5Layout.setHorizontalGroup(jInternalFrame5Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(jInternalFrame5Layout.createSequentialGroup().addGap(0, 0, 0).addComponent(jScrollPane4, javax.swing.GroupLayout.DEFAULT_SIZE, 799, Short.MAX_VALUE).addGap(0, 0, 0)));
jInternalFrame5Layout.setVerticalGroup(jInternalFrame5Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(jInternalFrame5Layout.createSequentialGroup().addGap(0, 0, 0).addComponent(jScrollPane4, javax.swing.GroupLayout.PREFERRED_SIZE, 500, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0)));
jInternalFrame6.setTitle("OpenMC commands guidance");
jInternalFrame6.setVisible(true);
guide_materials.setBackground(java.awt.SystemColor.text);
guide_materials.setColumns(20);
// NOI18N
guide_materials.setFont(new java.awt.Font("Ubuntu", 0, 12));
guide_materials.setLineWrap(true);
guide_materials.setRows(5);
guide_materials.setWrapStyleWord(true);
jScrollPane19.setViewportView(guide_materials);
javax.swing.GroupLayout jInternalFrame6Layout = new javax.swing.GroupLayout(jInternalFrame6.getContentPane());
jInternalFrame6.getContentPane().setLayout(jInternalFrame6Layout);
jInternalFrame6Layout.setHorizontalGroup(jInternalFrame6Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(jInternalFrame6Layout.createSequentialGroup().addGap(0, 0, 0).addComponent(jScrollPane19, javax.swing.GroupLayout.DEFAULT_SIZE, 1010, Short.MAX_VALUE).addGap(0, 0, 0)));
jInternalFrame6Layout.setVerticalGroup(jInternalFrame6Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(jInternalFrame6Layout.createSequentialGroup().addGap(0, 0, 0).addComponent(jScrollPane19, javax.swing.GroupLayout.DEFAULT_SIZE, 102, Short.MAX_VALUE).addGap(0, 0, 0)));
javax.swing.GroupLayout materials_pnlLayout = new javax.swing.GroupLayout(materials_pnl);
materials_pnl.setLayout(materials_pnlLayout);
materials_pnlLayout.setHorizontalGroup(materials_pnlLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(materials_pnlLayout.createSequentialGroup().addComponent(jInternalFrame4, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0).addComponent(jInternalFrame5)).addComponent(jInternalFrame6));
materials_pnlLayout.setVerticalGroup(materials_pnlLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(javax.swing.GroupLayout.Alignment.TRAILING, materials_pnlLayout.createSequentialGroup().addGap(2, 2, 2).addGroup(materials_pnlLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(jInternalFrame4, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(jInternalFrame5, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addGap(0, 0, 0).addComponent(jInternalFrame6)));
container.addTab("Materials ", materials_pnl);
settings_pnl.setBackground(java.awt.SystemColor.activeCaption);
settings_pnl.setForeground(java.awt.SystemColor.activeCaption);
jInternalFrame9.setTitle("OpenMC commands");
jInternalFrame9.setVisible(true);
btn_trace.setBackground(new java.awt.Color(0, 0, 154));
btn_trace.setForeground(new java.awt.Color(255, 255, 204));
btn_trace.setText("trace");
btn_trace.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
btn_trace.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
btn_trace.setFocusPainted(false);
btn_trace.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseExited(java.awt.event.MouseEvent evt) {
btn_traceMouseExited(evt);
}
public void mouseEntered(java.awt.event.MouseEvent evt) {
btn_traceMouseEntered(evt);
}
});
btn_trace.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
btn_traceActionPerformed(evt);
}
});
btn_cross_sections.setBackground(new java.awt.Color(0, 0, 154));
btn_cross_sections.setForeground(new java.awt.Color(255, 255, 204));
btn_cross_sections.setText("cross_sections");
btn_cross_sections.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
btn_cross_sections.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
btn_cross_sections.setFocusPainted(false);
btn_cross_sections.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseExited(java.awt.event.MouseEvent evt) {
btn_cross_sectionsMouseExited(evt);
}
public void mouseEntered(java.awt.event.MouseEvent evt) {
btn_cross_sectionsMouseEntered(evt);
}
});
btn_cross_sections.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
btn_cross_sectionsActionPerformed(evt);
}
});
btn_ptables.setBackground(new java.awt.Color(0, 0, 154));
btn_ptables.setForeground(new java.awt.Color(255, 255, 204));
btn_ptables.setText("ptables");
btn_ptables.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
btn_ptables.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
btn_ptables.setFocusPainted(false);
btn_ptables.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseExited(java.awt.event.MouseEvent evt) {
btn_ptablesMouseExited(evt);
}
public void mouseEntered(java.awt.event.MouseEvent evt) {
btn_ptablesMouseEntered(evt);
}
});
btn_ptables.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
btn_ptablesActionPerformed(evt);
}
});
btn_log_grid_bins.setBackground(new java.awt.Color(0, 0, 154));
btn_log_grid_bins.setForeground(new java.awt.Color(255, 255, 204));
btn_log_grid_bins.setText("log_grid_bins");
btn_log_grid_bins.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
btn_log_grid_bins.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
btn_log_grid_bins.setFocusPainted(false);
btn_log_grid_bins.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseExited(java.awt.event.MouseEvent evt) {
btn_log_grid_binsMouseExited(evt);
}
public void mouseEntered(java.awt.event.MouseEvent evt) {
btn_log_grid_binsMouseEntered(evt);
}
});
btn_log_grid_bins.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
btn_log_grid_binsActionPerformed(evt);
}
});
btn_threads.setBackground(new java.awt.Color(0, 0, 154));
btn_threads.setForeground(new java.awt.Color(255, 255, 204));
btn_threads.setText("threads");
btn_threads.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
btn_threads.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
btn_threads.setFocusPainted(false);
btn_threads.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseExited(java.awt.event.MouseEvent evt) {
btn_threadsMouseExited(evt);
}
public void mouseEntered(java.awt.event.MouseEvent evt) {
btn_threadsMouseEntered(evt);
}
});
btn_threads.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
btn_threadsActionPerformed(evt);
}
});
btn_output_path.setBackground(new java.awt.Color(0, 0, 154));
btn_output_path.setForeground(new java.awt.Color(255, 255, 204));
btn_output_path.setText("output_path");
btn_output_path.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
btn_output_path.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
btn_output_path.setFocusPainted(false);
btn_output_path.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseExited(java.awt.event.MouseEvent evt) {
btn_output_pathMouseExited(evt);
}
public void mouseEntered(java.awt.event.MouseEvent evt) {
btn_output_pathMouseEntered(evt);
}
});
btn_output_path.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
btn_output_pathActionPerformed(evt);
}
});
btn_confidence_intervals.setBackground(new java.awt.Color(0, 0, 154));
btn_confidence_intervals.setForeground(new java.awt.Color(255, 255, 204));
btn_confidence_intervals.setText("confidence_intervals");
btn_confidence_intervals.setToolTipText("");
btn_confidence_intervals.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
btn_confidence_intervals.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
btn_confidence_intervals.setFocusPainted(false);
btn_confidence_intervals.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseExited(java.awt.event.MouseEvent evt) {
btn_confidence_intervalsMouseExited(evt);
}
public void mouseEntered(java.awt.event.MouseEvent evt) {
btn_confidence_intervalsMouseEntered(evt);
}
});
btn_confidence_intervals.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
btn_confidence_intervalsActionPerformed(evt);
}
});
btn_comment_settings.setBackground(new java.awt.Color(0, 0, 154));
btn_comment_settings.setForeground(new java.awt.Color(255, 255, 204));
btn_comment_settings.setText("comment");
btn_comment_settings.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
btn_comment_settings.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
btn_comment_settings.setFocusPainted(false);
btn_comment_settings.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseExited(java.awt.event.MouseEvent evt) {
btn_comment_settingsMouseExited(evt);
}
public void mouseEntered(java.awt.event.MouseEvent evt) {
btn_comment_settingsMouseEntered(evt);
}
});
btn_comment_settings.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
btn_comment_settingsActionPerformed(evt);
}
});
btn_run_cmfd.setBackground(new java.awt.Color(0, 0, 154));
btn_run_cmfd.setForeground(new java.awt.Color(255, 255, 204));
btn_run_cmfd.setText("run_cmfd");
btn_run_cmfd.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
btn_run_cmfd.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
btn_run_cmfd.setFocusPainted(false);
btn_run_cmfd.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseExited(java.awt.event.MouseEvent evt) {
btn_run_cmfdMouseExited(evt);
}
public void mouseEntered(java.awt.event.MouseEvent evt) {
btn_run_cmfdMouseEntered(evt);
}
});
btn_run_cmfd.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
btn_run_cmfdActionPerformed(evt);
}
});
btn_output.setBackground(new java.awt.Color(0, 0, 154));
btn_output.setForeground(new java.awt.Color(255, 255, 204));
btn_output.setText("output");
btn_output.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
btn_output.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
btn_output.setFocusPainted(false);
btn_output.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseExited(java.awt.event.MouseEvent evt) {
btn_outputMouseExited(evt);
}
public void mouseEntered(java.awt.event.MouseEvent evt) {
btn_outputMouseEntered(evt);
}
});
btn_output.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
btn_outputActionPerformed(evt);
}
});
btn_track.setBackground(new java.awt.Color(0, 0, 154));
btn_track.setForeground(new java.awt.Color(255, 255, 204));
btn_track.setText("track");
btn_track.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
btn_track.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
btn_track.setFocusPainted(false);
btn_track.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseExited(java.awt.event.MouseEvent evt) {
btn_trackMouseExited(evt);
}
public void mouseEntered(java.awt.event.MouseEvent evt) {
btn_trackMouseEntered(evt);
}
});
btn_track.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
btn_trackActionPerformed(evt);
}
});
btn_entropy.setBackground(new java.awt.Color(0, 0, 154));
btn_entropy.setForeground(new java.awt.Color(255, 255, 204));
btn_entropy.setText("entropy");
btn_entropy.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
btn_entropy.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
btn_entropy.setFocusPainted(false);
btn_entropy.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseExited(java.awt.event.MouseEvent evt) {
btn_entropyMouseExited(evt);
}
public void mouseEntered(java.awt.event.MouseEvent evt) {
btn_entropyMouseEntered(evt);
}
});
btn_entropy.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
btn_entropyActionPerformed(evt);
}
});
btn_source_point.setBackground(new java.awt.Color(0, 0, 154));
btn_source_point.setForeground(new java.awt.Color(255, 255, 204));
btn_source_point.setText("source_point");
btn_source_point.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
btn_source_point.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
btn_source_point.setFocusPainted(false);
btn_source_point.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseExited(java.awt.event.MouseEvent evt) {
btn_source_pointMouseExited(evt);
}
public void mouseEntered(java.awt.event.MouseEvent evt) {
btn_source_pointMouseEntered(evt);
}
});
btn_source_point.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
btn_source_pointActionPerformed(evt);
}
});
btn_verbosity.setBackground(new java.awt.Color(0, 0, 154));
btn_verbosity.setForeground(new java.awt.Color(255, 255, 204));
btn_verbosity.setText("verbosity");
btn_verbosity.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
btn_verbosity.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
btn_verbosity.setFocusPainted(false);
btn_verbosity.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseExited(java.awt.event.MouseEvent evt) {
btn_verbosityMouseExited(evt);
}
public void mouseEntered(java.awt.event.MouseEvent evt) {
btn_verbosityMouseEntered(evt);
}
});
btn_verbosity.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
btn_verbosityActionPerformed(evt);
}
});
btn_uniform_fs.setBackground(new java.awt.Color(0, 0, 154));
btn_uniform_fs.setForeground(new java.awt.Color(255, 255, 204));
btn_uniform_fs.setText("uniform_fs");
btn_uniform_fs.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
btn_uniform_fs.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
btn_uniform_fs.setFocusPainted(false);
btn_uniform_fs.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseExited(java.awt.event.MouseEvent evt) {
btn_uniform_fsMouseExited(evt);
}
public void mouseEntered(java.awt.event.MouseEvent evt) {
btn_uniform_fsMouseEntered(evt);
}
});
btn_uniform_fs.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
btn_uniform_fsActionPerformed(evt);
}
});
btn_state_point.setBackground(new java.awt.Color(0, 0, 154));
btn_state_point.setForeground(new java.awt.Color(255, 255, 204));
btn_state_point.setText("state_point");
btn_state_point.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
btn_state_point.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
btn_state_point.setFocusPainted(false);
btn_state_point.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseExited(java.awt.event.MouseEvent evt) {
btn_state_pointMouseExited(evt);
}
public void mouseEntered(java.awt.event.MouseEvent evt) {
btn_state_pointMouseEntered(evt);
}
});
btn_state_point.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
btn_state_pointActionPerformed(evt);
}
});
btn_seed.setBackground(new java.awt.Color(0, 0, 154));
btn_seed.setForeground(new java.awt.Color(255, 255, 204));
btn_seed.setText("seed");
btn_seed.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
btn_seed.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
btn_seed.setFocusPainted(false);
btn_seed.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseExited(java.awt.event.MouseEvent evt) {
btn_seedMouseExited(evt);
}
public void mouseEntered(java.awt.event.MouseEvent evt) {
btn_seedMouseEntered(evt);
}
});
btn_seed.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
btn_seedActionPerformed(evt);
}
});
btn_source.setBackground(new java.awt.Color(0, 0, 154));
btn_source.setForeground(new java.awt.Color(255, 255, 204));
btn_source.setText("source");
btn_source.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
btn_source.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
btn_source.setFocusPainted(false);
btn_source.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseExited(java.awt.event.MouseEvent evt) {
btn_sourceMouseExited(evt);
}
public void mouseEntered(java.awt.event.MouseEvent evt) {
btn_sourceMouseEntered(evt);
}
});
btn_source.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
btn_sourceActionPerformed(evt);
}
});
btn_trigger.setBackground(new java.awt.Color(0, 0, 154));
btn_trigger.setForeground(new java.awt.Color(255, 255, 204));
btn_trigger.setText("trigger");
btn_trigger.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
btn_trigger.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
btn_trigger.setFocusPainted(false);
btn_trigger.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseExited(java.awt.event.MouseEvent evt) {
btn_triggerMouseExited(evt);
}
public void mouseEntered(java.awt.event.MouseEvent evt) {
btn_triggerMouseEntered(evt);
}
});
btn_trigger.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
btn_triggerActionPerformed(evt);
}
});
btn_energy_grid.setBackground(new java.awt.Color(0, 0, 154));
btn_energy_grid.setForeground(new java.awt.Color(255, 255, 204));
btn_energy_grid.setText("energy_grid");
btn_energy_grid.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
btn_energy_grid.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
btn_energy_grid.setFocusPainted(false);
btn_energy_grid.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseExited(java.awt.event.MouseEvent evt) {
btn_energy_gridMouseExited(evt);
}
public void mouseEntered(java.awt.event.MouseEvent evt) {
btn_energy_gridMouseEntered(evt);
}
});
btn_energy_grid.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
btn_energy_gridActionPerformed(evt);
}
});
btn_cutoff.setBackground(new java.awt.Color(0, 0, 154));
btn_cutoff.setForeground(new java.awt.Color(255, 255, 204));
btn_cutoff.setText("cutoff");
btn_cutoff.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
btn_cutoff.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
btn_cutoff.setFocusPainted(false);
btn_cutoff.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseExited(java.awt.event.MouseEvent evt) {
btn_cutoffMouseExited(evt);
}
public void mouseEntered(java.awt.event.MouseEvent evt) {
btn_cutoffMouseEntered(evt);
}
});
btn_cutoff.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
btn_cutoffActionPerformed(evt);
}
});
btn_resonance_scattering.setBackground(new java.awt.Color(0, 0, 154));
btn_resonance_scattering.setForeground(new java.awt.Color(255, 255, 204));
btn_resonance_scattering.setText("resonance_scattering");
btn_resonance_scattering.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
btn_resonance_scattering.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
btn_resonance_scattering.setFocusPainted(false);
btn_resonance_scattering.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseExited(java.awt.event.MouseEvent evt) {
btn_resonance_scatteringMouseExited(evt);
}
public void mouseEntered(java.awt.event.MouseEvent evt) {
btn_resonance_scatteringMouseEntered(evt);
}
});
btn_resonance_scattering.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
btn_resonance_scatteringActionPerformed(evt);
}
});
btn_fixed_source.setBackground(new java.awt.Color(0, 0, 154));
btn_fixed_source.setForeground(new java.awt.Color(255, 255, 204));
btn_fixed_source.setText("fixed_source");
btn_fixed_source.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
btn_fixed_source.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
btn_fixed_source.setFocusPainted(false);
btn_fixed_source.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseExited(java.awt.event.MouseEvent evt) {
btn_fixed_sourceMouseExited(evt);
}
public void mouseEntered(java.awt.event.MouseEvent evt) {
btn_fixed_sourceMouseEntered(evt);
}
});
btn_fixed_source.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
btn_fixed_sourceActionPerformed(evt);
}
});
btn_no_reduce.setBackground(new java.awt.Color(0, 0, 154));
btn_no_reduce.setForeground(new java.awt.Color(255, 255, 204));
btn_no_reduce.setText("no_reduce");
btn_no_reduce.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
btn_no_reduce.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
btn_no_reduce.setFocusPainted(false);
btn_no_reduce.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
btn_no_reduceMouseClicked(evt);
}
public void mouseExited(java.awt.event.MouseEvent evt) {
btn_no_reduceMouseExited(evt);
}
public void mouseEntered(java.awt.event.MouseEvent evt) {
btn_no_reduceMouseEntered(evt);
}
});
btn_no_reduce.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
btn_no_reduceActionPerformed(evt);
}
});
btn_survival_biasing.setBackground(new java.awt.Color(0, 0, 154));
btn_survival_biasing.setForeground(new java.awt.Color(255, 255, 204));
btn_survival_biasing.setText("survival_biasing");
btn_survival_biasing.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
btn_survival_biasing.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
btn_survival_biasing.setFocusPainted(false);
btn_survival_biasing.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseExited(java.awt.event.MouseEvent evt) {
btn_survival_biasingMouseExited(evt);
}
public void mouseEntered(java.awt.event.MouseEvent evt) {
btn_survival_biasingMouseEntered(evt);
}
});
btn_survival_biasing.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
btn_survival_biasingActionPerformed(evt);
}
});
btn_eignvalue.setBackground(new java.awt.Color(0, 0, 154));
btn_eignvalue.setForeground(new java.awt.Color(255, 255, 204));
btn_eignvalue.setText("eigenvalue");
btn_eignvalue.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
btn_eignvalue.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
btn_eignvalue.setFocusPainted(false);
btn_eignvalue.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseExited(java.awt.event.MouseEvent evt) {
btn_eignvalueMouseExited(evt);
}
public void mouseEntered(java.awt.event.MouseEvent evt) {
btn_eignvalueMouseEntered(evt);
}
});
btn_eignvalue.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
btn_eignvalueActionPerformed(evt);
}
});
btn_natural_elements.setBackground(new java.awt.Color(0, 0, 154));
btn_natural_elements.setForeground(new java.awt.Color(255, 255, 204));
btn_natural_elements.setText("natural_elements");
btn_natural_elements.setToolTipText("");
btn_natural_elements.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
btn_natural_elements.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
btn_natural_elements.setFocusPainted(false);
btn_natural_elements.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseExited(java.awt.event.MouseEvent evt) {
btn_natural_elementsMouseExited(evt);
}
public void mouseEntered(java.awt.event.MouseEvent evt) {
btn_natural_elementsMouseEntered(evt);
}
});
btn_natural_elements.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
btn_natural_elementsActionPerformed(evt);
}
});
javax.swing.GroupLayout jInternalFrame9Layout = new javax.swing.GroupLayout(jInternalFrame9.getContentPane());
jInternalFrame9.getContentPane().setLayout(jInternalFrame9Layout);
jInternalFrame9Layout.setHorizontalGroup(jInternalFrame9Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(jInternalFrame9Layout.createSequentialGroup().addGap(0, 0, 0).addGroup(jInternalFrame9Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(jInternalFrame9Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jInternalFrame9Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(btn_run_cmfd, javax.swing.GroupLayout.PREFERRED_SIZE, 200, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(btn_seed, javax.swing.GroupLayout.PREFERRED_SIZE, 200, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(btn_source, javax.swing.GroupLayout.PREFERRED_SIZE, 200, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(btn_track, javax.swing.GroupLayout.PREFERRED_SIZE, 200, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(btn_state_point, javax.swing.GroupLayout.PREFERRED_SIZE, 200, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(btn_source_point, javax.swing.GroupLayout.PREFERRED_SIZE, 200, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(btn_threads, javax.swing.GroupLayout.PREFERRED_SIZE, 200, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(btn_trace, javax.swing.GroupLayout.PREFERRED_SIZE, 200, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(btn_survival_biasing, javax.swing.GroupLayout.PREFERRED_SIZE, 200, javax.swing.GroupLayout.PREFERRED_SIZE)).addComponent(btn_confidence_intervals, javax.swing.GroupLayout.PREFERRED_SIZE, 200, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(btn_cross_sections, javax.swing.GroupLayout.PREFERRED_SIZE, 200, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(btn_cutoff, javax.swing.GroupLayout.PREFERRED_SIZE, 200, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(btn_eignvalue, javax.swing.GroupLayout.PREFERRED_SIZE, 200, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(btn_entropy, javax.swing.GroupLayout.PREFERRED_SIZE, 200, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(btn_fixed_source, javax.swing.GroupLayout.PREFERRED_SIZE, 200, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(btn_output, javax.swing.GroupLayout.PREFERRED_SIZE, 200, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(btn_no_reduce, javax.swing.GroupLayout.PREFERRED_SIZE, 200, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(btn_output_path, javax.swing.GroupLayout.PREFERRED_SIZE, 200, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(btn_ptables, javax.swing.GroupLayout.PREFERRED_SIZE, 200, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(btn_energy_grid, javax.swing.GroupLayout.PREFERRED_SIZE, 200, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(btn_natural_elements, javax.swing.GroupLayout.PREFERRED_SIZE, 200, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(btn_log_grid_bins, javax.swing.GroupLayout.PREFERRED_SIZE, 200, javax.swing.GroupLayout.PREFERRED_SIZE)).addComponent(btn_resonance_scattering, javax.swing.GroupLayout.PREFERRED_SIZE, 200, javax.swing.GroupLayout.PREFERRED_SIZE).addGroup(jInternalFrame9Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(btn_verbosity, javax.swing.GroupLayout.PREFERRED_SIZE, 200, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(btn_uniform_fs, javax.swing.GroupLayout.Alignment.TRAILING, javax.swing.GroupLayout.PREFERRED_SIZE, 200, javax.swing.GroupLayout.PREFERRED_SIZE)).addComponent(btn_trigger, javax.swing.GroupLayout.PREFERRED_SIZE, 200, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(btn_comment_settings, javax.swing.GroupLayout.PREFERRED_SIZE, 200, javax.swing.GroupLayout.PREFERRED_SIZE)).addGap(0, 0, 0)));
jInternalFrame9Layout.setVerticalGroup(jInternalFrame9Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(jInternalFrame9Layout.createSequentialGroup().addGap(0, 0, 0).addComponent(btn_confidence_intervals, javax.swing.GroupLayout.PREFERRED_SIZE, 18, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0).addComponent(btn_cross_sections, javax.swing.GroupLayout.PREFERRED_SIZE, 18, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0).addComponent(btn_cutoff, javax.swing.GroupLayout.PREFERRED_SIZE, 18, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0).addComponent(btn_eignvalue, javax.swing.GroupLayout.PREFERRED_SIZE, 18, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0).addComponent(btn_energy_grid, javax.swing.GroupLayout.PREFERRED_SIZE, 18, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0).addComponent(btn_entropy, javax.swing.GroupLayout.PREFERRED_SIZE, 18, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0).addComponent(btn_fixed_source, javax.swing.GroupLayout.PREFERRED_SIZE, 18, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0).addComponent(btn_log_grid_bins, javax.swing.GroupLayout.PREFERRED_SIZE, 18, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0).addComponent(btn_natural_elements, javax.swing.GroupLayout.PREFERRED_SIZE, 18, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0).addComponent(btn_no_reduce, javax.swing.GroupLayout.PREFERRED_SIZE, 18, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0).addComponent(btn_output, javax.swing.GroupLayout.PREFERRED_SIZE, 18, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0).addComponent(btn_output_path, javax.swing.GroupLayout.PREFERRED_SIZE, 18, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0).addComponent(btn_ptables, javax.swing.GroupLayout.PREFERRED_SIZE, 18, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0).addComponent(btn_resonance_scattering, javax.swing.GroupLayout.PREFERRED_SIZE, 18, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0).addComponent(btn_run_cmfd, javax.swing.GroupLayout.PREFERRED_SIZE, 18, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0).addComponent(btn_seed, javax.swing.GroupLayout.PREFERRED_SIZE, 18, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0).addComponent(btn_source, javax.swing.GroupLayout.PREFERRED_SIZE, 18, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0).addComponent(btn_state_point, javax.swing.GroupLayout.PREFERRED_SIZE, 18, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0).addComponent(btn_source_point, javax.swing.GroupLayout.PREFERRED_SIZE, 18, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0).addComponent(btn_survival_biasing, javax.swing.GroupLayout.PREFERRED_SIZE, 18, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0).addComponent(btn_threads, javax.swing.GroupLayout.PREFERRED_SIZE, 18, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0).addComponent(btn_trace, javax.swing.GroupLayout.PREFERRED_SIZE, 18, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0).addComponent(btn_track, javax.swing.GroupLayout.PREFERRED_SIZE, 18, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0).addComponent(btn_trigger, javax.swing.GroupLayout.PREFERRED_SIZE, 18, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0).addComponent(btn_uniform_fs, javax.swing.GroupLayout.PREFERRED_SIZE, 18, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0).addComponent(btn_verbosity, javax.swing.GroupLayout.PREFERRED_SIZE, 18, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0).addComponent(btn_comment_settings, javax.swing.GroupLayout.PREFERRED_SIZE, 18, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0)));
jInternalFrame10.setTitle("OpenMC XML Editor");
jInternalFrame10.setVisible(true);
jScrollPane5.setViewportView(settingsTxt);
javax.swing.GroupLayout jInternalFrame10Layout = new javax.swing.GroupLayout(jInternalFrame10.getContentPane());
jInternalFrame10.getContentPane().setLayout(jInternalFrame10Layout);
jInternalFrame10Layout.setHorizontalGroup(jInternalFrame10Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(jInternalFrame10Layout.createSequentialGroup().addGap(0, 0, 0).addComponent(jScrollPane5, javax.swing.GroupLayout.DEFAULT_SIZE, 799, Short.MAX_VALUE).addGap(0, 0, 0)));
jInternalFrame10Layout.setVerticalGroup(jInternalFrame10Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(jInternalFrame10Layout.createSequentialGroup().addGap(0, 0, 0).addComponent(jScrollPane5, javax.swing.GroupLayout.PREFERRED_SIZE, 500, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0)));
jInternalFrame11.setTitle("OpenMC commands guidance");
jInternalFrame11.setVisible(true);
Guide.setBackground(java.awt.SystemColor.text);
Guide.setColumns(20);
// NOI18N
Guide.setFont(new java.awt.Font("Ubuntu", 0, 12));
Guide.setLineWrap(true);
Guide.setRows(5);
Guide.setWrapStyleWord(true);
jScrollPane14.setViewportView(Guide);
javax.swing.GroupLayout jInternalFrame11Layout = new javax.swing.GroupLayout(jInternalFrame11.getContentPane());
jInternalFrame11.getContentPane().setLayout(jInternalFrame11Layout);
jInternalFrame11Layout.setHorizontalGroup(jInternalFrame11Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(jInternalFrame11Layout.createSequentialGroup().addGap(0, 0, 0).addComponent(jScrollPane14, javax.swing.GroupLayout.DEFAULT_SIZE, 1010, Short.MAX_VALUE).addGap(0, 0, 0)));
jInternalFrame11Layout.setVerticalGroup(jInternalFrame11Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(jInternalFrame11Layout.createSequentialGroup().addGap(0, 0, 0).addComponent(jScrollPane14, javax.swing.GroupLayout.DEFAULT_SIZE, 102, Short.MAX_VALUE).addGap(0, 0, 0)));
javax.swing.GroupLayout settings_pnlLayout = new javax.swing.GroupLayout(settings_pnl);
settings_pnl.setLayout(settings_pnlLayout);
settings_pnlLayout.setHorizontalGroup(settings_pnlLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(settings_pnlLayout.createSequentialGroup().addComponent(jInternalFrame9, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0).addComponent(jInternalFrame10)).addComponent(jInternalFrame11));
settings_pnlLayout.setVerticalGroup(settings_pnlLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(settings_pnlLayout.createSequentialGroup().addGap(2, 2, 2).addGroup(settings_pnlLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(jInternalFrame9, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(jInternalFrame10, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addGap(0, 0, 0).addComponent(jInternalFrame11)));
container.addTab("Settings ", settings_pnl);
tallies_pnl.setBackground(java.awt.SystemColor.activeCaption);
jInternalFrame7.setTitle("OpenMC commands");
jInternalFrame7.setVisible(true);
btn_comment_tallies.setBackground(new java.awt.Color(0, 0, 154));
btn_comment_tallies.setForeground(new java.awt.Color(255, 255, 204));
btn_comment_tallies.setText("comment");
btn_comment_tallies.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
btn_comment_tallies.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
btn_comment_tallies.setFocusPainted(false);
btn_comment_tallies.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseExited(java.awt.event.MouseEvent evt) {
btn_comment_talliesMouseExited(evt);
}
public void mouseEntered(java.awt.event.MouseEvent evt) {
btn_comment_talliesMouseEntered(evt);
}
});
btn_comment_tallies.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
btn_comment_talliesActionPerformed(evt);
}
});
btn_mesh.setBackground(new java.awt.Color(0, 0, 154));
btn_mesh.setForeground(new java.awt.Color(255, 255, 204));
btn_mesh.setText("mesh");
btn_mesh.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
btn_mesh.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
btn_mesh.setFocusPainted(false);
btn_mesh.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
btn_meshMouseClicked(evt);
}
public void mouseExited(java.awt.event.MouseEvent evt) {
btn_meshMouseExited(evt);
}
public void mouseEntered(java.awt.event.MouseEvent evt) {
btn_meshMouseEntered(evt);
}
});
btn_mesh.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
btn_meshActionPerformed(evt);
}
});
btn_tally.setBackground(new java.awt.Color(0, 0, 154));
btn_tally.setForeground(new java.awt.Color(255, 255, 204));
btn_tally.setText("tally");
btn_tally.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
btn_tally.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
btn_tally.setFocusPainted(false);
btn_tally.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseExited(java.awt.event.MouseEvent evt) {
btn_tallyMouseExited(evt);
}
public void mouseEntered(java.awt.event.MouseEvent evt) {
btn_tallyMouseEntered(evt);
}
});
btn_tally.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
btn_tallyActionPerformed(evt);
}
});
btn_assume_separate.setBackground(new java.awt.Color(0, 0, 154));
btn_assume_separate.setForeground(new java.awt.Color(255, 255, 204));
btn_assume_separate.setText("assume_separate");
btn_assume_separate.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
btn_assume_separate.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
btn_assume_separate.setFocusPainted(false);
btn_assume_separate.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseExited(java.awt.event.MouseEvent evt) {
btn_assume_separateMouseExited(evt);
}
public void mouseEntered(java.awt.event.MouseEvent evt) {
btn_assume_separateMouseEntered(evt);
}
});
btn_assume_separate.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
btn_assume_separateActionPerformed(evt);
}
});
javax.swing.GroupLayout jInternalFrame7Layout = new javax.swing.GroupLayout(jInternalFrame7.getContentPane());
jInternalFrame7.getContentPane().setLayout(jInternalFrame7Layout);
jInternalFrame7Layout.setHorizontalGroup(jInternalFrame7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(jInternalFrame7Layout.createSequentialGroup().addGap(0, 0, 0).addGroup(jInternalFrame7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING, false).addComponent(btn_mesh, javax.swing.GroupLayout.Alignment.LEADING, javax.swing.GroupLayout.PREFERRED_SIZE, 200, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(btn_assume_separate, javax.swing.GroupLayout.PREFERRED_SIZE, 200, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(btn_tally, javax.swing.GroupLayout.Alignment.LEADING, javax.swing.GroupLayout.PREFERRED_SIZE, 200, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(btn_comment_tallies, javax.swing.GroupLayout.PREFERRED_SIZE, 200, javax.swing.GroupLayout.PREFERRED_SIZE)).addGap(0, 0, 0)));
jInternalFrame7Layout.setVerticalGroup(jInternalFrame7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(jInternalFrame7Layout.createSequentialGroup().addGap(0, 0, 0).addComponent(btn_tally, javax.swing.GroupLayout.PREFERRED_SIZE, 21, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0).addComponent(btn_mesh, javax.swing.GroupLayout.PREFERRED_SIZE, 21, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0).addComponent(btn_assume_separate, javax.swing.GroupLayout.PREFERRED_SIZE, 21, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0).addComponent(btn_comment_tallies, javax.swing.GroupLayout.PREFERRED_SIZE, 21, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0)));
jInternalFrame8.setTitle("OpenMC XML Editor");
jInternalFrame8.setVisible(true);
jScrollPane8.setViewportView(talliesTxt);
javax.swing.GroupLayout jInternalFrame8Layout = new javax.swing.GroupLayout(jInternalFrame8.getContentPane());
jInternalFrame8.getContentPane().setLayout(jInternalFrame8Layout);
jInternalFrame8Layout.setHorizontalGroup(jInternalFrame8Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(jInternalFrame8Layout.createSequentialGroup().addGap(0, 0, 0).addComponent(jScrollPane8, javax.swing.GroupLayout.DEFAULT_SIZE, 799, Short.MAX_VALUE).addGap(0, 0, 0)));
jInternalFrame8Layout.setVerticalGroup(jInternalFrame8Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(jInternalFrame8Layout.createSequentialGroup().addGap(0, 0, 0).addComponent(jScrollPane8, javax.swing.GroupLayout.PREFERRED_SIZE, 500, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0)));
jInternalFrame12.setTitle("OpenMC commands guidance");
jInternalFrame12.setVisible(true);
guide_tallies.setBackground(java.awt.SystemColor.text);
guide_tallies.setColumns(20);
// NOI18N
guide_tallies.setFont(new java.awt.Font("Ubuntu", 0, 12));
guide_tallies.setLineWrap(true);
guide_tallies.setRows(5);
guide_tallies.setWrapStyleWord(true);
jScrollPane20.setViewportView(guide_tallies);
javax.swing.GroupLayout jInternalFrame12Layout = new javax.swing.GroupLayout(jInternalFrame12.getContentPane());
jInternalFrame12.getContentPane().setLayout(jInternalFrame12Layout);
jInternalFrame12Layout.setHorizontalGroup(jInternalFrame12Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(jInternalFrame12Layout.createSequentialGroup().addGap(0, 0, 0).addComponent(jScrollPane20, javax.swing.GroupLayout.DEFAULT_SIZE, 1010, Short.MAX_VALUE).addGap(0, 0, 0)));
jInternalFrame12Layout.setVerticalGroup(jInternalFrame12Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(jInternalFrame12Layout.createSequentialGroup().addGap(0, 0, 0).addComponent(jScrollPane20, javax.swing.GroupLayout.DEFAULT_SIZE, 102, Short.MAX_VALUE).addGap(0, 0, 0)));
javax.swing.GroupLayout tallies_pnlLayout = new javax.swing.GroupLayout(tallies_pnl);
tallies_pnl.setLayout(tallies_pnlLayout);
tallies_pnlLayout.setHorizontalGroup(tallies_pnlLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(tallies_pnlLayout.createSequentialGroup().addComponent(jInternalFrame7, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0).addComponent(jInternalFrame8)).addComponent(jInternalFrame12));
tallies_pnlLayout.setVerticalGroup(tallies_pnlLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(javax.swing.GroupLayout.Alignment.TRAILING, tallies_pnlLayout.createSequentialGroup().addGap(2, 2, 2).addGroup(tallies_pnlLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(jInternalFrame7, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(jInternalFrame8, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addGap(0, 0, 0).addComponent(jInternalFrame12)));
container.addTab("Tallies ", tallies_pnl);
cmfd_pnl.setBackground(java.awt.SystemColor.activeCaption);
jInternalFrame13.setTitle("OpenMC commands");
jInternalFrame13.setVisible(true);
btn_mesh_cmfd.setBackground(new java.awt.Color(0, 0, 154));
btn_mesh_cmfd.setForeground(new java.awt.Color(255, 255, 204));
btn_mesh_cmfd.setText("mesh");
btn_mesh_cmfd.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
btn_mesh_cmfd.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
btn_mesh_cmfd.setFocusPainted(false);
btn_mesh_cmfd.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseExited(java.awt.event.MouseEvent evt) {
btn_mesh_cmfdMouseExited(evt);
}
public void mouseEntered(java.awt.event.MouseEvent evt) {
btn_mesh_cmfdMouseEntered(evt);
}
});
btn_mesh_cmfd.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
btn_mesh_cmfdActionPerformed(evt);
}
});
btn_gauss_seidel_tolerance.setBackground(new java.awt.Color(0, 0, 154));
btn_gauss_seidel_tolerance.setForeground(new java.awt.Color(255, 255, 204));
btn_gauss_seidel_tolerance.setText("gauss_seidel_tolerance");
btn_gauss_seidel_tolerance.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
btn_gauss_seidel_tolerance.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
btn_gauss_seidel_tolerance.setFocusPainted(false);
btn_gauss_seidel_tolerance.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseExited(java.awt.event.MouseEvent evt) {
btn_gauss_seidel_toleranceMouseExited(evt);
}
public void mouseEntered(java.awt.event.MouseEvent evt) {
btn_gauss_seidel_toleranceMouseEntered(evt);
}
});
btn_gauss_seidel_tolerance.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
btn_gauss_seidel_toleranceActionPerformed(evt);
}
});
btn_norm.setBackground(new java.awt.Color(0, 0, 154));
btn_norm.setForeground(new java.awt.Color(255, 255, 204));
btn_norm.setText("norm");
btn_norm.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
btn_norm.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
btn_norm.setFocusPainted(false);
btn_norm.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseExited(java.awt.event.MouseEvent evt) {
btn_normMouseExited(evt);
}
public void mouseEntered(java.awt.event.MouseEvent evt) {
btn_normMouseEntered(evt);
}
});
btn_norm.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
btn_normActionPerformed(evt);
}
});
btn_power_monitor.setBackground(new java.awt.Color(0, 0, 154));
btn_power_monitor.setForeground(new java.awt.Color(255, 255, 204));
btn_power_monitor.setText("power_monitor");
btn_power_monitor.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
btn_power_monitor.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
btn_power_monitor.setFocusPainted(false);
btn_power_monitor.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseExited(java.awt.event.MouseEvent evt) {
btn_power_monitorMouseExited(evt);
}
public void mouseEntered(java.awt.event.MouseEvent evt) {
btn_power_monitorMouseEntered(evt);
}
});
btn_power_monitor.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
btn_power_monitorActionPerformed(evt);
}
});
btn_write_matrices.setBackground(new java.awt.Color(0, 0, 154));
btn_write_matrices.setForeground(new java.awt.Color(255, 255, 204));
btn_write_matrices.setText("write_matrices");
btn_write_matrices.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
btn_write_matrices.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
btn_write_matrices.setFocusPainted(false);
btn_write_matrices.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseExited(java.awt.event.MouseEvent evt) {
btn_write_matricesMouseExited(evt);
}
public void mouseEntered(java.awt.event.MouseEvent evt) {
btn_write_matricesMouseEntered(evt);
}
});
btn_write_matrices.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
btn_write_matricesActionPerformed(evt);
}
});
btn_dhat_set.setBackground(new java.awt.Color(0, 0, 154));
btn_dhat_set.setForeground(new java.awt.Color(255, 255, 204));
btn_dhat_set.setText("dhat_set");
btn_dhat_set.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
btn_dhat_set.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
btn_dhat_set.setFocusPainted(false);
btn_dhat_set.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseExited(java.awt.event.MouseEvent evt) {
btn_dhat_setMouseExited(evt);
}
public void mouseEntered(java.awt.event.MouseEvent evt) {
btn_dhat_setMouseEntered(evt);
}
});
btn_dhat_set.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
btn_dhat_setActionPerformed(evt);
}
});
btn_tally_reset.setBackground(new java.awt.Color(0, 0, 154));
btn_tally_reset.setForeground(new java.awt.Color(255, 255, 204));
btn_tally_reset.setText("tally_reset");
btn_tally_reset.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
btn_tally_reset.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
btn_tally_reset.setFocusPainted(false);
btn_tally_reset.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
btn_tally_resetMouseClicked(evt);
}
public void mouseExited(java.awt.event.MouseEvent evt) {
btn_tally_resetMouseExited(evt);
}
public void mouseEntered(java.awt.event.MouseEvent evt) {
btn_tally_resetMouseEntered(evt);
}
});
btn_tally_reset.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
btn_tally_resetActionPerformed(evt);
}
});
btn_display.setBackground(new java.awt.Color(0, 0, 154));
btn_display.setForeground(new java.awt.Color(255, 255, 204));
btn_display.setText("display");
btn_display.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
btn_display.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
btn_display.setFocusPainted(false);
btn_display.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseExited(java.awt.event.MouseEvent evt) {
btn_displayMouseExited(evt);
}
public void mouseEntered(java.awt.event.MouseEvent evt) {
btn_displayMouseEntered(evt);
}
});
btn_display.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
btn_displayActionPerformed(evt);
}
});
btn_shift.setBackground(new java.awt.Color(0, 0, 154));
btn_shift.setForeground(new java.awt.Color(255, 255, 204));
btn_shift.setText("shift");
btn_shift.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
btn_shift.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
btn_shift.setFocusPainted(false);
btn_shift.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseExited(java.awt.event.MouseEvent evt) {
btn_shiftMouseExited(evt);
}
public void mouseEntered(java.awt.event.MouseEvent evt) {
btn_shiftMouseEntered(evt);
}
});
btn_shift.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
btn_shiftActionPerformed(evt);
}
});
btn_begin.setBackground(new java.awt.Color(0, 0, 154));
btn_begin.setForeground(new java.awt.Color(255, 255, 204));
btn_begin.setText("begin");
btn_begin.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
btn_begin.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
btn_begin.setFocusPainted(false);
btn_begin.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseExited(java.awt.event.MouseEvent evt) {
btn_beginMouseExited(evt);
}
public void mouseEntered(java.awt.event.MouseEvent evt) {
btn_beginMouseEntered(evt);
}
});
btn_begin.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
btn_beginActionPerformed(evt);
}
});
btn_downscatter.setBackground(new java.awt.Color(0, 0, 154));
btn_downscatter.setForeground(new java.awt.Color(255, 255, 204));
btn_downscatter.setText("downscatter");
btn_downscatter.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
btn_downscatter.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
btn_downscatter.setFocusPainted(false);
btn_downscatter.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseExited(java.awt.event.MouseEvent evt) {
btn_downscatterMouseExited(evt);
}
public void mouseEntered(java.awt.event.MouseEvent evt) {
btn_downscatterMouseEntered(evt);
}
});
btn_downscatter.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
btn_downscatterActionPerformed(evt);
}
});
run_adjoint.setBackground(new java.awt.Color(0, 0, 154));
run_adjoint.setForeground(new java.awt.Color(255, 255, 204));
run_adjoint.setText("run_adjoint");
run_adjoint.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
run_adjoint.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
run_adjoint.setFocusPainted(false);
run_adjoint.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseExited(java.awt.event.MouseEvent evt) {
run_adjointMouseExited(evt);
}
public void mouseEntered(java.awt.event.MouseEvent evt) {
run_adjointMouseEntered(evt);
}
});
run_adjoint.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
run_adjointActionPerformed(evt);
}
});
btn_comment_cmfd.setBackground(new java.awt.Color(0, 0, 154));
btn_comment_cmfd.setForeground(new java.awt.Color(255, 255, 204));
btn_comment_cmfd.setText("comment");
btn_comment_cmfd.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
btn_comment_cmfd.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
btn_comment_cmfd.setFocusPainted(false);
btn_comment_cmfd.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseExited(java.awt.event.MouseEvent evt) {
btn_comment_cmfdMouseExited(evt);
}
public void mouseEntered(java.awt.event.MouseEvent evt) {
btn_comment_cmfdMouseEntered(evt);
}
});
btn_comment_cmfd.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
btn_comment_cmfdActionPerformed(evt);
}
});
btn_stol.setBackground(new java.awt.Color(0, 0, 154));
btn_stol.setForeground(new java.awt.Color(255, 255, 204));
btn_stol.setText("stol");
btn_stol.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
btn_stol.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
btn_stol.setFocusPainted(false);
btn_stol.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseExited(java.awt.event.MouseEvent evt) {
btn_stolMouseExited(evt);
}
public void mouseEntered(java.awt.event.MouseEvent evt) {
btn_stolMouseEntered(evt);
}
});
btn_stol.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
btn_stolActionPerformed(evt);
}
});
btn_ktol.setBackground(new java.awt.Color(0, 0, 154));
btn_ktol.setForeground(new java.awt.Color(255, 255, 204));
btn_ktol.setText("ktol");
btn_ktol.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
btn_ktol.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
btn_ktol.setFocusPainted(false);
btn_ktol.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseExited(java.awt.event.MouseEvent evt) {
btn_ktolMouseExited(evt);
}
public void mouseEntered(java.awt.event.MouseEvent evt) {
btn_ktolMouseEntered(evt);
}
});
btn_ktol.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
btn_ktolActionPerformed(evt);
}
});
btn_feedback.setBackground(new java.awt.Color(0, 0, 154));
btn_feedback.setForeground(new java.awt.Color(255, 255, 204));
btn_feedback.setText("feedback");
btn_feedback.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
btn_feedback.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
btn_feedback.setFocusPainted(false);
btn_feedback.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseExited(java.awt.event.MouseEvent evt) {
btn_feedbackMouseExited(evt);
}
public void mouseEntered(java.awt.event.MouseEvent evt) {
btn_feedbackMouseEntered(evt);
}
});
btn_feedback.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
btn_feedbackActionPerformed(evt);
}
});
btn_spectral.setBackground(new java.awt.Color(0, 0, 154));
btn_spectral.setForeground(new java.awt.Color(255, 255, 204));
btn_spectral.setText("spectral");
btn_spectral.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
btn_spectral.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
btn_spectral.setFocusPainted(false);
btn_spectral.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseExited(java.awt.event.MouseEvent evt) {
btn_spectralMouseExited(evt);
}
public void mouseEntered(java.awt.event.MouseEvent evt) {
btn_spectralMouseEntered(evt);
}
});
btn_spectral.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
btn_spectralActionPerformed(evt);
}
});
javax.swing.GroupLayout jInternalFrame13Layout = new javax.swing.GroupLayout(jInternalFrame13.getContentPane());
jInternalFrame13.getContentPane().setLayout(jInternalFrame13Layout);
jInternalFrame13Layout.setHorizontalGroup(jInternalFrame13Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(jInternalFrame13Layout.createSequentialGroup().addGap(0, 0, 0).addGroup(jInternalFrame13Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(btn_dhat_set, javax.swing.GroupLayout.PREFERRED_SIZE, 200, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(btn_stol, javax.swing.GroupLayout.PREFERRED_SIZE, 200, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(btn_begin, javax.swing.GroupLayout.PREFERRED_SIZE, 200, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(btn_display, javax.swing.GroupLayout.PREFERRED_SIZE, 200, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(btn_gauss_seidel_tolerance, javax.swing.GroupLayout.PREFERRED_SIZE, 200, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(btn_ktol, javax.swing.GroupLayout.PREFERRED_SIZE, 200, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(btn_mesh_cmfd, javax.swing.GroupLayout.PREFERRED_SIZE, 200, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(btn_norm, javax.swing.GroupLayout.PREFERRED_SIZE, 200, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(run_adjoint, javax.swing.GroupLayout.PREFERRED_SIZE, 200, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(btn_shift, javax.swing.GroupLayout.PREFERRED_SIZE, 200, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(btn_spectral, javax.swing.GroupLayout.PREFERRED_SIZE, 200, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(btn_downscatter, javax.swing.GroupLayout.PREFERRED_SIZE, 200, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(btn_feedback, javax.swing.GroupLayout.PREFERRED_SIZE, 200, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(btn_power_monitor, javax.swing.GroupLayout.PREFERRED_SIZE, 200, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(btn_write_matrices, javax.swing.GroupLayout.PREFERRED_SIZE, 200, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(btn_tally_reset, javax.swing.GroupLayout.PREFERRED_SIZE, 200, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(btn_comment_cmfd, javax.swing.GroupLayout.PREFERRED_SIZE, 200, javax.swing.GroupLayout.PREFERRED_SIZE)).addGap(0, 0, 0)));
jInternalFrame13Layout.setVerticalGroup(jInternalFrame13Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(jInternalFrame13Layout.createSequentialGroup().addGap(0, 0, 0).addComponent(btn_begin, javax.swing.GroupLayout.PREFERRED_SIZE, 21, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0).addComponent(btn_dhat_set, javax.swing.GroupLayout.PREFERRED_SIZE, 21, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0).addComponent(btn_display, javax.swing.GroupLayout.PREFERRED_SIZE, 21, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0).addComponent(btn_downscatter, javax.swing.GroupLayout.PREFERRED_SIZE, 21, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0).addComponent(btn_feedback, javax.swing.GroupLayout.PREFERRED_SIZE, 21, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0).addComponent(btn_gauss_seidel_tolerance, javax.swing.GroupLayout.PREFERRED_SIZE, 21, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0).addComponent(btn_ktol, javax.swing.GroupLayout.PREFERRED_SIZE, 21, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0).addComponent(btn_mesh_cmfd, javax.swing.GroupLayout.PREFERRED_SIZE, 21, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0).addComponent(btn_norm, javax.swing.GroupLayout.PREFERRED_SIZE, 21, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0).addComponent(btn_power_monitor, javax.swing.GroupLayout.PREFERRED_SIZE, 21, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0).addComponent(run_adjoint, javax.swing.GroupLayout.PREFERRED_SIZE, 21, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0).addComponent(btn_shift, javax.swing.GroupLayout.PREFERRED_SIZE, 21, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0).addComponent(btn_spectral, javax.swing.GroupLayout.PREFERRED_SIZE, 21, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0).addComponent(btn_stol, javax.swing.GroupLayout.PREFERRED_SIZE, 21, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0).addComponent(btn_tally_reset, javax.swing.GroupLayout.PREFERRED_SIZE, 21, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0).addComponent(btn_write_matrices, javax.swing.GroupLayout.PREFERRED_SIZE, 21, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0).addComponent(btn_comment_cmfd, javax.swing.GroupLayout.PREFERRED_SIZE, 21, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0)));
jInternalFrame14.setTitle("OpenMC XML Editor");
jInternalFrame14.setVisible(true);
jScrollPane9.setViewportView(cmfdTxt);
javax.swing.GroupLayout jInternalFrame14Layout = new javax.swing.GroupLayout(jInternalFrame14.getContentPane());
jInternalFrame14.getContentPane().setLayout(jInternalFrame14Layout);
jInternalFrame14Layout.setHorizontalGroup(jInternalFrame14Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(jInternalFrame14Layout.createSequentialGroup().addGap(0, 0, 0).addComponent(jScrollPane9, javax.swing.GroupLayout.DEFAULT_SIZE, 799, Short.MAX_VALUE).addGap(0, 0, 0)));
jInternalFrame14Layout.setVerticalGroup(jInternalFrame14Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(jInternalFrame14Layout.createSequentialGroup().addGap(0, 0, 0).addComponent(jScrollPane9, javax.swing.GroupLayout.PREFERRED_SIZE, 500, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0)));
jInternalFrame15.setTitle("OpenMC commands guidance");
jInternalFrame15.setVisible(true);
Guidecmfd.setBackground(java.awt.SystemColor.text);
Guidecmfd.setColumns(20);
// NOI18N
Guidecmfd.setFont(new java.awt.Font("Ubuntu", 0, 12));
Guidecmfd.setLineWrap(true);
Guidecmfd.setRows(5);
Guidecmfd.setWrapStyleWord(true);
jScrollPane21.setViewportView(Guidecmfd);
javax.swing.GroupLayout jInternalFrame15Layout = new javax.swing.GroupLayout(jInternalFrame15.getContentPane());
jInternalFrame15.getContentPane().setLayout(jInternalFrame15Layout);
jInternalFrame15Layout.setHorizontalGroup(jInternalFrame15Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(jInternalFrame15Layout.createSequentialGroup().addGap(0, 0, 0).addComponent(jScrollPane21, javax.swing.GroupLayout.DEFAULT_SIZE, 1010, Short.MAX_VALUE).addGap(0, 0, 0)));
jInternalFrame15Layout.setVerticalGroup(jInternalFrame15Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(jInternalFrame15Layout.createSequentialGroup().addGap(0, 0, 0).addComponent(jScrollPane21, javax.swing.GroupLayout.DEFAULT_SIZE, 102, Short.MAX_VALUE).addGap(0, 0, 0)));
javax.swing.GroupLayout cmfd_pnlLayout = new javax.swing.GroupLayout(cmfd_pnl);
cmfd_pnl.setLayout(cmfd_pnlLayout);
cmfd_pnlLayout.setHorizontalGroup(cmfd_pnlLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(cmfd_pnlLayout.createSequentialGroup().addComponent(jInternalFrame13, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0).addComponent(jInternalFrame14)).addComponent(jInternalFrame15));
cmfd_pnlLayout.setVerticalGroup(cmfd_pnlLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(cmfd_pnlLayout.createSequentialGroup().addGap(2, 2, 2).addGroup(cmfd_pnlLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(jInternalFrame13, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(jInternalFrame14, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addGap(0, 0, 0).addComponent(jInternalFrame15)));
container.addTab("CMFD ", cmfd_pnl);
plotting_pnl.setBackground(java.awt.SystemColor.activeCaption);
jInternalFrame16.setTitle("OpenMC commands");
jInternalFrame16.setVisible(true);
btn_comment_plotting.setBackground(new java.awt.Color(0, 0, 154));
btn_comment_plotting.setForeground(new java.awt.Color(255, 255, 204));
btn_comment_plotting.setText("comment");
btn_comment_plotting.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
btn_comment_plotting.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
btn_comment_plotting.setFocusPainted(false);
btn_comment_plotting.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseExited(java.awt.event.MouseEvent evt) {
btn_comment_plottingMouseExited(evt);
}
public void mouseEntered(java.awt.event.MouseEvent evt) {
btn_comment_plottingMouseEntered(evt);
}
});
btn_comment_plotting.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
btn_comment_plottingActionPerformed(evt);
}
});
btn_plot_voxel.setBackground(new java.awt.Color(0, 0, 154));
btn_plot_voxel.setForeground(new java.awt.Color(255, 255, 204));
btn_plot_voxel.setText("plot voxel");
btn_plot_voxel.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
btn_plot_voxel.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
btn_plot_voxel.setFocusPainted(false);
btn_plot_voxel.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseExited(java.awt.event.MouseEvent evt) {
btn_plot_voxelMouseExited(evt);
}
public void mouseEntered(java.awt.event.MouseEvent evt) {
btn_plot_voxelMouseEntered(evt);
}
});
btn_plot_voxel.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
btn_plot_voxelActionPerformed(evt);
}
});
btn_plot_slice.setBackground(new java.awt.Color(0, 0, 154));
btn_plot_slice.setForeground(new java.awt.Color(255, 255, 204));
btn_plot_slice.setText("plot slice");
btn_plot_slice.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
btn_plot_slice.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
btn_plot_slice.setFocusPainted(false);
btn_plot_slice.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseExited(java.awt.event.MouseEvent evt) {
btn_plot_sliceMouseExited(evt);
}
public void mouseEntered(java.awt.event.MouseEvent evt) {
btn_plot_sliceMouseEntered(evt);
}
});
btn_plot_slice.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
btn_plot_sliceActionPerformed(evt);
}
});
javax.swing.GroupLayout jInternalFrame16Layout = new javax.swing.GroupLayout(jInternalFrame16.getContentPane());
jInternalFrame16.getContentPane().setLayout(jInternalFrame16Layout);
jInternalFrame16Layout.setHorizontalGroup(jInternalFrame16Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(jInternalFrame16Layout.createSequentialGroup().addGap(0, 0, 0).addGroup(jInternalFrame16Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false).addComponent(btn_plot_voxel, javax.swing.GroupLayout.PREFERRED_SIZE, 200, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(btn_plot_slice, javax.swing.GroupLayout.PREFERRED_SIZE, 200, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(btn_comment_plotting, javax.swing.GroupLayout.PREFERRED_SIZE, 200, javax.swing.GroupLayout.PREFERRED_SIZE)).addGap(0, 0, 0)));
jInternalFrame16Layout.setVerticalGroup(jInternalFrame16Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(jInternalFrame16Layout.createSequentialGroup().addGap(0, 0, 0).addComponent(btn_plot_slice, javax.swing.GroupLayout.PREFERRED_SIZE, 21, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0).addComponent(btn_plot_voxel, javax.swing.GroupLayout.PREFERRED_SIZE, 21, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0).addComponent(btn_comment_plotting, javax.swing.GroupLayout.PREFERRED_SIZE, 21, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0)));
jInternalFrame17.setTitle("OpenMC XML Editor");
jInternalFrame17.setVisible(true);
jScrollPane10.setViewportView(plottingTxt);
javax.swing.GroupLayout jInternalFrame17Layout = new javax.swing.GroupLayout(jInternalFrame17.getContentPane());
jInternalFrame17.getContentPane().setLayout(jInternalFrame17Layout);
jInternalFrame17Layout.setHorizontalGroup(jInternalFrame17Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(jInternalFrame17Layout.createSequentialGroup().addGap(0, 0, 0).addComponent(jScrollPane10, javax.swing.GroupLayout.DEFAULT_SIZE, 799, Short.MAX_VALUE).addGap(0, 0, 0)));
jInternalFrame17Layout.setVerticalGroup(jInternalFrame17Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(jInternalFrame17Layout.createSequentialGroup().addGap(0, 0, 0).addComponent(jScrollPane10, javax.swing.GroupLayout.PREFERRED_SIZE, 500, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0)));
jInternalFrame18.setTitle("OpenMC commands guidance");
jInternalFrame18.setVisible(true);
GuidePlotting.setBackground(java.awt.SystemColor.text);
GuidePlotting.setColumns(20);
// NOI18N
GuidePlotting.setFont(new java.awt.Font("Ubuntu", 0, 12));
GuidePlotting.setLineWrap(true);
GuidePlotting.setRows(5);
GuidePlotting.setWrapStyleWord(true);
jScrollPane22.setViewportView(GuidePlotting);
javax.swing.GroupLayout jInternalFrame18Layout = new javax.swing.GroupLayout(jInternalFrame18.getContentPane());
jInternalFrame18.getContentPane().setLayout(jInternalFrame18Layout);
jInternalFrame18Layout.setHorizontalGroup(jInternalFrame18Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(jInternalFrame18Layout.createSequentialGroup().addGap(0, 0, 0).addComponent(jScrollPane22, javax.swing.GroupLayout.DEFAULT_SIZE, 1010, Short.MAX_VALUE).addGap(0, 0, 0)));
jInternalFrame18Layout.setVerticalGroup(jInternalFrame18Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(jInternalFrame18Layout.createSequentialGroup().addGap(0, 0, 0).addComponent(jScrollPane22, javax.swing.GroupLayout.DEFAULT_SIZE, 102, Short.MAX_VALUE).addGap(0, 0, 0)));
javax.swing.GroupLayout plotting_pnlLayout = new javax.swing.GroupLayout(plotting_pnl);
plotting_pnl.setLayout(plotting_pnlLayout);
plotting_pnlLayout.setHorizontalGroup(plotting_pnlLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(plotting_pnlLayout.createSequentialGroup().addComponent(jInternalFrame16, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, 0).addComponent(jInternalFrame17)).addComponent(jInternalFrame18));
plotting_pnlLayout.setVerticalGroup(plotting_pnlLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(javax.swing.GroupLayout.Alignment.TRAILING, plotting_pnlLayout.createSequentialGroup().addGap(2, 2, 2).addGroup(plotting_pnlLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(jInternalFrame16, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(jInternalFrame17, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addGap(0, 0, 0).addComponent(jInternalFrame18)));
container.addTab("Geometry Plotting ", plotting_pnl);
lbl.setBackground(java.awt.SystemColor.activeCaption);
lbl.setForeground(java.awt.Color.orange);
lbl.setText("Project path");
jMenuBar1.setBorder(javax.swing.BorderFactory.createEtchedBorder());
jMenu3.setBackground(java.awt.Color.orange);
jMenu3.setForeground(java.awt.SystemColor.activeCaption);
jMenu3.setText("File");
menu_new_openmc_project.setAccelerator(javax.swing.KeyStroke.getKeyStroke(java.awt.event.KeyEvent.VK_N, java.awt.event.InputEvent.CTRL_MASK));
menu_new_openmc_project.setText("New OpenMC project");
menu_new_openmc_project.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
menu_new_openmc_projectActionPerformed(evt);
}
});
jMenu3.add(menu_new_openmc_project);
menu_existing_project.setAccelerator(javax.swing.KeyStroke.getKeyStroke(java.awt.event.KeyEvent.VK_O, java.awt.event.InputEvent.CTRL_MASK));
menu_existing_project.setText("Open an existing project");
menu_existing_project.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
menu_existing_projectActionPerformed(evt);
}
});
jMenu3.add(menu_existing_project);
menu_save_project.setAccelerator(javax.swing.KeyStroke.getKeyStroke(java.awt.event.KeyEvent.VK_S, java.awt.event.InputEvent.CTRL_MASK));
menu_save_project.setText("Save project");
menu_save_project.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
menu_save_projectActionPerformed(evt);
}
});
jMenu3.add(menu_save_project);
menu_exit.setAccelerator(javax.swing.KeyStroke.getKeyStroke(java.awt.event.KeyEvent.VK_Q, java.awt.event.InputEvent.ALT_MASK | java.awt.event.InputEvent.CTRL_MASK));
menu_exit.setText("Exit");
menu_exit.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
menu_exitActionPerformed(evt);
}
});
jMenu3.add(menu_exit);
jMenuBar1.add(jMenu3);
jMenu8.setBackground(java.awt.Color.orange);
jMenu8.setForeground(java.awt.SystemColor.activeCaptionText);
jMenu8.setText("OpenMC");
jMenuItem_run_openmc.setAccelerator(javax.swing.KeyStroke.getKeyStroke(java.awt.event.KeyEvent.VK_R, java.awt.event.InputEvent.CTRL_MASK));
jMenuItem_run_openmc.setText("Run OpenMC");
jMenuItem_run_openmc.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
jMenuItem_run_openmcActionPerformed(evt);
}
});
jMenu8.add(jMenuItem_run_openmc);
jMenu_get_openmc.setAccelerator(javax.swing.KeyStroke.getKeyStroke(java.awt.event.KeyEvent.VK_I, java.awt.event.InputEvent.CTRL_MASK));
jMenu_get_openmc.setText("Get OpenMC");
jMenu_get_openmc.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
jMenu_get_openmcActionPerformed(evt);
}
});
jMenu8.add(jMenu_get_openmc);
jMenuBar1.add(jMenu8);
Menu_tools.setBackground(new java.awt.Color(102, 255, 102));
Menu_tools.setText("Tools");
menu_item_show_results.setAccelerator(javax.swing.KeyStroke.getKeyStroke(java.awt.event.KeyEvent.VK_S, java.awt.event.InputEvent.ALT_MASK));
menu_item_show_results.setText("Show results");
menu_item_show_results.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
menu_item_show_resultsActionPerformed(evt);
}
});
Menu_tools.add(menu_item_show_results);
jMenuItem9.setAccelerator(javax.swing.KeyStroke.getKeyStroke(java.awt.event.KeyEvent.VK_H, java.awt.event.InputEvent.ALT_MASK));
jMenuItem9.setText("View HDF5 file");
jMenuItem9.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
jMenuItem9ActionPerformed(evt);
}
});
Menu_tools.add(jMenuItem9);
jMenu4.setText("Geometry visualization");
jMenuItem6.setAccelerator(javax.swing.KeyStroke.getKeyStroke(java.awt.event.KeyEvent.VK_P, java.awt.event.InputEvent.ALT_MASK));
jMenuItem6.setText("PPM file (2D)");
jMenuItem6.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
jMenuItem6ActionPerformed(evt);
}
});
jMenu4.add(jMenuItem6);
jMenuItem7.setAccelerator(javax.swing.KeyStroke.getKeyStroke(java.awt.event.KeyEvent.VK_V, java.awt.event.InputEvent.ALT_MASK));
jMenuItem7.setText("VTI file (3D)");
jMenuItem7.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
jMenuItem7ActionPerformed(evt);
}
});
jMenu4.add(jMenuItem7);
Menu_tools.add(jMenu4);
jMenu6.setText("Data visualization");
jMenuItem5.setAccelerator(javax.swing.KeyStroke.getKeyStroke(java.awt.event.KeyEvent.VK_T, java.awt.event.InputEvent.ALT_MASK));
jMenuItem5.setText("Track visualization");
jMenuItem5.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
jMenuItem5ActionPerformed(evt);
}
});
jMenu6.add(jMenuItem5);
jMenuItem10.setAccelerator(javax.swing.KeyStroke.getKeyStroke(java.awt.event.KeyEvent.VK_M, java.awt.event.InputEvent.ALT_MASK));
jMenuItem10.setText("2D mesh plot");
jMenuItem10.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
jMenuItem10ActionPerformed(evt);
}
});
jMenu6.add(jMenuItem10);
_3d_mesh_plot.setAccelerator(javax.swing.KeyStroke.getKeyStroke(java.awt.event.KeyEvent.VK_N, java.awt.event.InputEvent.ALT_MASK));
_3d_mesh_plot.setText("3D mesh plot");
_3d_mesh_plot.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
_3d_mesh_plotActionPerformed(evt);
}
});
jMenu6.add(_3d_mesh_plot);
Menu_tools.add(jMenu6);
jMenu7.setText("File conversion");
jMenuItem4.setAccelerator(javax.swing.KeyStroke.getKeyStroke(java.awt.event.KeyEvent.VK_V, java.awt.event.InputEvent.ALT_MASK | java.awt.event.InputEvent.SHIFT_MASK));
jMenuItem4.setText("binary VOXEL to VTK");
jMenuItem4.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
jMenuItem4ActionPerformed(evt);
}
});
jMenu7.add(jMenuItem4);
jMenuItem_binary_track_to_pvtp.setAccelerator(javax.swing.KeyStroke.getKeyStroke(java.awt.event.KeyEvent.VK_T, java.awt.event.InputEvent.ALT_MASK | java.awt.event.InputEvent.SHIFT_MASK));
jMenuItem_binary_track_to_pvtp.setText("binary TRACK to PVTP");
jMenuItem_binary_track_to_pvtp.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
jMenuItem_binary_track_to_pvtpActionPerformed(evt);
}
});
jMenu7.add(jMenuItem_binary_track_to_pvtp);
jMenuItem8.setAccelerator(javax.swing.KeyStroke.getKeyStroke(java.awt.event.KeyEvent.VK_M, java.awt.event.InputEvent.ALT_MASK | java.awt.event.InputEvent.SHIFT_MASK));
jMenuItem8.setText("3D MESH to VTM");
jMenuItem8.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
jMenuItem8ActionPerformed(evt);
}
});
jMenu7.add(jMenuItem8);
Menu_tools.add(jMenu7);
Menu_tools.add(jSeparator2);
add_scorers.setAccelerator(javax.swing.KeyStroke.getKeyStroke(java.awt.event.KeyEvent.VK_S, java.awt.event.InputEvent.ALT_MASK));
add_scorers.setText("Add Scorers");
add_scorers.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
add_scorersActionPerformed(evt);
}
});
Menu_tools.add(add_scorers);
menu_item_table_of_nuclides.setAccelerator(javax.swing.KeyStroke.getKeyStroke(java.awt.event.KeyEvent.VK_N, java.awt.event.InputEvent.ALT_MASK | java.awt.event.InputEvent.SHIFT_MASK));
menu_item_table_of_nuclides.setText("Table of nuclides");
menu_item_table_of_nuclides.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
menu_item_table_of_nuclidesActionPerformed(evt);
}
});
Menu_tools.add(menu_item_table_of_nuclides);
jMenuItem2.setAccelerator(javax.swing.KeyStroke.getKeyStroke(java.awt.event.KeyEvent.VK_C, java.awt.event.InputEvent.ALT_MASK));
jMenuItem2.setText("RGB color");
jMenuItem2.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
jMenuItem2ActionPerformed(evt);
}
});
Menu_tools.add(jMenuItem2);
jMenuItem_openmc_xml_validation.setAccelerator(javax.swing.KeyStroke.getKeyStroke(java.awt.event.KeyEvent.VK_V, java.awt.event.InputEvent.SHIFT_MASK | java.awt.event.InputEvent.CTRL_MASK));
jMenuItem_openmc_xml_validation.setText("OpenMC XML validation");
jMenuItem_openmc_xml_validation.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
jMenuItem_openmc_xml_validationActionPerformed(evt);
}
});
Menu_tools.add(jMenuItem_openmc_xml_validation);
jMenuItem11.setAccelerator(javax.swing.KeyStroke.getKeyStroke(java.awt.event.KeyEvent.VK_M, java.awt.event.InputEvent.SHIFT_MASK | java.awt.event.InputEvent.CTRL_MASK));
jMenuItem11.setText("Memory Usage");
jMenuItem11.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
jMenuItem11ActionPerformed(evt);
}
});
Menu_tools.add(jMenuItem11);
Menu_tools.add(jSeparator1);
menu_item_get_openmc.setAccelerator(javax.swing.KeyStroke.getKeyStroke(java.awt.event.KeyEvent.VK_X, java.awt.event.InputEvent.SHIFT_MASK | java.awt.event.InputEvent.CTRL_MASK));
menu_item_get_openmc.setText("Get NNDC data");
menu_item_get_openmc.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
menu_item_get_openmcActionPerformed(evt);
}
});
Menu_tools.add(menu_item_get_openmc);
jMenuItem3.setAccelerator(javax.swing.KeyStroke.getKeyStroke(java.awt.event.KeyEvent.VK_P, java.awt.event.InputEvent.SHIFT_MASK | java.awt.event.InputEvent.CTRL_MASK));
jMenuItem3.setText("Project Tree");
jMenuItem3.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
jMenuItem3ActionPerformed(evt);
}
});
Menu_tools.add(jMenuItem3);
jMenuBar1.add(Menu_tools);
jMenu5.setText(" ?");
menu_item_about.setAccelerator(javax.swing.KeyStroke.getKeyStroke(java.awt.event.KeyEvent.VK_F1, 0));
menu_item_about.setText("About ERN-OpenMC");
menu_item_about.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
menu_item_aboutActionPerformed(evt);
}
});
jMenu5.add(menu_item_about);
jMenuBar1.add(jMenu5);
setJMenuBar(jMenuBar1);
javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());
getContentPane().setLayout(layout);
layout.setHorizontalGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(layout.createSequentialGroup().addGap(0, 0, 0).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(layout.createSequentialGroup().addComponent(lbl).addContainerGap()).addComponent(container, javax.swing.GroupLayout.Alignment.TRAILING))));
layout.setVerticalGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(layout.createSequentialGroup().addGap(0, 0, 0).addComponent(container).addGap(0, 0, 0).addComponent(lbl)));
pack();
setLocationRelativeTo(null);
}Example 63
| Project: CaliphEmir-master File: GeneralActionsPanel.java View source code |
/** This method is called from within the constructor to
* initialize the form.
* WARNING: Do NOT modify this code. The content of this method is
* always regenerated by the Form Editor.
*/
// <editor-fold defaultstate="collapsed" desc=" Generated Code ">//GEN-BEGIN:initComponents
private void initComponents() {
jPanel2 = new javax.swing.JPanel();
jPanel1 = new javax.swing.JPanel();
createIndexButton = new javax.swing.JButton();
showHelpButton = new javax.swing.JButton();
visitHomepageButton = new javax.swing.JButton();
showAboutButton = new javax.swing.JButton();
setLayout(new java.awt.BorderLayout());
jPanel2.setBackground(new java.awt.Color(255, 255, 255));
jPanel1.setLayout(new java.awt.GridLayout(0, 2));
createIndexButton.setBackground(new java.awt.Color(255, 255, 255));
createIndexButton.setIcon(new javax.swing.ImageIcon(getClass().getResource("/resources/icons/actions/index.png")));
createIndexButton.setText("Create Index");
createIndexButton.setActionCommand("wizardIndex");
createIndexButton.setBorder(javax.swing.BorderFactory.createEmptyBorder(5, 5, 5, 5));
createIndexButton.setBorderPainted(false);
createIndexButton.setFocusPainted(false);
createIndexButton.setHorizontalAlignment(javax.swing.SwingConstants.LEADING);
createIndexButton.setPreferredSize(new java.awt.Dimension(130, 50));
jPanel1.add(createIndexButton);
showHelpButton.setBackground(new java.awt.Color(255, 255, 255));
showHelpButton.setIcon(new javax.swing.ImageIcon(getClass().getResource("/resources/icons/actions/help.png")));
showHelpButton.setText("Show Online Help");
showHelpButton.setActionCommand("showHelpOnline");
showHelpButton.setBorder(javax.swing.BorderFactory.createEmptyBorder(5, 5, 5, 5));
showHelpButton.setBorderPainted(false);
showHelpButton.setFocusPainted(false);
showHelpButton.setHorizontalAlignment(javax.swing.SwingConstants.LEADING);
showHelpButton.setPreferredSize(new java.awt.Dimension(130, 50));
jPanel1.add(showHelpButton);
visitHomepageButton.setBackground(new java.awt.Color(255, 255, 255));
visitHomepageButton.setIcon(new javax.swing.ImageIcon(getClass().getResource("/resources/icons/actions/internet.png")));
visitHomepageButton.setText("Visit Homepage");
visitHomepageButton.setActionCommand("visitHomepage");
visitHomepageButton.setBorder(javax.swing.BorderFactory.createEmptyBorder(5, 5, 5, 5));
visitHomepageButton.setBorderPainted(false);
visitHomepageButton.setFocusPainted(false);
visitHomepageButton.setHorizontalAlignment(javax.swing.SwingConstants.LEADING);
visitHomepageButton.setPreferredSize(new java.awt.Dimension(130, 50));
jPanel1.add(visitHomepageButton);
showAboutButton.setBackground(new java.awt.Color(255, 255, 255));
showAboutButton.setIcon(new javax.swing.ImageIcon(getClass().getResource("/resources/icons/actions/about.png")));
showAboutButton.setText("About Emir");
showAboutButton.setActionCommand("about");
showAboutButton.setBorder(javax.swing.BorderFactory.createEmptyBorder(5, 5, 5, 5));
showAboutButton.setBorderPainted(false);
showAboutButton.setFocusPainted(false);
showAboutButton.setHorizontalAlignment(javax.swing.SwingConstants.LEADING);
showAboutButton.setPreferredSize(new java.awt.Dimension(130, 50));
jPanel1.add(showAboutButton);
jPanel2.add(jPanel1);
add(jPanel2, java.awt.BorderLayout.CENTER);
}Example 64
| Project: com.revolsys.open-master File: ColorTable.java View source code |
/* convienance method */
public IndexColorModel getIndexColorModel(int bits) {
int size = GetCount();
byte[] reds = new byte[size];
byte[] greens = new byte[size];
byte[] blues = new byte[size];
byte[] alphas = new byte[size];
int noAlphas = 0;
int zeroAlphas = 0;
int lastAlphaIndex = -1;
Color entry = null;
for (int i = 0; i < size; i++) {
entry = GetColorEntry(i);
reds[i] = (byte) (entry.getRed() & 0xff);
greens[i] = (byte) (entry.getGreen() & 0xff);
blues[i] = (byte) (entry.getBlue() & 0xff);
byte alpha = (byte) (entry.getAlpha() & 0xff);
// The byte type is -128 to 127 so a normal 255 will be -1.
if (alpha == -1)
noAlphas++;
else {
if (alpha == 0) {
zeroAlphas++;
lastAlphaIndex = i;
}
}
alphas[i] = alpha;
}
if (noAlphas == size)
return new IndexColorModel(bits, size, reds, greens, blues);
else if (noAlphas == (size - 1) && zeroAlphas == 1)
return new IndexColorModel(bits, size, reds, greens, blues, lastAlphaIndex);
else
return new IndexColorModel(bits, size, reds, greens, blues, alphas);
}Example 65
| Project: compalg-master File: ConversorParaLC.java View source code |
@SuppressWarnings("unchecked")
private // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
void initComponents() {
jPanel1 = new javax.swing.JPanel();
jLabel1 = new javax.swing.JLabel();
jScrollPane1 = new javax.swing.JScrollPane();
jTextPane1 = new javax.swing.JTextPane();
jPanel2 = new javax.swing.JPanel();
btcancelar = new javax.swing.JButton();
btguardar = new javax.swing.JButton();
btcopiar = new javax.swing.JButton();
setDefaultCloseOperation(javax.swing.WindowConstants.DISPOSE_ON_CLOSE);
setTitle("Programa Java");
setBackground(new java.awt.Color(255, 255, 255));
jPanel1.setBackground(new java.awt.Color(0, 0, 0));
// NOI18N
jLabel1.setIcon(new javax.swing.ImageIcon(getClass().getResource("/Conversor/C1.png")));
javax.swing.GroupLayout jPanel1Layout = new javax.swing.GroupLayout(jPanel1);
jPanel1.setLayout(jPanel1Layout);
jPanel1Layout.setHorizontalGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jPanel1Layout.createSequentialGroup().addContainerGap(31, Short.MAX_VALUE).addComponent(jLabel1).addGap(24, 24, 24)));
jPanel1Layout.setVerticalGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(jPanel1Layout.createSequentialGroup().addContainerGap().addComponent(jLabel1).addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)));
jTextPane1.setBackground(new java.awt.Color(0, 0, 0));
jTextPane1.setEditable(false);
// NOI18N
jTextPane1.setFont(new java.awt.Font("Times New Roman", 0, 18));
jTextPane1.setForeground(new java.awt.Color(255, 255, 255));
jScrollPane1.setViewportView(jTextPane1);
jPanel2.setBackground(new java.awt.Color(255, 255, 255));
jPanel2.setBorder(javax.swing.BorderFactory.createLineBorder(new java.awt.Color(102, 102, 102)));
jPanel2.setForeground(new java.awt.Color(0, 0, 51));
btcancelar.setBackground(new java.awt.Color(102, 153, 255));
// NOI18N
btcancelar.setIcon(new javax.swing.ImageIcon(getClass().getResource("/Conversor/cancelar.png")));
btcancelar.setToolTipText("Volta para o programa em Portugol");
btcancelar.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
btcancelarActionPerformed(evt);
}
});
btguardar.setBackground(new java.awt.Color(102, 153, 255));
// NOI18N
btguardar.setIcon(new javax.swing.ImageIcon(getClass().getResource("/Conversor/guardar.png")));
btguardar.setToolTipText("Guarda a classe");
btguardar.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
btguardarActionPerformed(evt);
}
});
btcopiar.setBackground(new java.awt.Color(102, 153, 255));
// NOI18N
btcopiar.setIcon(new javax.swing.ImageIcon(getClass().getResource("/Conversor/copiar.png")));
btcopiar.setToolTipText("Copia o programa para área de transferência");
btcopiar.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
btcopiarActionPerformed(evt);
}
});
javax.swing.GroupLayout jPanel2Layout = new javax.swing.GroupLayout(jPanel2);
jPanel2.setLayout(jPanel2Layout);
jPanel2Layout.setHorizontalGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(jPanel2Layout.createSequentialGroup().addGap(21, 21, 21).addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(btguardar, javax.swing.GroupLayout.Alignment.TRAILING, javax.swing.GroupLayout.PREFERRED_SIZE, 259, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(btcancelar, javax.swing.GroupLayout.PREFERRED_SIZE, 261, Short.MAX_VALUE).addComponent(btcopiar, javax.swing.GroupLayout.Alignment.TRAILING, javax.swing.GroupLayout.PREFERRED_SIZE, 261, Short.MAX_VALUE)).addContainerGap()));
jPanel2Layout.setVerticalGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(jPanel2Layout.createSequentialGroup().addGap(29, 29, 29).addComponent(btguardar, javax.swing.GroupLayout.PREFERRED_SIZE, 23, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(71, 71, 71).addComponent(btcopiar, javax.swing.GroupLayout.PREFERRED_SIZE, 23, javax.swing.GroupLayout.PREFERRED_SIZE).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 70, Short.MAX_VALUE).addComponent(btcancelar, javax.swing.GroupLayout.PREFERRED_SIZE, 27, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(34, 34, 34)));
javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());
getContentPane().setLayout(layout);
layout.setHorizontalGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(layout.createSequentialGroup().addContainerGap().addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false).addComponent(jPanel1, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE).addComponent(jPanel2, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)).addGap(18, 18, 18).addComponent(jScrollPane1, javax.swing.GroupLayout.PREFERRED_SIZE, 567, javax.swing.GroupLayout.PREFERRED_SIZE).addContainerGap(21, Short.MAX_VALUE)));
layout.setVerticalGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(layout.createSequentialGroup().addGap(14, 14, 14).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(jScrollPane1, javax.swing.GroupLayout.Alignment.TRAILING, javax.swing.GroupLayout.DEFAULT_SIZE, 576, Short.MAX_VALUE).addGroup(layout.createSequentialGroup().addComponent(jPanel1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(jPanel2, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))).addContainerGap(25, Short.MAX_VALUE)));
pack();
}Example 66
| Project: Pixelitor-master File: ParamStateTest.java View source code |
@Parameters
public static Collection<Object[]> instancesToTest() {
FilterParam angleParamStart = new AngleParam("AngleParam", 0);
FilterParam angleParamEnd = new AngleParam("AngleParam", 1);
FilterParam rangeParamStart = new RangeParam("RangeParam", 0, 10, 100);
FilterParam rangeParamEnd = new RangeParam("RangeParam", 0, 100, 100);
FilterParam groupedRangeParamStart = new GroupedRangeParam("GroupedRangeParam", 0, 0, 200);
FilterParam groupedRangeParamEnd = new GroupedRangeParam("GroupedRangeParam", 0, 0, 200);
FilterParam gradientParamStart = new GradientParam("GradientParam", Color.BLACK, Color.GREEN);
FilterParam gradientParamEnd = new GradientParam("GradientParam", BLUE, RED);
FilterParam imagePositionParamStart = new ImagePositionParam("ImagePositionParam", 0.1f, 0.0f);
FilterParam imagePositionParamEnd = new ImagePositionParam("ImagePositionParam", 0.9f, 1.0f);
FilterParam colorParamStart = new ColorParam("ColorParam", RED, FREE_OPACITY);
FilterParam colorParamEnd = new ColorParam("ColorParam", BLUE, FREE_OPACITY);
return Arrays.asList(new Object[][] { { angleParamStart.copyState(), angleParamEnd.copyState() }, { rangeParamStart.copyState(), rangeParamEnd.copyState() }, { groupedRangeParamStart.copyState(), groupedRangeParamEnd.copyState() }, { gradientParamStart.copyState(), gradientParamEnd.copyState() }, { imagePositionParamStart.copyState(), imagePositionParamEnd.copyState() }, { colorParamStart.copyState(), colorParamEnd.copyState() } });
}Example 67
| Project: tinkerpop-master File: GremlinGroovyScriptEngineTypeCheckedTest.java View source code |
@Test
public void shouldTypeCheck() throws Exception {
// with no type checking this should pass
try (GremlinGroovyScriptEngine scriptEngine = new GremlinGroovyScriptEngine()) {
assertEquals(255, scriptEngine.eval("((Object) new java.awt.Color(255, 255, 255)).getRed()"));
}
final TypeCheckedGroovyCustomizer provider = new TypeCheckedGroovyCustomizer();
try (GremlinGroovyScriptEngine scriptEngine = new GremlinGroovyScriptEngine(provider)) {
scriptEngine.eval("((Object) new java.awt.Color(255, 255, 255)).getRed()");
fail("Should have failed type checking");
} catch (ScriptException se) {
final Throwable root = ExceptionUtils.getRootCause(se);
assertEquals(MultipleCompilationErrorsException.class, root.getClass());
assertThat(se.getMessage(), containsString("[Static type checking] - Cannot find matching method java.lang.Object#getRed(). Please check if the declared type is right and if the method exists."));
}
}Example 68
| Project: AP2DX-master File: Drawer.java View source code |
public void paintSonarLines(Graphics g) {
java.awt.Color previousColor = g.getColor();
g.setColor(java.awt.Color.red);
int x1;
int x2;
int y1;
int y2;
double constant = (getSize().height);
for (int i = 0; i < sonarRanges.length; i++) {
double line = (sonarRanges[i] / MAX_VALUE) * constant;
double theta = Math.toRadians(sonarThetas[i]);
//System.out.printf("Theta = %f\n", theta);
x1 = getSize().width / 2;
y1 = getSize().height - 10;
y2 = (int) (getSize().height - 10 - (Math.sin(theta) * line));
x2 = (int) (.5 * getSize().width + (10 + (Math.cos(theta) * line)));
g.drawLine(x1, y1, x2, y2);
}
g.setColor(previousColor);
}Example 69
| Project: ggp-base-master File: JZebraTable.java View source code |
/** Compute zebra background stripe colors. */
private void updateZebraColors() {
if ((rowColors[0] = getBackground()) == null) {
rowColors[0] = rowColors[1] = java.awt.Color.white;
return;
}
final java.awt.Color sel = getSelectionBackground();
if (sel == null) {
rowColors[1] = rowColors[0];
return;
}
final float[] bgHSB = java.awt.Color.RGBtoHSB(rowColors[0].getRed(), rowColors[0].getGreen(), rowColors[0].getBlue(), null);
final float[] selHSB = java.awt.Color.RGBtoHSB(sel.getRed(), sel.getGreen(), sel.getBlue(), null);
rowColors[1] = java.awt.Color.getHSBColor(((selHSB[1] == 0.0) || (selHSB[2] == 0.0)) ? bgHSB[0] : selHSB[0], 0.1f * selHSB[1] + 0.9f * bgHSB[1], bgHSB[2] + ((bgHSB[2] < 0.5f) ? 0.05f : -0.05f));
}Example 70
| Project: MinecraftAutoInstaller-master File: Main.java View source code |
public void setLookandFeel() throws FontFormatException, IOException {
Main.font = Font.createFont(Font.TRUETYPE_FONT, this.getClass().getResourceAsStream("/fonts/NanumBarunGothic.ttf")).deriveFont(Font.PLAIN, 0);
UIManager.put("OptionPane.messageFont", font.deriveFont(Font.PLAIN, 14));
UIManager.put("OptionPane.buttonFont", font.deriveFont(Font.PLAIN, 14));
UIManager.put("FileChooser.listFont", font.deriveFont(Font.PLAIN, 14));
UIManager.put("Button.select", new javax.swing.plaf.ColorUIResource(Color.LIGHT_GRAY));
UIManager.put("ToggleButton.select", new javax.swing.plaf.ColorUIResource(Color.LIGHT_GRAY));
UIManager.put("Button.background", new java.awt.Color(238, 238, 238));
UIManager.put("ToggleButton.background", new java.awt.Color(238, 238, 238));
UIManager.put("Button.font", font.deriveFont(Font.PLAIN, 14));
UIManager.put("Label.font", font.deriveFont(Font.PLAIN, 14));
UIManager.put("ScrollPane.font", font.deriveFont(Font.PLAIN, 14));
UIManager.put("ComboBox.font", font.deriveFont(Font.PLAIN, 14));
UIManager.put("Button.focus", new javax.swing.plaf.ColorUIResource(Color.LIGHT_GRAY));
UIManager.put("Slider.focus", new java.awt.Color(238, 238, 238));
UIManager.put("Slider.altTrackColor", new javax.swing.plaf.ColorUIResource(Color.GRAY));
UIManager.put("Slider.paintThumbArrowShape", true);
UIManager.put("Slider.highlight", new java.awt.Color(238, 238, 238));
UIManager.put("Button.border", new javax.swing.border.LineBorder(new java.awt.Color(238, 238, 238), 4, true));
UIManager.put("ToggleButton.border", new javax.swing.border.LineBorder(new java.awt.Color(238, 238, 238), 4, true));
UIManager.put("OptionPane.background", new javax.swing.plaf.ColorUIResource(Color.WHITE));
UIManager.put("Label.background", new javax.swing.plaf.ColorUIResource(Color.WHITE));
UIManager.put("Panel.background", new javax.swing.plaf.ColorUIResource(Color.WHITE));
UIManager.put("CheckBox.background", new javax.swing.plaf.ColorUIResource(Color.WHITE));
UIManager.put("CheckBox.border", new EmptyBorder(1, 1, 1, 1));
UIManager.put("CheckBox.select", new javax.swing.plaf.ColorUIResource(Color.WHITE));
}Example 71
| Project: spudplayer-master File: JZebraTable.java View source code |
/** Compute zebra background stripe colors. */
private void updateZebraColors() {
if ((rowColors[0] = getBackground()) == null) {
rowColors[0] = rowColors[1] = java.awt.Color.white;
return;
}
final java.awt.Color sel = getSelectionBackground();
if (sel == null) {
rowColors[1] = rowColors[0];
return;
}
final float[] bgHSB = java.awt.Color.RGBtoHSB(rowColors[0].getRed(), rowColors[0].getGreen(), rowColors[0].getBlue(), null);
final float[] selHSB = java.awt.Color.RGBtoHSB(sel.getRed(), sel.getGreen(), sel.getBlue(), null);
rowColors[1] = java.awt.Color.getHSBColor(((selHSB[1] == 0.0) || (selHSB[2] == 0.0)) ? bgHSB[0] : selHSB[0], 0.1f * selHSB[1] + 0.9f * bgHSB[1], bgHSB[2] + ((bgHSB[2] < 0.5f) ? 0.05f : -0.05f));
}Example 72
| Project: SubTools-master File: ZebraJTable.java View source code |
/** Compute zebra background stripe colors. */
private void updateZebraColors() {
if ((rowColors[0] = getBackground()) == null) {
rowColors[0] = rowColors[1] = java.awt.Color.white;
return;
}
final java.awt.Color sel = getSelectionBackground();
if (sel == null) {
rowColors[1] = rowColors[0];
return;
}
final float[] bgHSB = java.awt.Color.RGBtoHSB(rowColors[0].getRed(), rowColors[0].getGreen(), rowColors[0].getBlue(), null);
final float[] selHSB = java.awt.Color.RGBtoHSB(sel.getRed(), sel.getGreen(), sel.getBlue(), null);
rowColors[1] = java.awt.Color.getHSBColor((selHSB[1] == 0.0 || selHSB[2] == 0.0) ? bgHSB[0] : selHSB[0], 0.1f * selHSB[1] + 0.9f * bgHSB[1], bgHSB[2] + ((bgHSB[2] < 0.5f) ? 0.05f : -0.05f));
}Example 73
| Project: Bull-Runner-master File: Gui.java View source code |
/**
* Sets size to be entire screen, and makes visible. Set cursor to be invisible.
*/
public void makeVisible() {
DisplayMode oldMode = device.getDisplayMode();
this.setSize(new Dimension(oldMode.getWidth(), oldMode.getHeight()));
this.validate();
this.setBackground(Color.white);
this.setForeground(Color.white);
getContentPane().setBackground(Color.white);
BufferedImage invisImage = getGraphicsConfiguration().createCompatibleImage(1, 1, Transparency.BITMASK);
Graphics2D g = invisImage.createGraphics();
g.setBackground(new Color(0, 0, 0, 0));
g.clearRect(0, 0, 1, 1);
Cursor invisibleCursor = getToolkit().createCustomCursor(invisImage, new Point(0, 0), "Invisible");
this.setCursor(invisibleCursor);
device.setFullScreenWindow(this);
examplePane.setVisible(false);
}Example 74
| Project: jdatechooser-master File: AppearancesList.java View source code |
private void registerHardCoded() {
registerHardCodedAppearance(new ViewAppearance("Contrast", new CustomCellAppearance(new Color(0, 0, 0), new Color(255, 255, 255), BorderFactory.createLineBorder(new Color(0, 0, 0), 1), new Font("Serif", Font.BOLD, 12), new Color(255, 255, 255), 1), new CustomCellAppearance(new Color(0, 0, 0), new Color(255, 255, 255), BorderFactory.createLineBorder(new Color(255, 255, 255), 1), new Font("Serif", Font.BOLD, 16), new Color(0, 255, 0), 1), new CustomCellAppearance(new Color(0, 0, 0), new Color(255, 255, 255), BorderFactory.createLineBorder(new Color(0, 0, 0), 1), new Font("Serif", Font.BOLD, 14), new Color(0, 255, 0), 1), new CustomCellAppearance(new Color(0, 0, 0), new Color(250, 250, 250), BorderFactory.createLineBorder(new Color(0, 0, 0), 1), new Font("Serif", Font.ITALIC, 12), new Color(0, 0, 255), 1), new CustomCellAppearance(new Color(0, 0, 0), new Color(255, 255, 255), BorderFactory.createLineBorder(new Color(0, 0, 0), 1), new Font("Serif", Font.BOLD, 12), new Color(0, 0, 255), 1), new CustomCellAppearance(new Color(0, 0, 0), new Color(180, 180, 180), BorderFactory.createLineBorder(new Color(0, 0, 0), 1), new Font("Serif", Font.PLAIN, 10), new Color(255, 0, 0), 1), null, true));
registerHardCodedAppearance(new ViewAppearance("Light", new CustomCellAppearance(new Color(255, 255, 255), new Color(0, 0, 0), (Border) null, new Font("Serif", Font.PLAIN, 12), new Color(0, 0, 153), 1), new CustomCellAppearance(new Color(153, 153, 255), new Color(0, 0, 0), (Border) null, new Font("Serif", Font.PLAIN, 12), new Color(0, 0, 102), 1), new CustomCellAppearance(new Color(204, 255, 204), new Color(51, 255, 51), (Border) null, new Font("Serif", Font.PLAIN, 12), new Color(0, 0, 153), 1), new CustomCellAppearance(new Color(255, 255, 255), new Color(0, 0, 102), (Border) null, new Font("Serif", Font.ITALIC, 10), new Color(0, 0, 255), 1), new CustomCellAppearance(new Color(255, 255, 255), new Color(0, 0, 0), (Border) null, new Font("Serif", Font.BOLD, 12), new Color(0, 0, 255), 1), new CustomCellAppearance(new Color(255, 255, 255), new Color(255, 0, 0), (Border) null, new Font("Serif", Font.PLAIN, 12), new Color(255, 0, 0), 1), null, true));
registerHardCodedAppearance(new ViewAppearance("Bordered", new CustomCellAppearance(new Color(204, 204, 204), new Color(0, 0, 249), BorderFactory.createEtchedBorder(EtchedBorder.LOWERED, (Color) null, (Color) null), new Font("Serif", Font.PLAIN, 12), new Color(0, 0, 0), 1), new CustomCellAppearance(new Color(204, 204, 204), new Color(0, 0, 255), BorderFactory.createBevelBorder(BevelBorder.LOWERED, (Color) null, (Color) null, new Color(0, 0, 0), (Color) null), new Font("Serif", Font.BOLD, 12), new Color(0, 0, 102), 1), new CustomCellAppearance(new Color(204, 204, 204), new Color(0, 51, 0), BorderFactory.createEtchedBorder(EtchedBorder.LOWERED, (Color) null, (Color) null), new Font("Serif", Font.PLAIN, 12), new Color(0, 102, 0), 1), new CustomCellAppearance(new Color(204, 204, 204), new Color(102, 102, 102), BorderFactory.createEtchedBorder(EtchedBorder.LOWERED, (Color) null, (Color) null), new Font("Serif", Font.PLAIN, 10), new Color(0, 0, 255), 1), new CustomCellAppearance(new Color(204, 204, 204), new Color(0, 0, 0), BorderFactory.createEtchedBorder(EtchedBorder.LOWERED, (Color) null, (Color) null), new Font("Serif", Font.BOLD, 12), new Color(0, 0, 255), 1), new CustomCellAppearance(new Color(204, 204, 204), new Color(153, 153, 153), BorderFactory.createEtchedBorder(EtchedBorder.LOWERED, (Color) null, (Color) null), new Font("Serif", Font.PLAIN, 12), new Color(255, 0, 0), 1), null, true));
registerHardCodedAppearance(new ViewAppearance("Grey", new CustomCellAppearance(new Color(120, 120, 120), new Color(255, 255, 255), BorderFactory.createLineBorder(new Color(0, 0, 0), 1), new Font("Serif", Font.PLAIN, 12), new Color(255, 255, 255), 1), new CustomCellAppearance(new Color(100, 100, 100), new Color(255, 255, 255), BorderFactory.createLineBorder(new Color(0, 0, 0), 1), new Font("Serif", Font.PLAIN, 12), new Color(0, 255, 0), 1), new CustomCellAppearance(new Color(120, 120, 120), new Color(0, 255, 0), BorderFactory.createLineBorder(new Color(0, 0, 0), 1), new Font("Serif", Font.PLAIN, 12), new Color(0, 255, 0), 1), new CustomCellAppearance(new Color(160, 160, 160), new Color(250, 250, 250), BorderFactory.createLineBorder(new Color(0, 0, 0), 1), new Font("Serif", Font.PLAIN, 12), new Color(0, 0, 255), 1), new CustomCellAppearance(new Color(100, 100, 100), new Color(255, 255, 255), BorderFactory.createLineBorder(new Color(0, 0, 0), 1), new Font("Serif", Font.PLAIN, 12), new Color(0, 0, 255), 1), new CustomCellAppearance(new Color(120, 120, 120), new Color(180, 180, 180), BorderFactory.createLineBorder(new Color(0, 0, 0), 1), new Font("Serif", Font.PLAIN, 12), new Color(255, 0, 0), 1), null, true));
registerHardCodedAppearance(new datechooser.view.appearance.ViewAppearance("Dali", new datechooser.view.appearance.custom.CustomCellAppearance(new java.awt.Color(0, 0, 0), new java.awt.Color(255, 255, 255), (javax.swing.border.Border) null, new java.awt.Font("Serif", java.awt.Font.PLAIN, 12), new java.awt.Color(0, 0, 153), 0.4f), new datechooser.view.appearance.custom.CustomCellAppearance(new java.awt.Color(153, 153, 255), new java.awt.Color(255, 255, 0), (javax.swing.border.Border) null, new java.awt.Font("Serif", java.awt.Font.BOLD, 14), new java.awt.Color(0, 0, 102), 0.2f), new datechooser.view.appearance.custom.CustomCellAppearance(new java.awt.Color(0, 0, 0), new java.awt.Color(51, 255, 51), (javax.swing.border.Border) null, new java.awt.Font("Serif", java.awt.Font.PLAIN, 12), new java.awt.Color(0, 0, 153), 0.5f), new datechooser.view.appearance.custom.CustomCellAppearance(new java.awt.Color(204, 204, 204), new java.awt.Color(0, 0, 102), (javax.swing.border.Border) null, new java.awt.Font("Serif", java.awt.Font.ITALIC, 10), new java.awt.Color(0, 0, 255), 0.4f), new datechooser.view.appearance.custom.CustomCellAppearance(new java.awt.Color(0, 0, 0), new java.awt.Color(255, 255, 255), (javax.swing.border.Border) null, new java.awt.Font("Serif", java.awt.Font.BOLD, 12), new java.awt.Color(0, 0, 255), 0.4f), new datechooser.view.appearance.custom.CustomCellAppearance(new java.awt.Color(255, 0, 0), new java.awt.Color(255, 0, 0), (javax.swing.border.Border) null, new java.awt.Font("Serif", java.awt.Font.PLAIN, 12), new java.awt.Color(255, 0, 0), 0.3f), new datechooser.view.BackRenderer(1, Pictures.getResource("dali.gif")), true, true));
registerHardCodedAppearance(new ViewAppearance(DEFAULT, /*usual*/
new SwingCellAppearance(null, null, Color.BLUE, false, true, new ButtonPainter()), /*selected*/
new SwingCellAppearance(null, null, Color.BLUE, true, true, new ButtonPainter()), /*now*/
new SwingCellAppearance(null, Color.BLUE, Color.BLUE, false, true, new ButtonPainter()), /*scroll*/
new SwingCellAppearance(null, Color.GRAY, Color.BLUE, false, true, new LabelPainter()), /*caption*/
new SwingCellAppearance(null, null, Color.BLUE, false, true, new LabelPainter()), /*disabled*/
new SwingCellAppearance(null, null, Color.RED, false, false, new ButtonPainter()), null, false));
}Example 75
| Project: camsudoku-master File: BpDigitTestGui.java View source code |
/**
* driver
*/
public static void main(String args[]) throws Exception {
System.out.println("begin");
BpDemo3 bd3 = null;
PatternList training = null;
training = new PatternList();
training.reader(new File(TRAIN_FILENAME));
if (args.length == 0) {
bd3 = new BpDemo3(new File(NETWORK_FILENAME));
} else {
bd3 = new BpDemo3(new File(args[0]));
}
BpDigitTestGui bdtg = new BpDigitTestGui("BP Demo 3", bd3, training);
bdtg.setBackground(java.awt.Color.white);
bdtg.setSize(500, 350);
bdtg.setVisible(true);
System.out.println("end");
}Example 76
| Project: ESign-master File: CertificateShowScreen.java View source code |
/**
* This method is called from within the constructor to initialize the form.
* WARNING: Do NOT modify this code. The content of this method is always
* regenerated by the Form Editor.
*/
@SuppressWarnings("unchecked")
private // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
void initComponents() {
userAgreementPane = new javax.swing.JPanel();
userAgreementScroller = new javax.swing.JScrollPane();
userAgreementArea = new javax.swing.JTextArea();
certPane = new javax.swing.JPanel();
certTypes = new javax.swing.JComboBox();
slcCertLabel = new javax.swing.JLabel();
certInfoPane = new javax.swing.JPanel();
certIdentityLabel = new javax.swing.JLabel();
certOwnerText = new javax.swing.JLabel();
certOwnerLabel = new javax.swing.JLabel();
certIdentityText = new javax.swing.JLabel();
certManufacturerLabel = new javax.swing.JLabel();
endDateLabel = new javax.swing.JLabel();
certManufacturerText = new javax.swing.JLabel();
startingDateLabel = new javax.swing.JLabel();
endDateText = new javax.swing.JLabel();
startingDateText = new javax.swing.JLabel();
backBtn = new javax.swing.JButton();
doneBtn = new javax.swing.JButton();
setLayout(null);
userAgreementPane.setBackground(new java.awt.Color(255, 255, 255));
userAgreementPane.setBorder(javax.swing.BorderFactory.createLineBorder(new java.awt.Color(0, 0, 0)));
userAgreementPane.setRequestFocusEnabled(false);
userAgreementPane.setSize(new java.awt.Dimension(260, 250));
userAgreementPane.setLayout(null);
userAgreementArea.setEditable(false);
userAgreementArea.setColumns(20);
userAgreementArea.setLineWrap(true);
userAgreementArea.setRows(5);
userAgreementArea.setText(ScreenProperties.getValue("data_to_be_signed") + Utils.getCurrentDate());
userAgreementArea.setWrapStyleWord(true);
userAgreementArea.setFocusable(false);
userAgreementScroller.setViewportView(userAgreementArea);
userAgreementPane.add(userAgreementScroller);
userAgreementScroller.setBounds(7, 10, 250, 230);
add(userAgreementPane);
userAgreementPane.setBounds(0, 0, 260, 250);
certPane.setBackground(new java.awt.Color(255, 255, 255));
certPane.setBorder(javax.swing.BorderFactory.createLineBorder(new java.awt.Color(0, 0, 0)));
certPane.setSize(new java.awt.Dimension(260, 250));
certPane.setLayout(null);
certPane.setName(Config.certPaneName);
certPane.add(certTypes);
certTypes.setBounds(10, 20, 180, 27);
slcCertLabel.setText(ScreenProperties.getValue("choose_certificate"));
certPane.add(slcCertLabel);
slcCertLabel.setBounds(20, 5, 150, 16);
certInfoPane.setBackground(new java.awt.Color(255, 255, 255));
certInfoPane.setBorder(javax.swing.BorderFactory.createEtchedBorder());
certInfoPane.setName(Config.certInfoPaneName);
certInfoPane.setLayout(null);
certIdentityLabel.setForeground(new java.awt.Color(0, 153, 153));
certIdentityLabel.setText(ScreenProperties.getValue("cert_identity"));
certInfoPane.add(certIdentityLabel);
certIdentityLabel.setBounds(10, 70, 150, 16);
certOwnerText.setText("...");
certInfoPane.add(certOwnerText);
certOwnerText.setBounds(10, 25, 210, 16);
certOwnerLabel.setForeground(new java.awt.Color(0, 153, 153));
certOwnerLabel.setText(ScreenProperties.getValue("cert_owner"));
certInfoPane.add(certOwnerLabel);
certOwnerLabel.setBounds(10, 10, 150, 16);
certIdentityText.setText("...");
certInfoPane.add(certIdentityText);
certIdentityText.setBounds(10, 85, 210, 16);
certManufacturerLabel.setForeground(new java.awt.Color(0, 153, 153));
certManufacturerLabel.setText(ScreenProperties.getValue("cert_manufacturer"));
certInfoPane.add(certManufacturerLabel);
certManufacturerLabel.setBounds(10, 40, 160, 16);
endDateLabel.setForeground(new java.awt.Color(0, 153, 153));
endDateLabel.setText(ScreenProperties.getValue("end_date"));
certInfoPane.add(endDateLabel);
endDateLabel.setBounds(10, 130, 150, 16);
certManufacturerText.setText("...");
certInfoPane.add(certManufacturerText);
certManufacturerText.setBounds(10, 55, 210, 16);
startingDateLabel.setForeground(new java.awt.Color(0, 153, 153));
startingDateLabel.setText(ScreenProperties.getValue("start_date"));
certInfoPane.add(startingDateLabel);
startingDateLabel.setBounds(10, 100, 150, 16);
endDateText.setText("...");
certInfoPane.add(endDateText);
endDateText.setBounds(10, 145, 210, 16);
startingDateText.setText("...");
certInfoPane.add(startingDateText);
startingDateText.setBounds(10, 115, 210, 16);
certPane.add(certInfoPane);
certInfoPane.setBounds(10, 45, 230, 180);
backBtn.setText(ScreenProperties.getValue("back"));
backBtn.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
backBtnActionPerformed(evt);
}
});
certPane.add(backBtn);
backBtn.setBounds(50, 225, 70, 25);
doneBtn.setText(ScreenProperties.getValue("continue"));
doneBtn.setPreferredSize(new java.awt.Dimension(85, 29));
doneBtn.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
doneBtnActionPerformed(evt);
}
});
certPane.add(doneBtn);
doneBtn.setBounds(130, 225, 85, 25);
add(certPane);
certPane.setBounds(270, 0, 260, 250);
}Example 77
| Project: gwar-master File: Bumper.java View source code |
public void draw(java.awt.Graphics g) {
if (this instanceof SpeedBumper) {
g.setColor(java.awt.Color.green);
} else {
//new java.awt.Color(133,57,0));
g.setColor(java.awt.Color.BLUE.darker().darker());
//new java.awt.Color(133,57,0));
g.setColor(java.awt.Color.BLUE.darker().darker());
g.fillRect((int) x, (int) y, (int) width, (int) height);
}
}Example 78
| Project: Open-Quark-master File: GemCodeSyntaxListener.java View source code |
/**
* Lookup the foreground colour for a given scanCode.
* Creation date: (1/30/01 9:08:01 AM)
* @return Style the font to apply
* @param scanCode the scan code (token type)
* @param image the token image
* @param suggestedColour the suggested colour (default or user set) or null
*/
public Color foreColourLookup(int scanCode, String image, Color suggestedColour) {
if (scanCode != org.openquark.cal.compiler.CALTokenTypes.VAR_ID && scanCode != org.openquark.cal.compiler.CALTokenTypes.CONS_ID) {
// simply accept the colour we're given
return suggestedColour;
}
// Modify the colour of identifiers depending on what they actually are
GemEntity entity = null;
int periodPos = image.indexOf('.');
if (periodPos == -1) {
if (Arrays.binarySearch(argumentNames, image) > -1) {
// This is an argument
return ARGUMENT_COLOUR;
}
// See if this is a known type or class
entity = perspective.resolveAmbiguousGemEntity(image);
if (entity == null) {
if (CodeAnalyser.getModulesContainingIdentifier(image, SourceIdentifier.Category.TYPE_CONSTRUCTOR, perspective.getWorkingModuleTypeInfo()).size() > 0) {
// This is a type constructor, found in a module
return USER_TYPE_COLOUR;
} else if (CodeAnalyser.getModulesContainingIdentifier(image, SourceIdentifier.Category.TYPE_CLASS, perspective.getWorkingModuleTypeInfo()).size() > 0) {
// This is a class, found in a module
return USER_CLASS_COLOUR;
} else if (Arrays.binarySearch(localVariableNames, image) > -1) {
// This is a local variable
return LOCAL_VARIABLE_COLOUR;
}
}
} else if (QualifiedName.isValidCompoundName(image)) {
QualifiedName rawImageName = QualifiedName.makeFromCompoundName(image);
ModuleName resolvedModuleName = perspective.getWorkingModuleTypeInfo().getModuleNameResolver().resolve(rawImageName.getModuleName()).getResolvedModuleName();
QualifiedName imageName = QualifiedName.make(resolvedModuleName, rawImageName.getUnqualifiedName());
if (imageName.getModuleName().equals(perspective.getWorkingModuleName()) && (Arrays.binarySearch(argumentNames, image) > -1)) {
// This is an argument
return ARGUMENT_COLOUR;
}
entity = perspective.getVisibleGemEntity(imageName);
if (entity == null) {
if (CodeAnalyser.getVisibleModuleEntity(imageName, SourceIdentifier.Category.TYPE_CONSTRUCTOR, perspective.getWorkingModuleTypeInfo()) != null) {
return USER_TYPE_COLOUR;
} else if (CodeAnalyser.getVisibleModuleEntity(imageName, SourceIdentifier.Category.TYPE_CLASS, perspective.getWorkingModuleTypeInfo()) != null) {
return USER_CLASS_COLOUR;
} else if (imageName.getModuleName().equals(perspective.getWorkingModuleName()) && (Arrays.binarySearch(localVariableNames, image) > -1)) {
return LOCAL_VARIABLE_COLOUR;
}
}
}
if (entity == null) {
return suggestedColour;
}
// We have this in our environment; we should know what it is
boolean cons = entity.isDataConstructor();
//check if constructor
if (cons) {
//System.out.println ("Coloured user defined constructor.");
return USER_CONS_COLOUR;
} else {
//System.out.println ("Coloured user defined SC.");
return USER_SC_COLOUR;
}
}Example 79
| Project: MatrixMover-master File: GeneratorPanel.java View source code |
/** This method is called from within the constructor to
* initialize the form.
* WARNING: Do NOT modify this code. The content of this method is
* always regenerated by the Form Editor.
*/
@SuppressWarnings("unchecked")
private // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
void initComponents() {
java.awt.GridBagConstraints gridBagConstraints;
ledScreen1 = new com.gyver.matrixmover.gui.LedScreen();
sceneSelectionPanel = new javax.swing.JPanel();
bScene1 = new com.gyver.matrixmover.gui.component.JSceneButton();
bScene2 = new com.gyver.matrixmover.gui.component.JSceneButton();
bScene3 = new com.gyver.matrixmover.gui.component.JSceneButton();
bScene4 = new com.gyver.matrixmover.gui.component.JSceneButton();
bScene5 = new com.gyver.matrixmover.gui.component.JSceneButton();
bScene6 = new com.gyver.matrixmover.gui.component.JSceneButton();
bScene7 = new com.gyver.matrixmover.gui.component.JSceneButton();
bScene8 = new com.gyver.matrixmover.gui.component.JSceneButton();
bScene9 = new com.gyver.matrixmover.gui.component.JSceneButton();
bScene10 = new com.gyver.matrixmover.gui.component.JSceneButton();
bScene11 = new com.gyver.matrixmover.gui.component.JSceneButton();
bScene12 = new com.gyver.matrixmover.gui.component.JSceneButton();
bScene13 = new com.gyver.matrixmover.gui.component.JSceneButton();
bScene14 = new com.gyver.matrixmover.gui.component.JSceneButton();
bScene15 = new com.gyver.matrixmover.gui.component.JSceneButton();
bScene16 = new com.gyver.matrixmover.gui.component.JSceneButton();
bScene17 = new com.gyver.matrixmover.gui.component.JSceneButton();
bScene18 = new com.gyver.matrixmover.gui.component.JSceneButton();
bScene19 = new com.gyver.matrixmover.gui.component.JSceneButton();
bScene20 = new com.gyver.matrixmover.gui.component.JSceneButton();
bScene21 = new com.gyver.matrixmover.gui.component.JSceneButton();
bScene22 = new com.gyver.matrixmover.gui.component.JSceneButton();
bScene23 = new com.gyver.matrixmover.gui.component.JSceneButton();
bScene24 = new com.gyver.matrixmover.gui.component.JSceneButton();
bScene25 = new com.gyver.matrixmover.gui.component.JSceneButton();
bScene26 = new com.gyver.matrixmover.gui.component.JSceneButton();
bScene27 = new com.gyver.matrixmover.gui.component.JSceneButton();
bScene28 = new com.gyver.matrixmover.gui.component.JSceneButton();
bScene29 = new com.gyver.matrixmover.gui.component.JSceneButton();
bScene30 = new com.gyver.matrixmover.gui.component.JSceneButton();
bScene31 = new com.gyver.matrixmover.gui.component.JSceneButton();
bScene32 = new com.gyver.matrixmover.gui.component.JSceneButton();
bScene33 = new com.gyver.matrixmover.gui.component.JSceneButton();
bScene34 = new com.gyver.matrixmover.gui.component.JSceneButton();
bScene35 = new com.gyver.matrixmover.gui.component.JSceneButton();
bScene36 = new com.gyver.matrixmover.gui.component.JSceneButton();
setPreferredSize(new java.awt.Dimension(416, 383));
setLayout(new java.awt.GridBagLayout());
ledScreen1.setBorder(javax.swing.BorderFactory.createLineBorder(new java.awt.Color(102, 102, 102)));
ledScreen1.setMinimumSize(new java.awt.Dimension(100, 100));
javax.swing.GroupLayout ledScreen1Layout = new javax.swing.GroupLayout(ledScreen1);
ledScreen1.setLayout(ledScreen1Layout);
ledScreen1Layout.setHorizontalGroup(ledScreen1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGap(0, 325, Short.MAX_VALUE));
ledScreen1Layout.setVerticalGroup(ledScreen1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGap(0, 313, Short.MAX_VALUE));
gridBagConstraints = new java.awt.GridBagConstraints();
gridBagConstraints.gridx = 0;
gridBagConstraints.gridy = 0;
gridBagConstraints.fill = java.awt.GridBagConstraints.BOTH;
gridBagConstraints.ipadx = 50;
gridBagConstraints.ipady = 50;
gridBagConstraints.anchor = java.awt.GridBagConstraints.PAGE_START;
gridBagConstraints.weightx = 1.0;
gridBagConstraints.weighty = 1.0;
gridBagConstraints.insets = new java.awt.Insets(13, 7, 7, 7);
add(ledScreen1, gridBagConstraints);
sceneSelectionPanel.setBorder(javax.swing.BorderFactory.createTitledBorder(javax.swing.BorderFactory.createLineBorder(new java.awt.Color(102, 102, 102)), "Scenes"));
sceneSelectionPanel.setLayout(new java.awt.GridBagLayout());
bScene1.setBorder(javax.swing.BorderFactory.createLineBorder(new java.awt.Color(102, 102, 102)));
bScene1.setText("1");
bScene1.setContentAreaFilled(false);
bScene1.setFont(new java.awt.Font("Dialog", 1, 10));
bScene1.setMaximumSize(new java.awt.Dimension(25, 15));
bScene1.setMinimumSize(new java.awt.Dimension(25, 15));
bScene1.setPreferredSize(new java.awt.Dimension(25, 15));
gridBagConstraints = new java.awt.GridBagConstraints();
gridBagConstraints.gridx = 0;
gridBagConstraints.gridy = 0;
gridBagConstraints.insets = new java.awt.Insets(2, 2, 2, 2);
sceneSelectionPanel.add(bScene1, gridBagConstraints);
bScene2.setBorder(javax.swing.BorderFactory.createLineBorder(new java.awt.Color(102, 102, 102)));
bScene2.setText("2");
bScene2.setContentAreaFilled(false);
bScene2.setFont(new java.awt.Font("Dialog", 1, 10));
bScene2.setMaximumSize(new java.awt.Dimension(25, 15));
bScene2.setMinimumSize(new java.awt.Dimension(25, 15));
bScene2.setPreferredSize(new java.awt.Dimension(25, 15));
gridBagConstraints = new java.awt.GridBagConstraints();
gridBagConstraints.gridx = 1;
gridBagConstraints.gridy = 0;
gridBagConstraints.insets = new java.awt.Insets(2, 2, 2, 2);
sceneSelectionPanel.add(bScene2, gridBagConstraints);
bScene3.setBorder(javax.swing.BorderFactory.createLineBorder(new java.awt.Color(102, 102, 102)));
bScene3.setText("3");
bScene3.setContentAreaFilled(false);
bScene3.setFont(new java.awt.Font("Dialog", 1, 10));
bScene3.setMaximumSize(new java.awt.Dimension(25, 15));
bScene3.setMinimumSize(new java.awt.Dimension(25, 15));
bScene3.setPreferredSize(new java.awt.Dimension(25, 15));
gridBagConstraints = new java.awt.GridBagConstraints();
gridBagConstraints.gridx = 2;
gridBagConstraints.gridy = 0;
gridBagConstraints.insets = new java.awt.Insets(2, 2, 2, 2);
sceneSelectionPanel.add(bScene3, gridBagConstraints);
bScene4.setBorder(javax.swing.BorderFactory.createLineBorder(new java.awt.Color(102, 102, 102)));
bScene4.setText("4");
bScene4.setContentAreaFilled(false);
bScene4.setFont(new java.awt.Font("Dialog", 1, 10));
bScene4.setMaximumSize(new java.awt.Dimension(25, 15));
bScene4.setMinimumSize(new java.awt.Dimension(25, 15));
bScene4.setPreferredSize(new java.awt.Dimension(25, 15));
gridBagConstraints = new java.awt.GridBagConstraints();
gridBagConstraints.gridx = 0;
gridBagConstraints.gridy = 1;
gridBagConstraints.insets = new java.awt.Insets(2, 2, 2, 2);
sceneSelectionPanel.add(bScene4, gridBagConstraints);
bScene5.setBorder(javax.swing.BorderFactory.createLineBorder(new java.awt.Color(102, 102, 102)));
bScene5.setText("5");
bScene5.setContentAreaFilled(false);
bScene5.setFont(new java.awt.Font("Dialog", 1, 10));
bScene5.setMaximumSize(new java.awt.Dimension(25, 15));
bScene5.setMinimumSize(new java.awt.Dimension(25, 15));
bScene5.setPreferredSize(new java.awt.Dimension(25, 15));
gridBagConstraints = new java.awt.GridBagConstraints();
gridBagConstraints.gridx = 1;
gridBagConstraints.gridy = 1;
gridBagConstraints.insets = new java.awt.Insets(2, 2, 2, 2);
sceneSelectionPanel.add(bScene5, gridBagConstraints);
bScene6.setBorder(javax.swing.BorderFactory.createLineBorder(new java.awt.Color(102, 102, 102)));
bScene6.setText("6");
bScene6.setContentAreaFilled(false);
bScene6.setFont(new java.awt.Font("Dialog", 1, 10));
bScene6.setMaximumSize(new java.awt.Dimension(25, 15));
bScene6.setMinimumSize(new java.awt.Dimension(25, 15));
bScene6.setPreferredSize(new java.awt.Dimension(25, 15));
gridBagConstraints = new java.awt.GridBagConstraints();
gridBagConstraints.gridx = 2;
gridBagConstraints.gridy = 1;
gridBagConstraints.insets = new java.awt.Insets(2, 2, 2, 2);
sceneSelectionPanel.add(bScene6, gridBagConstraints);
bScene7.setBorder(javax.swing.BorderFactory.createLineBorder(new java.awt.Color(102, 102, 102)));
bScene7.setText("7");
bScene7.setContentAreaFilled(false);
bScene7.setFont(new java.awt.Font("Dialog", 1, 10));
bScene7.setMaximumSize(new java.awt.Dimension(25, 15));
bScene7.setMinimumSize(new java.awt.Dimension(25, 15));
bScene7.setPreferredSize(new java.awt.Dimension(25, 15));
gridBagConstraints = new java.awt.GridBagConstraints();
gridBagConstraints.gridx = 0;
gridBagConstraints.gridy = 2;
gridBagConstraints.insets = new java.awt.Insets(2, 2, 2, 2);
sceneSelectionPanel.add(bScene7, gridBagConstraints);
bScene8.setBorder(javax.swing.BorderFactory.createLineBorder(new java.awt.Color(102, 102, 102)));
bScene8.setText("8");
bScene8.setContentAreaFilled(false);
bScene8.setFont(new java.awt.Font("Dialog", 1, 10));
bScene8.setMaximumSize(new java.awt.Dimension(25, 15));
bScene8.setMinimumSize(new java.awt.Dimension(25, 15));
bScene8.setPreferredSize(new java.awt.Dimension(25, 15));
gridBagConstraints = new java.awt.GridBagConstraints();
gridBagConstraints.gridx = 1;
gridBagConstraints.gridy = 2;
gridBagConstraints.insets = new java.awt.Insets(2, 2, 2, 2);
sceneSelectionPanel.add(bScene8, gridBagConstraints);
bScene9.setBorder(javax.swing.BorderFactory.createLineBorder(new java.awt.Color(102, 102, 102)));
bScene9.setText("9");
bScene9.setContentAreaFilled(false);
bScene9.setFont(new java.awt.Font("Dialog", 1, 10));
bScene9.setMaximumSize(new java.awt.Dimension(25, 15));
bScene9.setMinimumSize(new java.awt.Dimension(25, 15));
bScene9.setPreferredSize(new java.awt.Dimension(25, 15));
gridBagConstraints = new java.awt.GridBagConstraints();
gridBagConstraints.gridx = 2;
gridBagConstraints.gridy = 2;
gridBagConstraints.insets = new java.awt.Insets(2, 2, 2, 2);
sceneSelectionPanel.add(bScene9, gridBagConstraints);
bScene10.setBorder(javax.swing.BorderFactory.createLineBorder(new java.awt.Color(102, 102, 102)));
bScene10.setText("10");
bScene10.setContentAreaFilled(false);
bScene10.setFont(new java.awt.Font("Dialog", 1, 10));
bScene10.setMaximumSize(new java.awt.Dimension(25, 15));
bScene10.setMinimumSize(new java.awt.Dimension(25, 15));
bScene10.setPreferredSize(new java.awt.Dimension(25, 15));
gridBagConstraints = new java.awt.GridBagConstraints();
gridBagConstraints.gridx = 0;
gridBagConstraints.gridy = 3;
gridBagConstraints.insets = new java.awt.Insets(6, 2, 2, 2);
sceneSelectionPanel.add(bScene10, gridBagConstraints);
bScene11.setBorder(javax.swing.BorderFactory.createLineBorder(new java.awt.Color(102, 102, 102)));
bScene11.setText("11");
bScene11.setContentAreaFilled(false);
bScene11.setFont(new java.awt.Font("Dialog", 1, 10));
bScene11.setMaximumSize(new java.awt.Dimension(25, 15));
bScene11.setMinimumSize(new java.awt.Dimension(25, 15));
bScene11.setPreferredSize(new java.awt.Dimension(25, 15));
gridBagConstraints = new java.awt.GridBagConstraints();
gridBagConstraints.gridx = 1;
gridBagConstraints.gridy = 3;
gridBagConstraints.insets = new java.awt.Insets(6, 2, 2, 2);
sceneSelectionPanel.add(bScene11, gridBagConstraints);
bScene12.setBorder(javax.swing.BorderFactory.createLineBorder(new java.awt.Color(102, 102, 102)));
bScene12.setText("12");
bScene12.setContentAreaFilled(false);
bScene12.setFont(new java.awt.Font("Dialog", 1, 10));
bScene12.setMaximumSize(new java.awt.Dimension(25, 15));
bScene12.setMinimumSize(new java.awt.Dimension(25, 15));
bScene12.setPreferredSize(new java.awt.Dimension(25, 15));
gridBagConstraints = new java.awt.GridBagConstraints();
gridBagConstraints.gridx = 2;
gridBagConstraints.gridy = 3;
gridBagConstraints.insets = new java.awt.Insets(6, 2, 2, 2);
sceneSelectionPanel.add(bScene12, gridBagConstraints);
bScene13.setBorder(javax.swing.BorderFactory.createLineBorder(new java.awt.Color(102, 102, 102)));
bScene13.setText("13");
bScene13.setContentAreaFilled(false);
bScene13.setFont(new java.awt.Font("Dialog", 1, 10));
bScene13.setMaximumSize(new java.awt.Dimension(25, 15));
bScene13.setMinimumSize(new java.awt.Dimension(25, 15));
bScene13.setPreferredSize(new java.awt.Dimension(25, 15));
gridBagConstraints = new java.awt.GridBagConstraints();
gridBagConstraints.gridx = 0;
gridBagConstraints.gridy = 4;
gridBagConstraints.insets = new java.awt.Insets(2, 2, 2, 2);
sceneSelectionPanel.add(bScene13, gridBagConstraints);
bScene14.setBorder(javax.swing.BorderFactory.createLineBorder(new java.awt.Color(102, 102, 102)));
bScene14.setText("14");
bScene14.setContentAreaFilled(false);
bScene14.setFont(new java.awt.Font("Dialog", 1, 10));
bScene14.setMaximumSize(new java.awt.Dimension(25, 15));
bScene14.setMinimumSize(new java.awt.Dimension(25, 15));
bScene14.setPreferredSize(new java.awt.Dimension(25, 15));
gridBagConstraints = new java.awt.GridBagConstraints();
gridBagConstraints.gridx = 1;
gridBagConstraints.gridy = 4;
gridBagConstraints.insets = new java.awt.Insets(2, 2, 2, 2);
sceneSelectionPanel.add(bScene14, gridBagConstraints);
bScene15.setBorder(javax.swing.BorderFactory.createLineBorder(new java.awt.Color(102, 102, 102)));
bScene15.setText("15");
bScene15.setContentAreaFilled(false);
bScene15.setFont(new java.awt.Font("Dialog", 1, 10));
bScene15.setMaximumSize(new java.awt.Dimension(25, 15));
bScene15.setMinimumSize(new java.awt.Dimension(25, 15));
bScene15.setPreferredSize(new java.awt.Dimension(25, 15));
gridBagConstraints = new java.awt.GridBagConstraints();
gridBagConstraints.gridx = 2;
gridBagConstraints.gridy = 4;
gridBagConstraints.insets = new java.awt.Insets(2, 2, 2, 2);
sceneSelectionPanel.add(bScene15, gridBagConstraints);
bScene16.setBorder(javax.swing.BorderFactory.createLineBorder(new java.awt.Color(102, 102, 102)));
bScene16.setText("16");
bScene16.setContentAreaFilled(false);
bScene16.setFont(new java.awt.Font("Dialog", 1, 10));
bScene16.setMaximumSize(new java.awt.Dimension(25, 15));
bScene16.setMinimumSize(new java.awt.Dimension(25, 15));
bScene16.setPreferredSize(new java.awt.Dimension(25, 15));
gridBagConstraints = new java.awt.GridBagConstraints();
gridBagConstraints.gridx = 0;
gridBagConstraints.gridy = 5;
gridBagConstraints.insets = new java.awt.Insets(2, 2, 2, 2);
sceneSelectionPanel.add(bScene16, gridBagConstraints);
bScene17.setBorder(javax.swing.BorderFactory.createLineBorder(new java.awt.Color(102, 102, 102)));
bScene17.setText("17");
bScene17.setContentAreaFilled(false);
bScene17.setFont(new java.awt.Font("Dialog", 1, 10));
bScene17.setMaximumSize(new java.awt.Dimension(25, 15));
bScene17.setMinimumSize(new java.awt.Dimension(25, 15));
bScene17.setPreferredSize(new java.awt.Dimension(25, 15));
gridBagConstraints = new java.awt.GridBagConstraints();
gridBagConstraints.gridx = 1;
gridBagConstraints.gridy = 5;
gridBagConstraints.insets = new java.awt.Insets(2, 2, 2, 2);
sceneSelectionPanel.add(bScene17, gridBagConstraints);
bScene18.setBorder(javax.swing.BorderFactory.createLineBorder(new java.awt.Color(102, 102, 102)));
bScene18.setText("18");
bScene18.setContentAreaFilled(false);
bScene18.setFont(new java.awt.Font("Dialog", 1, 10));
bScene18.setMaximumSize(new java.awt.Dimension(25, 15));
bScene18.setMinimumSize(new java.awt.Dimension(25, 15));
bScene18.setPreferredSize(new java.awt.Dimension(25, 15));
gridBagConstraints = new java.awt.GridBagConstraints();
gridBagConstraints.gridx = 2;
gridBagConstraints.gridy = 5;
gridBagConstraints.insets = new java.awt.Insets(2, 2, 2, 2);
sceneSelectionPanel.add(bScene18, gridBagConstraints);
bScene19.setBorder(javax.swing.BorderFactory.createLineBorder(new java.awt.Color(102, 102, 102)));
bScene19.setText("19");
bScene19.setContentAreaFilled(false);
bScene19.setFont(new java.awt.Font("Dialog", 1, 10));
bScene19.setMaximumSize(new java.awt.Dimension(25, 15));
bScene19.setMinimumSize(new java.awt.Dimension(25, 15));
bScene19.setPreferredSize(new java.awt.Dimension(25, 15));
gridBagConstraints = new java.awt.GridBagConstraints();
gridBagConstraints.gridx = 0;
gridBagConstraints.gridy = 6;
gridBagConstraints.insets = new java.awt.Insets(6, 2, 2, 2);
sceneSelectionPanel.add(bScene19, gridBagConstraints);
bScene20.setBorder(javax.swing.BorderFactory.createLineBorder(new java.awt.Color(102, 102, 102)));
bScene20.setText("20");
bScene20.setContentAreaFilled(false);
bScene20.setFont(new java.awt.Font("Dialog", 1, 10));
bScene20.setMaximumSize(new java.awt.Dimension(25, 15));
bScene20.setMinimumSize(new java.awt.Dimension(25, 15));
bScene20.setPreferredSize(new java.awt.Dimension(25, 15));
gridBagConstraints = new java.awt.GridBagConstraints();
gridBagConstraints.gridx = 1;
gridBagConstraints.gridy = 6;
gridBagConstraints.insets = new java.awt.Insets(6, 2, 2, 2);
sceneSelectionPanel.add(bScene20, gridBagConstraints);
bScene21.setBorder(javax.swing.BorderFactory.createLineBorder(new java.awt.Color(102, 102, 102)));
bScene21.setText("21");
bScene21.setContentAreaFilled(false);
bScene21.setFont(new java.awt.Font("Dialog", 1, 10));
bScene21.setMaximumSize(new java.awt.Dimension(25, 15));
bScene21.setMinimumSize(new java.awt.Dimension(25, 15));
bScene21.setPreferredSize(new java.awt.Dimension(25, 15));
gridBagConstraints = new java.awt.GridBagConstraints();
gridBagConstraints.gridx = 2;
gridBagConstraints.gridy = 6;
gridBagConstraints.insets = new java.awt.Insets(6, 2, 2, 2);
sceneSelectionPanel.add(bScene21, gridBagConstraints);
bScene22.setBorder(javax.swing.BorderFactory.createLineBorder(new java.awt.Color(102, 102, 102)));
bScene22.setText("22");
bScene22.setContentAreaFilled(false);
bScene22.setFont(new java.awt.Font("Dialog", 1, 10));
bScene22.setMaximumSize(new java.awt.Dimension(25, 15));
bScene22.setMinimumSize(new java.awt.Dimension(25, 15));
bScene22.setPreferredSize(new java.awt.Dimension(25, 15));
gridBagConstraints = new java.awt.GridBagConstraints();
gridBagConstraints.gridx = 0;
gridBagConstraints.gridy = 7;
gridBagConstraints.insets = new java.awt.Insets(2, 2, 2, 2);
sceneSelectionPanel.add(bScene22, gridBagConstraints);
bScene23.setBorder(javax.swing.BorderFactory.createLineBorder(new java.awt.Color(102, 102, 102)));
bScene23.setText("23");
bScene23.setContentAreaFilled(false);
bScene23.setFont(new java.awt.Font("Dialog", 1, 10));
bScene23.setMaximumSize(new java.awt.Dimension(25, 15));
bScene23.setMinimumSize(new java.awt.Dimension(25, 15));
bScene23.setPreferredSize(new java.awt.Dimension(25, 15));
gridBagConstraints = new java.awt.GridBagConstraints();
gridBagConstraints.gridx = 1;
gridBagConstraints.gridy = 7;
gridBagConstraints.insets = new java.awt.Insets(2, 2, 2, 2);
sceneSelectionPanel.add(bScene23, gridBagConstraints);
bScene24.setBorder(javax.swing.BorderFactory.createLineBorder(new java.awt.Color(102, 102, 102)));
bScene24.setText("24");
bScene24.setContentAreaFilled(false);
bScene24.setFont(new java.awt.Font("Dialog", 1, 10));
bScene24.setMaximumSize(new java.awt.Dimension(25, 15));
bScene24.setMinimumSize(new java.awt.Dimension(25, 15));
bScene24.setPreferredSize(new java.awt.Dimension(25, 15));
gridBagConstraints = new java.awt.GridBagConstraints();
gridBagConstraints.gridx = 2;
gridBagConstraints.gridy = 7;
gridBagConstraints.insets = new java.awt.Insets(2, 2, 2, 2);
sceneSelectionPanel.add(bScene24, gridBagConstraints);
bScene25.setBorder(javax.swing.BorderFactory.createLineBorder(new java.awt.Color(102, 102, 102)));
bScene25.setText("25");
bScene25.setContentAreaFilled(false);
bScene25.setFont(new java.awt.Font("Dialog", 1, 10));
bScene25.setMaximumSize(new java.awt.Dimension(25, 15));
bScene25.setMinimumSize(new java.awt.Dimension(25, 15));
bScene25.setPreferredSize(new java.awt.Dimension(25, 15));
gridBagConstraints = new java.awt.GridBagConstraints();
gridBagConstraints.gridx = 0;
gridBagConstraints.gridy = 8;
gridBagConstraints.insets = new java.awt.Insets(2, 2, 2, 2);
sceneSelectionPanel.add(bScene25, gridBagConstraints);
bScene26.setBorder(javax.swing.BorderFactory.createLineBorder(new java.awt.Color(102, 102, 102)));
bScene26.setText("26");
bScene26.setContentAreaFilled(false);
bScene26.setFont(new java.awt.Font("Dialog", 1, 10));
bScene26.setMaximumSize(new java.awt.Dimension(25, 15));
bScene26.setMinimumSize(new java.awt.Dimension(25, 15));
bScene26.setPreferredSize(new java.awt.Dimension(25, 15));
gridBagConstraints = new java.awt.GridBagConstraints();
gridBagConstraints.gridx = 1;
gridBagConstraints.gridy = 8;
gridBagConstraints.insets = new java.awt.Insets(2, 2, 2, 2);
sceneSelectionPanel.add(bScene26, gridBagConstraints);
bScene27.setBorder(javax.swing.BorderFactory.createLineBorder(new java.awt.Color(102, 102, 102)));
bScene27.setText("27");
bScene27.setContentAreaFilled(false);
bScene27.setFont(new java.awt.Font("Dialog", 1, 10));
bScene27.setMaximumSize(new java.awt.Dimension(25, 15));
bScene27.setMinimumSize(new java.awt.Dimension(25, 15));
bScene27.setPreferredSize(new java.awt.Dimension(25, 15));
gridBagConstraints = new java.awt.GridBagConstraints();
gridBagConstraints.gridx = 2;
gridBagConstraints.gridy = 8;
gridBagConstraints.insets = new java.awt.Insets(2, 2, 2, 2);
sceneSelectionPanel.add(bScene27, gridBagConstraints);
bScene28.setBorder(javax.swing.BorderFactory.createLineBorder(new java.awt.Color(102, 102, 102)));
bScene28.setText("28");
bScene28.setContentAreaFilled(false);
bScene28.setFont(new java.awt.Font("Dialog", 1, 10));
bScene28.setMaximumSize(new java.awt.Dimension(25, 15));
bScene28.setMinimumSize(new java.awt.Dimension(25, 15));
bScene28.setPreferredSize(new java.awt.Dimension(25, 15));
bScene28.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
bScene28ActionPerformed(evt);
}
});
gridBagConstraints = new java.awt.GridBagConstraints();
gridBagConstraints.gridx = 0;
gridBagConstraints.gridy = 9;
gridBagConstraints.insets = new java.awt.Insets(6, 2, 2, 2);
sceneSelectionPanel.add(bScene28, gridBagConstraints);
bScene29.setBorder(javax.swing.BorderFactory.createLineBorder(new java.awt.Color(102, 102, 102)));
bScene29.setText("29");
bScene29.setContentAreaFilled(false);
bScene29.setFont(new java.awt.Font("Dialog", 1, 10));
bScene29.setMaximumSize(new java.awt.Dimension(25, 15));
bScene29.setMinimumSize(new java.awt.Dimension(25, 15));
bScene29.setPreferredSize(new java.awt.Dimension(25, 15));
gridBagConstraints = new java.awt.GridBagConstraints();
gridBagConstraints.gridx = 1;
gridBagConstraints.gridy = 9;
gridBagConstraints.insets = new java.awt.Insets(6, 2, 2, 2);
sceneSelectionPanel.add(bScene29, gridBagConstraints);
bScene30.setBorder(javax.swing.BorderFactory.createLineBorder(new java.awt.Color(102, 102, 102)));
bScene30.setText("30");
bScene30.setContentAreaFilled(false);
bScene30.setFont(new java.awt.Font("Dialog", 1, 10));
bScene30.setMaximumSize(new java.awt.Dimension(25, 15));
bScene30.setMinimumSize(new java.awt.Dimension(25, 15));
bScene30.setPreferredSize(new java.awt.Dimension(25, 15));
gridBagConstraints = new java.awt.GridBagConstraints();
gridBagConstraints.gridx = 2;
gridBagConstraints.gridy = 9;
gridBagConstraints.insets = new java.awt.Insets(6, 2, 2, 2);
sceneSelectionPanel.add(bScene30, gridBagConstraints);
bScene31.setBorder(javax.swing.BorderFactory.createLineBorder(new java.awt.Color(102, 102, 102)));
bScene31.setText("31");
bScene31.setContentAreaFilled(false);
bScene31.setFont(new java.awt.Font("Dialog", 1, 10));
bScene31.setMaximumSize(new java.awt.Dimension(25, 15));
bScene31.setMinimumSize(new java.awt.Dimension(25, 15));
bScene31.setPreferredSize(new java.awt.Dimension(25, 15));
gridBagConstraints = new java.awt.GridBagConstraints();
gridBagConstraints.gridx = 0;
gridBagConstraints.gridy = 10;
gridBagConstraints.insets = new java.awt.Insets(2, 2, 2, 2);
sceneSelectionPanel.add(bScene31, gridBagConstraints);
bScene32.setBorder(javax.swing.BorderFactory.createLineBorder(new java.awt.Color(102, 102, 102)));
bScene32.setText("32");
bScene32.setContentAreaFilled(false);
bScene32.setFont(new java.awt.Font("Dialog", 1, 10));
bScene32.setMaximumSize(new java.awt.Dimension(25, 15));
bScene32.setMinimumSize(new java.awt.Dimension(25, 15));
bScene32.setPreferredSize(new java.awt.Dimension(25, 15));
gridBagConstraints = new java.awt.GridBagConstraints();
gridBagConstraints.gridx = 1;
gridBagConstraints.gridy = 10;
gridBagConstraints.insets = new java.awt.Insets(2, 2, 2, 2);
sceneSelectionPanel.add(bScene32, gridBagConstraints);
bScene33.setBorder(javax.swing.BorderFactory.createLineBorder(new java.awt.Color(102, 102, 102)));
bScene33.setText("33");
bScene33.setContentAreaFilled(false);
bScene33.setFont(new java.awt.Font("Dialog", 1, 10));
bScene33.setMaximumSize(new java.awt.Dimension(25, 15));
bScene33.setMinimumSize(new java.awt.Dimension(25, 15));
bScene33.setPreferredSize(new java.awt.Dimension(25, 15));
gridBagConstraints = new java.awt.GridBagConstraints();
gridBagConstraints.gridx = 2;
gridBagConstraints.gridy = 10;
gridBagConstraints.insets = new java.awt.Insets(2, 2, 2, 2);
sceneSelectionPanel.add(bScene33, gridBagConstraints);
bScene34.setBorder(javax.swing.BorderFactory.createLineBorder(new java.awt.Color(102, 102, 102)));
bScene34.setText("34");
bScene34.setContentAreaFilled(false);
bScene34.setFont(new java.awt.Font("Dialog", 1, 10));
bScene34.setMaximumSize(new java.awt.Dimension(25, 15));
bScene34.setMinimumSize(new java.awt.Dimension(25, 15));
bScene34.setPreferredSize(new java.awt.Dimension(25, 15));
gridBagConstraints = new java.awt.GridBagConstraints();
gridBagConstraints.gridx = 0;
gridBagConstraints.gridy = 11;
gridBagConstraints.insets = new java.awt.Insets(2, 2, 2, 2);
sceneSelectionPanel.add(bScene34, gridBagConstraints);
bScene35.setBorder(javax.swing.BorderFactory.createLineBorder(new java.awt.Color(102, 102, 102)));
bScene35.setText("35");
bScene35.setContentAreaFilled(false);
bScene35.setFont(new java.awt.Font("Dialog", 1, 10));
bScene35.setMaximumSize(new java.awt.Dimension(25, 15));
bScene35.setMinimumSize(new java.awt.Dimension(25, 15));
bScene35.setPreferredSize(new java.awt.Dimension(25, 15));
gridBagConstraints = new java.awt.GridBagConstraints();
gridBagConstraints.gridx = 1;
gridBagConstraints.gridy = 11;
gridBagConstraints.insets = new java.awt.Insets(2, 2, 2, 2);
sceneSelectionPanel.add(bScene35, gridBagConstraints);
bScene36.setBorder(javax.swing.BorderFactory.createLineBorder(new java.awt.Color(102, 102, 102)));
bScene36.setText("36");
bScene36.setContentAreaFilled(false);
bScene36.setFont(new java.awt.Font("Dialog", 1, 10));
bScene36.setMaximumSize(new java.awt.Dimension(25, 15));
bScene36.setMinimumSize(new java.awt.Dimension(25, 15));
bScene36.setPreferredSize(new java.awt.Dimension(25, 15));
gridBagConstraints = new java.awt.GridBagConstraints();
gridBagConstraints.gridx = 2;
gridBagConstraints.gridy = 11;
gridBagConstraints.insets = new java.awt.Insets(2, 2, 2, 2);
sceneSelectionPanel.add(bScene36, gridBagConstraints);
gridBagConstraints = new java.awt.GridBagConstraints();
gridBagConstraints.gridx = 1;
gridBagConstraints.gridy = 0;
gridBagConstraints.fill = java.awt.GridBagConstraints.VERTICAL;
gridBagConstraints.anchor = java.awt.GridBagConstraints.FIRST_LINE_START;
gridBagConstraints.insets = new java.awt.Insets(5, 5, 5, 5);
add(sceneSelectionPanel, gridBagConstraints);
}Example 80
| Project: Kalender-master File: Index.java View source code |
/**
* This method is called from within the constructor to initialize the form.
* WARNING: Do NOT modify this code. The content of this method is always
* regenerated by the Form Editor.
*/
@SuppressWarnings("unchecked")
private // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
void initComponents() {
Lucka3 = new javax.swing.JButton();
Lucka4 = new javax.swing.JButton();
Lucka5 = new javax.swing.JButton();
Lucka1 = new javax.swing.JButton();
Lucka6 = new javax.swing.JButton();
Lucka2 = new javax.swing.JButton();
Lucka9 = new javax.swing.JButton();
Lucka10 = new javax.swing.JButton();
Lucka11 = new javax.swing.JButton();
Lucka7 = new javax.swing.JButton();
Lucka12 = new javax.swing.JButton();
Lucka8 = new javax.swing.JButton();
Lucka15 = new javax.swing.JButton();
Lucka16 = new javax.swing.JButton();
Lucka17 = new javax.swing.JButton();
Lucka13 = new javax.swing.JButton();
Lucka18 = new javax.swing.JButton();
Lucka14 = new javax.swing.JButton();
Lucka21 = new javax.swing.JButton();
Lucka22 = new javax.swing.JButton();
Lucka23 = new javax.swing.JButton();
Lucka19 = new javax.swing.JButton();
Lucka24 = new javax.swing.JButton();
Lucka20 = new javax.swing.JButton();
jLabel1 = new javax.swing.JLabel();
setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE);
getContentPane().setLayout(new org.netbeans.lib.awtextra.AbsoluteLayout());
// NOI18N
Lucka3.setFont(new java.awt.Font("Tahoma", 3, 36));
Lucka3.setForeground(new java.awt.Color(255, 255, 255));
Lucka3.setText("3");
Lucka3.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
Lucka3.setContentAreaFilled(false);
Lucka3.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
Lucka3ActionPerformed(evt);
}
});
getContentPane().add(Lucka3, new org.netbeans.lib.awtextra.AbsoluteConstraints(278, 75, 90, 70));
// NOI18N
Lucka4.setFont(new java.awt.Font("Tahoma", 3, 36));
Lucka4.setForeground(new java.awt.Color(255, 255, 255));
Lucka4.setText("4");
Lucka4.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
Lucka4.setContentAreaFilled(false);
Lucka4.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
Lucka4ActionPerformed(evt);
}
});
getContentPane().add(Lucka4, new org.netbeans.lib.awtextra.AbsoluteConstraints(398, 75, 90, 70));
// NOI18N
Lucka5.setFont(new java.awt.Font("Tahoma", 3, 36));
Lucka5.setForeground(new java.awt.Color(255, 255, 255));
Lucka5.setText("5");
Lucka5.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
Lucka5.setContentAreaFilled(false);
Lucka5.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
Lucka5ActionPerformed(evt);
}
});
getContentPane().add(Lucka5, new org.netbeans.lib.awtextra.AbsoluteConstraints(508, 75, 90, 70));
// NOI18N
Lucka1.setFont(new java.awt.Font("Tahoma", 3, 36));
Lucka1.setForeground(new java.awt.Color(255, 255, 255));
Lucka1.setText("1");
Lucka1.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
Lucka1.setContentAreaFilled(false);
Lucka1.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
Lucka1ActionPerformed(evt);
}
});
getContentPane().add(Lucka1, new org.netbeans.lib.awtextra.AbsoluteConstraints(38, 75, 90, 70));
// NOI18N
Lucka6.setFont(new java.awt.Font("Tahoma", 3, 36));
Lucka6.setForeground(new java.awt.Color(255, 255, 255));
Lucka6.setText("6");
Lucka6.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
Lucka6.setContentAreaFilled(false);
Lucka6.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
Lucka6ActionPerformed(evt);
}
});
getContentPane().add(Lucka6, new org.netbeans.lib.awtextra.AbsoluteConstraints(628, 75, 90, 70));
// NOI18N
Lucka2.setFont(new java.awt.Font("Tahoma", 3, 36));
Lucka2.setForeground(new java.awt.Color(255, 255, 255));
Lucka2.setText("2");
Lucka2.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
Lucka2.setContentAreaFilled(false);
Lucka2.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
Lucka2ActionPerformed(evt);
}
});
getContentPane().add(Lucka2, new org.netbeans.lib.awtextra.AbsoluteConstraints(158, 75, 90, 70));
// NOI18N
Lucka9.setFont(new java.awt.Font("Tahoma", 3, 36));
Lucka9.setForeground(new java.awt.Color(255, 255, 255));
Lucka9.setText("9");
Lucka9.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
Lucka9.setContentAreaFilled(false);
Lucka9.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
Lucka9ActionPerformed(evt);
}
});
getContentPane().add(Lucka9, new org.netbeans.lib.awtextra.AbsoluteConstraints(278, 185, 90, 70));
// NOI18N
Lucka10.setFont(new java.awt.Font("Tahoma", 3, 36));
Lucka10.setForeground(new java.awt.Color(255, 255, 255));
Lucka10.setText("10");
Lucka10.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
Lucka10.setContentAreaFilled(false);
Lucka10.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
Lucka10ActionPerformed(evt);
}
});
getContentPane().add(Lucka10, new org.netbeans.lib.awtextra.AbsoluteConstraints(398, 185, 90, 70));
// NOI18N
Lucka11.setFont(new java.awt.Font("Tahoma", 3, 36));
Lucka11.setForeground(new java.awt.Color(255, 255, 255));
Lucka11.setText("11");
Lucka11.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
Lucka11.setContentAreaFilled(false);
Lucka11.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
Lucka11ActionPerformed(evt);
}
});
getContentPane().add(Lucka11, new org.netbeans.lib.awtextra.AbsoluteConstraints(508, 185, 90, 70));
// NOI18N
Lucka7.setFont(new java.awt.Font("Tahoma", 3, 36));
Lucka7.setForeground(new java.awt.Color(255, 255, 255));
Lucka7.setText("7");
Lucka7.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
Lucka7.setContentAreaFilled(false);
Lucka7.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
Lucka7ActionPerformed(evt);
}
});
getContentPane().add(Lucka7, new org.netbeans.lib.awtextra.AbsoluteConstraints(38, 185, 90, 70));
// NOI18N
Lucka12.setFont(new java.awt.Font("Tahoma", 3, 36));
Lucka12.setForeground(new java.awt.Color(255, 255, 255));
Lucka12.setText("12");
Lucka12.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
Lucka12.setContentAreaFilled(false);
Lucka12.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
Lucka12ActionPerformed(evt);
}
});
getContentPane().add(Lucka12, new org.netbeans.lib.awtextra.AbsoluteConstraints(628, 185, 90, 70));
// NOI18N
Lucka8.setFont(new java.awt.Font("Tahoma", 3, 36));
Lucka8.setForeground(new java.awt.Color(255, 255, 255));
Lucka8.setText("8");
Lucka8.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
Lucka8.setContentAreaFilled(false);
Lucka8.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
Lucka8ActionPerformed(evt);
}
});
getContentPane().add(Lucka8, new org.netbeans.lib.awtextra.AbsoluteConstraints(158, 185, 90, 70));
// NOI18N
Lucka15.setFont(new java.awt.Font("Tahoma", 3, 36));
Lucka15.setForeground(new java.awt.Color(255, 255, 255));
Lucka15.setText("15");
Lucka15.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
Lucka15.setContentAreaFilled(false);
Lucka15.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
Lucka15ActionPerformed(evt);
}
});
getContentPane().add(Lucka15, new org.netbeans.lib.awtextra.AbsoluteConstraints(278, 295, 90, 70));
// NOI18N
Lucka16.setFont(new java.awt.Font("Tahoma", 3, 36));
Lucka16.setForeground(new java.awt.Color(255, 255, 255));
Lucka16.setText("16");
Lucka16.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
Lucka16.setContentAreaFilled(false);
Lucka16.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
Lucka16ActionPerformed(evt);
}
});
getContentPane().add(Lucka16, new org.netbeans.lib.awtextra.AbsoluteConstraints(398, 295, 90, 70));
// NOI18N
Lucka17.setFont(new java.awt.Font("Tahoma", 3, 36));
Lucka17.setForeground(new java.awt.Color(255, 255, 255));
Lucka17.setText("17");
Lucka17.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
Lucka17.setContentAreaFilled(false);
Lucka17.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
Lucka17ActionPerformed(evt);
}
});
getContentPane().add(Lucka17, new org.netbeans.lib.awtextra.AbsoluteConstraints(508, 295, 90, 70));
// NOI18N
Lucka13.setFont(new java.awt.Font("Tahoma", 3, 36));
Lucka13.setForeground(new java.awt.Color(255, 255, 255));
Lucka13.setText("13");
Lucka13.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
Lucka13.setContentAreaFilled(false);
Lucka13.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
Lucka13ActionPerformed(evt);
}
});
getContentPane().add(Lucka13, new org.netbeans.lib.awtextra.AbsoluteConstraints(38, 295, 90, 70));
// NOI18N
Lucka18.setFont(new java.awt.Font("Tahoma", 3, 36));
Lucka18.setForeground(new java.awt.Color(255, 255, 255));
Lucka18.setText("18");
Lucka18.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
Lucka18.setContentAreaFilled(false);
Lucka18.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
Lucka18ActionPerformed(evt);
}
});
getContentPane().add(Lucka18, new org.netbeans.lib.awtextra.AbsoluteConstraints(628, 295, 90, 70));
// NOI18N
Lucka14.setFont(new java.awt.Font("Tahoma", 3, 36));
Lucka14.setForeground(new java.awt.Color(255, 255, 255));
Lucka14.setText("14");
Lucka14.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
Lucka14.setContentAreaFilled(false);
Lucka14.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
Lucka14ActionPerformed(evt);
}
});
getContentPane().add(Lucka14, new org.netbeans.lib.awtextra.AbsoluteConstraints(158, 295, 90, 70));
// NOI18N
Lucka21.setFont(new java.awt.Font("Tahoma", 3, 36));
Lucka21.setForeground(new java.awt.Color(255, 255, 255));
Lucka21.setText("21");
Lucka21.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
Lucka21.setContentAreaFilled(false);
Lucka21.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
Lucka21ActionPerformed(evt);
}
});
getContentPane().add(Lucka21, new org.netbeans.lib.awtextra.AbsoluteConstraints(278, 405, 90, 70));
// NOI18N
Lucka22.setFont(new java.awt.Font("Tahoma", 3, 36));
Lucka22.setForeground(new java.awt.Color(255, 255, 255));
Lucka22.setText("22");
Lucka22.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
Lucka22.setContentAreaFilled(false);
Lucka22.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
Lucka22ActionPerformed(evt);
}
});
getContentPane().add(Lucka22, new org.netbeans.lib.awtextra.AbsoluteConstraints(398, 405, 90, 70));
// NOI18N
Lucka23.setFont(new java.awt.Font("Tahoma", 3, 36));
Lucka23.setForeground(new java.awt.Color(255, 255, 255));
Lucka23.setText("23");
Lucka23.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
Lucka23.setContentAreaFilled(false);
Lucka23.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
Lucka23ActionPerformed(evt);
}
});
getContentPane().add(Lucka23, new org.netbeans.lib.awtextra.AbsoluteConstraints(508, 405, 90, 70));
// NOI18N
Lucka19.setFont(new java.awt.Font("Tahoma", 3, 36));
Lucka19.setForeground(new java.awt.Color(255, 255, 255));
Lucka19.setText("19");
Lucka19.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
Lucka19.setContentAreaFilled(false);
Lucka19.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
Lucka19ActionPerformed(evt);
}
});
getContentPane().add(Lucka19, new org.netbeans.lib.awtextra.AbsoluteConstraints(38, 405, 90, 70));
// NOI18N
Lucka24.setFont(new java.awt.Font("Tahoma", 3, 36));
Lucka24.setForeground(new java.awt.Color(255, 255, 255));
Lucka24.setText("24");
Lucka24.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
Lucka24.setContentAreaFilled(false);
Lucka24.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
Lucka24ActionPerformed(evt);
}
});
getContentPane().add(Lucka24, new org.netbeans.lib.awtextra.AbsoluteConstraints(628, 405, 90, 70));
// NOI18N
Lucka20.setFont(new java.awt.Font("Tahoma", 3, 36));
Lucka20.setForeground(new java.awt.Color(255, 255, 255));
Lucka20.setText("20");
Lucka20.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));
Lucka20.setContentAreaFilled(false);
Lucka20.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
Lucka20ActionPerformed(evt);
}
});
getContentPane().add(Lucka20, new org.netbeans.lib.awtextra.AbsoluteConstraints(158, 405, 90, 70));
// NOI18N
jLabel1.setIcon(new javax.swing.ImageIcon(getClass().getResource("/adventskalender1/j23.jpg")));
getContentPane().add(jLabel1, new org.netbeans.lib.awtextra.AbsoluteConstraints(0, 0, 755, 551));
pack();
}Example 81
| Project: Pokeboard-1v1-master File: PokeboardUI.java View source code |
/**
* This method is called from within the constructor to initialize the form.
* WARNING: Do NOT modify this code. The content of this method is always
* regenerated by the Form Editor.
*/
// <editor-fold defaultstate="collapsed" desc="Generated
// Code">//GEN-BEGIN:initComponents
private void initComponents() {
JohtoActiveZoom = new javax.swing.JLabel();
KantoActiveZoom = new javax.swing.JLabel();
JohtoActiveCard = new javax.swing.JFrame();
KantoActiveCard = new javax.swing.JFrame();
JohtoActivePic = new javax.swing.JLabel();
Background = new javax.swing.JLayeredPane();
Stadium = new javax.swing.JComboBox<>();
JohtoActiveComboBox = new javax.swing.JComboBox<>();
JohtoPrize1 = new javax.swing.JLabel();
JohtoPrize2 = new javax.swing.JLabel();
JohtoPrize3 = new javax.swing.JLabel();
JohtoPrize4 = new javax.swing.JLabel();
JohtoPrize5 = new javax.swing.JLabel();
JohtoPrize6 = new javax.swing.JLabel();
KantoPrize1 = new javax.swing.JLabel();
KantoPrize2 = new javax.swing.JLabel();
KantoPrize3 = new javax.swing.JLabel();
KantoPrize4 = new javax.swing.JLabel();
KantoPrize5 = new javax.swing.JLabel();
KantoPrize6 = new javax.swing.JLabel();
JohtoActiveEnergy1 = new javax.swing.JButton();
JohtoActiveEnergy2 = new javax.swing.JButton();
JohtoActiveEnergy3 = new javax.swing.JButton();
JohtoActiveEnergy4 = new javax.swing.JButton();
JohtoBench5ComboBox = new javax.swing.JComboBox<>();
JohtoBench5Energy1 = new javax.swing.JButton();
JohtoBench5Energy2 = new javax.swing.JButton();
JohtoBench5Energy3 = new javax.swing.JButton();
JohtoBench5Energy4 = new javax.swing.JButton();
JohtoBench4ComboBox = new javax.swing.JComboBox<>();
JohtoBench4Energy1 = new javax.swing.JButton();
JohtoBench4Energy2 = new javax.swing.JButton();
JohtoBench4Energy3 = new javax.swing.JButton();
JohtoBench4Energy4 = new javax.swing.JButton();
JohtoBench3ComboBox = new javax.swing.JComboBox<>();
JohtoBench3Energy1 = new javax.swing.JButton();
JohtoBench3Energy2 = new javax.swing.JButton();
JohtoBench3Energy3 = new javax.swing.JButton();
JohtoBench3Energy4 = new javax.swing.JButton();
JohtoBench2ComboBox = new javax.swing.JComboBox<>();
JohtoBench2Energy1 = new javax.swing.JButton();
JohtoBench2Energy2 = new javax.swing.JButton();
JohtoBench2Energy3 = new javax.swing.JButton();
JohtoBench2Energy4 = new javax.swing.JButton();
JohtoBench1ComboBox = new javax.swing.JComboBox<>();
JohtoBench1Energy4 = new javax.swing.JButton();
JohtoBench1Energy3 = new javax.swing.JButton();
JohtoBench1Energy2 = new javax.swing.JButton();
JohtoBench1Energy1 = new javax.swing.JButton();
KantoActiveComboBox = new javax.swing.JComboBox<>();
KantoBench1ComboBox = new javax.swing.JComboBox<>();
KantoBench2ComboBox = new javax.swing.JComboBox<>();
KantoBench3ComboBox = new javax.swing.JComboBox<>();
KantoBench4ComboBox = new javax.swing.JComboBox<>();
KantoBench5ComboBox = new javax.swing.JComboBox<>();
ClearButton = new javax.swing.JButton();
JohtoPlus = new javax.swing.JButton();
JohtoMinus = new javax.swing.JButton();
JohtoDamageNumB5 = new javax.swing.JTextField();
JohtoDamageNum = new javax.swing.JTextField();
JohtoDamageNumB4 = new javax.swing.JTextField();
JohtoDamageNumB3 = new javax.swing.JTextField();
JohtoDamageNumB2 = new javax.swing.JTextField();
JohtoDamageNumB1 = new javax.swing.JTextField();
KantoPlus = new javax.swing.JButton();
KantoMinus = new javax.swing.JButton();
KantoDamageNum = new javax.swing.JTextField();
KantoDamageNumB5 = new javax.swing.JTextField();
KantoDamageNumB4 = new javax.swing.JTextField();
KantoDamageNumB3 = new javax.swing.JTextField();
KantoDamageNumB2 = new javax.swing.JTextField();
KantoDamageNumB1 = new javax.swing.JTextField();
StadiumCard = new javax.swing.JLabel();
JohtoCard = new javax.swing.JLabel();
KantoCard = new javax.swing.JLabel();
mid = new javax.swing.JLabel();
Kanto = new javax.swing.JLabel();
Johto = new javax.swing.JLabel();
KantoActiveEnergy1 = new javax.swing.JButton();
KantoActiveEnergy2 = new javax.swing.JButton();
KantoActiveEnergy3 = new javax.swing.JButton();
KantoActiveEnergy4 = new javax.swing.JButton();
KantoBench5Energy4 = new javax.swing.JButton();
KantoBench5Energy3 = new javax.swing.JButton();
KantoBench5Energy2 = new javax.swing.JButton();
KantoBench5Energy1 = new javax.swing.JButton();
KantoBench4Energy4 = new javax.swing.JButton();
KantoBench4Energy3 = new javax.swing.JButton();
KantoBench4Energy2 = new javax.swing.JButton();
KantoBench4Energy1 = new javax.swing.JButton();
KantoBench3Energy4 = new javax.swing.JButton();
KantoBench3Energy3 = new javax.swing.JButton();
KantoBench3Energy2 = new javax.swing.JButton();
KantoBench3Energy1 = new javax.swing.JButton();
KantoBench2Energy4 = new javax.swing.JButton();
KantoBench2Energy3 = new javax.swing.JButton();
KantoBench2Energy2 = new javax.swing.JButton();
KantoBench2Energy1 = new javax.swing.JButton();
KantoBench1Energy4 = new javax.swing.JButton();
KantoBench1Energy3 = new javax.swing.JButton();
KantoBench1Energy2 = new javax.swing.JButton();
KantoBench1Energy1 = new javax.swing.JButton();
JohtoPZ = new javax.swing.JButton();
JohtoSL = new javax.swing.JButton();
JohtoPO = new javax.swing.JButton();
JohtoBR = new javax.swing.JButton();
JohtoCN = new javax.swing.JButton();
KantoCN = new javax.swing.JButton();
KantoBR = new javax.swing.JButton();
KantoPO = new javax.swing.JButton();
KantoSL = new javax.swing.JButton();
KantoPZ = new javax.swing.JButton();
KantoBench5Switch = new javax.swing.JButton();
KantoBench4Switch = new javax.swing.JButton();
KantoBench3Switch = new javax.swing.JButton();
KantoBench2Switch = new javax.swing.JButton();
KantoBench1Switch = new javax.swing.JButton();
JohtoBench5Switch = new javax.swing.JButton();
JohtoBench4Switch = new javax.swing.JButton();
JohtoBench3Switch = new javax.swing.JButton();
JohtoBench2Switch = new javax.swing.JButton();
JohtoBench1Switch = new javax.swing.JButton();
KantoClear = new javax.swing.JButton();
JohtoClear = new javax.swing.JButton();
// NOI18N
JohtoActivePic.setIcon(new javax.swing.ImageIcon(getClass().getResource("/my/pokeboard/images/Back.png")));
JohtoActiveCard.setAlwaysOnTop(true);
JohtoActiveCard.setMinimumSize(new java.awt.Dimension(425, 575));
JohtoActiveCard.setPreferredSize(new java.awt.Dimension(425, 575));
JohtoActiveCard.setSize(new java.awt.Dimension(425, 575));
JohtoActiveCard.setType(java.awt.Window.Type.UTILITY);
KantoActiveCard.setAlwaysOnTop(true);
KantoActiveCard.setMinimumSize(new java.awt.Dimension(425, 575));
KantoActiveCard.setPreferredSize(new java.awt.Dimension(425, 575));
KantoActiveCard.setSize(new java.awt.Dimension(425, 575));
KantoActiveCard.setType(java.awt.Window.Type.UTILITY);
javax.swing.GroupLayout JohtoActiveCardLayout = new javax.swing.GroupLayout(JohtoActiveCard.getContentPane());
JohtoActiveCard.getContentPane().setLayout(JohtoActiveCardLayout);
JohtoActiveCardLayout.setHorizontalGroup(JohtoActiveCardLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGap(0, 400, Short.MAX_VALUE).addGroup(JohtoActiveCardLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(javax.swing.GroupLayout.Alignment.TRAILING, JohtoActiveCardLayout.createSequentialGroup().addContainerGap(36, Short.MAX_VALUE).addComponent(JohtoActiveZoom, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addContainerGap(191, Short.MAX_VALUE))));
JohtoActiveCardLayout.setVerticalGroup(JohtoActiveCardLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGap(0, 300, Short.MAX_VALUE).addGroup(JohtoActiveCardLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(JohtoActiveCardLayout.createSequentialGroup().addComponent(JohtoActiveZoom, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 30, Short.MAX_VALUE))));
javax.swing.GroupLayout KantoActiveCardLayout = new javax.swing.GroupLayout(KantoActiveCard.getContentPane());
KantoActiveCard.getContentPane().setLayout(KantoActiveCardLayout);
KantoActiveCardLayout.setHorizontalGroup(KantoActiveCardLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGap(0, 400, Short.MAX_VALUE).addGroup(KantoActiveCardLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(javax.swing.GroupLayout.Alignment.TRAILING, KantoActiveCardLayout.createSequentialGroup().addContainerGap(36, Short.MAX_VALUE).addComponent(KantoActiveZoom, javax.swing.GroupLayout.PREFERRED_SIZE, 400, javax.swing.GroupLayout.PREFERRED_SIZE).addContainerGap(191, Short.MAX_VALUE))));
KantoActiveCardLayout.setVerticalGroup(KantoActiveCardLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGap(0, 300, Short.MAX_VALUE).addGroup(KantoActiveCardLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(KantoActiveCardLayout.createSequentialGroup().addComponent(KantoActiveZoom, javax.swing.GroupLayout.PREFERRED_SIZE, 551, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 30, Short.MAX_VALUE))));
setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE);
setTitle("Pokeleague 2015");
setAlwaysOnTop(true);
setBackground(new java.awt.Color(0, 0, 0));
setCursor(new java.awt.Cursor(java.awt.Cursor.DEFAULT_CURSOR));
setForeground(java.awt.Color.black);
Background.setAlignmentX(0.0F);
Background.setAlignmentY(0.0F);
Background.setLayout(new org.netbeans.lib.awtextra.AbsoluteLayout());
Stadium.setEditable(true);
Stadium.setModel(new javax.swing.DefaultComboBoxModel<>(stadiumCards));
AutoCompleteDecorator.decorate(Stadium);
Stadium.addItemListener(this::StadiumItemStateChanged);
Background.add(Stadium, new org.netbeans.lib.awtextra.AbsoluteConstraints(90, 200, 150, 20));
// NOI18N
JohtoActiveZoom.setIcon(new javax.swing.ImageIcon(getClass().getResource("/my/pokeboard/images/Back.png")));
JohtoActiveZoom.setMaximumSize(new java.awt.Dimension(400, 551));
JohtoActiveZoom.setMinimumSize(new java.awt.Dimension(400, 551));
JohtoActiveZoom.setPreferredSize(new java.awt.Dimension(400, 551));
// NOI18N
KantoActiveZoom.setIcon(new javax.swing.ImageIcon(getClass().getResource("/my/pokeboard/images/Back.png")));
KantoActiveZoom.setMaximumSize(new java.awt.Dimension(400, 551));
KantoActiveZoom.setMinimumSize(new java.awt.Dimension(400, 551));
KantoActiveZoom.setPreferredSize(new java.awt.Dimension(400, 551));
JohtoActiveComboBox.setEditable(true);
// JohtoActive.setModel(new
// javax.swing.DefaultComboBoxModel(PokemonList));
JohtoActiveComboBox.setModel(new javax.swing.DefaultComboBoxModel<>(pokemonCards));
JohtoActiveComboBox.addItemListener(this::JohtoActiveItemStateChanged);
AutoCompleteDecorator.decorate(JohtoActiveComboBox);
Background.add(JohtoActiveComboBox, new org.netbeans.lib.awtextra.AbsoluteConstraints(280, 260, 210, 20));
// NOI18N
JohtoPrize1.setIcon(new javax.swing.ImageIcon(getClass().getResource("/my/pokeboard/images/BackSmall.png")));
JohtoPrize1.setBorder(new javax.swing.border.LineBorder(new java.awt.Color(0, 0, 0), 1, true));
JohtoPrize1.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
JohtoPrize1MouseClicked(evt);
}
});
Background.add(JohtoPrize1, new org.netbeans.lib.awtextra.AbsoluteConstraints(10, 170, 21, 30));
// NOI18N
JohtoPrize2.setIcon(new javax.swing.ImageIcon(getClass().getResource("/my/pokeboard/images/BackSmall.png")));
JohtoPrize2.setBorder(new javax.swing.border.LineBorder(new java.awt.Color(0, 0, 0), 1, true));
JohtoPrize2.setPreferredSize(new java.awt.Dimension(14, 20));
JohtoPrize2.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
JohtoPrize2MouseClicked(evt);
}
});
Background.add(JohtoPrize2, new org.netbeans.lib.awtextra.AbsoluteConstraints(40, 170, 21, 30));
// NOI18N
JohtoPrize3.setIcon(new javax.swing.ImageIcon(getClass().getResource("/my/pokeboard/images/BackSmall.png")));
JohtoPrize3.setBorder(new javax.swing.border.LineBorder(new java.awt.Color(0, 0, 0), 1, true));
JohtoPrize3.setPreferredSize(new java.awt.Dimension(21, 30));
JohtoPrize3.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
JohtoPrize3MouseClicked(evt);
}
});
Background.add(JohtoPrize3, new org.netbeans.lib.awtextra.AbsoluteConstraints(10, 210, 21, 30));
// NOI18N
JohtoPrize4.setIcon(new javax.swing.ImageIcon(getClass().getResource("/my/pokeboard/images/BackSmall.png")));
JohtoPrize4.setBorder(new javax.swing.border.LineBorder(new java.awt.Color(0, 0, 0), 1, true));
JohtoPrize4.setMaximumSize(new java.awt.Dimension(21, 30));
JohtoPrize4.setMinimumSize(new java.awt.Dimension(21, 30));
JohtoPrize4.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
JohtoPrize4MouseClicked(evt);
}
});
Background.add(JohtoPrize4, new org.netbeans.lib.awtextra.AbsoluteConstraints(40, 210, 21, 30));
// NOI18N
JohtoPrize5.setIcon(new javax.swing.ImageIcon(getClass().getResource("/my/pokeboard/images/BackSmall.png")));
JohtoPrize5.setBorder(new javax.swing.border.LineBorder(new java.awt.Color(0, 0, 0), 1, true));
JohtoPrize5.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
JohtoPrize5MouseClicked(evt);
}
});
Background.add(JohtoPrize5, new org.netbeans.lib.awtextra.AbsoluteConstraints(40, 250, 20, 30));
// NOI18N
JohtoPrize6.setIcon(new javax.swing.ImageIcon(getClass().getResource("/my/pokeboard/images/BackSmall.png")));
JohtoPrize6.setBorder(new javax.swing.border.LineBorder(new java.awt.Color(0, 0, 0), 1, true));
JohtoPrize6.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
JohtoPrize6MouseClicked(evt);
}
});
Background.add(JohtoPrize6, new org.netbeans.lib.awtextra.AbsoluteConstraints(10, 250, 20, 30));
// NOI18N
KantoPrize1.setIcon(new javax.swing.ImageIcon(getClass().getResource("/my/pokeboard/images/BackSmall.png")));
KantoPrize1.setBorder(new javax.swing.border.LineBorder(new java.awt.Color(0, 0, 0), 1, true));
KantoPrize1.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
KantoPrize1MouseClicked(evt);
}
});
Background.add(KantoPrize1, new org.netbeans.lib.awtextra.AbsoluteConstraints(10, 450, 21, 30));
// NOI18N
KantoPrize2.setIcon(new javax.swing.ImageIcon(getClass().getResource("/my/pokeboard/images/BackSmall.png")));
KantoPrize2.setBorder(new javax.swing.border.LineBorder(new java.awt.Color(0, 0, 0), 1, true));
KantoPrize2.setPreferredSize(new java.awt.Dimension(14, 20));
KantoPrize2.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
KantoPrize2MouseClicked(evt);
}
});
Background.add(KantoPrize2, new org.netbeans.lib.awtextra.AbsoluteConstraints(40, 450, 21, 30));
// NOI18N
KantoPrize3.setIcon(new javax.swing.ImageIcon(getClass().getResource("/my/pokeboard/images/BackSmall.png")));
KantoPrize3.setBorder(new javax.swing.border.LineBorder(new java.awt.Color(0, 0, 0), 1, true));
KantoPrize3.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
KantoPrize3MouseClicked(evt);
}
});
Background.add(KantoPrize3, new org.netbeans.lib.awtextra.AbsoluteConstraints(40, 490, 21, 30));
// NOI18N
KantoPrize4.setIcon(new javax.swing.ImageIcon(getClass().getResource("/my/pokeboard/images/BackSmall.png")));
KantoPrize4.setBorder(new javax.swing.border.LineBorder(new java.awt.Color(0, 0, 0), 1, true));
KantoPrize4.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
KantoPrize4MouseClicked(evt);
}
});
Background.add(KantoPrize4, new org.netbeans.lib.awtextra.AbsoluteConstraints(10, 490, 21, 30));
// NOI18N
KantoPrize5.setIcon(new javax.swing.ImageIcon(getClass().getResource("/my/pokeboard/images/BackSmall.png")));
KantoPrize5.setBorder(new javax.swing.border.LineBorder(new java.awt.Color(0, 0, 0), 1, true));
KantoPrize5.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
KantoPrize5MouseClicked(evt);
}
});
Background.add(KantoPrize5, new org.netbeans.lib.awtextra.AbsoluteConstraints(10, 530, 20, 30));
// NOI18N
KantoPrize6.setIcon(new javax.swing.ImageIcon(getClass().getResource("/my/pokeboard/images/BackSmall.png")));
KantoPrize6.setBorder(new javax.swing.border.LineBorder(new java.awt.Color(0, 0, 0), 1, true));
KantoPrize6.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
KantoPrize6MouseClicked(evt);
}
});
Background.add(KantoPrize6, new org.netbeans.lib.awtextra.AbsoluteConstraints(40, 530, 20, 30));
JohtoActiveEnergy1.setBackground(java.awt.Color.lightGray);
JohtoActiveEnergy1.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
JohtoActiveEnergy1MouseClicked(evt);
}
});
Background.add(JohtoActiveEnergy1, new org.netbeans.lib.awtextra.AbsoluteConstraints(340, 240, -1, 20));
Background.setLayer(JohtoActiveEnergy1, 1);
JohtoActiveEnergy2.setBackground(java.awt.Color.lightGray);
JohtoActiveEnergy2.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
JohtoActiveEnergy2MouseClicked(evt);
}
});
Background.add(JohtoActiveEnergy2, new org.netbeans.lib.awtextra.AbsoluteConstraints(360, 240, 30, 20));
Background.setLayer(JohtoActiveEnergy2, 2);
JohtoActiveEnergy3.setBackground(java.awt.Color.lightGray);
JohtoActiveEnergy3.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
JohtoActiveEnergy3MouseClicked(evt);
}
});
Background.add(JohtoActiveEnergy3, new org.netbeans.lib.awtextra.AbsoluteConstraints(380, 240, 30, 20));
Background.setLayer(JohtoActiveEnergy3, 3);
JohtoActiveEnergy4.setBackground(java.awt.Color.lightGray);
JohtoActiveEnergy4.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
JohtoActiveEnergy4MouseClicked(evt);
}
});
Background.add(JohtoActiveEnergy4, new org.netbeans.lib.awtextra.AbsoluteConstraints(400, 240, 30, 20));
Background.setLayer(JohtoActiveEnergy4, 4);
JohtoBench5ComboBox.setEditable(true);
// JohtoBench5.setModel(new
// javax.swing.DefaultComboBoxModel(PokemonList));
JohtoBench5ComboBox.setModel(new javax.swing.DefaultComboBoxModel<>(pokemonCards));
AutoCompleteDecorator.decorate(JohtoBench5ComboBox);
Background.add(JohtoBench5ComboBox, new org.netbeans.lib.awtextra.AbsoluteConstraints(640, 70, 100, 20));
JohtoBench5Energy1.setBackground(java.awt.Color.lightGray);
JohtoBench5Energy1.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
JohtoBench5Energy1MouseClicked(evt);
}
});
Background.add(JohtoBench5Energy1, new org.netbeans.lib.awtextra.AbsoluteConstraints(640, 50, -1, 20));
Background.setLayer(JohtoBench5Energy1, 1);
JohtoBench5Energy2.setBackground(java.awt.Color.lightGray);
JohtoBench5Energy2.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
JohtoBench5Energy2MouseClicked(evt);
}
});
Background.add(JohtoBench5Energy2, new org.netbeans.lib.awtextra.AbsoluteConstraints(660, 50, 30, 20));
Background.setLayer(JohtoBench5Energy2, 2);
JohtoBench5Energy3.setBackground(java.awt.Color.lightGray);
JohtoBench5Energy3.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
JohtoBench5Energy3MouseClicked(evt);
}
});
Background.add(JohtoBench5Energy3, new org.netbeans.lib.awtextra.AbsoluteConstraints(680, 50, 30, 20));
Background.setLayer(JohtoBench5Energy3, 3);
JohtoBench5Energy4.setBackground(java.awt.Color.lightGray);
JohtoBench5Energy4.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
JohtoBench5Energy4MouseClicked(evt);
}
});
Background.add(JohtoBench5Energy4, new org.netbeans.lib.awtextra.AbsoluteConstraints(700, 50, 30, 20));
Background.setLayer(JohtoBench5Energy4, 4);
JohtoBench4ComboBox.setEditable(true);
// JohtoBench4.setModel(new
// javax.swing.DefaultComboBoxModel(PokemonList));
JohtoBench4ComboBox.setModel(new javax.swing.DefaultComboBoxModel<>(pokemonCards));
AutoCompleteDecorator.decorate(JohtoBench4ComboBox);
Background.add(JohtoBench4ComboBox, new org.netbeans.lib.awtextra.AbsoluteConstraints(490, 70, 100, 20));
JohtoBench4Energy1.setBackground(java.awt.Color.lightGray);
JohtoBench4Energy1.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
JohtoBench4Energy1MouseClicked(evt);
}
});
Background.add(JohtoBench4Energy1, new org.netbeans.lib.awtextra.AbsoluteConstraints(490, 50, -1, 20));
Background.setLayer(JohtoBench4Energy1, 1);
JohtoBench4Energy2.setBackground(java.awt.Color.lightGray);
JohtoBench4Energy2.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
JohtoBench4Energy2MouseClicked(evt);
}
});
Background.add(JohtoBench4Energy2, new org.netbeans.lib.awtextra.AbsoluteConstraints(510, 50, 30, 20));
Background.setLayer(JohtoBench4Energy2, 2);
JohtoBench4Energy3.setBackground(java.awt.Color.lightGray);
JohtoBench4Energy3.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
JohtoBench4Energy3MouseClicked(evt);
}
});
Background.add(JohtoBench4Energy3, new org.netbeans.lib.awtextra.AbsoluteConstraints(530, 50, 30, 20));
Background.setLayer(JohtoBench4Energy3, 3);
JohtoBench4Energy4.setBackground(java.awt.Color.lightGray);
JohtoBench4Energy4.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
JohtoBench4Energy4MouseClicked(evt);
}
});
Background.add(JohtoBench4Energy4, new org.netbeans.lib.awtextra.AbsoluteConstraints(550, 50, 30, 20));
Background.setLayer(JohtoBench4Energy4, 4);
JohtoBench3ComboBox.setEditable(true);
// JohtoBench3.setModel(new
// javax.swing.DefaultComboBoxModel(PokemonList));
JohtoBench3ComboBox.setModel(new javax.swing.DefaultComboBoxModel<>(pokemonCards));
AutoCompleteDecorator.decorate(JohtoBench3ComboBox);
Background.add(JohtoBench3ComboBox, new org.netbeans.lib.awtextra.AbsoluteConstraints(330, 70, 100, 20));
JohtoBench3Energy1.setBackground(java.awt.Color.lightGray);
JohtoBench3Energy1.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
JohtoBench3Energy1MouseClicked(evt);
}
});
Background.add(JohtoBench3Energy1, new org.netbeans.lib.awtextra.AbsoluteConstraints(330, 50, -1, 20));
Background.setLayer(JohtoBench3Energy1, 1);
JohtoBench3Energy2.setBackground(java.awt.Color.lightGray);
JohtoBench3Energy2.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
JohtoBench3Energy2MouseClicked(evt);
}
});
Background.add(JohtoBench3Energy2, new org.netbeans.lib.awtextra.AbsoluteConstraints(350, 50, 30, 20));
Background.setLayer(JohtoBench3Energy2, 2);
JohtoBench3Energy3.setBackground(java.awt.Color.lightGray);
JohtoBench3Energy3.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
JohtoBench3Energy3MouseClicked(evt);
}
});
Background.add(JohtoBench3Energy3, new org.netbeans.lib.awtextra.AbsoluteConstraints(370, 50, 30, 20));
Background.setLayer(JohtoBench3Energy3, 3);
JohtoBench3Energy4.setBackground(java.awt.Color.lightGray);
JohtoBench3Energy4.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
JohtoBench3Energy4MouseClicked(evt);
}
});
Background.add(JohtoBench3Energy4, new org.netbeans.lib.awtextra.AbsoluteConstraints(390, 50, 30, 20));
Background.setLayer(JohtoBench3Energy4, 4);
JohtoBench2ComboBox.setEditable(true);
// JohtoBench2.setModel(new
// javax.swing.DefaultComboBoxModel(PokemonList));
JohtoBench2ComboBox.setModel(new javax.swing.DefaultComboBoxModel<>(pokemonCards));
AutoCompleteDecorator.decorate(JohtoBench2ComboBox);
Background.add(JohtoBench2ComboBox, new org.netbeans.lib.awtextra.AbsoluteConstraints(170, 70, 100, 20));
JohtoBench2Energy1.setBackground(java.awt.Color.lightGray);
JohtoBench2Energy1.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
JohtoBench2Energy1MouseClicked(evt);
}
});
Background.add(JohtoBench2Energy1, new org.netbeans.lib.awtextra.AbsoluteConstraints(170, 50, -1, 20));
Background.setLayer(JohtoBench2Energy1, 1);
JohtoBench2Energy2.setBackground(java.awt.Color.lightGray);
JohtoBench2Energy2.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
JohtoBench2Energy2MouseClicked(evt);
}
});
Background.add(JohtoBench2Energy2, new org.netbeans.lib.awtextra.AbsoluteConstraints(190, 50, 30, 20));
Background.setLayer(JohtoBench2Energy2, 2);
JohtoBench2Energy3.setBackground(java.awt.Color.lightGray);
JohtoBench2Energy3.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
JohtoBench2Energy3MouseClicked(evt);
}
});
Background.add(JohtoBench2Energy3, new org.netbeans.lib.awtextra.AbsoluteConstraints(210, 50, 30, 20));
Background.setLayer(JohtoBench2Energy3, 3);
JohtoBench2Energy4.setBackground(java.awt.Color.lightGray);
JohtoBench2Energy4.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
JohtoBench2Energy4MouseClicked(evt);
}
});
Background.add(JohtoBench2Energy4, new org.netbeans.lib.awtextra.AbsoluteConstraints(230, 50, 30, 20));
Background.setLayer(JohtoBench2Energy4, 4);
JohtoBench1ComboBox.setEditable(true);
// JohtoBench1.setModel(new
// javax.swing.DefaultComboBoxModel(PokemonList));
JohtoBench1ComboBox.setModel(new javax.swing.DefaultComboBoxModel<>(pokemonCards));
AutoCompleteDecorator.decorate(JohtoBench1ComboBox);
Background.add(JohtoBench1ComboBox, new org.netbeans.lib.awtextra.AbsoluteConstraints(10, 70, 100, 20));
JohtoBench1Energy4.setBackground(java.awt.Color.lightGray);
JohtoBench1Energy4.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
JohtoBench1Energy4MouseClicked(evt);
}
});
Background.add(JohtoBench1Energy4, new org.netbeans.lib.awtextra.AbsoluteConstraints(70, 50, 30, 20));
Background.setLayer(JohtoBench1Energy4, 4);
JohtoBench1Energy3.setBackground(java.awt.Color.lightGray);
JohtoBench1Energy3.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
JohtoBench1Energy3MouseClicked(evt);
}
});
Background.add(JohtoBench1Energy3, new org.netbeans.lib.awtextra.AbsoluteConstraints(50, 50, 30, 20));
Background.setLayer(JohtoBench1Energy3, 3);
JohtoBench1Energy2.setBackground(java.awt.Color.lightGray);
JohtoBench1Energy2.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
JohtoBench1Energy2MouseClicked(evt);
}
});
Background.add(JohtoBench1Energy2, new org.netbeans.lib.awtextra.AbsoluteConstraints(30, 50, 30, 20));
Background.setLayer(JohtoBench1Energy2, 2);
JohtoBench1Energy1.setBackground(java.awt.Color.lightGray);
JohtoBench1Energy1.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
JohtoBench1Energy1MouseClicked(evt);
}
});
Background.add(JohtoBench1Energy1, new org.netbeans.lib.awtextra.AbsoluteConstraints(10, 50, -1, 20));
Background.setLayer(JohtoBench1Energy1, 1);
KantoActiveComboBox.setEditable(true);
// KantoActive.setModel(new
// javax.swing.DefaultComboBoxModel(PokemonList));
KantoActiveComboBox.setModel(new javax.swing.DefaultComboBoxModel<>(pokemonCards));
KantoActiveComboBox.addItemListener(this::KantoActiveItemStateChanged);
AutoCompleteDecorator.decorate(KantoActiveComboBox);
Background.add(KantoActiveComboBox, new org.netbeans.lib.awtextra.AbsoluteConstraints(280, 460, 210, 20));
KantoBench1ComboBox.setEditable(true);
// KantoBench1.setModel(new
// javax.swing.DefaultComboBoxModel(PokemonList));
KantoBench1ComboBox.setModel(new javax.swing.DefaultComboBoxModel<>(pokemonCards));
AutoCompleteDecorator.decorate(KantoBench1ComboBox);
Background.add(KantoBench1ComboBox, new org.netbeans.lib.awtextra.AbsoluteConstraints(10, 620, 100, 20));
KantoBench2ComboBox.setEditable(true);
// KantoBench1.setModel(new
// javax.swing.DefaultComboBoxModel(PokemonList));
KantoBench2ComboBox.setModel(new javax.swing.DefaultComboBoxModel<>(pokemonCards));
AutoCompleteDecorator.decorate(KantoBench2ComboBox);
Background.add(KantoBench2ComboBox, new org.netbeans.lib.awtextra.AbsoluteConstraints(170, 620, 100, 20));
KantoBench3ComboBox.setEditable(true);
// KantoBench3.setModel(new
// javax.swing.DefaultComboBoxModel(PokemonList));
KantoBench3ComboBox.setModel(new javax.swing.DefaultComboBoxModel<>(pokemonCards));
AutoCompleteDecorator.decorate(KantoBench3ComboBox);
Background.add(KantoBench3ComboBox, new org.netbeans.lib.awtextra.AbsoluteConstraints(330, 620, 100, 20));
KantoBench4ComboBox.setEditable(true);
// KantoBench4.setModel(new
// javax.swing.DefaultComboBoxModel(PokemonList));
KantoBench4ComboBox.setModel(new javax.swing.DefaultComboBoxModel<>(pokemonCards));
AutoCompleteDecorator.decorate(KantoBench4ComboBox);
Background.add(KantoBench4ComboBox, new org.netbeans.lib.awtextra.AbsoluteConstraints(490, 620, 100, 20));
KantoBench5ComboBox.setEditable(true);
// KantoBench5.setModel(new
// javax.swing.DefaultComboBoxModel(PokemonList));
KantoBench5ComboBox.setModel(new javax.swing.DefaultComboBoxModel<>(pokemonCards));
AutoCompleteDecorator.decorate(KantoBench5ComboBox);
Background.add(KantoBench5ComboBox, new org.netbeans.lib.awtextra.AbsoluteConstraints(640, 620, 100, 20));
ClearButton.setBackground(new java.awt.Color(0, 0, 0));
// NOI18N
ClearButton.setFont(new java.awt.Font("Tahoma", Font.PLAIN, 12));
ClearButton.setForeground(new java.awt.Color(204, 0, 0));
ClearButton.setText("X");
ClearButton.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
ClearButtonMouseClicked(evt);
}
});
Background.add(ClearButton, new org.netbeans.lib.awtextra.AbsoluteConstraints(10, 300, 50, -1));
JohtoPlus.setBackground(new java.awt.Color(255, 0, 0));
JohtoPlus.setText("+");
JohtoPlus.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
JohtoPlusMouseClicked(evt);
}
});
Background.add(JohtoPlus, new org.netbeans.lib.awtextra.AbsoluteConstraints(340, 280, -1, -1));
Background.setLayer(JohtoPlus, 2);
JohtoMinus.setBackground(new java.awt.Color(255, 0, 0));
JohtoMinus.setText("-");
JohtoMinus.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
JohtoMinusMouseClicked(evt);
}
});
Background.add(JohtoMinus, new org.netbeans.lib.awtextra.AbsoluteConstraints(390, 280, -1, -1));
Background.setLayer(JohtoMinus, 2);
JohtoDamageNumB5.setHorizontalAlignment(javax.swing.JTextField.CENTER);
JohtoDamageNumB5.setText("0");
Background.add(JohtoDamageNumB5, new org.netbeans.lib.awtextra.AbsoluteConstraints(640, 90, 40, -1));
JohtoDamageNum.setEditable(false);
JohtoDamageNum.setHorizontalAlignment(javax.swing.JTextField.CENTER);
JohtoDamageNum.setText("0");
Background.add(JohtoDamageNum, new org.netbeans.lib.awtextra.AbsoluteConstraints(290, 280, 40, -1));
JohtoDamageNumB4.setHorizontalAlignment(javax.swing.JTextField.CENTER);
JohtoDamageNumB4.setText("0");
Background.add(JohtoDamageNumB4, new org.netbeans.lib.awtextra.AbsoluteConstraints(490, 90, 40, -1));
JohtoDamageNumB3.setHorizontalAlignment(javax.swing.JTextField.CENTER);
JohtoDamageNumB3.setText("0");
Background.add(JohtoDamageNumB3, new org.netbeans.lib.awtextra.AbsoluteConstraints(330, 90, 40, -1));
JohtoDamageNumB2.setHorizontalAlignment(javax.swing.JTextField.CENTER);
JohtoDamageNumB2.setText("0");
Background.add(JohtoDamageNumB2, new org.netbeans.lib.awtextra.AbsoluteConstraints(170, 90, 40, -1));
JohtoDamageNumB1.setHorizontalAlignment(javax.swing.JTextField.CENTER);
JohtoDamageNumB1.setText("0");
Background.add(JohtoDamageNumB1, new org.netbeans.lib.awtextra.AbsoluteConstraints(10, 90, 40, -1));
KantoPlus.setBackground(new java.awt.Color(255, 255, 255));
KantoPlus.setText("+");
KantoPlus.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
KantoPlusMouseClicked(evt);
}
});
Background.add(KantoPlus, new org.netbeans.lib.awtextra.AbsoluteConstraints(340, 480, -1, -1));
Background.setLayer(KantoPlus, 2);
KantoMinus.setBackground(new java.awt.Color(255, 255, 255));
KantoMinus.setText("-");
KantoMinus.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
KantoMinusMouseClicked(evt);
}
});
Background.add(KantoMinus, new org.netbeans.lib.awtextra.AbsoluteConstraints(390, 480, -1, -1));
Background.setLayer(KantoMinus, 2);
KantoDamageNum.setEditable(false);
KantoDamageNum.setHorizontalAlignment(javax.swing.JTextField.CENTER);
KantoDamageNum.setText("0");
Background.add(KantoDamageNum, new org.netbeans.lib.awtextra.AbsoluteConstraints(290, 480, 40, -1));
KantoDamageNumB5.setHorizontalAlignment(javax.swing.JTextField.CENTER);
KantoDamageNumB5.setText("0");
Background.add(KantoDamageNumB5, new org.netbeans.lib.awtextra.AbsoluteConstraints(640, 640, 40, -1));
KantoDamageNumB4.setHorizontalAlignment(javax.swing.JTextField.CENTER);
KantoDamageNumB4.setText("0");
Background.add(KantoDamageNumB4, new org.netbeans.lib.awtextra.AbsoluteConstraints(490, 640, 40, -1));
KantoDamageNumB3.setHorizontalAlignment(javax.swing.JTextField.CENTER);
KantoDamageNumB3.setText("0");
Background.add(KantoDamageNumB3, new org.netbeans.lib.awtextra.AbsoluteConstraints(330, 640, 40, -1));
KantoDamageNumB2.setHorizontalAlignment(javax.swing.JTextField.CENTER);
KantoDamageNumB2.setText("0");
Background.add(KantoDamageNumB2, new org.netbeans.lib.awtextra.AbsoluteConstraints(170, 640, 40, -1));
KantoDamageNumB1.setHorizontalAlignment(javax.swing.JTextField.CENTER);
KantoDamageNumB1.setText("0");
Background.add(KantoDamageNumB1, new org.netbeans.lib.awtextra.AbsoluteConstraints(10, 640, 40, -1));
Background.add(StadiumCard, new org.netbeans.lib.awtextra.AbsoluteConstraints(70, 230, 186, 260));
// NOI18N
JohtoCard.setIcon(new javax.swing.ImageIcon(getClass().getResource("/my/pokeboard/images/Back.png")));
JohtoCard.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
JohtoCardMouseClicked(evt);
}
});
Background.add(JohtoCard, new org.netbeans.lib.awtextra.AbsoluteConstraints(550, 150, 134, 190));
// NOI18N
KantoCard.setIcon(new javax.swing.ImageIcon(getClass().getResource("/my/pokeboard/images/Back.png")));
KantoCard.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
KantoCardMouseClicked(evt);
}
});
Background.add(KantoCard, new org.netbeans.lib.awtextra.AbsoluteConstraints(550, 390, 134, 190));
mid.setBackground(new java.awt.Color(0, 0, 0));
// NOI18N
mid.setIcon(new javax.swing.ImageIcon(getClass().getResource("/my/pokeboard/images/boackground2-1.png")));
mid.setAlignmentY(0.0F);
mid.setBorder(new javax.swing.border.LineBorder(new java.awt.Color(0, 0, 0), 1, true));
mid.setMaximumSize(new java.awt.Dimension(750, 469));
mid.setMinimumSize(new java.awt.Dimension(750, 469));
mid.setPreferredSize(new java.awt.Dimension(750, 469));
Background.add(mid, new org.netbeans.lib.awtextra.AbsoluteConstraints(0, 150, 750, 430));
mid.getAccessibleContext().setAccessibleName("mid");
// NOI18N
Kanto.setIcon(new javax.swing.ImageIcon(getClass().getResource("/my/pokeboard/images/Kanto copy.png")));
Kanto.setBorder(javax.swing.BorderFactory.createLineBorder(new java.awt.Color(0, 0, 0)));
Background.add(Kanto, new org.netbeans.lib.awtextra.AbsoluteConstraints(0, 570, 750, 170));
// NOI18N
Johto.setIcon(new javax.swing.ImageIcon(getClass().getResource("/my/pokeboard/images/Johto copy.png")));
Johto.setBorder(javax.swing.BorderFactory.createLineBorder(new java.awt.Color(0, 0, 0)));
Background.add(Johto, new org.netbeans.lib.awtextra.AbsoluteConstraints(0, 0, 750, 150));
KantoActiveEnergy1.setBackground(java.awt.Color.lightGray);
KantoActiveEnergy1.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
KantoActiveEnergy1MouseClicked(evt);
}
});
Background.add(KantoActiveEnergy1, new org.netbeans.lib.awtextra.AbsoluteConstraints(340, 440, -1, 20));
Background.setLayer(KantoActiveEnergy1, 1);
KantoActiveEnergy2.setBackground(java.awt.Color.lightGray);
KantoActiveEnergy2.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
KantoActiveEnergy2MouseClicked(evt);
}
});
Background.add(KantoActiveEnergy2, new org.netbeans.lib.awtextra.AbsoluteConstraints(360, 440, 30, 20));
Background.setLayer(KantoActiveEnergy2, 2);
KantoActiveEnergy3.setBackground(java.awt.Color.lightGray);
KantoActiveEnergy3.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
KantoActiveEnergy3MouseClicked(evt);
}
});
Background.add(KantoActiveEnergy3, new org.netbeans.lib.awtextra.AbsoluteConstraints(380, 440, 30, 20));
Background.setLayer(KantoActiveEnergy3, 3);
KantoActiveEnergy4.setBackground(java.awt.Color.lightGray);
KantoActiveEnergy4.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
KantoActiveEnergy4MouseClicked(evt);
}
});
Background.add(KantoActiveEnergy4, new org.netbeans.lib.awtextra.AbsoluteConstraints(400, 440, 30, 20));
Background.setLayer(KantoActiveEnergy4, 4);
KantoBench5Energy4.setBackground(java.awt.Color.lightGray);
KantoBench5Energy4.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
KantoBench5Energy4MouseClicked(evt);
}
});
Background.add(KantoBench5Energy4, new org.netbeans.lib.awtextra.AbsoluteConstraints(700, 600, 30, 20));
Background.setLayer(KantoBench5Energy4, 4);
KantoBench5Energy3.setBackground(java.awt.Color.lightGray);
KantoBench5Energy3.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
KantoBench5Energy3MouseClicked(evt);
}
});
Background.add(KantoBench5Energy3, new org.netbeans.lib.awtextra.AbsoluteConstraints(680, 600, 30, 20));
Background.setLayer(KantoBench5Energy3, 3);
KantoBench5Energy2.setBackground(java.awt.Color.lightGray);
KantoBench5Energy2.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
KantoBench5Energy2MouseClicked(evt);
}
});
Background.add(KantoBench5Energy2, new org.netbeans.lib.awtextra.AbsoluteConstraints(660, 600, 30, 20));
Background.setLayer(KantoBench5Energy2, 2);
KantoBench5Energy1.setBackground(java.awt.Color.lightGray);
KantoBench5Energy1.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
KantoBench5Energy1MouseClicked(evt);
}
});
Background.add(KantoBench5Energy1, new org.netbeans.lib.awtextra.AbsoluteConstraints(640, 600, -1, 20));
Background.setLayer(KantoBench5Energy1, 1);
KantoBench4Energy4.setBackground(java.awt.Color.lightGray);
KantoBench4Energy4.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
KantoBench4Energy4MouseClicked(evt);
}
});
Background.add(KantoBench4Energy4, new org.netbeans.lib.awtextra.AbsoluteConstraints(550, 600, 30, 20));
Background.setLayer(KantoBench4Energy4, 4);
KantoBench4Energy3.setBackground(java.awt.Color.lightGray);
KantoBench4Energy3.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
KantoBench4Energy3MouseClicked(evt);
}
});
Background.add(KantoBench4Energy3, new org.netbeans.lib.awtextra.AbsoluteConstraints(530, 600, 30, 20));
Background.setLayer(KantoBench4Energy3, 3);
KantoBench4Energy2.setBackground(java.awt.Color.lightGray);
KantoBench4Energy2.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
KantoBench4Energy2MouseClicked(evt);
}
});
Background.add(KantoBench4Energy2, new org.netbeans.lib.awtextra.AbsoluteConstraints(510, 600, 30, 20));
Background.setLayer(KantoBench4Energy2, 2);
KantoBench4Energy1.setBackground(java.awt.Color.lightGray);
KantoBench4Energy1.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
KantoBench4Energy1MouseClicked(evt);
}
});
Background.add(KantoBench4Energy1, new org.netbeans.lib.awtextra.AbsoluteConstraints(490, 600, -1, 20));
Background.setLayer(KantoBench4Energy1, 1);
KantoBench3Energy4.setBackground(java.awt.Color.lightGray);
KantoBench3Energy4.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
KantoBench3Energy4MouseClicked(evt);
}
});
Background.add(KantoBench3Energy4, new org.netbeans.lib.awtextra.AbsoluteConstraints(390, 600, 30, 20));
Background.setLayer(KantoBench3Energy4, 4);
KantoBench3Energy3.setBackground(java.awt.Color.lightGray);
KantoBench3Energy3.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
KantoBench3Energy3MouseClicked(evt);
}
});
Background.add(KantoBench3Energy3, new org.netbeans.lib.awtextra.AbsoluteConstraints(370, 600, 30, 20));
Background.setLayer(KantoBench3Energy3, 3);
KantoBench3Energy2.setBackground(java.awt.Color.lightGray);
KantoBench3Energy2.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
KantoBench3Energy2MouseClicked(evt);
}
});
Background.add(KantoBench3Energy2, new org.netbeans.lib.awtextra.AbsoluteConstraints(350, 600, 30, 20));
Background.setLayer(KantoBench3Energy2, 2);
KantoBench3Energy1.setBackground(java.awt.Color.lightGray);
KantoBench3Energy1.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
KantoBench3Energy1MouseClicked(evt);
}
});
Background.add(KantoBench3Energy1, new org.netbeans.lib.awtextra.AbsoluteConstraints(330, 600, -1, 20));
Background.setLayer(KantoBench3Energy1, 1);
KantoBench2Energy4.setBackground(java.awt.Color.lightGray);
KantoBench2Energy4.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
KantoBench2Energy4MouseClicked(evt);
}
});
Background.add(KantoBench2Energy4, new org.netbeans.lib.awtextra.AbsoluteConstraints(230, 600, 30, 20));
Background.setLayer(KantoBench2Energy4, 4);
KantoBench2Energy3.setBackground(java.awt.Color.lightGray);
KantoBench2Energy3.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
KantoBench2Energy3MouseClicked(evt);
}
});
Background.add(KantoBench2Energy3, new org.netbeans.lib.awtextra.AbsoluteConstraints(210, 600, 30, 20));
Background.setLayer(KantoBench2Energy3, 3);
KantoBench2Energy2.setBackground(java.awt.Color.lightGray);
KantoBench2Energy2.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
KantoBench2Energy2MouseClicked(evt);
}
});
Background.add(KantoBench2Energy2, new org.netbeans.lib.awtextra.AbsoluteConstraints(190, 600, 30, 20));
Background.setLayer(KantoBench2Energy2, 2);
KantoBench2Energy1.setBackground(java.awt.Color.lightGray);
KantoBench2Energy1.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
KantoBench2Energy1MouseClicked(evt);
}
});
Background.add(KantoBench2Energy1, new org.netbeans.lib.awtextra.AbsoluteConstraints(170, 600, -1, 20));
Background.setLayer(KantoBench2Energy1, 1);
KantoBench1Energy4.setBackground(java.awt.Color.lightGray);
KantoBench1Energy4.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
KantoBench1Energy4MouseClicked(evt);
}
});
Background.add(KantoBench1Energy4, new org.netbeans.lib.awtextra.AbsoluteConstraints(70, 600, 30, 20));
Background.setLayer(KantoBench1Energy4, 4);
KantoBench1Energy3.setBackground(java.awt.Color.lightGray);
KantoBench1Energy3.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
KantoBench1Energy3MouseClicked(evt);
}
});
Background.add(KantoBench1Energy3, new org.netbeans.lib.awtextra.AbsoluteConstraints(50, 600, 30, 20));
Background.setLayer(KantoBench1Energy3, 3);
KantoBench1Energy2.setBackground(java.awt.Color.lightGray);
KantoBench1Energy2.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
KantoBench1Energy2MouseClicked(evt);
}
});
Background.add(KantoBench1Energy2, new org.netbeans.lib.awtextra.AbsoluteConstraints(30, 600, 30, 20));
Background.setLayer(KantoBench1Energy2, 2);
KantoBench1Energy1.setBackground(java.awt.Color.lightGray);
KantoBench1Energy1.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
KantoBench1Energy1MouseClicked(evt);
}
});
Background.add(KantoBench1Energy1, new org.netbeans.lib.awtextra.AbsoluteConstraints(10, 600, -1, 20));
Background.setLayer(KantoBench1Energy1, 1);
JohtoPZ.setBackground(java.awt.Color.lightGray);
JohtoPZ.setText("PZ");
JohtoPZ.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
JohtoPZMouseClicked(evt);
}
});
Background.add(JohtoPZ, new org.netbeans.lib.awtextra.AbsoluteConstraints(480, 160, -1, -1));
Background.setLayer(JohtoPZ, 2);
JohtoSL.setBackground(java.awt.Color.lightGray);
JohtoSL.setText("SL");
JohtoSL.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
JohtoSLMouseClicked(evt);
}
});
Background.add(JohtoSL, new org.netbeans.lib.awtextra.AbsoluteConstraints(430, 160, -1, -1));
Background.setLayer(JohtoSL, 2);
JohtoPO.setBackground(java.awt.Color.lightGray);
JohtoPO.setText("PO");
JohtoPO.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
JohtoPOMouseClicked(evt);
}
});
Background.add(JohtoPO, new org.netbeans.lib.awtextra.AbsoluteConstraints(370, 160, -1, -1));
Background.setLayer(JohtoPO, 2);
JohtoBR.setBackground(java.awt.Color.lightGray);
JohtoBR.setText("BR");
JohtoBR.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
JohtoBRMouseClicked(evt);
}
});
Background.add(JohtoBR, new org.netbeans.lib.awtextra.AbsoluteConstraints(310, 160, -1, -1));
Background.setLayer(JohtoBR, 2);
JohtoCN.setBackground(java.awt.Color.lightGray);
JohtoCN.setText("CN");
JohtoCN.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
JohtoCNMouseClicked(evt);
}
});
Background.add(JohtoCN, new org.netbeans.lib.awtextra.AbsoluteConstraints(250, 160, -1, -1));
Background.setLayer(JohtoCN, 2);
KantoCN.setBackground(java.awt.Color.lightGray);
KantoCN.setText("CN");
KantoCN.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
KantoCNMouseClicked(evt);
}
});
Background.add(KantoCN, new org.netbeans.lib.awtextra.AbsoluteConstraints(250, 540, -1, -1));
Background.setLayer(KantoCN, 2);
KantoBR.setBackground(java.awt.Color.lightGray);
KantoBR.setText("BR");
KantoBR.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
KantoBRMouseClicked(evt);
}
});
Background.add(KantoBR, new org.netbeans.lib.awtextra.AbsoluteConstraints(310, 540, -1, -1));
Background.setLayer(KantoBR, 2);
KantoPO.setBackground(java.awt.Color.lightGray);
KantoPO.setText("PO");
KantoPO.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
KantoPOMouseClicked(evt);
}
});
Background.add(KantoPO, new org.netbeans.lib.awtextra.AbsoluteConstraints(370, 540, -1, -1));
Background.setLayer(KantoPO, 2);
KantoSL.setBackground(java.awt.Color.lightGray);
KantoSL.setText("SL");
KantoSL.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
KantoSLMouseClicked(evt);
}
});
Background.add(KantoSL, new org.netbeans.lib.awtextra.AbsoluteConstraints(430, 540, -1, -1));
Background.setLayer(KantoSL, 2);
KantoPZ.setBackground(java.awt.Color.lightGray);
KantoPZ.setText("PZ");
KantoPZ.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
KantoPZMouseClicked(evt);
}
});
Background.add(KantoPZ, new org.netbeans.lib.awtextra.AbsoluteConstraints(480, 540, -1, -1));
Background.setLayer(KantoPZ, 2);
KantoBench5Switch.setBackground(new java.awt.Color(255, 255, 255));
// NOI18N
KantoBench5Switch.setIcon(new javax.swing.ImageIcon(getClass().getResource("/my/pokeboard/images/switch.png")));
KantoBench5Switch.setPreferredSize(new java.awt.Dimension(33, 10));
KantoBench5Switch.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
KantoBench5SwitchMouseClicked(evt);
}
});
Background.add(KantoBench5Switch, new org.netbeans.lib.awtextra.AbsoluteConstraints(690, 640, 40, 30));
Background.setLayer(KantoBench5Switch, 2);
KantoBench4Switch.setBackground(new java.awt.Color(255, 255, 255));
// NOI18N
KantoBench4Switch.setIcon(new javax.swing.ImageIcon(getClass().getResource("/my/pokeboard/images/switch.png")));
KantoBench4Switch.setPreferredSize(new java.awt.Dimension(33, 10));
KantoBench4Switch.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
KantoBench4SwitchMouseClicked(evt);
}
});
Background.add(KantoBench4Switch, new org.netbeans.lib.awtextra.AbsoluteConstraints(540, 640, 40, 30));
Background.setLayer(KantoBench4Switch, 2);
KantoBench3Switch.setBackground(new java.awt.Color(255, 255, 255));
// NOI18N
KantoBench3Switch.setIcon(new javax.swing.ImageIcon(getClass().getResource("/my/pokeboard/images/switch.png")));
KantoBench3Switch.setPreferredSize(new java.awt.Dimension(33, 10));
KantoBench3Switch.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
KantoBench3SwitchMouseClicked(evt);
}
});
Background.add(KantoBench3Switch, new org.netbeans.lib.awtextra.AbsoluteConstraints(380, 640, 40, 30));
Background.setLayer(KantoBench3Switch, 2);
KantoBench2Switch.setBackground(new java.awt.Color(255, 255, 255));
// NOI18N
KantoBench2Switch.setIcon(new javax.swing.ImageIcon(getClass().getResource("/my/pokeboard/images/switch.png")));
KantoBench2Switch.setPreferredSize(new java.awt.Dimension(33, 10));
KantoBench2Switch.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
KantoBench2SwitchMouseClicked(evt);
}
});
Background.add(KantoBench2Switch, new org.netbeans.lib.awtextra.AbsoluteConstraints(220, 640, 40, 30));
Background.setLayer(KantoBench2Switch, 2);
KantoBench1Switch.setBackground(new java.awt.Color(255, 255, 255));
// NOI18N
KantoBench1Switch.setIcon(new javax.swing.ImageIcon(getClass().getResource("/my/pokeboard/images/switch.png")));
KantoBench1Switch.setPreferredSize(new java.awt.Dimension(33, 10));
KantoBench1Switch.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
KantoBench1SwitchMouseClicked(evt);
}
});
Background.add(KantoBench1Switch, new org.netbeans.lib.awtextra.AbsoluteConstraints(60, 640, 40, 30));
Background.setLayer(KantoBench1Switch, 2);
JohtoBench5Switch.setBackground(new java.awt.Color(255, 0, 0));
// NOI18N
JohtoBench5Switch.setIcon(new javax.swing.ImageIcon(getClass().getResource("/my/pokeboard/images/switch.png")));
JohtoBench5Switch.setPreferredSize(new java.awt.Dimension(33, 10));
JohtoBench5Switch.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
JohtoBench5SwitchMouseClicked(evt);
}
});
Background.add(JohtoBench5Switch, new org.netbeans.lib.awtextra.AbsoluteConstraints(690, 90, 40, 30));
Background.setLayer(JohtoBench5Switch, 2);
JohtoBench4Switch.setBackground(new java.awt.Color(255, 0, 0));
// NOI18N
JohtoBench4Switch.setIcon(new javax.swing.ImageIcon(getClass().getResource("/my/pokeboard/images/switch.png")));
JohtoBench4Switch.setPreferredSize(new java.awt.Dimension(33, 10));
JohtoBench4Switch.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
JohtoBench4SwitchMouseClicked(evt);
}
});
Background.add(JohtoBench4Switch, new org.netbeans.lib.awtextra.AbsoluteConstraints(540, 90, 40, 30));
Background.setLayer(JohtoBench4Switch, 2);
JohtoBench3Switch.setBackground(new java.awt.Color(255, 0, 0));
// NOI18N
JohtoBench3Switch.setIcon(new javax.swing.ImageIcon(getClass().getResource("/my/pokeboard/images/switch.png")));
JohtoBench3Switch.setPreferredSize(new java.awt.Dimension(33, 10));
JohtoBench3Switch.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
JohtoBench3SwitchMouseClicked(evt);
}
});
Background.add(JohtoBench3Switch, new org.netbeans.lib.awtextra.AbsoluteConstraints(380, 90, 40, 30));
Background.setLayer(JohtoBench3Switch, 2);
JohtoBench2Switch.setBackground(new java.awt.Color(255, 0, 0));
// NOI18N
JohtoBench2Switch.setIcon(new javax.swing.ImageIcon(getClass().getResource("/my/pokeboard/images/switch.png")));
JohtoBench2Switch.setPreferredSize(new java.awt.Dimension(33, 10));
JohtoBench2Switch.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
JohtoBench2SwitchMouseClicked(evt);
}
});
Background.add(JohtoBench2Switch, new org.netbeans.lib.awtextra.AbsoluteConstraints(220, 90, 40, 30));
Background.setLayer(JohtoBench2Switch, 2);
JohtoBench1Switch.setBackground(new java.awt.Color(255, 0, 0));
// NOI18N
JohtoBench1Switch.setIcon(new javax.swing.ImageIcon(getClass().getResource("/my/pokeboard/images/switch.png")));
JohtoBench1Switch.setPreferredSize(new java.awt.Dimension(33, 10));
JohtoBench1Switch.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
JohtoBench1SwitchMouseClicked(evt);
}
});
Background.add(JohtoBench1Switch, new org.netbeans.lib.awtextra.AbsoluteConstraints(60, 90, 40, 30));
Background.setLayer(JohtoBench1Switch, 2);
KantoClear.setBackground(new java.awt.Color(255, 255, 255));
// NOI18N
KantoClear.setFont(new java.awt.Font("Tahoma", Font.PLAIN, 12));
KantoClear.setForeground(new java.awt.Color(255, 0, 0));
KantoClear.setText("X");
KantoClear.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
KantoClearMouseClicked(evt);
}
});
Background.add(KantoClear, new org.netbeans.lib.awtextra.AbsoluteConstraints(440, 480, -1, -1));
Background.setLayer(KantoClear, 2);
JohtoClear.setBackground(new java.awt.Color(255, 0, 0));
// NOI18N
JohtoClear.setFont(new java.awt.Font("Tahoma", Font.PLAIN, 12));
JohtoClear.setText("X");
JohtoClear.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
JohtoClearMouseClicked(evt);
}
});
Background.add(JohtoClear, new org.netbeans.lib.awtextra.AbsoluteConstraints(440, 280, -1, -1));
Background.setLayer(JohtoClear, 2);
javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());
getContentPane().setLayout(layout);
layout.setHorizontalGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(layout.createSequentialGroup().addComponent(Background, javax.swing.GroupLayout.PREFERRED_SIZE, 750, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 0, Short.MAX_VALUE)));
layout.setVerticalGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(layout.createSequentialGroup().addComponent(Background, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addGap(0, 10, Short.MAX_VALUE)));
pack();
}Example 82
| Project: ClassiCubeLauncher-master File: DebugWindow.java View source code |
/**
* This method is called from within the constructor to initialize the form. WARNING: Do NOT
* modify this code. The content of this method is always regenerated by the Form Editor.
*/
@SuppressWarnings("unchecked")
private // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
void initComponents() {
javax.swing.JScrollPane jScrollPane1 = new javax.swing.JScrollPane();
tConsole = new javax.swing.JTextArea();
jScrollPane1.setVerticalScrollBarPolicy(javax.swing.ScrollPaneConstants.VERTICAL_SCROLLBAR_ALWAYS);
tConsole.setEditable(false);
tConsole.setBackground(new java.awt.Color(0, 0, 0));
tConsole.setColumns(80);
// NOI18N
tConsole.setFont(new java.awt.Font("Monospaced", 0, 12));
tConsole.setForeground(new java.awt.Color(204, 204, 204));
tConsole.setLineWrap(true);
tConsole.setRows(20);
tConsole.setTabSize(4);
tConsole.setWrapStyleWord(true);
tConsole.setBorder(null);
tConsole.setCaretColor(new java.awt.Color(255, 255, 255));
jScrollPane1.setViewportView(tConsole);
getContentPane().add(jScrollPane1, java.awt.BorderLayout.CENTER);
pack();
}Example 83
| Project: grouper-client-master File: ColorConverter.java View source code |
public Object unmarshal(HierarchicalStreamReader reader, UnmarshallingContext context) {
Map elements = new HashMap();
while (reader.hasMoreChildren()) {
reader.moveDown();
elements.put(reader.getNodeName(), Integer.valueOf(reader.getValue()));
reader.moveUp();
}
return new Color(((Integer) elements.get("red")).intValue(), ((Integer) elements.get("green")).intValue(), ((Integer) elements.get("blue")).intValue(), ((Integer) elements.get("alpha")).intValue());
}Example 84
| Project: pentaho-reporting-master File: ColorConceptMapper.java View source code |
/**
* @param value
* @param type
* @return
*/
public Object getValue(final Object value, final Class type, final DataAttributeContext context) {
if (value == null) {
return null;
}
if (value instanceof Color == false) {
return null;
}
if (type == null || Object.class.equals(type) || Color.class.equals(type)) {
return value;
}
final Color settings = (Color) value;
final java.awt.Color color = new java.awt.Color(settings.getRed(), settings.getGreen(), settings.getBlue());
if (java.awt.Color.class.equals(type)) {
return color;
}
if (String.class.equals(type)) {
try {
return colorValueConverter.toAttributeValue(color);
} catch (BeanException e) {
return null;
}
}
return null;
}Example 85
| Project: rfDynHUD-master File: DrawnString.java View source code |
private void clear(int offsetX, int offsetY, java.awt.Color clearColor, TextureImage2D clearBackground, int clearOffsetX, int clearOffsetY, TextureImage2D texture, Rect2i dirtyRect) {
if ((clearRect.getWidth() <= 0) || (clearRect.getHeight() <= 0))
return;
final int x = clearRect.getLeft();
final int y = clearRect.getTop();
final int width = clearRect.getWidth();
//final int height = clearRect.getHeight() - fontDescent;
final int height = clearRect.getHeight();
if ((clearColor == null) && (clearBackground == null)) {
widget.clearBackgroundRegion(texture, offsetX, offsetY, x - offsetX, y - offsetY, width, height, true, dirtyRect);
} else {
texture.getTextureCanvas().pushClip(x, y, width, height, true);
try {
if (clearColor != null) {
texture.clear(clearColor, x, y, width, height, true, dirtyRect);
}
if (clearBackground != null) {
int x1_ = x - clearOffsetX;
int y1_ = y - clearOffsetY;
int x2_ = x1_ + width - 1;
int y2_ = y1_ + height - 1;
x1_ = Math.max(x1_, 0);
y1_ = Math.max(y1_, 0);
x2_ = Math.min(x2_, clearBackground.getWidth() - 1);
y2_ = Math.min(y2_, clearBackground.getHeight() - 1);
int w_ = x2_ - x1_ + 1;
int h_ = y2_ - y1_ + 1;
if ((w_ > 0) && (h_ > 0)) {
int x_ = x + (x1_ - x + clearOffsetX);
int y_ = y + (y1_ - y + clearOffsetY);
texture.clear(clearBackground, x1_, y1_, w_, h_, x_, y_, w_, h_, true, dirtyRect);
}
//texture.clear( clearBackground, x1_, y1_, width, height, x, y, width, height, true, dirtyRect );
}
} finally {
texture.getTextureCanvas().popClip();
}
}
clearRect.setSize(0, 0);
}Example 86
| Project: ubc_viscog-master File: MoreImmutablesTest.java View source code |
// matteborder - only with color - no icon
public void testMatteBorder() {
DumperOptions options = new DumperOptions();
options.setWidth(400);
Yaml yaml = new Yaml(new ImmutablesRepresenter(), options);
Insets insets = new Insets(10, 20, 30, 40);
Color color = new Color(100, 150, 200);
MatteBorder border = BorderFactory.createMatteBorder(insets.top, insets.left, insets.bottom, insets.right, color);
String dump = yaml.dump(border);
assertEquals("!!javax.swing.border.MatteBorder [!!java.awt.Insets [10, 20, 30, 40], !!java.awt.Color [100, 150, 200, 255]]\n", dump);
Object loaded = yaml.load(dump);
assertTrue(loaded instanceof MatteBorder);
MatteBorder loadedBorder = (MatteBorder) loaded;
assertEquals(insets, loadedBorder.getBorderInsets());
assertEquals(color, loadedBorder.getMatteColor());
}Example 87
| Project: uml-auto-assessment-master File: TestableWindowControllerTest.java View source code |
// ----------------------------------------------------------
/**
* Test rectangle.
*/
public void testRectangle() {
FilledRect rect = new FilledRect(10, 20, 100, 200, window.getCanvas());
rect.setColor(java.awt.Color.RED);
//existence statements
//there is some object
window.assertHas2DObject(null, null, null, null, null, null);
//there is a FilledRect
window.assertHas2DObject(FilledRect.class, null, null, null, null, null);
//there is a FilledRect at (10,20)
window.assertHas2DObject(FilledRect.class, new Location(10, 20), null, null, null, null);
//there is a FilledRect at (10,20) with width 100
window.assertHas2DObject(FilledRect.class, new Location(10, 20), 100.0, null, null, null);
//etc.
window.assertHas2DObject(FilledRect.class, new Location(10, 20), 100.0, 200.0, null, null);
window.assertHas2DObject(FilledRect.class, new Location(10, 20), 100.0, 200.0, java.awt.Color.RED, null);
window.assertHas2DObject(FilledRect.class, new Location(10, 20), 100.0, 200.0, java.awt.Color.RED, true);
//nonexistence statements
//there is no framedrect
window.assertNo2DObject(FramedRect.class, null, null, null, null, null);
//there are no invisible objects
window.assertNo2DObject(null, null, null, null, null, false);
}Example 88
| Project: abstools-master File: NullValueProvider.java View source code |
public static Object getNullValue(Class<?> objectClass) {
if (objectClass == String.class) {
return "";
}
if (objectClass == Boolean.TYPE) {
return Boolean.FALSE;
}
if (objectClass.isPrimitive() || Number.class.isAssignableFrom(objectClass)) {
return ObjectFactory.createFromString(objectClass, "0");
}
if (objectClass == Date.class) {
return new Date(0);
}
if (objectClass == Color.class) {
return Color.WHITE;
}
if (objectClass == File.class) {
return new File(System.getProperty("user.home"), "untitled");
}
if (objectClass == File[].class) {
return new File[0];
}
if (objectClass == Font.class) {
return new Font("Dialog", Font.PLAIN, 12);
}
return null;
}Example 89
| Project: AliView-master File: ImageExporter.java View source code |
/**
*
*/
private static synchronized BufferedImage getBufferedImageFromComponent(Component comp) {
// Create a buffered image
BufferedImage image = new BufferedImage(comp.getWidth(), comp.getHeight(), BufferedImage.TYPE_INT_RGB);
Graphics2D g2 = (Graphics2D) image.getGraphics();
// First draw a background
g2.setColor(Color.WHITE);
g2.fillRect(0, 0, comp.getWidth(), comp.getHeight());
//Then draw component
comp.paint(g2);
return image;
}Example 90
| Project: AP_Comp_Sci-master File: RockHoundRunner.java View source code |
public static void main(String args[]) {
ActorWorld world = new ActorWorld();
world.add(new Location(7, 8), new Rock());
world.add(new Location(3, 3), new Rock());
world.add(new Location(2, 3), new Flower());
world.add(new Location(2, 8), new Rock(Color.BLUE));
world.add(new Location(5, 5), new Rock(Color.PINK));
world.add(new Location(1, 5), new Rock(Color.RED));
world.add(new Location(7, 2), new Rock(Color.YELLOW));
world.add(new Location(4, 4), new RockHound());
world.add(new Location(5, 8), new RockHound());
world.show();
}Example 91
| Project: archiv-editor-master File: JSONSyntax.java View source code |
@Override public Color getColor(final BaseXTextTokens text) { final int ch = text.curr(); final boolean quote = text.curr() == '"'; Color color = quoted || quote ? GUIConstants.BLUE : Color.black; if (!quoted) { if ("{}[]".indexOf(ch) != -1) color = GUIConstants.RED; if (":,".indexOf(ch) != -1) color = GUIConstants.GRAY; } if (quote) quoted ^= true; return color; }
Example 92
| Project: ARX-master File: Gradient.java View source code |
/**
* Returns the color array
* @param colors
* @param steps
* @return
*/
private final Color[] getGradient(int steps) {
Color[] colors = new Color[] { new Color(display, 0, 0, 255), new Color(display, 0, 255, 255), new Color(display, 0, 200, 0), new Color(display, 255, 255, 0), new Color(display, 255, 69, 0), new Color(display, 255, 0, 0) };
java.awt.Color[] awtcolor = new java.awt.Color[colors.length];
for (int i = 0; i < colors.length; i++) {
Color color = colors[i];
awtcolor[i] = new java.awt.Color(color.getRed(), color.getGreen(), color.getBlue());
}
Color[] result = getGradient(awtcolor, steps);
for (Color c : colors) {
c.dispose();
}
return result;
}Example 93
| Project: Aspose_Words_Java-master File: SetThemeProperties.java View source code |
public static void main(String[] args) throws Exception {
// The path to the documents directory.
String dataDir = Utils.getDataDir(SetThemeProperties.class);
Document doc = new Document(dataDir + "Document.doc");
Theme theme = doc.getTheme();
// Set Times New Roman font as Body theme font for Latin Character.
theme.getMinorFonts().setLatin("Algerian");
// Set Color.Gold for theme color Hyperlink.
theme.getColors().setHyperlink(java.awt.Color.DARK_GRAY);
doc.save(dataDir + "output.doc");
}Example 94
| Project: cewolf-master File: OverlayPostProcessor.java View source code |
public void processChart(Object jfc, Map params) {
XYPlot plot = (XYPlot) ((JFreeChart) jfc).getPlot();
// set different colors for each:
Color[] colors = new Color[] { Color.BLACK, Color.BLUE, Color.YELLOW, Color.GREEN, Color.GRAY };
for (int i = 0; i < 4; i++) {
XYItemRenderer renderer = plot.getRenderer(i);
if (renderer != null) {
renderer.setSeriesPaint(i, colors[i]);
}
}
}Example 95
| Project: chess-master File: ChessPanel.java View source code |
@Override
public void paintComponent(Graphics g) {
Graphics2D g2 = (Graphics2D) g.create();
Paint p = new GradientPaint(0, 0, new Color(21, 0, 255, 100), 0, getHeight(), new Color(0x272B39));
g2.setRenderingHint(RenderingHints.KEY_DITHERING, RenderingHints.VALUE_DITHER_ENABLE);
g2.setPaint(p);
g2.fillRect(0, 0, getWidth(), getHeight());
g2.dispose();
}Example 96
| Project: cms-ce-master File: SepiaFilter.java View source code |
public int filterRGB(int x, int y, int rgb) {
Color c = new Color(rgb);
int r = c.getRed();
int g = c.getGreen();
int b = c.getBlue();
int gry = (r + g + b) / 3;
r = g = b = gry;
r = r + (depth * 2);
g = g + depth;
if (r > 255) {
r = 255;
}
if (g > 255) {
g = 255;
}
int alpha = (rgb >> 24) & 0xff;
rgb = new Color(r, g, b).getRGB();
return (rgb & 0x00ffffff) | (alpha << 24);
}Example 97
| Project: codjo-standalone-common-master File: OperationStateRenderer.java View source code |
/**
* DOCUMENT ME!
*
* @param value The new Value value
*/
public void setValue(Object value) {
int stateCode = ((Integer) value).intValue();
switch(stateCode) {
case OperationState.TO_DO:
setText("A faire");
setBackground(Color.red);
break;
case OperationState.DONE:
setText("Fait");
setBackground(Color.green);
break;
case OperationState.FAILED:
setText("Echec");
setBackground(Color.orange);
break;
default:
setText("N/A");
setBackground(Color.cyan);
}
}Example 98
| Project: components-master File: LineSeparatorImage.java View source code |
public void paint(Graphics2D g2d) {
Dimension dimensions = calculateDimension();
g2d.setStroke(new BasicStroke(1));
g2d.setColor(new Color(this.getHeaderBackgroundColor()));
g2d.fillRect(-1, -1, dimensions.width + 2, dimensions.height + 2);
g2d.setColor(new Color(255, 255, 255, 150));
g2d.drawLine(1, -1, 1, dimensions.height + 2);
}Example 99
| Project: couchapp-takeout-master File: Splash.java View source code |
/** This method is called from within the constructor to
* initialize the form.
* WARNING: Do NOT modify this code. The content of this method is
* always regenerated by the Form Editor.
*/
@SuppressWarnings("unchecked")
private // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
void initComponents() {
jPanel1 = new javax.swing.JPanel();
statusLabel = new javax.swing.JLabel();
progressBar = new javax.swing.JProgressBar();
appNameLabel = new javax.swing.JLabel();
setBackground(new java.awt.Color(255, 255, 255));
jPanel1.setBorder(new javax.swing.border.LineBorder(new java.awt.Color(204, 204, 204), 1, true));
jPanel1.setLayout(new java.awt.BorderLayout());
statusLabel.setBackground(new java.awt.Color(255, 255, 255));
statusLabel.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
statusLabel.setText("Please Wait...");
statusLabel.setMaximumSize(new java.awt.Dimension(278, 200));
statusLabel.setOpaque(true);
jPanel1.add(statusLabel, java.awt.BorderLayout.CENTER);
progressBar.setIndeterminate(true);
progressBar.setMaximumSize(new java.awt.Dimension(200, 14));
jPanel1.add(progressBar, java.awt.BorderLayout.SOUTH);
appNameLabel.setBackground(new java.awt.Color(255, 255, 255));
// NOI18N
appNameLabel.setFont(new java.awt.Font("Lucida Grande", 0, 18));
appNameLabel.setText("App Name");
appNameLabel.setBorder(javax.swing.BorderFactory.createEmptyBorder(3, 10, 3, 1));
appNameLabel.setOpaque(true);
jPanel1.add(appNameLabel, java.awt.BorderLayout.PAGE_START);
getContentPane().add(jPanel1, java.awt.BorderLayout.CENTER);
pack();
}Example 100
| Project: coursework-master File: Checkerboard.java View source code |
public void paintComponent(Graphics g) {
//Draw 2-pixel border
g.setColor(Color.BLACK);
g.drawRect(0, 0, getSize().width - 1, getSize().height - 1);
g.drawRect(1, 1, getSize().width - 3, getSize().height - 3);
//Draw Checkerboard
for (int row = 0; row < 8; ++row) {
for (int col = 0; col < 8; ++col) {
if (row % 2 == col % 2) {
g.setColor(Color.LIGHT_GRAY);
} else {
g.setColor(Color.GRAY);
}
g.fillRect(2 + col * 20, 2 + row * 20, 20, 20);
}
}
}Example 101
| Project: damp.ekeko.snippets-master File: VariableListCellRenderer.java View source code |
public Component getListCellRendererComponent(JList list, Object value, int index, boolean isSelected, boolean cellHasFocus) {
if (value instanceof VariableSummary) {
VariableSummary varSummary = (VariableSummary) value;
setText(varSummary.getName() + " (" + varSummary.getType() + ")");
} else {
setText(value.toString());
}
setBackground(isSelected ? Color.red : Color.white);
setForeground(isSelected ? Color.white : Color.black);
return this;
}