On implementingthe paint method, the panel does not up

Hi,
I have a panel over which i am adding a second panel.
the second panel appears but when i implement the paintmethod() of second panel, it does not show...
what can be the reason???
deepak

hi!
i included the statement super.paint(g); in the paint method and now i can see the panel.
Following is the paint() method i have written, the on;y problem left is that i can't see the images i had drawn...otherwise line and rectangles are coming fine
super.paint(g);
                    if(showImage)
                              Point pe0 = new Point(180, 110);
                              Point pe1 = new Point(180, 280);
                              Point p0 = new Point(138, 182);
                              Point ce0 = new Point(120, 75);
                              Point ce2 = new Point(240, 75);
                              Point ce1 = new Point(120, 380);
                              Point ce3 = new Point(240, 380);
                              g.drawImage(verticalCloudImage, (int)p0.getX() - 20, (int)p0.getY() - 85, this);
                              g.drawImage(peImage, (int)pe0.getX(), (int)pe0.getY(), this);
                              g.drawImage(peImage, (int)pe1.getX(), (int)pe1.getY()+35, this);
                              g.drawImage(cloudImage, (int)ce0.getX()-88, (int)ce0.getY()-52, this);
                              g.drawImage(ceImage, (int)ce0.getX(), (int)ce0.getY(), this);
                              g.drawImage(cloudImage, (int)ce2.getX(), (int)ce2.getY()-45, this);
                              g.drawImage(ceImage, (int)ce2.getX(), (int)ce2.getY(), this);
                              g.drawImage(cloudImage, (int)ce1.getX()-88, (int)ce1.getY()-22, this);
                              g.drawImage(ceImage, (int)ce1.getX(), (int)ce1.getY(), this);
                              g.drawImage(cloudImage, (int)ce3.getX(), (int)ce3.getY()-22, this);
                              g.drawImage(ceImage, (int)ce3.getX(), (int)ce3.getY(), this);
                              int ceHeight = ceImage.getHeight(this);
                              int ceWidth = ceImage.getWidth(this);
                              int peHeight = peImage.getHeight(this);
                              int peWidth = peImage.getWidth(this);
                              int pHeight = pImage.getHeight(this);
                              int pWidth = pImage.getWidth(this);
                              g.drawLine((int)ce0.getX() + ceWidth/2, (int)ce0.getY() + ceHeight,
                                        (int)pe0.getX() + peWidth/2, (int)pe0.getY());
                              g.drawLine((int)ce2.getX() + ceWidth/2, (int)ce2.getY() + ceHeight,
                                        (int)pe0.getX() + peWidth/2, (int)pe0.getY());
                              g.draw3DRect((int)pe0.getX() + peWidth/2 - 3, (int)pe0.getY() + peHeight - 1,
                                             5, (int)p0.getY() - (int)pe0.getY() - peHeight - 2+23, true);
                              g.draw3DRect((int)p0.getX() + pWidth/2 - 10, (int)p0.getY() + peHeight - 1+20,
                                             5, (int)pe1.getY() - (int)p0.getY() - peHeight + 2+15, true);
                              g.fill3DRect((int)pe0.getX() + peWidth/2 - 3, (int)pe0.getY() + peHeight - 1,
                                             5, (int)p0.getY() - (int)pe0.getY() - peHeight - 2+23, true);
                              g.fill3DRect((int)p0.getX() + pWidth/2 - 10, (int)p0.getY() + peHeight - 1+20,
                                             5, (int)pe1.getY() - (int)p0.getY() - peHeight + 2+15, true);
                              g.drawLine((int)ce1.getX() + ceWidth/2, (int)ce1.getY(),
                                             (int)pe1.getX() + peWidth/2, (int)pe1.getY() + peHeight+35);
                              g.drawLine((int)ce3.getX() + ceWidth/2, (int)ce3.getY(),
                                             (int)pe1.getX() + peWidth/2, (int)pe1.getY() + peHeight+35);

