From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.help Subject: Re: [Question] How to change the height of the box for unprintable glyphs? Date: Wed, 15 May 2024 21:27:18 +0300 Message-ID: <86msorj5h5.fsf@gnu.org> References: <6aad61b5057ea92af6fd5f9daef953bc@rodrigomorales.site> Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="37128"; mail-complaints-to="usenet@ciao.gmane.io" To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane-mx.org@gnu.org Wed May 15 20:27:58 2024 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1s7JM5-0009UI-GS for geh-help-gnu-emacs@m.gmane-mx.org; Wed, 15 May 2024 20:27:57 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1s7JLX-00056F-Ur; Wed, 15 May 2024 14:27:23 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1s7JLV-00055l-CS for help-gnu-emacs@gnu.org; Wed, 15 May 2024 14:27:21 -0400 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1s7JLV-0002d8-3e for help-gnu-emacs@gnu.org; Wed, 15 May 2024 14:27:21 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=sRv+t9+81/TJJYyice3i89FVd4LZAURG7YSqMD6IfvU=; b=OwZ8uTRVblTI k9oM0p3QorAT/QXK6pRjEG1oO2ogf7IdpbhueF5jnhTU7YjMM+vepPgg7OzeJGsdkQGewM2fY/+m0 Paicfuc/6eIk6RDjuFCqurX89khh7MdDBPrT5XsJ6fwOL7qKxwMnQv91mc11X9aDtCjGeMDQ+hynv BNoThTZa2w+huBUR30RcZXlmvoAho3/nK3zfdSEPolUFSJSaHRHdUFdRk86loIkq/edAZO3XrTAO2 saD/ftqHrvh6l8wAztdpEhZ67BT5yUlteHt9SdSLNxcYROcyyUzUoaC8HVPwLDvGiZnj2myJrT/It 3yDb7PSEbVzSZwmB1yv9Tw==; In-Reply-To: <6aad61b5057ea92af6fd5f9daef953bc@rodrigomorales.site> (message from Rodrigo Morales on Wed, 15 May 2024 12:37:43 -0500) X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.help:146759 Archived-At: > Date: Wed, 15 May 2024 12:37:43 -0500 > From: Rodrigo Morales > > Some days ago, I noticed that some lines in a =*terminal*= buffer were shown with a different height. This caused the tmux status bar when it is shown at the top to be shown out of the =*terminal*= buffer. This is undesired behavior. I learned that this happened because Emacs tries to display some characters using different fonts which might have different heights. For this reason, I started looking for a bitmap font which defines glyphs for all Unicode characters. Thus, by using a single font, the height of all lines would be the same. I found GNU Unifont. Side note: IMNSHO, Unifont is a very ugly font, so I don't recommend this solution. > Upon evaluation of the sexp, all characters in the buffer =a.txt= except characters in line 3 were shown using GNU Unifont, boxes with hexadecimal notation were shown in line 3. See screenshot in http://web.archive.org/web/20240515172349/http://0x0.st/XK5h.png > > The boxes shown in line 3 significantly increased the height of that line. =(line-pixel-height= returned 16 in line 1 and line 2, but it returned 37 in line 3. > > * The question > > How to reduce the height of the rectangle containing hexadecimal notation that Emacs uses to display characters for which no font was found? You can modify the face used for this display. It's called 'glyphless-char'; if you make it small enough, the box will become smaller as well, I think. But I think a better idea is to customize glyphless-char-display-control such that one of the other alternative displays is used for characters for which there's no font.