Home Reference Source

Typedef

Static Public Summary
public
public
public
public
public
public
public
public
public

Inside of this object the controls are configured.

public
public
public
public
public
public
public

This describes the floating directions of an element.

public
public
public
public
public
public
public
public
public
public
public
public
public
public
public
public
public
public
public
public
public
public
public
public
public
public
public
public
public
public
public
public
public
public

SingleMoveOptions: olx.view.FitOptions

public

SourceServerVectorOptions: olx.source.VectorOptions

public

StyleLike: string | StyleObject | ol.style.Style

public
public
public
public
public
public

WMSSSourceConfig: SourceConfig

A wms source config.

public
public
public
public
public

Static Public

public APIMapInteraction: object source

Properties:

NameTypeAttributeDescription
cancel function

ends the interaction. The result promise will not resolve.

end function

ends the interaction properly. The result promise will resolve if possible.

result Promise

a promise that represents the value of the interaction.

public APIOptions: object source

Properties:

NameTypeAttributeDescription
drawStyle StyleLike
  • optional
  • default: '#drawStyle'

public ArrowButtonOptions: g4uControlOptions source

Properties:

NameTypeAttributeDescription
pixelDelta number
  • optional
  • default: 128

how many pixels should one click move the map

initExtent ol.Extent | undefined
  • optional
  • default: undefined

the initial Extent to move the map back to (center button)

animationDuration number
  • optional
  • default: 100

duration of the animation

animated boolean
  • optional
  • default: true

if the move should be done with an animation or without

labels {up: string, right: string, down: string, left: string, center: string}|{}
  • optional
  • default: {}

unicode labels for the buttons (only shown if pictures are not loaded)

public BaseLayerMixinOptions: object source

Properties:

NameTypeAttributeDescription
groupLayer GroupLayer

the group this baseLayer belongs to

public ButtonBoxOptions: object source

Properties:

NameTypeAttributeDescription
className string
  • optional
  • default: 'g4u-menu'
addClass string
  • optional

adds a classname

content HTMLElement | jQuery
  • optional

the content of the body of the button box

collapsible boolean
  • optional
collapsed boolean
  • optional
rtl boolean
  • optional
titleButton boolean
  • optional
  • default: false

displays an extra button with a title firing an 'title:click' event

title string
  • optional

the title appearing on the button

public CombinedZoomOptions: ComposedControlOptions source

Properties:

NameTypeAttributeDescription
buttons boolean
  • optional
  • default: true

visibility of the zoombuttons

slider boolean
  • optional
  • default: true

visibility of the zoomslider

buttonImportance number
  • optional

importance of the buttons

sliderImportance number
  • optional

importance of the slider

zoomInTipLabel string
  • optional
zoomOutTipLabel string
  • optional

public ComposedControlOptions: g4uControlOptions source

Properties:

NameTypeAttributeDescription
containerClassName string
  • optional

public ControlFactoryOptions: Object source

Properties:

NameTypeAttributeDescription
localiser L10N
map G4UMap

public ControlsConfig: object source

Inside of this object the controls are configured. Normally they are referenced by their type, but if you have multiple controls of one type you can specify a name under which it is referenced. Then you have to specify the controlType in the configuration object.

Example: let 'example' be the chosen name for an attribution control. Then we can reference it in onMap or any contains property as 'example'. The configuration object is now named 'example' but needs to have an 'controlType' property which needs to be set to 'attribution'.

   "controls": {
     "onMap": ["example"],
     "example": {
       "controlType": "attribution",
       ...
     }
   }

Properties:

NameTypeAttributeDescription
onMap string[]

All controls mentioned in this array will be added directly to the map.

arrowButtons ArrowButtonOptions
  • optional
attribution AttributionOptions
  • optional
combinedZoom CombinedZoomOptions
  • optional
geolocationButton GeoLocationButtonOptions
  • optional
helpButton HelpButtonOptions
  • optional
infoButton InfoButtonOptions
  • optional
languageSwitcherButton LanguageSwitcherButtonOptions
  • optional
languageSwitcherMenu LanguageSwitcherMenuOptions
  • optional
layerSelector LayerSelectorOptions
  • optional
linkButton LinkButtonOptions
  • optional
logo LogoOptions
  • optional
measurementButton MeasurementButtonOptions
  • optional
mobileControls ShiftableComposedControlOptions
  • optional
mousePosition MousePositionOptions
  • optional
overviewMap OverviewMapOptions
  • optional
printButton g4uControlOptions
  • optional
