-
- All Implemented Interfaces:
-
org.osmdroid.views.overlay.Overlay.Snappable,org.osmdroid.views.util.constants.OverlayConstants
@Deprecated() public class ItemizedOverlayWithFocus<Item extends OverlayItem> extends ItemizedIconOverlay<Item>
-
-
Constructor Summary
Constructors Constructor Description ItemizedOverlayWithFocus(Context pContext, List<Item> aList, ItemizedIconOverlay.OnItemGestureListener<Item> aOnItemTapListener)ItemizedOverlayWithFocus(List<Item> aList, ItemizedIconOverlay.OnItemGestureListener<Item> aOnItemTapListener, Context pContext)ItemizedOverlayWithFocus(List<Item> aList, Drawable pMarker, Drawable pMarkerFocused, int pFocusedBackgroundColor, ItemizedIconOverlay.OnItemGestureListener<Item> aOnItemTapListener, Context pContext)
-
Method Summary
Modifier and Type Method Description voidsetDescriptionBoxPadding(int value)default is 3 pixels voidsetDescriptionBoxCornerWidth(int value)default 3 voidsetDescriptionTitleExtraLineHeight(int value)default is 2 voidsetMarkerBackgroundColor(int value)default is a green like color voidsetMarkerTitleForegroundColor(int value)voidsetMarkerDescriptionForegroundColor(int value)voidsetFontSize(int value)default is 14 voidsetDescriptionMaxWidth(int value)in pixels, default is 600 voidsetDescriptionLineHeight(int value)default is 30 ItemgetFocusedItem()voidsetFocusedItem(int pIndex)voidunSetFocusedItem()voidsetFocusedItem(Item pItem)voidsetFocusItemsOnTap(boolean doit)voiddraw(Canvas c, Projection pProjection)Draw a marker on each of our items. voidonDetach(MapView mapView)Override to perform clean up of resources before shutdown. -
Methods inherited from class org.osmdroid.views.overlay.ItemizedIconOverlay
addItem, addItem, addItems, onLongPress, onSingleTapConfirmed, onSnapToItem, removeAllItems, removeAllItems, removeItem, removeItem, size -
Methods inherited from class org.osmdroid.views.overlay.ItemizedOverlay
draw, getDisplayedItems, getDrawnItemsLimit, getFocus, getItem, onSingleTapConfirmed, setDrawFocusedItem, setDrawnItemsLimit, setFocus, setOnFocusChangeListener -
Methods inherited from class org.osmdroid.views.overlay.Overlay
draw, draw, getBounds, isEnabled, onDetach, onDoubleTap, onDoubleTapEvent, onDown, onFling, onKeyDown, onKeyUp, onLongPress, onPause, onResume, onScroll, onShowPress, onSingleTapConfirmed, onSingleTapUp, onTouchEvent, onTrackballEvent, setEnabled -
Methods inherited from class org.osmdroid.views.overlay.Overlay.Snappable
onSnapToItem -
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
-
Constructor Detail
-
ItemizedOverlayWithFocus
ItemizedOverlayWithFocus(Context pContext, List<Item> aList, ItemizedIconOverlay.OnItemGestureListener<Item> aOnItemTapListener)
-
ItemizedOverlayWithFocus
ItemizedOverlayWithFocus(List<Item> aList, ItemizedIconOverlay.OnItemGestureListener<Item> aOnItemTapListener, Context pContext)
-
-
Method Detail
-
setDescriptionBoxPadding
void setDescriptionBoxPadding(int value)
default is 3 pixels
-
setDescriptionBoxCornerWidth
void setDescriptionBoxCornerWidth(int value)
default 3
-
setDescriptionTitleExtraLineHeight
void setDescriptionTitleExtraLineHeight(int value)
default is 2
-
setMarkerBackgroundColor
void setMarkerBackgroundColor(int value)
default is a green like color
-
setMarkerTitleForegroundColor
void setMarkerTitleForegroundColor(int value)
-
setMarkerDescriptionForegroundColor
void setMarkerDescriptionForegroundColor(int value)
-
setFontSize
void setFontSize(int value)
default is 14
-
setDescriptionMaxWidth
void setDescriptionMaxWidth(int value)
in pixels, default is 600
-
setDescriptionLineHeight
void setDescriptionLineHeight(int value)
default is 30
-
getFocusedItem
Item getFocusedItem()
-
setFocusedItem
void setFocusedItem(int pIndex)
-
unSetFocusedItem
void unSetFocusedItem()
-
setFocusedItem
void setFocusedItem(Item pItem)
-
setFocusItemsOnTap
void setFocusItemsOnTap(boolean doit)
-
draw
void draw(Canvas c, Projection pProjection)
Draw a marker on each of our items. populate() must have been called first.The marker will be drawn twice for each Item in the Overlay--once in the shadow phase, skewedand darkened, then again in the non-shadow phase. The bottom-center of the marker will bealigned with the geographical coordinates of the Item.The order of drawing may be changed by overriding the getIndexToDraw(int) method. An item mayprovide an alternate marker via its OverlayItem.getMarker(int) method. If that method returnsnull, the default marker is used.The focused item is always drawn last, which puts it visually on top of the other items.
-
-
-
-