From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Drew Adams Newsgroups: gmane.emacs.help Subject: RE: Variable that can be set only through customize Date: Thu, 29 Aug 2013 10:04:08 -0700 (PDT) Message-ID: <1e406524-3776-4e86-b759-075eda0dea9e@default> References: <87ob8gcujn.fsf@free.fr> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Trace: ger.gmane.org 1377795881 21810 80.91.229.3 (29 Aug 2013 17:04:41 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Thu, 29 Aug 2013 17:04:41 +0000 (UTC) To: Julien Cubizolles , help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Thu Aug 29 19:04:43 2013 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1VF5eD-0002lQ-Ma for geh-help-gnu-emacs@m.gmane.org; Thu, 29 Aug 2013 19:04:41 +0200 Original-Received: from localhost ([::1]:44970 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VF5eD-00016X-6l for geh-help-gnu-emacs@m.gmane.org; Thu, 29 Aug 2013 13:04:41 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:48951) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VF5dv-00015f-1N for help-gnu-emacs@gnu.org; Thu, 29 Aug 2013 13:04:31 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VF5dm-0003A8-FW for help-gnu-emacs@gnu.org; Thu, 29 Aug 2013 13:04:22 -0400 Original-Received: from userp1040.oracle.com ([156.151.31.81]:34791) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VF5dm-00039q-7s for help-gnu-emacs@gnu.org; Thu, 29 Aug 2013 13:04:14 -0400 Original-Received: from acsinet22.oracle.com (acsinet22.oracle.com [141.146.126.238]) by userp1040.oracle.com (Sentrion-MTA-4.3.1/Sentrion-MTA-4.3.1) with ESMTP id r7TH491U004663 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Thu, 29 Aug 2013 17:04:11 GMT Original-Received: from userz7021.oracle.com (userz7021.oracle.com [156.151.31.85]) by acsinet22.oracle.com (8.14.4+Sun/8.14.4) with ESMTP id r7TH49pm028058 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Thu, 29 Aug 2013 17:04:09 GMT Original-Received: from abhmt109.oracle.com (abhmt109.oracle.com [141.146.116.61]) by userz7021.oracle.com (8.14.4+Sun/8.14.4) with ESMTP id r7TH48I7019069; Thu, 29 Aug 2013 17:04:08 GMT In-Reply-To: <87ob8gcujn.fsf@free.fr> X-Priority: 3 X-Mailer: Oracle Beehive Extensions for Outlook 2.0.1.8 (707110) [OL 12.0.6680.5000 (x86)] X-Source-IP: acsinet22.oracle.com [141.146.126.238] X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic] X-Received-From: 156.151.31.81 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.14 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.org@gnu.org Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:93157 Archived-At: > While configuring AUCTex, I came upon this variable > LaTeX-math-abbrev-prefix that can only be set through customize. That's > what the docstring says, and indeed I can't change its value using > setq. What's the purpose of this limitation=C2=A0? Is there a way to > circumvent it=C2=A0? Someone else can speak more directly to your question. (I don't have the AUCTex code etc.) But in general it is good to keep in mind that Customize often does additional things when you use it to set an option value. One important thing it does is type-check the value to be assigned; it checks it against the type specified in the `defcustom' that defines the option. In addition, a `defcustom' can specify a `:set' operation, which is a function that is invoked whenever the option gets set to a new value. To set an option value programmatically, you will want to first check the option definition - its `defcustom'. Once you understand that you will be in a better position to know what you might need to do when setting the value. If you intend to set option values using Lisp, you will want to become familiar with (at least) these Customize functions: `customize-set-value', `customize-set-variable'.