Search:

Type: Posts; User: Norm

Search: Search took 0.21 seconds.

  1. Replies
    17
    Views
    2,027

    Re: Choosing the jpanel to draw on?

    It is possible. That is how I have it now.
    Remember the this variable.
  2. Replies
    17
    Views
    2,027

    Re: Choosing the jpanel to draw on?

    Where do you add an instance of the PongDrawer class to the JFrame?
  3. Replies
    17
    Views
    2,027

    Re: Choosing the jpanel to draw on?

    Please post the new code.
  4. Replies
    17
    Views
    2,027

    Re: Choosing the jpanel to draw on?

    Your code draws on the panel.
    However the panel is not visible on the JFrame. Where do you add it?
  5. Replies
    17
    Views
    2,027

    Re: Choosing the jpanel to draw on?

    You have added a paintComponent method to the class.
  6. Replies
    17
    Views
    2,027

    Re: Choosing the jpanel to draw on?

    Where do you add the the JPanel with the paintComponet method to the JFrame?
    What is the size of the JPanel when it is added to the JFrame?
    Add a println to the paintComponent method to show the...
  7. Replies
    17
    Views
    2,027

    Re: Choosing the jpanel to draw on?

    Ok , if you don't want to provide code for testing, then good luck with it.
  8. Replies
    17
    Views
    2,027

    Re: Choosing the jpanel to draw on?

    Have you solved the problem now?
    If you want anyone to help you with the problem, you need to provide: main() method and a JFrame that compiles, executes and shows the problem.
  9. Replies
    17
    Views
    2,027

    Re: Choosing the jpanel to draw on?

    How does anyone test this code? You need a main() method and a JFrame that compiles, executes and shows the problem.
Results 1 to 9 of 9