Scribe Development Blog

The lastest news about Scribe and ScribeUI

Release 1.8

Summary of the update

Hello everyone! I am releasing today a third update for ScribeUI, for the 2015 edition of Google Summer of Code. This is the final feature update for the summer, which adds a new classifying feature.

Classify

Classify is a new plugin that adds a button to automatically create classes from a set of data. To use it, start by opening a map. On the left side of the screen, you will find a Classify button:

Classify

Clicking on it will make a new popup appear:

Classify Menu

  • Group/Layer specifies in which group the classes should be added

  • Data source gives you a list of the data sources in the selected layer. Choose the one you want to use to make classes.

  • Field is the field to classify. The fields available are those found in the selected data source.

  • Class type is a choice between Qualitative, where all individual values have their own class, and Quantitative, where ranges of values have a class.

  • Colors defines the colors to use for the classes, if any. When clicking on Choose, this menu will appear:

Color menu

To add a single color, choose one by clicking on the black square (if you use Chrome or Firefox), or enter its hexadecimal value. Click on the Add button located on the right to add it to the selected colors.

To add a range of colors, choose the starting and last colors, as well as how many colors to generate, then click on Add.

To remove a selected color, press on it in the Selected colors area and click on Remove. To move it, click on Move left or Move right and to remove all the selected colors, click on Clear. When you’re done, press on Confirm in the bottom right of the popup.

When you’re done choosing colors, you will go back to the classify menu. To generate the classes, press on Confirm on the bottom right.

Here is an example of the kind of classes you can generate using this feature:

Map

Updating

You can update ScribeUI to v1.8 by using these commands:

sudo chown -R youruser .
git pull
git checkout v1.8
sudo make perms

You will also need to install GDAL and create a path to it:

sudo apt-get install gdal-bin python-gdal
export CPLUS_INCLUDE_PATH=/usr/include/gdal
export C_INCLUDE_PATH=/usr/include/gdal

Changelog

Second Update for GSoC2015

Summary of the update

I am releasing today version 1.6, the second update for Google Summer of Code 2015. The main objective of this update was to add map import and export.

Map export

To export a map, select a map in the manager tab and press on the Export Map button. This popup will open:

Example

Pressing on Export will generate a .zip file containing the map files. You can use it as a way to backup your maps or to share them with other users.

Map import

To import a map, go in the manager tab and press the Import Map button. This popup will open:

Example

You can choose a name for the map to be imported, select a .zip file and press import. While the file is uploading, the logs won’t update and the status will stay on “In progress”. It can take a long time if the map is large or if your connection is slow. Once the process is complete, you will see the map in the manager view.

Changelog

  • Fix #33 - Add map import
  • Fix #51 - Add a WMS Url for each map
  • Fix #67 - Add map export
  • Fix #107 - Fix some comment blocks not working in the Scribe syntax
  • Fix #128 - Fix standard maps not being saved when there are accents in it
  • Fix #129 - Fix includes not being removed when deleting a group on standard maps
  • Fix #130 - Fix name tags having numbers appended to them in the Scribe syntax
  • Fix #131 - Fix VOID keyword appearing with some comments with the Scribe syntax
  • Fix #132 - Fix log files becoming very large
  • Fix #134 - Fix french characters creating internal server errors
  • Fix #135 - Fix import and export fields not emptying after the popup is closed
  • Changed the map debug to use mapserv instead of shp2img

Updating

You will need to add a link to your server’s cgi-bin location in the local.ini file, in the [app:main] section. It will probably be very similar to the mapserver.url parameter, so you could place it next to it. The format is

cgi.url = http://myserver.com/mypath/mycgi

For example, this is what I had to add to the demo’s local.ini file:

cgi.url = http://demo.scribeui.org/cgi-bin

You can update ScribeUI to v1.6 by using these commands:

sudo chown -R youruser .
git pull
git checkout v1.6
sudo make perms

Plan for the rest of the summer

The last month of this summer will be spent on the data classifying feature. The goal is to provide a way to create a range of classes with different colors from a set of data. You can find more information about the summer’s plan here.

ScribeUI v1.4

Summary of the update

I am releasing today the first update for ScribeUI for Google Summer of Code 2015. I had three main objectives planned for this summer, which you can see in this previous blog post. This update contains the first part of the project, improved error detection. You can try it here!

To give you an example, here’s what happens when I try to use a comma instead of a dot for a decimal value:

Example

When the map renders pink error tiles, an error message appears over it with a link to open the logs if they’re not already open. In the logs, there are two links: one to the location of the error in the result mapfile, and one to the location of the error in the editor. These links are available only when the error returned by mapserver contains the line number.

Sometimes the error can’t be located in the editor, often because of the differences between the Scribe syntax and the regular mapfile syntax. When that happens, you should still be able to find it in the result tab.

The Debug tab now contains the output of shp2img with debug level 5 using the generated mapfile as the input. The logs generated by shp2img are very useful for debugging. The Result tab was also upgraded to a read-only CodeMirror editor, allowing syntax highlighting, error widgets and line numbering.

