public static interface CanvasLayer.Polygon extends CanvasLayer.Geometry
Polygon on the canvas.| Modifier and Type | Interface and Description | 
|---|---|
static class  | 
CanvasLayer.Polygon.ClickEvent
An event that is fired after click on the polygon. 
 | 
static class  | 
CanvasLayer.Polygon.ModifiedEvent
An event that is fired after modifying the polygon via UI. 
 | 
static class  | 
CanvasLayer.Polygon.RightClickEvent
An event that is fired after right click on the polygon. 
 | 
| Modifier and Type | Method and Description | 
|---|---|
io.jmix.core.common.event.Subscription | 
addClickListener(java.util.function.Consumer<CanvasLayer.Polygon.ClickEvent> listener)
Registers a new polygon click listener. 
 | 
io.jmix.core.common.event.Subscription | 
addModifiedListener(java.util.function.Consumer<CanvasLayer.Polygon.ModifiedEvent> listener)
Registers a new polygon modified listener. 
 | 
io.jmix.core.common.event.Subscription | 
addRightClickListener(java.util.function.Consumer<CanvasLayer.Polygon.RightClickEvent> listener)
Registers a new polygon right click listener. 
 | 
org.locationtech.jts.geom.Polygon | 
getGeometry()
Returns a JTS polygon. 
 | 
CanvasLayer.Polygon | 
setEditable(boolean editable)
Sets whether the geometry is to be modifiable on a canvas. 
 | 
CanvasLayer.Polygon | 
setPopupContent(java.lang.String popupContent)
Adds a popup window to be opened as user clicks on the polygon. 
 | 
CanvasLayer.Polygon | 
setPopupOptions(PopupWindowOptions options)
Specifies options for a popup window added by  
setPopupContent(String). | 
CanvasLayer.Polygon | 
setStyle(PolygonStyle style)
Applies a style to the polygon. 
 | 
CanvasLayer.Polygon | 
setTooltipContent(java.lang.String tooltipContent)
Adds a tooltip to be opened as user hovers on the polygon. 
 | 
CanvasLayer.Polygon | 
setTooltipOptions(TooltipOptions options)
Specifies options for a tooltip added by  
setTooltipContent(String). | 
closePopup, closeTooltip, isEditable, openPopup, openTooltiporg.locationtech.jts.geom.Polygon getGeometry()
getGeometry in interface CanvasLayer.GeometryCanvasLayer.Polygon setStyle(PolygonStyle style)
style - polygon styleCanvasLayer.Polygon setPopupContent(java.lang.String popupContent)
popupContent - content of the popup windowCanvasLayer.Polygon setPopupOptions(PopupWindowOptions options)
setPopupContent(String).options - popup window optionsCanvasLayer.Polygon setTooltipContent(java.lang.String tooltipContent)
tooltipContent - content of the tooltip boxCanvasLayer.Polygon setTooltipOptions(TooltipOptions options)
setTooltipContent(String).options - tooltip optionsCanvasLayer.Polygon setEditable(boolean editable)
CanvasLayer.GeometrysetEditable in interface CanvasLayer.Geometryio.jmix.core.common.event.Subscription addClickListener(java.util.function.Consumer<CanvasLayer.Polygon.ClickEvent> listener)
listener - the listener to be addedio.jmix.core.common.event.Subscription addRightClickListener(java.util.function.Consumer<CanvasLayer.Polygon.RightClickEvent> listener)
listener - the listener to be addedio.jmix.core.common.event.Subscription addModifiedListener(java.util.function.Consumer<CanvasLayer.Polygon.ModifiedEvent> listener)
listener - the listener to be added