android - 如何在 Android Studio 中自动完成 for 循环

标签 android for-loop android-studio keyboard-shortcuts code-completion

我正在使用 Android Studio,我正在尝试找到一种方法来使用一个非常常见的 我以前在eclipse中做的事情。 当我写(例如)一个for循环时,我写了“for”这个词然后我点击Ctrl+Space和eclipse自动完成到一个for循环包含所有参数,包括

for (int i=0 ; i<mCheckBoxArray.length;i++){
            mCheckBoxArray[i].setChecked(false);
        }

但现在,在 Android Studio 中,它只是自动完成到 for()。 for 循环只是一个例子, 有人知道如何在 android studio 中执行此操作吗?

最佳答案

您可以从建议列表中尝试 fori

enter image description here

关于android - 如何在 Android Studio 中自动完成 for 循环,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/29075797/

相关文章:

Android Emulator 给出错误 SO_REUSEPORT 并且调试不起作用

android - ADB 未检测到我的三星 Galaxy S6

java - 意外隐式转换为字符串 : layout tag was EditText error

javascript - 如何在循环内分配多个本地存储变量?

android - Android-onCreate中的finish()行为不一致

java - 尝试返回数组之和,方法调用错误

c++ - for 循环、读取和写入文件有困难

android-studio - Android Studio - 将项目与 Gradle 文件同步

java - Android 应用程序教程 content.xml 和 activity.xml 文件与教程有不同的代码

java - Android Studio 错误 : Not annotated parameter overrides @NonNull parameter 的含义