Build Q - minimizing size of applet

hello,
I'm writing a charting applet with JFreeChart, which is awesome but large. I've tried both including jfreechart.jar in the run-time libraries, and pulling out the .class files & putting them in my source folder, in the hope that Creator would walk the dependency tree and just include what it needed - but no luck, it includes everything and i'm left with a close to 3Mb applet with performance issues.
Short of either becoming an ant master, which i suppose i'll need to do eventually anyway, or manually just including the classes i think i need from the library & then looking for runtime errors, is there any way to get Creator to include just the classes it needs in the final applet.jar?
TIA,
alex.

AFAIK, creator will include all specified classes and will not exclude unused classes. (After all, the code could be loading classes dynamically and so unless the user specifically instructs that a class should not be included in the archive, the ide will by default include all classes).
So, imho, you will need to arrive at the list of needed classes by the method you have suggested.
btw, have u tried <param name=archive value="myapplet.jar" , "jfreechart.jar">? I think this will cache the chart jar and hence will speed up download after the first time...
Ref: http://java.sun.com/j2se/1.4.2/docs/guide/plugin/developer_guide/applet_caching.html
If it is an internal application, then you could also request users to install freechart jar as an extension library in their java runtime...
From http://www.jfree.org/jfreechart/faq.html#FAQ3:
Can I use JFreeChart in an applet?
...There are some provisos though:
    * JFreeChart doesn't incorporate any special applet features. For example, you can't pass data to the chart applet via HTML as you can in some charting packages.
    * we haven't made any special effort to minimise the size of the JFreeChart jar files. It is something that could be done, but really the demand for it is low, so it hasn't been done yet.

