Connecting Tech Pros Worldwide Help | Site Map

fooling for a repaint

 
LinkBack Thread Tools Search this Thread
  #1  
Old July 20th, 2005, 02:30 PM
Ike
Guest
 
Posts: n/a
Default fooling for a repaint

I changing the size of frames dynamically in a page (I am restricted in that
I cannot perform a reload of the content of any of the frames). In MSIE,
when I resize the frames, thinks repaint perfectly. In NS 7 there are
artifacts left over from what previously occupied a given frame.

If I minimize the NS browser, then mazimize it again, the NS browser
repaints the contents of the frames, and everything looks correct.

Is there a way - any conceivable way - anyone knows or can think of to trick
the browser into repainting itself when a frame is resized? Thanks, Ike



  #2  
Old July 20th, 2005, 02:30 PM
Michael Winter
Guest
 
Posts: n/a
Default Re: fooling for a repaint

On Fri, 13 Feb 2004 13:11:05 GMT, Ike <rxv@hotmail.com> wrote:
[color=blue]
> I changing the size of frames dynamically in a page (I am restricted in
> that I cannot perform a reload of the content of any of the frames). In
> MSIE, when I resize the frames, thinks repaint perfectly. In NS 7 there
> are artifacts left over from what previously occupied a given frame.
>
> If I minimize the NS browser, then mazimize it again, the NS browser
> repaints the contents of the frames, and everything looks correct.
>
> Is there a way - any conceivable way - anyone knows or can think of to
> trick the browser into repainting itself when a frame is resized?[/color]

Not off hand, but do report it to Netscape. At least then, future versions
of the browser might be free from the problem.

If you can't explain to them what causes it properly, host an example
version of the page, give them the URL and illustrate how interacting with
it causes artifacts.

Mike

--
Michael Winter
M.Winter@blueyonder.co.invalid (replace ".invalid" with ".uk" to reply)
  #3  
Old July 20th, 2005, 02:30 PM
Beauregard T. Shagnasty
Guest
 
Posts: n/a
Default Re: fooling for a repaint

Quoth the raven named Michael Winter:
[color=blue]
> On Fri, 13 Feb 2004 13:11:05 GMT, Ike <rxv@hotmail.com> wrote:
>[color=green]
>> I changing the size of frames dynamically in a page (I am
>> restricted in that I cannot perform a reload of the content of
>> any of the frames). In MSIE, when I resize the frames, thinks
>> repaint perfectly. In NS 7 there are artifacts left over from
>> what previously occupied a given frame.
>>
>> If I minimize the NS browser, then mazimize it again, the NS
>> browser repaints the contents of the frames, and everything looks
>> correct.
>>
>> Is there a way - any conceivable way - anyone knows or can think
>> of to trick the browser into repainting itself when a frame is
>> resized?[/color]
>
> Not off hand, but do report it to Netscape. At least then, future
> versions of the browser might be free from the problem.[/color]

Does this same problem occur with Mozilla 1.6? Or Firefox 0.8?

If not, then whatever the bug was, has already been fixed. Netscape
stopped development with 7.1, which is the Mozilla 1.4 engine. Or so I
am told; Netscape the company is dead.

--
-bts
-This space intentionally left blank.
  #4  
Old July 20th, 2005, 02:31 PM
Jerry Polyak
Guest
 
Posts: n/a
Default Re: fooling for a repaint

Add the following code into the <head> section of your documents:

<script language="JavaScript" type="text/JavaScript">
<!--
function MM_reloadPage(init) { //reloads the window if Nav4 resized
if (init==true) with (navigator) {if
((appName=="Netscape")&&(parseInt(appVersion)==4)) {
document.MM_pgW=innerWidth; document.MM_pgH=innerHeight;
onresize=MM_reloadPage; }}
else if (innerWidth!=document.MM_pgW || innerHeight!=document.MM_pgH)
location.reload();
}
MM_reloadPage(true);
//-->
</script>

Jerry P.


"Ike" <rxv@hotmail.com> wrote in message
news:J14Xb.3632$W74.1895@newsread1.news.atl.earthl ink.net...[color=blue]
> I changing the size of frames dynamically in a page (I am restricted in[/color]
that[color=blue]
> I cannot perform a reload of the content of any of the frames). In MSIE,
> when I resize the frames, thinks repaint perfectly. In NS 7 there are
> artifacts left over from what previously occupied a given frame.
>
> If I minimize the NS browser, then mazimize it again, the NS browser
> repaints the contents of the frames, and everything looks correct.
>
> Is there a way - any conceivable way - anyone knows or can think of to[/color]
trick[color=blue]
> the browser into repainting itself when a frame is resized? Thanks, Ike
>
>[/color]


  #5  
