Git Product home page Git Product logo

nationalsecurityagency / qgis-latlontools-plugin Goto Github PK

View Code? Open in Web Editor NEW
295.0 37.0 104.0 5.75 MB

QGIS tools to capture and zoom to coordinates using decimal, DMS, WKT, GeoJSON, MGRS, UTM, UPS, GEOREF, ECEF, H3, and Plus Codes notation. Provides external map support, MGRS & Plus Codes conversion and point digitizing tools.

License: GNU General Public License v2.0

Python 88.46% Makefile 0.24% HTML 11.28% Batchfile 0.02%
qgis plugin longitude latitude mgrs wkt capture dms geojson utm pluscode wgs84 epsg geohash ups georef ecef h3

qgis-latlontools-plugin's Introduction

Lat Lon Tools Plugin

Lat Lon Tools makes it easy to capture, zoom to coordinates, convert coordinates in text fields into new point layers, export point geometry into text fields, and interact with other on-line mapping tools. It adds MGRS, Standard UTM, UPS, Geohash, GEOREF, Plus Code (Open Location Code), WKT, EWKT, JSON, and ECEF coordinate support to QGIS. When working with Google Earth, Google Maps or other on-line mapping tools, coordinates are specified in the order of 'Latitude, Longitude'. By default Lat Lon Tools uses the standard Google Map format, but is very flexible and can use virtually any projection and coordinate format for input and output. The following tools are available in Lat Lon Tools.

Lat Lon Tools Plugin

Here are the expanded Copy Extents to Clipboard menu items.

Lat Lon Tools Plugin

Some of the functions can be accessed from the Lat Lon Tools toolbar. If for some reason the toolbar is missing, select the menu item View->Toolbars and make sure Lat Lon Tools Toolbar is enabled. The conversion algorithms can be run from the QGIS Processing Toolbox.

Lat Lon Tools toolbar

A number of the conversions can be accessed as field calculator functions. When in the Field Calculator find and expand the Lat Lon Tools menu. Clicking on each entry will give a description of the funciton with sample usage.

