Function: c-lineup-java-inher
c-lineup-java-inher is a byte-compiled function defined in
cc-align.el.gz.
Signature
(c-lineup-java-inher LANGELEM)
Documentation
Line up Java implements and extends declarations.
If class names follow on the same line as the implements/extends
keyword, they are lined up under each other. Otherwise, they are
indented by adding c-basic-offset to the column of the keyword.
E.g.:
class Foo class Foo
extends extends Cyphr,
Bar <-> Bar <- c-lineup-java-inher
<--> c-basic-offset
Works with: inher-cont.
Source Code
;; Defined in /usr/src/emacs/lisp/progmodes/cc-align.el.gz
(defun c-lineup-java-inher (langelem)
"Line up Java implements and extends declarations.
If class names follow on the same line as the implements/extends
keyword, they are lined up under each other. Otherwise, they are
indented by adding `c-basic-offset' to the column of the keyword.
E.g.:
class Foo class Foo
extends extends Cyphr,
Bar <-> Bar <- c-lineup-java-inher
<--> c-basic-offset
Works with: inher-cont."
(save-excursion
(goto-char (c-langelem-pos langelem))
(forward-word-strictly 1)
(if (looking-at "[ \t]*$")
c-basic-offset
(c-forward-syntactic-ws)
(vector (current-column)))))