Maps

Maps are components that take their layers from other components, with each layer being a drawing, an image or a labels component.     Map windows have layer tabs at the bottom of the map for each labels.  Tabs are convenient when maps have only a few layers.   When maps have many layers, use the Layers pane to manage layers.

 

Drawings, images and labels that appear in a map can use coordinate systems that are different from the map.  They will be reprojected on the fly into the map's coordinate system when displayed in the map.   The same component can simultaneously appear in many different maps.

 

Maps take zero storage space.  A map is just a list of layers that should be shown together.  All the data for layers in a map stays stored in the components that are layers.  We can add as many layers to a map as we want, and that will not increase the size of our project when we save it.   We can add as many maps as we like to a project without making the project larger.   

 

 

 

 

 

 

The map shown above contains eight layers: six layers are turned on (visible) and two layers have been turned off (hidden).   The Google Map satellite layer is a raster image from a web server, as are the hidden OpenSteetMap, and Bing layers.  All the other layers are vector drawings.   The buildings layer in the illustration is the active layer and is partially transparent.  Commands, like those in the Transform pane, operate on the active layer.

 

Each layer in the map has a tab at the bottom of the map window.  Layers to the left are displayed above layers to the right.  

 

 

Use the Layers pane to manage many layers, to turn layers on/off, to group layers in folders, and to set opacity of layers.  

Create a Map

Manifold provides four main ways to create new maps interactively.

 

 

 

 

 

We can also create new maps using queries.   Press the Edit Query button in any New Map dialog to see the SQL query that will create the map with those layers and the given coordinate system settings.

 

See the File - Create - New Map topic for details and examples of all the above ways to create a new map.   See the Example: Create Maps topic for step-by-step illustrations of different ways to create maps.

 

Changing a Map's Projection

We can change the projection of a map at any time.

 

To change a map's projection, in the Component pane click on the coordinate picker button for the map's coordinate system.   

 

To change the projection used by a map:

 

  1. Open the map.
  2. In the Component pane click the coordinate picker button for the map.
  3. Choose the new coordinate system desired, either from the favorites listed or by choosing More... to launch the full Coordinate System dialog.

 

See the Coordinate System dialog topic for details on using the dialog.

Layers in a Map

Layers in a map are seen in the map as if they were a vertical stack of transparent sheets, with the contents of each layer drawn on that sheet. If the contents of a drawing layer have "empty space" between the objects shown in that layer, whatever is in a layer below can be seen through that empty space.   Labels have empty space between the labels and if an image has any transparent pixels layers below the image can be seen through those regions of transparent pixels.

 

Layers in maps are persistent:  when we add layers to a map and then arrange those layers in order, if we close the map and then open it again those layers will still be in the map in that order.   If we save the project, the next time we open the project the map will still have exactly the same layers in the order saved.

 

 

 

 

 

 

 

A drawing, image or labels component can be a layer in many different maps at the same time and it can be open in its own window at the same time.   Changing the component in any one of those windows will change it in all of them.

 

The bottom background color for the map, by default white, is set in Layers Pane when a map is open.

 

 

The vertical order of layers is important because opaque shapes drawn in a higher layer will hide items drawn in lower layers below those shapes.   

 

 

For example, suppose we would like to show two layers together in a map, a layer of rivers drawn as blue lines together with a layer of provinces or states drawn as opaque shapes in various colors.   We should position the rivers layer above the provinces layer so that the solid, opaque shapes of provinces will not hide the river lines below.

 

 

Maps can have many layers.   To manage these it is often most convenient to use the Layers pane in addition to the layers tab strip at the bottom of the map.

 

Tech tip: Unless they contain regions of fully or partially transparent pixels, images are generally opaque and will hide anything in layers below them. That includes image layers such as those brought in from tile image server data sources such as Open Street Maps, Bing, Yandex satellite images, Google and so on.

 