field calculator
  • Copy/Display coordinate Copy/Display Coordinate - This captures coordinates onto the clipboard when the user clicks on the map, using the standard Google Map format or a format specified in Settings. If the user specifies a Tab separator, then the coordinate can be pasted into a spreadsheet in separate columns. While this tool is selected, the coordinate the mouse is over is shown in the lower left-hand corner either in decimal degrees, DMS, Degrees Minutes, MGRS, Standard UTM, UPS, GEOREF, Plus Codes (Open Location Code), Geohash, H3 (if the H3 library is installed), Maidenhead Grid Locator, WKT POINT, or GeoJSON notation depending on the Settings. By default it uses the geographic Latitude and Longitude to snapshot the coordinate, but this can be configured in Settings to use the project CRS or any other projection desired. See the Settings section for more details on the all the possibilities. An additional prefix or suffix can be added to the coordinate and is configured in Settings. If snapping is enabled under QGIS Project->Snapping Options... menu, then Copy/Display Coordinate will snap to any close vector vertices according to the parameters set in the snapping options.

  • Show in External Map Show in External Map - With this tool, the user can click on the QGIS map which launches an external browser and displays the location on an external map. The left and right mouse buttons can be configured to show different maps. Currently Open Street Map, Google Maps, Google Earth Web, MapQuest, Mapillary, Open Street Map iD Editor, and Bing Maps are supported along with Google Earth if it is installed on the system. The desired map that is displayed can be configured in Settings along with additional user added map services. A temporary marker can be displayed on the map at the location clicked on. To turn this on go to Settings. If snapping is enabled, then the clicked location will snap to any close vector vertices according to the parameters set in the snapping options.

  • Zoom-to Zoom to Coordinate - With this tool, type or paste a coordinate into the text area and hit Enter. QGIS centers the map on the coordinate, highlights and creates a temporary marker at the location. For formats that represent a region rather than a point such as Geohash, H3, Maindenhead, and Plus Codes (Open Location Code), the region area is displayed along with the center point. If the default WGS 84 (EPSG:4326 - latitude/longitude) coordinate system is specified, Zoom to Coordinate can interpret decimal degrees, DMS, WKT POINT, Standard UTM, UPS, MGRS, GEOREF, Plus Codes (Open Location Code), or GeoJSON coordinates. It can also zoom to Geohash coordinates, amateur radio Maidenhead grid coordinates, H3 geohash coordinates (if the H3 library is installed), or any other projection when configured in Settings or by the Select CRS Mode button. The Coordinate Order in Settings or Toggle Coordinate Order button below dictates whether the order is latitude followed by longitude (Y,X) or longitude followed by latitude (X,Y). The following actions can also be taken from the Zoom To dialog:

    • Zoom button Pressing this button causes QGIS to zoom to the location.
    • paste coordinate This pastes the contents of the clipboard into the text area.
    • Clear marker The marker is removed with this button.
    • This toggles the coordinate order without having to go into Settings.
    • This specifies the type of coordinate that is to be interpreted without having to go into Settings.
    • The behavior and coordinate types that are interpreted can be configured by pressing the Settings button.
      Zoom to Latitude, Longitude

    The following are acceptable coordinate formats when the Settings Zoom to Coordinate Type is set to WGS 84 (Latitude & Longitude). When the letters "N, S, E, W" are used, then the coordinate order is not important. These letters can be used before or after the coordinates. As long as the coordinate is understandable, punctuation, spaces, and ° ' " are optional. In these examples "d" represents degree digits, "m" minutes, and "s" seconds. Here are some example input formats:

    • Decimal Degree: 38.959390°, -95.265483° / 38.959390, -95.265483 / 38.959390N, 95.265483 W (d.dddd, d.dddd)
    • Degree, Minute: 38° 57.5634'N 95° 15.92890'W (d m.mmmm, d m.mmmm)
    • Degree, Minute: 3857.5634N 09515.92890W (ddmm.mmmm, dddmm.mmmm) - In this format the degree digits need to be 0 padded using 2 digits for latitude, and 3 digits for longitude degrees.
    • Degree, Minute, Second: 38°57'33.804"N, 95°15'55.739"W (d m s.ssss, d m s.ssss)
    • Degree, Minute, Second: 385733.804N 0951555.739W (ddmmss.ssss, dddmmss.ssss) - In this format the degree digits need to be 0 padded with 2 digits for latitude, and 3 digits for longitude.
    • Degree, Minute, Second: 004656S, 0093917E (ddmmss, dddmmss)- Notice the need for 0 padding in the decimal degree digits.
    • WKT: POINT(-95.265483 38.959390)
    • GeoJSON: {"type": "Point","coordinates": [-95.265483,38.959390]}
    • Standard WGS84 UTM: Note that the UTM standard does not include the MGRS latitude band which some use. Lat Lon Tools uses the proper UTM standard with zone and hemisphere where hemisphere is either N (north of the equator) or S (south of the equator). UTM is valid from - 80°S to 84°N.
      • 15N 303704.9 4314710.9 (ZoneHemisphere Easting Northing)
      • 303704.9,4314710.9,15N (Easting,Northing,ZoneHemisphere)
      • 303704.9mE,4314710.9mN,15N (Easting,Northing,ZoneHemisphere)
      • 303704.9mE,4314710.9mN,15,N (Easting,Northing,Zone,Hemisphere)
    • UPS (Universal Polar Stereographic): This is the equavalent to UTM except for the polar regions. It is defined north of 84° and south of -80°
      • Z 2426773mE 1530125mN
      • Z2426773E1530125N
    • GEOREF: FJKJ4407157563
    • Example MGRS coordinate when Zoom to Coordinate Type is set to MGRS: 15S UD 03704 14710
    • Example Plus Code coordinate when Zoom to Coordinate Type is set to Plus Codes: 86C6XP5M+QR
    • Example Geohash coordinate when Zoom to Coordinate Type is set to Geohash: 9yum8hmfckem
    • Example Amateur Radio Maidenhead coordinate when Zoom to Coordinate Type is set to Maidenhead Grid Locator: EM28ix (Note that the center point of the grid is the location that is returned.)
    • Example H3 geohash coordinate when Zoom to Coordinate Type is set to H3: 8826e5badbfffff
  • Multi-location Zoom Multi-location Zoom - Here the user can define a set of quick zoom-to locations. The user can also paste in or type in a coordinate in the Enter coordinate box to add it to the list. By default the format of the data entered is "latitude,longitude[,label,data1,...,data10]" where the contents in [...] are optional. Various input formats are supported and can be configured in Settings by selecting the input projection and coordinate order. These include:

    • "latitude,longitude[,label,data1,...,data10]"
    • "longitude,latitude[,label,data1,...,data10]"
    • "mgrs[,label,data1,...,data10]"
    • "Y,X[,label,data1,...,data10]"
    • "X,Y[,label,data1,...,data10]"
    • "plus codes[,label,data1,...,data10]"
    • "standard utm[,label,data1,...,data10]"

    When the user clicks on a location in the list, QGIS centers the map on the location and highlights it. Double clicking on a Label or Data cell allows the text to be edited. By default the Data fields will not be visible, but can be added from Settings. More than one location can be selected by clicking on the first point and then Shift-Click to select a range or using Ctrl-Click to add additional selected items. Markers for all selected items will be displayed. The following are additional functions.

    • Open Open Location List reads in a set of coordinates that are comma separated with an optional label. There should only be one location per line and formatted as "latitude,longitude,label,data1,...,data10" or simply "latitude,longitude".
    • Save Save Location List saves all of the zoom-to entries in a .csv file, formatted as "latitude,longitude,label,data1,...,data10".
    • Delete Delete Selected Location removes all selected locations.
    • Clear All Clear All Locations clears the list of all locations.
    • New Create Vector Layer From Location List creates a memory layer out of the zoom-to locations.
    • Settings Show Style Settings chooses a style for the layer created from the create layer button. This displays the Settings dialog box.
    • Start capture Start Capture enables the user to click on the map to capture coordinates directly to the list.
    Multi-location Zoom
    • The Show all markers displays markers of all locations.
  • Copy Extents to Clipboard - There are four tools used to copy a bounding box extent to the clipboard. The bounding box format is determined in settings dialog. The output CRS for the bounding box extent is either that of the QGIS project or EPSG:4326. The four copy extent tools are:

    • Copy canvas bounding box - Copy the canvas bounding box extent to the clipboard.
    • Copy selected area to an extent - Interactively select a region on the map to extract its bounding box extent and copy it to the clipboard.
    • Copy selected area to an extent - Copy the selected layer's extent. In some vector layers, this value may be estimated and not exact depending on how the layer was imported into QGIS.
    • Copy selected area to an extent - Copy the bounding box extent of selected features in a vector layer. If no features are selected then nothing will be copied. If the layer is not a vector layer, then the bounding box extent of the layer will be copied. In some vector layers, the bounding box extent may be estimated and not exact depending on how the layer was imported into QGIS.
  • Coordinate Conversion Coordinate Conversion Tool - This dialog provides a way to either type in a coordinate or grab a coordinate from the map and convert it to a number of different formats.

    Coordinate Conversion

    Type in a coordinate in any one of the formats listed and then press the enter button and all the other coordinates will be populated. Here are the functions of the following icons:

    • X, Y Coordinate Order / Y, X Coordinate Order Coordinate order - Select whether the coordinates should be displayed in an x,y (longitude, latitude) or y,x (latitude, longitude) order.
    • Clear all fields Clear form - This clears the form of all values.
    • Settings Show coordinate conversion settings - This shows the default settings for coordinate conversion.
    • Zoom to Zoom to will zoom to the coordinate in the Decimal Degrees field.
    • Capture coordinate Capture coordinate enables the user to click on the map to capture a coordinate directly to the form and have it automatically converted.
    • Copy to clipboard Copy to clipboard copies the value in the text area onto the clipboard.
  • Digitizing Tool Lat Lon Digitizing Tool - This tool digitizes points and add features the selcted layer using the same coordinate input formats as the Zoom, to Latitude, Longitude. A point vector layer must be selected and be edit mode for this tool to be enabled. When the user clicks on the tool, the following dialog is displayed.

    Add Feature

    Enter a coordinate in any of the Zoom to Latitude, Longitude formats and press Enter or click on the Add Feature button. If a layer contains fields then a secondary dialog box will popup to allow editing of the attributes.

    The projection of the input coordinates can be specified by the CRS drop down menu which has the following options:

    • WGS84 WGS84 Projection - This is the default specifying coordinates as latitudes and longitudes.
    • MGRS MGRS Coordinate - This specifies an MGRS coordinate.
    • Project Projection Project Projection - With this selected, it is assumed that the input coordinates are in the projection of the project.
    • Custome Projection New/Custom Projection - This allows the user to select any projection for the input coordinates.
    • Plus Codes Plus Codes Coordinate - This specifies a Plus Code coordinate.

    The next drop down menu specifies whether the coordinates are listed as Y,X (Latitude, Longitude) or X,Y (Longitude, Latitude). If the coordinate uses N, S, E, W then these take presidence and this setting is ignored.

    • Y, X Y,X (Latitude, Longitude) Order
    • X, Y X,Y (Longitude, Latitude) Order

    Right below the text input box is a status line that tells you exactly what CRS and coordinate order you are using.

  • Conversions

    All of the conversion routines can eighter be access from the Lat Lon Tool main menu or from the Processing Lat Lon Tools toolbox.

    Lat Lon Tools processing toolbox
    • Fields to point layer Fields to point layer - This converts ASCII coordinates found in one or two attribute fields into a new point geometry layer. If the coordinates are numeric and are in two fields, then the default QGIS importer can be used. This importer supports formats not available by the QGIS importer such as DMS, MGRS, Plus Codes (Open Location Code), Standard UTM, Geohash, Maidenhead grid locator, and X & Y (latitude & longitude) coordinates that are in a single field separated by a separator.

      Select the input coordinate format which may be found in one or two fields. Decimal and DMS coordinates can be in one or two fields, but MGRS, Plus Codes, Geohash, and Maidenhead grid coordinates are always in one field. When DMS or Decimal coordinates are in 1 field select which order the Y & X (latitude & longitude) coordinates are in. The order is important if the hemisphere indicators N,S,E,W are not present. The column 'Select the field containing the X or longitude coordinate' is used when the coordinates are in two fields.
    Fields to point layer
    • Point layer to field Point layer to fields - This takes a point vector layer and creates a new layer with the layer's latitude, longitude (Y, X) coordinates copied into one or two fields in the new output layer. The user has a lot of flexibility as to the output format. For Wgs84 the output can be in decimal degrees or DMS. Other formats include GeoJSON, WKT, MGRS, Standard UTM, Geohash, Plus Codes, and Maidenhead grid.
    Point layer to Field
    • MGRS to point layer MGRS to point layer - The input for this conversion is a table or vector layer containing a field with MGRS coordinates. It converts the MGRS field to a new point vector layer where each record is converted to WGS 84 (EPSG:4326) geometry.
    MGRS to point layer
    • Point layer to MGRS Point layer to MGRS - Convert a point vector layer into a new layer with an added MGRS column containing coordinates based on the vector layer's geometry. MGRS supports measuring precision's of 1m, 10m, 100m, 1km, 10km, and 100km. MGRS Precision of 5 is 1m and an MGRS Precision of 0 represents a point accuracy of 100km.
    MGRS to Geometry
    • Plus Codes to point layer Plus Codes to point layer - Convert a Plus Codes field from a table or vector layer into a new point vector layer where each record is converted to WGS 84 (EPSG:4326) geometry.
    Plus Codes to point layer
    • Plus Codes Point layer to Plus Codes - Convert a point vector layer into a new layer with an Plus Codes column, containing coordinates based on the vector layer's geometry.
    Point layer to Plus Codes
    • ECEF ECEF to Lat, Lon, Altitude - Convert an ECEF (Earth-centered, Earth-fixed coordinate system) layer into a new point layer that includes the altitude as a part of the geometry and optionally as an attribute.

    • ECEF Lat, Lon, Altitude to ECEF - Convert a point vector layer that includes an altitude Z dimension as a part of the geometery or as a part of the attribute table into an ECEF (Earth-centered, Earth-fixed coordinate system) layer.

    • WKT Geometry to WKT/JSON - Add a WKT, EWKT or JSON attribute to a vector layer and converts each feature's geometery to that format. This supports points, lines, and polygons.

    • WKT WKT attribute to layers - This creates new layers from a vector or table layer that has an attribute field containing WKT notation coordinates. WKT can specify points, lines, and polygons with either single geometries or multi-geometries. This algorithm supports all of these and can potentially output three different layers. The attribute containing the WKT geometries is chosen by Select a WKT coordinate field. Note that this only supports point, line, and polygon WKT objects and it does not support GeometryCollection objects.

  • Settings Settings - Displays the settings dialog box (see below).

  • Help Help - Displays this help page.

