打開org.eclipse.birt.report.engine.fonts_2.3.2.r232_20090202.jar文件,修改fontsConfig_pdf.xml文件中下面行
<font font-family="STSong-Light" catalog="Chinese" />






posted @ 2013-10-21 12:53 在路上... 閱讀(1774) | 評論 (0) | 編輯 收藏
posts - 33, comments - 46, trackbacks - 0, articles - 2 |
||||
Linux birt3.7環(huán)境中,部分導(dǎo)出pdf的漢字不能正確顯示,解決辦法:
打開org.eclipse.birt.report.engine.fonts_2.3.2.r232_20090202.jar文件,修改fontsConfig_pdf.xml文件中下面行 <font font-family="STSong-Light" catalog="Chinese" /> ![]() ![]() ![]() ![]() ![]() ![]() posted @ 2013-10-21 12:53 在路上... 閱讀(1774) | 評論 (0) | 編輯 收藏 1、下載
wget http://mirror.bit.edu.cn/apache/subversion/subversion-1.8.3.tar.gz 2、下載依賴包 ./get-deps.sh 3.install apr ./configur make make install 4.install apr-util ./configure --with-apr=/usr/local/apr make make install 5.update sqlite sqlite-amalgamation下載安裝最新版本sqlite,解壓 4.yum install glibc gcc expat expat-devel openssl openssl-devel 下載有關(guān)依賴包 5.compile svn ./configure --with-apr=/usr/local/apr --with-apr-util=/usr/local/apr --with-zlib \ --with-openssl --enable-maintainer-mode --with-serf=/usr/local/serf --enable-mod-activation 可能錯(cuò)誤現(xiàn)象: 只需要執(zhí)行以下命令,將apr和apr-util都卸載即可 rpm -e --allmatches apr-util --nodeps posted @ 2013-09-11 20:35 在路上... 閱讀(1799) | 評論 (0) | 編輯 收藏
1、打包文件命名規(guī)則
根據(jù)JavaEE規(guī)范,打包的EAR文件可以不適用部署描述符部署,因此需要使用一些默認(rèn)的約定規(guī)則,例如 •EJBs and client archives are packaged as .jar files. •Web applications are packaged as .war files. •Resource adapters are packaged as .rar files. •Enterprise applications are packaged as .ear files, and can contain other Java EE modules such as EJBs, JDBC, JMS, Web applications, and Resource Adapters. •Web Services can be packaged either as .war files or as .jar files, depending on whether they are implemented using Java classes or EJBs. Typically, the .war or .jar files are then packaged in an Enterprise Application .ear file. •Java EE libraries are packaged either as an Enterprise Application (.ear file) or as a standard Java EE module. •Client applications and optional packages are packaged as .jar files. •For an exploded archived Web application, in the absence of WEB-INF/web.xml descriptor, the name of the directory should have a .war suffix. •For an exploded archived Enterprise Application without a META-INF/application.xml descriptor, the directory should have an .ear suffix. Within the application, the directory of exploded Web module should have a .war suffix. Similarly, the exploded EJB module should have a .jar suffix and the exploded RAR module should have a .rar suffix. •If an exploded Enterprise Application contains no META-INF/application.xml descriptor, the order in which modules are deployed is undefined and is dependent on the underlying File.listFiles() method order. To ensure a specific order in which modules are deployed, you must add an application.xml descriptor and list the modules in the desired order. 如果在weblogic下面如果不使用上面的規(guī)則,則需要在application.xml 文件中指定對應(yīng)的uri路徑
posted @ 2013-04-08 16:18 在路上... 閱讀(3461) | 評論 (0) | 編輯 收藏 1、安裝編譯器 Objective-C的編譯器有很多,其中LLVM屬于從GCC發(fā)展出來的,主要使用在蘋果的平臺(tái)中,GNU可以使用GnuStep,網(wǎng)址是http://wwwmain.gnustep.org/,從這里可以下載Windows版本的gcc編譯器,配合codeblocks可以編譯調(diào)試object c程序。 2、安裝CodeBlocks IDE環(huán)境 下載地址:http://www.codeblocks.org/ 3、配置編譯器 安裝好codeblocks之后,進(jìn)入Settings->Compiler and debugger...,選擇GNU GCC Compiler編譯器,復(fù)制重新命名為“GNUstep MinGW Compiler“配置 編譯其他選項(xiàng)錄入:-fconstant-string-class=NSConstantString -std=c99 同時(shí)指定搜索目錄: 設(shè)置編譯器、連接器的搜索目錄 4、配置語法、文件類型,關(guān)鍵字等 添加文件類型支持 1) 進(jìn)入Settings->Environment... 2) 選擇 Files extension handling 添加*.m 3) 進(jìn)入 Project->Project tree->Edit file types & categories... 4) 在Sources, 下面添加 *.m到文件類型列表中. 添加語法高亮支持 1) 進(jìn)入 Settings->Editor... 2) 選擇 Syntax highlighting 進(jìn)入Filemasks.... 添加*.m 到文件類型列表中. 3) 進(jìn)入 Keywords... (緊靠Filemasks...) 添加下面的關(guān)鍵字到列表中
5、代碼測試 新建一個(gè)工程,修改main.c為main.m,錄入下面代碼 #import <Foundation/Foundation.h> int main (int argc, const char *argv[]) { NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init]; NSLog(@"%@",@"hello world"); [pool drain]; return 0; } 編譯運(yùn)行效果如下:
posted @ 2012-03-07 17:40 在路上... 閱讀(7172) | 評論 (5) | 編輯 收藏 在linux環(huán)境部署應(yīng)用時(shí),有時(shí)候需要用到AWT處理圖片的功能,典型的就是圖片的縮放處理等等,可能會(huì)遇到下面錯(cuò)誤: 甚至在默寫情況下面可能導(dǎo)致jvm崩潰,對于該問題的解決辦法是 1、配置java啟動(dòng)參數(shù)java -Djava.awt.headless=true 2、配置合適的DISPLAY屬性 例如通過當(dāng)前用戶啟動(dòng)了一個(gè)x window的圖形界面,可以將設(shè)置類似export DISPLAY=localhost:10.0這樣的環(huán)境變量將awt定位到一個(gè)實(shí)際存在的環(huán)境處理。 配置成功之后,可能可以看到這樣的提示 nl.ikarus.nxt.priv.imageio.icoreader.lib.ICOReader loaded, version: 0.06.064 build: 691 配置好之后就不會(huì)報(bào)錯(cuò)了 網(wǎng)上還有一種辦法,啟動(dòng)Xvfb 使用 ls -l /tmp/.X*lock 可以查看當(dāng)前啟動(dòng)了那些xwindow,如果發(fā)現(xiàn)X0,可能0.0已經(jīng)被使用了使用兩個(gè)命令: ------------------------------------ Xvfb :1 -screen 0 800x600x16 & 啟動(dòng)Xwindows的虛擬設(shè)備 export DISPLAY=localhost:1.0 配置本地環(huán)境 ------------------------------------ 參考:http://javatechniques.com/blog/linux-x11-libraries-for-headless-mode/ posted @ 2012-01-19 12:01 在路上... 閱讀(922) | 評論 (0) | 編輯 收藏 安裝好的CentOS會(huì)自帶OpenJdk,用命令 java -version ,會(huì)有下面的信息: java version "1.6.0" 最好還是先卸載掉openjdk,在安裝sun公司的jdk. 先查看 rpm -qa | grep java 顯示如下信息: java-1.4.2-gcj-compat-1.4.2.0-40jpp.115 卸載: rpm -e --nodeps java-1.4.2-gcj-compat-1.4.2.0-40jpp.115 還有一些其他的命令 rpm -qa | grep gcj rpm -qa | grep jdk 如果出現(xiàn)找不到openjdk source的話,那么還可以這樣卸載 yum -y remove java java-1.4.2-gcj-compat-1.4.2.0-40jpp.115 posted @ 2012-01-17 10:42 在路上... 閱讀(372) | 評論 (0) | 編輯 收藏 最近需要把a(bǔ)ndroid手機(jī)root一下,找到了這個(gè)刷機(jī)精靈,的確很好用,經(jīng)過測試,在華為C8650,U8800,HTC S710D,HTC Sensation上面都測試通過,對于不想深入研究的用戶來說,的確夠簡單!推薦一下。 posted @ 2012-01-14 16:28 在路上... 閱讀(431) | 評論 (0) | 編輯 收藏 碰到中文亂碼的時(shí)候,可以考慮使用一個(gè)熟悉的中心字符串入手進(jìn)行調(diào)試跟蹤轉(zhuǎn)換過程的變化,這里記錄一下“中文”漢字的編碼變化過程 UNICODE編碼:4e2d 6587 GBK編碼:d6d0 cec4,byte[]={-42,-48,-50,-60} UTF8編碼:e4 b8 ad e6 96 87,byte[]={-28,-72,-83,-26,-106,-121} ISO8859-1編碼:如果試圖將byte[]={-42,-48,-50,-60}采用new String(byte[],”iso8859-1”)讀取,由于不能正確轉(zhuǎn)換,所以是2個(gè)問號(hào)byte[]={63,63} Javascript:可以使用var str=”\u4E2D\u6587”;來表示 HTML中,可以使用中文,相當(dāng)于吧16進(jìn)制轉(zhuǎn)換為10進(jìn)制,再加上轉(zhuǎn)義控制&#和;結(jié)尾。 如果需要從utf byte[]和GBK byte[]之間互相轉(zhuǎn)換,在支持unicode的java平臺(tái),可以使用下面的轉(zhuǎn)換規(guī)則 byte[] utf8={-28,-72,-83,-26,-106,-121}; String str=new String(utf8,”utf-8”);//轉(zhuǎn)換為正確的中文 byte[] gbk=str.getBytes(“GBK”); 或者: byte[] gbk={-42,-48,-50,-60}; String str=new String(utf8,"GBK");//轉(zhuǎn)換為正確的中文 byte[] utf8=str.getBytes("utf-8") 注意上面的byte[]為java的,與.net不一樣,需要轉(zhuǎn)換 posted @ 2012-01-14 16:16 在路上... 閱讀(326) | 評論 (0) | 編輯 收藏 1、使用apktool反編譯
apktool d [file.apk] [path] 2、根據(jù)需要修改配置文件、smali文件,如果需要反編譯成jar文件,可以使用dex2jar,然后使用jd-gui查看代碼 3、重新編譯成apk文件 apktool b [path] file.apk 4、簽名 使用JDK自帶工具keytool創(chuàng)建keystore c:\>keytool -genkey -alias android.keystore -keyalg RSA -validity 10000 -keystore mystore.keystore 其中validity 為有效期天數(shù),這里創(chuàng)建的keystore文件也可以供eclipse打包apk時(shí)使用,注意記住密碼。 使用JDK自帶工具jarsigner簽名apk文件,需要輸入keystore的密碼 c:\>jarsigner -verbose -keystore mystore.jks -signedjar [簽名后的文件.jar] [需要簽名的文件.apk] my 5、安裝到手機(jī)上面測試 adb -d install -r signed-file.apk posted @ 2012-01-04 16:07 在路上... 閱讀(568) | 評論 (0) | 編輯 收藏 摘要: 轉(zhuǎn)載:http://pallergabor.uw.hu/androidblog/dalvik_opcodes.html
Dalvik opcodes
Author: Gabor PallerVx values in the table denote a Dalvik register. Depending on the instruction, 16, 256 or 64k r... 閱讀全文
posted @ 2012-01-04 15:59 在路上... 閱讀(49809) | 評論 (5) | 編輯 收藏 已經(jīng)有一段時(shí)間了,經(jīng)過半天時(shí)間的多次嘗試,還是沒能在redhat EL6上面安裝成功oracle 10g,雖然說該版本的oracle沒有在經(jīng)過redhat el6的認(rèn)證,但是網(wǎng)絡(luò)上還是可以找到不少相關(guān)的文章好像是可以安裝成功的,不過通過這次嘗試,也獲得不少相關(guān)當(dāng)面的經(jīng)驗(yàn),那就是接下來重裝為CentOS5.5,然后安裝Oracle 10g,一次成功,1個(gè)小時(shí)內(nèi)完成,呵呵。 接下來再記錄一下相關(guān)的一些資料 posted @ 2011-12-28 11:59 在路上... 閱讀(301) | 評論 (0) | 編輯 收藏 為了安裝軟件包方便,通常需要配置使用yum來安裝,或者在機(jī)房里面,不能使用互聯(lián)網(wǎng)的時(shí)候,不希望使用rpm來安裝,如何配置等等問題,為了方便以后使用,記錄下備忘: 1、基于ISO安裝包的repo配置 首先需要將iso文件mount起來,可以使用mount –o loop /FILE_TO_DVD.iso /mnt/cdrom 進(jìn)入yum repo目錄:/etc/yum.repos.d,編輯一個(gè)文件iso.repo
把原來的文件CentOS-Base.repo CentOS-Media.repo可以加個(gè).bak擴(kuò)展名備份一下。 接下來安裝軟件就可以方便的使用類似這樣的命令安裝了 使用yum list可以測試一下是否包含了剛才的軟件庫,或者可以使用'yum clean all' 清除metadata 2、配置yum代理 可以修改/etc/yum.conf 文件,加入: # 代理服務(wù)器 - proxy server:port number 或者可以通過環(huán)境變量加入當(dāng)前用戶的全局代理,可以修改.bash_profile文件: http_proxy="http://yum-user:qwerty@mycache.mydomain.com:3128" posted @ 2011-12-28 11:50 在路上... 閱讀(374) | 評論 (0) | 編輯 收藏 通過下面方式可以發(fā)布jboss的naming服務(wù)
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() java.naming.provider.url=jnphost.mycompany.com:1099 java.naming.factory.initial=org.jnp.interfaces.NamingContextFactory java.naming.factory.url.pkgs=org.jboss.naming 連接參數(shù)如上 posted @ 2011-06-20 11:23 在路上... 閱讀(390) | 評論 (0) | 編輯 收藏 摘要: 通常,如果需要在應(yīng)用中使用tomcat的jndi數(shù)據(jù)源,需要修改context配置,例如
<?xml version="1.0" encoding="UTF-8"?>
<Context path="/app" docBase="E:\appweb">
<Resource name="jnd... 閱讀全文
posted @ 2011-01-02 17:36 在路上... 閱讀(12341) | 評論 (0) | 編輯 收藏 通過jconsole可以遠(yuǎn)程監(jiān)控web應(yīng)用服務(wù)器,可以在啟動(dòng)參數(shù)中加上
-Dcom.sun.management.jmxremote -Dcom.sun.management.jmxremote.port=8888 -Dcom.sun.management.jmxremote.ssl=false -Dcom.sun.management.jmxremote.authenticate=false posted @ 2011-01-02 17:14 在路上... 閱讀(873) | 評論 (0) | 編輯 收藏 |
||||