From unknown Tue Aug 19 10:01:18 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#34451 <34451@debbugs.gnu.org> To: bug#34451 <34451@debbugs.gnu.org> Subject: Status: 26.1; doc-view-toggle-display chokes if default major-mode is text-mode Reply-To: bug#34451 <34451@debbugs.gnu.org> Date: Tue, 19 Aug 2025 17:01:18 +0000 retitle 34451 26.1; doc-view-toggle-display chokes if default major-mode is= text-mode reassign 34451 emacs submitter 34451 "Roland Winkler" severity 34451 normal thanks From debbugs-submit-bounces@debbugs.gnu.org Mon Feb 11 22:43:06 2019 Received: (at submit) by debbugs.gnu.org; 12 Feb 2019 03:43:06 +0000 Received: from localhost ([127.0.0.1]:44308 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gtOyQ-00014q-7o for submit@debbugs.gnu.org; Mon, 11 Feb 2019 22:43:06 -0500 Received: from eggs.gnu.org ([209.51.188.92]:51159) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gtOyO-00014K-BD for submit@debbugs.gnu.org; Mon, 11 Feb 2019 22:43:04 -0500 Received: from lists.gnu.org ([209.51.188.17]:32946) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1gtOyJ-0006rQ-1K for submit@debbugs.gnu.org; Mon, 11 Feb 2019 22:42:59 -0500 Received: from eggs.gnu.org ([209.51.188.92]:37189) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gtOyI-0001jo-4n for bug-gnu-emacs@gnu.org; Mon, 11 Feb 2019 22:42:58 -0500 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-1.0 required=5.0 tests=ALL_TRUSTED,BAYES_40, URIBL_BLOCKED autolearn=disabled version=3.3.2 Received: from fencepost.gnu.org ([2001:470:142:3::e]:45170) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gtOyH-0006og-Sd for bug-gnu-emacs@gnu.org; Mon, 11 Feb 2019 22:42:58 -0500 Received: from [2602:30a:2e52:d720:65b7:1416:12e7:8bfb] (port=36372 helo=regnitz) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_128_CBC_SHA1:128) (Exim 4.82) (envelope-from ) id 1gtOyH-00010K-Ly for bug-gnu-emacs@gnu.org; Mon, 11 Feb 2019 22:42:57 -0500 MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Message-ID: <16572.72292.221387.23650@gargle.gargle.HOWL> Date: Mon, 11 Feb 2019 21:42:52 -0600 From: "Roland Winkler" To: bug-gnu-emacs@gnu.org Subject: 26.1; doc-view-toggle-display chokes if default major-mode is text-mode X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-Spam-Score: 0.0 (/) 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: -1.0 (-) Start `emacs -Q' eval (setq-default major-mode 'text-mode) visit a pdf or postscript file Type C-c C-c twice doc-view-toggle-display: Wrong type argument: stringp, nil The problem is that doc-view-toggle-display assumes that if the major-mode is text-mode the user is viewing the document's text contents. But that's incorrect if the default value of major-mode is text-mode so that this mode is also used for a "raw" pdf or postscript file. In GNU Emacs 26.1 (build 1, x86_64-pc-linux-gnu, GTK+ Version 3.18.9) of 2018-05-29 built on regnitz Windowing system distributor 'The X.Org Foundation', version 11.0.11804000 System Description: Ubuntu 16.04.5 LTS Recent messages: For information about GNU Emacs and the GNU system, type C-h C-a. text-mode DocView: using cached files! Type C-c C-c to toggle between editing or viewing the document. [2 times] doc-view-toggle-display: Wrong type argument: stringp, nil Configured features: XPM JPEG TIFF GIF PNG RSVG IMAGEMAGICK SOUND GPM DBUS GSETTINGS NOTIFY ACL LIBSELINUX GNUTLS LIBXML2 FREETYPE M17N_FLT LIBOTF XFT ZLIB TOOLKIT_SCROLL_BARS GTK3 X11 THREADS LCMS2 Important settings: value of $LC_COLLATE: C value of $LANG: en_US.utf8 value of $XMODIFIERS: locale-coding-system: utf-8-unix From debbugs-submit-bounces@debbugs.gnu.org Sat Mar 09 16:08:23 2019 Received: (at 34451-done) by debbugs.gnu.org; 9 Mar 2019 21:08:23 +0000 Received: from localhost ([127.0.0.1]:37467 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1h2jCh-0003CE-Dp for submit@debbugs.gnu.org; Sat, 09 Mar 2019 16:08:23 -0500 Received: from eggs.gnu.org ([209.51.188.92]:60870) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1h2jCf-0003C2-D9 for 34451-done@debbugs.gnu.org; Sat, 09 Mar 2019 16:08:21 -0500 Received: from fencepost.gnu.org ([2001:470:142:3::e]:36492) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1h2jCa-0004XG-7C for 34451-done@debbugs.gnu.org; Sat, 09 Mar 2019 16:08:16 -0500 Received: from auth2-smtp.messagingengine.com ([66.111.4.228]:41189) by fencepost.gnu.org with esmtpsa (TLS1.2:DHE_RSA_AES_256_CBC_SHA256:256) (Exim 4.82) (envelope-from ) id 1h2jCZ-000473-Ks; Sat, 09 Mar 2019 16:08:15 -0500 Received: from compute7.internal (compute7.nyi.internal [10.202.2.47]) by mailauth.nyi.internal (Postfix) with ESMTP id 1653721D2E; Sat, 9 Mar 2019 16:08:15 -0500 (EST) Received: from mailfrontend2 ([10.202.2.163]) by compute7.internal (MEProxy); Sat, 09 Mar 2019 16:08:15 -0500 X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedutddrgedvgddugeekucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmne cujfgurhephffvufhfffgjkfgfgggtsehttdertddtredtnecuhfhrohhmpefvrghsshhi lhhoucfjohhrnhcuoehtshguhhesghhnuhdrohhrgheqnecukfhppeelfedrvdefiedrud dvledrhedvnecurfgrrhgrmhepmhgrihhlfhhrohhmpehthhhorhhnodhmvghsmhhtphgr uhhthhhpvghrshhonhgrlhhithihqdekieejfeekjeekgedqieefhedvleekqdhtshguhh eppehgnhhurdhorhhgsehfrghsthhmrghilhdrfhhmnecuvehluhhsthgvrhfuihiivgep td X-ME-Proxy: Received: from thinkpad-t440p (p5dec8134.dip0.t-ipconnect.de [93.236.129.52]) by mail.messagingengine.com (Postfix) with ESMTPA id C594C10312; Sat, 9 Mar 2019 16:08:13 -0500 (EST) From: Tassilo Horn To: "Roland Winkler" Subject: Re: bug#34451: 26.1; doc-view-toggle-display chokes if default major-mode is text-mode References: <16572.72292.221387.23650@gargle.gargle.HOWL> Date: Sat, 09 Mar 2019 22:08:11 +0100 In-Reply-To: <16572.72292.221387.23650@gargle.gargle.HOWL> (Roland Winkler's message of "Mon, 11 Feb 2019 21:42:52 -0600") Message-ID: <871s3f21tw.fsf@gnu.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 34451-done Cc: 34451-done@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.0 (-) "Roland Winkler" writes: > Start `emacs -Q' > eval (setq-default major-mode 'text-mode) > visit a pdf or postscript file > Type C-c C-c twice > doc-view-toggle-display: Wrong type argument: stringp, nil > > The problem is that doc-view-toggle-display assumes that if the > major-mode is text-mode the user is viewing the document's text > contents. But that's incorrect if the default value of major-mode is > text-mode so that this mode is also used for a "raw" pdf or postscript > file. Right, thanks for the pointer. Now I use a separate mode (which is actually just `view-mode' with a doc-view-specific value for major-mode). Bye, Tassilo From unknown Tue Aug 19 10:01:18 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Sun, 07 Apr 2019 11:24:05 +0000 User-Agent: Fakemail v42.6.9 # This is a fake control message. # # The action: # bug archived. thanks # This fakemail brought to you by your local debbugs # administrator