Forum Moderators: open
Dean Edwards Packer
This will make the code smaller to load but you will need to check the run time advantage.
If using Firefox install Firebug and Yslow.
Do you have control over the end user PC? If yes then make them use FF.
Run a windows optimizer app which tunes IE as well as network connections.
Remove the bloat such as toolbars which may be bolted onto IE.
Should I try to make my script shorter
Like temporarily overclocking IE
I'm working on a web-based MS Paint style drawing program in JavaScript,
It constantly checks the mouse coordinations and draws a line from the old coordinations to the new ones. It's working fine in Firefox, but in IE the script runs too slow. And because it's slow, the scripts catches less mouse coordinations, and the line drawn is more angular whereas in FF it's smooth.
Javascript application running on a web browser may be simply the wrong environment for heavy animations such as this, I'm afraid. As a person who has done extensive benchmark testing of animation timing differences between IE and FF and others, I can say that IE simply will not keep up to run as fast as one may want. As a general rule of thumb, it's best not run at less than 25ms per cycle when accessing DOM and can be even longer in some situations. In fact, attempting to run faster can actually slow it down even more and cause longer real-time run cycles. That said, believe it or not there are situations where it outperforms FF, but generally not usually.
I believe Flash/Actionscript 3 would be a much better choice for such heavy animations.
What you're more-than-likely looking for is a way to optimize/over-optimize your code. For that, there are many different ways, but as may have been stated, we'd need to see the actual JavaScript for thatt.