all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* Property: How to define allowed values at file level
@ 2024-07-15  1:18 Sébastien Gendre
  2024-07-15  4:34 ` Phil
  0 siblings, 1 reply; 4+ messages in thread
From: Sébastien Gendre @ 2024-07-15  1:18 UTC (permalink / raw)
  To: Org Mode List

[-- Attachment #1: Type: text/plain, Size: 707 bytes --]

Hello,

After reading the manual about property syntax[1], I want to set the
allowed values for a property at the file level.

So, at the beginning of my buffer, I have written this:

    #+PROPERTY:     Review_ALL: ⭐ ⭐⭐ ⭐⭐⭐ ⭐⭐⭐⭐ ⭐⭐⭐⭐⭐


But when I try to set the property of an heading, with keyboard shortcut
C-c C-x p, and select the property "Review": I can set any value.

Didn't the minibuffer should offer me only the values above, with completion ?

Did I misunderstand the manual ? Is it not possible to set allowed
values at a file level ?



[1] https://orgmode.org/manual/Property-Syntax.html


Best regards

-------
Gendre Sébastien

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 849 bytes --]

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

* Re: Property: How to define allowed values at file level
  2024-07-15  1:18 Property: How to define allowed values at file level Sébastien Gendre
@ 2024-07-15  4:34 ` Phil
  2024-07-15 19:48   ` mu4e: A new field added to message view is not shown Sébastien Gendre
  0 siblings, 1 reply; 4+ messages in thread
From: Phil @ 2024-07-15  4:34 UTC (permalink / raw)
  To: Sébastien Gendre, Org Mode List

Hello Sébastien,

Remove the two dots after Review_all and everything will be fine.

#+PROPERTY: Review_ALL ⭐ ⭐⭐ ⭐⭐⭐ ⭐⭐⭐⭐ ⭐⭐⭐⭐⭐

Best,

Phil


* [2024-07-15 03:18] Sébastien Gendre:
> Hello,
> 
> After reading the manual about property syntax[1], I want to set the
> allowed values for a property at the file level.
> 
> So, at the beginning of my buffer, I have written this:
> 
>      #+PROPERTY:     Review_ALL: ⭐ ⭐⭐ ⭐⭐⭐ ⭐⭐⭐⭐ ⭐⭐⭐⭐⭐
> 
> 
> But when I try to set the property of an heading, with keyboard shortcut
> C-c C-x p, and select the property "Review": I can set any value.
> 
> Didn't the minibuffer should offer me only the values above, with completion ?
> 
> Did I misunderstand the manual ? Is it not possible to set allowed
> values at a file level ?
> 
> 
> 
> [1] https://orgmode.org/manual/Property-Syntax.html
> 
> 
> Best regards
> 
> -------
> Gendre Sébastien


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

* mu4e: A new field added to message view is not shown
  2024-07-15  4:34 ` Phil
@ 2024-07-15 19:48   ` Sébastien Gendre
  2024-07-16  4:57     ` Tassilo Horn
  0 siblings, 1 reply; 4+ messages in thread
From: Sébastien Gendre @ 2024-07-15 19:48 UTC (permalink / raw)
  To: Emacs text editor help

[-- Attachment #1: Type: text/plain, Size: 1326 bytes --]


Hello,

I meet a problem with mu4e. I wanted to send my e-mail to the mu4e
mailing list, but I didn't success to subscribe to. I hope I can ask
for help here.

I have defined a custom field that show the E-mail user agent. And I
have added it to the message view. But when I show a message, my field
is nowhere.

Here is my code:


    ;; Add an e-mail custom header that give the correspondant user agent, at the end
    (add-to-list 'mu4e-header-info-custom
                 '(:user-agent .
                               ( :name "User agent"
                                 :shortname "UsrAgnt"
                                 :help "E-mail client used by correspondant"
                                 :function (lambda (msg)
                                             (or (mu4e-fetch-field msg "User-Agent") ""))))
                 t)

    ;; Add the new :user-agent field into the message view, at the end
    (add-to-list 'mu4e-view-fields :user-agent t)


I have tested the code `(mu4e-fetch-field (mu4e-message-at-point)
"User-Agent")` with `eval-expression` (M-:), and I get the User agent of
the message.

I also seen that in the variable `mu4e-view-fields`, I have ":tags" but
I don't see any "Tags:" field in a message view.


Best regards

-------
Gendre Sébastien

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 849 bytes --]

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

* Re: mu4e: A new field added to message view is not shown
  2024-07-15 19:48   ` mu4e: A new field added to message view is not shown Sébastien Gendre
@ 2024-07-16  4:57     ` Tassilo Horn
  0 siblings, 0 replies; 4+ messages in thread
From: Tassilo Horn @ 2024-07-16  4:57 UTC (permalink / raw)
  To: Sébastien Gendre; +Cc: Emacs text editor help

Sébastien Gendre <seb@k-7.ch> writes:

Hi Sébastien,

> I have defined a custom field that show the E-mail user agent. And I
> have added it to the message view. But when I show a message, my field
> is nowhere.

Since mu4e-view-mode derives from gnus-article-mode nowadays, you can
use

    ;; Show User-Agent header by default.
    (setq gnus-visible-headers (concat gnus-visible-headers
                                       "\\|^User-Agent:"))

HTH,
  Tassilo



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

end of thread, other threads:[~2024-07-16  4:57 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-07-15  1:18 Property: How to define allowed values at file level Sébastien Gendre
2024-07-15  4:34 ` Phil
2024-07-15 19:48   ` mu4e: A new field added to message view is not shown Sébastien Gendre
2024-07-16  4:57     ` Tassilo Horn

Code repositories for project(s) associated with this external index

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

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.