How to Style and Configure Map Layers in InstantAtlas Reports

Author: GeoWise User Support
Released: 05/07/2013
Version: 6.7.0
How to Style and Configure Map
TM
Layers in InstantAtlas Reports
visualise | communicate | ENGAGE
How to Style and Configure Map Layers in InstantAtlas Reports
g the InstantAtlas Area Profile Template User Guide
Table of Contents
1.
Introduction ...................................................................................................................................... 1
2.
Base Geography Layer .................................................................................................................... 1
3.
© GeoWise Ltd. 2013
2.1.
Setting the Border Width for the Map ...................................................................................... 1
2.2.
Setting the Border Width for the Legend ................................................................................. 2
2.3.
Setting the Default Border Colour and Fill Opacity for Map and Legend ................................ 3
2.4.
Setting the Point Size(s) .......................................................................................................... 4
2.5.
Changing the Tooltip of Map Features .................................................................................... 5
Contextual Geography Layers ......................................................................................................... 7
3.1.
Setting the Border Width and Fill Opacity for the Map ............................................................ 7
3.2.
Setting the Border Width and Fill Opacity for the Legend ....................................................... 8
3.3.
Setting the Border and Fill Colours for Map and Legend ........................................................ 8
3.4.
Displaying Contextual Points as Symbols ............................................................................... 9
3.5.
Setting the Point Size............................................................................................................. 10
3.6.
Activating Tips for Contextual Features ................................................................................. 11
4.
Labelling of Map Layers ................................................................................................................. 14
5.
InstantAtlas Support....................................................................................................................... 17
visualise | communicate | ENGAGE
How to Style and Configure Map Layers in InstantAtlas Reports
The following chapters will explain where the style settings for map layers
1. Introduction
g the InstantAtlas Area Profile Template User Guide
InstantAtlas™ is award-winning software for publishing eye-catching,
and the legend are held, how they can be edited, and whether the settings
affect a map layer, the legend, or both.
stand-alone, dynamic web reports that make the regional and local
patterns in your data easy to see.
You can create interactive atlases,
2. Base Geography Layer
dashboards, profiles, or key indicator reports that allow information
professionals, analysts, policy advisors and management executives to
2.1. Setting the Border Width for the Map
view and explore patterns, monitor key indicators, present trends and
support decision-making. For more information about InstantAtlas dynamic
You may want to specify a thicker border surrounding each of the polygons
reports, please visit www.instantatlas.com.
or points in your base layer. To do this, click on the ‘Properties’ button of
It is assumed for this guide that you have read the user guides for the
Publisher, the Designer and the Style Editor.
Please note that this guide applies to the InstantAtlas Flash
templates only. With the HTML Edition templates most map layer
your map layer in the ‘Choose Your Base Geography’ screen to open the
‘Layer Properties’ dialog. On the ‘Settings’ tab change the value of the
‘Border thickness’ (Figure 1).
Please note it is not possible to change the border width of your base
layer features after the publishing process.
settings are set in the Publisher in the properties dialog of each layer
and can be changed after the publishing process by editing the
map.js file in a text editor.
Map layers are added to InstantAtlas reports as either base or contextual
geography types. Either type may consist of polygons, lines or points,
whose styles and information are displayed in the legend. Depending on
how you would like to style your map layers and legend, you may need to
edit some of the default style settings. Some settings may only be edited
during the publishing process by using the Publisher. Other settings may
only be defined by using the Designer or Style Editor after the publishing
process.
© GeoWise Ltd. 2013
Page 1
visualise | communicate | ENGAGE
How to Style and Configure Map Layers in InstantAtlas Reports
Figure 1
Figure 2
g the InstantAtlas Area Profile Template User Guide
2.2. Setting the Border Width for the Legend
To set the border width of the legend symbols you need to do the following:
1. Open the file called default.css in the Style Editor.
2. Find the style class called ‘.baseLayer’ in the left hand panel.
This setting only affects the features displayed in the map itself.
The
legend symbols will still show a border width of the default (1 pixel, see
3. In the bottom right corner of the window, click the icon with the
green plus
to add a property to this class (Figure 3).
Figure 2). If you want to change the legend symbol border width, please
4. Choose the property ‘borderThickness’ from the list and click ok.
refer to section 2.2 of this guide.
5. Set the border thickness to the same value you chose for your
base geography in the Publisher.
6. Save the style sheet. Refresh your browser window to see the
changes you made.
© GeoWise Ltd. 2013
Page 2
visualise | communicate | ENGAGE
Figure 3
How to Style and Configure Map Layers in InstantAtlas Reports
Figure 4
g the InstantAtlas Area Profile Template User Guide
You can set your report to different default values of these properties by
using the Style Editor to edit the style class called ‘.baseLayer’. The
relevant properties are called ‘borderColor’ and ‘fillAlpha’ (Figure 5). The
‘fillAlpha’ values range from 0 to 1, where 0 indicates complete
transparency (in other words, no legend colours are visible) and ‘1’ will
make all map features completely opaque.
Figure 5
2.3. Setting the Default Border Colour and Fill Opacity for
Map and Legend
By default, end-users may change the border colour and fill opacity in the
legend settings menu (Figure 4).
© GeoWise Ltd. 2013
Page 3
visualise | communicate | ENGAGE
The property
called
‘fillColor’
used
g the InstantAtlas
Area Profile
Template
UserisGuide
How to Style and Configure Map Layers in InstantAtlas Reports
for polygons and lines when:

