如何在Eclipse中的包资源管理器/大纲中配置树项的字体大小?
"首选项下的字体"中的哪个项目应该更改?
如何配置git log显示commit date而不是author date?
我试图在Ubuntu 9.10(gcc 4.4.1)中编译我的C程序.
我收到此错误:
Rect.cpp:344: error: ‘memset’ was not declared in this scope
Run Code Online (Sandbox Code Playgroud)
但问题是我已经包含在我的cpp文件中:
#include <stdio.h>
#include <stdlib.h>
Run Code Online (Sandbox Code Playgroud)
同样的程序在Ubuntu 8.04(gcc 4.2.4)下编译得很好.
请告诉我我错过了什么.
当我创建一个Intellij项目时,我不断收到以下内存错误.
我已经增加了我的堆大小idea.vmoptions:
-Xms128m
-Xmx2048m
-XX:MaxPermSize=1024m
-XX:ReservedCodeCacheSize=64m
-ea
Run Code Online (Sandbox Code Playgroud)
但我仍然得到这个错误:
Information:The system is out of resources.
Information:Consult the following stack trace for details.
Information:java.lang.OutOfMemoryError: Java heap space
Information: at com.sun.tools.javac.util.Position$LineMapImpl.build(Position.java:139)
Information: at com.sun.tools.javac.util.Position.makeLineMap(Position.java:63)
Information: at com.sun.tools.javac.parser.Scanner.getLineMap(Scanner.java:1105)
Information: at com.sun.tools.javac.main.JavaCompiler.parse(JavaCompiler.java:512)
Information: at com.sun.tools.javac.main.JavaCompiler.parse(JavaCompiler.java:550)
Information: at com.sun.tools.javac.main.JavaCompiler.parseFiles(JavaCompiler.java:804)
Information: at com.sun.tools.javac.main.JavaCompiler.compile(JavaCompiler.java:727)
Information: at com.sun.tools.javac.main.Main.compile(Main.java:353)
Information: at com.sun.tools.javac.main.Main.compile(Main.java:279)
Information: at com.sun.tools.javac.main.Main.compile(Main.java:270)
Information: at com.sun.tools.javac.Main.compile(Main.java:69)
Information: at com.sun.tools.javac.Main.main(Main.java:54)
Information: at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
Information: at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
Information: at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
Information: at java.lang.reflect.Method.invoke(Method.java:597)
Information: at com.intellij.rt.compiler.JavacRunner.main(JavacRunner.java:71)
Information:Compilation …Run Code Online (Sandbox Code Playgroud) 它说,在git社区书中
您可以做的另一个有趣的事情是使用'--graph'选项可视化提交图,如下所示:
Run Code Online (Sandbox Code Playgroud)$ git log --pretty=format:'%h : %s' --graph * 2d3acf9 : ignore errors from SIGCHLD on trap * 5e3ee11 : Merge branch 'master' of git://github.com/dustin/grit |\ | * 420eac9 : Added a method for getting the current branch. * | 30e367c : timeout code and tests * | 5a09431 : add timeout protection to grit * | e1193f8 : support for heads with slashes in them |/ * d6016bc : require time for xmlschema它将为提交历史记录行提供非常好的ASCII表示.
我该如何阅读此图表?如何420eac9从剩下的有什么不同?
你能否告诉我如何删除我在本地制作的更改?
在git,我可以做git checkout -- aFile.cpp,我怎么能做同样的事情hg?
在android中,使用静态变量是推荐的做法吗?例如,在Java中实现Singleton模式,我通常会这样做:
private static A the_instance;
public static A getInstance() {
if (the_instance == null) {
the_instance = new A();
}
return the_instance;
}
Run Code Online (Sandbox Code Playgroud)
此外,Android JVM何时清理它?
谢谢.
我想限制我的文本视图最多有5行,所以我做了:
<TextView
android:id="@+id/text"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:maxLines="5" />
Run Code Online (Sandbox Code Playgroud)
但是当我尝试将其配置为在文本被截断时添加"..."时,我添加了android:ellipsize ="end".我确实看到了......但是我的TextView只有2的最大值,而不是5.
您能否建议我如何制作最大5行的文本视图,并在截断时添加"..."?
谢谢.
我正在使用ubuntu 10.10,当我编译铬时,它说
remoting/host/event_executor_linux.cc:9: fatal error: X11/extensions/XTest.h: No such file or directory
但我已经安装了libx11-dev:
$ sudo apt-get install libx11-dev
Reading package lists... Done
Building dependency tree
Reading state information... Done
libx11-dev is already the newest version.
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
Run Code Online (Sandbox Code Playgroud)
请告诉我如何解决我的问题.
谢谢.