GNU bug report logs - #45917
[PATCH] Use big brackets in Calc in big mode

Previous Next

Package: emacs;

Reported by: Mattias Engdegård <mattiase <at> acm.org>

Date: Sat, 16 Jan 2021 17:11:01 UTC

Severity: normal

Tags: patch

Done: Mattias Engdegård <mattiase <at> acm.org>

Bug is archived. No further changes may be made.

To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 45917 in the body.
You can then email your comments to 45917 AT debbugs.gnu.org in the normal way.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to bug-gnu-emacs <at> gnu.org:
bug#45917; Package emacs. (Sat, 16 Jan 2021 17:11:01 GMT) Full text and rfc822 format available.

Acknowledgement sent to Mattias Engdegård <mattiase <at> acm.org>:
New bug report received and forwarded. Copy sent to bug-gnu-emacs <at> gnu.org. (Sat, 16 Jan 2021 17:11:02 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Mattias Engdegård <mattiase <at> acm.org>
To: bug-gnu-emacs <at> gnu.org
Subject: [PATCH] Use big brackets in Calc in big mode
Date: Sat, 16 Jan 2021 18:10:31 +0100
[Message part 1 (text/plain, inline)]
The attached patch makes Calc use big brackets in Big mode when the Unicode characters are available. This makes for prettier display which is sort of the point of using Big mode. It follows previous use of Unicode characters for square root and integral signs.

The code supports big versions of round, square and curly brackets. Big square brackets are currently only used for intervals and curly ones not at all (maybe they could be put to use for Stirling numbers of the second kind).

Matrices do not use big brackets but they probably should since it is standard mathematical notation.

As far as I can tell the only reasons for not applying this would be that it is common with fonts or terminals where this doesn't look good, or that the resulting formula isn't recognised by the embedded-mode parser (which is already the case with several other constructs).

[0001-Calc-use-big-Unicode-brackets-in-Big-mode-when-avail.patch (application/octet-stream, attachment)]
[Message part 3 (text/plain, inline)]


Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#45917; Package emacs. (Tue, 19 Jan 2021 05:38:01 GMT) Full text and rfc822 format available.

Message #8 received at 45917 <at> debbugs.gnu.org (full text, mbox):

From: Lars Ingebrigtsen <larsi <at> gnus.org>
To: Mattias Engdegård <mattiase <at> acm.org>
Cc: 45917 <at> debbugs.gnu.org
Subject: Re: bug#45917: [PATCH] Use big brackets in Calc in big mode
Date: Tue, 19 Jan 2021 06:37:19 +0100
Mattias Engdegård <mattiase <at> acm.org> writes:

> The attached patch makes Calc use big brackets in Big mode when the
> Unicode characters are available. This makes for prettier display
> which is sort of the point of using Big mode. It follows previous use
> of Unicode characters for square root and integral signs.

Makes sense to me, but...

> As far as I can tell the only reasons for not applying this would be
> that it is common with fonts or terminals where this doesn't look
> good,

... would it be possible to have a fallback if the display doesn't
support these characters?

> or that the resulting formula isn't recognised by the
> embedded-mode parser (which is already the case with several other
> constructs).

Yeah.  Or there could be a variable to allow the user to not use these
fancy brackets if this is important for them?

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#45917; Package emacs. (Tue, 19 Jan 2021 10:13:02 GMT) Full text and rfc822 format available.

Message #11 received at 45917 <at> debbugs.gnu.org (full text, mbox):

From: Mattias Engdegård <mattiase <at> acm.org>
To: Lars Ingebrigtsen <larsi <at> gnus.org>
Cc: 45917 <at> debbugs.gnu.org
Subject: Re: bug#45917: [PATCH] Use big brackets in Calc in big mode
Date: Tue, 19 Jan 2021 11:12:05 +0100
19 jan. 2021 kl. 06.37 skrev Lars Ingebrigtsen <larsi <at> gnus.org>:

> ... would it be possible to have a fallback if the display doesn't
> support these characters?

Yes, all Unicode characters are checked using char-displayable-p in the patch. However, some characters may be technically displayable but not very pretty, or have awkward metrics.

That said, the brackets look fine where I've tested them so it's probably not a serious concern.

> Yeah.  Or there could be a variable to allow the user to not use these
> fancy brackets if this is important for them?

Maybe, but Calc already has rather too many variables and should we have separate variables for all non-ASCII features then, like the square root sign?

We are just speculating here. I'd hoped for concrete cheerful evidence like 'looks terrible on my terminal', 'completely destroys embedded-mode for me'...





Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#45917; Package emacs. (Tue, 19 Jan 2021 15:46:02 GMT) Full text and rfc822 format available.

Message #14 received at 45917 <at> debbugs.gnu.org (full text, mbox):

From: Lars Ingebrigtsen <larsi <at> gnus.org>
To: Mattias Engdegård <mattiase <at> acm.org>
Cc: 45917 <at> debbugs.gnu.org
Subject: Re: bug#45917: [PATCH] Use big brackets in Calc in big mode
Date: Tue, 19 Jan 2021 16:45:01 +0100
Mattias Engdegård <mattiase <at> acm.org> writes:

> 19 jan. 2021 kl. 06.37 skrev Lars Ingebrigtsen <larsi <at> gnus.org>:
>
>> ... would it be possible to have a fallback if the display doesn't
>> support these characters?
>
> Yes, all Unicode characters are checked using char-displayable-p in
> the patch.

Duh.  I skimmed the patch, but I missed that bit...

> However, some characters may be technically displayable but
> not very pretty, or have awkward metrics.
>
> That said, the brackets look fine where I've tested them so it's
> probably not a serious concern.

Yup.

>> Yeah.  Or there could be a variable to allow the user to not use these
>> fancy brackets if this is important for them?
>
> Maybe, but Calc already has rather too many variables and should we
> have separate variables for all non-ASCII features then, like the
> square root sign?

Possibly?  But I see you've just pushed a fix for parsing the root
sign.  :-)

