Received: from mailman by lists.gnu.org with archive (Exim 4.43) id 1Mdh6U-0006SU-24 for mharc-grub-devel@gnu.org; Wed, 19 Aug 2009 05:05:10 -0400 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1Mdh6S-0006RS-Hs for grub-devel@gnu.org; Wed, 19 Aug 2009 05:05:08 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1Mdh6N-0006MC-MK for grub-devel@gnu.org; Wed, 19 Aug 2009 05:05:07 -0400 Received: from [199.232.76.173] (port=33867 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Mdh6N-0006Ln-CV for grub-devel@gnu.org; Wed, 19 Aug 2009 05:05:03 -0400 Received: from rv-out-0708.google.com ([209.85.198.249]:43762) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1Mdh6M-0003Ts-P6 for grub-devel@gnu.org; Wed, 19 Aug 2009 05:05:02 -0400 Received: by rv-out-0708.google.com with SMTP id f25so1699091rvb.6 for ; Wed, 19 Aug 2009 02:05:01 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:date:message-id:subject :from:to:content-type:content-transfer-encoding; bh=nVKHmzjpXlTCVuqcLdS44fG9IvlcisaBx/HL8QcV/Po=; b=BkquGSj/qqsYuEHJ1sFNEyEnbVE+zHybcO8dvecUL3+Va9lp5gfrATKtQsDaFIhb1s qmDDsIbadyZoL8yJQI8gkMhzoV2iM/FI4+rSEoqdnCZU0S4q4kNRn1IBVaM7k7W2kiHS EZ8iMOYqivBRvP1LAE9IhtebUaAo0PBYrfd1I= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:date:message-id:subject:from:to:content-type :content-transfer-encoding; b=xh/py+y/bQTO8LWm7tW+ZU0ovIUYRhdyk/ISUrKBdOY14ObfyysYfgH6Ifl02V+Pah CO6i17EOR3mjJCC6zleKA7XXrLJkRAW+ZFwkfET/b8k7wbIOR2/67l1J4wMA8HAodc92 rhJE1NGTYFWA7UacA1XGTEWs3S8xyPawSkQtc= MIME-Version: 1.0 Received: by 10.141.48.3 with SMTP id a3mr3518371rvk.266.1250672701872; Wed, 19 Aug 2009 02:05:01 -0700 (PDT) Date: Wed, 19 Aug 2009 17:05:01 +0800 Message-ID: From: Bean To: The development of GRUB 2 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.6 (newer, 2) Subject: [RFC] Redesign of the menu system 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: Wed, 19 Aug 2009 09:05:08 -0000 Hi, Currently, the menu system is a little unorganized and difficult to extend. My goal of the redesign are: Modular Split code into small modules, each module implement a specific function, modules uses predefined interface to call each other. Extensible The core of the menu system is components, which can be extended easily. Components can be written in C or lua. Configurable The menu system can be configured easily by end users. The layout of screen can be configured with xml file, while the window styles is configured with css file. Interface are exported to C and lua so that you can configure the menu system dynamically. I suggest reorganize the menu system based on four layers: Display layer This is the lowest layer and have already been implemented. There are two display modules, one for text mode and one for graphics mode. Windows layer The windows layer build on top of display layer, it implement windows creation and manipulation. The windows layer uses css to configure the look and feel of windows, it also handle the difference between text mode and graphics mode so that components can be written regardless of the underlying display system. Component layer This is the core of menu system. This layer implements the logic of gui components, and rely on the windows layer or display layer for the actual rendering. Menu layer This is the lop layer. The layer is actually quite simple, it creates the components based on xml and link the various parts together. -- Bean gitgrub home: http://github.com/grub/grub/ my fork page: http://github.com/bean123/grub/