Sunday, November 29, 2009

Lagu keren

Hey hey anoko wa ima ichi
Ne ne atarashii ko ga hitsuyou
Hey hey atashi nante iinjyanai

Hey hey atashi ni wa wakatteru
No way no way himitsujyanai
Hey hey atashi ga natteageru

You're so fine I want you mine you're so delicious
I think about you all the time you're so addictive
Don't you know what I can do to make you feel alright (Alright...)

Don't pretend I think you know I'm damn precious
And hell yeah, I'm the mother fucking princess
I can tell you like me too and you know I'm right (I'm right...)

She's like so whatever
You could do so much better
I think we should get together now
And that's what everyone's talking about

hey hey anoko wa ima ichi
ne ne atarashii ko ga hitsuyou
hey hey atashi nante iinjyanai

hey hey atashi ni wa wakatteru
no way no way himitsujyanai
hey hey atashi ga natteageru

I can see the way, I see the way you look at me
And even when you look away I know you think of me
I know you talk about me all the time again and again (Again and again...)

So come over here and tell me what I wanna hear
Better, yet, make your girlfriend disappear
I don't wanna hear you say her name ever again (And again...)

Because...

She's like so whatever
And she could do so much better
I think we should get together now
And that's what everyone's talking about

hey hey anoko wa ima ichi
ne ne atarashii ko ga hitsuyou
hey hey atashi nante iinjyanai

hey hey atashi ni wa wakatteru
no way no way himitsujyanai
hey hey atashi ga natteageru

(Uh)
In a second you'll be wrapped around my finger
'Cause I can, 'cause I can do it better
There's no other, so when's it gonna sink in
She's so stupid, what the hell were you thinking?

(Uh)
In a second you'll be wrapped around my finger
'Cause I can, 'cause I can do it better
There's no other, so when's it gonna sink in
She's so stupid, what the hell were you thinking?

hey hey anoko wa ima ichi
ne ne atarashii ko ga hitsuyou
hey hey atashi nante iinjyanai

hey hey atashi ni wa wakatteru
no way no way himitsujyanai
hey hey atashi ga natteageru

hey hey anoko wa ima ichi
ne ne atarashii ko ga hitsuyou
hey hey atashi nante iinjyanai

hey hey atashi ni wa wakatteru
no way no way himitsujyanai
hey hey atashi ga natteageru

Hey, hey! Selengkapnya...

Modul III
package dwi;
public class BuatFrame extends javax.swing.JFrame {
public BuatFrame() {
initComponents();
}
@SuppressWarnings("unchecked")
//
private void initComponents() {
jButton1 = new javax.swing.JButton();
jButton2 = new javax.swing.JButton();
jButton3 = new javax.swing.JButton();
jButton4 = new javax.swing.JButton();
setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE);
jButton1.setText("jButton1");
jButton1.setHorizontalAlignment(javax.swing.SwingConstants.RIGHT);
jButton2.setText("jButton2");
jButton3.setText("jButton3");
jButton4.setText("jButton4");
javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());
getContentPane().setLayout(layout);
layout.setHorizontalGroup(
layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
.addGroup(layout.createSequentialGroup()
.addContainerGap()
.addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
.addGroup(layout.createSequentialGroup()
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
.addComponent(jButton1)
.addGap(18, 18, 18)
.addComponent(jButton2)
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
.addComponent(jButton3))
.addComponent(jButton4))
.addContainerGap(141, Short.MAX_VALUE))
);
layout.setVerticalGroup(
layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
.addGroup(layout.createSequentialGroup()
.addContainerGap()
.addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
.addComponent(jButton2)
.addComponent(jButton3)
.addComponent(jButton1))
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
.addComponent(jButton4)
.addContainerGap(237, Short.MAX_VALUE))
);

pack();

//
public static void main(String args[]) {
java.awt.EventQueue.invokeLater(new Runnable() {

public void run() {
new BuatFrame().setVisible(true);
}
});
}

// Variables declaration - do not modify
private javax.swing.JButton jButton1;
private javax.swing.JButton jButton2;
private javax.swing.JButton jButton3;
private javax.swing.JButton jButton4;
// End of variables declaration
}



Penjelasan
Program diatas di buat menggunakan frame yang sudah ada dalam netbeans kita tinggal masukkan frame yang sudah disediakan, disini kita tidak ribet-ribet lagi untuk menulis program satu persatu kita tinggal memasukkan button yang suadah ada.

package dwi;

import java.awt.*;
import javax.swing.*;

class BLayout extends JFrame{
JButton tombolSave, tombolEdit, tombolDelete, tombolOpen;
JLabel labelGambar;

public BLayout() {
setTitle("Border Layout");
tombolOpen = new JButton("Open");
tombolOpen.setMnemonic('O');
tombolSave = new JButton("Save");
tombolSave.setMnemonic('S');
tombolEdit = new JButton("Edit");
tombolEdit.setMnemonic('E');
tombolDelete = new JButton("Delate");
tombolDelete.setMnemonic('D');
labelGambar = new JLabel
(new ImageIcon("Image/Garong.jpg"));
setLayout(new BorderLayout());
add(tombolOpen,"North");
add(tombolSave,"West");
add(labelGambar,"Center");
add(tombolEdit,"East");
add(tombolDelete,"South");
pack();
setVisible(true);
setDefaultCloseOperation(EXIT_ON_CLOSE);
}
}
public class CobaBorderLayout {
public static void main(String[] args) {
BLayout b =new BLayout();
}
}


