On Fri, Apr 26, 2013 at 8:15 AM, <[email protected]> wrote:

>   Today's Topic Summary
>
> Group: http://groups.google.com/group/jpassion_java/topics
>
>    - 
> JFrame_AddJPanelToJFrame_JPanel_paint<#13e4532fa10cff14_group_thread_0>[1 
> Update]
>    - JFrame_AddJPanelToJFrame_JPanel_paint" sample application in Swing,
>    Java Programming course <#13e4532fa10cff14_group_thread_1> [1 Update]
>    - "paint" method <#13e4532fa10cff14_group_thread_2> [1 Update]
>
>   
> JFrame_AddJPanelToJFrame_JPanel_paint<http://groups.google.com/group/jpassion_java/t/a04f3e41de92143f>
>
>    Haichien Nguyen <[email protected]> Apr 24 01:52PM -0700
>
>    Hi there
>
>    I just want to ask about "JFrame_AddJPanelToJFrame_**JPanel_paint"
>    sample
>    application in Swing, Java Programming course. There is method "paint"
>    in
>    this project, which never be called anywhere in the project, but it
>    still
>    being executed. I don't understand that. Please explain for me.
>
>    Best regards
>
>
>
>   JFrame_AddJPanelToJFrame_JPanel_paint" sample application in Swing,
> Java Programming 
> course<http://groups.google.com/group/jpassion_java/t/4661fb41d1c773dc>
>
>    Haichien Nguyen <[email protected]> Apr 24 05:41PM -0700
>
>    Hi there
>
>    I just want to ask about "JFrame_AddJPanelToJFrame_**JPanel_paint"
>    sample
>    application in Swing, Java Programming course. There is method "paint"
>    in
>    this project, which never be called anywhere in the project, but it
>    still
>    being executed. I don't understand that. Please explain for me.
>
>
>    --
>    Best regards,
>
>
>
>   "paint" 
> method<http://groups.google.com/group/jpassion_java/t/fb190cb0c2856616>
>
>    Haichien Nguyen <[email protected]> Apr 24 09:54PM -0700
>
>    Hi All
>
>    Please look at the code below and tell me why "paint" method run
>    without
>    being callled? For your reference it is sample 1.3 "
>    JFrame_AddJPanelToJFrame_JPanel_paint " in Swing - Java programming
>
>    Thank you
>
>    =============
>
>
>    package mypackage;
>
>    import java.awt.Color;
>    import java.awt.Font;
>    import java.awt.Graphics;
>    import javax.swing.JFrame;
>    import javax.swing.JPanel;
>
>    public class Main extends JPanel {
>
>    Main() {
>    setBackground(Color.black);
>    }
>
>    public void paint(Graphics g) {
>    g.setColor(new Color(0,255,0)); //green
>    g.setFont(new Font("Helvetica",Font.PLAIN,16));
>    g.drawString("Hello GUI World!", 30, 100);
>    g.setColor(new Color(1.0f,0,0)); //red
>    g.fillRect(30, 100, 150, 10);
>    }
>
>    /* need to place Panel in Frame or other Window */
>    public static void main(String args[]) {
>
>    JFrame jFrame = new JFrame("Testing Graphics Panel");
>    Main gp = new Main(); // It is JPanel
>    jFrame.add(gp);
>    jFrame.setSize(600, 300);
>    jFrame.setVisible(true);
>    }
>    }
>
>
>
>  You received this message because you are subscribed to the Google Group
> jpassion_java.
> You can post via email <[email protected]>.
> To unsubscribe from this group, 
> send<[email protected]>an empty message.
> For more options, 
> visit<http://groups.google.com/group/jpassion_java/topics>this group.
>
> --
> You received this message because you are subscribed to the Google Groups
> "JPassion.com: Java Programming" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to [email protected].
> Visit this group at http://groups.google.com/group/jpassion_java?hl=en-US.
> For more options, visit https://groups.google.com/groups/opt_out.
>
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"JPassion.com: Java Programming" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
Visit this group at http://groups.google.com/group/jpassion_java?hl=en-US.
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to