unofficial mirror of help-gnu-emacs@gnu.org
 help / color / mirror / Atom feed
* problem with (notifications-notify :body "<test>")
@ 2012-11-06 11:09 Peter Münster
  2012-11-06 11:59 ` Tassilo Horn
  2012-11-06 14:42 ` Michael Albinus
  0 siblings, 2 replies; 8+ messages in thread
From: Peter Münster @ 2012-11-06 11:09 UTC (permalink / raw)
  To: help-gnu-emacs

Hi,

When I call
   
    (notifications-notify :body "<test>")

the notification pop-up is empty, no body-text.

How could I solve this problem please?

TIA,
-- 
           Peter




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

* Re: problem with (notifications-notify :body "<test>")
  2012-11-06 11:09 problem with (notifications-notify :body "<test>") Peter Münster
@ 2012-11-06 11:59 ` Tassilo Horn
  2012-11-06 19:31   ` Peter Münster
  2012-11-06 14:42 ` Michael Albinus
  1 sibling, 1 reply; 8+ messages in thread
From: Tassilo Horn @ 2012-11-06 11:59 UTC (permalink / raw)
  To: help-gnu-emacs

Peter Münster <pmlists@free.fr> writes:

Hi Peter,

> When I call
>    
>     (notifications-notify :body "<test>")
>
> the notification pop-up is empty, no body-text.

When I do the same, the <test> body is there.  Possibly, the difference
is the notification service we're using.  I'm on GNOME3.

BTW, I've just noticed that

  % notify-send "" "<test>"

in a terminal just says

  No summary specified.

and no notification appears.  So probably the summary is kind of a
mandatory field, and your notification daemon is strict with that while
the GNOME Shell isn't.

Bye,
Tassilo




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

* Re: problem with (notifications-notify :body "<test>")
  2012-11-06 11:09 problem with (notifications-notify :body "<test>") Peter Münster
  2012-11-06 11:59 ` Tassilo Horn
@ 2012-11-06 14:42 ` Michael Albinus
  2012-11-06 19:39   ` Peter Münster
  1 sibling, 1 reply; 8+ messages in thread
From: Michael Albinus @ 2012-11-06 14:42 UTC (permalink / raw)
  To: Peter Münster; +Cc: help-gnu-emacs

Peter Münster <pmlists@free.fr> writes:

> Hi,

Hi Peter,

> When I call
>    
>     (notifications-notify :body "<test>")
>
> the notification pop-up is empty, no body-text.
>
> How could I solve this problem please?

IIRC, for some notification daemons a non-empty title is mandatory. You
might try:

(notifications-notify :title " " :body "test")

Note, that notification daemons might also support markups in the body,
like "<b>bold text</b>" etc. I wouldn't use tags in the body, if not
intended for formatting.

> TIA,

Best regards, Michael.



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

* Re: problem with (notifications-notify :body "<test>")
  2012-11-06 11:59 ` Tassilo Horn
@ 2012-11-06 19:31   ` Peter Münster
  0 siblings, 0 replies; 8+ messages in thread
From: Peter Münster @ 2012-11-06 19:31 UTC (permalink / raw)
  To: help-gnu-emacs

On Tue, Nov 06 2012, Tassilo Horn wrote:

> When I do the same, the <test> body is there.  Possibly, the difference
> is the notification service we're using.  I'm on GNOME3.

Hi,

Indeed. I forgot to test with the command line tool. So this has nothing
to do with emacs. Sorry for the noise.

-- 
           Peter




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

* Re: problem with (notifications-notify :body "<test>")
  2012-11-06 14:42 ` Michael Albinus
@ 2012-11-06 19:39   ` Peter Münster
  2012-11-06 20:32     ` Michael Albinus
  2012-11-09 22:31     ` Xavier Maillard
  0 siblings, 2 replies; 8+ messages in thread
From: Peter Münster @ 2012-11-06 19:39 UTC (permalink / raw)
  To: help-gnu-emacs

On Tue, Nov 06 2012, Michael Albinus wrote:

> (notifications-notify :title " " :body "test")

`(notifications-notify :body "test")' works too.
The problem is the "<".


> Note, that notification daemons might also support markups in the body,
> like "<b>bold text</b>" etc. I wouldn't use tags in the body, if not
> intended for formatting.

Thanks, now I understand the reason for that behaviour. At first glance
it seemed quite strange to me, because even with `:body "bla < bla"'
the body was empty...

-- 
           Peter




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

* Re: problem with (notifications-notify :body "<test>")
  2012-11-06 19:39   ` Peter Münster
@ 2012-11-06 20:32     ` Michael Albinus
  2012-11-09 22:31     ` Xavier Maillard
  1 sibling, 0 replies; 8+ messages in thread
From: Michael Albinus @ 2012-11-06 20:32 UTC (permalink / raw)
  To: Peter Münster; +Cc: help-gnu-emacs

Peter Münster <pmlists@free.fr> writes:

> Thanks, now I understand the reason for that behaviour. At first glance
> it seemed quite strange to me, because even with `:body "bla < bla"'
> the body was empty...

If you need special characters, you might use html quoting, like
"bla &lt; bla".

(Maybe this should be explained in the docstring).

Best regards, Michael.



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

* Re: problem with (notifications-notify :body "<test>")
  2012-11-06 19:39   ` Peter Münster
  2012-11-06 20:32     ` Michael Albinus
@ 2012-11-09 22:31     ` Xavier Maillard
  2012-11-18 19:55       ` Michael Albinus
  1 sibling, 1 reply; 8+ messages in thread
From: Xavier Maillard @ 2012-11-09 22:31 UTC (permalink / raw)
  To: Peter Münster; +Cc: help-gnu-emacs


> 
>> `(notifications-notify :body "test")' works too.
> The problem is the "<".

Ony my girlfriend's computer, it does work with "<".

Her computer uses XFCE on a slackware GNU/linux system.

	Xavier
-- 
http://www.gnu.org
http://www.april.org
http://www.lolica.org



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

* Re: problem with (notifications-notify :body "<test>")
  2012-11-09 22:31     ` Xavier Maillard
@ 2012-11-18 19:55       ` Michael Albinus
  0 siblings, 0 replies; 8+ messages in thread
From: Michael Albinus @ 2012-11-18 19:55 UTC (permalink / raw)
  To: Xavier Maillard; +Cc: help-gnu-emacs, Peter Münster

Xavier Maillard <xavier@maillard.im> writes:

>>> `(notifications-notify :body "test")' works too.
>> The problem is the "<".
>
> Ony my girlfriend's computer, it does work with "<".

It depends on the capabilities of the notifications daemon. If it
doesn't support :body-markup, it is likely to accept "<".

See `notifications-get-capabilities'.

> 	Xavier

Best regards, Michael.



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

end of thread, other threads:[~2012-11-18 19:55 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-11-06 11:09 problem with (notifications-notify :body "<test>") Peter Münster
2012-11-06 11:59 ` Tassilo Horn
2012-11-06 19:31   ` Peter Münster
2012-11-06 14:42 ` Michael Albinus
2012-11-06 19:39   ` Peter Münster
2012-11-06 20:32     ` Michael Albinus
2012-11-09 22:31     ` Xavier Maillard
2012-11-18 19:55       ` Michael Albinus

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).