Phil Race has posted a blog post over at the JavaFX Blog on the addition of LCD text support in the latest JavaFX 2.1 developer preview.
LCD sub-pixel text has become a must-have for many Windows desktop users, who have become accustomed to its superior legibility and less blocky appearance at smaller point sizes over hinted black and white text, and being sharper than grey scale anti-aliased text at the same size.
Java SE has supported LCD subpixel text on AWT heavyweights and also on Swing components using Java 2D for many years. However up until now, JavaFX has supported only more Mac OS X-like grey scale smoothed text.
For the JavaFX 2.1 release we’ve added the ability to use Windows-style LCD sub-pixel rendering. All the JavaFX UI controls will be LCD-text enabled by default on Windows, as will “WebView”, the Webkit-based node for rendering Web content.
Applications can also opt-in to use LCD text on the low-level scenegraph “Text” node by a new API : Text.setFontSmoothingType(FontSmoothingType.LCD));
These intros become harder as the weeks go by. The core message is always the same: Enoy! 🙂
- It’s another week, so another developer preview release of JavaFX 2.1 is out for Linux, Mac OS and Windows. This week we are up to build 10.
- With the availability of JavaFX 2.1 developer preview builds for Linux, a number of people and news websites covered this. For example: Weigi Gao, Jaxenter, and H online.
- Jasper Potts has put up two blogs posts here at FX Experience. The first post discusses his work on extending the PathBuilder class to include more convenience methods, and secondly he has a post about extending the charts code shipped with JavaFX to apply curve fitting.
- Speaking of the builder classes shipped with JavaFX, Michael Heinrichs, a member of the JavaFX team, has put up a post about the advantages of the JavaFX builder APIs.
- Kevin Farnham put up a blog post over at Java.net about getting started with the JavaFX 2.1 developer preview on Linux.
- Dustin Marx talks about the @DefaultProperty annotation used in the JavaFX APIs, and what this means for you when building user interfaces with FXML.
- The GroovyFX library now has a new website.
- Thierry Janaudy has a blog post showing how to put a pie chart inside a TableView using a custom cell factory, whilst programming in Scala.
- Sébastien Bordes has a post detailing how to build and package JavaFX application with Maven.
- Narayan has blogged about the ‘include’ and ‘define’ tags in FXML.
- Yet another DatePicker control has appeared, pushing my count to at least five such controls. This week it belongs to Altuğ Uzunali.
- Andrew Krizhanovsky let me know about his wikokit project, which he describes as a “Machine-readable Wiktionary with GUI now ported to JavaFX 2.0. This version contains huge drop-down list of available languages.”
These conclusions are equally difficult. The core message is always the same: I hope you enjoy what I just linked to, and I hope it was good enough to see you again in a weeks time (where hopefully my introductions and conclusions are slightly more considered!) 🙂
I was experimenting today with extending AreaChart to do curve fitting for some example code I was hacking on. It is also a example of what can be done with styling JavaFX charts with CSS. Here is the result:
I came across the interesting blog “JavaFx and HTML5 differences” by Chika Okereke. Looking at the example code and comparing to the HTML Canvas version I thought the Java code could be made less verbose and easier to read.
Path path_4 = new Path();
ObservableList shape_4 = path_4.getElements();
So I hacked together a Extended version of the PathBuilder that ships with JavaFX 2.0 adding methods for all of the path elements like moveTo() etc. The end result seems much cleaner code to me, what do you think?
Code with new Builder
Path path4 = PathBuilderExtended.create()
This seemed a lot cleaner and simpler to read. I have filed a feature request RT-19266 in JIRA to add this to the platform. Feel free to comment on the bug if you any feedback or better suggestions. Also I have attached a implementation of this builder to the bug so you can see how it would be implemented or use it with your code today.
A heap of links this week (partly because I’m a day and a half late with this post!). Hopefully something for everyone 🙂
Catch you all in a weeks time.