From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Heime via Users list for the GNU Emacs text editor Newsgroups: gmane.emacs.help Subject: Re: Mode hooks for latex and tex files Date: Mon, 02 Dec 2024 15:58:13 +0000 Message-ID: References: Reply-To: Heime Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="861"; mail-complaints-to="usenet@ciao.gmane.io" Cc: help-gnu-emacs@gnu.org To: Arash Esbati Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane-mx.org@gnu.org Mon Dec 02 16:59:27 2024 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1tI8pb-000AeU-DV for geh-help-gnu-emacs@m.gmane-mx.org; Mon, 02 Dec 2024 16:59:27 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1tI8oo-0004VB-36; Mon, 02 Dec 2024 10:58:38 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1tI8oZ-0004UG-Ky for help-gnu-emacs@gnu.org; Mon, 02 Dec 2024 10:58:24 -0500 Original-Received: from mail-40137.protonmail.ch ([185.70.40.137]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1tI8oX-0007ee-1B; Mon, 02 Dec 2024 10:58:22 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=protonmail.com; s=protonmail3; t=1733155097; x=1733414297; bh=qEGVocT0QuZppbAlbAsL3g7ccLIXMVsTurAv9XGBg7I=; h=Date:To:From:Cc:Subject:Message-ID:In-Reply-To:References: Feedback-ID:From:To:Cc:Date:Subject:Reply-To:Feedback-ID: Message-ID:BIMI-Selector:List-Unsubscribe:List-Unsubscribe-Post; b=cU77g14vF27J6wiSPNRwuF68dQ1GD9xb9JQYG6AFY7I4/h4nJIcch82CsJ7KzJ95s XiNiHYkJYsruFiJwhnkz+XsEsn2dR12i/fstOuVwDSl+KfkTHWWTT/uhxEJSVN70oG Jw83Fl/dhtwizKpark35h5s9QWG1RoIH0FAkvkZxZfFD+9Cy0ASoiwZET3SDUpXT/O BQuzLZX7lNN0TDDQ/NwfJk5ejUFP6GyzfBS7kXMwOEWaDh6e6Ig6/X0IE/eX9JABXF 0V4z93hVsixbk7YGyBJKyoz7YLd/KWMbz4FXpvTWdzXZ88baTVa4RHqKRJJwhhk4+q PlVH31dObjm/A== In-Reply-To: Feedback-ID: 57735886:user:proton X-Pm-Message-ID: 7e2643d3fd0f036f07bf651631bac4588a931f96 Received-SPF: pass client-ip=185.70.40.137; envelope-from=heimeborgia@protonmail.com; helo=mail-40137.protonmail.ch X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 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_MSPIKE_H4=0.001, RCVD_IN_MSPIKE_WL=0.001, RCVD_IN_VALIDITY_CERTIFIED_BLOCKED=0.001, RCVD_IN_VALIDITY_RPBL_BLOCKED=0.001, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.help:148494 Archived-At: On Tuesday, December 3rd, 2024 at 1:17 AM, Arash Esbati wro= te: > Heime via Users list for the GNU Emacs text editor help-gnu-emacs@gnu.org= writes: > > > What are the mode hooks for latex and tex files? > > It depends. > > > Using latex and tex is currently very non-intuitive, with things > > like LaTex-mode, TeX-mode. This mixed capitalisation is all too > > confusing because ordinary users see only a latex or tex configuration > > for their modes, rather than the nuances of capitalisation changes. > > > The only point you have to consider is that there are 2 major modes for > editing plain-tex and latex files: > > =E2=80=A2 The modes bundled with Emacs (in tex-mode.el, do > 'M-x locate-library RET tex-mode RET') and > > =E2=80=A2 the modes provided by AUCTeX (a package you must install from E= LPA > first). > > If you're using the former, use `plain-tex-mode-hook' or` latex-mode-hook= ', and with the latter, set `plain-TeX-mode-hook' or` LaTeX-mode-hook'. > > `tex-mode-hook' and` TeX-mode-hook' are sort of meta-modes and not > intended for end users, so don't set them. > > Best, Arash AUCTeX introduces unnecessary complexity by deviating from standard naming conventions for tool-related modes. Instead of adhering to the typical package-prefixed predicate style (e.g., auctex-tex-mode and auctex-latex-mode), it opts for inconsistent and unintuitive names. The use of plain-tex-mode instead of a unified tex-mode (as seen with latex-mode) adds further redundancy. Meta-modes not intended for direct user interaction should avoid using intuitive and general names like tex-mode, reserving such names for user-facing functionality. This inconsistency is unique to AUCTeX; other language tools, such as for C, avoid analogous confusion=E2=80=94there is no equival= ent plain-c-mode.