scaleLine ScaleLineOptions
  • optional
singleDrawButton DrawButtonsOptions
  • optional
toolbox ComposedControlOptions
  • optional
layerMenu ComposedControlOptions
  • optional

public DrawButtonsOptions: g4uControlOptions source

Properties:

NameTypeAttributeDescription
editStyle StyleLike
  • optional
  • default: '#defaultStyle'
finishedStyle StyleLike
  • optional
  • default: '#defaultStyle'

public DropdownOptions: object source

Properties:

NameTypeAttributeDescription
className string
  • optional
  • default: 'g4u-dropdown'
ghostentry string
  • optional
  • default: 'no entries'

This text is shown if the dropdown has no entries

slideDuration number
  • optional
  • default: 400

standard slideDuration

public ElementPosition: object source

Properties:

NameTypeAttributeDescription
$actualElement jQuery
$oldParent jQuery
oldIndex number

public Entry: Object source

Properties:

NameTypeAttributeDescription
$element jQuery
value *

public FeaturePopupOptions: object source

Properties:

NameTypeAttributeDescription
className string
  • optional
  • default: 'g4u-featurepopup'
offset number[]
  • optional
  • default: [0,0]
positioning ol.OverlayPositioning
  • optional
  • default: 'center-center'
iconSizedOffset number[]
  • optional
  • default: [0,0]
centerOnPopup boolean
  • optional
  • default: false
animated boolean
  • optional
  • default: true
popupModifier string[]
  • optional

default popupModifiers to use

public FeatureTooltipOptions: object source

Properties:

NameTypeAttributeDescription
className string
  • optional
  • default: 'g4u-featuretooltip'
offset number[]
  • optional
  • default: [0,0]
positioning ol.OverlayPositioning
  • optional
  • default: 'center-center'
popupModifier string[]
  • optional
  • default: []

public Float: string[] | string source

This describes the floating directions of an element. It can be an array, then it will move from the center to the first specified direction and after that it moves in the second direction. If it is set to 'fixed' it is not positioned via Positioning.

public G4UMapOptions: object source

Properties:

NameTypeAttributeDescription
localiser L10N
  • optional
popupModifiers object<string, PopupModifier>
  • optional

public GeoLocationButtonOptions: g4uControlOptions source

Properties:

NameTypeAttributeDescription
animated boolean
  • optional

if the move on the map to the geoposition should be animated

style StyleLike
  • optional
  • default: '#defaultStyle'
maxZoom number
  • optional
active boolean
  • optional
  • default: false

public HelpButtonOptions: g4uControlOptions source

Properties:

NameTypeAttributeDescription
configControls object
  • optional
  • default: {}
fileName string

of the json with the helptexts

active boolean
  • optional
  • default: false

public HideableElement: Object source

Properties:

NameTypeAttributeDescription
control Control
importance number
order number
float Float
  • optional

first and second direction or special value 'fixed'

hideableChildren HideableElement[]
  • optional

public InfoButtonOptions: g4uControlOptions source

Properties:

NameTypeAttributeDescription
contentURL URLLike

url providing content to be shown

attribution boolean
  • optional
  • default: true
active boolean
  • optional
  • default: false

public KineticOptions: object source

Properties:

NameTypeAttributeDescription
decay number
  • optional
minVelocity number
  • optional
delay number
  • optional

public L10NOptions: object source

Properties:

NameTypeAttributeDescription
defaultLanguage string
  • optional
  • default: 'en'
currentLanguage string
  • optional
languageFile string
  • optional
  • default: 'files/l10n.commented.json'
availableLanguages string[]
  • optional

public LanguageSwitcherButtonOptions: g4uControlOptions source

public LanguageSwitcherMenuOptions: g4uControlOptions source

Properties:

NameTypeAttributeDescription
showLongLanguage boolean
  • optional
  • default: false
active boolean
  • optional
  • default: false

public LayerButton: object source

Properties:

NameTypeAttributeDescription
title string
checked boolean
  • optional

if QUERY_LAYERS are set and checked is true, the featureInfo appears turned on.

LAYERS string[]
QUERY_LAYERS string[]
  • optional

public LayerConfig: Object source

Properties:

NameTypeAttributeDescription
baseLayers AnyLayerConfig[]
featureLayers AnyLayerConfig[]
fixedFeatureLayers AnyLayerConfig[]
queryLayers AnyLayerConfig[]

public LayerSelectorOptions: g4uControlOptions source

Properties:

NameTypeAttributeDescription
collapsible boolean
  • optional
  • default: true

if the menu should be collapsible

collapsed boolean
  • optional
  • default: false

if the menu starts collapsed

minVisibleEntries number
  • optional
  • default: 6

amount of minimal visible elements

layerGroupName string

the name of the layerGroup this selector is connected to. For example 'baseLayers'

minLayerAmount number
  • optional
  • default: 1

the minimum number of layers which should be visible to show this selector

public LinkButtonOptions: g4uControlOptions source

Properties:

NameTypeAttributeDescription
url string
  • optional
linkTarget string
  • optional

set the link target (e.g. '_blank')

public Localizable: Object<string, string> | string source

public LogoOptions: g4uControlOptions source

Properties:

NameTypeAttributeDescription
src string
  • optional
  • default: 'images/g4u-logo.png'

path to the image

width number
  • optional
height number
  • optional
opacity number
  • optional
mode string
  • optional
  • default: 'both'

possible values: print, screen, both

public MapConfig: Object source

Properties:

NameTypeAttributeDescription
proxy string
  • optional

A proxy url. It should have an {url} string which will be replaced with the proxied url. Example: 'proxy.php?csurl={url}'.

userActionTracking Boolean
  • optional
  • default: false

if checked the map tracks certain user actions and fires 'userActionTracking' events that contain this information. Tracked actions are: move, layer activation, clicks on features, printing, measurements.

languageSettings L10NOptions
  • optional

settings regarding the display language.

interfaceProjection string
  • optional
  • default: 'EPSG:4326'

the projection the interface will use to interact with the user or the api.

mapProjection string
  • optional

the projection that is used internally. Will be infered from map data if not set.

measurementProjection string
  • optional

the projection measurements will calculated in.

enableContextMenu boolean
  • optional
  • default: false

enables the contextMenu outside of textinput fields

view g4uViewOptions

View options.

scaleIcons number
  • optional

a default scaling for all used feature icons

hitTolerance number
  • optional
  • default: 0

a default hit tolerance that will be used for all interactions (except show wms feature info).

manageStyles boolean
  • optional
  • default: true

set this to false to disable style managing. This disables scaleIcons, mobileScaleIcons, feature hiding and adjustable style opacity

mobileLayout MobileLayoutOptions
  • optional

special layout options for mobile use.

additionalProjections ProjectionConfig[]
  • optional

if any other projections than 'EPSG:4326' or 'EPSG:3857' are needed they can be specified here.

api APIOptions
  • optional

API-Options

featurePopup FeaturePopupOptions
  • optional

Options regarding the feature popup.

featureTooltip FeatureTooltipOptions
  • optional

Options regarding the feature tooltip.

showWMSFeatureInfo ShowWMSFeatureInfoOptions
  • optional

Options regarding WMS GetFeatureInfo.

interactions Object<string, boolean>
  • optional

Specifies which map interactions should be turned on by default. Possible interactions are: 'doubleClickZoom', 'dragPan' (to which the {KineticOptions} are applied), 'dragRotate', 'dragZoom', 'keyboardPan', 'keyboardZoom', 'mouseWheelZoom', 'pinchRotate', 'pinchZoom'

kinetic KineticOptions | boolean
  • optional

This influences the DragPan behaviour. If set to false no kinetic options are applied, if not set, the defaults are used.

move MoveOptions
  • optional

Options regarding the behaviour of movements on the maps.

positioning PositioningOptions
  • optional

Options regarding the positioning of the controls.

loadingStrategy string
  • optional
  • default: 'ALL'

Global default loading strategy. Can have the values 'BBOX' or 'ALL'.

ignoreLayerAvailability boolean
  • optional
  • default: false

If set all layers are added to the map, regardless of their available config option.

cssFile string
  • optional

a cssFile to load and insert in the head dynamically.

cssTemplate Color[]
  • optional

if 3 colors are given, the colors used in the text of the loaded cssFile will be replaced by this colors. The colors in the cssFile need to be pure red, blue and green.

styleMap Object<string, StyleObject>
  • optional

the style objects which will be mapped to certain identifiers. It is recommended that identifiers start with a #. The {{StyleObject}} with the identifier '#defaultStyle' will be used as a default Style in the whole Software.

controls ControlsConfig

public MeasurementButtonOptions: g4uControlOptions source

Properties:

NameTypeAttributeDescription
style StyleLike
  • optional
  • default: '#defaultStyle'
type string

geometry type ('LineString', 'Polygon')

dimension number
  • optional
  • default: 1