If we want to create a map that shows locations in a drawing using a Google street map as a background, we should put the drawing layer above the Google layer, that is, with the drawing's layer tab to the left of the Google layer tab.   If we do not see some expected layer in a map, we should drag that layer's tab all the way to the left to make sure it is the uppermost layer in the map.

 

Do not use the same color as the background color for objects in layers because then they will be invisible against the background color.  Likewise, do not format objects entirely in transparent color as then they will be invisible no matter what the background color may be.   See the Example: How Not to Format a Drawing topic for an example.

Layer Tabs in Map Windows

When a map is opened in a window just like with other components the name of the map will be in the tab for the window at the top of the window.  In addition, the layers of the map will be shown as tabs at the bottom of the map window, each tab giving the name of the layer.

 

To fit into this documentation, Illustrations show an artificially small Manifold desktop, with only two panes, docked to the right side.   In real life we use a much larger Manifold desktop, and all panes would be turned on, with some panes docked to the left and others docked to the right.  Right-click a pane's  tab to change where it is docked.  Manifold will remember that new arrangement for our next session.

 

 

 

 

The layer tabs of a map show the order of layers with higher layer tabs to the left and lower layer tabs to the right.   The illustration above shows a map called Australia Hydro that has been opened.  The map has three layers, all drawings, which consist in order from top layer to bottom layer of the Lakes, WatercourseAreas and WatercourseLines drawings.   We have used the Style pane to format the colors of lakes, areas and lines in blue colors.  

 

 

 

The  Layers pane has been used to assign a light beige background color to the map.

 

We can move a layer up or down within the display stack by dragging the layer tab for that layer to the left or right, or by Ctrl-clicking the layer's row in the Layers pane and moving it up and down in the stack with the Layers pane toolbar arrow buttons.

 

Tech tip: Careful readers will notice the illustration shows a map that has a layer with areas above a layer that contains lines. That is unusual.  Because areas are usually opaque they will hide any lines beneath a particular area so we would normally position a layer with lines above a layer with areas.  

 

The illustration takes the unusual step of putting a layer with areas above a layer of lines because the data sets it utilizes, from an Australian government website, are inconsistent in how they show streams and rivers as either lines or areas.  In some cases wider rivers are shown as areas in one drawing, like the broad river at the top of the window, and also as a network of interwoven lines in an accompanying drawing.  

 

To avoid a confusing display that shows river lines wending their way through a lake, in our illustration we put areas above lines so that any inconsistency is resolved visually in favor of a prettier and more logical area.

 

 

 

 

Shift-click the title tab for a window or a pane to undock it.   We can then resize the undocked window as we like and move it to anywhere on our Windows desktop.

 

 

Double-clicking a layer tab turns that layer on and off for display.   

 

 

 

In the illustrations above we have double-clicked the WatercourseLines layer to turn it off, leaving only the Lakes and the WatercourseAreas layers on for display.  The illustrations show the map as an undocked window.   Shift-click the title tab for a window or a pane to undock it.

 

If we can't see something in a layer that we expect to see it could be that something in a higher layer is blocking it.   If we do not want to drag our layer of interest all the way to the left to make it the uppermost layer, we can double-click off all layers above our layer of interest to see if that indeed is the case.   

 

 

If layer names do not fit we can see layers by clicking the down triangle to choose from a pull-down menu of layers.  We can also hover the mouse over the layer to see the full layer name in a tooltip.

 

We can add layers to a map by dragging components from the Project pane and dropping them into the map.   We can drag and drop one component at a time or several components at a time, using Ctrl-click or Shift-click to highlight more than one component at a time in the Project pane.  We can also drag and drop a folder into the map to add all the components found in that folder and subfolders.

 

We can delete a layer from a map by right-clicking the layer tab and choosing Delete.  That will delete the layer from the map - it will not delete the layer from the project.

 

 

