Loading ...
Sorry, an error occurred while loading the content.

treeview wrapper

Expand Messages
  • kindom_2006
    Hi list, I have what should be a pretty simple request. I have tree view, what I want is a box that wraps around it fairly tightly but will expand it s width
    Message 1 of 4 , May 28, 2007
    • 0 Attachment
      Hi list,

      I have what should be a pretty simple request.

      I have tree view, what I want is a box that wraps around it fairly
      tightly but will expand it's width if subnodes "stretch" it.

      I can use the css:

      div#tree { border:1px solid #000; background:#de3;
      }

      However this expands to the full horizontal space, meaning a lot of
      empty space in the box, particularly when closed.

      So I changed it to:

      div#tree { border:1px solid #000; background:#de3; width:120px;
      min-width:120px;
      }

      which looks good with my unexpanded tree, but expansion doesn't make
      this div get wider :(

      I tried working with the root's child node, using:

      div#ygtvc0 { border:1px solid #000; background:#3de;
      }
      div#ygtvc0 { border:1px solid #000; background:#3de; width:120px;
      min-width:120px;
      }

      and got a similar lack of results.

      Any ideas?

      Jeff
    • kindom_2006
      Solved my own problem guys. For those that care: div#tree { position:absolute; width:auto; } This draws the box where I position it, but also minimizes the
      Message 2 of 4 , May 29, 2007
      • 0 Attachment
        Solved my own problem guys.

        For those that care:

        div#tree { position:absolute; width:auto;
        }

        This draws the box where I position it, but also minimizes the size of
        the box to just what's needed to contain the tree.

        Which makes my overall tree selection widget look an awful lot like a
        select box widget.

        happy clients!!

        :)


        --- In ydn-javascript@yahoogroups.com, "kindom_2006" <kindom_2006@...>
        wrote:
        >
        > Hi list,
        >
        > I have what should be a pretty simple request.
        >
        > I have tree view, what I want is a box that wraps around it fairly
        > tightly but will expand it's width if subnodes "stretch" it.
        >
        > I can use the css:
        >
        > div#tree { border:1px solid #000; background:#de3;
        > }
        >
        > However this expands to the full horizontal space, meaning a lot of
        > empty space in the box, particularly when closed.
        >
        > So I changed it to:
        >
        > div#tree { border:1px solid #000; background:#de3; width:120px;
        > min-width:120px;
        > }
        >
        > which looks good with my unexpanded tree, but expansion doesn't make
        > this div get wider :(
        >
        > I tried working with the root's child node, using:
        >
        > div#ygtvc0 { border:1px solid #000; background:#3de;
        > }
        > div#ygtvc0 { border:1px solid #000; background:#3de; width:120px;
        > min-width:120px;
        > }
        >
        > and got a similar lack of results.
        >
        > Any ideas?
        >
        > Jeff
        >
      • kindom_2006
        Argh... the problem rears its head again for IE6. (why won t the world upgrade???) Anyway, as it seems no one else is vocally concerned, I ll post an update
        Message 3 of 4 , May 30, 2007
        • 0 Attachment
          Argh...

          the problem rears its head again for IE6. (why won't the world
          upgrade???)

          Anyway, as it seems no one else is vocally concerned, I'll post an
          update when I solve it for ie6.

          Jeff

          --- In ydn-javascript@yahoogroups.com, "kindom_2006" <kindom_2006@...>
          wrote:
          >
          > Solved my own problem guys.
          >
          > For those that care:
          >
          > div#tree { position:absolute; width:auto;
          > }
          >
          > This draws the box where I position it, but also minimizes the size of
          > the box to just what's needed to contain the tree.
          >
          > Which makes my overall tree selection widget look an awful lot like a
          > select box widget.
          >
          > happy clients!!
          >
          > :)
          >
          >
          > --- In ydn-javascript@yahoogroups.com, "kindom_2006" <kindom_2006@>
          > wrote:
          > >
          > > Hi list,
          > >
          > > I have what should be a pretty simple request.
          > >
          > > I have tree view, what I want is a box that wraps around it fairly
          > > tightly but will expand it's width if subnodes "stretch" it.
          > >
          > > I can use the css:
          > >
          > > div#tree { border:1px solid #000; background:#de3;
          > > }
          > >
          > > However this expands to the full horizontal space, meaning a lot of
          > > empty space in the box, particularly when closed.
          > >
          > > So I changed it to:
          > >
          > > div#tree { border:1px solid #000; background:#de3; width:120px;
          > > min-width:120px;
          > > }
          > >
          > > which looks good with my unexpanded tree, but expansion doesn't make
          > > this div get wider :(
          > >
          > > I tried working with the root's child node, using:
          > >
          > > div#ygtvc0 { border:1px solid #000; background:#3de;
          > > }
          > > div#ygtvc0 { border:1px solid #000; background:#3de; width:120px;
          > > min-width:120px;
          > > }
          > >
          > > and got a similar lack of results.
          > >
          > > Any ideas?
          > >
          > > Jeff
          > >
          >
        • kindom_2006
          I sort-of solved it. I picked a number with my designer and hard-coded the width to that using: _width:193px; for ie6 only. Jeff
          Message 4 of 4 , May 31, 2007
          • 0 Attachment
            I sort-of solved it.

            I picked a number with my designer and hard-coded the width to that using:

            _width:193px; for ie6 only.

            Jeff

            --- In ydn-javascript@yahoogroups.com, "kindom_2006" <kindom_2006@...>
            wrote:
            >
            > Argh...
            >
            > the problem rears its head again for IE6. (why won't the world
            > upgrade???)
            >
            > Anyway, as it seems no one else is vocally concerned, I'll post an
            > update when I solve it for ie6.
            >
            > Jeff
            >
            > --- In ydn-javascript@yahoogroups.com, "kindom_2006" <kindom_2006@>
            > wrote:
            > >
            > > Solved my own problem guys.
            > >
            > > For those that care:
            > >
            > > div#tree { position:absolute; width:auto;
            > > }
            > >
            > > This draws the box where I position it, but also minimizes the size of
            > > the box to just what's needed to contain the tree.
            > >
            > > Which makes my overall tree selection widget look an awful lot like a
            > > select box widget.
            > >
            > > happy clients!!
            > >
            > > :)
            > >
            > >
            > > --- In ydn-javascript@yahoogroups.com, "kindom_2006" <kindom_2006@>
            > > wrote:
            > > >
            > > > Hi list,
            > > >
            > > > I have what should be a pretty simple request.
            > > >
            > > > I have tree view, what I want is a box that wraps around it fairly
            > > > tightly but will expand it's width if subnodes "stretch" it.
            > > >
            > > > I can use the css:
            > > >
            > > > div#tree { border:1px solid #000; background:#de3;
            > > > }
            > > >
            > > > However this expands to the full horizontal space, meaning a lot of
            > > > empty space in the box, particularly when closed.
            > > >
            > > > So I changed it to:
            > > >
            > > > div#tree { border:1px solid #000; background:#de3; width:120px;
            > > > min-width:120px;
            > > > }
            > > >
            > > > which looks good with my unexpanded tree, but expansion doesn't make
            > > > this div get wider :(
            > > >
            > > > I tried working with the root's child node, using:
            > > >
            > > > div#ygtvc0 { border:1px solid #000; background:#3de;
            > > > }
            > > > div#ygtvc0 { border:1px solid #000; background:#3de; width:120px;
            > > > min-width:120px;
            > > > }
            > > >
            > > > and got a similar lack of results.
            > > >
            > > > Any ideas?
            > > >
            > > > Jeff
            > > >
            > >
            >
          Your message has been successfully submitted and would be delivered to recipients shortly.