> We are just speculating here. I'd hoped for concrete cheerful evidence
> like 'looks terrible on my terminal', 'completely destroys
> embedded-mode for me'...

I'm guessing you won't get feedback like that until you push this
change.  :-)

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no




Reply sent to Mattias Engdegård <mattiase <at> acm.org>:
You have taken responsibility. (Tue, 19 Jan 2021 18:00:05 GMT) Full text and rfc822 format available.

Notification sent to Mattias Engdegård <mattiase <at> acm.org>:
bug acknowledged by developer. (Tue, 19 Jan 2021 18:00:05 GMT) Full text and rfc822 format available.

Message #19 received at 45917-done <at> debbugs.gnu.org (full text, mbox):

From: Mattias Engdegård <mattiase <at> acm.org>
To: Lars Ingebrigtsen <larsi <at> gnus.org>
Cc: 45917-done <at> debbugs.gnu.org
Subject: Re: bug#45917: [PATCH] Use big brackets in Calc in big mode
Date: Tue, 19 Jan 2021 18:59:20 +0100
19 jan. 2021 kl. 16.45 skrev Lars Ingebrigtsen <larsi <at> gnus.org>:

>> Maybe, but Calc already has rather too many variables and should we
>> have separate variables for all non-ASCII features then, like the
>> square root sign?
> 
> Possibly?  But I see you've just pushed a fix for parsing the root
> sign.  :-)

Yes, it turned out to be easy! Parsing big brackets is probably not quite as easy; I'm not even going to try.

>> We are just speculating here. I'd hoped for concrete cheerful evidence
>> like 'looks terrible on my terminal', 'completely destroys
>> embedded-mode for me'...
> 
> I'm guessing you won't get feedback like that until you push this
> change.  :-)

Right, now done. Let's see if anything turns up.





bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Wed, 17 Feb 2021 12:24:06 GMT) Full text and rfc822 format available.

This bug report was last modified 3 years and 62 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.