jgrid

32
J G R I D

Upload: hendrik-ebbers

Post on 24-May-2015

2.993 views

Category:

Technology


0 download

DESCRIPTION

Keynote about the JGrid. For more informations visit www.guigarge.com

TRANSCRIPT

Page 1: Jgrid

J G R I D

Page 2: Jgrid

Table of contents

• About me

• My projects

• The JGrid

• Demo

Page 3: Jgrid

About me

• Java, UI and Apple nerd

• Java Development Lead at SIC GmbH in Dortmund, Germany

• I just started open source development

Page 4: Jgrid

About GuiGarage

• Just another Java blog

• My daily experience with Java & Swing

• Home of my opensource projects

GestureWrapper jGridjRating

www.guigarage.com

Page 5: Jgrid

GestureWrapper

• Use Mac OS Multitouch gestures in every Java programm

• Forget about java.lang.NoClassDefFoundError

GestureUtilities.registerListener(panel, new GestureRotationListener() {...});

Page 6: Jgrid

JRating

• Simple JComponent for rating

• Renderer support for different skins

Page 7: Jgrid

JGrid

• Grid based visualization of Data

• Underlying data is administrated in a list

• Raw Data visualized by renderer

Grid

Page 8: Jgrid

Examples of grid based views

Page 9: Jgrid

Examples of grid based views

Page 10: Jgrid

Examples of grid based views

Page 11: Jgrid

When to use grids?

best overview for „simple“

data

best overview for „complex“

data

best overview for „illustrated“

data

three options for visualizing non-hirarchical collections of data

ListTable

Grid

Page 12: Jgrid

Integration

same data, different views

Page 13: Jgrid

Integration

• Fall back on swing classes

• Shares interfaces with JList

• Makes use of the swing renderer concept

Page 14: Jgrid

Develop a new example

I copied „iBooks“

I copied „iPhoto“

Let´s continue this series ...

Page 15: Jgrid

Let´s copy iTunes...

Page 16: Jgrid

... and implement GarageTunes

cross-platform(pure Java)

modern UI

Page 17: Jgrid

Collect some UI ideas

cool ListView

Controls

dribbble.com

Page 18: Jgrid

Collect some UI ideas

Grid of covers

dribbble.com

Page 19: Jgrid

Collect some UI ideas

switch betweenGrid & List

dribbble.com

Page 20: Jgrid

User Interface Sketching

Page 21: Jgrid

Implementing the model• Create a datamodel

• MP3 to data (MP3-Tags)

• Drag & Drop MP3 files

data is generated from MP3-Tags

all albums are stored in a ListModel

Page 22: Jgrid

Intermediate result

Controls

switch between views

drop MP3´s here

Page 23: Jgrid

Custom renderer

• Create a ListCellRenderer

• Activate antialiasing

• Use gradients

Page 24: Jgrid

Retrieve album covers

AWSECommerceService service = new AWSECommerceService();service.setHandlerResolver(new AwsHandlerResolver(awsSecretKey));AWSECommerceServicePortType port = service.getAWSECommerceServicePort();

ItemSearchRequest itemSearchRequest = new ItemSearchRequest();itemSearchRequest.setSearchIndex("Music");itemSearchRequest.setArtist(interpreter);itemSearchRequest.setTitle(albumName);itemSearchRequest.getResponseGroup().add("Images");

ItemSearch itemSearch = new ItemSearch();itemSearch.setAWSAccessKeyId(awsAccessKeyId);itemSearch.getRequest().add(itemSearchRequest);ItemSearchResponse response = port.itemSearch(itemSearch);

register @ aws.amazon.com

• Use amazon webservices

• Search by album name & interpreter

Page 25: Jgrid

Intermediate result

JRating as part of the renderer

covers from amazon

webservices

Page 26: Jgrid

Adding a gridview

• Add GridView

• Grid and list share selection & data model

• Add GridCellRenderer

model

Page 27: Jgrid

Intermediate result

pinch to zoom

Page 28: Jgrid

Finishing coding

• Play the MP3s

• mp3spi.jar

• Service provider interface

• Use javax.sound.*

Page 29: Jgrid

GarageTunes ToDosbetter user feedback:rollover effects on

controls

showing loading state for covers

(animation?)

GarageTunes Icon

Page 30: Jgrid

JGrid Roadmap

• Full support for ListSelectionModel (interval selection, etc.)

• Sorting & filtering

• Label renderer

• Cell & label editor

• OS specific UIs

Page 31: Jgrid

Summery• Use JGrid alternative to JList

• Best practice:

• Let the user change the view

• share the models between the views

• Integrate gestures as a alternative to your user guidance

• Subscribe to my Blog feedstay tuned for more

UI stuff!

Page 32: Jgrid

Q&A