Announcements and discussions for Gnus, the GNU Emacs Usenet newsreader
 help / color / mirror / Atom feed
* Face - problem!!
@ 2005-03-31  0:44 Surendra Singhi
  2005-03-31 17:41 ` David Z Maze
  2005-03-31 21:56 ` Surendra Singhi
  0 siblings, 2 replies; 8+ messages in thread
From: Surendra Singhi @ 2005-03-31  0:44 UTC (permalink / raw)


I want to insert face into my news posts and I have the following lines in my
.gnus file

(setq message-required-news-headers
   (nconc message-required-news-headers
	  (list '(Face . (lambda ()
		   (gnus-face-from-file "~/.xemacs/face.jpg"))))))

The value of the variable is also set accordingly to

(From Newsgroups Subject Date Message-ID (optional . Organization)
 (optional . User-Agent) (Face lambda nil 
(gnus-face-from-file "~/.xemacs/face.jpg")))

But it doesn't seems to have the intended effect.

Am I doing anything wrong, or do I need to set some other variable?

Thanks in advance.
-- 
Surendra Singhi
www.public.asu.edu/~sksinghi/

"O thou my friend! The prosperity of Crime is like unto the lightning,
whose traitorous brilliancies embellish the atmosphere but for an
instant, in order to hurl into death's very depths the luckless one
they have dazzled." -- Marquis de Sade


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

* Re: Face - problem!!
  2005-03-31  0:44 Face - problem!! Surendra Singhi
@ 2005-03-31 17:41 ` David Z Maze
  2005-03-31 20:50   ` Surendra Singhi
  2005-03-31 21:56 ` Surendra Singhi
  1 sibling, 1 reply; 8+ messages in thread
From: David Z Maze @ 2005-03-31 17:41 UTC (permalink / raw)


Surendra Singhi <efuzzyone@netscape.net> writes:

> I want to insert face into my news posts and I have the following lines in my
> .gnus file
>
> (setq message-required-news-headers
>    (nconc message-required-news-headers
> 	  (list '(Face . (lambda ()
> 		   (gnus-face-from-file "~/.xemacs/face.jpg"))))))
>
> The value of the variable is also set accordingly to
>
> (From Newsgroups Subject Date Message-ID (optional . Organization)
>  (optional . User-Agent) (Face lambda nil 
> (gnus-face-from-file "~/.xemacs/face.jpg")))
>
> But it doesn't seems to have the intended effect.
>
> Am I doing anything wrong, or do I need to set some other variable?

I don't think you're actually getting the lambda (code) into the list;
instead, you're getting the symbol 'lambda and such into it.  Maybe
you mean something more like

(setq message-required-news-headers
  (append message-required-news-headers
    (list (cons 'Face (lambda ()
                        (gnus-face-from-file "face.jpg"))))))

Or, even,

(defun acquire-gnus-face () (gnus-face-from-file "face.jpg"))
(setq message-required-news-headers
  (append message-required-news-headers
    '((Face . acquire-gnus-face))))

(It's not obvious to me that "~/.xemacs/face.jpg" will do what you
want as an argument to gnus-face-from-file; you might need to pass
that through expand-file-name on the way.)

  --dzm


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

* Re: Face - problem!!
  2005-03-31 17:41 ` David Z Maze
@ 2005-03-31 20:50   ` Surendra Singhi
  2005-03-31 21:11     ` Rebecca Ore
  0 siblings, 1 reply; 8+ messages in thread
From: Surendra Singhi @ 2005-03-31 20:50 UTC (permalink / raw)


David Z Maze <dmaze@mit.edu> writes:

