From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: 2QdxY4RzWzUUiLuE@potatochowder.com Newsgroups: gmane.emacs.help Subject: Re: displaying missing glyphs Date: Mon, 12 Apr 2021 10:49:52 -0700 Message-ID: References: <86mtu72zc6.fsf@x201.butler.org> <87pmz2ux0k.fsf@eder.anydns.info> <86y2dn1ldz.fsf@x201.butler.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="12083"; 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 Mon Apr 12 19:51:45 2021 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 1lW0iu-00033J-IY for geh-help-gnu-emacs@m.gmane-mx.org; Mon, 12 Apr 2021 19:51:44 +0200 Original-Received: from localhost ([::1]:46264 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lW0it-0002EJ-GK for geh-help-gnu-emacs@m.gmane-mx.org; Mon, 12 Apr 2021 13:51:43 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:57262) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from <2QdxY4RzWzUUiLuE@potatochowder.com>) id 1lW0hK-0002De-Lb for help-gnu-emacs@gnu.org; Mon, 12 Apr 2021 13:50:06 -0400 Original-Received: from www458.your-server.de ([136.243.165.62]:50288) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from <2QdxY4RzWzUUiLuE@potatochowder.com>) id 1lW0hH-0003cb-D0 for help-gnu-emacs@gnu.org; Mon, 12 Apr 2021 13:50:06 -0400 Original-Received: from sslproxy03.your-server.de ([88.198.220.132]) by www458.your-server.de with esmtpsa (TLSv1.3:TLS_AES_256_GCM_SHA384:256) (Exim 4.92.3) (envelope-from <2QdxY4RzWzUUiLuE@potatochowder.com>) id 1lW0hA-0004Y5-Kj for help-gnu-emacs@gnu.org; Mon, 12 Apr 2021 19:49:56 +0200 Original-Received: from [47.44.249.130] (helo=localhost) by sslproxy03.your-server.de with esmtpsa (TLSv1.3:TLS_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from <2QdxY4RzWzUUiLuE@potatochowder.com>) id 1lW0h9-000D63-Ti for help-gnu-emacs@gnu.org; Mon, 12 Apr 2021 19:49:56 +0200 Mail-Followup-To: help-gnu-emacs@gnu.org Content-Disposition: inline In-Reply-To: <86y2dn1ldz.fsf@x201.butler.org> X-Authenticated-Sender: 2QdxY4RzWzUUiLuE@potatochowder.com X-Virus-Scanned: Clear (ClamAV 0.102.4/26138/Mon Apr 12 13:05:56 2021) Received-SPF: pass client-ip=136.243.165.62; envelope-from=2QdxY4RzWzUUiLuE@potatochowder.com; helo=www458.your-server.de X-Spam_score_int: -18 X-Spam_score: -1.9 X-Spam_bar: - X-Spam_report: (-1.9 / 5.0 requ) BAYES_00=-1.9, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.23 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" Xref: news.gmane.io gmane.emacs.help:128971 Archived-At: On 2021-04-12 at 12:08:08 -0500, Regarding "Re: displaying missing glyphs," Leo Butler wrote: > Andreas Eder writes: > > > On Fr 09 Apr 2021 at 11:32, Leo Butler wrote: > > > >> I use `emacs -nw` inside of screen inside of uxterm. Unfortunately, many > >> unicode glyphs are not displayed correctly (although they are if I > >> attach the screen session in gnome-terminal, for example). > >> > >> In emacs/elisp, how might I override the default empty box to display > >> something more informative? > > > > The problem is - most likely - a font that is not unicode capable. > > If you set uxterm to ise the same font as gnome-terminal then it should > > work. > > The same combination (uxterm, screen and emacs) works perfectly well > > here. > > Thanks for the suggestion. I have attached a marked-up screen shot of an > xterm (left) and gnome-terminal running `emacsclient -nw` and showing > the same buffer. You can see there is a noticeable clipping of some of > the characters in the xterm. > > According to lsof, gnome-terminal is using > > /usr/share/fonts/truetype/dejavu/DejaVuSansMono.ttf > > so the xterm has been run using > > xterm -fa 'DejaVuSansMono' -fs 9 > > (and all font-related options are commented out in ~/.Xdefaults). > > FWIW, this is on a debian testing system with XTERM_LOCALE=en_US.UTF-8. At startup time, both programs have to determine the size of a character cell. They do so by applying some algorithm to the font(s) involved (the maximum width of all glyphs? the average width of selected glyphs? something else?). Evidently, xterm's algorithm doesn't account for all the glyphs, and ends up clipping some of them, whereas gnome-terminal has a different algorithm. You clipped the xterm and gnome-terminal windows. Are they the same size? Does the gnome-terminal contain more pixels (because it accounts for the wider glyphs)?