Greg,
Thanks for the response. I think I get it now...
Type: Posts; User: tim8w
Greg,
Thanks for the response. I think I get it now...
Hi,
I have a stupid question. Trying to teach myself about Java Inheritance. I have the following classes:
public class A
{
private int iClassVariableA;
public...
Norm,
I understand what you were trying to do in your example. Thanks. Here's what I got based on your suggestions:
import java.awt.Color;
import java.awt.Graphics;
import java.awt.Rectangle;...
Norm,
@Override does not work in the main, only from an extended class (at least that's what the compiler says anyway)
So you are a moderator on both Forums?
This post is cross posted here:
Drawing on a JFrame that has a Shape (Swing / AWT / SWT forum at JavaRanch)
Hi,
I have created a JFrame for my application that has a custom shape. In this case...
Got it to work by doing the following:
@Override
public void doClick()
{
if (isEnabled())
{
...
Hi,
I have calss JPButton that extends JButton. It basically is a graphical button that shifts 1 pixel to the right and down when mousePressed(), and shifts back when mouseReleased(). Both of those...
Norm,
Not sure what you mean. MyClass creates a JButton adds it to the Frame Container and displays the Frame with the button on it. That much works just fine. And as I mentioned if I assign the...
Norm,
As you should be able to see in the code, I tried to set the KeyListener to the Container. I have a breakpoint in the debugger in all three key routines and it never gets there. I have also...
Norm,
Everytime I try and post the small complete program, the Forum deletes the post...
Norm,
Here's a simple example. I have breakpoints in the debugger on all three key functions and they never get called:
import java.awt.Color;
import java.awt.Container;
import...
I have a JFrame to which I have added JButtons.
win=new JFrame("MyFrame");
win.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
win.setBounds(400,200,335,630);win.setResizable(false);...