{"id":10308,"date":"2015-08-26T07:21:29","date_gmt":"2015-08-26T11:21:29","guid":{"rendered":"http:\/\/bangla.salearningschool.com\/?p=10308"},"modified":"2015-08-24T08:57:56","modified_gmt":"2015-08-24T12:57:56","slug":"message-java-applet-that-reads-customization-parameters-from-an-html-file","status":"publish","type":"post","link":"http:\/\/bangla.sitestree.com\/?p=10308","title":{"rendered":"Message.java Applet that reads customization parameters from an HTML file"},"content":{"rendered":"<pre>*******************\r\nMessage.java Applet that reads customization parameters from an HTML file\r\n*******************\r\nimport java.applet.Applet;\r\nimport java.awt.*;\r\n\r\n****************\r\n\u00a0\r\npublic class Message extends Applet {\r\n\u00a0 private int fontSize;\r\n\u00a0 private String message;\r\n\u00a0 \r\n\u00a0 public void init() {\r\n\u00a0\u00a0\u00a0 setBackground(Color.black);\r\n\u00a0\u00a0\u00a0 setForeground(Color.white);\r\n\u00a0\u00a0 \u00a0\r\n\u00a0\u00a0\u00a0 \/\/ Base font size on window height.\r\n\u00a0\u00a0\u00a0 fontSize = getSize().height - 10;\r\n\u00a0\u00a0 \u00a0\r\n\u00a0\u00a0\u00a0 setFont(new Font(\"SansSerif\", Font.BOLD, fontSize));\r\n\r\n\u00a0\u00a0\u00a0 \/\/ Read heading message from PARAM entry in HTML.\r\n\u00a0\u00a0\u00a0 message = getParameter(\"MESSAGE\");\r\n\u00a0 }\r\n\r\n\u00a0 public void paint(Graphics g) {\r\n\u00a0\u00a0\u00a0 if (message != null) {\r\n\u00a0\u00a0\u00a0\u00a0\u00a0 g.drawString(message, 5, fontSize+5);\r\n\u00a0\u00a0\u00a0 }\r\n\u00a0 }\r\n}\r\n*******************<\/pre>\n","protected":false},"excerpt":{"rendered":"<p>******************* Message.java Applet that reads customization parameters from an HTML file ******************* import java.applet.Applet; import java.awt.*; **************** \u00a0 public class Message extends Applet { \u00a0 private int fontSize; \u00a0 private String message; \u00a0 \u00a0 public void init() { \u00a0\u00a0\u00a0 setBackground(Color.black); \u00a0\u00a0\u00a0 setForeground(Color.white); \u00a0\u00a0 \u00a0 \u00a0\u00a0\u00a0 \/\/ Base font size on window height. \u00a0\u00a0\u00a0 fontSize = &hellip; <\/p>\n<p><a class=\"more-link btn\" href=\"http:\/\/bangla.sitestree.com\/?p=10308\">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,1425],"tags":[706,308,285],"class_list":["post-10308","post","type-post","status-publish","format-standard","hentry","category-code-programming-samples--","category-javascript","tag-code","tag-java","tag-285","item-wrap"],"jetpack_featured_media_url":"","jetpack_sharing_enabled":true,"jetpack-related-posts":[{"id":27249,"url":"http:\/\/bangla.sitestree.com\/?p=27249","url_meta":{"origin":10308,"position":0},"title":"Message.java Applet that reads customization parameters from an HTML file #Programming Code Examples #Java\/J2EE\/J2ME #Advanced Swing","author":"Author-Check- Article-or-Video","date":"May 15, 2021","format":false,"excerpt":"******************* Message.java Applet that reads customization parameters from an HTML file ******************* import java.applet.Applet; import java.awt.*; **************** public class Message extends Applet { private int fontSize; private String message; public void init() { setBackground(Color.black); setForeground(Color.white); \/\/ Base font size on window height. fontSize = getSize().height - 10; setFont(new Font(\"SansSerif\", Font.BOLD,\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":10526,"url":"http:\/\/bangla.sitestree.com\/?p=10526","url_meta":{"origin":10308,"position":1},"title":"HelloWWW.java Basic Hello World (Wide Web) Applet","author":"","date":"August 29, 2015","format":false,"excerpt":"********************* import java.applet.Applet; import java.awt.*; ********************* \u00a0 public class HelloWWW extends Applet { \u00a0 private int fontSize = 40; \u00a0 \u00a0 public void init() { \u00a0\u00a0\u00a0 setBackground(Color.black); \u00a0\u00a0\u00a0 setForeground(Color.white); \u00a0\u00a0\u00a0 setFont(new Font(\"SansSerif\", Font.BOLD, fontSize)); \u00a0 } \u00a0 \u00a0 public void paint(Graphics g) { \u00a0\u00a0\u00a0 g.drawString(\"Hello, World Wide Web.\", 5, fontSize+5);\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":26990,"url":"http:\/\/bangla.sitestree.com\/?p=26990","url_meta":{"origin":10308,"position":2},"title":"HelloWWW.java Basic Hello World (Wide Web) Applet #Programming Code Examples #Java\/J2EE\/J2ME #Basic Java","author":"Author-Check- Article-or-Video","date":"May 7, 2021","format":false,"excerpt":"********************* import java.applet.Applet; import java.awt.*; ********************* public class HelloWWW extends Applet { private int fontSize = 40; public void init() { setBackground(Color.black); setForeground(Color.white); setFont(new Font(\"SansSerif\", Font.BOLD, fontSize)); } public void paint(Graphics g) { g.drawString(\"Hello, World Wide Web.\", 5, fontSize+5); } } < <<<<<<<<<<<<<<<<<<<< Note: Brought from our old site: http:\/\/www.salearningschool.com\/example_codes\/\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":10460,"url":"http:\/\/bangla.sitestree.com\/?p=10460","url_meta":{"origin":10308,"position":3},"title":"HeadingExample.jsp Page that uses the HeadingTag custom tag","author":"","date":"August 28, 2015","format":false,"excerpt":"HeadingExample.jsp Page that uses the HeadingTag custom tag <!DOCTYPE HTML PUBLIC \"-\/\/W3C\/\/DTD HTML 4.0 Transitional\/\/EN\"> <!-- Illustration of HeadingTag tag. Taken from Core Web Programming Java 2 Edition from Prentice Hall and Sun Microsystems Press, . May be freely used or adapted. --> <HTML> <HEAD> <TITLE>Some Tag-Generated Headings<\/TITLE> <\/HEAD> <BODY>\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":10457,"url":"http:\/\/bangla.sitestree.com\/?p=10457","url_meta":{"origin":10308,"position":4},"title":"HeadingTag.java Custom tag that makes use of a tag body","author":"","date":"August 28, 2015","format":false,"excerpt":"HeadingTag.java Custom tag that makes use of a tag body package cwp.tags; import javax.servlet.jsp.*; import javax.servlet.jsp.tagext.*; import java.io.*; \/** Generates an HTML heading with the specified background \u00a0*\u00a0 color, foreground color, alignment, font, and font size. \u00a0*\u00a0 You can also turn on a border around it, which normally \u00a0*\u00a0 just\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":27117,"url":"http:\/\/bangla.sitestree.com\/?p=27117","url_meta":{"origin":10308,"position":5},"title":"HeadingExample.jsp Page that uses the HeadingTag custom tag #Programming Code Examples #Java\/J2EE\/J2ME #Applets and Basic Graphics","author":"Author-Check- Article-or-Video","date":"May 11, 2021","format":false,"excerpt":"HeadingExample.jsp Page that uses the HeadingTag custom tag <!DOCTYPE HTML PUBLIC \"-\/\/W3C\/\/DTD HTML 4.0 Transitional\/\/EN\"> <!-- Illustration of HeadingTag tag. Taken from Core Web Programming Java 2 Edition from Prentice Hall and Sun Microsystems Press, . May be freely used or adapted. --> <HTML> <HEAD> <TITLE>Some Tag-Generated Headings<\/TITLE> <\/HEAD> <BODY>\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":[]}],"_links":{"self":[{"href":"http:\/\/bangla.sitestree.com\/index.php?rest_route=\/wp\/v2\/posts\/10308","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=10308"}],"version-history":[{"count":1,"href":"http:\/\/bangla.sitestree.com\/index.php?rest_route=\/wp\/v2\/posts\/10308\/revisions"}],"predecessor-version":[{"id":10309,"href":"http:\/\/bangla.sitestree.com\/index.php?rest_route=\/wp\/v2\/posts\/10308\/revisions\/10309"}],"wp:attachment":[{"href":"http:\/\/bangla.sitestree.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=10308"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/bangla.sitestree.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=10308"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/bangla.sitestree.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=10308"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}