Settings

The CRS and coordinate order are set independently for the coordinate capture, zoom to, and multi-zoom to tools. Be careful when setting one of these settings, that you check the rest to make sure that they are set correctly for your needs.

Capture & Display Settings

Capture and Display Settings

There are 7 capture projections/formats that can be selected from the CRS/Projection of captured coordinate drop down menu. They are as follows.

  • WGS 84 (Latitude & Longitude) - This captures the coordinates as a latitude and longitude regardless of what the project CRS is set to. This is the default setting.
  • Project CRS - This captures the coordinates using the project's specified CRS.
  • Custom CRS - The captures the coordinate in any coordinate reference system regardless of what the project CRS is set to. When this is selected, then the Custom CRS dialog box is activated allowing selection of any projection.
  • MGRS - This captures the coordinates in the MGRS format,
  • Plus Codes - This captures the coordinate in Google Plus Codes format.
  • Standard UTM - This has the form of '12N 417159.0 4515540.6'
  • Geohash - This has the form of '9zpnbf0w9yuf'
  • Amateur Radio Maidenhead Grid Locator - This has the form of 'EM28ix'
  • UPS (Universal Polar Stereographic) - The string form of this format is one of the following: 'Z 2426773mE 1530125mN' or 'Z2426773E1530125N'
  • GEOREF - An example coordinate is 'FJKJ4407157563'

Additional coordinate formatting can be specified with WGS 84 (Latitude & Longitude) Number Format.

  • Decimal Degrees - "42.20391297, -86.023854202"
  • DMS - "36° 47' 24.27" N, 99° 22' 9.39" W"
  • D°MM' - "42° 12.2348' N, 86° 1.4313' W"
  • DDMMSS - "400210.53N, 1050824.96 W"
  • WKT POINT - POINT(-86.023854202 42.20391297)
  • GeoJSON - {"type": "Point","coordinates": [-86.02385420,42.20393450]}

For Other CRS number format such as Project CRS or Custom CRS the coordinate formatting options are:

  • Normal Coordinate - Decimal coordinate notation.
  • WKT POINT

