Received: from list by lists.gnu.org with archive (Exim 4.71) id 1UDE58-00031j-6c for mharc-grub-devel@gnu.org; Wed, 06 Mar 2013 08:08:30 -0500 Received: from eggs.gnu.org ([208.118.235.92]:53921) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UDE55-0002ww-2K for grub-devel@gnu.org; Wed, 06 Mar 2013 08:08:28 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UDE4z-0002wR-Uj for grub-devel@gnu.org; Wed, 06 Mar 2013 08:08:26 -0500 Received: from collab.rosalab.ru ([217.199.216.181]:51984) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UDE4z-0002vT-EZ for grub-devel@gnu.org; Wed, 06 Mar 2013 08:08:21 -0500 Received: from localhost (localhost.localdomain [127.0.0.1]) by collab.rosalab.ru (Postfix) with ESMTP id 4CA8F29C347 for ; Wed, 6 Mar 2013 17:08:18 +0400 (MSK) X-Virus-Scanned: amavisd-new at rosalab.ru Received: from collab.rosalab.ru ([127.0.0.1]) by localhost (collab.rosalab.ru [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id dAIwJ9QtNJ-Q for ; Wed, 6 Mar 2013 17:08:17 +0400 (MSK) Received: from icedphoenix.localnet (unknown [10.168.1.56]) by collab.rosalab.ru (Postfix) with ESMTPSA id A676829C32F for ; Wed, 6 Mar 2013 17:08:17 +0400 (MSK) From: Vladimir Testov To: grub-devel@gnu.org Subject: [PATCH] fixed progress_bar highlight_style box displaying Date: Wed, 06 Mar 2013 17:08:16 +0400 Message-ID: <272517394.NKOXnIMaqQ@icedphoenix> User-Agent: KMail/4.9.4 (Linux/3.5.0-23-generic; KDE/4.9.4; x86_64; ; ) MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="nextPart4106477.uS0jrkTO8I" Content-Transfer-Encoding: 7Bit X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-Received-From: 217.199.216.181 X-BeenThere: grub-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list Reply-To: The development of GNU GRUB List-Id: The development of GNU GRUB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 06 Mar 2013 13:08:28 -0000 This is a multi-part message in MIME format. --nextPart4106477.uS0jrkTO8I Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" In current state we could not correctly use styled box for highlight_style. We could set only center slice for highlight_style. Otherwise highlighted area won't be correctly displayed. Patch included. -- With best regards, _______________________________ Vladimir Testov, ROSA Laboratory. www.rosalab.ru --nextPart4106477.uS0jrkTO8I Content-Disposition: attachment; filename="grub-2.00-fix-progress-bar-highligh.patch" Content-Transfer-Encoding: 7Bit Content-Type: text/x-patch; charset="UTF-8"; name="grub-2.00-fix-progress-bar-highligh.patch" diff -Naur grub-2.00/grub-core/gfxmenu/gui_progress_bar.c grub-new/grub-core/gfxmenu/gui_progress_bar.c --- grub-2.00/grub-core/gfxmenu/gui_progress_bar.c 2012-03-10 22:37:48.000000000 +0400 +++ grub-new/grub-core/gfxmenu/gui_progress_bar.c 2013-03-06 16:55:17.444044638 +0400 @@ -139,6 +139,12 @@ int bar_b_pad = bar->get_bottom_pad (bar); int bar_h_pad = bar_l_pad + bar_r_pad; int bar_v_pad = bar_t_pad + bar_b_pad; + int hl_l_pad = hl->get_left_pad (hl); + int hl_r_pad = hl->get_right_pad (hl); + int hl_t_pad = hl->get_top_pad (hl); + int hl_b_pad = hl->get_bottom_pad (hl); + int hl_h_pad = hl_l_pad + hl_r_pad; + int hl_v_pad = hl_t_pad + hl_b_pad; int tracklen = w - bar_h_pad; int trackheight = h - bar_v_pad; int barwidth; @@ -148,7 +154,7 @@ barwidth = (tracklen * (self->value - self->start) / (self->end - self->start)); - hl->set_content_size (hl, barwidth, h - bar_v_pad); + hl->set_content_size (hl, barwidth - hl_h_pad, h - bar_v_pad - hl_v_pad); bar->draw (bar, 0, 0); hl->draw (hl, bar_l_pad, bar_t_pad); --nextPart4106477.uS0jrkTO8I--