Old July 20th, 2005, 02:31 PM
Ike
Guest
 
Posts: n/a
Default Re: fooling for a repaint

Thanks Jerry,

But I have to avoid reloading the page as it contains a java applet which,
if the page is reloaded, gets restarted, and I need to avoid that. Instead,
I need to simply "repaint" what is already there, but evidently, there's no
way to do this under html/dhtml/javascript. What I'm trying to do is find a
way to "fool" the browser into repainting the view, much as it does,
automatically, if a window is opened in front of it, and subsequently
closed, the browser view repaints correctly.

-Ike

"Jerry Polyak" <jpgoalNOSPAM@yahoo.com> wrote in message
news:mdadnXaAHpRcr7DdRVn-vA@adelphia.com...[color=blue]
> Add the following code into the <head> section of your documents:
>
> <script language="JavaScript" type="text/JavaScript">
> <!--
> function MM_reloadPage(init) { //reloads the window if Nav4 resized
> if (init==true) with (navigator) {if
> ((appName=="Netscape")&&(parseInt(appVersion)==4)) {
> document.MM_pgW=innerWidth; document.MM_pgH=innerHeight;
> onresize=MM_reloadPage; }}
> else if (innerWidth!=document.MM_pgW || innerHeight!=document.MM_pgH)
> location.reload();
> }
> MM_reloadPage(true);
> //-->
> </script>
>
> Jerry P.
>
>
> "Ike" <rxv@hotmail.com> wrote in message
> news:J14Xb.3632$W74.1895@newsread1.news.atl.earthl ink.net...[color=green]
> > I changing the size of frames dynamically in a page (I am restricted in[/color]
> that[color=green]
> > I cannot perform a reload of the content of any of the frames). In MSIE,
> > when I resize the frames, thinks repaint perfectly. In NS 7 there are
> > artifacts left over from what previously occupied a given frame.
> >
> > If I minimize the NS browser, then mazimize it again, the NS browser
> > repaints the contents of the frames, and everything looks correct.
> >
> > Is there a way - any conceivable way - anyone knows or can think of to[/color]
> trick[color=green]
> > the browser into repainting itself when a frame is resized? Thanks, Ike
> >
> >[/color]
>
>[/color]


  #6  
Old July 20th, 2005, 02:31 PM
Jerry Polyak
Guest
 
Posts: n/a
Default Re: fooling for a repaint

I see. Than that probably won't work. LOL. Coincidentally, the code was
generated by Dreamweaver MX as a fix for Netscape resize problem. Which
just makes me think that it is a well known problem.


"Ike" <rxv@hotmail.com> wrote in message
news:3SaXb.3967$W74.2584@newsread1.news.atl.earthl ink.net...[color=blue]
> Thanks Jerry,
>
> But I have to avoid reloading the page as it contains a java applet which,
> if the page is reloaded, gets restarted, and I need to avoid that.[/color]
Instead,[color=blue]
> I need to simply "repaint" what is already there, but evidently, there's[/color]
no[color=blue]
> way to do this under html/dhtml/javascript. What I'm trying to do is find[/color]
a[color=blue]
> way to "fool" the browser into repainting the view, much as it does,
> automatically, if a window is opened in front of it, and subsequently
> closed, the browser view repaints correctly.
>
> -Ike
>
> "Jerry Polyak" <jpgoalNOSPAM@yahoo.com> wrote in message
> news:mdadnXaAHpRcr7DdRVn-vA@adelphia.com...[color=green]
> > Add the following code into the <head> section of your documents:
> >
> > <script language="JavaScript" type="text/JavaScript">
> > <!--
> > function MM_reloadPage(init) { //reloads the window if Nav4 resized
> > if (init==true) with (navigator) {if
> > ((appName=="Netscape")&&(parseInt(appVersion)==4)) {
> > document.MM_pgW=innerWidth; document.MM_pgH=innerHeight;
> > onresize=MM_reloadPage; }}
> > else if (innerWidth!=document.MM_pgW || innerHeight!=document.MM_pgH)
> > location.reload();
> > }
> > MM_reloadPage(true);
> > //-->
> > </script>
> >
> > Jerry P.
> >
> >
> > "Ike" <rxv@hotmail.com> wrote in message
> > news:J14Xb.3632$W74.1895@newsread1.news.atl.earthl ink.net...[color=darkred]
> > > I changing the size of frames dynamically in a page (I am restricted[/color][/color][/color]
in[color=blue][color=green]
> > that[color=darkred]
> > > I cannot perform a reload of the content of any of the frames). In[/color][/color][/color]
MSIE,[color=blue][color=green][color=darkred]
> > > when I resize the frames, thinks repaint perfectly. In NS 7 there are
> > > artifacts left over from what previously occupied a given frame.
> > >
> > > If I minimize the NS browser, then mazimize it again, the NS browser
> > > repaints the contents of the frames, and everything looks correct.
> > >
> > > Is there a way - any conceivable way - anyone knows or can think of to[/color]
> > trick[color=darkred]
> > > the browser into repainting itself when a frame is resized? Thanks,[/color][/color][/color]
Ike[color=blue][color=green][color=darkred]
> > >
> > >[/color]
> >
> >[/color]
>
>[/color]


  #7  
