[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: cc-mode help - how to support literal strings in C# syntax?
From: |
Andreas Roehler |
Subject: |
Re: cc-mode help - how to support literal strings in C# syntax? |
Date: |
Fri, 01 Jan 2010 17:04:59 +0100 |
User-agent: |
Thunderbird 2.0.0.19 (X11/20081227) |
Hi again,
with little experimental form below
address@hidden' is detected. See screenshot
attached.
It's core is built upon thingatpt-utils-base.el from
https://code.launchpad.net/s-x-emacs-werkstatt/
Reporting borders and all kind of at-point-functions
will be available likewise - it's just to put new form
address@hidden' into a template.
If that kind of functions being useful, needed
functions from thingatpt-utils-base.el might be
extracted into a standalone app.
Andreas
;;;;;;;;
(require 'thingatpt-utils-base)
;; @-Prefixed-csharp-string
(put '@-prefixed-csharp-string 'beginning-op-at
(lambda ()
(beginning-of-form-base "@\"" "address@hidden"" nil 1)))
(put '@-prefixed-csharp-string 'end-op-at
(lambda ()
(when (looking-at "@\"")
(end-of-form-base "@\"" "address@hidden"" nil 1))))
(defun @-prefixed-csharp-string (&optional arg)
"Returns @-prefixed-csharp-string at point if any, nil otherwise. "
(interactive "P")
(th '@-prefixed-csharp-string arg (interactive-p)))
;;;;;;;