Similar Messages

  • When transfering tracks across to ipod a sliding panel appears on the right hand side of itunes. after acknowleadging the transfer the panel does not slide back out of the way to alow another transfer.

    When transfering tracks to an ipod a sliding panel appears on the right hand side of itunes. This allows the selected track to be transfered. After registering this action the panel does not slide back out of the way to allow scrolling and more song selection. Any solutions..Help?

    I have an even simpler method. I use MyPublisher to print my books. I select their page layout for a two-page spread, drag and drop the image. DONE!  I understand that most people have their favorite places to have work done. I have been extremely pleased with MyPublisher.com, so I haven't even tried the book module in Lightroom.

  • Index Preview Panel does not include all my index entries

    I've put all my chapters in a book and created an Index. All is well until I try to edit the Index. InDesigns materials tell me to go to my Index Preview Panel to make edits, which works fine. But the Panel does not contain all my index entries. I've tried updating the previews and regenerating the Index numerous times, but I still cannot get an up-to-date preview panel. Any ideas???

    Organize Bookmarks was renamed to '''Show All Bookmarks''' in Firefox 4+ versions.

  • The paint bucket tool is not working properly. The colors does not change, any suggestion?

    The paint bucket tool is not working properly. The colors does not change, any suggestion?

    Maybe on the wrong layer.
    It would be more beneficial if you capture your screen with the layers panel open and any layers that are collapsed, expand them.

  • I am part of a family sharing setup.  Can I have my own payment method so the organizer does not get charged for my purchases?

    I am part of a family sharing setup.  Can I have my own payment method so the organizer does not get charged for my purchases?  If so, how do I set this up?

    Yes.  Just redeem gift cards so that your own account always has a sufficient credit balance.  Here is how it works:
    Family purchases and payments
    After you set up your family, any time a family member initiates a new purchase it will be billed directly to your account unless that family member has gift or store credit. First, their store credit will be used to pay the partial or total bill. The remainder will bill to the family organizer's card.

  • The graphic HTML signature panel does not appear in my Mac mail

    The graphic HTML signature panel does not appear in my Mac mail. I have inserted the signature after reading on the forum. But the images do not download - the rest of the text in the signature is in place - just the logo and the baseline which is a graphic file does not download.  Please help.

    Hi, are the pics at a remote location, or on your Mac?
    Have you tried drag & dropping the graphics on the signature window?

  • CC 2014 nik efex - My Nik Efex filters are not working in Photoshop CC 2014 - they appear under plug-ins and seem to work, but after running and clicking okay, no new layer appears - seems to have no effect.  The separate menu panel does not appear either

    My Nik Efex filters are not working in Photoshop CC 2014 - they appear under plug-ins and seem to work, but after running and clicking okay, no new layer appears - seems to have no effect.  The separate menu panel does not appear either.  Help with this?

    BINGO !!!!
    Thanks so much Woodsroad. I had the exact same problem with my Dell Windows 7 64 bit with AMD Radeon 6700 Video card.
    All the video tests passed with flying colors.
    The sniffer rename trick fixed the problem.
    Thank goodness for the internet!

  • When I open Photoshop CS6, the image does not show in Photoshop. The image IS open, i.e. the filename is shown on a tab and the image layers show in the layer panel. What is going on?

    Both Photoshop and Bridge open as usual. But when I open an image, the image does not show in the image area. The image filename does show in a tab and the layers show in the layer panel. What is going on and how do I fix this.

    I resolved the problem. It was somehow related to my using Microsoft
    theme pictures. I set Windows to use the basic theme and the problem
    went away. Thank you for the suggestions.
    Jac

  • In the Program Panel, when I click the Spacebar (i.e., "Play"), the image does not advance.

    In the Program Panel, when I click the Spacebar (i.e., "Play"), the image does not advance. When I click "Play" again (i.e., "Stop"), the still image confirms that we have moved on. Please, What must I do so that when I click the Spacebar (i.e., "Play"), the image does indeed advance? Thanks!

    This pertains to Adobe Premiere Pro CS6:
    Thanks for your prompt reply. This is my first post and I appreciate your patience. I imported media into the Project Panel. From there, I placed a few clips into a sequence in the Timeline. In the Timeline, I clicked on a clip. I then double clicked in Program Panel, and could then see the clip. However, when I click on the space bar, (i.e., "Play") in the Program Panel, the image in that panel does not advance. When I click "Play" again (i.e., "Stop"), the still image confirms that we have moved on a bit in the footage. (The audio plays normally, confirming that we are advancing in time. )
    I want to be able to press the space bar in the Program Panel and to see the "motion picture" in the Program Panel.
    Please, What must I do so that when I click the Spacebar (i.e., "Play") in the Program Panel, the image does indeed advance? Thanks!
    Not sure I yet have the capabibility of providing a URL of the problem. 
    Thanks for your guidance,
    David

  • Ok, the project panel does not work anymore!!!!

    I'm using flash cs5.5 and today I opened my project to start working... just to find out that the project panel does not work. When I click the tab to expand it, flash hangs for a minute and then it works, but the panel is blank, empty. The odd thing, I saved the project as CS5 version to open it in the CS5 Flash, but CS5 it's broken too.
    I tried opening Flash (both versions) without loading any project and the tab does not work either.
    Anyone has an idea on this?
    Thanks!

    Ok, I think I get what the problem is... When I make right click over the PROJECT panel, it displays the flash player popup menu, so I guess it's made with flash/air. What I think is that my flash player is somehow screwed, so it don't displays the project panel contents and won't let me export my FLA files correctly. And it happens in both CS5 and CS5.5 versions.
    Maybe a clean reinstall of both should solve the issue... I reinstalled the CS5.5 two times, and didn't solve the problem, neither uninstalling/installing the flash player plugin for all browsers.
    kglad:
    I only see the tab, when I try to display the panel contents, FLASH hangs like for a minute, then it responds but the panel is blank... no menus, options, nothing.

  • Ipod restore failed  can see on the screen is the cable connection symbom and the ipod does not appear in the LH panel of itunes is there an easy solution to this

    ipod restore failed  can see on the screen is the cable connection symbom and the ipod does not appear in the LH panel of itunes is there an easy solution to this

    To get iTunes to see your iPod try:
    - Placing the iPod in recovery mode.  See:
    iPhone and iPod touch: Unable to update or restore
    - Placing it in recovery DFU mode:
    How to put iPod touch / iPhone into DFU mode « Karthik's scribblings
    - Sometimes this program will get th iPod in recovery mode:
    RecBoot iPod-1.0.2-Mac-Jaxov.zip - File Shared from Box.net - Free Online File Storage

  • Hints image on the animation panel does not change.

    Help I have several animation panels when the program initializes from the constructor. I have a separate AnimationPanel class that creates each panel for display. The initial ?hello ? welcome panel (from the constructor) animates on the main panel when the program begins.
    The problem is I want to have different animation panels (that are stored ) to animate and replace the main panel animation at a push of a button. While, the various panels can animate if called from the constructor, they do not animate when called from a button.
    The buttons I created to switch the main animated panel with a different one seems to work to the extent that it gets the correct music, but the image on the animation panel does not change.
    I know this is a more in depth of a question but might you be able to give me a point in the right direction?
    Here is the code from the constructor that works fine in the constructor to start the main animation.
    public PingPong()
    // null layout because it has a main panel where this display panel is placed
    super(null);
    //panels are created
    instantiatePanels();
    //panels are added to the main content pane
    placePanelsOnView();
    startAnimation();
    initializeAudio();

    The problem is that I now start it with no animation to begin with and just an empty panel, but still when I try to add an animation from the button and it will not start. The contentPane is in a different class that places the buttons and the view together.
    Here is the code that the button calls back with a getNextPanel() :
    AnimatedPanel expertPingPongPlayerPanel
              = new AnimatedPanel( );
    add(expertPingPongPlayerPanel );
         expertPingPongPlayerPanel.animate();
              expertPingPongPlayerPanel.setVisible(true);
              startAnimation();

  • When the screen saver turns off my front panel does not refresh.

    when the screen saver turns off my front panel does not refresh. If I use the show desktop button sometimes I can not maximize my vi by just clicking on it from the start bar.

    I utilize both a screen saver and the show desktop feature but have never seen this problem in the past. You might play around with your screen saver settings to see if they have any affect. You might also try another computer just to make sure something larger scale isn't going on. Also, testing with other programs to make sure it isn't a general OS issue is always a good idea. Other possibilities include changing your Video Driver settings, updating your video driver, and uninstalling - reinstalling.

  • Script error (the object does not support the property or method of loaded0)

    I am getting a script error each time I "run" my site from Dreamweaver (F12). It says something like:
    "The object does not support the property or method of loaded0, code0, url https://apis.google.com" etc etc "Do you want to keep running the script?"
    (I just get it in a different language, so sorry for the translation). What have I done wrong here?

    I am using internet explore, with yahoo as my "startpage"
    These two have different urls, the last one is the one I got today when I didn't have Dreamweaver open. I rarely use google.

  • Application is fine in prompt line but in the JSW does not work

    Hi folks
    I have a stuck problem with my application. It works fine with java ... but does not work with the javaws! The problem is in a inner class who extends a panel which must be painted several times (the application works with a optimazation traffic algorithm)... If i use the inner class, the program does not appear and there is no bug messages.
    If a cut the lines with the drawingPane code, the application run without a problem with the javaws!
    These are the important lines of the code:
    // Main class
    public class AlgConstrutivos extends JPanel
    implements MouseListener, ActionListener{
    // The problem PANEL!!!!!!!!!!
    private JPanel drawingPane;
    // The constructor of main class
    public AlgConstrutivos() {
    drawingPane = new DrawingPane();
    drawingPane.setBackground(Color.white);
    drawingPane.addMouseListener(this);
    //Put the drawing area in a scroll pane.
    JScrollPane scroller = new JScrollPane(drawingPane);
    scroller.setPreferredSize(new Dimension(400,400));
    //Lay out
    add(ordem, BorderLayout.PAGE_START);
    add(scroller, BorderLayout.CENTER);
    // The main function
    public static void main(String[] args) {
    JFrame.setDefaultLookAndFeelDecorated(true);
    //Create and set up the window.
    JFrame frame = new JFrame("Test");
    frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
    //Create and set up the content pane.
    JComponent newContentPane = new AlgConstrutivos();
    newContentPane.setOpaque(true);
    frame.setContentPane(newContentPane);
    //Display the window.
    frame.pack();
    frame.setVisible(true);
    public class DrawingPane extends JPanel {
    public void paintComponent(Graphics g) {
    super.paintComponent(g);
    // Draw some lines and points...
    Any help?
    Thanks...
    Andre Cordenonsi

    Yes... In fact, the inner class is in the same .java file...
    There are no error messages at all!
    My jnpl file is (i run with --> javaws a.jnpl)
    <?xml version="1.0" encoding="UTF-8"?>
    <jnlp spec="1.0+"
    codebase="file:///c:/animacao/" href="a.jnlp"
    >
    <information>
    <title>ARGH!</title>
    <vendor>Myself</vendor>
    <homepage href="/animacao" />
    <description>...</description>
    </information>
    <offline-allowed/>
    <security>
    <all-permissions/>
    </security>
    <resources>
    <j2se version="1.2+" />
    <jar href="Teste.jar"/>
    <nativelib href="Teste.jar"/>
    </resources>
    <application-desc main-class="AlgConstrutivos" />
    </jnlp>
    I try use the nativelib resource, but nothing happens...
    Andre Cordenonsi

Maybe you are looking for