emacs-bug-tracker
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#67395: closed (Fix "Text is read-only" on backspacing initial calc i


From: GNU bug Tracking System
Subject: bug#67395: closed (Fix "Text is read-only" on backspacing initial calc input)
Date: Thu, 23 Nov 2023 15:43:01 +0000

Your message dated Thu, 23 Nov 2023 17:42:22 +0200
with message-id <83o7fkfpcx.fsf@gnu.org>
and subject line Re: bug#67395: Fix "Text is read-only" on backspacing initial 
calc input
has caused the debbugs.gnu.org bug report #67395,
regarding Fix "Text is read-only" on backspacing initial calc input
to be marked as done.

(If you believe you have received this mail in error, please contact
help-debbugs@gnu.org.)


-- 
67395: https://debbugs.gnu.org/cgi/bugreport.cgi?bug=67395
GNU Bug Tracking System
Contact help-debbugs@gnu.org with problems
--- Begin Message --- Subject: Fix "Text is read-only" on backspacing initial calc input Date: Wed, 22 Nov 2023 21:02:31 -0500
This is a one-line fix for a minor issue in calc-mode. When your last
command has caused the minibuffer to open for input - for example,
you've typed a digit - and you immediately press backspace, it should
clear the minibuffer and return you to *Calculator*. Instead, the
minibuffer is unchanged, and emacs prints the message "Text is
read-only". Note that you can then backspace again to delete the
minibuffer contents as normal; this bug only manifests if you try to
backspace right after the command that puts you in the minibuffer.

The issue is that `calcDigit-backspace' tries to clear the minibuffer with
`erase-buffer', which also tries to delete the prompt, which is
read-only. `delete-minibuffer-contents' would have the desired effect
since it doesn't try to delete the prompt. This change just replaces the
former function with the latter.



In GNU Emacs 29.1 (build 1, x86_64-redhat-linux-gnu, GTK+ Version
 3.24.38, cairo version 1.17.8) of 2023-09-24 built on
 e1d0f5fdfea948b9bb25e212c9c623e4
Windowing system distributor 'The X.Org Foundation', version 11.0.12302002
System Description: Fedora Linux 39 (Workstation Edition)

Configured using:
 'configure --build=x86_64-redhat-linux-gnu
 --host=x86_64-redhat-linux-gnu --program-prefix=
 --disable-dependency-tracking --prefix=/usr --exec-prefix=/usr
 --bindir=/usr/bin --sbindir=/usr/sbin --sysconfdir=/etc
 --datadir=/usr/share --includedir=/usr/include --libdir=/usr/lib64
 --libexecdir=/usr/libexec --localstatedir=/var --runstatedir=/run
 --sharedstatedir=/var/lib --mandir=/usr/share/man
 --infodir=/usr/share/info --with-dbus --with-gif --with-jpeg --with-png
 --with-rsvg --with-tiff --with-xpm --with-x-toolkit=gtk3 --with-gpm=no
 --with-xwidgets --with-modules --with-harfbuzz --with-cairo --with-json
 --with-native-compilation=aot --with-tree-sitter --with-sqlite3
 --with-webp --with-xinput2 build_alias=x86_64-redhat-linux-gnu
 host_alias=x86_64-redhat-linux-gnu CC=gcc 'CFLAGS=-DMAIL_USE_LOCKF -O2
 -flto=auto -ffat-lto-objects -fexceptions -g -grecord-gcc-switches
 -pipe -Wall -Werror=format-security
 -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS
 -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong
 -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -m64 -mtune=generic
 -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection
 -fno-omit-frame-pointer -mno-omit-leaf-frame-pointer '
 LDFLAGS=-Wl,-z,relro
 PKG_CONFIG_PATH=:/usr/lib64/pkgconfig:/usr/share/pkgconfig CXX=g++
 'CXXFLAGS=-O2 -flto=auto -ffat-lto-objects -fexceptions -g
 -grecord-gcc-switches -pipe -Wall -Werror=format-security
 -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS
 -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong
 -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -m64 -mtune=generic
 -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection
 -fno-omit-frame-pointer -mno-omit-leaf-frame-pointer ''

Attachment: calc-mode-backspace-fix.patch
Description: Text Data


--- End Message ---
--- Begin Message --- Subject: Re: bug#67395: Fix "Text is read-only" on backspacing initial calc input Date: Thu, 23 Nov 2023 17:42:22 +0200
> From: George Kuzler <gkuzler@gmail.com>
> Date: Wed, 22 Nov 2023 21:02:31 -0500
> 
> This is a one-line fix for a minor issue in calc-mode. When your last
> command has caused the minibuffer to open for input - for example,
> you've typed a digit - and you immediately press backspace, it should
> clear the minibuffer and return you to *Calculator*. Instead, the
> minibuffer is unchanged, and emacs prints the message "Text is
> read-only". Note that you can then backspace again to delete the
> minibuffer contents as normal; this bug only manifests if you try to
> backspace right after the command that puts you in the minibuffer.
> 
> The issue is that `calcDigit-backspace' tries to clear the minibuffer with
> `erase-buffer', which also tries to delete the prompt, which is
> read-only. `delete-minibuffer-contents' would have the desired effect
> since it doesn't try to delete the prompt. This change just replaces the
> former function with the latter.

Thanks, I installed this on the emacs-29 branch, and I'm closing the
bug.


--- End Message ---

reply via email to

[Prev in Thread] Current Thread [Next in Thread]