Android的工作室 - 在项目中的所有文件名都是红色,但没有错误都是、文件名、但没、红色

2023-09-05 10:55:52 作者:雁归来

我进口ADT项目的Andr​​oid工作室。我有一吨的错误,但我可以解决他们所有。我不认为怎么做是在这种情况下,重要的是,我不能反正记得所有的错误。该项目现在运行没有错误,但不知何故,Android的工作室,标志着所有文件红色。只是文件名,也有在code中没有错误。我试图清洗和重新启动。

I imported a ADT Project in Android Studio. I got a ton of errors, but I could fix them all. I don't think the "how" is important in this case, I wouldn't be able to recall all the errors anyways. The project runs now without errors, but somehow Android Studio marks all files red. Just the filenames, there are no errors in the code. I tried cleaning and restarting.

是否有人领教过这样的事情?或者,也许一个相关问题的IntelliJ有人可以解决?

Did someone experience something like this before? Or maybe a related problem with IntelliJ someone could solve?

编辑: 这是版本控制。该项目未版本控制,但在一个SVN控制的文件夹。那是什么红得表示。一个解决办法是将项目复制到另一个文件夹或将文件添加到版本控制。

It was the version control. The project was unversioned but in a SVN controlled folder. Thats what the red was indicating. A solution could be to copy the project to a different folder or to add the files to version control.

推荐答案

也许你看到了Android的工作室用来显示文件的状态,文件状态的颜​​色。打开设置,然后转至编辑>颜色和放大器;字体>文件状态。在这里,你可以看到所有的不同颜色的含义。我的猜测是,你微红文件是颜色,因为你还没有被添加到他们到源代码管理。

Perhaps you are seeing the File Status colors that Android Studio uses to show the status of the file. Open Settings and go to Editor > Colors & Fonts > File Status. Here you can see what all of the different colors mean. My guess is that your reddish files are that color because you have not yet added them to source control.