From kde-commits Sat Mar 31 20:47:18 2012 From: Ingo Malchow Date: Sat, 31 Mar 2012 20:47:18 +0000 To: kde-commits Subject: [websites/wiki-kde-org/develop] extensions/Maps: force to add maps config... does that become a runn Message-Id: <20120331204718.B3437A60A9 () git ! kde ! org> X-MARC-Message: https://marc.info/?l=kde-commits&m=133322692613198 Git commit 272165799a3b7bdea8d62ce54325361cdfe56939 by Ingo Malchow. Committed on 31/03/2012 at 22:47. Pushed by imalchow into branch 'develop'. force to add maps config... does that become a running gag? A +402 -0 extensions/Maps/Maps_Settings.php http://commits.kde.org/websites/wiki-kde-org/272165799a3b7bdea8d62ce5432536= 1cdfe56939 diff --git a/extensions/Maps/Maps_Settings.php b/extensions/Maps/Maps_Setti= ngs.php new file mode 100644 index 0000000..7ee81d0 --- /dev/null +++ b/extensions/Maps/Maps_Settings.php @@ -0,0 +1,402 @@ + $egMapsDefaultService, + 'display_map' =3D> $egMapsDefaultService + ); + + + = +# Geocoding + + # Array of String. Array containing all the geocoding services that will = be + # made available to the user. Currently Maps provides the following servi= ces: + # geonames, google, yahoo + # It is recommended that when using GeoNames you get a GeoNames webser= vice account + # at http://www.geonames.org/login and set the username to $egMapsGeoN= amesUser below. + # Not doing this will result into a legacy service being used, which m= ight be + # disabled at some future point. + $egMapsAvailableGeoServices =3D array( + 'geonames', + 'google', + 'yahoo' + ); + + # String. The default geocoding service, which will be used when no servi= ce is + # is provided by the user. This service needs to be enabled, if not, the = first + # one from the available services will be taken. + $egMapsDefaultGeoService =3D 'geonames'; + = + # Boolean. Indicates if geocoders can override the default geoservice bas= ed on + # the used mapping service. + $egMapsUserGeoOverrides =3D true; + = + # Boolean. Sets if coordinates should be allowed in geocoding calls. + $egMapsAllowCoordsGeocoding =3D true; + = + # Boolean. Sets if geocoded addresses should be stored in a cache. + $egMapsEnableGeoCache =3D true; + = + # String. GeoNames API user/application name. + # Obtain an account here: http://www.geonames.org/login + # Do not forget to activate your account for API usage! + $egMapsGeoNamesUser =3D ''; + + + +# Coordinate configuration + + # The coordinate notations that should be available. + $egMapsAvailableCoordNotations =3D array( + Maps_COORDS_FLOAT, + Maps_COORDS_DMS, + Maps_COORDS_DM, + Maps_COORDS_DD + ); + = + # Enum. The default output format of coordinates. + # Possible values: Maps_COORDS_FLOAT, Maps_COORDS_DMS, Maps_COORDS_DM, Ma= ps_COORDS_DD + $egMapsCoordinateNotation =3D Maps_COORDS_DMS; + = + # Boolean. Indicates if coordinates should be outputted in directional no= tation by default. + # Recommended to be true for Maps_COORDS_DMS and false for Maps_COORDS_FL= OAT. + $egMapsCoordinateDirectional =3D true; + = + # Boolean. Sets if direction labels should be translated to their equival= ent in the wiki language or not. + $egMapsInternatDirectionLabels =3D true; + + + +# Distance configuration + = + # Array. A list of units (keys) and how many meters they represent (value= ). + # No spaces! If the unit consists out of multiple words, just write them = together. + $egMapsDistanceUnits =3D array( + 'm' =3D> 1, + 'meter' =3D> 1, + 'meters' =3D> 1, + 'km' =3D> 1000, + 'kilometers' =3D> 1000, + 'kilometres' =3D> 1000, + 'mi' =3D> 1609.344, + 'mile' =3D> 1609.344, + 'miles' =3D> 1609.344, + 'nm' =3D> 1852, + 'nauticalmile' =3D> 1852, + 'nauticalmiles' =3D> 1852, + ); + = + # String. The default unit for distances. + $egMapsDistanceUnit =3D 'm'; + = + # Integer. The default amount of fractal digits in a distance. + $egMapsDistanceDecimals =3D 2; = + = + = + = +# General map configuration + + # Integer or string. The default width and height of a map. These values = will + # only be used when the user does not provide them. + $egMapsMapWidth =3D 'auto'; + $egMapsMapHeight =3D 350; + + # Array. The minimum and maximum width and height for all maps. First min= and + # max for absolute values, then min and max for percentage values. When t= he + # height or width exceed their limits, they will be changed to the closest + # allowed value. + $egMapsSizeRestrictions =3D array( + 'width' =3D> array( 50, 1020, 1, 100 ), + 'height' =3D> array( 50, 1000, 1, 100 ), + ); + = + # String. The default centre for maps. Can be either a set of coordinates= or an address. + $egMapsDefaultMapCentre =3D '0, 0'; + = + # Strings. The default content for all pop-ups. This value will only be u= sed + # when the user does not provide one. + $egMapsDefaultTitle =3D ''; + $egMapsDefaultLabel =3D ''; + = + $egMapsResizableByDefault =3D false; + = + $egMapsRezoomForKML =3D false; + + + = +# Other general configuration + = + # When true, debugging messages will be logged using mw.log(). Do not use= on production wikis. + $egMapsDebugJS =3D false; + = + # Namespace index start of the mapping namespaces. + $egMapsNamespaceIndex =3D 420; + = + # Boolean. Controls if you can specify images using a full path in layers. + $egMapsAllowExternalImages =3D true; + = + = + = +# Specific mapping service configuration + + # Google Maps v3 + = + # Integer. The default zoom of a map. This value will only be used when = the + # user does not provide one. + $egMapsGMaps3Zoom =3D 14; + = + # Array of String. The Google Maps v3 default map types. This value will= only + # be used when the user does not provide one. + $egMapsGMaps3Types =3D array( + 'roadmap', + 'satellite', + 'hybrid', + 'terrain' + ); + = + # String. The default map type. This value will only be used when the us= er + # does not provide one. + $egMapsGMaps3Type =3D 'roadmap'; + = + # Array. List of controls to display onto maps by default. + $egMapsGMaps3Controls =3D array( + 'pan', + 'zoom', + 'type', + 'scale', + 'streetview' = + ); + = + # String. The default style for the type control. + # horizontal, vertical or default + $egMapsGMaps3DefTypeStyle =3D 'default'; + + # String. The default style for the zoom control. + # small, large or default + $egMapsGMaps3DefZoomStyle =3D 'default'; + = + # Boolean. Open the info windows on load by default? + $egMapsGMaps3AutoInfoWindows =3D false; + = + # Array. Layers to load by default. + $egMapsGMaps3Layers =3D array(); + = + # Integer. Default tilt when using Google Maps. + $egMapsGMaps3DefaultTilt =3D 0; + = + # Google JavaScript Loader API key. + # Can be obtained at: https://code.google.com/apis/loader/signup.html + # This key is needed when using Google Earth. + $egGoogleJsApiKey =3D ''; + = + = + # Google Maps + = + # Your Google Maps API key. Required for displaying Google Maps, and usi= ng the + # Google Geocoder services. + $egGoogleMapsKey =3D ''; # http://code.google.com/apis/maps/signup.html + = + # If your wiki is accessable via multiple urls, you'll need multiple key= s. + # Example: $egGoogleMapsKeys['http://yourdomain.tld/something'] =3D 'you= r key'; + $egGoogleMapsKeys =3D array(); + = + # Integer. The default zoom of a map. This value will only be used when = the + # user does not provide one. + $egMapsGoogleMapsZoom =3D 14; + = + # Array of String. The Google Maps v2 default map types. This value will= only + # be used when the user does not provide one. + $egMapsGoogleMapsTypes =3D array( + 'normal', + 'satellite', + 'hybrid', + 'physical' + ); + = + # String. The default map type. This value will only be used when the us= er does + # not provide one. + $egMapsGoogleMapsType =3D 'normal'; + = + # Boolean. The default value for enabling or disabling the autozoom of a= map. + # This value will only be used when the user does not provide one. + $egMapsGoogleAutozoom =3D true; + = + # Array of String. The default controls for Google Maps v2. This value w= ill + # only be used when the user does not provide one. + # Available values: auto, large, small, large-original, small-original, = zoom, + # type, type-menu, overview-map, scale, nav-label, overlays + $egMapsGMapControls =3D array( + 'auto', + 'scale', + 'type', + 'overlays' + ); + = + # Array. The default overlays for the Google Maps v2 overlays control, a= nd + # whether they should be shown at pageload. This value will only be used= when + # the user does not provide one. + # Available values: photos, videos, wikipedia, webcams + $egMapsGMapOverlays =3D array( + 'photos', + 'videos', + 'wikipedia', + 'webcams' + ); + = + = + = + # Yahoo! Maps + = + # Your Yahoo! Maps API key. Required for displaying Yahoo! Maps. + # Haven't got an API key yet? Get it here: https://developer.yahoo.com/w= sregapp/ + $egYahooMapsKey =3D ''; + = + # Array of String. The Google Maps default map types. This value will on= ly be + # used when the user does not provide one. + $egMapsYahooMapsTypes =3D array( + 'normal', + 'satellite', + 'hybrid' + ); + = + # String. The default map type. This value will only be used when the us= er does + # not provide one. + $egMapsYahooMapsType =3D 'normal'; + = + # Integer. The default zoom of a map. This value will only be used when = the + # user does not provide one. + $egMapsYahooMapsZoom =3D 4; + = + # Boolean. The default value for enabling or disabling the autozoom of a= map. + # This value will only be used when the user does not provide one. + $egMapsYahooAutozoom =3D true; + = + # Array of String. The default controls for Yahoo! Maps. This value will= only + # be used when the user does not provide one. + # Available values: type, pan, zoom, zoom-short, auto-zoom + $egMapsYMapControls =3D array( + 'type', + 'pan', + 'auto-zoom' + ); + = + = + = + # OpenLayers + = + # Integer. The default zoom of a map. This value will only be used when = the + # user does not provide one. + $egMapsOpenLayersZoom =3D 13; + = + # Array of String. The default controls for Open Layers. This value will= only + # be used when the user does not provide one. + # Available values: layerswitcher, mouseposition, autopanzoom, panzoom, + # panzoombar, scaleline, navigation, keyboarddefaults, overviewmap, perm= alink + $egMapsOLControls =3D array( + 'layerswitcher', + 'mouseposition', + 'autopanzoom', + 'scaleline', + 'navigation' + ); + = + # Array of String. The default layers for Open Layers. This value will o= nly be + # used when the user does not provide one. + $egMapsOLLayers =3D array( + 'osm-mapnik', + 'osm-cyclemap', + 'osmarender' + ); + = + # The difinitions for the layers that should be available for the user. + $egMapsOLAvailableLayers =3D array( + //'google' =3D> array( 'OpenLayers.Layer.Google("Google Streets")' ), + = + 'bing-normal' =3D> array( 'OpenLayers.Layer.VirtualEarth( "Bing Streets= ", {type: VEMapStyle.Shaded, "sphericalMercator":true} )', 'bing' ), + 'bing-satellite' =3D> array( 'OpenLayers.Layer.VirtualEarth( "Bing Sate= llite", {type: VEMapStyle.Aerial, "sphericalMercator":true} )', 'bing' ), + 'bing-hybrid' =3D> array( 'OpenLayers.Layer.VirtualEarth( "Bing Hybrid"= , {type: VEMapStyle.Hybrid, "sphericalMercator":true} )', 'bing' ), + = + 'yahoo-normal' =3D> array( 'OpenLayers.Layer.Yahoo( "Yahoo! Streets", {= "sphericalMercator":true} )', 'yahoo' ), + 'yahoo-hybrid' =3D> array( 'OpenLayers.Layer.Yahoo( "Yahoo! Hybrid", {"= type": YAHOO_MAP_HYB, "sphericalMercator":true} )', 'yahoo' ), + 'yahoo-satellite' =3D> array( 'OpenLayers.Layer.Yahoo( "Yahoo! Satellit= e", {"type": YAHOO_MAP_SAT, "sphericalMercator":true} )', 'yahoo' ), + = + 'osmarender' =3D> array( 'OpenLayers.Layer.OSM.Osmarender("OSM arender"= )', 'osm' ), + 'osm-mapnik' =3D> array( 'OpenLayers.Layer.OSM.Mapnik("OSM Mapnik")', '= osm' ), + 'osm-cyclemap' =3D> array( 'OpenLayers.Layer.OSM.CycleMap("OSM Cycle Ma= p")', 'osm' ), + = + 'nasa' =3D> 'OpenLayers.Layer.WMS("NASA Global Mosaic", "http://t1.hype= rcube.telascience.org/cgi-bin/landsat7", + {layers: "landsat7", "sphericalMercator":true} )', + ); + = + # Layer group definitions. Group names must be different from layer name= s, and + # must only contain layers that are present in $egMapsOLAvailableLayers. + $egMapsOLLayerGroups =3D array( + 'yahoo' =3D> array( 'yahoo-normal', 'yahoo-satellite', 'yahoo-hybrid' ), + 'bing' =3D> array( 'bing-normal', 'bing-satellite', 'bing-hybrid' ), + 'osm' =3D> array( 'osmarender', 'osm-mapnik', 'osm-cyclemap' ), + ); + = + # Layer dependencies + $egMapsOLLayerDependencies =3D array( + 'yahoo' =3D> "