The order in which the coordinates are captured is determined by Coordinate order (Not used with MGRS, UTM, UPS, WKT, GeoJSON & Plus codes) and are one of the following:

  • Lat, Lon (Y,X) - Google Map Order

  • Lon, Lat (X,Y) Order.

  • Coordinate capture delimiter (Not used with MGRS, UTM, UPS, WKT, GeoJSON & Plus codes) - Specifies the delimiter that separates the two coordinates. The options are:

    • Comma - Specifies a comma separator
    • Comma Space - This is a comma followed by a space.
    • Tab - This useful if you are pasting the coordinates into two columns of a spreadsheet.
    • Space
    • Other - With this selected, the contents of Other delimiter is used.
  • DMS second precision - Used when formatting DMS coordinates and specifies the number of digits after the decimal.

  • D°MM' precision - Used when formatting D°MM' coordinates and specifies the number of digits after the decimal for the minutes.

  • UTM precision - Used when formatting UTM coordinates and specifies the number of digits after the decimal.

  • UTM format - This specifies a UTM string format and is one of the following:

    • '15N 755631 4283168'
    • '755631,4283168,15N'
    • '755631mE,4283168mN,15N'
    • '755631mE,4283168mN,15,N'
  • UPS precision - Used when formatting UPS coordinates and specifies the number of digits after the decimal.

  • UPS format - This specifies a UPS string format and is one of the following: 'Z 2426773mE 1530125mN' or 'Z2426773E1530125N'

  • MGRS precision - This specifies the precision of MGRS coordinates ranging between 0 and 5 with precisions of 100km, 10km, 1km, 100m, 10m and 1m repectively.

  • Plus codes length - Used when formatting Plus Code coordinates. The minimum value is 10.

  • Geohash precision - Used when formatting Geohash coordinates.

  • Maidenhead grid precision - Used when formatting Amateur Radio Maidenhead grid coordinates.The value ranges from 1 to 4.

  • GEOREF precision - Used when formatting GEOREF coordinates. The maximum value is 10.

  • H3 precision - Used when formatting H3 coordinates when the H3 library is installed. Values range from 0 to 15.

  • Coordinate prefix - This text string is added to the beginning of the captured coordinate.

  • Coordinate suffix - This text string is added to the end of the captured coordinate.

  • Add space between D° M' S" and D° M.MM' numbers - When checked a space will be added between each pair of numbers.

  • Pad DMS and DM.MM output coordinates with leading zeros - When checked individual DMS coordinates will be padded with leading zero. A coordinate that normally looks like 1° 5' 15"N, 10° 19' 50"W would become 01° 05' 15"N, 010° 19' 50"W.

  • Add spaces to MGRS coordinates - This will add spaces to an MGRS coordinate when checked. Unchecked it looks like "16TDL8016526461" and checked it looks like "16T DL 80165 26461".

  • Show marker on QGIS map - When checked, a persistent marker stays on the map at the clicked location until another location is clicked on or a new tools is selected.

Zoom to Settings

Zoom to Settings

The Zoom to Latitude, Longitude tool accepts the following input coordinates as specified by Zoom to Coordinate Type:

  • WGS 84 (Latitude & Longitude) / Auto Detect Format - Input coordinates can be either in decimal degrees, DMS degrees, WKT, or GeoJSON. For decimal and DMS formats, the order of the coordinates are determined by Zoom to Coordinate Order. It also auto detects MGRS, Plus Codes, Standard UTM, UPS, GEOREF, and Geohash formats so it is generally unnecessary to specify them separately.
  • Project CRS - This accepts coordinates formatted in the CRS of the QGIS project. The numbers can be formatted in decimal or WKT notation.
  • Custom CRS - You can specify any CRS for the input coordinates and QGIS zooms to that coordinate regardless of the project CRS. The numbers can be formatted in decimal or WKT notation.
  • MGRS - This only accepts MGRS coordinates as input.
  • Plus Codes - This only accepts Plus Codes coordinates as input.
  • Standard UTM - This only accepts Standard UTM coordinates as input.
  • Geohash - This only accepts Geohash coordinates as input.
  • Maidenhead Grid - This only accepts Maidenhead Grid coordinates as input.
  • H3 - This will only be available if the H3 library is installed. It only accepts H3 coordinates as input.

The order in which the coordinates are parsed in the Zoom to Latitude, Longitude tool is specified by Zoom to Coordinate Type and has the following two options: This is not applicable for WKT, GeoJSON, MGRS, Plus Codes, and Standard UTM coordinates.

  • Lat, Lon (Y,X) - Google Map Order
  • Lon, Lat (X,Y) Order

Use Persistent Marker - If this is checked, then when you zoom to a coordinate a persistent marker is displayed until you exit, zoom to another location, or click on the Clear marker button.

Show coordinate resolution area - Some coordinate formats represent an area rather than a point depending on its resolution. These include Geohash, H3, Plus Codes, and Maindenhead. If this is checked, then when you zoom to a coordinate the area represented by the coordinate is displayed until you exit, zoom to another location, or click on the Clear marker button.

  • Marker icon size - This is the size of the marker icon when zooming to a coordinate. It is also used by the multi-zoom dialog box.
  • Marker width - This the width of the lines for the marker icon and flashing of the coordinate location.
  • Marker color - The color of the marker icon and color of the lines flashing the coordinate location.
  • Grid color - This is the color of the area displayed for Geohash, H3, Plus Codes, and Maindenhead corrdinates when the Show corrdinate resolution area is checked.

External Map Settings

External Map Settings

You can Select an External Map Provider for Left Mouse. The options are:

  • OSM - Open Street Map
  • Google Map
  • Google Aerial
  • Bing Map
  • Bing Aerial
  • MapQuest Map
  • MapQuest Aerial
  • Mapillary Street
  • Mapillary Aerial
  • iD Editor ESRI World Imagery
  • iD Editor OpenTopoMap
  • Google Earth - (This only works if it is installed on your system)
  • Panoramax
  • User Added Map Services...

Select an External Map Provider for Right Mouse has the same set of options. These correspond to the left and right mouse buttons.

Map Hints are desired attributes you would like to see in the resulting map.

  • Show placemark - When checked the external map shows a placemark at the location clicked on in the QGIS map. If this is not checked then the external map centers itself around clicked location, but will not display the placemark. Depending on the map service, this may or may not be available.
  • Map Zoom Level - This is the desired default zoom level in the external map when it is launched.