Old July 20th, 2005, 02:31 PM
Randy Webb
Guest
 
Posts: n/a
Default Re: fooling for a repaint

Jerry Polyak wrote:
[color=blue]
> Add the following code into the <head> section of your documents:[/color]

And then remove it, its junk.
[color=blue]
> <script language="JavaScript" type="text/JavaScript">
> <!--
> function MM_reloadPage(init) { //reloads the window if Nav4 resized
> if (init==true) with (navigator) {if
> ((appName=="Netscape")&&(parseInt(appVersion)==4)) {
> document.MM_pgW=innerWidth; document.MM_pgH=innerHeight;
> onresize=MM_reloadPage; }}
> else if (innerWidth!=document.MM_pgW || innerHeight!=document.MM_pgH)
> location.reload();
> }
> MM_reloadPage(true);
> //-->
> </script>
>
> Jerry P.[/color]

Read the comp.lang.javascript FAQ with regards to browser detection, and
its impossibility and futility. Also with regards to top-posting.

--
Randy
Chance Favors The Prepared Mind
comp.lang.javascript FAQ - http://jibbering.com/faq/

  #8  
Old July 20th, 2005, 02:31 PM
Jerry Polyak
Guest
 
Posts: n/a
Default Re: fooling for a repaint

What about top posting, there Randy?

You must be that news group police?


"Randy Webb" <hikksnotathome@aol.com> wrote in message
news:NO6dnaZgK5b6y7DdRVn-gQ@comcast.com...[color=blue]
> Jerry Polyak wrote:
>[color=green]
> > Add the following code into the <head> section of your documents:[/color]
>
> And then remove it, its junk.
>[color=green]
> > <script language="JavaScript" type="text/JavaScript">
> > <!--
> > function MM_reloadPage(init) { //reloads the window if Nav4 resized
> > if (init==true) with (navigator) {if
> > ((appName=="Netscape")&&(parseInt(appVersion)==4)) {
> > document.MM_pgW=innerWidth; document.MM_pgH=innerHeight;
> > onresize=MM_reloadPage; }}
> > else if (innerWidth!=document.MM_pgW || innerHeight!=document.MM_pgH)
> > location.reload();
> > }
> > MM_reloadPage(true);
> > //-->
> > </script>
> >
> > Jerry P.[/color]
>
> Read the comp.lang.javascript FAQ with regards to browser detection, and
> its impossibility and futility. Also with regards to top-posting.
>
> --
> Randy
> Chance Favors The Prepared Mind
> comp.lang.javascript FAQ - http://jibbering.com/faq/
>[/color]


  #9  
Old July 20th, 2005, 02:31 PM
Dana Cartwright
Guest
 
Posts: n/a
Default Re: fooling for a repaint

You could, on a timer event, put up an opaque (color of your choice) DIV
that covers the entire screen (or the part that you know you want to
repaint) and then hide it again. This might well force a repaint of
everything that was under the DIV. It would cause a brief flash of the
screen, but that might be preferable to having garbage on the screen.

You have to do this on a timer event because you have to give the browser a
chance to make the DIV visible, before you tear it down. In other words,
you can't, in JS, just make the DIV visible and immediately hide it, on two
successive lines of code, because the browser will just ignore that. You
have to make it visible, exit from your event's code, and then a fraction of
a second later you can hide it.

--
--------------------
My e-mail address doesn't have a 2 in it.
"Beauregard T. Shagnasty" <a.nony.mous@example.invalid> wrote in message
news:Ou6Xb.13569$um1.288@twister.nyroc.rr.com...[color=blue]
> Quoth the raven named Michael Winter:
>[color=green]
> > On Fri, 13 Feb 2004 13:11:05 GMT, Ike <rxv@hotmail.com> wrote:
> >[color=darkred]
> >> I changing the size of frames dynamically in a page (I am
> >> restricted in that I cannot perform a reload of the content of
> >> any of the frames). In MSIE, when I resize the frames, thinks
> >> repaint perfectly. In NS 7 there are artifacts left over from
> >> what previously occupied a given frame.
> >>
> >> If I minimize the NS browser, then mazimize it again, the NS
> >> browser repaints the contents of the frames, and everything looks
> >> correct.
> >>
> >> Is there a way - any conceivable way - anyone knows or can think
> >> of to trick the browser into repainting itself when a frame is
> >> resized?[/color]
> >
> > Not off hand, but do report it to Netscape. At least then, future
> > versions of the browser might be free from the problem.[/color]
>
> Does this same problem occur with Mozilla 1.6? Or Firefox 0.8?
>
> If not, then whatever the bug was, has already been fixed. Netscape
> stopped development with 7.1, which is the Mozilla 1.4 engine. Or so I
> am told; Netscape the company is dead.
>
> --
> -bts
> -This space intentionally left blank.[/color]


  #10  
