Received: from mailman by lists.gnu.org with archive (Exim 4.43) id 1MwEgC-0004TT-4j for mharc-grub-devel@gnu.org; Fri, 09 Oct 2009 08:34:40 -0400 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1MwEgA-0004Rx-GO for grub-devel@gnu.org; Fri, 09 Oct 2009 08:34:38 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1MwEg5-0004MI-OE for grub-devel@gnu.org; Fri, 09 Oct 2009 08:34:38 -0400 Received: from [199.232.76.173] (port=57198 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1MwEg5-0004Lw-GM for grub-devel@gnu.org; Fri, 09 Oct 2009 08:34:33 -0400 Received: from mail-pz0-f181.google.com ([209.85.222.181]:34450) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1MwEg4-0006gz-Vx for grub-devel@gnu.org; Fri, 09 Oct 2009 08:34:33 -0400 Received: by pzk11 with SMTP id 11so5092522pzk.14 for ; Fri, 09 Oct 2009 05:34:31 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:in-reply-to:references :date:message-id:subject:from:to:content-type :content-transfer-encoding; bh=ebc8rVQ/WNPYNi0QasnpyIfA8Fdil97l0HlXZMALgi8=; b=nC861Xy8j40B/ZMmoQ5tkaW72Fi4iLdAo1hfUhGbSMVIY4bhpRf/EyjFrBVxWPTQxF +6PxxZGN+aJ6n09MRAo6VKkmxbwcpQUOHOGF2bpgoNKo1An3Ful/ibDnLz+qkhkLlfug VhsC/fQBK3R14VTp/d+hzEI91dV1f324YcDMA= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type:content-transfer-encoding; b=RZhixHHsRbgp2fUUnCgoCcM/hE9igyRsbaFYNV/hfibhgFYlobUTbbrj+O2LF97oVm P2/Bpx8r2VZlZrWyNc0iRTgyKVPoW4EvNWZwGzQuYxAqmU/n3MFhaYnP/Nqvkdxp1EAG 7pAcZ5WUhBq96KP2sF5oOOsiEWEEhy/JeWcS8= MIME-Version: 1.0 Received: by 10.141.43.9 with SMTP id v9mr248887rvj.75.1255091671811; Fri, 09 Oct 2009 05:34:31 -0700 (PDT) In-Reply-To: References: Date: Fri, 9 Oct 2009 20:34:31 +0800 Message-ID: From: Bean To: The development of GRUB 2 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.6 (newer, 2) Subject: Re: [GITGRUB] New menu interface (implementation) X-BeenThere: grub-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: The development of GRUB 2 List-Id: The development of GRUB 2 List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 09 Oct 2009 12:34:38 -0000 On Fri, Oct 9, 2009 at 7:48 PM, Michal Suchanek wrote= : > 2009/10/9 Bean : >> On Fri, Oct 9, 2009 at 5:46 AM, Michal Suchanek wr= ote: >>> 2009/10/8 Bean : >>>> On Thu, Oct 8, 2009 at 7:18 PM, Michal Suchanek = wrote: >>>>>> 2, You should use far position as you want to extend the widget at t= he >>>>>> far side (top). >>>>> >>>>> This dependency is a problem. The rules for creating a working layout >>>>> are then complicated and hard to understand. >>>>> >>>>> Also I have no idea why I should set position on the screen, it is >>>>> never positioned. >>>> >>>> Hi, >>>> >>>> For example, if parent width=3D10, two children, width=3D4, then the >>>> extend property decide how to assign the extra 2 space: >>>> >>>> extend=3Dfirst, space is added to first widget, which is 6,4 >>>> extend=3Dall, space is distributed to alls widget, which is 5,5 >>>> extend=3Dlast, space is added to last widget, which is 4,6 >>> >>> This should not be necessary. The default is to wrap the children with >>> any spacing the children specify. =A0This should work nicely for layout= s >>> similar to the current gfxterm. >>> >>> If the panel is larger (because it is itself extended or fixed-width) >>> then children are packed at the start (which is determined by >>> direction). This should work nicely for buttons in a dialog box, for >>> example. If a dialog has two buttons they should be placed together, >>> placing one on each end can easily lead to situation when the user >>> notices only one of the buttons. >>> >>> If you want to explicitly control which children get the available >>> space then finer granularity is again achieved by setting properties >>> on the chidren. Any child that has the expand property will take a >>> share of the surplus space. If you want children to take space without >>> growing add another property which specifies that the space should be >>> taken without expanding the element. >> >> Hi, >> >> What if more than one children has the extend property, for example, >> how do we handle config like this: >> >> panel { >> =A0panel { halign=3D"extend" } >> =A0panel { } >> =A0panel { halign=3D"extend"} >> =A0panel { } >> } >> >> > > Then both get a share of the available space, obviously. It's similar > to your extend=3Dall but each child can opt to get a share of the extra > space individually. Hi, Ok, fine with me. --=20 Bean gitgrub home: http://github.com/grub/grub/ my fork page: http://github.com/bean123/grub/