innerWidth

Discussion in 'HTML' started by Tim Streater, Jul 29, 2012.

  1. Tim Streater

    Tim Streater Guest

    I have a frame, part of a frameset, whose width I would like to set and
    by doing so alter the overall window width too. The user may also do
    this by hand.

    I have the impression that, as long as I do *not* adjust the frame's
    innerWidth, then reading the frame's innerWidth later gives me a value
    that reflects the frame's actual width. So if the user manually makes
    the frame narrower, I would get a smaller innerWidth value.

    However, if I use JavaScript to set the innerWidth to some value (X,
    say), thereby making the frame narrower, then X is always what I'll get
    back when reading innerWidth, even if the user manually resizes the
    frame, making it wider or narrower.

    Is this expected behaviour for innerWidth? Would I be better off using
    resizeTo() instead?

    Thanks,

    --
    Tim

    "That excessive bail ought not to be required, nor excessive fines imposed,
    nor cruel and unusual punishments inflicted" -- Bill of Rights 1689
    Tim Streater, Jul 29, 2012
    #1
    1. Advertising

  2. On Sun, 29 Jul 2012 23:15:46 +0100, Tim Streater wrote:

    > Would I be better off using resizeTo() instead?


    Dunno. You'd be "better off" posting to a javascript ng.
    Allodoxaphobia, Jul 30, 2012
    #2
    1. Advertising

  3. Tim Streater

    Tim Streater Guest

    In article <>,
    Allodoxaphobia <> wrote:

    > On Sun, 29 Jul 2012 23:15:46 +0100, Tim Streater wrote:
    >
    > > Would I be better off using resizeTo() instead?

    >
    > Dunno. You'd be "better off" posting to a javascript ng.


    Why. innerWidth is part of the DOM, ISTM.

    --
    Tim

    "That excessive bail ought not to be required, nor excessive fines imposed,
    nor cruel and unusual punishments inflicted" -- Bill of Rights 1689
    Tim Streater, Jul 30, 2012
    #3
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.

Share This Page