How can I stop Android Studio from wrapping method lines and constructors?
This is how Android Studio currently does it:
A class
public class Foo {
public Foo(Context context, AttributeSet attrs) { super(context, attrs); }
}
A Method
public static void doSomething(Foo foo) { foo.doWork(); }
This is how I would like it:
A class
public class Foo {
public Foo(Context context, AttributeSet attrs) {
super(context, attrs);
}
}
A Method
public static void doSomething(Foo foo) {
foo.doWork();
}
Navigate to
Settings >> Editor >> General >> Code Folding
You will find One-line methods
checked there. Uncheck it. There are also other settings, you can change as you need. I attached the screenshot too.
Finally Restart your IDE. Done!
Hope this is helpful.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With