POV-Ray : Newsgroups : povray.unix : povray mode for emacs update? : Re: povray mode for emacs update? Server Time
23 Apr 2024 16:12:55 EDT (-0400)
  Re: povray mode for emacs update?  
From: Jonathan Bush
Date: 15 Oct 2021 11:15:00
Message: <web.616999c2f99d6e74d80ced0afde6c206@news.povray.org>
=?utf-8?Q?Harald_J=C3=B6rg?= <haj### [at] posteode> wrote:
>
> I also found a the 'pavement' pattern and the 'albedo' keyword for
> diffuse reflection not yet included in the keyword list - but I haven't
> done a comprehensive check.  The "Keywords" section in the docs would
> provide the relevant test cases, it contains many I've never used and
> some I've never heard of.

Here is a passage with regards to elseif, taken from the changes list at
<http://www.povray.org/download/changes.txt>
------------------------------
Other SDL Changes/Enhancements
------------------------------

  Added #elseif statement; the #if, #ifdef and #ifndef directives syntax is
  changed as follows:

    IF_DIRECTIVE:
      #if ( Cond ) TOKENS... [ELSE_DIRECTIVE] #end
    IFDEF_DIRECTIVE:
      #ifdef ( IDENTIFIER ) TOKENS... [ELSE_DIRECTIVE] #end
    IFNDEF_DIRECTIVE:
      #ifndef ( IDENTIFIER ) TOKENS... [ELSE_DIRECTIVE] #end

    ELSE_DIRECTIVE:
      #else TOKENS... |
      #elseif ( Cond ) TOKENS... [ELSE_DIRECTIVE]

  Example:

    #if (Foo)
      #debug "Foo is true\n"
    #elseif (Bar)
      #debug "Foo is false, but Bar is true\n"
    #else
      #debug "Foo and Bar are both false\n"
    #end


> Adding keywords for highlighting isn't that difficult.  I found the
> Emacs Lisp tutorial (comes with Emacs) helpful to get started.
>
> If Marco (melmothx) doesn't reply within decent time, I could give it a
> try and provide a pull request for his repository.
> --
> Cheers,
> haj

I am grateful for your offer!


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.