CONTENTS Connections
The Map Styles Editor allows you to customize your job design with connections, nodes, and sections that appear on your project map.
The editor is located within Job Settings, which can be accessed by clicking the gear icon next to your job's name.
Under the three-dot menu in the top right, you can click on the paint can icon ("Map Styles") button. This will open a window to edit the styles for your connections, nodes, and sections.
Connections
If we start with the "Connections" tab, you can see that on the left-hand side, you can move the style around with the arrow grab handles to change the order. Order is very important within the editor, as it determines the priority for how styles will be displayed on your map. If multiple map style conditions resolve to true for a connection, then whichever map style rule is highest on the list will display on the Map. See more on order/priority later in this guide.
Using the gear next to the arrows, you can change the settings of your map style rules.
Within this window, you can change the line thickness, set a solid or dashed line (or a custom line style, which you can learn more about in our Model Editor Manual), and select an icon to exist along the line if you would like.
The line icon will be an icon that is fixed on the connection itself. Using the “More...” button, you can look for different symbols to use. You can use the Icon Scale text line to change the size of the icon along the line and also have the icon be a different color if needed. Clicking the “X” at the top will close out the line settings window.
Returning back to the main Map Styles Editor, the Color square can be used to set custom colors for your connections, nodes, or sections.
You can use the color picker that opens when you click the Color square to choose a color, use the tools to adjust hue (0 to 359), saturation, and lightness, or you can manually enter the RGBA or hexadecimal values to get a known color.
To the right of these settings, you can define what the line will represent on the map.
The first dropdown is the attribute. Use this dropdown to set the attribute that will be used for the style. The next dropdown is the comparator. You can choose between equals, does not equal, has, or does not have. In the above example, the green line represents an aerial connection.
If you choose equals or does not equal, you can define what that should be based on how the attribute is set up in the Model Editor. If it is a picklist, you will see the options of the picklist, and if it is a checkbox, you will see the check box, and if it is a text area or text box, you will see the line for the text.
You can use the three dot menu to the far right to delete, duplicate, or add a new style below.
Clicking the “Add a New Style” button at the top will place a new style at the top of the list. Again, you can use the arrows to move the style, the gear icon to edit the line settings, and the Color square to change the color. You will also need to define what you want the style to represent.
Example
If you needed to make a new style for an Underground Cable, you would first want to make sure that "underground cable" is an existing picklist value under the attribute "Connection Type." You can do this using the Model Editor.
*See our Model Editor Manual for help adding or editing attributes
Once you have your attributes and picklist values properly configured and saved in the Model Editor, you can click the “Add New Style” button.
Use the line settings to adjust the thickness and style. For the attribute, choose "connection_type." For comparator, we want the connection type to be an underground cable, so select "equals" for the second dropdown, and find "underground cable" in the picklist that appears.
Once the style is created, press "Done." If you want to use the style as a template for more jobs, go to the top right of the window to select the three dot menu to save the style as a template.
You can save the template as a new template or an existing template to overwrite it. Check the default box if you want the template to be the default style for all new jobs you create. Once the template is selected or named, click “Save.”
*Changing an existing template or making a new style template the default will not update past jobs. Only new jobs created will use the template if it is selected for default. You will need to load the new default styles in existing jobs.
Nodes and Sections
For Nodes and Sections, there are a few more options. Additionally, order generally plays a more important role.
You can click on the icon to see various options for map symbology. Clicking “More” will give you a bigger list to choose from. To choose an icon, click on the one you want to use.
*You can also upload custom SVG icons in the Model Editor.
Clicking the double “T” button will allow you to change the icon size. The bigger the number, the larger the icon will appear on the Map.
The stackable icon, when clicked, means that the style can be stacked with another style if both styles are true and are marked as 'stackable.' (See our example further into this manual for how that looks.)
Again, you will need to select an attribute and comparator to finish setting up the style rule, and you can use the arrows to move the style within the list.
Order
Order matters when multiple attributes exist for a node on the Map—particularly if each attribute has a style rule.
In the above example, if a pole is placed on the map with no attributes other than "node_type" being set to "pole," it will appear as a black circle. If you would add the "done" attribute to the pole and leave it unchecked, it will turn into a red circle. Then if the pole is collected in the field, it would update to be a blue hexagon. Finally, if you check the "done" attribute checkbox, it would turn to a green circle. Even though the location still has the "node type" and "field completed" attributes, the "done = true" map style is highest in this list, so that is the style that is displayed on the map.
If you want to save it as a template, go to the three dot menu at the top right to save the template. When everything is set in the Map Styles Editor, click "Done."
Custom Logic
Familiarize yourself with the Logic Editor by reading our manual. To understand how this works in the Map Styles Editor, let's explore an example together. Let's say you're mapping addresses, and you want to mark which ones have been verified and which ones have not. Let's say you also want to distinguish each address by its type, such as "residential" or "commercial."
First, make sure you use the Model Editor to set up the attributes needed in this scenario. For this example, I searched for "Node Type" in the Attributes under the Model Editor, added a picklist called "Address," and added a value for "Address."
I then found "Node Sub Type" in the Attributes and added "Residential" and "Commercial" values under the "Address" picklist I created. (With a node type "Address" and these subtypes, we can have a 'default' style for an address if its type is not specified.)
First we set the scene by creating rules for an address with no sub type (a default address), a residential address, and a commercial address. I changed the icon, the colors, increased the size to 30, and defined what the style is for.
Here's how the styles look on the map.
Now for the tricky part! We're going to add a "halo" to houses that have been verified, regardless of what type of house they are.
First I opened the Map Styles Editor and clicked "Add a New Style." I changed the icon to a completely filled in circle, changed the color and its opacity (by changing the "A" value from 100% to 35%), and increased its size to 60. I moved the style below the houses so that it'll show up 'behind' the houses when the styles get stacked and made it stackable (as well as making all the houses stackable).
Now we get to use the Logic Editor! I want this style to apply when the node type is address and the address has been verified.
First, we'll click on this little "summation" symbol to open the Logic Editor.
If you read the manual, this structure will look familiar to you. First of all, we're starting with a "Logical And" expression, because we're saying we want the style to apply when the node type is address AND the address has been verified. (In this example, I assume when the field completed attribute is true, which is when a fielder marks a node as done, that the address has been verified.)
Then we have those two expressions nested underneath that root "Logical And" block. So for the first part of our condition, "...when the node type is address," the "is" in that statement indicates we need to use the "Equal" expression. Then we'll want to access the node type of the node, so this'll require us to use the data path. Data paths can difficult, but it works well if you think of it like a filing system. In this case, we're accessing a node's attribute, node_type. So the data path we get is 'node.attributes.node_type.*'. (The '*' wild card is saying that whatever info is at this level, the node_type level, grab it. Since we don't know what the node_type is for that node, we use the '*'.)
The last part of our condition, "...the address has been verified," indicates another "Equal" expression. We want to access the node's attribute, field_completed, so the data path will be 'node.attributes.field_completed.*'. (Again, we use the wildcard '*" because we don't know whether the field_completed value is TRUE or FALSE.) Since field_completed is a checkbox, this means the value is Boolean, meaning the value is TRUE or FALSE. In this case, we want the value to be TRUE. So we choose a literal block and select "Boolean" as the type and click "TRUE" for the value. Now that our logic statement is built out, we can click on the summation symbol to close that window and click "Done" in our Map Styles Editor.
And here's how the map looks with all of our styles applied! You can see that there are commercial addresses (yellow houses), residential addresses (blue houses), and "default" addresses (gray houses). The houses with green halos are ones that have been verified (regardless of the type of address, as there are default addresses, residential, and commercial addresses that have the green halo).
Additional Notes
If you return to older jobs that were created before a style or template was created, you can go into the Map Style Editor window, and in the three dot menu at the top right select “Load Style Template” to load the newly created template for that job.
You can edit and create custom logic for map styles to add even more specific details to the map.
Pink lines for connections and pink circles for nodes are used for default styles. If you see these on the map where you did not intend for them, it just means a style is not yet created for that connection or node. You can go into the Map Styles Editor to create the style, and once saved, the line or node will update to represent your desired look.
Thanks for reading! Contact us at support@katapultengineering.com with any questions. How can we improve our documentation? Let us know in the comments below!