Home
Blogs
Questions
Jobs
Monetize

Home

About Us

Blogs

Questions

Jobs

Monetize

Post Job

banner

Questions about paintcomponent

Read more about paintcomponent

python (12.9k questions)

javascript (9.2k questions)

reactjs (4.7k questions)

java (4.2k questions)

java (4.2k questions)

c# (3.5k questions)

c# (3.5k questions)

html (3.3k questions)

Questions - paintcomponent

Why does paint(Graphics g) work, while paintComponent(Graphics g) does not?

I am very much a noob when it comes to swing. So far, all of my knowledge comes from YouTube and Stack Overflow. I am trying to make an interactive 5x5 board, with a random image in every spot, and a ...
test-img

Sterling.wp

java

swing

jpanel

paint

paintcomponent

Votes: 0

Answers: 3

Latest Answer

Again, no issue. Both paint and paintComponent will produce a grid, the problem isn't with the code you're presenting us. import java.awt.Color; import java.awt.Dimension; import java.awt.EventQueue; ...
test-img

MadProgrammer

JAVA code doesn't run because of many threads

I have a small problem. I wanted to draw something in JPanel using paintComponent() but I wanted the objects to be drawn with a delay. I realized that Thread.sleep() doesn't work to make that delay so...
test-img

Tomek Nałęcz

java

multithreading

paintcomponent

scheduledexecutorservice

Votes: 0

Answers: 0

Posts

Questions

Blogs

Jobs

The ultimate platform for coders and IT specialists

About

  • Company
  • Support

  • Platform

  • Terms & Conditions
  • Privacy statement
  • Cookie policy
  • Cookie option
  • OnlyCoders © 2025  |  All rights reserved