Similar Messages

  • How to set the size of applet when invoking forms through formsserver

    HI,
    I m using forms server to display my forms in browser, my
    problem is to change the size of applet at runtime so that the
    entire forms is displayed.
    right now the forms whose size is more r displayed with
    scrollbars.
    and thats giving me problem with printing.
    Sreekant

    - The HEIGHT and WIDTH parameters in the HTML file are
    responsible for the size
    of the applet area. This is documented in the Forms online
    manuals. The
    manual also states that these values are in pixels.
    Tip
    This value can be set to a percentage of the browser's available
    work space.
    This means that if the browser is resized or the DISPLAY
    resolution is changed
    the applet area will adjust to those changes.
    Example
    Instead of the following:
    WIDTH=800
    HEIGHT=600
    Change to:
    WIDTH=100%
    HEIGHT=100%
    This will make the applet use 100% of the browser's work space.
    If you
    change the values to 50%, the applet will use 50% or the
    browser's space.
    The HEIGHT and WIDTH values can be defined in your FORMSWEB.CFG
    or your own
    static html file. These values can also be added to the URL when
    using CGI.
    NOTE: THIS WILL NOT WORK IF SEPARATEFRAME=TRUE
    Regards
    Grant Ronald
    Forms Product Management

  • Files open using Notepad o always in minimized size

    All of a sudden, when I open a file using note pad, it always open in minimized size, I have to give an extra click to maximaze it.
    I searched on line, and tried something like to setup in Notepad property window, in run field , set it to normal.
    Or tried open it and maximize it and close it, nothing works.
    I can open a new notepad document in big window, but not for all existing files.
    Please help what I should do.
    Thanks,
    SQLFriend

    I found on website this worked for me:
    http://stackoverflow.com/questions/15941211/notepad-files-always-open-as-a-very-small-window
    "I know its just anyhow solution but will work First, close all other windows. Now, grab the corners of the window and drag it to full screen size. Close the window using File:Close, or File:Exit depending what program you're in. Windows will
    remember the last screen size used the next time you open the program. – 
    KodeCeeper Apr 11 '13 at 8:24"
    Thanks
    SQLFriend

  • Size of applet in Internet Explorer

    Thanx in advance
    When i run a form through 9iDS it shows the form not in actual size in applet window. How can i make changing in applet size.

    Hi,
    in the file <oracle_home>/forms90/server/formsweb.cfg
    Param width and height.

  • Shape builder tool changing sizes?

    Hello,
    I am using shape builder tool a lot to clean up dxf files generated from cad programs, where there are a lot of loose/open paths. I just noticed that when I join paths with the shape builder tool, the size of the form changes slightly. This effect is not occuring if I join the same paths with the slower step-by-step join command, and I can't see the reason for those minor size deviations?
    Is there a way to change some settings to get rid of this effect?
    Br, Jörgen

    I get a similar result if the strokes have an effect, such as "rounded corner" applied to them. Taking off the effect before using Shape Builder eliminates the issue.

  • CS4 Test Movie window keeps defaulting back to minimal size

    When I go to Test Movie in Flash CS4 the screen defaults back to minimal size each time I preview.  In CS3 which I still use as well, after the first time you test your movie and maximize your window (I like to see the site with the background color) it will be maximized the next time you preview.  With CS4 I have to maximize each time I test the movie.  I've looked in preferences and can't seem to find a setting for this.
    Any help would be so appreciated.
    Thanks,
    BC

    Myself and many others have the same problem - check out this thread
    http://forums.adobe.com/thread/436313

  • How can i increase size of applet

    when i run my form in windows my applet don't visible full .how can change the size of applet.what property i have to set.i forget that property.

    are you using an application server or the local OC4J container?
    In both cases the height and width of your applet can be set in the formsweb.cfg file.
    you can find this file under <oracle_home>/forms/server directory
    search in the file for with and height
    you can put a fixed size in pixels or in percentage of your screen resolution
    hope it helps
    Erwin

  • How to let Stage size adjust to size of applet ?

    Sirs and madams,
    I need to deploy an app online. There is going to be lots of stuff on the Stage.
    To keep possible damage to user's eye minimal i would like to adjust the size of the Stage and
    it's components to the size of the applet.
    Is such a thing possible? If yes - how?
    Thanks in advance!

    The size of the applet is defined in the HTML file generated by javafxpackager (or NetBeans using the latter):
    <script>
        javafx(
                  archive: "JavaFXProgram.jar",
                  draggable: true,
                  width: 1024,
                  height: 768,
                  code: "JavaFXProgram",
                  name: "JavaFXProgram"
    </script>In general, you define these values to the size of the stage, not the way around...
    Although, I suppose you can generate these sizes if you generate dynamically the page (eg. with a JSP or something similar).
    You can get these values with FX.getArgument(), and size the stage with them:
    def WIDTH: Integer = Integer.parseInt(FX.getArgument('width') as String);
    def HEIGHT: Integer = Integer.parseInt(FX.getArgument('height') as String);
    Stage
      title: "JavaFX Packaging and Deployment Test"
      width: WIDTH
      height: HEIGHT
      scene: scene
    }

  • Size of applet

    Hi
    I want to know the total size of my applet.
    It contains the size when installing it and the memory used while processing it.
    How should I calculate?
    Do it become it as well as the size of "CAP file"?
    When the package is installed from the JCOP shell, the following messages are output.
    Load report:
      16030 bytes loaded in 64.9 seconds
      effective code size on card:
          + package AID       6
          + applet AIDs       17
          + classes           95
          + methods           13137
          + statics           125
          + exports           0
            overall           13380  bytes

    Hi
    I solved the problem.
    I installed the test applet (..return value of "getAvailableMemory".. make a response).
    And, I installed many applets that wanted to measure the size while changing AID.
    And, when applets of a certain number were installed, test applet ("getAvailableMemory") returned 6A10h.
    And, when the applet of another piece was installed in addition, test applet ("getAvailableMemory") returned 17DCh.
    6A10h - 17DCh = 5234hI think that the size of my applet is 5234h.

  • Size of applet & scrollbars

    I start the applet from a html page with <applet....width="100%" Height="100%">. The problem is the components on the applet are created dynamically and can be changed to need a different size applet by changing a config file. The applet use table layout manager. The problem with using width="100%" & Height="100% is that if the browser size starts small any horizontal scroll does not scroll to the full width of the applet - the browser needs to be resized manually to see all the components.
    The html file that start the applet is built on the fly, so I could potentially read the config and set the width manually. But there are lots of components in the applet and it would mean maintaining size in 2 different places.
    Any comments appreciated.
    Thanks, Tom.

    I start the applet from a html page with <applet....width="100%" Height="100%">. The problem is the components on the applet are created dynamically and can be changed to need a different size applet by changing a config file. The applet use table layout manager. The problem with using width="100%" & Height="100% is that if the browser size starts small any horizontal scroll does not scroll to the full width of the applet - the browser needs to be resized manually to see all the components.
    The html file that start the applet is built on the fly, so I could potentially read the config and set the width manually. But there are lots of components in the applet and it would mean maintaining size in 2 different places.
    Any comments appreciated.
    Thanks, Tom.

  • Minimization size of applet

    So I need to create empty applet, with smallest size.
    import java.applet.Applet;
    public class EmptyApplet extends Applet
         public void init()
    }After compiling its size about 2KB is any chanses to increase its size?

    Probably not, but why would someone do something pointless like creating an empty applet?

  • Pack200 for reducing size of applets

    Hi i am working swing based applet application which is deployed on a jboss3.2.6 webserver.the jar file application.jar+ size is 140kb.i compressed the jar file using sun java pack200 technology as application.pack200.gz+ file.now the jar file size is 46kb.the jar is deployed on application.war+ file with context-path */application* on the jboss deploy path.the war file that contains the jar file also has a servlet(pack200 servlet provided in the sunjava website) to service the *.jar requests to give the compressed application.pack200.gz file to the response.outputstream() for any incoming requests for any jar file.
    When i make a request on the webbrowser as http://localhost:8080/application/application.jar+ the pack200 service servlet inside the application.war services the request to yield a compressed application.jar(46kb).+
    Now the problem arises when im calling application.jar+ from an html page(*index.html*)using THE FOLLOWING CODE
    <html>
    <html>
        <title>
    Applet APPLICATION
      </title>
      <head>
         <meta HTTP-EQUIV="Pragma" CONTENT="no-cache">
         <meta HTTP-EQUIV="Expires" CONTENT="-1">
      <meta HTTP-EQUIV="accept-encoding" CONTENT="gzip,deflate">
      <meta http-equiv="content-type" content="text/html">
      </head>
    <BODY>
    <Applet code='application.main.class' codebase='.' archive='../application/application.jar'>
    <param name="java_arguments" value="-Djnlp.packEnabled=true"/>
    </applet>
    </BODY>
    </HTML>The index.html file calling the applet is deployed in separate war file viewer.war+ with a context path */view* inside the jboss3.2.6 deploy path
    When i load the index.html inside the webbrowser i always get the following exception in the sun java console of the webbrowser
    Java Plug-in 1.5.0_02
    Using JRE version 1.5.0_02 Java HotSpot(TM) Client VM
    User home directory = C:\Documents and Settings\kartheepan
    c: clear console window
    f: finalize objects on finalization queue
    g: garbage collect
    h: display this help message
    l: dump classloader list
    m: print memory usage
    o: trigger logging
    p: reload proxy configuration
    q: hide console
    r: reload policy configuration
    s: dump system and deployment properties
    t: dump thread list
    v: dump thread stack
    x: clear classloader cache
    0-5: set trace level to <n>
    load: class application.main.class not found.
    java.lang.ClassNotFoundException: chart.MainApplet.class
    at sun.applet.AppletClassLoader.findClass(Unknown Source)
    at java.lang.ClassLoader.loadClass(Unknown Source)
    at sun.applet.AppletClassLoader.loadClass(Unknown Source)
    at java.lang.ClassLoader.loadClass(Unknown Source)
    at sun.applet.AppletClassLoader.loadCode(Unknown Source)
    at sun.applet.AppletPanel.createApplet(Unknown Source)
    at sun.plugin.AppletViewer.createApplet(Unknown Source)
    at sun.applet.AppletPanel.runLoader(Unknown Source)
    at sun.applet.AppletPanel.run(Unknown Source)
    at java.lang.Thread.run(Unknown Source)
    Caused by: java.io.IOException: open HTTP connection failed.
    at sun.applet.AppletClassLoader.getBytes(Unknown Source)
    at sun.applet.AppletClassLoader.access$100(Unknown Source)
    at sun.applet.AppletClassLoader$1.run(Unknown Source)
    at java.security.AccessController.doPrivileged(Native Method)
    ... 10 moreThe applet did not load successfully.
    When i change the coding in the pack200 service servlet to give application.jar+ as response rather the compressed application.pack200.gz+ the application loads successfully in the index.html without fail.I believe there is no problem with the pack200 service servlet provided by the sun website.I am using jdk.1.5 version of java for development with jboss3.2.6 as application server.
    i am afraid the webbrowser is not able to decompress the compressed application.jar successfully using the jdk1.5/bin/+unpack200.exe+ provided by the jdk1.5 version of java.Is it something im missing in the index.html+ code.
    i have provided the following 2 mandatory things as mentioned in the pack200 deployment guidelines
    <meta HTTP-EQUIV="accept-encoding" CONTENT="pack200-gzip,gzip">inside the <head> tag and also
    <param name="java_arguments" value="-Djnlp.packEnabled=true"/>i even tried changing the meta tag value from
    <meta HTTP-EQUIV="accept-encoding" CONTENT="pack200-gzip,gzip">to
    <meta HTTP-EQUIV="accept-encoding" CONTENT="gzip,deflate">but with no success i still get the class not found exception.
    Where i my going wrong shoul i need to write any pack200 install routine.AND IF SO WHERE DO I need to write should it be written on the server provided alongside the compressed jar or should it be present on the client machine.
    Edited by: kartheepanmirra on Jun 12, 2009 8:45 AM
    Edited by: kartheepanmirra on Jun 12, 2009 8:49 AM

    is it some thing to do with the application server jboss3.2.6 it works fine in my localsystem and adjacent systems in intranet but it fails in remote system where network access between the remote and my system is slow.I get the following exception in jboss 3.2.6
    18:34:19,875 ERROR [Engine] StandardWrapperValve[jarService]: Servlet.service() for servlet jarServi
    ce threw exception
    java.lang.NullPointerException
            at ContentType1.doGet(Unknown Source)
            at javax.servlet.http.HttpServlet.service(HttpServlet.java:697)
            at javax.servlet.http.HttpServlet.service(HttpServlet.java:810)
            at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.j
    ava:237)
            at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:157)
            at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:75)
            at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.j
    ava:186)
            at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:157)
            at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:214)
            at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
            at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
            at org.apache.catalina.core.StandardContextValve.invokeInternal(StandardContextValve.java:19
    8)
            at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:152)
            at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
            at org.jboss.web.tomcat.security.CustomPrincipalValve.invoke(CustomPrincipalValve.java:66)
            at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:102)
            at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.ja
    va:158)
            at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:102)
            at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
            at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:137)
            at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
            at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:118)
            at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:102)
            at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
            at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
            at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
            at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
            at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:929)
            at org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:160)
            at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:799)
            at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11P
    rotocol.java:705)
            at org.apache.tomcat.util.net.TcpWorkerThread.runIt(PoolTcpEndpoint.java:577)
            at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:683)
            at java.lang.Thread.run(Thread.java:619) when it fails to decompress on the remote machine.The decompression works fine in local and adjacent machine.also i checked it myself to c whether the servlet services the compressed jar file.yes it works fine.the servlet has no problem.I think it must be some issue with the slow network.but nevertheless it should work fine in local area network.if it doesnt it will not work in internet.
    Edited by: kartheepanmirra on Jun 16, 2009 8:48 AM
    Edited by: kartheepanmirra on Jun 16, 2009 8:51 AM

  • How can I build Instalation Program for java applet?

    I want to build on line internet game based on java applet.
    Uset must instull the game to his computer.And this program mast Connect to the server when user enter
    to this application.Not from explorer,but from my application,like when i enter to ICQ.
    My questions:
    How can i build instalation program in java?
    How can i connect to the server when user enter into my game not from explorer but from game?
    Thanks,Maya.

    Hi Maya
    First of all an Applet does not have to be "installed" as you would with a normal application. The browser handles the install and execution of the applet.
    Check out this URL for more about applets:
    http://web2.java.sun.com/docs/books/tutorial/applet/index.html
    On the subject client/server pairs - see:
    http://web2.java.sun.com/docs/books/tutorial/networking/sockets/index.html
    If you decide to make the game an application instead check out Sun's WebStart - under the products section.
    That's about all the help I can give you.
    Programming a game is a complicated subject - I am doing one too:
    http://hjem.get2net.dk/mhjembaek/armageddon/
    Kind reg,
    Hjembaek

  • Build a .jar from an applet

    Hi. I have the following code.
    import controller.Application;
    import model.Slideshow;
    import view.MainFrame;
    import java.applet.Applet;
    public class Main extends Applet {
        public void init() {
            Slideshow slideshow = new Slideshow("untitled.xml");
            Application app = new Application(slideshow);
            new MainFrame(app);
    }I can create the .jar file but when I open it a message of "couldn't finde main class" appears... obviously... it's an applet ! how can I create an excecutable file? thanks very much

    Akcents wrote:
    public class Main{
    public static void main(String[] args) {
    Slideshow slideshow = new Slideshow("untitled.xml");
    Application app = new Application(slideshow);
    new MainFrame(app);
    how can I make an executable file with this class????
    This question is quite different from your original question. Is it your intent to convert the application into an applet or are you interested in creating an [executable JAR file|http://java.sun.com/javase/6/docs/technotes/guides/jar/jarGuide.html]? If it's the latter, when bundling your application in a JAR file you'll need to update the [JAR file manifest|http://java.sun.com/javase/6/docs/technotes/guides/jar/jar.html] with a Main-Class entry. If it's the former, the following link will be helpful:
    [http://java.sun.com/docs/books/tutorial/deployment/applet/getStarted.html |http://java.sun.com/docs/books/tutorial/deployment/applet/getStarted.html ]

  • Set the minimal size of a Component with BorderLayout

    Hi,
    I got a little problem using BorderLayout.
    The scenario is :
    A JPanel placed BorderLayout.WEST got a size a few pixel too small for a JTable contained in this panel to paint all names of the table header.
    If i set the preferredScrollableViewportSize larger then a specific amount the table disappear(shrinks to a tiny size)
    The panel uses GridBagLayout...
    How can i set the size of this "west"-component of the border layout a little larger?
    regards
    Olek

    My understanding of help is an other then only post messages likeWell, your understanding, in my opinion is wrong.
    You must post a self documenting program ...Not everybody who uses this forum speaks english as their main language. Even if english is your main language it is not always easy to communicate the problem effectively. By posting demo code we can see exactly what you are doing.
    Or why you don't read the API... Of course that is a valid answer. You should always read the API. Why should we waste time typing the Documentation from the API when we can point you directly to the API????????
    why you don't search the forum Again, why should be waste time answering questions that have already been answered???????
    You learn by searching the forum and finding multiple solutions, then you use the solution that is appropriate. There is rarely a single solution for all cases. The more knowledge you have the better decision you can make.
    Have a little pride and learn to do some problem solving on your own without us spoonfeeding every anser to you.
    It is not possible to post a short self documenting program ...Then you truly don't understand what the problem is. And if you don't understand what the problem is how to you expect to communicate that problem verbally so that we understand the problem. You question is not about logic its about sizing of components. How hard is it to create a component and add it to a panel to demonstrate the problem. You don't even need real data. For example you can create a JTable with a single line of code, JTable table = new JTable(5, 10).
    the core of the problem depends on the components added to the JSplitPane...Then demonstrate that with a SSCCE.

Maybe you are looking for

  • Why can't I email photos from iPhoto as described in the video?

    I have iPhoto 9.3.2 on my MacBook Pro.  I have watched to video on how to email photos several times.  After selecting the photos to email, the photos appear in the email message but not as described in the video.  Instead of showing up in a pattern

  • Vendor Rating

    Dear All.                  Please any one tell me standard vendor rating report available in sap or not.. if yes please tell me the T-code for that and procedure REgards Kumar

  • Powerbook G4 Power Supply Replacement

    The model number is M8407. I can't find any items on Ebay whose charger works with this labtop. Can you tell me what I need to look for?

  • Users are not authorized to accesContent Management- Classification- Report

    Hi All, We are planning to user 'Property Propagation' tool present at Content Management->Classification->Report. We have added the report iView to custom role. When user access the rerport he is getting following message: "No reports are available

  • Internal error with jgoodies form lib

    I was evaluating the 0.9.7 version of the form lib (nc version) with JDeveloper 9.0.3.1 and I could not compile anything with the library. Everytime I tried to compile my project I got a "compiler internal error". I did not see any speific error mess