Copy and paste Components

Please support our Java advertiser: Programming Forums - DaniWeb Sister Site
Reply

Join Date: Oct 2004
Posts: 44
Reputation: jigvesh is an unknown quantity at this point 
Solved Threads: 0
jigvesh jigvesh is offline Offline
Light Poster

Copy and paste Components

 
0
  #1
Feb 24th, 2006
Well, i searched all through google and stuff...but in vain..i want to add a functionality in my program to copy and paste buttons which are present on the screen.....I got a wonderful article to copy and paste text.but what about some swing components???????how do we copy and paste them?????

[site]http://www.cafeaulait.org/course/week13/[/site]
Reply With Quote Quick reply to this message  
Join Date: Jun 2004
Posts: 2,108
Reputation: server_crash is on a distinguished road 
Solved Threads: 18
server_crash server_crash is offline Offline
Postaholic

Re: Copy and paste Components

 
0
  #2
Feb 24th, 2006
Use the ClipBoard?
Reply With Quote Quick reply to this message  
Join Date: Aug 2005
Posts: 216
Reputation: hooknc is an unknown quantity at this point 
Solved Threads: 8
hooknc hooknc is offline Offline
Posting Whiz in Training

Re: Copy and paste Components

 
0
  #3
Feb 24th, 2006
are you talking about cutting and pasting complete swing components, like buttons and panels?
Reply With Quote Quick reply to this message  
Join Date: Oct 2004
Posts: 44
Reputation: jigvesh is an unknown quantity at this point 
Solved Threads: 0
jigvesh jigvesh is offline Offline
Light Poster

Re: Copy and paste Components

 
0
  #4
Feb 26th, 2006
Originally Posted by hooknc
are you talking about cutting and pasting complete swing components, like buttons and panels?
Oh Yeah........something which enables the users to copy and paste the buttons which are present on the interface itself........
Reply With Quote Quick reply to this message  
Join Date: Aug 2005
Posts: 216
Reputation: hooknc is an unknown quantity at this point 
Solved Threads: 8
hooknc hooknc is offline Offline
Posting Whiz in Training

Re: Copy and paste Components

 
0
  #5
Feb 26th, 2006
This is a difficult problem. What is your main goal? Are you trying to build a gui editor?

Just shooting from the hip, but I would think that you would want to create your own buttons that extend the normal components and then extend the current java cut and paste utility. Maybe have an interface called Copyable or something like that and then have the new cut and paste utility look for components that are copyable and go from there...
Reply With Quote Quick reply to this message  
Join Date: Oct 2004
Posts: 44
Reputation: jigvesh is an unknown quantity at this point 
Solved Threads: 0
jigvesh jigvesh is offline Offline
Light Poster

Re: Copy and paste Components

 
0
  #6
Feb 27th, 2006
Originally Posted by hooknc
This is a difficult problem. What is your main goal? Are you trying to build a gui editor?
Oh yes its something like a GUI editor

Just shooting from the hip, but I would think that you would want to create your own buttons that extend the normal components and then extend the current java cut and paste utility. Maybe have an interface called Copyable or something like that and then have the new cut and paste utility look for components that are copyable and go from there...
From all that's written here, i have created my buttons and can drag and drop them too..........and frankly the explanation u gave seemed a bit of greek to me.....I'll be grateful to u if u culd explain it in a bit simpler way.......Thanks..........
Reply With Quote Quick reply to this message  
Join Date: Aug 2005
Posts: 216
Reputation: hooknc is an unknown quantity at this point 
Solved Threads: 8
hooknc hooknc is offline Offline
Posting Whiz in Training

Re: Copy and paste Components

 
0
  #7
Feb 27th, 2006
Reply With Quote Quick reply to this message  
Join Date: Oct 2004
Posts: 44
Reputation: jigvesh is an unknown quantity at this point 
Solved Threads: 0
jigvesh jigvesh is offline Offline
Light Poster

Re: Copy and paste Components

 
0
  #8
Feb 27th, 2006
Originally Posted by hooknc
http://java.sun.com/docs/books/tutor.../misc/dnd.html
Thanks a tonne dude.....Now let me work it out.....
Reply With Quote Quick reply to this message  
Reply

This thread is more than three months old.
Perhaps start a new thread instead?
Message:



Similar Threads
Other Threads in the Java Forum
Thread Tools Search this Thread



About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC