I quite like this coolsmile one (www.coolsmile.net) but i don't like the way
it defaults to blue text.. and when you select other colours (e.g. black)
your text can't be seen if someone has a black background. We don't like to
encourage ppl to use colour on our server, but don't want to strip it out
altogether, server-side, either.
If I knew anything about java it's open source adn I would be able to remove
the colour options altogether i guess.
Anyway I like the way it looks so if someone can suggest a similar
alternative, or advice on how to tweak this one, that'd be great.
TIA.
Roedy Green - 30 Sep 2005 06:57 GMT
>I quite like this coolsmile one (www.coolsmile.net) but i don't like the way
>it defaults to blue text.
That site has not a stick of Java on it that I could see. The server
code might be written in Java, but what controls the colour is the CSS
style sheet the generated HTML uses. You change that, and it totally
changes the look. See http://mindprod.com/jgloss/css.html
You can peek at the style sheets it is using, and if you are feeling
bold save the page and the style sheets locally and fiddle with them
using a tool like TopStyle to totally change the way that page looks.
<LINK rel="stylesheet" href="/css/cool.css">
<LINK rel="stylesheet" href="/css/bleu.css">
CSS has almost nothing to do with Java or Servlets. The idea is to
control the presentation layout, colours, spacing, borders etc from
the style sheet so you can change it without changing the server side
code.
See http://mindprod.com/jgloss/topstyle.html

Signature
Canadian Mind Products, Roedy Green.
http://mindprod.com Again taking new Java programming contracts.
bort - 30 Sep 2005 10:00 GMT
>>I quite like this coolsmile one (www.coolsmile.net) but i don't like the
>>way
[quoted text clipped - 4 lines]
> style sheet the generated HTML uses. You change that, and it totally
> changes the look. See http://mindprod.com/jgloss/css.html
wtf? I'm talking about the actual coolsmile java chat applet not their
website.
Roedy Green - 30 Sep 2005 10:45 GMT
>wtf? I'm talking about the actual coolsmile java chat applet not their
>website.
It crashed right off: This looks like very old code for a Netscape
signed Applet.
The other hint is I am in Canada and it looks as though somehow this
app does not work with a Canadian locale.
ava.lang.ExceptionInInitializerError
at
netscape.security.PrivilegeManager.printErrorMessage(Unknown Source)
at netscape.security.PrivilegeManager.enablePrivilege(Unknown
Source)
at EIRC.a(Unknown Source)
at EIRC.long(Unknown Source)
at EIRC.k(Unknown Source)
at EIRC.start(Unknown Source)
at com.opera.PluginPanel.startApplet(PluginPanel.java:297)
at com.opera.PluginPanel.run(PluginPanel.java:424)
at java.lang.Thread.run(Unknown Source)
Caused by: java.util.MissingResourceException: Can't find bundle for
base name sun.plugin.resources.Activator, locale en_CA
at
java.util.ResourceBundle.throwMissingResourceException(Unknown Source)
at java.util.ResourceBundle.getBundleImpl(Unknown Source)
at java.util.ResourceBundle.getBundle(Unknown Source)
at sun.plugin.resources.ResourceHandler.<clinit>(Unknown
Source)
... 9 more

Signature
Canadian Mind Products, Roedy Green.
http://mindprod.com Again taking new Java programming contracts.
bort - 30 Sep 2005 12:53 GMT
>>wtf? I'm talking about the actual coolsmile java chat applet not their
>>website.
>
> It crashed right off: This looks like very old code for a Netscape
> signed Applet.
ok thanks, maybe there are issues with this one. i might keep looking
Roedy Green - 30 Sep 2005 10:53 GMT
>I quite like this coolsmile one (www.coolsmile.net) but i don't like the way
>it defaults to blue text.. and when you select other colours (e.g. black)
[quoted text clipped - 4 lines]
>If I knew anything about java it's open source adn I would be able to remove
>the colour options altogether i guess.
There are two sorts of colours in a Java Applet. The Applet did not
get very far so I don't even know for sure if it is AWT or Swing. I
suspect AWT.
Some are burned into the program. The choices have nothing to do with
the Java language. These are purely the colours the Applet author
liked. There are three ways you could change them:
1. get the program source from the author. Change the colour numbers.
See http://mindprod.com/jgloss/colour.html for the colour numbers --
same as HTML. Just look for new Color(...) or Color.xxxx
2. decompile the source, change the colour numbers, recompile.
See http://mindprod.com/jgloss/decompiler.html
3. patch the color numbers in the class file. This is quite bit
harder. See http://mindprod.com/jgloss/jasm.html
The other colours are the colours of the frames and widgets. These in
Swing are controlled by the Look and Feel. You can change that by
adding one line of code to the program to select a different
L&F/skin.. You must decompile/recompile to do that or get the source.
See http://mindprod.com/laf.html

Signature
Canadian Mind Products, Roedy Green.
http://mindprod.com Again taking new Java programming contracts.