Changelog

  • Fix #65 - Update the Readme for the latest version of Apache
  • Fix #87 - Make the map’s viewport change when resizing the logs tab
  • Fix #92 - Add an error message when something goes wrong while creating a map
  • Fix #94 - Fix the issue where the log tab disapears when resizing the window
  • Fix #112 - Add an option for the cgi-bin url in the local.ini file
  • Fix #113 - Fix the issue with Scribe.py where links would be interpreted as comments
  • Fix #114 - Remove the extra options in the map type when creating a new map
  • Fix #117 - Make the debug logs always available
  • Fix #118 - Fix the issue where a map’s name stays visible after deleting it
  • Fix #119 - Don’t let the user create two maps with the same name
  • Fix #120 - Escape characters in the description to prevent cross-site scripting
  • Fix #121 - Add a maximum height to the log window
  • Fix #122 - Refresh the log window when resized
  • Updated CodeMirror to version 5.3
  • Add error widgets in the result tab
  • Add error widgets in the editor
  • Add a notification when the map fails to renders

Updating

As with the previous release, you can update ScribeUI by using these commands:

sudo chown -R youruser .
git pull
git checkout v1.4
sudo make perms

You will also need mapserver-bin to use the new debugging feature. If you’re updating, use this command:

sudo apt-get install mapserver-bin

Plan for the next weeks

The second feature planned is exporting and importing maps and workspaces. This would allow users to share their maps more easily, and it would make it possible to add backups.

Getting Started With ScribeUI

There is now a Getting Started guide to Scribe UI! It is located on the project’s wiki. You can also try ScribeUI without installing it by going on the demo page. It is reset every day to keep it from getting too messy.

ScribeUI on GSoC 2015

ScribeUI is back as a Google Summer of Code project with OSGeo.

We decided to put the old developement blog back up, and use it to post news on what’s going on with the project. I will post a getting started guide this week to help new users use ScribeUI. This summer’s plan involves fixing bugs and adding a few features:

Improve the error detection of ScribeUI

Right now, the only way we have to know something is wrong with a Scribe map file is when it is converted to the Mapserver Mapfile format and Mapserver can’t read it. ScribeUI displays Mapserver’s error output in the logs, allowing the user to have an idea of the problem. However, the line numbers displayed in the logs do not fit with the Scribe files since it is a different format. The goal is to have an error output that displays the correct location of errors in the code.

Import and export workspaces

I want to add the possibility to export workspaces into a single zipped file, and allow other users to import it on their installation of ScribeUI. This would make sharing maps easier.

Classify the data

One of the commonly requested features to automatically add classes based on a set of data and scales. For example, most demographics can be displayed with a map colored with a scale based from brighter to darker colors. Adding a way to automatically create these classes would be very useful to ScribeUI users.

My objective is to complete all these features by the end of the summer and release a new stable version of ScribeUI.

Mockups

First Page

When the app is first opened, the app asks for a workspace to work on. The workspaces allow ScribeUI to be cloud-based, with each user or project having its own workspace.

Manager

The manager lists the maps withing the project. The icons will be snapshots of the map. The toolbar at the bottom of the map is accessible from anywhere. The quickview is very useful, as it allows the user to save and quickly get back to certain map extents.

Editor

This is the most important part of the app. The toolbar on top of the text box contains most tools for the mapfile edition.

  • Layer Groups: Choose the currently edited layer group from the drop-down. Group order and deletion managed in a pop-up appearing when the user clicks on the icon next to the drop-down.

  • Variables: Opens a panel on top of the regular editor. It contains the map’s variables, if the project is in Scribe.

  • Settings: This drop-down contains editable sections of the map project.

  • Debug: The flag icon opens a list of debugs links. Mapfile Result is the outputted mapfile, Scribe logs contains log messages from Scribe and Mapserver Debug contains the debug output from mapserver.

  • Editor Settings: The gear icon will allow the user to edit the editor’s configuration.

  • Swatch Toolbar: The swatches at the bottom of the editor allow the user to edit the project’s colors with a color picker.

Editable Panel

When a user clicks on one of the settings option, or on the variable button, a panel opens that allows the edition of that particular setting.

A big thanks to the people from Balsamiq who gave a licence for their mockups software to this GSoC project !

Start of the Project

ScribeUI was accepted as a Google Summer of Code 2013 entry with OSGeo!

The beginning of the project so far has been all about preparation. What new functionnalities do we want ? What current functionnality needs to get better ? What is good about the current application, and what needs to be redone ? What are the bugs, and how important are they ?

So before a first version can be released, a few things need to be done. First, GUI Mockups. The main weakness of the application right now is the GUI, and the mockups really help bringing new ideas before doing any coding. The mockups will be up shortly on this blog.

Next, there need to be some rethinking of the code to have it work with modules. That way, implementing new features will be much easier.

Also, two bugs need to be corrected before releasing the project. Both bugs cause loss of work made by the user, that is why they need to be fixed as soon as possible.

And finally, actually implemeting the new GUI as directed by the mockups.

Once all of this is done, the app can be used and tested by anyone interested. Some functionnalities will be missing, but the core will be there.