X: Align Fields/variables groups Follow
How exactly is this new alignment option meant to work?
Currently for fields annotations and blank lines prevent the alignment, for example in
@In
private GridBean gridBean;
private String gridId;
Also to me it seems that currently local variables are never aligned.
Then: Is there a way to align multiline parameter declarations, for example
public ExtJsPageResponse<RoleDto> getRoles(@FormParam("start") int start,
@FormParam("limit") int limit,
@FormParam("sort") String sortKey,
@FormParam("dir") String sortDirection,
@FormParam("filterItems") boolean queryFilterItems,
@FormParam("filters") FilterItemsDto inFilterItems)
{
Please sign in to leave a comment.
Hi Stephen,
Blank lines break alignment by design. I.e. the idea is that you always can insert blank lines between the fields if you want to ensure that they are not aligned.
Annotation shouldn't prevent alignment. I created corresponding ticket for that - IDEA-56946
About alignment in columns for local variables - IDEA-56947
About method parameters alignment - there is a dedicated option for that - 'Project settings -> Code Style -> Alignment and Braces -> Align when multiline -> Method parameters'
Denis