1 for lines, 2 for polygons

atDrawEnd string
  • optional

if set to 'newMeasurement' the control will start a new measurement after completing a measurement. if set to 'closeWindow' the window will be closed.

active boolean
  • optional
  • default: false

public MessageConstructorOptions: MessageDisplayOptions source

Properties:

NameTypeAttributeDescription
arrowShow boolean
  • optional
  • default: true

whether to show an arrow pointing at the element

arrowSize number
  • optional
  • default: 5

Arrow size in pixels

autoHide boolean
  • optional
  • default: true

whether to auto-hide the notification

autoHideDelay number
  • optional
  • default: 15000

milliseconds before hide (if autoHide is set)

className string | string[]
  • optional
  • default: 'error'

default class

position string
  • optional
  • default: bottom left

notification position relative to element

gap number
  • optional
  • default: 2

padding between element and notification

hideAnimation string
  • optional
  • default: slideUp

hide animation type

hideDuration number
  • optional
  • default: 200

hide animation duration in milliseconds

showAnimation string
  • optional
  • default: slideDown

show animation type

showDuration number
  • optional
  • default: 400

show animation duration in miliseconds

style string
  • optional
  • default: bootstrap

default style

public MessageDisplayOptions: MessageReducedDisplayOptions source

Properties:

NameTypeAttributeDescription
className string | string[]
  • optional

default class

public MessageReducedDisplayOptions: object source

Properties:

NameTypeAttributeDescription
autoHide boolean
  • optional

whether to auto-hide the notification

autoHideDelay number
  • optional

milliseconds before hide (if autoHide is set)

position string
  • optional

notification position relative to element

public MobileLayoutOptions: object source

Properties:

NameTypeAttributeDescription
mediaQueries string[]

these will enable the mobile layout including removing the g4u-desktop class from the ol-viewport and adding the g4u-mobile class

scaleIcons number
  • optional
  • default: 1

a value to scale all icons by

animations boolean
  • optional
  • default: true

if animations should be disabled

hitTolerance number
  • optional

public MousePositionOptions: g4uControlOptions source

Properties:

NameTypeAttributeDescription
coordinateFormat function
  • optional

public MoveOptions: object source

Properties:

NameTypeAttributeDescription
map G4UMap
pixelPadding number
  • optional
  • default: 50

a default padding around the target extent in pixels

meterMinSize number
  • optional
  • default: 500

the minimal size of the target extent in meters

animationDuration number
  • optional
  • default: 2000
animations boolean
  • optional
  • default: true
bouncing boolean
  • optional
  • default: false

if the animation should bounce or not

public OnTopOptions: object source

Properties:

NameTypeAttributeDescription
findParentWindow boolean
  • optional
  • default: false

public OverviewMapOptions: g4uControlOptions source

Properties:

NameTypeAttributeDescription
tipLabel Localizable
  • optional
layerGroup ol.layer.Group
  • optional

public PopupContent: object source

Properties:

NameTypeAttributeDescription
name string
description string

public PositionedElement: HideableElement source

Properties:

NameTypeAttributeDescription
float string[]

first and second direction or special value 'fixed'

minWidth number
minHeight number
size {width: number, height: number}

public PositioningOptions: object source

Properties:

NameTypeAttributeDescription
padding number
  • optional
  • default: 5
spacing number
  • optional
  • default: 10
viewport HTMLElement

public ProjectionConfig: Object source

Properties:

NameTypeAttributeDescription
code string
definition string

public QuerySourceOptions: SourceServerVectorOptions source

Properties:

NameTypeAttributeDescription
queryValues String[]
  • optional
  • default: []

public ShieldOptions: object source

Properties:

NameTypeAttributeDescription
map G4UMap
className string
  • optional
  • default: 'g4u-shield'

public ShiftableComposedControlOptions: ComposedControlOptions source

Properties:

NameTypeAttributeDescription
visibleControls number

specifies amount visible controls

public ShowWMSFeatureInfoOptions: Object source

Properties:

NameTypeAttributeDescription
style StyleLike
  • optional
  • default: '#defaultStyle'
seperator String
  • optional
  • default: '
    '
popupModifiers String[]
  • optional
  • default: []
animated boolean
  • optional

public SingleMoveOptions: olx.view.FitOptions source

Properties:

NameTypeAttributeDescription
animated boolean
  • optional

if specified overwrites the default settings

padding number[] | string
  • optional

can be set to 'default' to use the default settings

public SourceServerVectorOptions: olx.source.VectorOptions source

