Loading ...
Sorry, an error occurred while loading the content.

491Euphoria hilight

Expand Messages
  • Rodolfo Valeiras Reina
    Dec 11, 2001
    • 0 Attachment
      Hello all.

      I've wrote a macro file for add hilight support for the Euphoria programming
      language (http://www.rapideuphoria.com). I hope it's ok. A few questions are
      at the end.


      Create the file hkeuphoria.emf in the macros directory:

      !if &sequal .hilight.euphoria "ERROR"
      set-variable .hilight.euphoria &pinc .hilight.next 1
      !endif

      0 hilight .hilight.euphoria 1 $global-scheme

      hilight .hilight.euphoria 2 "--" .scheme.comment

      hilight .hilight.euphoria 1 "and" .scheme.keyword
      hilight .hilight.euphoria 1 "by" .scheme.keyword
      hilight .hilight.euphoria 1 "constant" .scheme.keyword
      hilight .hilight.euphoria 1 "do" .scheme.keyword
      hilight .hilight.euphoria 1 "else" .scheme.keyword
      hilight .hilight.euphoria 1 "elsif" .scheme.keyword
      hilight .hilight.euphoria 1 "end" .scheme.keyword
      hilight .hilight.euphoria 1 "exit" .scheme.keyword
      hilight .hilight.euphoria 1 "for" .scheme.keyword
      hilight .hilight.euphoria 1 "function" .scheme.keyword
      hilight .hilight.euphoria 1 "global" .scheme.keyword
      hilight .hilight.euphoria 1 "if" .scheme.keyword
      hilight .hilight.euphoria 1 "include" .scheme.keyword
      hilight .hilight.euphoria 1 "not" .scheme.keyword
      hilight .hilight.euphoria 1 "or" .scheme.keyword
      hilight .hilight.euphoria 1 "procedure" .scheme.keyword
      hilight .hilight.euphoria 1 "return" .scheme.keyword
      hilight .hilight.euphoria 1 "then" .scheme.keyword
      hilight .hilight.euphoria 1 "to" .scheme.keyword
      hilight .hilight.euphoria 1 "type" .scheme.keyword
      hilight .hilight.euphoria 1 "while" .scheme.keyword
      hilight .hilight.euphoria 1 "else" .scheme.keyword
      hilight .hilight.euphoria 1 "with" .scheme.keyword
      hilight .hilight.euphoria 1 "without" .scheme.keyword
      hilight .hilight.euphoria 1 "xor" .scheme.keyword

      hilight .hilight.euphoria 1 "object" .scheme.type
      hilight .hilight.euphoria 1 "sequence" .scheme.type
      hilight .hilight.euphoria 1 "atom" .scheme.type
      hilight .hilight.euphoria 1 "integer" .scheme.type

      hilight .hilight.euphoria 4 "\"" "\"" "\\" .scheme.string
      hilight .hilight.euphoria 4 "'" "'" "\\" .scheme.string

      define-macro fhook-euphoria
      set-variable $buffer-hilight .hilight.euphoria
      ml-write "Euphoria file loaded"
      !emacro
      ml-write "[MicroEmacs Euphoria file hook loaded]"

      Add these lines to the me.emf file:

      add-file-hook ".ex .exw .exu .e .ew .eu" "fhook-euphoria"
      1 add-file-hook "^#!/.*exu" "fhook-euphoria"
      1 add-file-hook "-!-[ \t]*euphoria[ \t]*-!-" "fhook-euphoria"


      The official editor for Euphoria use colors for matching brackets inside
      other brackets. For example, in

      s = upper(QuitaEspacios(Linea[1..Pos_Igual-1]))
      A B BA

      "A" parenthesis appear in yellow and "B" brackets in white. It's this
      possible using MicroEmacs?

      The macro etfinsrt replace $USER_NAME$ by <unknown>, despite an user name is
      set and his value is assigned to $MENAME. This is because the registry entry
      /history/user-name is not defined? Why is not defined?

      Aparent errors in the documentation:

      The macro ascii-time is defined in utils-emf, not in misc.emf

      In the title bar of the hlp version of the documentation appears ME'00, not
      ME'01.

      In this example of the Language Templates doc is needed an numeric
      argument?

      add-file-hook "-!-[ \t]*foo.*-!-" fhook-foo


      Regards,

      Rodolfo Valeiras