emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
* [BUG] Two problems with defcustom of org-structure-template-alist
@ 2013-07-03 15:50 Nick Dokos
  2013-07-03 17:47 ` Bastien
  0 siblings, 1 reply; 2+ messages in thread
From: Nick Dokos @ 2013-07-03 15:50 UTC (permalink / raw)
  To: emacs-orgmode

There seem to be two problem in the defcustom of
org-structure-template-alist. It looks like this:

--8<---------------cut here---------------start------------->8---
  :type '(repeat
	  (string :tag "Key")
	  (string :tag "Template")
	  (string :tag "Muse Template")))
--8<---------------cut here---------------end--------------->8---

and afaict, this is not well-formed, so when I try to customize it,
I get a (mismatch). I believe it should look like this:

--8<---------------cut here---------------start------------->8---
  :type '(repeat
          (list
 	   (string :tag "Key")
	   (string :tag "Template")
	   (string :tag "Muse Template"))))
--8<---------------cut here---------------end--------------->8---

That's the first problem, but even after doing this, I still get a
(mismatch).

I think the (second) problem now is that the Muse Template is not
optional as far as defcustom is concerned, but there are entries in the
list above with only two elements. If I add a third element (an empty
string) to those entries missing it, I can customize to my heart's
content.

The question is: is the Muse Template optional? If so, how does one
tell defcustom that? I did a cursory reading of the customization
chapter in the elisp manual but my brain refuses to cooperate.

GNU Emacs 24.3.50.2 (x86_64-unknown-linux-gnu, GTK+ Version 2.24.10) of
2013-06-17 on pierrot
Org-mode version 8.0.3 (release_8.0.3-358-gb0174f @
/home/nick/elisp/org-mode/lisp/)

Thanks!
-- 
Nick

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [BUG] Two problems with defcustom of org-structure-template-alist
  2013-07-03 15:50 [BUG] Two problems with defcustom of org-structure-template-alist Nick Dokos
@ 2013-07-03 17:47 ` Bastien
  0 siblings, 0 replies; 2+ messages in thread
From: Bastien @ 2013-07-03 17:47 UTC (permalink / raw)
  To: Nick Dokos; +Cc: emacs-orgmode

Hi Nick,

Nick Dokos <ndokos@gmail.com> writes:

> That's the first problem, but even after doing this, I still get a
> (mismatch).
>
> I think the (second) problem now is that the Muse Template is not
> optional as far as defcustom is concerned, but there are entries in the
> list above with only two elements. If I add a third element (an empty
> string) to those entries missing it, I can customize to my heart's
> content.

Thanks, I pushed this fix:
http://orgmode.org/cgit.cgi/org-mode.git/commit/?id=a42c09

> The question is: is the Muse Template optional? If so, how does one
> tell defcustom that? I did a cursory reading of the customization
> chapter in the elisp manual but my brain refuses to cooperate.

Well, mine refuses too :)

-- 
 Bastien

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2013-07-03 17:48 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-07-03 15:50 [BUG] Two problems with defcustom of org-structure-template-alist Nick Dokos
2013-07-03 17:47 ` Bastien

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).