From unknown Fri Aug 15 20:24:11 2025 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-Mailer: MIME-tools 5.509 (Entity 5.509) Content-Type: text/plain; charset=utf-8 From: bug#44799 <44799@debbugs.gnu.org> To: bug#44799 <44799@debbugs.gnu.org> Subject: Status: 28.0.50; Calc: Meter not printed as \text in latex output Reply-To: bug#44799 <44799@debbugs.gnu.org> Date: Sat, 16 Aug 2025 03:24:11 +0000 retitle 44799 28.0.50; Calc: Meter not printed as \text in latex output reassign 44799 emacs submitter 44799 Michael Heerdegen severity 44799 normal thanks From debbugs-submit-bounces@debbugs.gnu.org Sun Nov 22 10:20:55 2020 Received: (at submit) by debbugs.gnu.org; 22 Nov 2020 15:20:55 +0000 Received: from localhost ([127.0.0.1]:48067 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kgrAd-000542-6U for submit@debbugs.gnu.org; Sun, 22 Nov 2020 10:20:55 -0500 Received: from lists.gnu.org ([209.51.188.17]:60264) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kgrAb-00053u-0E for submit@debbugs.gnu.org; Sun, 22 Nov 2020 10:20:53 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:52836) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kgrAa-00014I-ME for bug-gnu-emacs@gnu.org; Sun, 22 Nov 2020 10:20:52 -0500 Received: from mout.web.de ([217.72.192.78]:59331) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kgrAY-00065V-I1 for bug-gnu-emacs@gnu.org; Sun, 22 Nov 2020 10:20:52 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=web.de; s=dbaedf251592; t=1606058446; bh=1mVUMhhnxBu1ansOBtkJ+s8aecqvT5cWZ4fVwNmAwZQ=; h=X-UI-Sender-Class:From:To:Subject:Date; b=Zc44b7aUPC9eE8tqSqGitQ8dT57yIZUtx1oW4LIa/ssR//OTVpaESMZJydo2nKWQe k7cV723qcjt/fGoCknYnFhIUo9kXxXMbJizvcWYvLSmsOLwdl8MYa1szGaBLlvsJ7B 9jJouNLlR7NPJxewBGcVVn0OJ60p24c95b3q4/xE= X-UI-Sender-Class: c548c8c5-30a9-4db5-a2e7-cb6cb037b8f9 Received: from drachen.dragon ([94.218.219.247]) by smtp.web.de (mrweb105 [213.165.67.124]) with ESMTPSA (Nemesis) id 1MY5fb-1kkYzL2y6f-00YIZH for ; Sun, 22 Nov 2020 16:20:46 +0100 From: Michael Heerdegen To: bug-gnu-emacs@gnu.org Subject: 28.0.50; Calc: Meter not printed as \text in latex output Date: Sun, 22 Nov 2020 16:20:46 +0100 Message-ID: <87zh39to35.fsf@web.de> MIME-Version: 1.0 Content-Type: text/plain X-Provags-ID: V03:K1:yL8UiDaJYTd6Ow7OEpF3PjK3mUBvVQgWDlBSemPSPUe/D8Ayd3p iMPcyGIC1Q3qjXON2XMvtTlhEY75hwqgiVnC4Cn5BE9VI6j0zPd+GQI6piz44iKpBi9kqzE btXZP1t8M7Bjn39y6A+Y/bP2Pkq1G7JgqJ9qZpSNEzTUrDTqrRkATw48l9RUfrllN1rk4eb Hm5DsXqG35KDQHeTKGpLw== X-Spam-Flag: NO X-UI-Out-Filterresults: notjunk:1;V03:K0:2fTKb/vYG8U=:c270jJcQAqXqb3r1jv43mH Jof4pe0/8O7hc0GtClnAe1sGXZlkACuRd7+xTqUmF2hJHumhMSCGOtG9SfnhRWQVVGKZopiBB qFMCAcQLdz04tQ0DmrAd1soE9fqiwnhTzORpPqhcq0iBXLiHhtDPm/UP71oCXwhGElB+Hg/nV zfsKPXlaWW/GMFcNHjyq6Sp5qEucLers6SHDSwqJ3I01+eqxeJ4JcUChMCM9sM+EnT5icgDNs YOZ7IqRrzttilkYkMUaf5nyDoPgA/7g+jLIlbNCgwnDfnTt9dIzS079Vg7XILQebULPKygfFd 7eR4Xx8gAdIPiyjfb/HStgOotWaRcGsamq7X1CwdsLQ/Q3zOezo/V5DVUibgeinFhZuHJZuO/ q+bp8Cyfjxho/+q/RAtz7uo/otKYKM0H0lfcQKXvwqsbRT6SxIfZGGDXW+FnFbjh3OErLw5EB IsaBndwPwowcLj34v2OfHUJCaKL9vwqJ9IXq30pMp589OEau1xuJVJx/fm/ddafnKGNT6RpJ1 yj4lgHoLrSoC2WsSygRu3AE57EBEFlofhOvTO6h05D3RBFW1+CeSkS+Vw5c+V+Qk52IpF/VeF eYmgNXvWjjsC8Rwrqzd56+nkS+Uob/G2tH4aPOnIdq8foLROR3UtL36sTldh3GEAZllXmudJ2 1+YzeZCwPFegPM/m9Snj4e3c0B3JTMgwko7yDNpcCcbAryaLBUCS0CuTIwtoVbf5lCJyJJKFh 3EtYPawhUSMhXEu0xfHNlArDTyL9eiJsl7Y/kgTK7selD/fjd8GJzvLhtn9cMdgez54MXoRaf iP/1MG2c7KxTW6rNaZJ5g7TXExvc00cxTr/GMwelUwv+4LSb/TYC82Nkcy+a1lrMAbtH/UI/3 Dz3CK/0zIlg0tVArpKJucNNyd6lXlbVPRGyAxMMKY= Received-SPF: pass client-ip=217.72.192.78; envelope-from=michael_heerdegen@web.de; helo=mout.web.de X-Spam_score_int: -27 X-Spam_score: -2.8 X-Spam_bar: -- X-Spam_report: (-2.8 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_LOW=-0.7, RCVD_IN_MSPIKE_H2=-0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-Spam-Score: 0.1 (/) X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -2.4 (--) Hello, in Calc, C-u d L to switch to latex language with \text{} printed units. `min' for example is then printed "\text{min}" but (bug) Meter still "m". AFAIU, the printing code assumes that any unit has at least two characters, which is obviously not the case for some units. TIA, Michael. In GNU Emacs 28.0.50 (build 3, x86_64-pc-linux-gnu, GTK+ Version 3.24.23, cairo version 1.16.0) of 2020-11-22 built on drachen Repository revision: ce5458fe6eeb37df37119d04228ac7fcd5d39236 Repository branch: master Windowing system distributor 'The X.Org Foundation', version 11.0.12008000 System Description: Debian GNU/Linux bullseye/sid From debbugs-submit-bounces@debbugs.gnu.org Sun Nov 22 11:38:42 2020 Received: (at 44799) by debbugs.gnu.org; 22 Nov 2020 16:38:42 +0000 Received: from localhost ([127.0.0.1]:48140 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kgsNu-0000kp-5o for submit@debbugs.gnu.org; Sun, 22 Nov 2020 11:38:42 -0500 Received: from mail1435c50.megamailservers.eu ([91.136.14.35]:42618 helo=mail263c50.megamailservers.eu) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kgsNr-0000kT-P3 for 44799@debbugs.gnu.org; Sun, 22 Nov 2020 11:38:40 -0500 X-Authenticated-User: mattiase@bredband.net DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=megamailservers.eu; s=maildub; t=1606063111; bh=DEM1xdvoE9j8zJUK4yRtQQ7lYDq3iplAm7t00mopgrw=; h=From:Subject:Date:Cc:To:From; b=J4Z5lkysF013vmF0M4aLz67vTEXz0SZD03BAMVU0FhdW1T8dBXpAZSLYoGviur5Um W9tPSTeTSi6alSDdbX5RKMIcGuWQb2pebopEKK5v66b1iwPhVuihZS7JoQO79dbLx4 emLebcpGtJuzbEYD9n6N4BnHRyoYYsON8kte1gCg= Feedback-ID: mattiase@acm.or Received: from stanniol.lan (c-064ae655.032-75-73746f71.bbcust.telenor.se [85.230.74.6]) (authenticated bits=0) by mail263c50.megamailservers.eu (8.14.9/8.13.1) with ESMTP id 0AMGcSXs014340; Sun, 22 Nov 2020 16:38:30 +0000 From: =?utf-8?Q?Mattias_Engdeg=C3=A5rd?= Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: quoted-printable Mime-Version: 1.0 (Mac OS X Mail 12.4 \(3445.104.17\)) Subject: bug#44799: 28.0.50; Calc: Meter not printed as \text in latex output Message-Id: Date: Sun, 22 Nov 2020 17:38:28 +0100 To: Michael Heerdegen X-Mailer: Apple Mail (2.3445.104.17) X-CTCH-RefID: str=0001.0A782F18.5FBA9407.001F, ss=1, re=0.000, recu=0.000, reip=0.000, cl=1, cld=1, fgs=0 X-CTCH-VOD: Unknown X-CTCH-Spam: Unknown X-CTCH-Score: 0.000 X-CTCH-Rules: X-CTCH-Flags: 0 X-CTCH-ScoreCust: 0.000 X-CSC: 0 X-CHA: v=2.3 cv=WbZylHpX c=1 sm=1 tr=0 a=Ni+dBsiEfW2GqKMPYZim9A==:117 a=Ni+dBsiEfW2GqKMPYZim9A==:17 a=kj9zAlcOel0A:10 a=M51BFTxLslgA:10 a=SLQVzPF7ysr3sh7I1LoA:9 a=CjuIK1q_8ugA:10 X-Origin-Country: SE X-Spam-Score: 1.4 (+) X-Spam-Report: Spam detection software, running on the system "debbugs.gnu.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see the administrator of that system for details. Content preview: It seems to be a heuristic for distinguishing units from variables, both of which unfortunately have the same representation in Calc. We could make it more precise by looking in the unit table (and al [...] Content analysis details: (1.4 points, 10.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- 0.0 SPF_HELO_NONE SPF: HELO does not publish an SPF Record 0.0 URIBL_BLOCKED ADMINISTRATOR NOTICE: The query to URIBL was blocked. See http://wiki.apache.org/spamassassin/DnsBlocklists#dnsbl-block for more information. [URIs: megamailservers.eu] 1.0 SPF_SOFTFAIL SPF: sender does not match SPF record (softfail) 0.4 KHOP_HELO_FCRDNS Relay HELO differs from its IP's reverse DNS X-Debbugs-Envelope-To: 44799 Cc: 44799@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -0.0 (/) It seems to be a heuristic for distinguishing units from variables, both = of which unfortunately have the same representation in Calc. We could = make it more precise by looking in the unit table (and allow for = prefixes), but it would mean that a variable 'm' would always look like = a unit. I'm afraid I have no other good solution at hand. For that matter, shouldn't units use \mathrm{} rather than \text{} ? From debbugs-submit-bounces@debbugs.gnu.org Sun Nov 22 16:12:34 2020 Received: (at 44799) by debbugs.gnu.org; 22 Nov 2020 21:12:34 +0000 Received: from localhost ([127.0.0.1]:48429 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kgwew-0007f8-7y for submit@debbugs.gnu.org; Sun, 22 Nov 2020 16:12:34 -0500 Received: from mout.web.de ([212.227.17.12]:52515) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kgwet-0007et-Ar for 44799@debbugs.gnu.org; Sun, 22 Nov 2020 16:12:33 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=web.de; s=dbaedf251592; t=1606079531; bh=3yJaE/Qfxhas37Aw72F9p+vfptkmXHDW8o9xbR0PbkA=; h=X-UI-Sender-Class:From:To:Cc:Subject:References:Date:In-Reply-To; b=NR11RT65XGHdrelHcnoLfz2Ua8sXIdiCmYIsS3irlc6any+idkSJjY1dmX/1bHzjs OXNykSZ0/LxrucYDWfHoN8Wo4t/8a1qD5UXxTEaxY/SG+1Y2miwR8j5DmLeXx3nBId Q3EpKmKpEH1Vmmayq3yRDaUbH+MuM0gUnJvEmsxU= X-UI-Sender-Class: c548c8c5-30a9-4db5-a2e7-cb6cb037b8f9 Received: from drachen.dragon ([94.218.219.247]) by smtp.web.de (mrweb105 [213.165.67.124]) with ESMTPSA (Nemesis) id 1N30dT-1kFYWt3LB7-012wIE; Sun, 22 Nov 2020 22:12:10 +0100 From: Michael Heerdegen To: Mattias =?utf-8?Q?Engdeg=C3=A5rd?= Subject: Re: bug#44799: 28.0.50; Calc: Meter not printed as \text in latex output References: Date: Sun, 22 Nov 2020 22:12:09 +0100 In-Reply-To: ("Mattias =?utf-8?Q?Engdeg=C3=A5rd=22's?= message of "Sun, 22 Nov 2020 17:38:28 +0100") Message-ID: <87mtz9cd06.fsf@web.de> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Provags-ID: V03:K1:Tv+aBzItcaGqgGfV5kLhtZXM9YHJ7mkRB/WpppvmzSb7UMXCgdA 3MdfQ+fPQWxzrLBN6ZkW9rj0qFsvRV1kAWlFRmcis3UTr8/Irxb/5X+Vy8Y6grW/hX1gw+F Bk7Esjh/9A5EzajR7Ty1GN6L6slR8htXEMyvnIxf9MnHdLK2nQIFKeSeS3OTqQk8YaLwKZO jpi9E0/PafqD3g1wIuQMA== X-Spam-Flag: NO X-UI-Out-Filterresults: notjunk:1;V03:K0:mngemN9zGWw=:2c8RqnsfSSCLn2/lAnHGr4 5ABmbaE40BKXdsW4vm30Dtbe324MFWSukYPE3FwtvG28/nU/Hg6/2GYfAbcIrHp7duTc1fDJK 2B82ks2Unw3LAILYmO+En73s5aXt9gABQAQU0fSmCQnZa74DCAjWVvutjNpvvxPpNtq5Um+4q rACW2WqRUXGE+EOLTEYaC/vOS12uDm2rDEguLJegBQ6XhJiS6nENMDC0g/GaRxmsrnnyE7yJu vD7zNmApxW8m2bOjVbXt10+zUPU+vEhsV/o3p3SwUNSWHvYbRvebpI9WcygU7MG3gClfMXS4z c50wL8at8KUvd5mt+Z1BjDKb5jhO/E1NBeCWOZVG1TNYfLKQWm3Ddpjks79FOkijP0HLKy2GU OvasWrydXJ7sAohHhb/ecAPDg1Jc3o3dT0FONX8gvf9sYVBGl1DUKPAdnkXrv5MPr5IjPiDq0 DDUEIRCQGW6lrONofpGm4cbZDc7oV6hRhlbYHbxjXXr4/CycbZyqXPyKGe1tMCv68qcysgUu0 z/bmxq9freyL01Ng4u4Hw4RSwW91lWAQcxyLM71yZjUPBJ37jZCpNaeBEAJnruiDOHfKzS3f6 PNwdsCWUiDJ0yCxXXLl1pyAnZS7E1Winh+WJS0SK/dVmxfdr9UNPzlpLKWVgP8lqnJHnF670B uArdFQUoheWvH6Z9IPCnlaGYowbNHDRqaBOF7gpQu1TzP4Yr6eteU0L+5s9op2GSL6T+ZFSgu A7oZI95y37RjMyXp4BWAkjGGQ3W3PtXpO6od0lDODz9RS4UbkGrA7F6Kate9FIIQV/LFlwziA J41LfpaLY1YXB22fjeX3/0aXJndHZgUrIN7oY7KW1cES0Katna01hdcvhD6OWf5B0k7Invkg+ 7JMxHduWzcM8i+Un+IS0jdyh0ZDz+UEqMBHCux2xg= X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 44799 Cc: 44799@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) Mattias Engdeg=C3=A5rd writes: > It seems to be a heuristic for distinguishing units from variables, > both of which unfortunately have the same representation in Calc. We > could make it more precise by looking in the unit table (and allow for > prefixes), but it would mean that a variable 'm' would always look > like a unit. I'm afraid I have no other good solution at hand. Ah, so there can be a variable and a unit of the same name at the same time? I can s s a variable "m". Is it good to allow this? I mean it's good that meters is "m" as expected but if someone wants to use "m" as a variable in the same formula it necessarily gets ugly. > For that matter, shouldn't units use \mathrm{} rather than \text{} ? I dunno. latex language mode has several submodes (see `calc-latex-language'), but none of them uses that. BTW, do you know (Bug#30231) why allowed characters in units are restricted? Thanks, Michael. From debbugs-submit-bounces@debbugs.gnu.org Mon Nov 23 05:26:15 2020 Received: (at 44799) by debbugs.gnu.org; 23 Nov 2020 10:26:15 +0000 Received: from localhost ([127.0.0.1]:49152 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kh931-0006Sv-6u for submit@debbugs.gnu.org; Mon, 23 Nov 2020 05:26:15 -0500 Received: from mail1449c50.megamailservers.eu ([91.136.14.49]:57230 helo=mail265c50.megamailservers.eu) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kh92v-0006Sb-Ry for 44799@debbugs.gnu.org; Mon, 23 Nov 2020 05:26:14 -0500 X-Authenticated-User: mattiase@bredband.net DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=megamailservers.eu; s=maildub; t=1606127163; bh=nNZXrr+usaWHbReeFDfyDkC578ccxWdKm1atHKa8/hs=; h=Subject:From:In-Reply-To:Date:Cc:References:To:From; b=qzgH5bA1/2i219s0lAJTt48fRh1Yk0bK+1WCo2ZA5SPmLxd+nqqs/I84HNqyYxdT5 6h6d2uZyKCDlQ76uqT1xW9cwUq59DHcmDrFH0E3exCyv0ZnAZp3Fs4ODzmn12RZJmZ hlL8bmVialEyJ53nhzZN6m3OgfFiuGN1WrNQ0zqs= Feedback-ID: mattiase@acm.or Received: from stanniol.lan (c-064ae655.032-75-73746f71.bbcust.telenor.se [85.230.74.6]) (authenticated bits=0) by mail265c50.megamailservers.eu (8.14.9/8.13.1) with ESMTP id 0ANAQ1B3014128; Mon, 23 Nov 2020 10:26:02 +0000 Content-Type: text/plain; charset=utf-8 Mime-Version: 1.0 (Mac OS X Mail 12.4 \(3445.104.17\)) Subject: Re: bug#44799: 28.0.50; Calc: Meter not printed as \text in latex output From: =?utf-8?Q?Mattias_Engdeg=C3=A5rd?= In-Reply-To: <87mtz9cd06.fsf@web.de> Date: Mon, 23 Nov 2020 11:26:00 +0100 Content-Transfer-Encoding: quoted-printable Message-Id: <732F118E-0110-4CE2-8900-C64E06D78A04@acm.org> References: <87mtz9cd06.fsf@web.de> To: Michael Heerdegen X-Mailer: Apple Mail (2.3445.104.17) X-CTCH-RefID: str=0001.0A782F22.5FBB8E3B.004E, ss=1, re=0.000, recu=0.000, reip=0.000, cl=1, cld=1, fgs=0 X-CTCH-VOD: Unknown X-CTCH-Spam: Unknown X-CTCH-Score: 0.000 X-CTCH-Rules: X-CTCH-Flags: 0 X-CTCH-ScoreCust: 0.000 X-CSC: 0 X-CHA: v=2.3 cv=VaOJw2h9 c=1 sm=1 tr=0 a=Ni+dBsiEfW2GqKMPYZim9A==:117 a=Ni+dBsiEfW2GqKMPYZim9A==:17 a=IkcTkHD0fZMA:10 a=M51BFTxLslgA:10 a=NoirPxP4FYxAGmrsBmkA:9 a=QEXdDO2ut3YA:10 X-Origin-Country: SE X-Spam-Score: 0.4 (/) X-Debbugs-Envelope-To: 44799 Cc: 44799@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -0.0 (/) 22 nov. 2020 kl. 22.12 skrev Michael Heerdegen = : > Ah, so there can be a variable and a unit of the same name at the same > time? I can s s a variable "m". Is it good to allow this? I mean = it's > good that meters is "m" as expected but if someone wants to use "m" as = a > variable in the same formula it necessarily gets ugly. Given the number of units, it seems difficult to disallow using the same = symbols as variables. Many innocent-looking single-letter names are = units: s, N, m, A, V, W, J, g, l, ... For instance, 'e' both has a value (2.7something) and is a unit = (electron charge). Variables in Calc include not only names having an assigned concrete = value, but also variables in the wider mathematical sense since Calc is = capable of some symbolic computing. Units of measurement just use the = same mechanism and are treated as any other variables in all computation = except for operations explicitly related to units such as 'u s'. A serious reform seems unlikely unless someone really is willing to do = the work. More realistic might be adding a way to tell Calc which = variables you want to have typeset as units, as this can vary from = person to person and time to time. > BTW, do you know (Bug#30231) why allowed characters in units are > restricted? No idea, but isn't it just the restriction of variable symbols in = general? Unless they already play some syntactic role I suppose we could = be more permissive. Currency symbols like =E2=82=AC, =C2=A5 and $ appear = to be of special interest, but $ already has a special meaning. From debbugs-submit-bounces@debbugs.gnu.org Mon Nov 23 07:17:36 2020 Received: (at 44799) by debbugs.gnu.org; 23 Nov 2020 12:17:36 +0000 Received: from localhost ([127.0.0.1]:49328 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1khAmm-00031z-HO for submit@debbugs.gnu.org; Mon, 23 Nov 2020 07:17:36 -0500 Received: from mout.web.de ([217.72.192.78]:46807) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1khAmk-00031l-Ut for 44799@debbugs.gnu.org; Mon, 23 Nov 2020 07:17:35 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=web.de; s=dbaedf251592; t=1606133782; bh=GIx4V9MBjJ9g1ncdd3Adym6wD6yExAQkgMgb8KI+f1c=; h=X-UI-Sender-Class:From:To:Cc:Subject:References:Date:In-Reply-To; b=Zjnookz1YxbPMjkFLQn1dsZEmKjmgGPfN2jh7NcfXI+GCA0xbKHYKq9ojxASv21oU iehXRmK0BGVaadrda14QNhPQNGBUTGlWdPHLzJxQJf4CwQlynbVNKsBGCmRC1Q1VNC T4L5x15AEoEEYbA4W6DJpacXmGSuQIcw/Tw79PoI= X-UI-Sender-Class: c548c8c5-30a9-4db5-a2e7-cb6cb037b8f9 Received: from drachen.dragon ([94.218.219.247]) by smtp.web.de (mrweb105 [213.165.67.124]) with ESMTPSA (Nemesis) id 1N4627-1kGOkp1tfV-00zdTC; Mon, 23 Nov 2020 13:16:22 +0100 From: Michael Heerdegen To: Mattias =?utf-8?Q?Engdeg=C3=A5rd?= Subject: Re: bug#44799: 28.0.50; Calc: Meter not printed as \text in latex output References: <87mtz9cd06.fsf@web.de> <732F118E-0110-4CE2-8900-C64E06D78A04@acm.org> Date: Mon, 23 Nov 2020 13:16:21 +0100 In-Reply-To: <732F118E-0110-4CE2-8900-C64E06D78A04@acm.org> ("Mattias =?utf-8?Q?Engdeg=C3=A5rd=22's?= message of "Mon, 23 Nov 2020 11:26:00 +0100") Message-ID: <87o8joz2sq.fsf@web.de> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Provags-ID: V03:K1:cfQTqzTGWD4vcqcS9ZCEQ/mbkARJ/GLeBOTAnmKlOet/6ARqRay uyqgK/sWUOC6fTtz1SN3Vo7zsuhs565FmBy9hOUeX1zAuFzRklLGKGij1kH02sqoFS8X/lc WCTCTBQHYxPsvPIzCdoMzUCfxmyeyaIgrLR7r/tm6gOqvO1D28RNV7gHFFs7v+dDAhnqdvu DmTLz2dbBObleakdy6HTg== X-Spam-Flag: NO X-UI-Out-Filterresults: notjunk:1;V03:K0:7E7sjlHYW9A=:0NJbfFmpLB4HFEQ+0+NXw+ +2N3PL/f3KOPdflMGkxy3FYSL2dVoVJjXzw0nlc2IyMmwDxBvptk5Ap1oc64jb96MW4q8tY5B DVIEbxbMmFjTZ4JuoZgNgl0EZLzUB0RHukZXKohHfI7i6sMyhJGq5ACmGGY6UPranvH0WrVAO 5dO1T13chQMk46pwyuheoPdFACHWfwVmj/LiDVT6U6MqLiFhi10DZ7Y5tMSzqqACC5qqR2kga MCCJ7fPKs5ls9kJ6tuP6aGjhe+KIEo0v0YfQBjTY+3rKg08Ni2YwnFocsmxZ4aJtjlgF8Iwhl jSQAwyqwTAUxTqIzM+qPhC6ibZHatJmRfx7WQsej2qYnQeKVRV0mRzoql/N1LIVVL9HwiC05t Cd3eGwEmtoZwA1qeyYBH7HE7bB4pa/6bVgPliPwPIGa4L48zNW7ZYviuOdvnhMqf9x/rucrRa JdxToeWXMid4VlhR+wtK9lna8pUACaE71oX6SAeacpxluhGOpr+ydPnZKzRUT4sO4PHcB2a2e /s9g2gTTvlTs006LRuptvVeGmQUkkKVH4jtjSIN8wrQ4mn0g8aGlbz5F3Gl9Yx5+0yv3E3uhE yETVAgS8g2II4nFafkKjDwPd5CE2UgBLTqznqWFW/IrZQxjImshoYRVx0C9RvpEQPqvli/JbI BUCvKzPxEJjjLzCQOEdkFBRL3zr5FG8cTTtiwZFGT8TptcrComI/+bIJ8yWThFoUtLj1vcq31 PD3Q0dvn27ojqrnXzhJh8Kjylju9P320z0tgiCIeQp5l4FePN7QsoS0cC6PuDUhQ3P8jtfmZD XcXdiduoXCulMrtoaR5gxTHjg6wUznTRJkHQ8iBexFB09DP8BXs6LXZHhBOoUPl61UyitomO9 zdk2g6Ohqrn5AXGs6Fi2VkZg/9Nop5RBZs0Hc2TCA= X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 44799 Cc: 44799@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) Mattias Engdeg=C3=A5rd writes: > A serious reform seems unlikely unless someone really is willing to do > the work. More realistic might be adding a way to tell Calc which > variables you want to have typeset as units, as this can vary from > person to person and time to time. Would it be possible to make output syntax depend on how the symbol is actually interpreted by Calc in the given context? > > BTW, do you know (Bug#30231) why allowed characters in units are > > restricted? > > No idea, but isn't it just the restriction of variable symbols in > general? You mean, in Calc? Then I wonder why we have that restriction. Regards, Michael. From debbugs-submit-bounces@debbugs.gnu.org Mon Nov 23 08:52:36 2020 Received: (at 44799) by debbugs.gnu.org; 23 Nov 2020 13:52:36 +0000 Received: from localhost ([127.0.0.1]:49567 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1khCGi-0001JS-Df for submit@debbugs.gnu.org; Mon, 23 Nov 2020 08:52:36 -0500 Received: from mail152c50.megamailservers.eu ([91.136.10.162]:41042 helo=mail50c50.megamailservers.eu) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1khCGf-0001JG-CA for 44799@debbugs.gnu.org; Mon, 23 Nov 2020 08:52:35 -0500 X-Authenticated-User: mattiase@bredband.net DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=megamailservers.eu; s=maildub; t=1606139551; bh=0SV1ycG1bZQg0XhggMmHB1c72QFTfiz5cHPPhyyX6oY=; h=Subject:From:In-Reply-To:Date:Cc:References:To:From; b=ZnGMJVIvXWLrPkT5NPAENV0UsGOIhzDl8WaSefdoN53YiogGLfzmunPyMy1cBEvzN /lLdDA95wKimtFHYhtDUWd1Ip1A9GReW8aBGrY11Cyu4TJOcEnsUsPMqrIgRkJVSkM UBBb+U4U8GikVr+lmsaWzRvgT4bv4oHDaBuCm2CU= Feedback-ID: mattiase@acm.or Received: from stanniol.lan (c-064ae655.032-75-73746f71.bbcust.telenor.se [85.230.74.6]) (authenticated bits=0) by mail50c50.megamailservers.eu (8.14.9/8.13.1) with ESMTP id 0ANDqP43021012; Mon, 23 Nov 2020 13:52:30 +0000 Content-Type: text/plain; charset=utf-8 Mime-Version: 1.0 (Mac OS X Mail 12.4 \(3445.104.17\)) Subject: Re: bug#44799: 28.0.50; Calc: Meter not printed as \text in latex output From: =?utf-8?Q?Mattias_Engdeg=C3=A5rd?= In-Reply-To: <87o8joz2sq.fsf@web.de> Date: Mon, 23 Nov 2020 14:52:25 +0100 Content-Transfer-Encoding: quoted-printable Message-Id: References: <87mtz9cd06.fsf@web.de> <732F118E-0110-4CE2-8900-C64E06D78A04@acm.org> <87o8joz2sq.fsf@web.de> To: Michael Heerdegen X-Mailer: Apple Mail (2.3445.104.17) X-CTCH-RefID: str=0001.0A782F23.5FBBBE9F.0085, ss=1, re=0.000, recu=0.000, reip=0.000, cl=1, cld=1, fgs=0 X-CTCH-VOD: Unknown X-CTCH-Spam: Unknown X-CTCH-Score: 0.000 X-CTCH-Rules: X-CTCH-Flags: 0 X-CTCH-ScoreCust: 0.000 X-CSC: 0 X-CHA: v=2.3 cv=ceesUULM c=1 sm=1 tr=0 a=Ni+dBsiEfW2GqKMPYZim9A==:117 a=Ni+dBsiEfW2GqKMPYZim9A==:17 a=IkcTkHD0fZMA:10 a=M51BFTxLslgA:10 a=UKZ2ViDlf4qED5UZk2sA:9 a=QEXdDO2ut3YA:10 X-Origin-Country: SE X-Spam-Score: 1.4 (+) X-Spam-Report: Spam detection software, running on the system "debbugs.gnu.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see the administrator of that system for details. Content preview: 23 nov. 2020 kl. 13.16 skrev Michael Heerdegen : > Would it be possible to make output syntax depend on how the symbol is > actually interpreted by Calc in the given context? Content analysis details: (1.4 points, 10.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- 1.0 SPF_SOFTFAIL SPF: sender does not match SPF record (softfail) 0.0 SPF_HELO_NONE SPF: HELO does not publish an SPF Record 0.4 KHOP_HELO_FCRDNS Relay HELO differs from its IP's reverse DNS X-Debbugs-Envelope-To: 44799 Cc: 44799@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -0.0 (/) 23 nov. 2020 kl. 13.16 skrev Michael Heerdegen = : > Would it be possible to make output syntax depend on how the symbol is > actually interpreted by Calc in the given context? Not sure if that is even possible. For example, adding 2 m and 3 m gives = 5 m, and Calc doesn't care whether m is a variable or unit here. >>> BTW, do you know (Bug#30231) why allowed characters in units are >>> restricted? >>=20 >> No idea, but isn't it just the restriction of variable symbols in >> general? >=20 > You mean, in Calc? Then I wonder why we have that restriction. Again, it's probably a matter of history. Calc is old and may even = predate full Unicode support in Emacs. Latin and Greek letters suffice for the vast majority of units; the only = major exceptions I can think of are =C3=85 and =C2=B0 (for the angle and = =C2=B0C). Same goes for variables, although diacritics could be useful. = Then there are currencies, but as mentioned, $ has special meaning and = cannot be used. From debbugs-submit-bounces@debbugs.gnu.org Mon Nov 23 09:22:19 2020 Received: (at 44799) by debbugs.gnu.org; 23 Nov 2020 14:22:19 +0000 Received: from localhost ([127.0.0.1]:49597 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1khCjT-00025G-KW for submit@debbugs.gnu.org; Mon, 23 Nov 2020 09:22:19 -0500 Received: from mout.web.de ([212.227.17.11]:55523) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1khCjS-000253-Bl for 44799@debbugs.gnu.org; Mon, 23 Nov 2020 09:22:18 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=web.de; s=dbaedf251592; t=1606141232; bh=vd4ptRspUxV7WTaa9vFy9dCWJPU6AH7+ViaXItdT70w=; h=X-UI-Sender-Class:From:To:Cc:Subject:References:Date:In-Reply-To; b=h6/nDYEdqlgGreEc7TQFUYXL0QyLJLtlJxssDtANS23TTeophQEJyMqzSv+mDM2hk U5ZyJqtsvftWW/VTGMQaFQWcCrpr5D6iXXq3ue/cyDR+QmNInAlFD0poenKDO35lK8 JIWLUZzdwFUjw23vhLU/+Tqde7PHCbNSEqa0FUP0= X-UI-Sender-Class: c548c8c5-30a9-4db5-a2e7-cb6cb037b8f9 Received: from drachen.dragon ([94.218.219.247]) by smtp.web.de (mrweb102 [213.165.67.124]) with ESMTPSA (Nemesis) id 0MPYNR-1kcXrt1xg1-004mpX; Mon, 23 Nov 2020 15:20:32 +0100 From: Michael Heerdegen To: Mattias =?utf-8?Q?Engdeg=C3=A5rd?= Subject: Re: bug#44799: 28.0.50; Calc: Meter not printed as \text in latex output References: <87mtz9cd06.fsf@web.de> <732F118E-0110-4CE2-8900-C64E06D78A04@acm.org> <87o8joz2sq.fsf@web.de> Date: Mon, 23 Nov 2020 15:20:31 +0100 In-Reply-To: ("Mattias =?utf-8?Q?Engdeg=C3=A5rd=22's?= message of "Mon, 23 Nov 2020 14:52:25 +0100") Message-ID: <87blfoxihc.fsf@web.de> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Provags-ID: V03:K1:d3ax+PEElQkibM6vnwTFZKQ5V0BzTvJVRkrcB8aeidi4WDeS3i3 1ep/SXwFjsZv+b/FkrqN16VwmBJzWLPZR/Da1Bje66a9md3i4lnZXkgY/nr71yZLdN4UdbG WHS0Sj/cMuTliv3lZirHboApUN5LCzRhImtJQeZMioGlTlAhd+G8n3Uj6wFIaMJ8yg1hVZY 0lJb575abeLLAQ/+CG1lw== X-Spam-Flag: NO X-UI-Out-Filterresults: notjunk:1;V03:K0:PY0xbzFV56A=:3yzW1XImACnsocA1QNUlHN Gz28q1/C8MFfeH/E2JQX4v/vGzhIdwX6wcjVnbAZlZo4kM/RGzkihslcAwLc/QNaOC52xGHeI 8D7au4MBLT+5gLHqMbSn7ARakV8FuLhOSGQqKzw1qpg92bxIWMjERm9kcE+u39LgSRuR5h6yW xEFevu3halZ50DO2mFBZlamLzeQRlzk6k4xsZed+dQ1So/MepbP7ag6huUq0BqFNscZ+f45lL QpqE9Ha6EKXboewaSPQinBo4L0zGlFh8OGi0K+f8GNX5RGGFvx+23hd53F2J639UQz0/xZz5E vFo7Bun20xuE0TVWA1AZBOzjB85NCm/pv9OX/Iqkd5HNg6ifVYmcIieYn3BYZtu0KFq3fEo7W OPq8yimXRXuQS6qes4GQnAAvZrjOKZJwD2UZqljWVn9KKrUAKmr1Ceba2ZzKb+hOVSYw8tgfP kNyFd8fWwUjRisukDvw/jrGoJywiUnicGEXJ1qZR79HHj5HJje1D6k5tD4Az9LUew1HbICHV/ 6iJWwbYv3fygSaNwdHZMNyVANg54cH5l/vCVAZ03Ao6mZLaSucTsnlhU9b311fwYbRZj48bZT DJVtCveOlcg9iEoFLSi+ZwhGorR7kV5+UVtsG+2pFatBcETJYs6pYgHJiU033dUuUM2sTsdjZ n6+50bv09thSyjKsMo+29PxBHBCRwHeYzJa+QUjrapTsuEvLOEyWM2WJj+M1iZzkjd2GFat8B O5rVtK++IdJSRjW9i1kNdS07CFCTsLv/KT+tw7nrBspc6ETwbKdXK7jZdKfbrVmwtLmah9MLC I/LYgAi2VA2GMpT6J5pdDY97XstGqoIWt5Uoc08AuqXsuU5S3X/+H6xhV6W0h2CTtg+9RZ4Wr t9/iY0mlB9CTlVf/UMlpziQd4+dGdFnqbA9dQp6gM= X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 44799 Cc: 44799@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) Mattias Engdeg=C3=A5rd writes: > > Would it be possible to make output syntax depend on how the symbol is > > actually interpreted by Calc in the given context? > > Not sure if that is even possible. For example, adding 2 m and 3 m > gives 5 m, and Calc doesn't care whether m is a variable or unit here. You are probably right. Why don't we then just print all symbol names as we do for units now? In mathematical contexts variables like in $v$ are printed as Calc currently prints units. > Latin and Greek letters suffice for the vast majority of units; the > only major exceptions I can think of are =C3=85 and =C2=B0 (for the angle= and > =C2=B0C). Same goes for variables, although diacritics could be > useful. Then there are currencies, but as mentioned, $ has special > meaning and cannot be used. There are variants of the latin alphabet including the same letters looking a bit different. People may also want to use these. I don't see a reason to exclude anything...oh wait, ok, the characters must be compatible with all supported language modes, that may be the reason for the restrictions. Michael. From debbugs-submit-bounces@debbugs.gnu.org Mon Nov 23 10:13:15 2020 Received: (at 44799) by debbugs.gnu.org; 23 Nov 2020 15:13:15 +0000 Received: from localhost ([127.0.0.1]:50706 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1khDWl-0003YV-9G for submit@debbugs.gnu.org; Mon, 23 Nov 2020 10:13:15 -0500 Received: from mail176c50.megamailservers.eu ([91.136.10.186]:55286 helo=mail37c50.megamailservers.eu) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1khDWi-0003YL-3Z for 44799@debbugs.gnu.org; Mon, 23 Nov 2020 10:13:13 -0500 X-Authenticated-User: mattiase@bredband.net DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=megamailservers.eu; s=maildub; t=1606144390; bh=OvEHMSazK8d4uZIQ8bTFt7N24ykuIuw7Kh3pVHm/DHA=; h=Subject:From:In-Reply-To:Date:Cc:References:To:From; b=iP6vNEdX48C8L2VJwWG7Tawu7d3DWHzPBYo1ayFJOys1BsCJdsTghlVRGRJ85GHGX iW0wQu+HBAspvq9FtOyGLJaZF0DpPg6S+lMhKs4cTKg6V5sj1IhQ7Ta6tRy7mcavY2 wtCHczalQPxAnaouBehbDGZe1bYdKyz3y1979At8= Feedback-ID: mattiase@acm.or Received: from stanniol.lan (c-064ae655.032-75-73746f71.bbcust.telenor.se [85.230.74.6]) (authenticated bits=0) by mail37c50.megamailservers.eu (8.14.9/8.13.1) with ESMTP id 0ANFD8Bg001609; Mon, 23 Nov 2020 15:13:09 +0000 Content-Type: text/plain; charset=us-ascii Mime-Version: 1.0 (Mac OS X Mail 12.4 \(3445.104.17\)) Subject: Re: bug#44799: 28.0.50; Calc: Meter not printed as \text in latex output From: =?utf-8?Q?Mattias_Engdeg=C3=A5rd?= In-Reply-To: <87blfoxihc.fsf@web.de> Date: Mon, 23 Nov 2020 16:13:07 +0100 Content-Transfer-Encoding: quoted-printable Message-Id: <6BCCA4D0-5279-4B8B-8EFC-E539C66F9E1C@acm.org> References: <87mtz9cd06.fsf@web.de> <732F118E-0110-4CE2-8900-C64E06D78A04@acm.org> <87o8joz2sq.fsf@web.de> <87blfoxihc.fsf@web.de> To: Michael Heerdegen X-Mailer: Apple Mail (2.3445.104.17) X-CTCH-RefID: str=0001.0A782F26.5FBBD186.0046, ss=1, re=0.000, recu=0.000, reip=0.000, cl=1, cld=1, fgs=0 X-CTCH-VOD: Unknown X-CTCH-Spam: Unknown X-CTCH-Score: 0.000 X-CTCH-Rules: X-CTCH-Flags: 0 X-CTCH-ScoreCust: 0.000 X-CSC: 0 X-CHA: v=2.3 cv=WZBylHpX c=1 sm=1 tr=0 a=Ni+dBsiEfW2GqKMPYZim9A==:117 a=Ni+dBsiEfW2GqKMPYZim9A==:17 a=kj9zAlcOel0A:10 a=M51BFTxLslgA:10 a=4Sh1-kQKSMhjU_3VsJ0A:9 a=CjuIK1q_8ugA:10 X-Origin-Country: SE X-Spam-Score: 1.0 (+) X-Debbugs-Envelope-To: 44799 Cc: 44799@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -0.0 (/) 23 nov. 2020 kl. 15.20 skrev Michael Heerdegen = : > You are probably right. Why don't we then just print all symbol names > as we do for units now? In mathematical contexts variables like in = $v$ > are printed as Calc currently prints units. It's a matter of taste -- most (La)TeX users probably prefer variables = in italic as usual. For that matter, Calc's unit typesetting has more flaws that you may = want to fix while you are at it. It omits the space between the number = and the unit, normally written something like $9.8\ \mathrm{m/s^2}$. It = also gives the unsightly \frac{23 m}{s} instead of the expected 23\ = \mathrm{m/s}. > There are variants of the latin alphabet including the same letters > looking a bit different. Right. I don't know how often they are used in Calc formulae though, but = why not.