shikas
java Toolkit
1 Answer(s)      3 years and 6 months ago
Posted in : Java Beginners

how to set jframe form screen size any resolutions fit to full screen?

Advertisement
View Answers

January 20, 2012 at 3:37 PM


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

class LoginDemo extends JFrame{

 JButton SUBMIT;
 JLabel label1,label2;
 final JTextField  text1,text2;
  LoginDemo(){
    setTitle("Login Form");
    setLayout(null);
    label1 = new JLabel();
    label1.setText("Username:");
    text1 = new JTextField(15);

    label2 = new JLabel();
    label2.setText("Password:");
    text2 = new JPasswordField(15);

    SUBMIT=new JButton("SUBMIT");
    label1.setBounds(350,100,100,20);
    text1.setBounds(450,100,200,20);
    label2.setBounds(350,130,100,20);
    text2.setBounds(450,130,200,20);
    SUBMIT.setBounds(450,160,100,20);
   add(label1);
   add(text1);
   add(label2);
   add(text2);
   add(SUBMIT);

   setVisible(true);
   setSize(1024,768);

   SUBMIT.addActionListener(new ActionListener(){
   public void actionPerformed(ActionEvent ae){

   }
 });
  }

  public static void main(String arg[]){
  new LoginDemo();
}
}









Related Tutorials/Questions & Answers:
java Toolkit
java Toolkit  how to set jframe form screen size any resolutions fit to full screen
Toolkit Class.......... - Java Beginners
Toolkit Class  Hi will you please tell me something about Toolkit class. What following code will give ToolKit kit=ToolKit.getDefaultToolKit(); Dimension dim=kit.getScreenSize(); & How JFileChosser is used Please
Advertisements
Java Wrieless Toolkit
Java Wrieless Toolkit  MY application code does not work on the Java Wireless Toolkit- import java.io.*; public Write{ public static void main(String[] args) throws IOException{ BufferedReader in = new BufferedReader(new
Sun Java Wireless Toolkit
Sun Java Wireless Toolkit       Java Platform, Micro Edition The Sun Java Wireless Toolkit is also known as Java Platform, Micro Edition (Java ME) Wireless Toolkit. Java
IT Mill Toolkit
IT Mill Toolkit       IT Mill Toolkit 5 is a server-side RIA framework that provides Java programmers with complete set of RIA widgets. Applications are programmed (with Java
Plex Toolkit
Plex Toolkit       The Plex Toolkit is a collection of JavaScript libraries which handle the transformation of custom XML markup embedded in an HTML document into user interface
What is the best in Ajax Toolkit?
What is the best in Ajax Toolkit?  What is the best in Ajax Toolkit? Is not Ajax toolkit similar to the Ajax control toolkit? Can you expand it? (Sr, I am not good at English
Google Web Toolkit
Google Web Toolkit       Google Web Toolkit (GWT) is a Java software development framework that makes... serializable Java classes for your request and response. In production, GWT
Dojo Toolkit
Dojo Toolkit       Dojo is the Open Source JavaScript toolkit that helps you build serious applications in less time. It fills in the gaps where JavaScript and browsers don't go quite
DHTMLX Toolkit
DHTMLX Toolkit       DHTMLX Ajax Toolkit combines the most widely-used types of UI components: grid, treegrid, treeview, combobox, tabbar, menu, toolbar. All components are written
HP OCMP vXML developer toolkit
HP OCMP vXML developer toolkit       The HP OpenCall Voice Application Developer Toolkit... OpenCall Voice Application Developer Toolkit, you can: * Create VoiceXML
Cross-platform programming with Java technology and the IBM Web Services Toolkit for Mobile Devices
Cross-platform programming with Java technology and the IBM Web Services Toolkit for Mobile Devices         When you?re writing a Java application
What is AWT in java
What is AWT in java In this Example we will describe awt in java. The awt in java stands for Abstract Windowing Toolkit and is a package... in java full tutorials We have described Interface and Description of AWT Package
Java Swing
Java Swing       Swing works as a widget toolkit for Java and is a part of JFC and are replacement... interface (GUI) components for Java programs. Swings are lightweight and 100
WAP Toolkits Motorola - Mobile ADK 1.1 Nokia - WAP Toolkit
ColdJava Java components with WAP/WML... Enhydra - Java/XML server 3.0... JAWAP (Java framework) 1.3.1B1
New Releases
;   Sun?s released the Java Wireless Toolkit 2.5.2 Sun has released the Java Wireless Toolkit 2.5.2. The Toolkit includes build tools, utilities..., extensible framework for creating enterprise Java web applications
SWTCalendar
SWTCalendar         SWTCalendar is a port of Kai Toedter's JCalendar to Eclipse's SWT. It is a GUI date picker for Java using SWT as the GUI toolkit. SWTCalendar
Graphical User Interfaces
; A class library is provided by the Java programming language which is known as Abstract Window Toolkit (AWT). The Abstract Window Toolkit... to the display area with a layout manager. As the Java programming language, the AWT
AonixADT Ada Development Toolkit
AonixADT Ada Development Toolkit       Combine User-Friendliness and Productivity Eclipse offers a common platform for which many companies have developed plug-ins
AWT basics
for abstract window toolkit, which is used to develop platform-independent windowing, graphics, and user-interface for the desktop application using Java technology
java
java  java swing   Swing is a principal GUI toolkit for the Java programming language. It is a part of the JFC (Java Foundation Classes), which is an API for providing a graphical user interface for Java programs
j2s
j2s       Java2Script (J2S) Pacemaker provides an Eclipse Java to JavaScript/HTML/CSS compiler plugin and an implementation of JavaScript version of Eclipse Standard Widget Toolkit (SWT
Image Size
; This Java awt (Abstract Windowing Toolkit) tutorial describes about the image size... of image. You will try and get it. Description of code: Toolkit(): This is the constructor of Toolkit class that is the abstract super class of all exact
java swing
java swing  what is java swing   Swing is a principal GUI toolkit for the Java programming language. It is a part of the JFC (Java Foundation Classes), which is an API for providing a graphical user interface for Java
Creating List in Java using SWT
Creating List in Java using SWT   ... of certain items using the Standard Widget Toolkit In this example, we have create a list... org.eclipse.swt.widgets to create the list in Java language. The style SWT.MULTI provided
Java-Swings - Java Beginners
Java-Swings  How to set the size of a JButton,JLabel depending...*; public class ButtonSizeDemo extends JFrame { private Toolkit toolkit..."); setSize(300, 200); toolkit = getToolkit
HiberObjects
and unit tests for Java Persistence API (JPA) or Hibernate. PropertyChange support and DTO's for Google Web Toolkit (GWT) can also be generated. HiberObjects... to generate Java classes and Hibernate mapping files (depending on the selected
Java2Script (J2S) Pacemaker
an Eclipse Java to JavaScript compiler plugin and an implementation of JavaScript version of Eclipse Standard Widget Toolkit (SWT) with other common utilities... learning. All you have to do is to develop your Java applications in Eclipse
Eclipse Plunging/Web
the Google Web Toolkit (GWT). With GWT Designer, you can use the visual designer and Java code will be generated for you. You can easily add controls using... The Struts Console is a FREE standalone Java Swing application (or IDE
java
).The Abstract Window Toolkit supports GUI Java programming. It is a portable... Toolkit provides the connection between your application and the native GUI. The AWT provides a high level of abstraction for your Java program since it hides you