Shape Buttons/Help

JAVA

    Sponsored Links

    Next

  • 1. how to capture keys from other application
    I need help for : a java code should capture keys from desktop or other applications Ex: notepad, Internet Explorer and other third party software.
  • 2. Text Fields
    I am writing a gui and want my program to remember the values that have been stored in the textfields after the user exits the program so that when the user restarts the program he does not have to re-type the data. I am new to using Java and was told that there was a class that would allow me to do this. Any hints would be appreciated.
  • 3. Image loading
    Hello, I have two classes: main & room //main.java import java.awt.*; import java.applet.*; public class main extends Applet { Image image; room current_room; public main() {} public void init() { image=getImage(getCodeBase(), "someimage.png"); current_room=new room(image); } public void paint(Graphics g) { current_room.paint(g); } } //room.java import java.awt.*; import java.applet.*; public class room extends Applet { Image image; public room(Image _image) { image=_image; } public void init() { } public void paint(Graphics g) { g.drawImage(this.image, 100, 100, null); } } This works like a charm. However, I'd like room to load its image(s) directly, either in room() - gather it ain't possible from tutorials I saw, in init(), didn't work when I tried, in paint() - neither, or in a custom method LoadTile(), didn't work also; I tried every combination I could think of, and though it never worked, I didn't get any exception so the image must have loaded, yet it didn't show on screen. I have browsed Applet, Image, Graphics in the API - something I must have missed, but difficult to know what's missing till you have some knowledge of the language - which I don't - yet. Any pointers? Thank you very much.

Shape Buttons/Help

Postby jim » Wed, 19 Nov 2003 03:17:18 GMT

I have program that I'm working on and it's close but can't quite figure out
how to get the buttons to paint specfic shapes.  anyone have any ideas?
 thanks
JD



Similar Threads:

1.How to use shaped buttons with an overlapped Jpanel

2.Change shape of button

3.Help : Implementing rubberbanding (moving shapes) in Applet

Hello,

I need the advice on how to implement rubberbanding and moving rectangles 
in an applet.

I can think of two approaches.
1. Use Java 2D and handle mouse events in the panel.
2. Draw each rectangle as a AWT/Swing component and let it handle its own
   mouse events.

Can someone advice me which of the above approaches is better. 

In the second approach, I was thinking that if I use a layout manager like
GridBagLayout, then I wont be able to control exact locations of the rectangles.

Your help/advice is appreciated.

Ajay

4.Need help with button click and java code

i have a back button inside the code i have the following:

Response.Redirect("javaScript:history.go(-1)"); 

I can't get the thing to work like i want it to, i want the user to click 
the button and to return to whatever page they came from ... 

i can have a link button that works with this: javaScript:history.go(-1)

But i need a button instead of a link.

Also is there anyway to display a Yes / No dialog when a user hits a button 
on a webpage?

5.External Javascript File and FP Interactive Buttons (help pls)

It seems there is a lot of javascript generated by FP when using Interactive 
Buttons. Has anyone ever tried to pull all the js code out and into an 
external file, and been successful at it? If so, any suggestions how to do it 
"properly / effectively"??

I ask, as I understand making it an external file can speed up the 
page-loading process. Some of the visitors to the web pages I'm creating may 
have lower bandwidths, including 56K modems. Is this right?

Thanks.

Margaret

6. help needed with displaying navigation buttons

7. Creating button dynamically not working in firefox..please help

8. Help with function to dsable all buttons in HTML doccument



Return to JAVA

 

Who is online

Users browsing this forum: No registered users and 68 guest