Enable the following if a temporary marker is desired to be displayed at the location click on:

  • Show marker on QGIS map

Add additional external map providers allows the user to add their own map providers by specifying a URL with latitude, longitude, and zoom level defined by the variables {lat}, {lon}, and {zoom}. For example the URL for Open Street Map would be entered as: http://www.openstreetmap.org/#map={zoom}/{lat}/{lon}. The button Add Provider adds a new service. Delete Provider deletes the selected provider. Once added the map providers will appear in the left and right mouse external map provider menus.

Multi-location Zoom Settings

Multi-location Zoom Settings

These are settings for the Multi-location zoom dialog box.

CRS/Projection of input coordinates

The user sets the CRS/projection of the coordinates in the Enter coordinate text box. By default this is set to WGS 84, latitude and longitude. This has no effect on the coordinates in the Location List that can be read in. The location list must always be WGS 84. The options are:

  • WGS 84 (Latitude & Longitude)
  • Project CRS
  • Custom CRS
  • MGRS
  • Plus Codes
  • Standard UTM

When Custom CRS is selected, the user is allowed to select a custom CRS projection.

Coordinate Order of input coordinates

The user sets the order of coordinates in the Enter coordinate text box. The order is either latitude followed by longitude (Y,X) or longitude followed by latitude (X,Y). By default the order is "Latitude, Longitude", the format used by Google Maps. This is not applicable when MGRS or Plus Codes coordinates are being used.

Create Vector Layer Style

The user can specify a style when creating a layer from the zoom locations. It can be a simple default style, default with labels, or a .qml style file that contains advanced styling.

  • Default style for multi-location zoom new layers determines the new layer style when Create Vector Layer From Location List is clicked on. The options are:
    • Default - No style is applied.
    • Label - The newly created layer will have labels next to the points.
    • Custom - The user can create a QGIS .qml file that contains style information for a point vector layer. If a .qml file has been selected, then this setting will apply the style to the new layer.

The Browse button allows selection of the .qml style file. When a .qml file is selected, Custom is automatically selected as the default style.

Data Field Settings

  • Number of extra data fields - Besides Latitude, Longitude, and Label, the user can add up to 10 additional data fields which are labeled as Data1, Data2, ... Data10. By default this is set to 0.

BBox (Bounding Box Extent) Capture Settings

BBOX Capture Settings

These are the settings for the bounding box capture to clipboard tool.

CRS/Projection of captured bounding box coordinates

Specify whether the captured bounding box will use WGS84 or the QGIS project's projections. The options are:

  • WGS 84 (Latitude & Longitude)
  • Project CRS

Format of the captured bounding box specifies the format of the bounding box captured on the clipboard. It can be one of the following formats.

  • minX,minY,maxX,maxY (W,S,E,N) - Using the selected delimiter
  • minX,maxX,minY,maxY (W,E,S,N) - Using the selected delimiter
  • minY,minX,maxY,maxX (S,W,N,E) - Using the selected delimiter
  • x1 y1,x2 y2,x3 y3,x4 y4,x1 y1 - Polygon format
  • x1,y1 x2,y2 x3,y3 x4,y4, x1,y1 - Alternate polygon format
  • WKT Polygon
  • bbox: [minX, minY, maxX, maxY] - Format used by MapProxy
  • bbox=minX,minY,maxX,maxY - Format used by GeoServer WFS, WMS

Delimiter between coordinates for non-specific formats - This affects only the first two of the above formats. It is used between coordinates with presets for Comma, Comma Space, Space, Tab, and Other.

BBOX prefix - This text string is added to the beginning of the captured bounding box string.

BBOX suffix - This text string is added to the end of the captured bounding box string.

Significant digits after decimal - This is the precision or number of digits after the decimal in the output coordinates.

Coordinate Conversion Settings

These are the default settings for the Coordinate Conversion dialog box.

Coordinate Conversion Settings
  • Default custom CRS / projection specifies the default projection when a custom CRS is selected.
  • Coordinate order for decimal and DMS notations determines whether the coordinates will be formatted in an Lat, Lon (Y, X) or Lon, Lat (X, Y) order.
  • EPSG:4326 decimal degree precision determines the number of digits after the decimal point for a WGS 84 latitude and longitude coordinate.
  • Other Decimal degree precision is the number of digits after the decimal point for all other coordinate formats.
  • DMS.ss seconds precision is the number of decimal digits for the second in a DMS formatted coordinate.
  • DM.mm' precision is the number of decimal digits for the minute in a DM.mm' formatted coordinate.
  • UTM precision specifies the number of decimal digits for a UTM formatted coordinate.
  • UTM format specifies one of these formats to be displayed: '15N 755631 4283168', '755631,4283168,15N','755631mE,4283168mN,15N', or '755631mE,4283168mN,15,N'.
  • UPS precision specifies the number of decimal digits for a UPS formatted coordinate.
  • UPS format specifies one of these formats to be displayed: 'Z 2426773mE 1530125mN', or 'Z2426773E1530125N'.
  • Plus codes length is the number of digits in a plus code coordinate.
  • Geohash precision is the number of digits in a geohash coordinate.
  • Maidenhead precision specifies the maidenhead coordinate precision.
  • GEOREF precision determins the number of digits in a GEOREF coordinate.
  • Delimiter between coordinate pairs is the delimiter used between coordinate pairs for those representations that require a delimiter.
  • DDMMSS delimiter is the delimiter used between DDMMSS coordinate pairs. Leave this blank if no space is desired between coordinates. The default is ", ".
  • Add space between DMS.ss and DM.mm' numbers - When checked a space will be added between each pair of numbers and will look like 1° 5' 15" N, 10° 19' 50" W vs. 1°5'15"N, 10°19'50"W when unchecked.
  • Pad DMS and DM.mm output coordinates with leading zeros - When checked individual DMS coordinates will be padded with leading zero. A coordinate that normally looks like 1° 5' 15"N, 10° 19' 50"W would become 01° 05' 15"N, 010° 19' 50"W.
  • Format DMS coordinates with NSEW at the beginning - This causes the N,S,E,W direction abbreviations to be placed at the beginning of a DMS coordinate such as "N400210.53, W1050824.96".
  • Add spaces to MGRS coordinates - This will add spaces to an MGRS coordinate when checked. Unchecked it looks like "16TDL8016526461" and checked it looks like "16T DL 80165 26461".

