irstv/orbisgis — pull request #88 by agueganno (2012-08-02 11:34:41+00:00)
Title: Feature : point wkn selection

from the user point of view, this pull request just adds a combo box that let's him choose between the well-nown names used to cofnigure the shape of MarkGraphic instances. That's a real step forward, as it finally make useful the editor for punctual unique symbols...

From the code point of view, I've finally implemented restrictions on StringParameters. That improves the controls made on some parameters, for instance on well-nown names (yes, that was on purpose ;-) ), but also on label fonts, etc... It's quite agressive : if the value you want to set does not match restrictions, an exception is thrown. If the current value does not match newly set exceptions, an exception is thrown and the first value of the array of restrictions is set as the value. That's pure defensive coding, here...

As I don't want to pollute the code with throws clause everywhere, InvalidString (that's the name of the exception) is an unchecked exception. I think this is coherent with the fact that it is directly linked with user inputs made during software execution.

With this commit come some improvement of the type definitions made in legend, too.