http://blog.csdn.net/fhy_2008/article/details/6318498今天在論壇看到有人問怎麼更改progressDialog的字型,調查了一下,終於搞清楚了,現在分享下。 (一)先把完整代碼貼出來: /** Called when the activity is first created. */ private static final int DLG_SHOW = 0; private TextView
在android4.0源碼中,mm編譯apk時出現下面的錯誤:make: *** No rule to make target `out/target/common/obj/JAVA_LIBRARIES/android_stubs_current_intermediates/javalib.jar', needed by `out/target/common/obj/APPS/NativeTimer_intermediates/classes-full-debug.jar'.
例如使用QObject::connect( video_frame_process, SIGNAL(ImageReady(cv::Mat )),this, SLOT(ShowImage(cv::Mat)));編譯沒問題,但啟動並執行時候發現收不到ImageReady的signal,沒有觸發ShowImage,查看debug的output會看到Make sure 'cv::Mat' is registered using
Assume you have a method isSubstring which checks if one word is a substring of another Given two strings, s1 and s2, write code to check if s2 is a rotation of s1 using only one call to isSubstring (i e , “waterbottle” is a rotation of “erbottlewat”
使用如下代碼時,發現字型大小不會變大,反而會變小:size = (int) mText.getTextSize() + 1;mText.setTextSize(size);後來發現getTextSize傳回值是以像素(px)為單位的,而setTextSize()是以sp為單位的,兩者單位不一致才造成這樣的結果。這裡可以用setTextSize()的另外一種形式,可以指定單位:setTextSize(int unit, int size)TypedValue.COMPLEX_UNIT_PX :