> Surendra Singhi <efuzzyone@netscape.net> writes:
>
>> I want to insert face into my news posts and I have the following lines in my
>> .gnus file
>>
>> (setq message-required-news-headers
>>    (nconc message-required-news-headers
>> 	  (list '(Face . (lambda ()
>> 		   (gnus-face-from-file "~/.xemacs/face.jpg"))))))
>>
>> The value of the variable is also set accordingly to
>>
>> (From Newsgroups Subject Date Message-ID (optional . Organization)
>>  (optional . User-Agent) (Face lambda nil 
>> (gnus-face-from-file "~/.xemacs/face.jpg")))
>>
>> But it doesn't seems to have the intended effect.
>>
>> Am I doing anything wrong, or do I need to set some other variable?
>
> I don't think you're actually getting the lambda (code) into the list;
> instead, you're getting the symbol 'lambda and such into it.  Maybe
> you mean something more like
>
> (setq message-required-news-headers
>   (append message-required-news-headers
>     (list (cons 'Face (lambda ()
>                         (gnus-face-from-file "face.jpg"))))))
>
> Or, even,
>
> (defun acquire-gnus-face () (gnus-face-from-file "face.jpg"))
> (setq message-required-news-headers
>   (append message-required-news-headers
>     '((Face . acquire-gnus-face))))
>
Both your method and my method gives the same result
i.e., ((Face lambda nil
       (gnus-face-from-file "face.jpg")))

> (It's not obvious to me that "~/.xemacs/face.jpg" will do what you
> want as an argument to gnus-face-from-file; you might need to pass
> that through expand-file-name on the way.)

Even after using expand-file-name on the way I don't get face field in my
messages.
The value of the variable is now:

(From Newsgroups Subject Date Message-ID (optional . Organization) 
(optional . User-Agent) (Face lambda nil (gnus-face-from-file 
(expand-file-name "~/.xemacs/face.jpg"))))

Thanks in advance.
-- 
Surendra Singhi
www.public.asu.edu/~sksinghi/

"O thou my friend! The prosperity of Crime is like unto the lightning,
whose traitorous brilliancies embellish the atmosphere but for an
instant, in order to hurl into death's very depths the luckless one
they have dazzled." -- Marquis de Sade


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

* Re: Face - problem!!
  2005-03-31 20:50   ` Surendra Singhi
@ 2005-03-31 21:11     ` Rebecca Ore
  2005-03-31 21:39       ` Surendra Singhi
  0 siblings, 1 reply; 8+ messages in thread
From: Rebecca Ore @ 2005-03-31 21:11 UTC (permalink / raw)


Surendra Singhi <efuzzyone@netscape.net> writes:

> David Z Maze <dmaze@mit.edu> writes:
>

>> I don't think you're actually getting the lambda (code) into the list;
>> instead, you're getting the symbol 'lambda and such into it.  Maybe
>> you mean something more like
>>
>> (setq message-required-news-headers
>>   (append message-required-news-headers
>>     (list (cons 'Face (lambda ()
>>                         (gnus-face-from-file "face.jpg"))))))

This worked for me on XDarwin running over Mac OS 10.2.8.  I'd also
been trying to figure out how to do this. 

This follows those lines

        (add-hook 'message-header-setup-hook
                    'my-message-header-setup-hook)

Not sure if those are necessary or not, but if you don't have them,
try adding the.

Also, you need to make sure you've compiled png support into your
(X)Emacs/Gnus.


> Even after using expand-file-name on the way I don't get face field in my
> messages.
> The value of the variable is now:
>
> (From Newsgroups Subject Date Message-ID (optional . Organization) 
> (optional . User-Agent) (Face lambda nil (gnus-face-from-file 
> (expand-file-name "~/.xemacs/face.jpg"))))
>
> Thanks in advance.

-- 
Rebecca Ore


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

* Re: Face - problem!!
  2005-03-31 21:11     ` Rebecca Ore
@ 2005-03-31 21:39       ` Surendra Singhi
  2005-03-31 22:16         ` Rebecca Ore
  0 siblings, 1 reply; 8+ messages in thread
From: Surendra Singhi @ 2005-03-31 21:39 UTC (permalink / raw)


Rebecca Ore <ogoense.net@verizon.net> writes:

> Surendra Singhi <efuzzyone@netscape.net> writes:
>
>> David Z Maze <dmaze@mit.edu> writes:
>>
>
>>> I don't think you're actually getting the lambda (code) into the list;
>>> instead, you're getting the symbol 'lambda and such into it.  Maybe
>>> you mean something more like
>>>
>>> (setq message-required-news-headers
>>>   (append message-required-news-headers
>>>     (list (cons 'Face (lambda ()
>>>                         (gnus-face-from-file "face.jpg"))))))
>
> This worked for me on XDarwin running over Mac OS 10.2.8.  I'd also
> been trying to figure out how to do this. 
>
> This follows those lines
>
>         (add-hook 'message-header-setup-hook
>                     'my-message-header-setup-hook)
>
It seems in my case gnus is not using the variable message-required-news-headers
anywhere.

You also need to give me the code for the function
my-message-header-setup-hook.

Thanks.
-- 
Surendra Singhi
www.public.asu.edu/~sksinghi/

"O thou my friend! The prosperity of Crime is like unto the lightning,
whose traitorous brilliancies embellish the atmosphere but for an
instant, in order to hurl into death's very depths the luckless one
they have dazzled." -- Marquis de Sade


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

* Re: Face - problem!!
  2005-03-31  0:44 Face - problem!! Surendra Singhi
  2005-03-31 17:41 ` David Z Maze
@ 2005-03-31 21:56 ` Surendra Singhi
  1 sibling, 0 replies; 8+ messages in thread
From: Surendra Singhi @ 2005-03-31 21:56 UTC (permalink / raw)


Surendra Singhi <efuzzyone@netscape.net> writes:

> I want to insert face into my news posts and I have the following lines in my
> .gnus file
>
> (setq message-required-news-headers
>    (nconc message-required-news-headers
> 	  (list '(Face . (lambda ()
> 		   (gnus-face-from-file "~/.xemacs/face.jpg"))))))
>
> The value of the variable is also set accordingly to
>
> But it doesn't seems to have the intended effect.
>
I was finally able to do this by setting the  gnus-posting-styles variable.
     (Face (lambda()(gnus-face-from-file "~/.xemacs/face.jpg"))

Doc: http://www.gnus.org/manual/gnus_139.html#SEC139

What I was doing earlier was also from documentation: 
http://www.gnus.org/manual/gnus_286.html#SEC286

If it is something which has changed with the newer version of gnus and is no
longer supported then the documentation should be modified to reflect this change.

Anyway, thanks for all the suggestions.

-- 
Surendra Singhi
www.public.asu.edu/~sksinghi/

"O thou my friend! The prosperity of Crime is like unto the lightning,
whose traitorous brilliancies embellish the atmosphere but for an
instant, in order to hurl into death's very depths the luckless one
they have dazzled." -- Marquis de Sade


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

* Re: Face - problem!!
  2005-03-31 21:39       ` Surendra Singhi
@ 2005-03-31 22:16         ` Rebecca Ore
  2005-04-01  6:53           ` Surendra Singhi
  0 siblings, 1 reply; 8+ messages in thread
From: Rebecca Ore @ 2005-03-31 22:16 UTC (permalink / raw)


Surendra Singhi <efuzzyone@netscape.net> writes:

>
> You also need to give me the code for the function
> my-message-header-setup-hook.

The sections in my .gnus.el that I've cobbled together
script-kitty-wise from other people's lisp suggestions are as follows:


  (defun my-message-header-setup-hook ()
            (let ((group (or gnus-newsgroup-name "")))
              (when (or (message-fetch-field "newsgroups")
                        (gnus-group-find-parameter group 'to-address)
                        (gnus-group-find-parameter group 'to-list))
                (insert "Mail-Copies-To: never\n"))))

(setq message-required-news-headers
  (append message-required-news-headers
    (list (cons 'Face (lambda ()
                        (gnus-face-from-file "~/Graphics/Photographs/smallberniesiguana.jpg"))))))

          
          (add-hook 'message-header-setup-hook
                    'my-message-header-setup-hook)



-- 
Rebecca Ore


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

* Re: Face - problem!!
  2005-03-31 22:16         ` Rebecca Ore
@ 2005-04-01  6:53           ` Surendra Singhi
  0 siblings, 0 replies; 8+ messages in thread
From: Surendra Singhi @ 2005-04-01  6:53 UTC (permalink / raw)


Rebecca Ore <ogoense.net@verizon.net> writes:

> Surendra Singhi <efuzzyone@netscape.net> writes:
>
>>
>> You also need to give me the code for the function
>> my-message-header-setup-hook.
>
> The sections in my .gnus.el that I've cobbled together
> script-kitty-wise from other people's lisp suggestions are as follows:
>
>   (defun my-message-header-setup-hook ()
>             (let ((group (or gnus-newsgroup-name "")))
>               (when (or (message-fetch-field "newsgroups")
>                         (gnus-group-find-parameter group 'to-address)
>                         (gnus-group-find-parameter group 'to-list))
>                 (insert "Mail-Copies-To: never\n"))))
>
> (setq message-required-news-headers
>   (append message-required-news-headers
>     (list (cons 'Face (lambda ()
>                         (gnus-face-from-file "~/Graphics/Photographs/smallberniesiguana.jpg"))))))
>
>           (add-hook 'message-header-setup-hook
>                     'my-message-header-setup-hook)
>
Thanks for your help, but "my-message-header-setup-hook" is not the reason 
because of which message-required-news-headers works, there must be some other
setting or something else which makes it tick.
Anyway, I got was able to use some other workaround to make FACE work.

Cheers.
-- 
Surendra Singhi
www.public.asu.edu/~sksinghi/

"O thou my friend! The prosperity of Crime is like unto the lightning,
whose traitorous brilliancies embellish the atmosphere but for an
instant, in order to hurl into death's very depths the luckless one
they have dazzled." -- Marquis de Sade


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

end of thread, other threads:[~2005-04-01  6:53 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2005-03-31  0:44 Face - problem!! Surendra Singhi
2005-03-31 17:41 ` David Z Maze
2005-03-31 20:50   ` Surendra Singhi
2005-03-31 21:11     ` Rebecca Ore
2005-03-31 21:39       ` Surendra Singhi
2005-03-31 22:16         ` Rebecca Ore
2005-04-01  6:53           ` Surendra Singhi
2005-03-31 21:56 ` Surendra Singhi

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 NNTP newsgroup(s).