From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Alan Mackenzie Newsgroups: gmane.emacs.bugs Subject: bug#20707: [PROPOSED PATCH] Use curved quoting in C-generated errors Date: Sat, 6 Jun 2015 20:50:23 +0000 Message-ID: <20150606205023.GA3862@acm.fritz.box> References: <556C81C4.3010107@cs.ucla.edu> <20150601171723.GB16298@acm.fritz.box> <556CA97C.8070807@cs.ucla.edu> <20150602115600.GA3468@acm.fritz.box> <556DCE36.9070505@cs.ucla.edu> <20150602170724.GA2567@acm.fritz.box> <20150602204423.GA2619@acm.fritz.box> <55707236.6060605@cs.ucla.edu> <20150606155445.GE3418@acm.fritz.box> <557337CD.60706@cs.ucla.edu> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: ger.gmane.org 1433623832 11516 80.91.229.3 (6 Jun 2015 20:50:32 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sat, 6 Jun 2015 20:50:32 +0000 (UTC) Cc: 20707@debbugs.gnu.org To: Paul Eggert Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Sat Jun 06 22:50:18 2015 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1Z1L2l-0004vl-Ol for geb-bug-gnu-emacs@m.gmane.org; Sat, 06 Jun 2015 22:50:16 +0200 Original-Received: from localhost ([::1]:52521 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Z1L2k-0001Ub-UO for geb-bug-gnu-emacs@m.gmane.org; Sat, 06 Jun 2015 16:50:14 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:56227) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Z1L2g-0001QZ-JS for bug-gnu-emacs@gnu.org; Sat, 06 Jun 2015 16:50:12 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Z1L2b-0000OF-Jb for bug-gnu-emacs@gnu.org; Sat, 06 Jun 2015 16:50:10 -0400 Original-Received: from debbugs.gnu.org ([140.186.70.43]:33543) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Z1L2b-0000Mc-H1 for bug-gnu-emacs@gnu.org; Sat, 06 Jun 2015 16:50:05 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.80) (envelope-from ) id 1Z1L2a-0000kt-Pj for bug-gnu-emacs@gnu.org; Sat, 06 Jun 2015 16:50:05 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Alan Mackenzie Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 06 Jun 2015 20:50:04 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 20707 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch Original-Received: via spool by 20707-submit@debbugs.gnu.org id=B20707.14336237992885 (code B ref 20707); Sat, 06 Jun 2015 20:50:04 +0000 Original-Received: (at 20707) by debbugs.gnu.org; 6 Jun 2015 20:49:59 +0000 Original-Received: from localhost ([127.0.0.1]:43518 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1Z1L2U-0000kR-J5 for submit@debbugs.gnu.org; Sat, 06 Jun 2015 16:49:59 -0400 Original-Received: from mail.muc.de ([193.149.48.3]:19993) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1Z1L2R-0000kH-B9 for 20707@debbugs.gnu.org; Sat, 06 Jun 2015 16:49:56 -0400 Original-Received: (qmail 22525 invoked by uid 3782); 6 Jun 2015 20:49:53 -0000 Original-Received: from acm.muc.de (p548A5F44.dip0.t-ipconnect.de [84.138.95.68]) by colin.muc.de (tmda-ofmipd) with ESMTP; Sat, 06 Jun 2015 22:49:52 +0200 Original-Received: (qmail 4403 invoked by uid 1000); 6 Jun 2015 20:50:23 -0000 Content-Disposition: inline In-Reply-To: <557337CD.60706@cs.ucla.edu> User-Agent: Mutt/1.5.23 (2014-03-12) X-Delivery-Agent: TMDA/1.1.12 (Macallan) X-Primary-Address: acm@muc.de X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x X-Received-From: 140.186.70.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:103678 Archived-At: Hello, Paul. On Sat, Jun 06, 2015 at 11:11:25AM -0700, Paul Eggert wrote: > Alan Mackenzie wrote: [ .... ] > > Linux consoles are not rare > Well, that depends on one's definition of "rare" :-), ... If you were to regard the Linux console as too rare to be worth supporting, you'd effectively be saying that Emacs was now only supported within GUIs. > ... but even assuming they're common, curved quotes work on Linux > consoles, either by default (as on Fedora) or by configuration (needed > on Arch). All we need to do is to set you up. No. You need to make sure that _everybody_ on a non-unicode terminal is set up. After all, you are making a drastic change to the software. Up till now, all messages output have been ASCII (with the exception of user supplied characters and in some other rare instances such as outputting `sentence-end'). You are now changing the character set to UTF-8. At the very least, this warrants an extensive entry in NEWS. > > On the Linux console, there are a maximum of 256 glyphs which can be > > displayed > That's not a problem: we're only talking about two glyphs. and you > undoubtedly have two to spare (what are you using? CP437? I'll bet you > never use its U+263B BLACK SMILING FACE ...). I'm using lat1-16. Somehow, I'm sure I can find four (not two - there's the curly double quotes, too) glyphs to sacrifice. > > the two varieties of quotes are mapped > > to the same glyphs in my consolefont. > I assume this is because you're running bleeding-edge Emacs and have told it > that you're in an 8-bit environment that can't display curved quotes. No. My environment is set up as UTF-8. It's lat1-16 that maps the two characters to the same glyph, something I wasn't aware of until the last few days. > This is what commit 496bfe74990d6601d3584cb900643aa77d7b7a78 was about > (Bug#20545). The idea is that ordinary users in obsolescent locales > will just see straight apostrophes instead of curved quotes, which is > good enough for them. I don't have a straight apostrophe. :-) I haven't looked at that change in any detail, but I have a question: does the code test the output display setup to decide what sort of quotes to output (best), or is it up to some user option (middling) or is it hard coded (worst)? > But you're not an ordinary user: you're a developer, and would prefer > to see the the various kinds of quotes when you're writing error > messages and the like. So it'd be nice to get that to work for you. I've an idea that Richard uses a Linux terminal, too, but I'm not sure. > > But it will not work well on a console, even with the most recent Emacs. > Sure it will. It works fine. I just tried it on my Linux console > (Ubuntu 15.04). All you have to do is configure your fonts. This is > not too much to ask of an Emacs developer. Of course not, but could it be too much to ask of an Emacs user? > We should not have to contort Emacs source code merely to make it fit > into the character set of a circa-1981 IBM PC. > So how about trying a font that works? You're running Arch Linux, .... Gentoo, actually, and just to pre-empt RMS, we should say GNU/Linux. ;-) > .... and an 8-year-old post in the Arch Linux forums > says that > the Debian Lat15-Terminus16 works and looks nice on Arch Linux. I just > tried this font on Ubuntu 15.04 and it worked for me too, and displayed > curved quotes well. Please give it a try. You can use the attached > file (a copy of Ubuntu 15.04 > /usr/share/consolefonts/Lat15-Terminus16.psf.gz), and check out its > curved quotes. I don't think that's the font for me. It has one-pixel thick spidery characters, rather than the two-pixel thick ones the default fonts have. I find its @ difficult to make out, and perhaps most critically, there isn't a big enough difference between ( and { or between ) and }. Its apostrophe is a vertical line rather than a top right to bottom left sloping character, and I find its curly single quotes too indistinct, each of them being a mere 3 pixels. Perhaps most seriously, it's missing an ffdf "character not found" character. Other than that, it's not too bad. It at least gives another idea of which characters are worth including in the 256 character list. -- Alan Mackenzie (Nuremberg, Germany).