Tech Tip: When adding the first layer to a map, or, if we do not see anything in a map when we open it,  we should make sure to press the Zoom to Fit button.   It is always possible the data is in the map but the viewport of the map is aimed at a location and at a zoom level where the data is not visible.  Another problem might be lack of a coordinate system in the table from which the drawing or image is created.   Open the table's properties: if it does not have a FieldCoordSystem property it does not have a coordinate system and one should be specified.  

Layer Tabs and Folders

Layers can be grouped within folders in the Layers pane.  All the layers that are in a folder are grouped into one tab, with the name of the folder on the tab.  Using folders allows us to turn entire groups of layers on and off together, and to reposition an entire folder full of layers up and down in the display stack.

 

When layers are grouped together in a folder, one layer in the group can be the active layer for that tab.  The name of the active layer appears on the tab with the folder.  We can switch to a different active layer within that folder layer tab in a map window by right-clicking the tab, Switch to and then choosing the desired folder.   We can also switch to a different active layer within a folder by Alt-clicking the desired layer in the Layers pane list.

Context Menus for Layer Tabs

Right-clicking on a layer tab in a map calls up a useful context menu:

 

Switch to

When a map tab appears for a folder, the Switch to command allows choosing which of the layers within that folder will be the active layer for that tab.

Visible

Turn the layer on or off for display.

Center

Pan the map viewport to center the contents of this layer.

Zoom

Pan and zoom the map viewport to zoom to fit the contents of this layer.

Zoom to Selection

Enabled if there is a selection in the layer.  Zoom to fit the selection.

Refresh

Refresh the layer, taking the latest data from whatever data source is used.   Used in cases where data sources might not signal changes to enable automatic refreshing.

Delete from Map

Delete this layer from the map.   Does not delete the component from the project.

Open

Open this layer in its own window.

Open Table

Open this layer's table in its own window.

Show in Layers

Pop open the Layers pane and move the list cursor onto this layer, scrolling the list and opening any folders as necessary to bring the layer into view.

Show in Project

Highlight this layer's component in the Project pane, expanding hierarchies and scrolling the project pane as necessary.

Properties

Launch the View - Properties dialog with this layer's component.

 

Consider a map that contains two drawing layers taken from an ESRI gdb file database shown above a layer taken from a Bing image server layer.    For a step-by-step example working with an ESRI gdb file database see the Example: Connect to an ESRI GDB File Geodatabase  topic.

 

 

Right-clicking on the wMainDrawing layer calls up a context menu:

 

 

 

Clicking on the Zoom option will zoom to fit to show the contents of that layer.

 

 

Users familiar with ESRI examples utilizing file geodatabases will recognize the drawing as one of the sample data sets for Naperville, Illinois, in the US, showing the locations of fire hydrants on water mains in Naperville.   

 

Users of file geodatabases also know that they can often contain very many components.   In a large Manifold project that contains very many data sources and components it is good we have a Show in Project context menu option to highlight in the project the component used for the layer.

 

 

Suppose we start with a Project pane where all data sources and folders are collapsed, that is, closed.   Suppose we would like to find in the Project pane the wHydrant Drawing layer that is used in the map.

 

 

We right-click on the wHydrant Drawing tab in the map and choose Show in Project.

 

 

Instantly, the Project pane opens up data source and folder hierarchies as necessary and scrolls to show the highlighted component.

Zoom to Fit Shortcuts

The following commands work with any window that has a tab at the bottom:  map windows, drawings in their own windows, images in their own windows, etc.

 

Ctrl-click the bottom layer tab of any window to Zoom to Fit the contents of that layer.

 

 

Shift-Ctrl-click will Zoom to Fit any selection that is in the layer.  This is a great way to see in a drawing or map layer those objects that have been selected in a drawing's table.

 

See the Manifold 9 - Incredibly Convenient Zooms video for the above in action.  

 

A Selections Short Cut - Maps in real world projects can have very many layers, and each of those layers might have a selection in it.   If we want to clear all selections in all layers in a map, a quick way to do that is to use the Edit - Select None Map menu command.  That will deselect all objects in all layers in a map, including within hidden layers.  

