Tim,

I think you found the need for a new variable, which I will call
ess-first-arg-indent

The default value is the column after the "(" for the function header.
You want it to be set to 2.
Defining the variable in ess-custom.el in the section labeled
;;;*;;; Indentation parameters
and adding it to all the styles in ess-style-alist
is easy enough.

Finding where it needs to be used and writing the code is harder.  I think
it needs to happen in
the defun ess-calculate-indent in ess-mode.el.  I am not going to be able
to do this anytime soon.


There is a similar indentation nuisance that I have run into, and that I
will not be fixing soon.

## breaking this line into two lines
abc <- list(a=c(def=1, ghi=2))

## gives this, with non-alignment of def and ghi
abc <- list(a=c(def=1,
              ghi=2))

## I would prefer alignment as in
abc <- list(a=c(def=1,
                ghi=2))

## and you need to see this in a mono-width font.  My email shows a
proportional font so it isn't visible until
## I copy it to a tmp.r buffer.

Rich
On Sun, Nov 13, 2011 at 12:24 AM, Tim Hesterberg <timhesterberg@gmail.com>wrote:

> The current ESS indentation is:
>
> my.very.very.long.variable.name <-
>  MyVeryVeryLongAndDescriptiveFunctionName(
>
> my.first.argument.which.is.a.long.expression,
>
> my.second.argument.which.is.a.long.expression)
>
> I would like this instead:
>
> my.very.very.long.variable.name <-
>  MyVeryVeryLongAndDescriptiveFunctionName(
>      my.first.argument.which.is.a.long.expression,
>      my.second.argument.which.is.a.long.expression)
>
> Is there a way to get that?
>
> I'm running ess-5.14.
> I didn't see a variables to set for this, in the list of variables found by
> doing describe-mode in a .R buffer.  I tried some of them.
> I also tried
> (ess-set-style 'OWN)
> as well as the other options, and none of the options gave the desired
> behavior.
>
> Thanks,
> Tim Hesterberg
>
> ______________________________________________
> ESS-help@r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/ess-help
>

	[[alternative HTML version deleted]]

