Drawning text/images in a JPanel and then resizing/moving it with the mouse
Hello ebverybody!
I need to be able to draw some text objects in a JPanel and then resize/move it with the mouse... How could I do that!? Same for some images loaded from jpg files...
Should I just paint the text and then repaint when the mouse selects it? How to do this selection?! Or should use something like a jLabel and then change it`s font metrics?!
I need to keep track of the upper left corner of the text/image, as well as the width/height of it. This will be recorded in a file.
The text/images need to smoothly move around the panel as the mouse drags when selectin an entity.. not just "click the entity, then click another point and the entity appears there as if by magic...":)
Please, tell the best way to do that!
Thanks everybody!
Message was edited by:
cassio.marques
I know what you mean! This happened to me as well!
And one thing that I found useful is, if you want to directly select a layer without selecting from the layers pallete and without having autoselect enabled, just hold Ctrl and click on in directly in the image. This saved me a lot of time!
Similar Messages
-
Can I upgrade to OS X Lion, and then reformat my computer with the OS X CD?
Can I upgrade to OS X Lion, and then reformat my computer with the OS X CD? Because if I reformating my mac with the regualr OS X CD, would that erase the Lion? Since I just donwloading the Lion, and don't really have a CD for it.
If you install Lion then erase the drive that will erase Lion. To purchase and download Lion you must first install Snow Leopard 10.6.6 or later to access the App Store where you purchase and download the Lion installer. You might read this before:
Make Your Own Lion Installer
1. After downloading Lion you must first save the Install Mac OS X Lion application. After Lion downloads DO NOT click on the Install button. Go to your Applications folder and make a copy of the Lion installer. Move the copy into your Downloads folder. Now you can click on the Install button. You must do this because the installer deletes itself automatically when it finishes installing Lion.
2. Get a USB flash drive that is at least 8 GBs. Prep this flash drive as follows:
Open Disk Utility in your Utilities folder.
After DU loads select your hard drive (this is the entry with the mfgr.'s ID and size) from the left side list. Note the SMART status of the drive in DU's status area. If it does not say "Verified" then the drive is failing or has failed and will need replacing. SMART info will not be reported on external drives. Otherwise, click on the Partition tab in the DU main window.
Under the Volume Scheme heading set the number of partitions from the drop down menu to one. Set the format type to Mac OS Extended (Journaled.) Click on the Options button, set the partition scheme to GUID then click on the OK button. Click on the Partition button and wait until the process has completed.
Select the volume you just created (this is the sub-entry under the drive entry) from the left side list. Click on the Erase tab in the DU main window.
Set the format type to Mac OS Extended (Journaled.) Click on the Options button, check the button for Zero Data and click on OK to return to the Erase window.
Click on the Erase button. The format process can take up to several hours depending upon the drive size.
3. Locate the saved Lion installer in your Downloads folder. CTRL- or RIGHT-click on the installer and select Show Package Contents from the contextual menu. Double-click on the Contents folder to open it. Double-click on the SharedSupport folder. In this folder you will see a disc image named InstallESD.dmg.
4. Plug in your freshly prepared USB flash drive. You are going to clone the InstallESD.dmg disc image to the flash drive as follows:
Open Disk Utility.
Select the USB flash drive from the left side list.
Click on the Restore tab in the DU main window.
Check the box labeled Erase destination.
Select the USB flash drive volume from the left side list and drag it to the Destination entry field.
Drag the InstallESD.dmg disc image file into the Source entry field.
Double-check you got it right, then click on the Restore button.
When the clone is completed you have a fully bootable Lion installer that you can use without having to re-download Lion. -
i have an ipod 4 with iOS 5 and then ran an update with the 5.0.1 and it is not working, i got an error message
This device is not registered as part of the iPhone developer proraom . ##br####br## if yuo are member of the program.,please register your device in ..you can update over the air with strong wireless signal, or by connecting to a computer running iTunes. Either works well. If you do the update over the air, be sure and attach your iPhone to a wall outlet so you have a solid power supply and don't risk the battery dying during the update.
The iTunes approach installs a much larger file because of the connection, but if you have not updated since 5.1 that might be a better approach...replace the entire operating system instead of patching.
Either way, backup the iPhone yourself just for your own protection in the off-chance something should go wrong...a little paranoia while updating is a good thing -
I've been having this problem where I can't use the move tool with the mouse properly. I'll go and select a single item on a layer and then try to move it with the mouse (move tool). I've done this before and still do it all the time on Photoshop on my other machines. However, on my laptop it won't work. I grab the single object I want to move and the second I move it, it defaults to moving every single layer in my file. The only way to get around it is to use the arrows, but that's becoming laborious and frustrating.
Any ideas?I know what you mean! This happened to me as well!
And one thing that I found useful is, if you want to directly select a layer without selecting from the layers pallete and without having autoselect enabled, just hold Ctrl and click on in directly in the image. This saved me a lot of time! -
Here is the entire error message I get in addition to what I typed above (I could NOT copy it - I had to write it down so I could send it to you).
https://webmail.reagan.com/versions/webmail/8.14.6-RC/popup.php?wsid=0251f407d826d9d121577f50f3052
Then I have to hit OK and this comes up:
prevent this page from creating additional dialogs
This happens if I am in the middle of an e-mail, have to go elsewhere to find info to add to the e-mail and then when I come back, I cannot continue the e-mail. I have to copy the e-mail, save it and start all over.
Can you HELP me? I use REAGAN.COM for my e-mails.
P.S. This does NOT happen all the time - I would say one out of every 20 e-mails, but it is way too time consuming when it does happen that I have to start all over again.
Many thanks.It sounds as though a script on the site, or an advertisement, is not working quite right...
When you have a problem with one particular site, a good "first thing to try" is clearing your Firefox cache and deleting your saved cookies for the site.
(1) Bypass Firefox's Cache
Use Ctrl+Shift+r to reload the page fresh from the server.
(You also can clear Firefox's cache completely using:
orange Firefox button ''or'' Tools menu > Options > Advanced
On the Network mini-tab > Cached Web Content : "Clear Now")
(2) Remove the site's cookies using either of these. Save any pending work first.
While viewing a page on the site:
* right-click and choose View Page Info > Security > "View Cookies"
* Alt+t (open the classic Tools menu) > Page Info > Security > "View Cookies"
Then try reloading the page. Does that help? -
Confirm an account and then update a view with the results of customer hist
Hello Everyone,
I have a question and was wondering if someone can help.
In IC Webclient, in a B2B scenario, I change the framework so that when it tries to call BuPaIbaseSearch view, calls instead IRecHistory.
My intention is that when we need to identify an account, we show the views BuPaSearchB2B and the IRecHistory, side-by-side. OK.
When we confirm an acount, I need to display the last five interaction records in the IRecHistory view.
The problem is that when I confirm an acount (at BuPaSearchB2B), this view (IRecHistory) changes his buttons layout, but doesn't fill the table with the data. When if I go to somewhere else, no matter what entry in my navigation bar, and then return, the table is now filled.
How can I fill this table, right after the confirmation of an account? Maybe a refresh of the IRecHistory view?? How can I manage that?
Can somebody give me hints?
Best regards
Bruno GarciaI am not sure to understand what you are explaining. As far as I understand you have two frames and when you change somehing in one and you go to the other passing a table the last one does not get the values but when you return you have the table fill.
Well, I am also working with frames and I have had the same problems with the attributes. Sometimes it was because they were "Auto", and other it was because the page was stateless instead of statefull. I am not sure enough as to explain you what is the rigth combination so I suggest you to try.
Good luck.
-- Oscar -- -
large number of duplicate listings of songs. 1 (or several) is found and then 1 or more not-found with the circled "!" in col 1. I would like to automatically delete all duplicates and then all marked as not found. How do I do this without losing my one good copy?
large number of duplicate listings of songs. 1 (or several) is found and then 1 or more not-found with the circled "!" in col 1. I would like to automatically delete all duplicates and then all marked as not found. How do I do this without losing my one good copy?
-
I was using my ipad and then it would not connect to a server. Then I closed it down and it welcomed me and the internet was working. The only thing I cannot do is get into my email. Any ideas?
Have you already set up your email account in Settings > Mail, Contacts, Calendars?
-
The mouse wont click anywhere over a 1" strip that includes the area where the tabs are lined, and extends 0.5cm above and below this. So, to open or close a tab I can only use Ctrl T or Ctrl W respectively. And, for ex, I cannot click on the top most line on Facebook (which has the Home, messages, news feeds options etc) or that of Twitter, and so on. I have used Mozilla Firefox all my life and this has never happened before. I don't have this problem with any other browser like Internet explorer or Google Chrome. I find it very strange.
Both the Yahoo! Toolbar extension and the Babylon extension have been reported to cause this issue. Disable or uninstall those add-ons.
* https://support.mozilla.com/kb/Troubleshooting+extensions+and+themes -
I have a laptop and desktop can I sync my itunes to a master libary on a nas or my airport extream? this would be similar to syncing my devices to my imac (iPad, iPhonce, ect.)
two answers as I am unshour to what you want to do:
Setup homeshareing or:
1) QUIT not just Close iTunes if it open
1) Make a folder on the shared disk
2) Move the "Users/username/Music/iTunes folder you want to share with all the devices to the folder on the shared disk
3) Make that folder accessable by all the users you want to access it.
4) Hold the "Option/alt" key down and click iTunes and it will ask if you want to "Choose a Library"
5) click "Choose a Library" and choose the one on the shared disk
6) Do this on evey meachine you want to have access to this library
8) REMBER THAT IF YOUR NOT CONNECTED TO YOUR SHARED DISK THEN YOU WILL NOT BE ABLE TO ACCESS YOUR LIBRARY but you can choose librays at any time by using step 4 and you can have as meany librarys as you like.
I hope this answers your question
Sorry for any bad spellings I am dyslex...... -
I am unable to open press enter in the address bar and have to click return with the mouse
So when i open a new session of firefox/new window/new tab and click to type in the address bar, firefox will not allow me to hit return/enter to load the page. I have to manually click on the return icon to get the page to load. I have tried using a different keyboard but this does not help. This only occurs within the address bar not within any other part of the page or within any other program. please help
the it was the avg safe search that was causing the issue. Thanks for the help.
-
IPhone 6 when held in landscape will not open text messages in landscape. Phone needs to be held upright and then back to landscape. The phone sits in landscape mode on a dock.
have the same issue even after upgrading to 8.1
-
How to edit images on local drive and then archive to external?
I have a Drobo that I use to archive my permanent lightroom archive and image files. Currently, everything lightroom resides on this external drive. But the Drobo is no where near as fast as my internal hard drive as far as read/write and seek speed. I was wondering if there is a fairly easy way for me to work with my most recent import of images off of my internal hard drive and then "move" the images to the drobo once my post-processing is complete. I'm thinking storing the catalog on my internal drive would make sense as well and then use lightroom's built in catalog backup feature to backup the catalog file to the external drive. Any suggestions for those of you out there using Drobos or other large external storage devices on some type of "best practice" would be great. I apologize if this has been covered elsewhere in the forum; I searched but I couldn't find anything.
bisabuelo wrote:
... I was wondering if there is a fairly easy way for me to work with my most recent import of images off of my internal hard drive and then "move" the images to the drobo once my post-processing is complete. ...
You can do exactly that, I do it all the times. Import your photos to an internal drive, work on them, and once you're done with the major work, move the photos or folder(s) from within LR to your drobo. LR will keep track of where your photos are if you move them from within LR.
I even sometimes move an image to a tomporary directory on a local drive from my NAS storage before opening it in PSE, since the building of a large TIFF takes forever on my NAS. I then move it back after finishing my work.
... I'm thinking storing the catalog on my internal drive would make sense as well and then use lightroom's built in catalog backup feature to backup the catalog file to the external drive. ...
I think that's a good way of handling it.
Please also be aware of the fact that the most important performance topics are access times to
Catalog
Previews
ACR cache (!!)
Access time to the raw file itself is actually not the most important issue.
Beat Gossweiler
Switzerland -
I put an object and/or a text box on a page and then cannot select it - the Text cursor (not pointer, just the text cursor shows) is put on the object or text box and nothing happens. It is so frustrating! I then open up Everweb and the same thing, I create an object and then try and elect it to make it bigger etc and cannot. I know it must be something system wide as it happens in apps other than Pages.
I put an object and/or a text box on a page and then cannot select it - the Text cursor (not pointer, just the text cursor shows) is put on the object or text box and nothing happens. It is so frustrating! I then open up Everweb and the same thing, I create an object and then try and elect it to make it bigger etc and cannot. I know it must be something system wide as it happens in apps other than Pages.
Maybe you are looking for
-
I basically want to buy an iphone as a gift, but i'm unsure if it will need extra unlocking in another country or will i be able to use it srtaight away if i have a sim card
-
Officejet 6310 and windows 8.1 rt
how do i get my hp officejet 6310 to connect wirelessly to my surface 2 running windows 8.1rt. right now it cant find the printer. before the last update it did.
-
Customer Field in Delivery Address(Reference data, item)tab under Ite in PO
Dear experts, While creating a PO in line item level, under the "Delivery Address" tab, we are able to see the Vendor option and the Address option for selecting the delivery address in the PO. We are unable to view the Customer Option even though we
-
How do I fix uncontrollable scrolling in Elements Organiser?
How do I fix uncontrollable scrolling through image thumbnails in Elements Organiser? The problem occurs whether I use the trackpad on my Macbook or the Magic Mouse. I have tried slowing the gesture speed to Zero in Settings. This has absolutely no e
-
Is Director's Lingo faster than Flash's Actionscript?
Back in 2001, Gary Rosenzweig published "Comparing Lingo and ActionScript" over at http://director-online.com/buildArticle.php?id=973 At the time Lingo was 45x faster for a script that finds all of the prime numbers between 1 and 1000. AS code and Li