Properties:

NameTypeAttributeDescription
type string

the format to use

url URLLike
defaultStyle StyleLike
  • optional

a default style to fallback to

extractStyles boolean
  • optional
  • default: true

if styles should get extracted from the KML

loadingStrategy string
  • optional
  • default: 'ALL'

Either 'BBOX' or 'ALL' (Synonym: 'FIXED'). If BBOX the given url has to contain the parameters {bboxleft}, {bboxbottom}, {bboxright}, {bboxtop}.

bboxRatio number
  • optional
  • default: 1

If set the bbox loading strategy will increase the load extent by this factor

bboxProjection ol.ProjectionLike
  • optional

coordinates will be inserted into the url in this format. defaults to the interfaceProjection

cache boolean
  • optional
  • default:

true, false for dataType 'script' and 'jsonp'

refresh number
  • optional

if set the layer will refresh itself in the specified time (in ms)

localiser L10N
localised boolean
styling Styling

public StyleLike: string | StyleObject | ol.style.Style source

public StyleObject: Object source

public URLConfig: object source

Properties:

NameTypeAttributeDescription
url Localizable
useProxy boolean
  • optional
proxy string
  • optional
cache boolean
  • optional
  • default: true
username string
  • optional

only implemented for wms at the moment

password string
  • optional

only implemented for wms at the moment

public URLLike: URLConfig | Localizable | URL source

public VectorLayerOptions: object source

Properties:

NameTypeAttributeDescription
mutators string[]
  • optional
  • default: []

list of mutators (changes featurepopup content) to use for this layer.

public WMSFeatureInfoOptions: object source

Properties:

NameTypeAttributeDescription
params object<string, string>
  • optional

the params to be used with the GetFeatureInfo call. Needs to include INFO_FORMAT. If the layer does not use the buttons options than needs to include QUERY_LAYERS.

checkable boolean
  • optional
  • default: false

If the layer does not use the buttons options, this options specifies if an extra button on the layer button appears to toggle the feature info.

checked boolean
  • optional
  • default: true

If the layer does not use the buttons options and checkable is true, this option specifies if the feature info button appears activated or not.

public WMSSSourceConfig: SourceConfig source

A wms source config.

Properties:

NameTypeAttributeDescription
params object

required. needs to contain a LAYERS parameter. For other parameters see: http://openlayers.org/en/latest/apidoc/ol.source.ImageWMS.html -> Constructor options -> params

featureInfo WMSFeatureInfoOptions

public WindowDecoratorOptions: g4uControlOptions source

Properties:

NameTypeAttributeDescription
component Control

public WindowOptions: object source

Properties:

NameTypeAttributeDescription
draggable boolean
  • optional
  • default: false
id string
  • optional

an html id for the outer window element

className string
  • optional

an alternative html class name to use instead of 'g4u-window', not recommended

map G4UMap
  • optional

the map the window should be shown on. The viewport will be set as the context of the window

$context jQuery
  • optional

context the window is shown in

visible boolean
  • optional
  • default: false

the visibility of the window on start up

fixedPosition boolean
  • optional
  • default: false

if the window is movable or not

public ZoomOptions: g4uControlOptions source

Properties:

NameTypeAttributeDescription
zoomInTipLabel Localizable
  • optional
zoomOutTipLabel Localizable
  • optional

public g4uControlOptions: object source

Properties:

NameTypeAttributeDescription
controlType string
  • optional

the type of the control. If not given the name of the control is used

importance number
  • optional

how important the control is on the map. the higher this value is, the longer it will be kept on the map if the viewport gets smaller.

activeGroup string
  • optional

if controls are in the same active group only one of them can be active at the same time

className string
  • optional
element HTMLElement
localiser L10N

the localiser to use by the control.

controlName string

the name of the control.

singleButton boolean
  • optional
  • default: false

if the control only consists of one button

target String | HTMLElement | jQuery
  • optional
title Localizable
  • optional

not used by every control

tipLabel Localizable
  • optional

not used by every control

float Float
  • optional
windowed boolean
  • optional
  • default: false

whether the control resides inside a window or not

public g4uViewOptions: Object source

Properties:

NameTypeAttributeDescription
center ol.Coordinate

the initial center of the map

extent ol.Extent
  • optional

the max extent the center can lay in

resolution number
  • optional
zoom number
  • optional
rotation number
  • optional
fit number
  • optional

an extent to fit the map initialy to, overwrites center settings

projection ol.ProjectionLike
  • optional