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

2343RE: [jasspa] some ME macros question

Expand Messages
  • Phillips, Steven
    Jul 23, 2008
    • 0 Attachment
      1. &sin is equivalent, see help page for more details.
       
      2. Yuo should probably use $buffer-fname and use &rsin "." $buffer-fname to locate the last '.', try executing the following macro code:
       
          !if &seq &set #l1 $buffer-fname ""
              set-variable #l1 $buffer-bname
          !endif
          !if &gre &set #l4 &rsin "." #l1 1
              set-variable #l2 &lef #l1 &sub #l4 1
              set-variable #l3 &rig #l1 &sub #l4 1
          !else
              set-variable #l2 #l1
              set-variable #l3 ""
          !endif
          ml-write &spr "File basename \"%s\", extension \"%s\"" #l2 #l3
      3) Not sure what you are trying to do here, but from the output of describe-binding command:
       
          "insert" ...................... 147 buffer-mode
      This binding is used to toggle overwrite mode and is bound to the insert key,
       
      Steve


      From: jasspa@yahoogroups.com [mailto:jasspa@yahoogroups.com] On Behalf Of Lechee.Lai
      Sent: 23 July 2008 13:58
      To: jasspa@yahoogroups.com
      Subject: [jasspa] some ME macros question

      since the first time using ME macros hope ME guys can share something
      for me
      1. is ME macros have function like strstr(...) position for first
      occurrence str

      2. how the get buffer extension, I only found $buffer-bname

      3. how to create buffer mode have own bind-key <retrun> for example
      I've trying buffer-bind- key but didn't active ... :-(

      Thanks
      Lechee

    • Show all 3 messages in this topic