Old July 20th, 2005, 02:31 PM
Toby A Inkster
Guest
 
Posts: n/a
Default Re: fooling for a repaint

Beauregard T. Shagnasty wrote:
[color=blue]
> Netscape the company is dead.[/color]

Netscape the browser is dead. Netscape the brand lives on. Netscape has
recently opened an ISP in the UK (didn't it just close one down?) and the
Netscape.com portal site is still soldiering on.

--
Toby A Inkster BSc (Hons) ARCS
Contact Me - http://www.goddamn.co.uk/tobyink/?page=132

  #11  
Old July 20th, 2005, 02:31 PM
Beauregard T. Shagnasty
Guest
 
Posts: n/a
Default Re: fooling for a repaint

Quoth the raven named Toby A Inkster:[color=blue]
> Beauregard T. Shagnasty wrote:
>[color=green]
>> Netscape the company is dead.[/color]
>
> Netscape the browser is dead. Netscape the brand lives on. Netscape
> has recently opened an ISP in the UK (didn't it just close one
> down?) and the Netscape.com portal site is still soldiering on.[/color]

Ok, thanks for the clarification, Toby.

"The browser is dead, long live the browser..."

--
-bts
-This space intentionally left blank.
  #12  
Old July 20th, 2005, 02:32 PM
Ike
Guest
 
Posts: n/a
Default Re: fooling for a repaint

How might I do such a thing?

"Dana Cartwright" <danapub2@weavemaker.com> wrote in message
news:EveXb.14058$um1.12481@twister.nyroc.rr.com...[color=blue]
> You could, on a timer event, put up an opaque (color of your choice) DIV
> that covers the entire screen (or the part that you know you want to
> repaint) and then hide it again. This might well force a repaint of
> everything that was under the DIV. It would cause a brief flash of the
> screen, but that might be preferable to having garbage on the screen.
>
> You have to do this on a timer event because you have to give the browser[/color]
a[color=blue]
> chance to make the DIV visible, before you tear it down. In other words,
> you can't, in JS, just make the DIV visible and immediately hide it, on[/color]
two[color=blue]
> successive lines of code, because the browser will just ignore that. You
> have to make it visible, exit from your event's code, and then a fraction[/color]
of[color=blue]
> a second later you can hide it.
>
> --
> --------------------
> My e-mail address doesn't have a 2 in it.
> "Beauregard T. Shagnasty" <a.nony.mous@example.invalid> wrote in message
> news:Ou6Xb.13569$um1.288@twister.nyroc.rr.com...[color=green]
> > Quoth the raven named Michael Winter:
> >[color=darkred]
> > > On Fri, 13 Feb 2004 13:11:05 GMT, Ike <rxv@hotmail.com> wrote:
> > >
> > >> I changing the size of frames dynamically in a page (I am
> > >> restricted in that I cannot perform a reload of the content of
> > >> any of the frames). In MSIE, when I resize the frames, thinks
> > >> repaint perfectly. In NS 7 there are artifacts left over from
> > >> what previously occupied a given frame.
> > >>
> > >> If I minimize the NS browser, then mazimize it again, the NS
> > >> browser repaints the contents of the frames, and everything looks
> > >> correct.
> > >>
> > >> Is there a way - any conceivable way - anyone knows or can think
> > >> of to trick the browser into repainting itself when a frame is
> > >> resized?
> > >
> > > Not off hand, but do report it to Netscape. At least then, future
> > > versions of the browser might be free from the problem.[/color]
> >
> > Does this same problem occur with Mozilla 1.6? Or Firefox 0.8?
> >
> > If not, then whatever the bug was, has already been fixed. Netscape
> > stopped development with 7.1, which is the Mozilla 1.4 engine. Or so I
> > am told; Netscape the company is dead.
> >
> > --
> > -bts
> > -This space intentionally left blank.[/color]
>
>[/color]


 

Bookmarks

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Popular Articles

What is Bytes?

We are a network of experts and professionals in IT and software development that help one another with answers to tough questions and share insights. Get the best answers to your questions from over 220,989 network members.