Re: Applets automatically
To: comp.lang.java.gui
Qu0ll wrote:
The point is not the applet. The applet does not do *anything*
specific to cause the resize. The only aspect the applet has
that helps the entire demo., is that is it amenable to resizing.
It is the HTML and styles (CSS) in the page that cause the applet
to either be resized, or not (in the case of the browsers that fail).
OK then, do you provide guidelines as to the requirements on the HTML/CSS
side for applet resizing or could you recommend a good source for such
guidelines?
As far as the actual example goes, pull up the HTML
and CSS by viewing the source of the web page in your
browser. The styles (90% of the behaviour) are written
directly into the page.
Guidelines? The W3C is the definitive source of
recommendations for HTML and CSS. The trouble is
that browser manufacturers choose which bits of the
recommnedations they will implement, and how.
A classic example is this very page we have been talking about.
<http://www.physci.org/test/resize/fullwnd5.html>
It is declared as HTML 4.01 transitional (but even
then it has two validation errors because I neglected
to specify a width/height for the first (invisible) applet).
It requires HTML 4.01 for styles - CSS, but the APPLET
element was deprecated in HTML 4.01 in preference
to the OBJECT element, which is not supported in
Mozilla family browsers. To support applets in pure
HTML 4.01 requires the horrid nested OBJECT/EMBED
element, but ..what am I saying! That can *never* be
pure, *valid* HTML 4.01, since the EMBED element is
not defined in HTML 4.01!
Then we come to the last comment in the HTML of that
page (the details are hidden in HTML comments, directly
in the web page!). The page ends like this..
"...
<!--
IE introduces scroll-bars unless the last three tags are
together on a single line.
-->
</applet></body></html>"
It certainly is not specified in any spec. that you might
need to put all those elements together on a single line
in order to get IE to honour the layout and style of the
web page!
...If I do decide to go down the applet route then I would
do whatever it took to get it to work on all platforms.
You're a better man than me, Gungadin, if you can
achieve that aim.
...
Why does web start *not* provide what these
applications need?
Sorry, didn't mean to avoid it. It's not so much that web start can't
handle my requirements - it's more that I just don't like it. ...
(snip)
Answered. I cannot say I entirely agree with your caveats
to web start, but the 'want it embedded in a web page'
certainly answers the question.
--
Andrew Thompson
http://www.athompson.info/andrew/
Message posted via JavaKB.com
http://www.javakb.com/Uwe/Forums.aspx/java-gui/200708/1
---
* Synchronet * The Whitehouse BBS --- whitehouse.hulds.com --- check it out free usenet!
--- Synchronet 3.15a-Win32 NewsLink 1.92
Time Warp of the Future BBS - telnet://time.synchro.net:24