首页 > 代码库 > IntelliJ IDEA2016学习小结

IntelliJ IDEA2016学习小结

前提:本人菜鸟一枚,欢迎狂黑。

网上找资料基本上全是15之前的,从16开始感觉交互页面改了好多,所以学起来还是很吃力。

1,改JDK,IDEA 2016只支持jdk1.8,(亲测)本地系统必须装1.8才行。然后在IDEA的File-->Project Structure-->Project Settings-->Project中将SDK改成安好的jdk1.8的版本

版本太低报的错:

技术分享
Error:Internal error: (java.lang.UnsupportedClassVersionError) org/jetbrains/jps/android/model/impl/JpsAndroidModelSerializerExtension : Unsupported major.minor version 52.0java.lang.UnsupportedClassVersionError: org/jetbrains/jps/android/model/impl/JpsAndroidModelSerializerExtension : Unsupported major.minor version 52.0    at java.lang.ClassLoader.defineClass1(Native Method)    at java.lang.ClassLoader.defineClass(ClassLoader.java:800)    at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142)    at java.net.URLClassLoader.defineClass(URLClassLoader.java:449)    at java.net.URLClassLoader.access$100(URLClassLoader.java:71)    at java.net.URLClassLoader$1.run(URLClassLoader.java:361)    at java.net.URLClassLoader$1.run(URLClassLoader.java:355)    at java.security.AccessController.doPrivileged(Native Method)    at java.net.URLClassLoader.findClass(URLClassLoader.java:354)    at java.lang.ClassLoader.loadClass(ClassLoader.java:425)    at java.lang.ClassLoader.loadClass(ClassLoader.java:358)    at java.lang.Class.forName0(Native Method)    at java.lang.Class.forName(Class.java:270)    at java.util.ServiceLoader$LazyIterator.next(ServiceLoader.java:363)    at java.util.ServiceLoader$1.next(ServiceLoader.java:445)    at com.intellij.util.containers.ContainerUtilRt.copy(ContainerUtilRt.java:179)    at com.intellij.util.containers.ContainerUtilRt.newArrayList(ContainerUtilRt.java:168)    at org.jetbrains.jps.plugin.impl.JpsPluginManagerImpl.loadExtensions(JpsPluginManagerImpl.java:18)    at org.jetbrains.jps.service.impl.JpsServiceManagerImpl.getExtensions(JpsServiceManagerImpl.java:59)    at org.jetbrains.jps.model.serialization.JpsModelSerializerExtension.getExtensions(JpsModelSerializerExtension.java:46)    at org.jetbrains.jps.model.serialization.library.JpsSdkTableSerializer.getSdkPropertiesSerializer(JpsSdkTableSerializer.java:208)    at org.jetbrains.jps.model.serialization.library.JpsSdkTableSerializer.loadSdk(JpsSdkTableSerializer.java:102)    at org.jetbrains.jps.model.serialization.library.JpsSdkTableSerializer.loadSdks(JpsSdkTableSerializer.java:83)    at org.jetbrains.jps.model.serialization.JpsGlobalLoader$SdkTableSerializer.loadExtension(JpsGlobalLoader.java:144)    at org.jetbrains.jps.model.serialization.JpsGlobalLoader$SdkTableSerializer.loadExtension(JpsGlobalLoader.java:137)    at org.jetbrains.jps.model.serialization.JpsLoaderBase.loadComponents(JpsLoaderBase.java:61)    at org.jetbrains.jps.model.serialization.JpsGlobalLoader.loadGlobalComponents(JpsGlobalLoader.java:83)    at org.jetbrains.jps.model.serialization.JpsGlobalLoader.load(JpsGlobalLoader.java:73)    at org.jetbrains.jps.model.serialization.JpsGlobalLoader.loadGlobalSettings(JpsGlobalLoader.java:59)    at org.jetbrains.jps.model.serialization.impl.JpsSerializationManagerImpl.loadModel(JpsSerializationManagerImpl.java:38)    at org.jetbrains.jps.cmdline.JpsModelLoaderImpl.loadModel(JpsModelLoaderImpl.java:45)    at org.jetbrains.jps.cmdline.BuildRunner.load(BuildRunner.java:79)    at org.jetbrains.jps.cmdline.BuildSession.runBuild(BuildSession.java:267)    at org.jetbrains.jps.cmdline.BuildSession.run(BuildSession.java:125)    at org.jetbrains.jps.cmdline.BuildMain$MyMessageHandler$1.run(BuildMain.java:238)    at org.jetbrains.jps.service.impl.SharedThreadPoolImpl$1.run(SharedThreadPoolImpl.java:44)    at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)    at java.util.concurrent.FutureTask.run(FutureTask.java:262)    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)    at java.lang.Thread.run(Thread.java:744)
View Code

 2,有时候单机右键想运行程序的时候发现,没有下面带绿色图标的选项,原因是程序或者jar包或者依赖还在加载,没有加载完成

技术分享

3,Maven项目,初次新建Maven项目或者引进的时候,会加载好多的依赖jar包,需要很长时间

具体操作:点击Reimport All Maven Projects,会自动加载

技术分享

下面图片,在整个交互界面的右下角,用来隐藏界面边上的操作栏

技术分享

4,更改主题背景颜色,具体如何从网上下载第三方的主题jar包请参考:http://jingyan.baidu.com/article/90895e0fcd5e1d64ec6b0bb9.html

File->Settings...->Editor->Colors&Fonts中的Scheme下拉框中会有加入的新主题,选择对应的monokai主题。(如果下拉框中没有新加入的主题,可以再重启一次)

技术分享

 

IntelliJ IDEA2016学习小结