qgis-latlontools-plugin's People

Contributors

hamiltoncj avatar jeremieprudhomme avatar kaplanlior avatar liuxsdev avatar mhugent avatar nyalldawson avatar panieravide avatar red-wheelbarrow77 avatar thorasine avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

qgis-latlontools-plugin's Issues

[FEATURE REQEST] add Button for Multi-Location Zoom

Thinking out loud here: working with a user who needs to add a couple of coordinates (being some sensor positions, or cars having sensor onboard).

He can add these via the Multi-Location Zoom, but to VIEW them (let's say those 5 points) I have to popup the dialog again and click the Coordinates one by one (NOTE: you can do a multiple selection in that table, but that does not show multiple coordinates).

So some idea's:

  • make it possible to 'show all'
  • make it possible to 'show and keep showing' or something like that
  • in the multilocation zoom, instead of the full cross-hair, show mini-crosshairs (having 4 coordinates with their full horizontal and vertical lines showing will easily become a mess)

One bigger feature request (especially working with a handfull of locations): would be cool to 'freeze' locations to a set of points in a memory layer, that is: create a memory layer (epsg:4326 + OTF?) and create points. It would even be ubercool to have at least one attribute added to the points so it is possible to visualize/categorize those points based on the value in that attribute (practical example: these points can be fixed sensor masts or driving sensor cars).

Happy to split this up in several requests, or try to do this myself and do Pull Requests>

Interested?

2.14 and 2.18 throw exception in 0.9

RuntimeError: no access to protected functions or signals for objects not created from Python

Traceback (most recent call last):
File "~/.qgis2/python/plugins/latlontools/multizoom.py", line 114, in geomChanged
self.resultsTable.horizontalHeader().resizeSections()
RuntimeError: no access to protected functions or signals for objects not created from Python

Copy coordinate is WGS 84 by default

Hello,

The coordinate system of the 'Copy/Display Coordinate' Tool is always WGS 84 when first used. After opening and closing the settings without doing any changes it works fine with the project crs.

Also the settings of 'Multi-zoom', 'BBOX Capture' and the 'Converter' are not persistent again and a phyton error occurs when opening the settings.

UI: current active tab is not remembered during session?

During writing a little handout and writing about using the settings for latlon tools, it appeared to me that it does not remember the latest used tab in the settings, it always opens on 'Zoom to'.

Screenshot-20201120105638-568x275

If I just changed something in the Capture tab, and after testing want to change it back, I see that users then are editing the 'Zoom to' settings, because that is what is shown then... And though different it is for non geo-peeps all abacadabra anyway, so they do not see the difference sometimes.

I think this is a simple fix. If I have time I can probably do it myself :-)

Specify CRS error

Hi,

I've got this error, when wanted to use the Specify CRS in LatLon Digitize : Add Feature tool

An error has occurred while executing Python code:

TypeError: QgsProjectionSelectionTreeWidget.setOgcWmsCrsFilter(): argument 1 has unexpected type 'str'
Traceback (most recent call last):
File "/home/toni/.local/share/QGIS/QGIS3/profiles/default/python/plugins/latlontools/digitizer.py", line 205, in crsTriggered
selector.setOgcWmsCrsFilter(self.inputCustomCRS)
TypeError: QgsProjectionSelectionTreeWidget.setOgcWmsCrsFilter(): argument 1 has unexpected type 'str'

Python version: 3.6.5rc1 (default, Mar 14 2018, 06:54:23) [GCC 7.3.0]
QGIS version: 3.0.2-Girona Girona, a84084cf91

Please consider merging your work

Your plugin is part of a group of plugins with very similar functionalities:
http://plugins.qgis.org/plugins/latlontools/
http://plugins.qgis.org/plugins/zoomtopoint/
http://plugins.qgis.org/plugins/zoomtocoordinates/
http://plugins.qgis.org/plugins/copy_coords/

See a detailed analysis here:
https://lists.osgeo.org/pipermail/qgis-developer/2016-June/043164.html
It would be great if you could cooperate to create a new plugin, merging all your work. This will certainly result in a more robust software, less duplication of efforts, and especially less confusion for users: it is currently quite difficult for them to understand which one to use.
If successful, it would be reasonbable to insert this new plugin into QGIS core.

Add ability to input MGRS under multi location zoom

Working with QGIS, I have been trying to find an open-source plugin that is as close to Geo Rover Locus Track, and Lat Lon Tools is very similar, except that I primarily work with MGRS coordinates. Being able to add MGRS coordinates in Multi Location Zoom would significantly enhance workload efficiency.

feature request : shortcut capture gps

Rather than clicking the Copy Coordinates button.

Is it possible to assign a keyboard shortcut?

scenario:
Key pressed (keyboard shortcut)

=> enable the coordinate copy feature
=> click
=> finished, coordinated in the clipboard

Include functions for expression builder

Would it be possible to include a set of functions for the expression builder based on the LatLonTools calculations?

Example:
MGRS functions to extract GZD and bigram etc for use in layouts.

Code for some MGRS functions as example (should be saved as python/expressions/latlontools.py):
latlontools.txt

Including functions like this would mean that it is possible to create layout templates with reference to mgrs with only one single plugin required.

/Thanks for a really useful plugin.

plugin breaks WMS loading

with: qgis 1: 2.18.13 + 14stretch

I have a problem with the extension, because I activate it I can not load a WMS (HTTPS) background.

I think it's a worry with pyhton, but have you ever had the case?

minor issue: not clear what file extension should be when Saving Locations

This is a minor issue, but as a user I tried to save a list of location (multi location tools), and was presented with as 'Save Lat,Lon File' dialog, which as 'type' showed me: 'Lat,Lon File'

selection_102

Which (peeking into the source code) appears a .csv or .txt file...

I would propose to just call it 'csv, txt' file in the 'type/filter dropdown',
OR add an option in the type dropdown 'show all files'.
As you cannot see the files if they do not have the right file extension.

Add YX to LatLon converter and vice versa

I think this is a very needed tool, for instance, when you want to move a point (vertex) to exact coordinates you can do it only changing XY of vertex. But if you have only decimal coordinates (xx.xxxx yy.yyyyy) you need to use external applications to convert them in XY and then to paste them in vertex's XY.

I have a python code for such conversion.

import ogr, osr

