emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

cc-mode enhancement for Objective-C


From: Adrian Robert
Subject: cc-mode enhancement for Objective-C
Date: Sat, 13 Oct 2007 09:43:30 +0300

Hi,

This patch, against emacs-unicode-2/lisp/progmodes, enhances cc-mode's
handling of Objective-C:

- auto-indent method calls by colons (like XCode)
- syntax highlighting for method calls
- add more constants for font-lock highlighting

The original version was written by Michael Weber, and I updated it
for GNU emacs-21+.  I'd be interested in getting it into the emacs
distribution as it would provide a better out-of-box environment for
Objective-C developers.  I'm unsure if that means it needs to go into
cc-mode's own tree?  I sent a couple of messages a while ago to
cc-mode's own list but they may have been drowned in spam.
(http://article.gmane.org/gmane.emacs.cc-mode-general/2692)

(If there are any Obj-C devs using emacs on this list, perhaps they
could try the patch -- it's also built-in to the Emacs.app
distribution at http://emacs-app.sf.net/ )


Changed files:

cc-align.el (c-lineup-ObjC-method-call-colons): New function to indent
        method calls.

cc-fonts.el (c-complex-decl-matchers: c-font-lock-objc-methods): Add code to
        highlight method calls.

cc-langs.el (c-constant-kwds): Add constant keywords for ObjC boolean types,
        exception macros, and GNUstep ref-counting macros.

cc-menus.el (cc-imenu-objc-function): Drop obsolete calls to
        imenu-progress-message.

cc-vars.el (objc-method-arg-min-delta-to-bracket,
        objc-method-arg-unfinished-offset, objc-method-parameter-offset): New
        variables for customizing (c-lineup-ObjC-method-call).
        (c-offsets-alist): Add ObjC-specific rules.

Attachment: objc-enhance_v3.patch
Description: Binary data


reply via email to

[Prev in Thread] Current Thread [Next in Thread]