public class NoGroupRenderer extends AbstractGridGroupRenderer
Alternate group renderer for the Gallery widget. This group renderer does not draw group titles. Only items are displayed. All groups are considered as expanded.
The visual aspect is the same as the first version of the gallery widget.
NOTE: THIS WIDGET AND ITS API ARE STILL UNDER DEVELOPMENT.
Modifier and Type | Field and Description |
---|---|
protected static int |
OFFSET |
autoMargin, DEFAULT_SIZE, EMPTY_STRING, H_COUNT, itemHeight, itemWidth, margin, minMargin, V_COUNT
expanded, gallery
Constructor and Description |
---|
NoGroupRenderer() |
Modifier and Type | Method and Description |
---|---|
void |
draw(org.eclipse.swt.graphics.GC gc,
GalleryItem group,
int x,
int y,
int clipX,
int clipY,
int clipWidth,
int clipHeight)
Group size informations can be retrieved from group.
|
GalleryItem |
getItem(GalleryItem group,
org.eclipse.swt.graphics.Point coords)
Returns the item at coords relative to the parent group.
|
org.eclipse.swt.graphics.Rectangle |
getSize(GalleryItem item)
Returns the size of a group.
|
void |
layout(org.eclipse.swt.graphics.GC gc,
GalleryItem group)
This method is called on each root item when the Gallery changes (resize,
item addition or removal) in order to update the gallery size.
|
boolean |
mouseDown(GalleryItem group,
org.eclipse.swt.widgets.Event e,
org.eclipse.swt.graphics.Point coords)
This method can be implemented to handle mouse down events at the group
level.
|
calculateMargins, dispose, drawItem, getItem, getItemHeight, getItemWidth, getLayoutData, getMinMargin, getNextItem, getSize, getSize, getVisibleItems, gridLayout, isAlwaysExpanded, isAutoMargin, isGroupExpanded, mouseDown, preLayout, setAlwaysExpanded, setAutoMargin, setItemHeight, setItemSize, setItemWidth, setMinMargin
getBackground, getFont, getForeground, getGallery, getGroupPosition, getGroupSize, getScrollBarIncrement, isDebugMode, isExpanded, notifyTreeListeners, postDraw, postLayout, preDraw, setExpanded, setGallery, setGroupSize, updateScrollBarsProperties, updateStructuralValues
public void draw(org.eclipse.swt.graphics.GC gc, GalleryItem group, int x, int y, int clipX, int clipY, int clipWidth, int clipHeight)
AbstractGalleryGroupRenderer
draw
in class AbstractGridGroupRenderer
org.eclipse.nebula.widgets.gallery.AbstractGridGroupRenderer#draw(org
.eclipse.swt.graphics.GC,
org.eclipse.nebula.widgets.gallery.GalleryItem, int, int, int, int,
int, int)
public void layout(org.eclipse.swt.graphics.GC gc, GalleryItem group)
AbstractGalleryGroupRenderer
layout
in class AbstractGridGroupRenderer
org.eclipse.nebula.widgets.gallery.AbstractGridGroupRenderer#layout(org
.eclipse.swt.graphics.GC,
org.eclipse.nebula.widgets.gallery.GalleryItem)
public GalleryItem getItem(GalleryItem group, org.eclipse.swt.graphics.Point coords)
AbstractGalleryGroupRenderer
getItem
in class AbstractGridGroupRenderer
AbstractGridGroupRenderer.getItem(
org.eclipse.nebula.widgets.gallery.GalleryItem,
org.eclipse.swt.graphics.Point)
public boolean mouseDown(GalleryItem group, org.eclipse.swt.widgets.Event e, org.eclipse.swt.graphics.Point coords)
AbstractGalleryGroupRenderer
mouseDown
in class AbstractGalleryGroupRenderer
group
- The group on which the mouse click occurede
- The original mouse eventcoords
- The pointer coordinates relative to the groupAbstractGalleryGroupRenderer.mouseDown(org.eclipse.nebula.widgets.gallery.GalleryItem,
org.eclipse.swt.widgets.Event, org.eclipse.swt.graphics.Point)
public org.eclipse.swt.graphics.Rectangle getSize(GalleryItem item)
AbstractGalleryGroupRenderer
getSize
in class AbstractGridGroupRenderer
AbstractGridGroupRenderer.getSize(
org.eclipse.nebula.widgets.gallery.GalleryItem)