the map features are not part of an applied filter or

they are not included in the data.xml file or

the defined legend range does not cover the values of these
Figure 6
features.
In each case above, point base layers will not appear on the map.
Therefore this property does not apply to point base layers.
2.4. Setting the Point Size(s)
Points with numeric indicators can be displayed in two ways. The default
setting is to display proportional point sizes, which are dependent on
indicator values; in other words, large indicator values will result in large
points in the map. The other option is to set all points to be the same size,
but filled with different colours depending on indicator values. You can
specify your choice with the Designer by activating or deactivating the
property called ‘Point Proportional Symbols’ in the ‘Legend Properties’
(Figure 6).
The ‘Point Symbol Min Size’ and ‘Point Symbol Max Size’ properties
control the default minimum and maximum point size when the ‘Point
Proportional Symbols’ option is active. If you choose not to use
proportional symbols, or if you have categorical indicators, you can adjust
the point size using the property ‘Symbol Size’.
© GeoWise Ltd. 2013
Page 4
visualise | communicate | ENGAGE
2.5. Changing the Tooltip of Map Features
g the InstantAtlas Area Profile Template User Guide
The content of the tooltip, which appears when you hover with the mouse
How to Style and Configure Map Layers in InstantAtlas Reports
In addition to the default area name and indicator value, this code adds
another paragraph (starting on a new line) with ‘Count: ’ as a static text and
the associate with the name ‘count’ as a dynamic value (Figure 8).
pointer over a base geography feature, is controlled by the ‘Tip’ property of
the Map in the InstantAtlas Designer. This property contains the code for
Figure 8
the tooltip, which by default looks like this:
<p>${featureName}: ${indicatorValue}</p>
The <p>...</p> indicates that it is HTML code (the <p>-tag stands for a
paragraph)
Example 2:
<p>${featureName}: ${count}</p>
${featureName} and ${indicatorValue} are substitution variables. Their
values are dynamic and change depending on the map feature you mouse
This will replace the indicator value with the count associate (Figure 9).
over.
Figure 9
The colon in between the variables is static text. Figure 7 shows how the
default tooltip looks for the post code sector with the name ‘EH14 7’.
Figure 7
The style of the text can be set in the Style Editor in the style class
‘MapTip’. You can also access this via the Designer in the ‘Styles’ tab. If
you wish to format certain parts of the text differently to the overall style,
You can add any other static text, substitution variables or HTML tags if
you like.
Example 1:
© GeoWise Ltd. 2013
you can do this using HTML. The following HTML tags are supported:
Anchor tag (<a>)
Bold tag (<b>)
Break tag (<br>)
<p>${featureName}: ${indicatorValue}</p><p>Count:
Font tag (<font>)
${count}</p>
Image tag (<img>)
Page 5
visualise | communicate | ENGAGE
Italic tag (<i>)
g the InstantAtlas Area Profile Template User Guide
List item tag (<li>)
How to Style and Configure Map Layers in InstantAtlas Reports
<p>
<b>
<font size ="14" color="#00aa00" face="Arial">
Paragraph tag (<p>)
${featureName}: ${indicatorValue}
Text format tag (<textformat>)
</font>
Underline tag (<u>)
</b>
As you can see from this list, you can also add images to the tooltip. When
</p>
doing this, please be aware that the tooltip box does not recognise the
${flag}<br><br><br><br>
dimensions of the image. This means that it is possible that the image will
<p><b>Capital:</b>${capital}</p>
float out of the text box. The same will happen to text next to the image
<p><b>Area:</b> ${area} mi²</p>
(Figure 10).
<p><b>Population:</b> ${population}</p>
Figure 10
The above code will create a tooltip as shown in Figure 11. The ${flag}
variable calls dynamically the content of the ‘flag’ associate which contains
the HTML code for each flag image for each county. For ‘South Africa’ this
would be:
<img vspace="0" src="flags/flag_south_africa.png" />
To fix this, you need to make sure that you always have text above and
Figure 11
below the image. To get the text below the image you need to add a
certain number of break tags (<br>) after the image into your HTML code.
The following code is an example of what can be done using a combination
of HTML tags, static text and substitution variables. Please note that line
breaks and indentations shown in the code were added to improve
readability. To use the code within the ‘Tip’ property you will need to delete
all line breaks and indentations so that the code is on one line.
© GeoWise Ltd. 2013
Page 6
visualise | communicate | ENGAGE
3. Contextual Geography Layers
How to Style and Configure Map Layers in InstantAtlas Reports
Figure 12
g the InstantAtlas Area Profile Template User Guide
3.1. Setting the Border Width and Fill Opacity for the Map
You may want to specify a thicker border representing each of the
polygons, points or lines in your contextual layer. To do this, click on the
‘Properties’ button of your contextual map layer in the ‘Choose Your
Contextual Geographies’ screen to open the ‘Layer Properties’ dialog. On
the ‘Settings’ tab change the value of the ‘Border thickness’ (Figure 12).
By default, contextual layers are published completely transparent. This
means if you specify a fill colour in the Style Editor after the publishing
process, you will not see your changes reflected in the map. To enable
your contextual layer to contain colours, in the Publisher you must set the
‘Fill opacity’ of your contextual layer to any number greater than ‘0’. Values
can range between zero and one, where ‘0’ indicates total transparency
and ‘1' will cause total opacity (Figure 12).
Border width and fill opacity changes to the contextual layers may only
be set during the publishing process. It is not possible to change these
settings after publishing.
However, the border width and fill opacity changes effected in the
publishing process will only appear in the map component of the report.
© GeoWise Ltd. 2013
Page 7
visualise | communicate | ENGAGE
Legend symbols will continue to show a border width with a default 1px
How to Style and Configure Map Layers in InstantAtlas Reports
Figure 13
g the InstantAtlas Area Profile Template User Guide
with a transparent fill. Please refer to section 3.2 or information on how to
adjust the border width and fill opacity of the legend symbols.
3.2. Setting the Border Width and Fill Opacity for the
Legend
To set the border width of the legend symbols you need to do the following:
1. After publishing your report, use the Style Editor to open the
stylesheet, which is called default.css .
2. In the left hand panel, find the style class for the contextual layer
you wish to change, e.g. ‘.contextualLayer2’ (Figure 13). You can
easily see from the applied border colours which style class is the
one you need to edit.
3. In the main panel set the property ‘fillAlpha’ to the same value you
chose as fill opacity for this contextual layer in the Publisher (0 =
completely transparent, 1= completely opaque).
4. Set the property ‘borderThickness’ to the same value you chose for
this contextual geography in the Publisher.
5. Save the style sheet and refresh your browser window to see the
As the default fill colour for all contextual layers is white, if you only
change the property ‘fillAlpha’, you may not see any difference in the
legend symbols because the background is also while by default.
3.3. Setting the Border and Fill Colours for Map and
Legend
changes.
The colours for the border and fill of your contextual layers may be defined
in the Style Editor. Select the style class of the contextual layer you wish to
change in the left hand panel, for example ‘.contextualLayer2’ (Figure 14).
You can easily see from the applied border colours which style class is the
one you wish to edit. The first two properties in the main panel define the
border and fill colour.
© GeoWise Ltd. 2013
Page 8
visualise | communicate | ENGAGE
Figure 14
g the InstantAtlas Area Profile Template User Guide
How to Style and Configure Map Layers in InstantAtlas Reports
3.4. Displaying Contextual Points as Symbols
If you do not want your contextual points to be displayed as filled or hollow
circles, you can upload an icon file into the Publisher when you add the
contextual layer (Figure 15).
Figure 15
If you do not see the fill colour applied in your map, you must re-publish
your report and ensure the fill opacity for the contextual layer in question is
set to a value greater than zero. Please refer to section 3.1 for further
information.
If you do not see the fill colour applied in your legend, then the fill of the
legend symbols are set to be transparent. Please refer to section 3.2 for
information on how to change this.
When lines are used as a contextual geography, the colour of the lines
are controlled by the fillColor property, which by default will always be set
to appear as white in the map.
© GeoWise Ltd. 2013
Page 9
visualise | communicate | ENGAGE
How to Style and Configure Map Layers in InstantAtlas Reports
This icon replaces the default circle symbol for each of the points
g the InstantAtlas Area Profile Template User Guide
3.5. Setting the Point Size
(Figure 16).
You can set the size of contextual points in the Style Editor in the style
Figure 16
class for the relevant contextual layer. The property is called ‘symbolSize’
(Figure 17).
Figure 17
Valid icon formats are JPG and PNG.
If you would like to have a
transparent background, you need to create a PNG file since the JPG
format does not support transparency.
Some of the most common symbols in the different colours can be found in
the installation folder of your InstantAtlas software, in a subfolder called
If you are using an image file to display your contextual points as
‘icons’. The default location for this is:
symbols, it is best not to change the size of the symbols in the Style Editor
C:\Program Files\GeoWise\InstantAtlas\icons\.
as described in this section. If you do, you may find that the image quality
of your icons is greatly reduced. Instead, change the dimensions of the
image outside of InstantAtlas using graphics software, and use the resized
image to represent the contextual point layer.
© GeoWise Ltd. 2013
Page 10
visualise | communicate | ENGAGE
3.6. Activating Tips for Contextual Features
How to Style and Configure Map Layers in InstantAtlas Reports
Figure 18
g the InstantAtlas Area Profile Template User Guide
You might wish to see the names of your contextual geography features
pop up when you hover your mouse over them. There are two steps
involved to achieve this:
Step 1
The values you wish to see when you hover over the contextual layer must
be included within a field of the digital map file you want to use as your
contextual layer. You must then choose this field as the ‘Feature name
field’ when adding that contextual geography in the Publisher. For example
if you want to see the town names when you hover over the points of the
town layer, you would choose the ‘NAME’ field as the feature name field
(Figure 18).
© GeoWise Ltd. 2013
Page 11
visualise | communicate | ENGAGE
Step 2
How to Style and Configure Map Layers in InstantAtlas Reports
Figure 20
g the InstantAtlas Area Profile Template User Guide
The second step is to activate the boxes that appear when the mouse
hovers over a contextual layer. These boxes are called tips, and they can
be activated using the ‘Map Properties’ options in the Designer. The
property to edit is ‘List Of Layers Displaying Tips’. Add the ID(s) of the
contextual layer(s) for which you would like to activate tips. If you do not
know the ID(s) of your map layers, you can find them in the ‘map.swf.xml’
file, which is located in your report folder. When viewed in a text editor, this
file looks similar to Figure 19.
Figure 19
Copy and paste the ID(s) into the ‘Edit values...’ dialog in the Designer. If
you want to activate tips for more than one layer, add each layer as a new
row in the ‘Edit values...’ dialogue.
In the example shown in Figure 20, tips are activated for the town layer,
which has the ID ‘contextualLayer2’.
© GeoWise Ltd. 2013
Page 12
visualise | communicate | ENGAGE
Now save the config file and refresh your browser window. When you
g the InstantAtlas Area Profile Template User Guide
hover over the contextual map features, the tip will appear (Figure 21).
How to Style and Configure Map Layers in InstantAtlas Reports
Font tag (<font>)
Image tag (<img>)
Italic tag (<i>)
Figure 21
List item tag (<li>)
Paragraph tag (<p>)
Text format tag (<textformat>)
Underline tag (<u>)
Both ESRI Shapefiles and MapInfo Interchange Files (MID/MIF or Tab
files) only support text fields up to 254 characters. This limits the amount of
HTML code you can use for the tooltips of contextual layers.
The following code is an example of what can be done using a combination
of HTML tags and text.
Please note that line breaks and indentations
shown in the code were added to improve readability. Before using this
code for a feature of a digital map file, delete all of the line breaks and
Like the base layer, it is also possible to add HTML code into the tooltips of
indentations so that the code appears on one line.
contextual layers to add or format text, images and hyperlinks. Note that
the tip will always show the content of the field you chose as a ‘Feature
name field’ in the Publisher. Therefore you would need to add the HTML
code into an attribute field of the digital map file you intend to use as the
contextual layer.
This needs to be done outside InstantAtlas using a
suitable GIS package.
The following HTML tags are supported:
<font size="12">
<b>Pretoria</b>
</font>
<br><br>
<a href="http://en.wikipedia.org/wiki/Pretoria">
<img vspace="0" src="wiki.png"/>
<br>
<br>
Anchor tag (<a>)
Bold tag (<b>)
Break tag (<br>)
© GeoWise Ltd. 2013
<font color="#0000ff">
<u>Link to Wikipedia</u>
</font>
Page 13
visualise | communicate | ENGAGE
</a>
How to Style and Configure Map Layers in InstantAtlas Reports
Figure 23
g the InstantAtlas Area Profile Template User Guide
The above code will create a tooltip as shown in Figure 22. Tooltips of
contextual layers can be made “sticky” by clicking with the left mouse key
when the tooltip appears. This allows users to follow links shown in the tip.
Figure 22
4. Labelling of Map Layers
With InstantAtlas version 6.3.0 onwards, it is now possible to label
geography features in the map. For base layers, the label will be the name
of the geographies as they are in your data.xml file. When labelling
contextual layers, the label will be the values of the field that you chose as
‘Feature name field’ in the Publisher.
For example if you want to see the town names and local authority names
as labels in you map, you need to choose the ‘NAME’ field as the feature
name field in both contextual layers (Figure 23).
The zoom to filter function is dependent on the field chosen in the
‘Feature code field’. The filter names in your workbook or database must
match the ‘Feature code field’ of the contextual geography to make the
© GeoWise Ltd. 2013
Page 14
visualise | communicate | ENGAGE
map zoom to filters. For more information, please see the ‘Making your
How to Style and Configure Map Layers in InstantAtlas Reports
Figure 25
g the InstantAtlas Area Profile Template User Guide
map zoom to filters’ documentation, available from the Support section of
the InstantAtlas website.
By default no labels are activated in your report. Labels may be activated in
the ‘Map Properties’ in the Designer. The second property from the bottom
is the ‘List Of Layers Displaying Labels’. Here you need to add the ID(s) of
the map layers(s) for which you would like to activate labels. This can be
contextual or base geography layers. If you do not know the ID(s) of your
map layers you can find them in the ‘map.swf.xml’ file located in your report
folder. When opened in a text editor, this file looks something like
Figure 24.
Figure 24
Copy and paste the ID(s) into the ‘Edit values...’ dialog in the Designer. If
you want to activate labels for more than 1 layer, add a new row for each
layer ID in the ‘Edit values...’ dialog box. In the example shown in Figure 25
the base layer (ID ‘_Wards-nottinghamshire.shp1’), the local authority layer
(ID ‘contextualLayer1’) and the towns layer (ID ‘contextualLayer2’) will
display with labels.
© GeoWise Ltd. 2013
Page 15
visualise | communicate | ENGAGE
You can also define display ranges for the labels in the Map Properties of
How to Style and Configure Map Layers in InstantAtlas Reports
Figure 26
g the InstantAtlas Area Profile Template User Guide
the Designer. The property is called ‘List Of Display Ranges For labelled
Layers’. These need to be defined as the percentage of the starting map
width. For example, the value ‘50-0’ would cause labels to appear only
after zooming midway into the map. If you have more than one layer with
labels, the ranges need to be in the same order as the layer IDs in the ‘List
Of Layers Displaying Labels’ (Figure 26).
Now save the config file and refresh your browser window. You will now
see labels in the map.
Figure 27 shows three different zoom levels with different labels visible
depending on the ranges defined in Figure 26.
© GeoWise Ltd. 2013
Page 16
visualise | communicate | ENGAGE
Figure 27
g the InstantAtlas Area Profile Template User Guide
How to Style and Configure Map Layers in InstantAtlas Reports
The images in Figure 27 also show the limitations of the labelling
functionality. Since labels cannot be moved, they may sometimes overlap.
Further, labels are positioned in the centroid of the polygons, which may
not always be inside the polygon border (e.g. U-shaped polygons). For this
reason it is recommended to use labels only for those layers where the
labels will not overlap and – if you wish to label a polygon layer – where the
centroid lies within the shapes. It is not recommended to label line features
since it is not possible to align labels to the lines.
The labels can be styled through the style class .layerLabels in the Style
Editor, however you cannot have different styles for labels of different
layers.
5. InstantAtlas Support
You can find IA support resources at www.instantatlas.com/support.xhtml.
InstantAtlas customers can login to their My InstantAtlas account at
www.instantatlas.com/mia and download a wide range of support
resources and access a searchable knowledgebase. If these resources do
not provide a solution, please contact your support provider.
© GeoWise Ltd. 2013
Page 17