Layers Pane with a Map

The tab strip of layers at the bottom of a Map window is useful for maps with few layers.  When maps have many layers, the Layers pane is our primary interface to manage layers.

 

 

The layers list in the Layers pane shows the display order of layers in the window, with higher layers in the list rendered above lower layers in the list.  A "virtual layer" called the Background appears at the bottom of the list to allow us to control the background color of the window and to turn background color off and on.

 

Click on the on/off box to turn a layer off and on, and double-click the % value to change the opacity of a layer.  For example, the buildings layer in the illustration above has an opacity of 50%.  We can easily move one or more layers up and down the list, delete them from the map and combine them within folders for easy management as a group.   See the Layers Pane topic for many examples and illustrations.

 

The illustration above shows only a few layers, but when there are dozens of layers in a map the Layers pane is the only way to manipulate layer ordering, to group layers into folders, and to quickly turn layers off and on.

Map Layers and Projections

A new, blank map uses whatever projection we assign to it when creating the map with the New Map dialog.   

 

To change a map's projection, in the Info pane click on the coordinate picker button for the map's coordinate system.   

 

A map has a projection that it uses, that is, a coordinate system, which we can see in the Info pane.  The Component tab in the Info pane will also report the projections used by the active layer in the map.

 

 

 

 

The components which appear as layers in a map window can have different coordinate systems from the map window.  The map window will automatically convert on the fly those different coordinate systems into the map's coordinate system to display such layers in the map.

Reprojection on the Fly

Manifold is very fast at reprojecting data on the fly, using parallel processing if multiple processor cores are available.  Manifold is so fast at reprojecting layers on the fly for display that even with large layers, tens or hundreds of gigabytes in size, normally we can pan and zoom maps instantaneously without any delays at all.  It has become perfectly routine to drop a 200 GB image into a map where the image is in a different projection from the map and still have panning and zooming in the map happen instantly.

 

But even though Manifold is exceptionally fast at reprojecting on the fly,  the process does take some time.  What we do not notice with layers in the tens or hundreds of gigabytes might become noticeable when panning and zooming in maps that contain exceptionally huge layers or exceptionally many large layers with a native projection different than that used by the map.  

 

In such cases, to get the fastest possible rendering performance in a map it is best to ensure that all components which are displayed as layers in the map use exactly the same coordinate system as the map window does.  When all components use the same projection as the map, no reprojection on the fly is necessary.  For example, in the illustration above the layers all use the same Latitude / Longitude coordinate system used by the map.  

 

 

If only one layer is exceptionally large, then ideally the map should use whatever projection is used by the largest component.   When creating a new map if we know that one of the layers will be a 200 GB image and the other layers will be small drawings in a different projection, we should add the 200 GB image to the map first so the map will use that image's projection for the map.   We can then drag and drop the small drawings into the map.   

 

 

When images and drawings that are layers within a map use the same projection as the map, when the map renders there will be no need to reproject the image on the fly into the map's coordinate system.  

 

Rotated Views and North Arrows

We can quickly and easily create a map presentation that is a rotated view, other than "North up."  In a matter of seconds we can rotate the view by using a rotated projection, as shown in the Rotated Views topic.  

 

Parallelized Layer Rendering

Manifold renders maps using parallel performance, taking advantage of multiple cores to render multiple layers and then merging data rendered for different layers in a user interface thread.    As a result maps which have many layers can render as fast as a single drawing with the same amount of data.  

 

 

The Log Window will report rendering times for map windows and will report after an @ character the parallelization coefficient achieved in rendering, with a higher coefficient better.  In the example above involving very large vector data the lower value of 2.0 involved a zoom or pan operation in which the contents of few layers were visible while the last value of 8.1 most probably involved a Zoom to Fit operation where the contents of many layers with many objects were visible in the view.   Small data sets will often show low parallelization coefficients  because with small data it is quicker to simply render the data in a single thread than to launch multiple rendering threads on multiple processors.

 

