how to hide scrollbars in netscape?

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • adrien

    #1

    how to hide scrollbars in netscape?

    Hi,

    (also posted in netscape.public .mozilla.browse r)
    i use netscape 7 and want to hide the scrollbars of the window when
    something happens. I tried this:
    window.scrollba rs.visible=fals e
    window.scrollba rs.visibility=" no"
    ....
    nothing works
    Is it also possible only to hide the vertical scrollbar instead of both?

    thanks for any clue


  • Grant Wagner

    #2
    Re: how to hide scrollbars in netscape?

    adrien wrote:
    [color=blue]
    > Hi,
    >
    > (also posted in netscape.public .mozilla.browse r)
    > i use netscape 7 and want to hide the scrollbars of the window when
    > something happens. I tried this:
    > window.scrollba rs.visible=fals e
    > window.scrollba rs.visibility=" no"
    > ...
    > nothing works
    > Is it also possible only to hide the vertical scrollbar instead of both?
    >
    > thanks for any clue[/color]

    Well, you could continue to guess, or you could read the documentation:

    <url: http://www.mozilla.org/docs/dom/domr...4.html#1020687
    />

    Pay particular attention to the "Notes" section.

    --
    | Grant Wagner <gwagner@agrico reunited.com>

    * Client-side Javascript and Netscape 4 DOM Reference available at:
    *


    * Internet Explorer DOM Reference available at:
    *
    http://msdn.microsoft.com/workshop/a...ence_entry.asp

    * Netscape 6/7 DOM Reference available at:
    * http://www.mozilla.org/docs/dom/domref/
    * Tips for upgrading JavaScript for Netscape 6/7 and Mozilla
    * http://www.mozilla.org/docs/web-deve...upgrade_2.html


    Comment

    • David Dorward

      #3
      Re: how to hide scrollbars in netscape?

      adrien wrote:
      [color=blue]
      > (also posted in netscape.public .mozilla.browse r)[/color]


      [color=blue]
      > i use netscape 7 and want to hide the scrollbars of the window when
      > something happens. I tried this:
      > window.scrollba rs.visible=fals e
      > window.scrollba rs.visibility=" no"[/color]

      html,body { overflow: hidden; } in the style sheet.

      But what if the content won't fit in the window?
      [color=blue]
      > Is it also possible only to hide the vertical scrollbar instead of both?[/color]

      No

      --
      David Dorward http://david.us-lot.org/

      Comment

      • adrien

        #4
        Re: how to hide scrollbars in netscape?

        The purpose with the scrollbars is for me to learn making dynamic webpages
        with javascript with Netscape, not for publishing. When i try something, i
        try until it works ..or until i realise it's impossible.
        What i aimed here is to make the scrollbars hidden when the mouse tries to
        reach the vertical scrollbar. With all the received info, look at this code,
        please:
        <BODY id="bod">
        <script language="JavaS cript">
        var usermouse;
        var limit;
        limit=document. body.clientWidt h * 0.9;

        function test(e) {
        usermouse=e.scr eenX
        sbar=document.g etElementById(" bod");
        if (usermouse>=lim it)
        {
        sbar.setAttribu te("style" , "overflow:hidde n;");
        alert("you cannot reach the vertical scrollbar");
        }
        else
        {
        sbar.setAttribu te("style" , "overflow:visib le;");
        }
        document.onmous emove=test;
        }
        </script>


        BUT it doesn't work. Only the Alert appears but the scrollbars are still
        visible. Do i do something wrong (no error in javascript console) or ...?
        Thanks anyway.


        "DU" <drunclear@hotR EMOVEmail.com> wrote in message
        news:bfke6r$een $1@news.eusc.in ter.net...[color=blue]
        > adrien wrote:[color=green]
        > > Hi,
        > >
        > > (also posted in netscape.public .mozilla.browse r)
        > > i use netscape 7 and want to hide the scrollbars of the window when
        > > something happens. I tried this:
        > > window.scrollba rs.visible=fals e
        > > window.scrollba rs.visibility=" no"
        > > ....
        > > nothing works
        > > Is it also possible only to hide the vertical scrollbar instead of both?
        > >
        > > thanks for any clue
        > >
        > >[/color]
        >
        > Why would you want to remove the scrollbars when the content overflows
        > the window dimensions? ... because this is why and when scrollbars[/color]
        appear..[color=blue]
        >
        > The user can override even a html, body {overflow:hidde n;} css
        > declaration by editing an userContent.css and have html, body
        > {overflow:visib le !important;} or {overflow:auto !important;}.
        >
        > And the user.js file can take care of "scrollbars =no" in the
        > window.open() calls with
        > user_pref("dom. disable_window_ open_feature.sc rollbars", true);
        >
        > What you are asking to do is counter-accessibility and is anti-user.
        > Preventing to notice that overflowed content is clipped and preventing
        > to access, to reach via scrollbars such clipped content just can not be
        > in the objective interests of the web designer and in the objective
        > interests of the visitors/users/customers.
        >
        > DU
        > --
        > Javascript and Browser bugs:
        > http://www10.brinkster.com/doctorunclear/
        >[/color]


        Comment

        • Lasse Reichstein Nielsen

          #5
          Re: how to hide scrollbars in netscape?

          "adrien" <hghjgh@sdgs.fb > writes:
          [color=blue]
          > and i tried this too:
          >
          > sbar.style = "overflow: hidden";
          >
          > now i get the error: "setting a property that has only a getter"[/color]

          It's
          sbar.style.over flow="hidden";
          /L
          --
          Lasse Reichstein Nielsen - lrn@hotpop.com
          Art D'HTML: <URL:http://www.infimum.dk/HTML/randomArtSplit. html>
          'Faith without judgement merely degrades the spirit divine.'

          Comment

          • Grant Wagner

            #6
            Re: how to hide scrollbars in netscape?

            Your original function was assigning document.onmous emove=test; inside the
            event handler, so it was never called. Here is a version that provides the
            coordinates on the status bar (so you can see stuff happening) and that
            provides the alerts you want. It does not, however, hide the scrollbars. As
            has been pointed out a couple of times already, you can not remove the
            scrollbars on an existing window in the default security environment. And
            even with the proper security, Mozilla can be configured to defeat your
            attempt to hide the scrollbars.

            var limit = document.body.c lientWidth * 0.9;

            function test(e) {
            var usermouse = e.screenX;
            var sbar = document.getEle mentById("bod") ;
            // watch the values to ensure this event handler is executing
            window.status = usermouse + ":" + limit;
            if (usermouse >= limit) {
            sbar.style.over flow = "hidden";
            alert("you cannot reach the vertical scrollbar");
            } else {
            sbar.style.over flow = "visible";
            }
            }
            document.onmous emove = test;

            adrien wrote:
            [color=blue]
            > thanks, that's right, i changed but ....
            >
            > it still not working: i get the alert, no error anymore, but the bars are
            > sill visible ...
            >
            > "Lasse Reichstein Nielsen" <lrn@hotpop.com > wrote in message
            > news:y8yph8l3.f sf@hotpop.com.. .[color=green]
            > > "adrien" <hghjgh@sdgs.fb > writes:
            > >[color=darkred]
            > > > and i tried this too:
            > > >
            > > > sbar.style = "overflow: hidden";
            > > >
            > > > now i get the error: "setting a property that has only a getter"[/color]
            > >
            > > It's
            > > sbar.style.over flow="hidden";
            > > /L[/color][/color]

            --
            | Grant Wagner <gwagner@agrico reunited.com>

            * Client-side Javascript and Netscape 4 DOM Reference available at:
            *


            * Internet Explorer DOM Reference available at:
            *
            http://msdn.microsoft.com/workshop/a...ence_entry.asp

            * Netscape 6/7 DOM Reference available at:
            * http://www.mozilla.org/docs/dom/domref/
            * Tips for upgrading JavaScript for Netscape 6/7 and Mozilla
            * http://www.mozilla.org/docs/web-deve...upgrade_2.html


            Comment

            • Carl Woffenden

              #7
              Re: how to hide scrollbars in netscape?

              DU wrote:
              [color=blue]
              > The challenge and question still remains: why would you want to remove
              > the scrollbars? A specific case still has not been explicited.[/color]

              Lets say I'm writing a scrolling shoot 'em up for a browser. I could
              just move the scrolling section by setting the top or left properties of
              a containing element, but that would be very slow on older machines, so
              a better way to do this would be using an IFRAME with the scrollbars
              turned off.

              Carl.

              Comment

              Working...