About How to Make Phantomjs Render Google Embeded Web Fonts Correctly
Currently, before 1.8.1 version, phantomjs doesn’t support WOFF files, a fix is to use https://github.com/Vitallium ‘s commit which has fixed WOFF file support issue. But you have to compile it from source, it takes a long time if your computer is not powerful enough. On my Quad-Core i7 laptop, it uses 10-15 minutes. On my EC2 dul-core middle instance, it compiles forever…
The Web Open Font Format (WOFF) is a font format for use in web pages
To do:
1) Checkout PhantomJS 1.X version as described in the official instruction: http://phantomjs.org/build.html
1 2 3 4 5 6 7 8 9 10 11 12 13 14 |
|
Note that by don’t ./build.sh now, cause it’s the master branch of the phantomjs, so, after checkout, don’t build.
2) Add the remote repo which contains the needed branch:
About How to Embed Image Into One Single Html
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 |
|
Java Core Series 2: About Java Socket
COMMING SOON …
Java Core Series 1: About Java IO
COMMING SOON …
About How to Get Mime Types Using Java
1. using javax.activation.MimetypesFileTypeMap
1 2 |
|
1 2 3 4 5 6 |
|
2. Write yourself
Journal
今天做了一些关于Docx转换Html的研究, 发现Java现在并无什么很完美的解决方案, 主要是转换效果不佳, 公司想要的Header里的图片没有任何一个Java的开源解决方案可以完美的转换的. 一天搞来搞去, 没有任何成果. 这半年时间做开发的工作, 感觉自己并非非常关心具体的细节实现, 而是对数据传输和系统架构比较有兴趣. 未来怎么走, 变数还很大.
三月的目标:
- 签证问题搞清楚, 争取准时寄出.
- 选择一门脚本语言或者更加高层的语言学习熟悉.
- 把pdftojson完善, 提高并发性能.
- 完善rtf,docx,doc to html, 提高并发性能.
- 最好把MQ实现出来.
About How to Convert Docx/doc/rtf Into Html Using JAVA
Actually, there is one solution, “One sulution to rule them all” . That is to use OpenOffice as the background service to convert them all. You can implement this remote call by yourself, but someone already wrote a java library to provide a high level API for us to use called JODConverter.
http://code.google.com/p/jodconverter/
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 |
|
How to Use Libsvm to Do Classification With Java
A real example from data preparing to train the model to finally do the classification included
Comming soon…
Octopress的中文使用测试
试试中文在Octopress中的表现如何
测试文章:
来自美国宇航局太阳动力学天文台的最新观测,显示了太阳表面发生新的喷发事件。太阳耀斑和日冕物质抛射等太阳活动可导致外层结构出现的变化,这些复 杂的现象与太阳表面大气运动相联系,并受到磁场线的影响。在2012年7月19日,太阳表面爆发了一次强度较大的太阳耀斑事件,发射出大量的光和辐射,接 下来就是日冕物质抛射阶段,在磁场作用下,整个爆发事件变得异常诡异,这一现象被称为“日冕雨”。