hobbit Posted May 19, 2010 Posted May 19, 2010 Well, it's time for my final project and was wondering how to do a few things to add onto this existing code for an IM (instant messenger). I want to add the following things: 1.Ppl's names to the chat window once ppl send a msg 2. A panel which lets users select background color. 3. A panel which changes font. I know most of this will be kinda easy, but atm having a brain fart. If you do help plz leave hints on how to reach the desired effect and not the code needed. I want to learn a bit Anyway, if someone could leave me some help by Friday would be great Code which i already have is attached. IMcode.zip Quote
Duckie Posted May 19, 2010 Posted May 19, 2010 I didn't really run this... just read the code But the line: msgInABottle = new DataPacket(username.getText(), sendArea.getText(), target); Might change to: msgInABottle = new DataPacket(username + ": " + username.getText(), sendArea.getText(), target); to add the username... import the files into netbeans and it should be really easy to create a UI that allows you to change the background color.. Quote
Saizou Posted May 19, 2010 Posted May 19, 2010 I have some experience with Java, so there's probably better and far more elegant way than this: 1. really no idea, only started to learn about communication between programs 2. you can launch new frame with a single image in it which is divided into smaller parts with separate colors so clicking a certain area sets the certain background color (of all elements or the ones you want change) 3. launch new frame with buttons each representing a font (the text on the button has the font that it sets), basically you'd need to rewrite all the text on GUI each time you select it. Some of the ideas that one can come up at 2 AM. Hope it helps a bit. I'm also curious what IDE are you using? Quote
hobbit Posted May 21, 2010 Author Posted May 21, 2010 Thanks for your helpz, i figured out a few handy things @Saizou- I'm using BlueJ for now, since thats what my teacher has told me would work best for 'beginners' lol Quote
Saizou Posted May 23, 2010 Posted May 23, 2010 Our teacher told us to use Eclipse, though he showed us how to compile through command prompt and even how to compile using Ant, but his course soon turns from a beginners course to an advanced course. Quote
Duckie Posted May 24, 2010 Posted May 24, 2010 eclipse is nice, I use it at work. however if you're editing a gui... netbeans has tools built right in so you can drag and drop panels around as you wish... then it generates the code for you on the fly =] Quote
tdkxeon Posted August 25, 2010 Posted August 25, 2010 eclipse is nice, I use it at work. however if you're editing a gui... netbeans has tools built right in so you can drag and drop panels around as you wish... then it generates the code for you on the fly =] not completely true my guess is you are using the free verison of eclipse !! i use Myeclipse and this version is not free but it is awesome http://www.myeclipseide.com/ myeclipse has way better functionality if you are building gui it has drag and drop functionality too Quote
Krauersaut Posted August 25, 2010 Posted August 25, 2010 I'm pretty sure he uses eclipse, which is free and open source software, and not MyEclipse, which describes itself as "Eclipse plugin developement tools". Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.