We can see parallel rendering in action when working with bigger data.  Manifold will display a blue bar at the bottom of the tab for layers in the process of being rendered.   Unless we are working with large data we are unlikely to catch more than a fleeting glimpse of a blue bar at the bottom of a layer tab.   

 

 

The screenshot above shows a layer tab for a drawing that contains all of the roads in the United States (approximately 13 gigabytes of vector data) which is currently being rendered, a process that takes under a second on a reasonable desktop computer.  The smaller layers which contain roads for the states of New Hampshire and Maine have already finished rendering in their threads.

 

If a layer has been updated while it is in the process of rendering, the map window will automatically restart rendering that layer to ensure the latest version is displayed.    That is important when working with components that can change dynamically.

 

Components displayed as layers in a map can come from any of the sources used to bring data into a Manifold project, some of which can change the components we see without any editing by us.   Some such sources, for example, linking in a drawing from a spatial DBMS like Oracle Spatial, could easily result in drawing data that changes as we are viewing it, for example, when someone else also connected to that spatial DBMS edits the drawing on a different computer.

Notes

Deletions are Confirmed - Deleting objects or labels in layers in a map window displays a confirmation dialog. The default button in the confirmation dialog is set to Cancel.  If we do not want to see the confirmation dialog, we can check the Never show this again box.  That will remove the confirmation dialog for deleting frames in layouts, for deleting objects in drawing layers, for deleting labels, and for deleting records in tables.    Another way to eliminate the confirmation dialog is to uncheck the Confirm deleting records box in the Tools - Options dialog.  Objects and labels are records in the associated drawing's table, hence the "records" terminology.

 

No redundant layers - A given layer can appear just once in a map.    For example, a drawing of roads can appear only once as a layer in a map.  We cannot have a map that has two layer tabs that both refer to the same roads drawing.   It is possible using programming or by manually changing a map's properties to add two layers to a map that both refer to the same roads drawing.  However, in that case only one layer tab will appear in the map window.   Both "roads" layers will appear in the Layers pane but only the first, upper layer will be valid and will be usable.   Any additional layers referring to the same roads drawing will be invalid and will not be usable.  The invalid layers will appear in the Layers pane so we can select them and delete them, a useful way of cleaning up programming errors.

 

Measurements - We can measure distances and bearings in maps using the Tracker tool.

 

See Also

Getting Started

 

Tables

 

Rotated Views

 

Drawings

 

Images

 

Labels

 

Project Pane

 

Style

 

Tracker: Measurements

 

Component Pane

 

Layers Pane

 

Map Projection

 

File - Create - New Map

 

Example: Project Pane Tutorial - In this example we take an extended tour of the Project pane, engaging in a variety of simple but typical moves that are illustrated step by step.

 

Example: Layers Tutorial - We take a tour of the Layers pane, learning how to manage layer display order, select layers, turn several layers on and off at the same time, alter opacity settings for one or more layers and how to change background color.

 

Example: Create Maps - Maps are used to show layers that can be drawings, images, and labels.  This topic shows how to create new, blank maps, how to create maps from existing components, and how to create maps from other maps.

 

Example: How Not to Format a Drawing -  When using Style to format a drawing it is a really bad idea to use the same color for objects that is used for the background color.    It can also be a bad idea to use transparent color.   This topic illustrates why.

 

Example: Reproject a Drawing - An essential example on changing the projection of a drawing, either within the drawing itself, or by changing the projection of a map window that shows the drawing and on the fly reprojects the drawing for display.

 

Example: Create a Rotated View of a Map - Illustrates use of rotated views, that is, map displays which are not "North up," using a  Bing street map image server layer, to show how even layers fetched on the fly from a web server can be rotated.  The topic also shows an alternate way of creating North arrows that is initially simpler, but ultimately much less convenient than the more sophisticated method illustrated in the Rotated Views topic.