On 10/10/11 3:43 PM, Peter Klügl wrote:

Nope, the settings are only type-sensitive. The file looks like:

<styleMap>
<rule>
<pattern>de.uniwue.tm.citie.Author</pattern>
<label>de.uniwue.tm.citie.Author</label>
<style>color:red;background:yellow;checked:false;hidden:false;</style>
</rule>

Looks like you save the "hidden" flag in this styling file, do you serialize the styling file every time
a user changes the hidden setting for an annotation?

Well, this is just a "default" setting which Text Marker can create, right?

Yes, the predefined colors for some types.
The Cas Editor offers a util class you could use to come up with different default colors, this code is actually based on code we used over at one of our swing UIMA UI tools (forgot which one).

How do you decide which type system xml file to use in Text Marker when a CAS file is opened?


The CEV plugin has an extension point for search strategies with priorities like a dialog to select the type system. The most common strategy is to take the type system of the script that was launched last if it is in the same project as the CAS file. I'd really like to add this functionality to the CAS Editor for TextMarker projects when it replaces the CEV plugin.

You would need to implement your own CasDocumentProvider, there you can reuse your existing code to load a CAS, to find and load a type system, and to store preferences per type system preferences. There you could also place migration code, to initialize the new Cas Editor settings from
an existing map file.

Do you also have settings in Text Marker which need to be stored per session and per type system?

Jörn

Reply via email to