pointLON = 41.660391636282924
pointLAT = 42.20147902194137

# Spatial Reference System
inputEPSG = 4326
outputEPSG = 32638

# create a geometry from coordinates
point = ogr.Geometry(ogr.wkbPoint)
point.AddPoint(pointLON, pointLAT)

# create coordinate transformation
inSpatialRef = osr.SpatialReference()
inSpatialRef.ImportFromEPSG(inputEPSG)

outSpatialRef = osr.SpatialReference()
outSpatialRef.ImportFromEPSG(outputEPSG)

coordTransform = osr.CoordinateTransformation(inSpatialRef, outSpatialRef)

# transform point
point.Transform(coordTransform)

print (point.GetX(), point.GetY())

This works in reverse direction too.
If you have time and will adding of this function will make your tool even more popular and cool! :)

Convert Layer Extents to WGS84

Select a layer (vector or raster) and have the extent converted to wgs84 decimal degree coordinates, since most metadata creation software requires the input to be in geographic coordinates.

error after upgrade

Impossible de charger l'extension 'latlontools' provoque une erreur lors de l'appel à sa méthode classFactory()

SyntaxError: invalid syntax
Traceback (most recent call last):
File "/usr/lib/python3/dist-packages/qgis/utils.py", line 335, in startPlugin
plugins[packageName] = package.classFactory(iface)
File "/home/alex/.local/share/QGIS/QGIS3/profiles/Alex/python/plugins/latlontools/init.py", line 2, in classFactory
from .latLonTools import LatLonTools
File "/usr/lib/python3/dist-packages/qgis/utils.py", line 672, in _import
mod = _builtin_import(name, globals, locals, fromlist, level)
File "/home/alex/.local/share/QGIS/QGIS3/profiles/Alex/python/plugins/latlontools/latLonTools.py", line 8, in
from .zoomToLatLon import ZoomToLatLon
File "/usr/lib/python3/dist-packages/qgis/utils.py", line 672, in _import
mod = _builtin_import(name, globals, locals, fromlist, level)
File "/home/alex/.local/share/QGIS/QGIS3/profiles/Alex/python/plugins/latlontools/zoomToLatLon.py", line 10, in
from .util import epsg4326, parseDMSString
File "/usr/lib/python3/dist-packages/qgis/utils.py", line 672, in _import
mod = _builtin_import(name, globals, locals, fromlist, level)
File "/home/alex/.local/share/QGIS/QGIS3/profiles/Alex/python/plugins/latlontools/util.py", line 36
s = f"{deg:.0f}\xB0{min:.0f}'{sec:.{prec}f}""
^
SyntaxError: invalid syntax

Version de Python : 3.5.3 (default, Sep 27 2018, 17:25:39) [GCC 6.3.0 20170516]
Version de QGIS : 3.4.4-Madeira Madeira, f6ddc62

External Map

Can you add custom CRS selection of type of coordinates that are added to additional externel map provider through {lat} and {lon} I need this to be in GKY and GKX (EPSG:3912).

Thank you.

Python error when reloading processing algorithms

ATM, when the Lat Lon Tools plugin is installed & active, entering the QGIS settings window (to modify settings) and clicking on the [ OK ] button throws the following python error:

An error has occurred while executing Python code: 

RuntimeError: wrapped C/C++ object of type MGRStoLayerlgorithm has been deleted 
Traceback (most recent call last):
  File "/home/webmaster/.local/share/QGIS/QGIS3/profiles/default/python/plugins/latlontools/provider.py", line 20, in loadAlgorithms
    self.addAlgorithm( alg )
RuntimeError: wrapped C/C++ object of type MGRStoLayerlgorithm has been deleted

