{"id":10214,"date":"2015-08-25T00:00:02","date_gmt":"2015-08-25T04:00:02","guid":{"rendered":"http:\/\/bangla.salearningschool.com\/?p=10214"},"modified":"2015-08-24T08:42:05","modified_gmt":"2015-08-24T12:42:05","slug":"basic-swing-details","status":"publish","type":"post","link":"http:\/\/bangla.sitestree.com\/?p=10214","title":{"rendered":"Basic Swing Details"},"content":{"rendered":"<ul>\n<li style=\"text-align: justify;\">WindowUtilities.java Utility class that simplifies creating a window and setting the look and feel.<\/li>\n<li style=\"text-align: justify;\">ExitListener.java A WindowListener with support to close the window.<\/li>\n<li style=\"text-align: justify;\">JAppletExample.java A simple applet (JApplet) created in Swing. Illustrates setting the look and feel, adding components to the content pane, and changing the layout to FlowLayout (default is BorderLayout). See JAppletExample.html (requires the Java Plug-In or a Java 2 compliant browser, for example, Netscape 6.x).<\/li>\n<li style=\"text-align: justify;\">JFrameExample.java Demonstrates creating a simple Swing application using a JFrame. As with a JApplet, components must be added to the content pane, instead of the window directly.<\/li>\n<li style=\"text-align: justify;\">JLabels.java Illustrates creating labels in Swing. A nice feature of JLabels is that the label text can contain HTML markup. Uses image JHUAPL.gif<\/li>\n<li style=\"text-align: justify;\">JButtons.java Creates various buttons. In Swing, buttons can contain text only, an image only, or a combination of both an image and a label. Uses image cup.gif.<\/li>\n<li style=\"text-align: justify;\">JPanels.java A simple example that illustrates creating panels. In Swing, a JPanel can contain custom borders. Typically, utility methods in the BorderFactory class are used to create a border for the panel. Uses the following class:<br \/>\no SixChoicePanel.java A JPanel that displays six radio buttons with labels.<\/li>\n<li style=\"text-align: justify;\">JSliders.java Creates three common types of sliders: one without tick marks, one with tick marks, and one with both tick marks and labels.<\/li>\n<li style=\"text-align: justify;\">JColorChooserTest.java Demonstrates the use of a JColorChooser which presents a dialog with three different tabbed panes to allow the user to select a color preference. The dialog returns a Color object based on the user&#8217;s selection or null if the user entered Cancel.<\/li>\n<li style=\"text-align: justify;\">JInternalFrames.java Illustrates the ability to create a Multiple Document Interface (MDI) application by placing internal frames (JInternalFrame) in a desktop pane (JDesktopPane).<\/li>\n<li style=\"text-align: justify;\">JToolBarExample.java Small example showing the basic use of a JToolBar. Uses the following classes and images:<br \/>\no ToolBarButton.java A simple button that contains an image and a label for use in a toolbar.<br \/>\no BrowserToolBar.java A basic tool bar for holding multiple buttons.<br \/>\no Images used in the toolbar buttons: Help.gif, Home.gif, Left.gif, Print.gif, Right.gif, RotCCUp.gif, TrafficRed.gif.<\/li>\n<li style=\"text-align: justify;\">Browser.java Implementation of a simple browser in Swing. The user can specify a URL to load into the browser (JEditorPane). By attaching an HyperlinkListener, the editor pane is responsive to hyperlinks selected by the user. Uses the following class and image:<br \/>\no JIconButton.java A simple button that the user can select to load the entered URL.<br \/>\no home.gif Image used in the button.<\/li>\n<li style=\"text-align: justify;\">JCheckBoxTest.java Simple example illustrating the use of check boxes.<\/li>\n<li style=\"text-align: justify;\">JRadioButtonTest.java Creates three radio buttons and illustrates handling ItemEvents in response to selecting a radio button.<\/li>\n<li style=\"text-align: justify;\">JOptionPaneExamples.java Creates various modal dialogs to show messages. Uses the follwoing classes:<br \/>\no JLabeledTextField.java A simple JPanel that combines a JLabel and a JTextField.<br \/>\no RadioButtonPanel.java Groups several radio buttons in a single row, with a label on the left.<br \/>\no DisableListener.java A listener that toggles the enabled status of some other component.<\/li>\n<\/ul>\n","protected":false},"excerpt":{"rendered":"<p>WindowUtilities.java Utility class that simplifies creating a window and setting the look and feel. ExitListener.java A WindowListener with support to close the window. JAppletExample.java A simple applet (JApplet) created in Swing. Illustrates setting the look and feel, adding components to the content pane, and changing the layout to FlowLayout (default is BorderLayout). See JAppletExample.html (requires &hellip; <\/p>\n<p><a class=\"more-link btn\" href=\"http:\/\/bangla.sitestree.com\/?p=10214\">Continue reading<\/a><\/p>\n","protected":false},"author":130,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_jetpack_memberships_contains_paid_content":false,"footnotes":""},"categories":[1417,1424],"tags":[706,308,285],"class_list":["post-10214","post","type-post","status-publish","format-standard","hentry","category-code-programming-samples--","category-javaj2eej2me","tag-code","tag-java","tag-285","item-wrap"],"jetpack_featured_media_url":"","jetpack_sharing_enabled":true,"jetpack-related-posts":[{"id":26896,"url":"http:\/\/bangla.sitestree.com\/?p=26896","url_meta":{"origin":10214,"position":0},"title":"Basic Swing Details #Programming Code Examples #Java\/J2EE\/J2ME #Basic Swing","author":"Author-Check- Article-or-Video","date":"May 4, 2021","format":false,"excerpt":"* WindowUtilities.java Utility class that simplifies creating a window and setting the look and feel. * ExitListener.java A WindowListener with support to close the window. * JAppletExample.java A simple applet (JApplet) created in Swing. Illustrates setting the look and feel, adding components to the content pane, and changing the layout\u2026","rel":"","context":"In &quot;FromSitesTree.com&quot;","block_context":{"text":"FromSitesTree.com","link":"http:\/\/bangla.sitestree.com\/?cat=1917"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]},{"id":10275,"url":"http:\/\/bangla.sitestree.com\/?p=10275","url_meta":{"origin":10214,"position":1},"title":"creating a simple Swing application using a JFrame","author":"","date":"August 26, 2015","format":false,"excerpt":"JFrameExample.java Demonstrates creating a simple Swing application using a JFrame. As with a JApplet, components must be added to the content pane, instead of the window directly.import java.awt.*; import javax.swing.*; \/** Tiny example showing the main difference in using \u00a0*\u00a0 JFrame instead of Frame: using the content pane \u00a0*\u00a0 and\u2026","rel":"","context":"In &quot;Code . Programming Samples . \u09aa\u09cd\u09b0\u09cb\u0997\u09cd\u09b0\u09be\u09ae \u0989\u09a6\u09be\u09b9\u09b0\u09a8&quot;","block_context":{"text":"Code . Programming Samples . \u09aa\u09cd\u09b0\u09cb\u0997\u09cd\u09b0\u09be\u09ae \u0989\u09a6\u09be\u09b9\u09b0\u09a8","link":"http:\/\/bangla.sitestree.com\/?cat=1417"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]},{"id":27211,"url":"http:\/\/bangla.sitestree.com\/?p=27211","url_meta":{"origin":10214,"position":2},"title":"creating a simple Swing application using a JFrame #Programming Code Examples #Java\/J2EE\/J2ME #Advanced Swing","author":"Author-Check- Article-or-Video","date":"May 14, 2021","format":false,"excerpt":"JFrameExample.java Demonstrates creating a simple Swing application using a JFrame. As with a JApplet, components must be added to the content pane, instead of the window directly.import java.awt.*; import javax.swing.*; \/** Tiny example showing the main difference in using * JFrame instead of Frame: using the content pane * and\u2026","rel":"","context":"In &quot;FromSitesTree.com&quot;","block_context":{"text":"FromSitesTree.com","link":"http:\/\/bangla.sitestree.com\/?cat=1917"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]},{"id":10273,"url":"http:\/\/bangla.sitestree.com\/?p=10273","url_meta":{"origin":10214,"position":3},"title":"A simple applet (JApplet) created in Swing.","author":"","date":"August 26, 2015","format":false,"excerpt":"import java.awt.*; import javax.swing.*; \/** Tiny example showing the main differences in using \u00a0*\u00a0 JApplet instead of Applet: using the content pane, \u00a0*\u00a0 getting Java (Metal) look and feel by default, and \u00a0*\u00a0 having BorderLayout be the default instead of FlowLayout. \u00a0* \u00a0 *\/ \u00a0 public class JAppletExample extends JApplet\u2026","rel":"","context":"In &quot;Code . Programming Samples . \u09aa\u09cd\u09b0\u09cb\u0997\u09cd\u09b0\u09be\u09ae \u0989\u09a6\u09be\u09b9\u09b0\u09a8&quot;","block_context":{"text":"Code . Programming Samples . \u09aa\u09cd\u09b0\u09cb\u0997\u09cd\u09b0\u09be\u09ae \u0989\u09a6\u09be\u09b9\u09b0\u09a8","link":"http:\/\/bangla.sitestree.com\/?cat=1417"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]},{"id":27209,"url":"http:\/\/bangla.sitestree.com\/?p=27209","url_meta":{"origin":10214,"position":4},"title":"A simple applet (JApplet) created in Swing. #Programming Code Examples #Java\/J2EE\/J2ME #Advanced Swing","author":"Author-Check- Article-or-Video","date":"May 14, 2021","format":false,"excerpt":"import java.awt.*; import javax.swing.*; \/** Tiny example showing the main differences in using * JApplet instead of Applet: using the content pane, * getting Java (Metal) look and feel by default, and * having BorderLayout be the default instead of FlowLayout. * *\/ public class JAppletExample extends JApplet { public\u2026","rel":"","context":"In &quot;FromSitesTree.com&quot;","block_context":{"text":"FromSitesTree.com","link":"http:\/\/bangla.sitestree.com\/?cat=1917"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]},{"id":10146,"url":"http:\/\/bangla.sitestree.com\/?p=10146","url_meta":{"origin":10214,"position":5},"title":"PluginApplet.jsp Page that demonstrates the use of jsp:plugin.","author":"","date":"August 12, 2015","format":false,"excerpt":"PluginApplet.jsp\u00a0 Page that demonstrates the use of jsp:plugin. Requires you to compile and install PluginApplet.java, TextPanel.java, DrawingPanel.java, and WindowUtilities.java\u00a0 Since these are classes sent to the client to used by applets, the .class files should be in the same directory as the JSP page, not in the WEB-INF\/classes directory where\u2026","rel":"","context":"In &quot;Code . Programming Samples . \u09aa\u09cd\u09b0\u09cb\u0997\u09cd\u09b0\u09be\u09ae \u0989\u09a6\u09be\u09b9\u09b0\u09a8&quot;","block_context":{"text":"Code . Programming Samples . \u09aa\u09cd\u09b0\u09cb\u0997\u09cd\u09b0\u09be\u09ae \u0989\u09a6\u09be\u09b9\u09b0\u09a8","link":"http:\/\/bangla.sitestree.com\/?cat=1417"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]}],"_links":{"self":[{"href":"http:\/\/bangla.sitestree.com\/index.php?rest_route=\/wp\/v2\/posts\/10214","targetHints":{"allow":["GET"]}}],"collection":[{"href":"http:\/\/bangla.sitestree.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/bangla.sitestree.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/bangla.sitestree.com\/index.php?rest_route=\/wp\/v2\/users\/130"}],"replies":[{"embeddable":true,"href":"http:\/\/bangla.sitestree.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=10214"}],"version-history":[{"count":3,"href":"http:\/\/bangla.sitestree.com\/index.php?rest_route=\/wp\/v2\/posts\/10214\/revisions"}],"predecessor-version":[{"id":10217,"href":"http:\/\/bangla.sitestree.com\/index.php?rest_route=\/wp\/v2\/posts\/10214\/revisions\/10217"}],"wp:attachment":[{"href":"http:\/\/bangla.sitestree.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=10214"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/bangla.sitestree.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=10214"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/bangla.sitestree.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=10214"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}