TableView data selection by mouse press

Well It has been quiet long time but I found it would be time for me to blog small post about making the table cell selection in JavaFX. Normally TableView has facility to select the cell or row by using Ctrl,Command (Shortcut Key) and Shift button. You can easily select the data using your keyboards. But when it comes for ease to user interaction using mouse is vital. So today we will go through how to create selection of data by mouse. Lets categorize them in two parts. Read the rest of this entry »

Tags: , , , ,

ListCell Animation in ListView

After a long time I am back again with new stuffs. I have seen that JavaFX has got so many demand nowadays. Lots of people are requesting for something new something wow effect. In the same way one of my colleagues told me what if we have listview got some effects on scrolling the list. I got some dig around JavaFX Animation API and did some animation with ListCell but I thought it would be great if I share my works to you guys.

First We got to revamp what is the Listcell. ListCell are designed for making user to display text content in list format. But we can override these and make our own like displaying images,shapes and other controls as well.

ListCell inherits the character of Labeled so in default ListCell only displays the text content.If you want some control in your listcell other than label then there are some bunch of cellfactory in javafx.scene.control.cell package.

Every ListCell are being rendered according to the cellFactory implementation so you are free to implement your own cellFactory to make the listcell even more customizable. I had posted about TableCell customization which utilizes use of cellFactory (TableView Cell Modify)

Lets roll with the ListCell customization.
Read the rest of this entry »

Tags: , , ,

Lights in JavaFX 3D

It has been so long day that I have not blogged but today I am here with some new stuffs related to the JavaFX 3D. Before touching in JavaFX it is better to introduce some lights definition. There are many lights types but let not go more we are relating only two lights

Requirement:

  • JDK 8 EA build ver. 91 or later (or JDK8 General Release Version)

 
 
 Ambient Light 
An ambient light source represents a fixed-intensity and fixed-color light source that affects all objects in the scene equally. Upon rendering, all objects in the scene are brightened with the specified intensity and color. This type of light source is mainly used to provide the scene with a basic view of the different objects in it.
 

ambient lights javafx


Read the rest of this entry »

Tags: , , , , , ,

Pagination and style in JavaFX TableView

Hello geeks, I think most of you have already knew that JavaFX 2.2 contains the “Pagination” which is really awesome although it is not pretty hard to make our own. Lets first look over how the Pagination actually looks like.

 

1. LOOKS

Normal Pagination

Ok now that was just the normal Pagination you can modify and change as per your need . You can just style it using some CSS codes.
Read the rest of this entry »

Tags: , , ,

3d Object (Cube) Concept to Code Part 2

After all I am near to Christmas, My hands are shaking so cold: P. Today I’m writing about the post of how to create a 3d cube box in JavaFX. Well I’ve you have already read my previous post of how to create Cube in JavaFX using the technique I’ve described.

 

We’ll create here one function which can create a cube box using parameter of width. Even if we create a 3D in JavaFX, The Object will not look like a real 3D because there is absence of good Camera stuffs class. But hope these things will arrive very soon.

Here is the JavaFX function which can create the Cube3D
Read the rest of this entry »

Tags: , , , ,