This is because the plugin code tries to add algorithm objects (created in the def init(self) function that have been deleted during the processing algorithms' reload process.

To fix this, simply move this line (https://github.com/NationalSecurityAgency/qgis-latlontools-plugin/blob/master/provider.py#L13) into the def loadAlgorithms(self) function (https://github.com/NationalSecurityAgency/qgis-latlontools-plugin/blob/master/provider.py#L18), that'll fix the error (which can actually cause QGIS to crash randomly).

copy to clipboard = corrupted data?

Hi
When i use the copy to clipboard command of the conversion menu they are some invisible characters (at the front of lat and long coord) who are also copied !?

On my mac i use copy to clipboard => paste on a filemaker db field=> export for mysql => (when checking the db on phpmyadmin i can see those character as ? or ?? at the front of lat and long coord)

at the end this break the js of my (openlayer6) map application ...

So the question is why we get those characters are they usefull ??

Thanks

Multi-location zoom select multiple entries and delete and display them

[IDEA ?]
If you make the table (with label and coordinates) in Multi-Location
Zoom multi-line selectable, you can get rid of the 'Show all markers'
checkbox. As you will show all selected rows in the table.
This would also make it possible to remove ALL rows in the table in one
go (using current red trash-button, which currently removes just 1 item
at a time).

Points Digitizing Tool Error to convert

I have a problem with "points and add features" . Longitude with error.
I trying to add 385733.804N, 951555.739W
Latitude all is OK! 385733.804N = "38.959390"
Longitude is wrong. 951555.739W = "-951555.739"

◦Degree, Minute, Second:
lat-long
385733.804N, 951555.739W (ddmmss.ssss, dddmmss.ssss) - In this format there must be 2 digits for latitude degrees, and 3 digits for longitude degrees.

Geopackage with id field throws "Feature xxxx for attribute update not found"

While demonstrating (online) the lat lon plugins (latest version: 3.5.0 in latest QGIS (master/3.18)) we both on different machines/os's got the same error:

2021-02-18T18:02:53 CRITICAL Layer cc : Feature -9223372036854775808 for attribute update not found.

Screenshot-20210218180047-842x332

I think/hope it is just a lat lon tools plugin, but I will also try/test it without the plugin...

To reproduce:

  • empty project + lat lon tools plugin installed
  • create a world layer by typing 'world' in the coordinate input in the bottom bar
  • create a fresh geopackage layer: point, EPSG:4326, 3 attributes: 2 text ones: 'aa', 'bb' and 1 integer one: 'id'
  • make the layer editable
  • create one point using 'lat lon digitize' by giving lat,lon coordinate
  • in the attr form presented, then ONLY add soemthing in either the aa or the bb field (NOTHING in 'id' and leave 'fid' on 'autogenerated'
  • toggle 'editable' on your new gpkg layer
  • get the error message..

Note: earlier I had this on I think 3.14 or 3.16...
I think it could have something to do with the combi of an unused 'id' field and the 'fid' field of gpkg itself?

I will also try to test it with normal digitizing: same setup but without lat lon tools.

Multi-location zoom add more attributes

And following up on that, a feature request: what about making it
possible to add even more attributes (I would like to have 3 ;-) )
My use case:
lat,
lon,
label, (which I can either use as label, or miss-use to style it)
data, (in my case a sensor value,)
time, (string)

Or maybe more general:
lat,
lon,
label,
data1,
data2,
data3,

where only lat an lon are mandatory,
first row determines the number of attributes (that is: you have to
start with 4 attributes to be able to have 4 in other rows).

DMS format

Hello!
What format should the DMS coordinates be in? I try to convert fields to points without success.
Point1 70 20 42.13 68 51 28.8

Zoom To - Zoom level

Zoom To

Is it possible to have a choice on the zoom level?

  1. Paste coordinates
  2. Zoom to 1:5000

Listen to Project CRS change

Listen to QgsMapCanvas::destinationCrsChanged so that Zoom To Lat Lon can be properly updated.

I think running configure() in ZoomToLatLon will do the trick

Add support for snapping

It seems that the plugin does not support snapping, even though enabled via "Project > Snapping Options" menu. Please consider adding support for snapping.

Clarify the definition of UTM and add additional UTM MGRS Grid Zone Conversions

This site https://www.maptools.com/tutorials/utm/quick_guide doesn't make it completely obvious that they are talking about MGRS. Moreover it makes demonstrably false claims like

The 10S is the Grid Zone Designation you are in. The Grid Zone is necessary to make the coordinates unique over the entire globe.

This site https://www.spatialreference.org/ref/epsg/wgs-84-utm-zone-10s/ makes the use of N and S as zones north of the equator and zones south of the equator completely clear, but doesn't mention MGRS.

Not to mention the Wikipedia article quoted awhile back in this conversation, which refers to both in an unclear fashion.

So my suggestion to you is that you make it clear that you are referring to UTM Zones as described by the spatialreference.org site and not UTM Grid Zone Designations (or MGRS if you like) as described by maptools.com. You may even want to be explicit in saying that there are only N and S designators in UTM Zones and they refer to metres north of the equator vs metres north of the -80th parallel.

You could call the version you have right now "UTM Zones" and the version you might develop "UTM Grid Zone Designations". Or maybe the latter as "UTM MGRS".

Python Error when clicking with Copy Latitude, Longitude

Hi there,

I'm currently using the tool and have set the output to be MGRS.

When I click on the canvas I receive the following Python Error:

An error has occurred while executing Python code: 

TypeError: QgsMapToolEmitPoint.toMapCoordinates(): arguments did not match any overloaded call:   overload 1: argument 1 has unexpected type 'QgsPointXY'   overload 2: argument 1 has unexpected type 'QgsPointXY' 
Traceback (most recent call last):
  File "C:/Users/evansc/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\latlontools\copyLatLonTool.py", line 198, in clicked
    pt = self.snappoint(pt)
  File "C:/Users/evansc/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\latlontools\copyLatLonTool.py", line 153, in snappoint
    return self.toMapCoordinates(point)
TypeError: QgsMapToolEmitPoint.toMapCoordinates(): arguments did not match any overloaded call:
  overload 1: argument 1 has unexpected type 'QgsPointXY'
  overload 2: argument 1 has unexpected type 'QgsPointXY'


Python version: 3.7.0 (v3.7.0:1bf9cc5093, Jun 27 2018, 04:59:51) [MSC v.1914 64 bit (AMD64)] 
QGIS version: 3.4.0-Madeira Madeira, 4a4b62ed19 

external map settings error

Can't define additional external map providers - error message appears during openning settings form:
"File "C:/Users/xxx/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\latlontools\settings.py", line 552, in showEvent for item in settings.userMapProviders: TypeError: 'NoneType' object is not iterable".
Built-in map providers list is empty.

plugin version 3.3.22,
QGIS 3.10.9 x64,
Windows 10

error

message

Feature Request : Qgis URL

Hello,

A silly idea:

Have a type url:
latlong: //45.157558, 6.151008

Who opens QGIS and focuses on the position

This could be used in emails, wiki etc.
To make life easier for people who have to look at a geographic location.

TypeError

Getting the following issue in QGIS 2.18.7.
This is on mac, qgis installed via homebrew.
Looked at latlontools/settings.py file but don't see anything wrong there.
Last working version was perhaps 0.7/0.8.

Couldn't load plugin latlontools due to an error when calling its initGui() method 

TypeError: coercing to Unicode: need string or buffer, QPyNullVariant found 
Traceback (most recent call last):
  File "/usr/local/Cellar/qgis2/2.18.7_1/QGIS.app/Contents/MacOS/../Resources/python/qgis/utils.py", line 342, in startPlugin
    plugins[packageName].initGui()
  File "/Users/joao/.qgis2/python/plugins/latlontools/latLonTools.py", line 30, in initGui
    self.settingsDialog = SettingsWidget(self, self.iface, self.iface.mainWindow())
  File "/Users/joao/.qgis2/python/plugins/latlontools/settings.py", line 59, in __init__
    self.readSettings()
  File "/Users/joao/.qgis2/python/plugins/latlontools/settings.py", line 129, in readSettings
    if not os.path.isfile(self.qmlStyle):
  File "/usr/local/opt/python/Frameworks/Python.framework/Versions/2.7/lib/python2.7/genericpath.py", line 37, in isfile
    st = os.stat(path)
TypeError: coercing to Unicode: need string or buffer, QPyNullVariant found

[Digitizer] Feature Attributes UI is missing default values which are configured in Layer Properties->Attributes Form

Reproduction steps:

  1. Add a default value at Layer properties->Attributes Form->Defaults
    image
  2. Use "Lat Long Digitize" to add a feature and enter the coordinates
  3. At the attribute form the default value is not set:
    image

If I add a feature with the standard "Add Point feature" it's setting the default value:
image

What is the difference here? I thought these two ways are calling the same method openFeatureForm()?

QGIS 2.14, buitinerror

Hi,

trying to install the plugin in qgis 2.14.1 here, I get the following error:

builtinerror

will try on other systems/versions too

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.