Date: Sun, 14 Oct 2001 13:42:42 +0200 From: Alexander Langer <alex@big.endian.de> To: The Anarcat <anarcat@anarcat.dyndns.org>, Libh <freebsd-libh@FreeBSD.ORG> Subject: Re: doc/hui Message-ID: <20011014134242.B79323@fump.kawo2.rwth-aachen.de> In-Reply-To: <20011013141605.E739@shall.anarcat.dyndns.org>; from anarcat@anarcat.dyndns.org on Sat, Oct 13, 2001 at 02:16:05PM -0400 References: <20011013130619.C739@shall.anarcat.dyndns.org> <20011013194100.A77141@fump.kawo2.rwth-aachen.de> <20011013141605.E739@shall.anarcat.dyndns.org>
next in thread | previous in thread | raw e-mail | index | archive | help
Thus spake The Anarcat (anarcat@anarcat.dyndns.org): > > Yes, boxes have been removed by me about one year ago. > Have they been replaced by "containers"? Exactly > > > the Y dimension shrinks. Not x!!! Why? And what does the -1 *do* > > > exactly? And what are the units for these dimensions??? > > -1 has a special meaning if you don't you free placement (=3D=3D arrang= ing) > > of widgets. > you=3D=3Duse? :) Heh, yes. > > Arranging means, it raises the sub-widgets to max. possible size, > > giving all sub-widgets the same width/height (depending on > > if it is arranging horizontally or vertically). > Ok. How is that selected? $<somegroupwidget> arrange "free" / "horizontal" / "vertical" Groupwidget is either a DialogWidget or a WindowWidget or a ContainerWidget. GroupWidgets can contain ContainerWidgets as well. > > Now, if you for example want a fixed size of 2 for one widget, > > but the others shall be arranged automatically (you can > > still use "free" arranging and do everything manually...), > > use -1. > Now wait a minute... There are 2 "arrangement" here. "free" and > "arranging", right? > You said: "free placement (=3D=3D arranging) of widgets" and "Arranging > means it raises the sub-widgets to max. possible size" but also: "use > "free" arranging and do everything manually". > "Free arranging", is that "manual" or "automatic"? Sorry. There is only "free", "horizontal" and "vertical". "free" is the manual way. You might want to test out the other two to see the effect, ecspecially when you resize the windowwidget. > > So, if you want a fixed height of 2 for example, use > > resize "-1 2" =20 > > (resize "width height"). > But the fun thing is that this will make: "fixed width of 2", and > "height max". No, this makes "fixed height of 2" > This should be: > if (to.width() <=3D -1 && to.height() <=3D -1) > return; Probably, though it has the same effect already now. > > mFixedSize =3D (to.width() < 0) ? to.height() : to.widt= h(); > interesting.. is this where the "switch" would take place (ie y modifies > x and so on)? Yes. And this is used in GroupWidget::arrange() BTW, this is the bug. > Again, I do not thing so. Modifying the first param changes y: > set cmd_cont [$cons_w container "container"] What happens before? What do you do with $cons_w and what is $cons_w? > $cmd_cont resize "3 -1" > # the container is now of a given vertical size > $cmd_cont resize "5 -1" > # the container is now of a bigger vertical size :) The above check doesn't test for the correctness of the non-"-1"-value. It just sets the mFixedSize in any case to the value that is not -1. This is why you get a bigger vertical size. Can I have the whole code maybe? Look like you are using a vertical arrangement. I should fix this, btw. It's on my TODO now. Alex To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-libh" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20011014134242.B79323>