2013 time just looked at the East Teacher's Dark Horse programmer tutorial, swing has a very strong interest, a lot of friends should and I have the same feeling it! have been learning for so long Java has been facing the black paint of the DOS window, finally can make a window, in the heart good happy. Like seeing the light. Remember the first time to write a program pops up a frame when the heart is really very excited. Then I spent a lot of time in swing studying, after all, without a teacher's guidance so I didn't know that swing was really worth the time. It's good to be aware of swing. It's good to have free time to see it.
But while swing delayed a lot of time, but also did something to play.
Wrote a simple version of LAN chat software
Login interface
Chat Features
font settings (the logo itself with PS painting at that time feel pretty good. Now feel hey. Still too young.)
Of course also realized the change of skin, switch Java style and Windows style, as well as the message flashing prompt system tray menu
history function. Just at the beginning of the more naïve write no database can add friends or something, only 2 people play
play. But there are plenty of places to learn (if you're interested in swing), such as dealing with a jpanel with a picture background, how to do this without overwriting the component, and doing it more mature in the program. There is also the use of swing components and layout aspects.
It's kinda fun, but it's not much to use now.
I want to highlight is this couple piano!
After you connect with each other, you can invite each other to listen to your play, you think one day you call your girlfriend to play this and give her a song "Fairy tale", is not great!
Forgive me programmer dick Silk's sentiment.
This piano has 3 mode, you can play it yourself, you play him, you play together. Of course, the results you played together are certainly not very good (very noisy!) )。
The idea is this:
Collection of piano 1234567 Low, Medium, high, ultra-high audio made into 28 MP3 files
Listen to the keyboard 26 letters corresponding to 1234567 from low to high 26 notes, which one to play which
Memory Overflow is very easy here, so when playing the next audio, be sure to destroy the previous
at the other end of the program, a thread listens to the agreed port, and the note is played. This will enable the transmission of the notes!
Resource code all passed in the "easy to communicate the source jar package" Resources are interested in you can search OH.
If the great God read the code willing to guide the course I am very happy, but also I write blog power.
but the code was written 2 years ago and there should be a lot of violent places to deal with.
Copyright NOTICE: This article for Bo Master original article, without Bo Master permission not reproduced.
Java Swing LAN chat software + couple computer piano