package dwi;
import dwi.*;
import java.awt.*;
import javax.swing.*;

class FLayout extends JFrame{
JButton tombolSave, tombolEdit, tombolDelete, tombolOpen;

public FLayout() {
setTitle("Flow Layout");
tombolOpen = new JButton("Open");
tombolOpen.setMnemonic('O');
tombolSave = new JButton("Save");
tombolSave.setMnemonic('S');
tombolEdit = new JButton("Edit");
tombolEdit.setMnemonic('E');
tombolDelete = new JButton("Delate");
tombolDelete.setMnemonic('D');

setLayout(new FlowLayout());
add(tombolOpen);
add(tombolSave);
add(tombolEdit);
add(tombolDelete);

pack();
setVisible(true);
setDefaultCloseOperation(EXIT_ON_CLOSE);
}
}

public class CobaFlowLayout {
public static void main(String[] args) {
FLayout f= new FLayout();
}
}



package dwi;
import dwi.*;
import java.awt.*;
import javax.swing.*;

class GLayout extends JFrame{
JButton tombolSave, tombolEdit, tombolDelete, tombolOpen;

public GLayout() {
setTitle("Grid Layout");
tombolOpen = new JButton("Open");
tombolOpen.setMnemonic('O');
tombolSave = new JButton("Save");
tombolSave.setMnemonic('S');
tombolEdit = new JButton("Edit");
tombolEdit.setMnemonic('E');
tombolDelete = new JButton("Delate");
tombolDelete.setMnemonic('D');

setLayout(new GridLayout(2,2));
add(tombolOpen);
add(tombolSave);
add(tombolEdit);
add(tombolDelete);

pack();
setVisible(true);
setDefaultCloseOperation(EXIT_ON_CLOSE);
}
}

public class CobaGridLayout {
public static void main(String[] args) {
GLayout g= new GLayout();
}
}




package dwi;
import dwi.*;
import javax.swing.*;

class NLayout extends JFrame{
JButton tombolSave, tombolEdit, tombolDelete, tombolOpen;

public NLayout() {
setTitle("Flow Layout");
tombolOpen = new JButton("Open");
tombolOpen.setMnemonic('O');
tombolSave = new JButton("Save");
tombolSave.setMnemonic('S');
tombolEdit = new JButton("Edit");
tombolEdit.setMnemonic('E');
tombolDelete = new JButton("Delate");
tombolDelete.setMnemonic('D');

setLayout(null);
add(tombolOpen);
add(tombolSave);
add(tombolEdit);
add(tombolDelete);

tombolOpen.setBounds(10, 10, 150, 20);
tombolSave.setBounds(150, 15, 150, 20);
tombolEdit.setBounds(100, 30, 150, 20);
tombolDelete.setBounds(40, 50, 150, 20);

setSize(350,200);
setVisible(true);
setDefaultCloseOperation(EXIT_ON_CLOSE);
}
}

public class CobaNullLayout {
public static void main(String[] args) {
NLayout n= new NLayout();
}

}





/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/

package dwi;

/**
*
* @author mulmed
*/
import java.awt.*;
import javax.swing.*;
import javax.swing.JPanel.*;




class BLayout extends JFrame{
JButton tombolSave, tombolEdit, tombolDelete, tombolOpen;
JLabel labelGambar;
JButton xSave, xEdit, xDelete, xOpen;
JPanel p1,p2;

public BLayout() {
setTitle("Border Layout");
tombolOpen = new JButton("B1");
tombolOpen.setMnemonic('1');
tombolSave = new JButton("B2");
tombolSave.setMnemonic('2');
tombolEdit = new JButton("B3");
tombolEdit.setMnemonic('3');
tombolDelete = new JButton("B4");
tombolDelete.setMnemonic('4');
labelGambar = new JLabel
(new ImageIcon("Image/Garong.jpg"));


xOpen = new JButton("B5");
xOpen.setMnemonic('5');
xSave = new JButton("B6");
xSave.setMnemonic('6');
xEdit = new JButton("B7");
xEdit.setMnemonic('7');
xDelete = new JButton("B8");
xDelete.setMnemonic('8');
p1 = new JPanel();
p2 = new JPanel();

this.setLayout(new GridLayout(1,2));
add(p1);
add(p2);
p1.setLayout(new BorderLayout());
p1.add(tombolOpen,"North");
p1.add(tombolSave,"West");
p1.add(labelGambar,"Center");
p1.add(tombolEdit,"East");
p1.add(tombolDelete,"South");

p2.setLayout(new GridLayout(2,2));
p2.add(xOpen);
p2.add(xSave);
p2.add(xEdit);
p2.add(xDelete);


pack();
setSize(500,300);
setVisible(true);
setDefaultCloseOperation(EXIT_ON_CLOSE);
}


}
public class coba {
public static void main(String[] args) {
BLayout b =new BLayout();

}
}

Selengkapnya...

BLOGGER © 2009. Design by :Two_susant Sponsored by: Tutorial87 Commentcute