title: How to draw "Gantt Chart" on JPanel?
body: <p>I am trying to implement CPU scheduling algorithms ... i am using <code>java swing</code> (not a runtime design)</p>
  
  <p>This is how my main form looks:
  I've designed it by dragging components from swing containers/controls/menus and dropping them on a <code>JFrame</code>.</p>
  
  <p>I've a <code>JPanel</code> on my main-panel of FCFS tab. I want to draw a 'Gantt Chart' on that panel (as it's shown in picture). I've read so many tutorials and implemented many examples on drawing lines but i don't know how to <code>@Override</code> <code>painComponent()</code> method in my code, because all the variables and methods are generated automatically (am using NetBeans IDE), and am unable to locate my <code>JPanel</code> (on which i want to draw lines).</p>
  
  <p><img src="https://i.stack.imgur.com/C1KKQ.jpg" alt="enter image description here"></p>
  
  <p>I want to draw a "Gantt Chart" like this one. It will be generated automatically when user enters CPU burst for a number of processes and presses "Calculate" button. The current chart will be generated if user enters '10 ms' burst for each process.</p>
  
  <p><img src="https://i.stack.imgur.com/rs2cI.jpg" alt="enter image description here"></p>
  
  <p>In this picture i've tried to explain the sequence of components, i've added on my JFrame, along with their variable names.</p>
  
  <p><img src="https://i.stack.imgur.com/l7gAz.jpg" alt="enter image description here"></p>
  
  <p>I'm searching for the solution from last 15 days ... but am stuck in this problem ... please please help me to solve this problem.</p>
  
  <p>Please please please help me...</p>