Mercurial > dive4elements > river
changeset 2737:83b22ccf48da
Introduced theme groups and added new service to get themes filtered by name.
flys-artifacts/trunk@4470 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author | Raimund Renkert <raimund.renkert@intevation.de> |
---|---|
date | Wed, 23 May 2012 08:46:45 +0000 |
parents | 8839086c4b7b |
children | 7337655d3ed8 |
files | flys-artifacts/ChangeLog flys-artifacts/doc/conf/conf.xml flys-artifacts/doc/conf/themes.xml flys-artifacts/src/main/java/de/intevation/flys/artifacts/context/FLYSContextFactory.java flys-artifacts/src/main/java/de/intevation/flys/artifacts/services/ThemeListingService.java flys-artifacts/src/main/java/de/intevation/flys/collections/FLYSArtifactCollection.java flys-artifacts/src/main/java/de/intevation/flys/themes/ThemeFactory.java flys-artifacts/src/main/java/de/intevation/flys/themes/ThemeGroup.java |
diffstat | 8 files changed, 2000 insertions(+), 1021 deletions(-) [+] |
line wrap: on
line diff
--- a/flys-artifacts/ChangeLog Wed May 23 08:12:49 2012 +0000 +++ b/flys-artifacts/ChangeLog Wed May 23 08:46:45 2012 +0000 @@ -1,3 +1,29 @@ +2012-05-23 Raimund Renkert <raimund.renkert@intevation.de> + + * src/main/java/de/intevation/flys/themes/ThemeGroup.java: + New. A theme group takes a set of themes configured in the themes.xml. + + * src/main/java/de/intevation/flys/themes/ThemeFactory.java: + Read the theme groups configured in the themes.xml. + Improved reading the xml file. Thanks to Sascha for the patch. + + * src/main/java/de/intevation/flys/collections/FLYSArtifactCollection.java: + Get a theme using the new parameter themegroup. + + * src/main/java/de/intevation/flys/artifacts/context/FLYSContextFactory.java: + Create theme groups while configuring themes. + + * src/main/java/de/intevation/flys/artifacts/services/ThemeListingService.java: + New. This service returns a list with all configured theme groups, each + containing exactly one theme filtered by name. + The theme name has to be provided as parameter. + + * doc/conf/conf.xml: + Added new service to config. + + * doc/conf/themes.xml: + Introduced theme groups and added new group. + 2012-05-23 Felix Wolfsteller <felix.wolfsteller@intevation.de> * doc/conf/meta-data.xml: Repair CS-DC-Conf, allow loading
--- a/flys-artifacts/doc/conf/conf.xml Wed May 23 08:12:49 2012 +0000 +++ b/flys-artifacts/doc/conf/conf.xml Wed May 23 08:46:45 2012 +0000 @@ -159,6 +159,10 @@ name="fileupload" service="de.intevation.flys.artifacts.services.FileUploadService" description="Takes base64 coded files embedded in XML.">de.intevation.artifactdatabase.DefaultServiceFactory</service-factory> + <service-factory + name="themelisting" + service="de.intevation.flys.artifacts.services.ThemeListingService" + description="Returns a list of Themes filtered by theme name.">de.intevation.artifactdatabase.DefaultServiceFactory</service-factory> </service-factories> </factories>
--- a/flys-artifacts/doc/conf/themes.xml Wed May 23 08:12:49 2012 +0000 +++ b/flys-artifacts/doc/conf/themes.xml Wed May 23 08:46:45 2012 +0000 @@ -1,1027 +1,1792 @@ <themes> <!-- Concrete themes are following now! --> - <theme name="DischargeCurve"> - <inherits> - <inherit from="HiddenColorLines"/> - <inherit from="MinMaxPoints"/> - </inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="0, 0, 153"/> - <field name="linesize" type="int" display="Liniendicke" default="2" hints="h"/> - </fields> - </theme> - - - <!-- concrete theme for historical discharge curves --> - <theme name="HistoricalDischargeCurveQ"> - <inherits> - <inherit from="HiddenColorLines"/> - <inherit from="MinMaxPoints"/> - </inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="0, 0, 153"/> - <field name="linesize" type="int" display="Liniendicke" default="2" hints="h"/> - </fields> - </theme> - - <theme name="HistoricalDischargeCurveQDiff"> - <inherits> - <inherit from="HiddenColorLines"/> - <inherit from="MinMaxPoints"/> - </inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="204, 204, 204"/> - <field name="linesize" type="int" display="Liniendicke" default="2" hints="h"/> - </fields> - </theme> + <themegroup name="default"> + <theme name="DischargeCurve"> + <inherits> + <inherit from="HiddenColorLines"/> + <inherit from="MinMaxPoints"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0, 0, 153"/> + <field name="linesize" type="int" display="Liniendicke" default="2" hints="h"/> + </fields> + </theme> - <!-- - Discharge Longitudinal Section - --> - <theme name="LongitudinalSectionW"> - <inherits> - <inherit from="HiddenColorLines"/> - <inherit from="MinMaxPoints"/> - </inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="204, 204, 204"/> - </fields> - </theme> - - <theme name="LongitudinalSectionW_HQ1"> - <inherits> - <inherit from="LongitudinalSectionW"/> - </inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="0, 0, 102"/> - </fields> - </theme> - - <theme name="LongitudinalSectionW_HQ2"> - <inherits> - <inherit from="LongitudinalSectionW"/> - </inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="0, 0, 102"/> - </fields> - </theme> - - <theme name="LongitudinalSectionW_HQ5"> - <inherits> - <inherit from="LongitudinalSectionW"/> - </inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="0, 153, 51"/> - </fields> - </theme> - - <theme name="LongitudinalSectionW_HQ10"> - <inherits> - <inherit from="LongitudinalSectionW"/> - </inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="0, 204, 204"/> - </fields> - </theme> - - <theme name="LongitudinalSectionW_HQ20"> - <inherits> - <inherit from="LongitudinalSectionW"/> - </inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="153, 153, 0"/> - </fields> - </theme> - - <theme name="LongitudinalSectionW_HQ25"> - <inherits> - <inherit from="LongitudinalSectionW"/> - </inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="102, 51, 0"/> - </fields> - </theme> - - <theme name="LongitudinalSectionW_HQ50"> - <inherits> - <inherit from="LongitudinalSectionW"/> - </inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="255, 153, 153"/> - </fields> - </theme> - - <theme name="LongitudinalSectionW_HQ100"> - <inherits> - <inherit from="LongitudinalSectionW"/> - </inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="255, 0, 51"/> - </fields> - </theme> + <!-- concrete theme for historical discharge curves --> + <theme name="HistoricalDischargeCurveQ"> + <inherits> + <inherit from="HiddenColorLines"/> + <inherit from="MinMaxPoints"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0, 0, 153"/> + <field name="linesize" type="int" display="Liniendicke" default="2" hints="h"/> + </fields> + </theme> - <theme name="LongitudinalSectionW_HQ200"> - <inherits> - <inherit from="LongitudinalSectionW"/> - </inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="255, 0, 255"/> - </fields> - </theme> - - <theme name="LongitudinalSectionW_HQ500"> - <inherits> - <inherit from="LongitudinalSectionW"/> - </inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="102, 0, 102"/> - </fields> - </theme> - - <theme name="LongitudinalSectionW_HQ1000"> - <inherits> - <inherit from="LongitudinalSectionW"/> - </inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="0, 0, 0"/> - </fields> - </theme> - - <theme name="LongitudinalSectionW_HQRZ"> - <inherits> - <inherit from="LongitudinalSectionW"/> - </inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="102, 0, 102"/> - </fields> - </theme> - - <theme name="LongitudinalSectionW_HSQ"> - <inherits> - <inherit from="LongitudinalSectionW"/> - </inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="253, 153, 0"/> - </fields> - </theme> + <theme name="HistoricalDischargeCurveQDiff"> + <inherits> + <inherit from="HiddenColorLines"/> + <inherit from="MinMaxPoints"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="204, 204, 204"/> + <field name="linesize" type="int" display="Liniendicke" default="2" hints="h"/> + </fields> + </theme> - <theme name="LongitudinalSectionW_MHQ"> - <inherits> - <inherit from="LongitudinalSectionW"/> - </inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="102, 255, 102"/> - </fields> - </theme> - - <theme name="LongitudinalSectionW_MNQ"> - <inherits> - <inherit from="LongitudinalSectionW"/> - </inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="0, 255, 255"/> - </fields> - </theme> - <theme name="LongitudinalSectionW_MQ"> - <inherits> - <inherit from="LongitudinalSectionW"/> - </inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="0, 51, 204"/> - </fields> - </theme> + <!-- + Discharge Longitudinal Section + --> + <theme name="LongitudinalSectionW"> + <inherits> + <inherit from="HiddenColorLines"/> + <inherit from="MinMaxPoints"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="204, 204, 204"/> + </fields> + </theme> - <theme name="LongitudinalSectionW_NQ"> - <inherits> - <inherit from="LongitudinalSectionW"/> - </inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="153, 204, 255"/> - </fields> - </theme> + <theme name="LongitudinalSectionW_HQ1"> + <inherits> + <inherit from="LongitudinalSectionW"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0, 0, 102"/> + </fields> + </theme> - <theme name="LongitudinalSectionW_HQExtrem"> - <inherits> - <inherit from="LongitudinalSectionW"/> - </inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="0, 0, 0"/> - </fields> - </theme> + <theme name="LongitudinalSectionW_HQ2"> + <inherits> + <inherit from="LongitudinalSectionW"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0, 0, 102"/> + </fields> + </theme> - <theme name="LongitudinalSectionPoints"> - <inherits> - <inherit from="LongitudinalSectionW"/> - </inherits> - <fields> + <theme name="LongitudinalSectionW_HQ5"> + <inherits> + <inherit from="LongitudinalSectionW"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0, 153, 51"/> + </fields> + </theme> + + <theme name="LongitudinalSectionW_HQ10"> + <inherits> + <inherit from="LongitudinalSectionW"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0, 204, 204"/> + </fields> + </theme> + + <theme name="LongitudinalSectionW_HQ20"> + <inherits> + <inherit from="LongitudinalSectionW"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="153, 153, 0"/> + </fields> + </theme> + + <theme name="LongitudinalSectionW_HQ25"> + <inherits> + <inherit from="LongitudinalSectionW"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="102, 51, 0"/> + </fields> + </theme> + + <theme name="LongitudinalSectionW_HQ50"> + <inherits> + <inherit from="LongitudinalSectionW"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="255, 153, 0"/> + </fields> + </theme> + + <theme name="LongitudinalSectionW_HQ100"> + <inherits> + <inherit from="LongitudinalSectionW"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="255, 0, 255"/> + </fields> + </theme> + + <theme name="LongitudinalSectionW_HQ200"> + <inherits> + <inherit from="LongitudinalSectionW"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="255, 0, 255"/> + </fields> + </theme> + + <theme name="LongitudinalSectionW_HQ500"> + <inherits> + <inherit from="LongitudinalSectionW"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="102, 0, 102"/> + </fields> + </theme> + + <theme name="LongitudinalSectionW_HQ1000"> + <inherits> + <inherit from="LongitudinalSectionW"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0, 0, 0"/> + </fields> + </theme> + + <theme name="LongitudinalSectionW_HQRZ"> + <inherits> + <inherit from="LongitudinalSectionW"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="102, 0, 102"/> + </fields> + </theme> + + <theme name="LongitudinalSectionW_HSQ"> + <inherits> + <inherit from="LongitudinalSectionW"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="253, 153, 0"/> + </fields> + </theme> + + <theme name="LongitudinalSectionW_MHQ"> + <inherits> + <inherit from="LongitudinalSectionW"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="102, 255, 102"/> + </fields> + </theme> + + <theme name="LongitudinalSectionW_MNQ"> + <inherits> + <inherit from="LongitudinalSectionW"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0, 255, 255"/> + </fields> + </theme> + + <theme name="LongitudinalSectionW_MQ"> + <inherits> + <inherit from="LongitudinalSectionW"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0, 51, 204"/> + </fields> + </theme> + + <theme name="LongitudinalSectionW_NQ"> + <inherits> + <inherit from="LongitudinalSectionW"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="153, 204, 255"/> + </fields> + </theme> + + <theme name="LongitudinalSectionW_HQExtrem"> + <inherits> + <inherit from="LongitudinalSectionW"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0, 0, 0"/> + </fields> + </theme> + + <theme name="LongitudinalSectionPoints"> + <inherits> + <inherit from="LongitudinalSectionW"/> + </inherits> + <fields> + <field name="showlines" type="boolean" display="Linie anzeigen" default="false"/> + <field name="showpoints" type="boolean" display="Punkte anzeigen" default="true"/> + </fields> + </theme> + + <theme name="LongitudinalSectionW_HQ1_Points"> + <inherits><inherit from="LongitudinalSectionPoints"/></inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0, 0, 102"/> + </fields> + </theme> + + <theme name="LongitudinalSectionW_HQ2_Points"> + <inherits><inherit from="LongitudinalSectionPoints"/></inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0, 0, 102"/> + </fields> + </theme> + + <theme name="LongitudinalSectionW_HQ5_Points"> + <inherits><inherit from="LongitudinalSectionPoints"/></inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0, 153, 51"/> + </fields> + </theme> + + <theme name="LongitudinalSectionW_HQ10_Points"> + <inherits><inherit from="LongitudinalSectionPoints"/></inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0, 204, 204"/> + </fields> + </theme> + + <theme name="LongitudinalSectionW_HQ20_Points"> + <inherits><inherit from="LongitudinalSectionPoints"/></inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="153, 153, 0"/> + </fields> + </theme> + + <theme name="LongitudinalSectionW_HQ25_Points"> + <inherits><inherit from="LongitudinalSectionPoints"/></inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="102, 51, 0"/> + </fields> + </theme> + + <theme name="LongitudinalSectionW_HQ50_Points"> + <inherits><inherit from="LongitudinalSectionPoints"/></inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="255, 153, 153"/> + </fields> + </theme> + + <theme name="LongitudinalSectionW_HQ100_Points"> + <inherits><inherit from="LongitudinalSectionPoints"/></inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="255, 0, 51"/> + </fields> + </theme> + + <theme name="LongitudinalSectionW_HQ200_Points"> + <inherits><inherit from="LongitudinalSectionPoints"/></inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="255, 0, 255"/> + </fields> + </theme> + + <theme name="LongitudinalSectionW_HQ500_Points"> + <inherits><inherit from="LongitudinalSectionPoints"/></inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="102, 0, 102"/> + </fields> + </theme> + + <theme name="LongitudinalSectionW_HQ1000_Points"> + <inherits><inherit from="LongitudinalSectionPoints"/></inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0, 0, 0"/> + </fields> + </theme> + + <theme name="LongitudinalSectionW_HQRZ_Points"> + <inherits><inherit from="LongitudinalSectionPoints"/></inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="102, 0, 102"/> + </fields> + </theme> + + <theme name="LongitudinalSectionW_HSQ_Points"> + <inherits><inherit from="LongitudinalSectionPoints"/></inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="253, 153, 0"/> + </fields> + </theme> + + <theme name="LongitudinalSectionW_MHQ_Points"> + <inherits><inherit from="LongitudinalSectionPoints"/></inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="102, 255, 102"/> + </fields> + </theme> + + <theme name="LongitudinalSectionW_MNQ_Points"> + <inherits><inherit from="LongitudinalSectionPoints"/></inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0, 255, 255"/> + </fields> + </theme> + + <theme name="LongitudinalSectionW_MQ_Points"> + <inherits><inherit from="LongitudinalSectionPoints"/></inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0, 51, 204"/> + </fields> + </theme> + + <theme name="LongitudinalSectionW_NQ_Points"> + <inherits><inherit from="LongitudinalSectionPoints"/></inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="153, 204, 255"/> + </fields> + </theme> + + <theme name="LongitudinalSectionW_HQExtrem_Points"> + <inherits><inherit from="LongitudinalSectionPoints"/></inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0, 0, 0"/> + </fields> + </theme> + + <!-- + Longitudinal Section Q's + --> + + <theme name="LongitudinalSectionQ"> + <inherits> + <inherit from="HiddenColorLines"/> + <inherit from="MinMaxPoints"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="204, 204, 204"/> + </fields> + </theme> + + <theme name="LongitudinalSectionQ_HQ1"> + <inherits> + <inherit from="LongitudinalSectionQ"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0, 0, 102"/> + </fields> + </theme> + + <theme name="LongitudinalSectionQ_HQ2"> + <inherits> + <inherit from="LongitudinalSectionQ"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0, 0, 102"/> + </fields> + </theme> + + <theme name="LongitudinalSectionQ_HQ5"> + <inherits> + <inherit from="LongitudinalSectionQ"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0, 153, 51"/> + </fields> + </theme> + + <theme name="LongitudinalSectionQ_HQ10"> + <inherits> + <inherit from="LongitudinalSectionQ"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0, 204, 204"/> + </fields> + </theme> + + <theme name="LongitudinalSectionQ_HQ20"> + <inherits> + <inherit from="LongitudinalSectionQ"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="153, 153, 0"/> + </fields> + </theme> + + <theme name="LongitudinalSectionQ_HQ25"> + <inherits> + <inherit from="LongitudinalSectionQ"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="102, 51, 0"/> + </fields> + </theme> + + <theme name="LongitudinalSectionQ_HQ50"> + <inherits> + <inherit from="LongitudinalSectionQ"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="255, 153, 153"/> + </fields> + </theme> + + <theme name="LongitudinalSectionQ_HQ100"> + <inherits> + <inherit from="LongitudinalSectionQ"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="255, 0, 51"/> + </fields> + </theme> + + <theme name="LongitudinalSectionQ_HQ200"> + <inherits> + <inherit from="LongitudinalSectionQ"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="255, 0, 255"/> + </fields> + </theme> + + <theme name="LongitudinalSectionQ_HQ500"> + <inherits> + <inherit from="LongitudinalSectionQ"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="102, 0, 102"/> + </fields> + </theme> + + <theme name="LongitudinalSectionQ_HQ1000"> + <inherits> + <inherit from="LongitudinalSectionQ"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0, 0, 0"/> + </fields> + </theme> + + <theme name="LongitudinalSectionQ_HQRZ"> + <inherits> + <inherit from="LongitudinalSectionQ"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="102, 0, 102"/> + </fields> + </theme> + + <theme name="LongitudinalSectionQ_HSQ"> + <inherits> + <inherit from="LongitudinalSectionQ"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="253, 153, 0"/> + </fields> + </theme> + + <theme name="LongitudinalSectionQ_MHQ"> + <inherits> + <inherit from="LongitudinalSectionQ"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="102, 255, 102"/> + </fields> + </theme> + + <theme name="LongitudinalSectionQ_MNQ"> + <inherits> + <inherit from="LongitudinalSectionQ"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0, 255, 255"/> + </fields> + </theme> + + <theme name="LongitudinalSectionQ_MQ"> + <inherits> + <inherit from="LongitudinalSectionQ"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0, 51, 204"/> + </fields> + </theme> + + <theme name="LongitudinalSectionQ_NQ"> + <inherits> + <inherit from="LongitudinalSectionQ"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="153, 204, 255"/> + </fields> + </theme> + + <theme name="LongitudinalSectionQ_HQExtrem"> + <inherits> + <inherit from="LongitudinalSectionQ"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0, 0, 0"/> + </fields> + </theme> + + + <!-- + Computed Discharge Curves + --> + <theme name="ComputedDischargeCurve"> + <inherits> + <inherit from="HiddenColorLines"/> + <inherit from="MinMaxPoints"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0, 0, 153"/> + <field name="linesize" type="int" display="Liniendicke" default="2" hints="h"/> + </fields> + </theme> + + <theme name="ComputedDischargeCurveQ"> + <inherits> + <inherit from="HiddenColorLines"/> + <inherit from="MinMaxPoints"/> + <inherit from="Text"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Farbe" default="200, 0, 15"/> + <field name="textcolor" type="Color" display="Farbe" default="200, 0, 15"/> + </fields> + </theme> + + <theme name="ComputedDischargeCurveW"> + <inherits> + <inherit from="HiddenColorLines"/> + <inherit from="MinMaxPoints"/> + <inherit from="Text"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Farbe" default="0, 215, 0"/> + <field name="textcolor" type="Color" display="Farbe" default="0, 215, 0"/> + <field name="textorientation" type="boolean" display="Textausrichtung" default="true"/> + </fields> + </theme> + + <!-- + Cross Sections + --> + <theme name="CrossSection"> + <inherits> + <inherit from="HiddenColorLines"/> + <inherit from="MinMaxPoints"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0,0,0"/> + <field name="linesize" type="int" display="Liniendicke" default="1" hints="h"/> + </fields> + </theme> + + <theme name="CrossSectionWaterLine"> + <inherits> + <inherit from="HiddenColorLines"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0,0,153"/> + <field name="linesize" type="int" display="Liniendicke" default="1" hints="h"/> + <field name="showwidth" type="boolean" display="Breite anzeigen" default="false"/> + <field name="showlevel" type="boolean" display="Wasserstand anzeigen" default="false"/> + <field name="showmiddleheight" type="boolean" display="Wasserstand anzeigen" default="false"/> + </fields> + </theme> + + <theme name="Hyk"> + <inherits> + <inherit from="Text"/> + </inherits> + <fields> + <field name="textorientation" type="boolean" display="Textausrichtung" default="true"/> + </fields> + </theme> + + <!-- + Duration Curves + --> + <theme name="DurationCurveW"> + <inherits> + <inherit from="HiddenColorLines"/> + <inherit from="MinMaxPoints"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0,51,204"/> + <field name="linesize" type="int" display="Liniendicke" default="2" hints="h"/> + </fields> + </theme> + + <theme name="DurationCurveQ"> + <inherits> + <inherit from="HiddenColorLines"/> + <inherit from="MinMaxPoints"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0,204,0"/> + <field name="linesize" type="int" display="Liniendicke" default="2" hints="h"/> + </fields> + </theme> + + <!-- Differences --> + <theme name="Differences"> + <inherits> + <inherit from="HiddenColorLines"/> + <inherit from="MinMaxPoints"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="204, 204, 204"/> + </fields> + </theme> + + <!-- Reference Curves --> + <theme name="ReferenceCurveNormalized"> + <inherits> + <inherit from="HiddenColorLines"/> + <inherit from="MinMaxPoints"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="204, 204, 204"/> + </fields> + </theme> + + <theme name="ReferenceCurve"> + <inherits> + <inherit from="HiddenColorLines"/> + <inherit from="MinMaxPoints"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="204, 204, 204"/> + </fields> + </theme> + + <!-- General --> + <theme name="WKms"> + <inherits> + <inherit from="HiddenColorLines"/> + <inherit from="MinMaxPoints"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="204, 204, 204"/> + </fields> + </theme> + + <theme name="WQKms"> + <inherits> + <inherit from="HiddenColorLines"/> + <inherit from="MinMaxPoints"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="204, 204, 204"/> + </fields> + </theme> + + <theme name="WQPoints"> + <inherits><inherit from="Points"/></inherits> + <fields> <field name="showlines" type="boolean" display="Linie anzeigen" default="false"/> <field name="showpoints" type="boolean" display="Punkte anzeigen" default="true"/> - </fields> - </theme> - - <theme name="LongitudinalSectionW_HQ1_Points"> - <inherits><inherit from="LongitudinalSectionPoints"/></inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="0, 0, 102"/> - </fields> - </theme> - - <theme name="LongitudinalSectionW_HQ2_Points"> - <inherits><inherit from="LongitudinalSectionPoints"/></inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="0, 0, 102"/> - </fields> - </theme> - - <theme name="LongitudinalSectionW_HQ5_Points"> - <inherits><inherit from="LongitudinalSectionPoints"/></inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="0, 153, 51"/> - </fields> - </theme> - - <theme name="LongitudinalSectionW_HQ10_Points"> - <inherits><inherit from="LongitudinalSectionPoints"/></inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="0, 204, 204"/> - </fields> - </theme> - - <theme name="LongitudinalSectionW_HQ20_Points"> - <inherits><inherit from="LongitudinalSectionPoints"/></inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="153, 153, 0"/> - </fields> - </theme> - - <theme name="LongitudinalSectionW_HQ25_Points"> - <inherits><inherit from="LongitudinalSectionPoints"/></inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="102, 51, 0"/> - </fields> - </theme> - - <theme name="LongitudinalSectionW_HQ50_Points"> - <inherits><inherit from="LongitudinalSectionPoints"/></inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="255, 153, 153"/> - </fields> - </theme> - - <theme name="LongitudinalSectionW_HQ100_Points"> - <inherits><inherit from="LongitudinalSectionPoints"/></inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="255, 0, 51"/> - </fields> - </theme> - - <theme name="LongitudinalSectionW_HQ200_Points"> - <inherits><inherit from="LongitudinalSectionPoints"/></inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="255, 0, 255"/> - </fields> - </theme> - - <theme name="LongitudinalSectionW_HQ500_Points"> - <inherits><inherit from="LongitudinalSectionPoints"/></inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="102, 0, 102"/> - </fields> - </theme> - - <theme name="LongitudinalSectionW_HQ1000_Points"> - <inherits><inherit from="LongitudinalSectionPoints"/></inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="0, 0, 0"/> - </fields> - </theme> - - <theme name="LongitudinalSectionW_HQRZ_Points"> - <inherits><inherit from="LongitudinalSectionPoints"/></inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="102, 0, 102"/> - </fields> - </theme> - - <theme name="LongitudinalSectionW_HSQ_Points"> - <inherits><inherit from="LongitudinalSectionPoints"/></inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="253, 153, 0"/> - </fields> - </theme> - - <theme name="LongitudinalSectionW_MHQ_Points"> - <inherits><inherit from="LongitudinalSectionPoints"/></inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="102, 255, 102"/> - </fields> - </theme> - - <theme name="LongitudinalSectionW_MNQ_Points"> - <inherits><inherit from="LongitudinalSectionPoints"/></inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="0, 255, 255"/> - </fields> - </theme> - - <theme name="LongitudinalSectionW_MQ_Points"> - <inherits><inherit from="LongitudinalSectionPoints"/></inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="0, 51, 204"/> - </fields> - </theme> - - <theme name="LongitudinalSectionW_NQ_Points"> - <inherits><inherit from="LongitudinalSectionPoints"/></inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="153, 204, 255"/> - </fields> - </theme> - - <theme name="LongitudinalSectionW_HQExtrem_Points"> - <inherits><inherit from="LongitudinalSectionPoints"/></inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="0, 0, 0"/> - </fields> - </theme> - - <!-- - Longitudinal Section Q's - --> - - <theme name="LongitudinalSectionQ"> - <inherits> - <inherit from="HiddenColorLines"/> - <inherit from="MinMaxPoints"/> - </inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="204, 204, 204"/> - </fields> - </theme> - - <theme name="LongitudinalSectionQ_HQ1"> - <inherits> - <inherit from="LongitudinalSectionQ"/> - </inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="0, 0, 102"/> - </fields> - </theme> + <field name="linecolor" type="Color" display="Linienfarbe" default="204, 0, 0"/> + </fields> + </theme> - <theme name="LongitudinalSectionQ_HQ2"> - <inherits> - <inherit from="LongitudinalSectionQ"/> - </inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="0, 0, 102"/> - </fields> - </theme> - - <theme name="LongitudinalSectionQ_HQ5"> - <inherits> - <inherit from="LongitudinalSectionQ"/> - </inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="0, 153, 51"/> - </fields> - </theme> - - <theme name="LongitudinalSectionQ_HQ10"> - <inherits> - <inherit from="LongitudinalSectionQ"/> - </inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="0, 204, 204"/> - </fields> - </theme> - - <theme name="LongitudinalSectionQ_HQ20"> - <inherits> - <inherit from="LongitudinalSectionQ"/> - </inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="153, 153, 0"/> - </fields> - </theme> - - <theme name="LongitudinalSectionQ_HQ25"> - <inherits> - <inherit from="LongitudinalSectionQ"/> - </inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="102, 51, 0"/> - </fields> - </theme> - - <theme name="LongitudinalSectionQ_HQ50"> - <inherits> - <inherit from="LongitudinalSectionQ"/> - </inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="255, 153, 153"/> - </fields> - </theme> - - <theme name="LongitudinalSectionQ_HQ100"> - <inherits> - <inherit from="LongitudinalSectionQ"/> - </inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="255, 0, 51"/> - </fields> - </theme> - - <theme name="LongitudinalSectionQ_HQ200"> - <inherits> - <inherit from="LongitudinalSectionQ"/> - </inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="255, 0, 255"/> - </fields> - </theme> - - <theme name="LongitudinalSectionQ_HQ500"> - <inherits> - <inherit from="LongitudinalSectionQ"/> - </inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="102, 0, 102"/> - </fields> - </theme> - - <theme name="LongitudinalSectionQ_HQ1000"> - <inherits> - <inherit from="LongitudinalSectionQ"/> - </inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="0, 0, 0"/> - </fields> - </theme> - - <theme name="LongitudinalSectionQ_HQRZ"> - <inherits> - <inherit from="LongitudinalSectionQ"/> - </inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="102, 0, 102"/> - </fields> - </theme> - - <theme name="LongitudinalSectionQ_HSQ"> - <inherits> - <inherit from="LongitudinalSectionQ"/> - </inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="253, 153, 0"/> - </fields> - </theme> - - <theme name="LongitudinalSectionQ_MHQ"> - <inherits> - <inherit from="LongitudinalSectionQ"/> - </inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="102, 255, 102"/> - </fields> - </theme> - - <theme name="LongitudinalSectionQ_MNQ"> - <inherits> - <inherit from="LongitudinalSectionQ"/> - </inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="0, 255, 255"/> - </fields> - </theme> - - <theme name="LongitudinalSectionQ_MQ"> - <inherits> - <inherit from="LongitudinalSectionQ"/> - </inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="0, 51, 204"/> - </fields> - </theme> - - <theme name="LongitudinalSectionQ_NQ"> - <inherits> - <inherit from="LongitudinalSectionQ"/> - </inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="153, 204, 255"/> - </fields> - </theme> - - <theme name="LongitudinalSectionQ_HQExtrem"> - <inherits> - <inherit from="LongitudinalSectionQ"/> - </inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="0, 0, 0"/> - </fields> - </theme> + <!-- + Discharge Longitudinal Section + --> + <theme name="DischargeLongitudinalSectionW"> + <inherits> + <inherit from="HiddenColorLines"/> + <inherit from="MinMaxPoints"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="204, 204, 204"/> + </fields> + </theme> - <!-- - Computed Discharge Curves - --> - <theme name="ComputedDischargeCurve"> - <inherits> - <inherit from="HiddenColorLines"/> - <inherit from="MinMaxPoints"/> - </inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="0, 0, 153"/> - <field name="linesize" type="int" display="Liniendicke" default="2" hints="h"/> - </fields> - </theme> - - <theme name="ComputedDischargeCurveQ"> - <inherits> - <inherit from="HiddenColorLines"/> - <inherit from="MinMaxPoints"/> - <inherit from="Text"/> - </inherits> - <fields> - <field name="linecolor" type="Color" display="Farbe" default="200, 0, 15"/> - <field name="textcolor" type="Color" display="Farbe" default="200, 0, 15"/> - </fields> - </theme> - - <theme name="ComputedDischargeCurveW"> - <inherits> - <inherit from="HiddenColorLines"/> - <inherit from="MinMaxPoints"/> - <inherit from="Text"/> - </inherits> - <fields> - <field name="linecolor" type="Color" display="Farbe" default="0, 215, 0"/> - <field name="textcolor" type="Color" display="Farbe" default="0, 215, 0"/> - <field name="textorientation" type="boolean" display="Textausrichtung" default="true"/> - </fields> - </theme> - - <!-- - Cross Sections - --> - <theme name="CrossSection"> - <inherits> - <inherit from="HiddenColorLines"/> - <inherit from="MinMaxPoints"/> - </inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="0,0,0"/> - <field name="linesize" type="int" display="Liniendicke" default="1" hints="h"/> - </fields> - </theme> - - <theme name="CrossSectionWaterLine"> - <inherits> - <inherit from="HiddenColorLines"/> - </inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="0,0,153"/> - <field name="linesize" type="int" display="Liniendicke" default="1" hints="h"/> - <field name="showwidth" type="boolean" display="Breite anzeigen" default="false"/> - <field name="showlevel" type="boolean" display="Wasserstand anzeigen" default="false"/> - <field name="showmiddleheight" type="boolean" display="Wasserstand anzeigen" default="false"/> - </fields> - </theme> - - <theme name="Hyk"> - <inherits> - <inherit from="Text"/> - </inherits> - <fields> - <field name="textorientation" type="boolean" display="Textausrichtung" default="true"/> - </fields> - </theme> + <theme name="DischargeLongitudinalSectionC"> + <inherits> + <inherit from="HiddenColorLines"/> + <inherit from="MinMaxPoints"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="255, 0 , 0"/> + </fields> + </theme> - <!-- - Duration Curves - --> - <theme name="DurationCurveW"> - <inherits> - <inherit from="HiddenColorLines"/> - <inherit from="MinMaxPoints"/> - </inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="0,51,204"/> - <field name="linesize" type="int" display="Liniendicke" default="2" hints="h"/> - </fields> - </theme> - - <theme name="DurationCurveQ"> - <inherits> - <inherit from="HiddenColorLines"/> - <inherit from="MinMaxPoints"/> - </inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="0,204,0"/> - <field name="linesize" type="int" display="Liniendicke" default="2" hints="h"/> - </fields> - </theme> - - <!-- Differences --> - <theme name="Differences"> - <inherits> - <inherit from="HiddenColorLines"/> - <inherit from="MinMaxPoints"/> - </inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="204, 204, 204"/> - </fields> - </theme> - - <!-- Reference Curves --> - <theme name="ReferenceCurveNormalized"> - <inherits> - <inherit from="HiddenColorLines"/> - <inherit from="MinMaxPoints"/> - </inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="204, 204, 204"/> - </fields> - </theme> - - <theme name="ReferenceCurve"> - <inherits> - <inherit from="HiddenColorLines"/> - <inherit from="MinMaxPoints"/> - </inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="204, 204, 204"/> - </fields> - </theme> - - <!-- General --> - <theme name="WKms"> - <inherits> - <inherit from="HiddenColorLines"/> - <inherit from="MinMaxPoints"/> - </inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="204, 204, 204"/> - </fields> - </theme> - - <theme name="WQKms"> - <inherits> - <inherit from="HiddenColorLines"/> - <inherit from="MinMaxPoints"/> - </inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="204, 204, 204"/> - </fields> - </theme> - - <theme name="WQPoints"> - <inherits><inherit from="Points"/></inherits> - <fields> - <field name="showlines" type="boolean" display="Linie anzeigen" default="false"/> - <field name="showpoints" type="boolean" display="Punkte anzeigen" default="true"/> - <field name="linecolor" type="Color" display="Linienfarbe" default="204, 0, 0"/> - </fields> - </theme> - - <!-- - Discharge Longitudinal Section - --> - <theme name="DischargeLongitudinalSectionW"> - <inherits> - <inherit from="HiddenColorLines"/> - <inherit from="MinMaxPoints"/> - </inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="204, 204, 204"/> - </fields> - </theme> + <theme name="DischargeLongitudinalSectionQ"> + <inherits> + <inherit from="HiddenColorLines"/> + <inherit from="MinMaxPoints"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="204, 204, 204"/> + </fields> + </theme> - <theme name="DischargeLongitudinalSectionC"> - <inherits> - <inherit from="HiddenColorLines"/> - <inherit from="MinMaxPoints"/> - </inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="255, 0 , 0"/> - </fields> - </theme> + <!-- Annotations --> + <theme name="Annotations"> + <inherits> + <inherit from="HiddenColorLines"/> + <inherit from="Text"/> + <inherit from="AnnotationText"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0, 0, 0"/> + </fields> + </theme> - <theme name="DischargeLongitudinalSectionQ"> - <inherits> - <inherit from="HiddenColorLines"/> - <inherit from="MinMaxPoints"/> - </inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="204, 204, 204"/> - </fields> - </theme> + <!-- Manual Points --> + <theme name="ManualPoints"> + <inherits> + <inherit from="Points"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="250, 0, 0"/> + <field name="font" type="Font" display="Schriftart" default="arial"/> + <field name="textcolor" type="Color" display="Schriftfarbe" default="0, 0, 0"/> + <field name="textsize" type="int" display="Schriftgröße" default="10"/> + <field name="textstyle" type="Style" display="Schriftstil" default="standard"/> + <field name="pointsize" type="int" display="Punktdicke" default="3" hints="h"/> + <field name="backgroundcolor" type="Color" display="Texthintergrund" default="255, 255, 255"/> + <field name="textorientation" type="boolean" display="Textausrichtung" default="true"/> + <field name="showbackground" type="boolean" display="Hintergrund anzeigen" default="false"/> + </fields> + </theme> + + <!-- Height Marks --> + <theme name="heightmarks_points"> + <inherits> + <inherit from="Points"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0, 0, 0"/> + </fields> + </theme> + </themegroup> + + <themegroup name="default-2"> + <theme name="DischargeCurve"> + <inherits> + <inherit from="HiddenColorLines"/> + <inherit from="MinMaxPoints"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0, 153, 153"/> + <field name="linesize" type="int" display="Liniendicke" default="2" hints="h"/> + </fields> + </theme> - <!-- Annotations --> - <theme name="Annotations"> - <inherits> - <inherit from="HiddenColorLines"/> - <inherit from="Text"/> - <inherit from="AnnotationText"/> - </inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="0, 0, 0"/> - </fields> - </theme> + <!-- concrete theme for historical discharge curves --> + <theme name="HistoricalDischargeCurveQ"> + <inherits> + <inherit from="HiddenColorLines"/> + <inherit from="MinMaxPoints"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0, 153, 153"/> + <field name="linesize" type="int" display="Liniendicke" default="2" hints="h"/> + </fields> + </theme> - <!-- Manual Points --> - <theme name="ManualPoints"> - <inherits> - <inherit from="Points"/> - </inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="250, 0, 0"/> - <field name="font" type="Font" display="Schriftart" default="arial"/> - <field name="textcolor" type="Color" display="Schriftfarbe" default="0, 0, 0"/> - <field name="textsize" type="int" display="Schriftgröße" default="10"/> - <field name="textstyle" type="Style" display="Schriftstil" default="standard"/> - <field name="pointsize" type="int" display="Punktdicke" default="3" hints="h"/> - <field name="backgroundcolor" type="Color" display="Texthintergrund" default="255, 255, 255"/> - <field name="textorientation" type="boolean" display="Textausrichtung" default="true"/> - <field name="showbackground" type="boolean" display="Hintergrund anzeigen" default="false"/> - </fields> - </theme> + <theme name="HistoricalDischargeCurveQDiff"> + <inherits> + <inherit from="HiddenColorLines"/> + <inherit from="MinMaxPoints"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="204, 0, 204"/> + <field name="linesize" type="int" display="Liniendicke" default="2" hints="h"/> + </fields> + </theme> - <!-- Height Marks --> - <theme name="heightmarks_points"> - <inherits> - <inherit from="Points"/> - </inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="0, 0, 0"/> - </fields> - </theme> + <!-- + Discharge Longitudinal Section + --> + <theme name="LongitudinalSectionW"> + <inherits> + <inherit from="HiddenColorLines"/> + <inherit from="MinMaxPoints"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="204, 0, 204"/> + </fields> + </theme> + + <theme name="LongitudinalSectionW_HQ1"> + <inherits> + <inherit from="LongitudinalSectionW"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0, 102, 102"/> + </fields> + </theme> + + <theme name="LongitudinalSectionW_HQ2"> + <inherits> + <inherit from="LongitudinalSectionW"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0, 102, 102"/> + </fields> + </theme> + + <theme name="LongitudinalSectionW_HQ5"> + <inherits> + <inherit from="LongitudinalSectionW"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0, 51, 51"/> + </fields> + </theme> + + <theme name="LongitudinalSectionW_HQ10"> + <inherits> + <inherit from="LongitudinalSectionW"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0, 0, 204"/> + </fields> + </theme> + + <theme name="LongitudinalSectionW_HQ20"> + <inherits> + <inherit from="LongitudinalSectionW"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="153, 0, 0"/> + </fields> + </theme> + + <theme name="LongitudinalSectionW_HQ25"> + <inherits> + <inherit from="LongitudinalSectionW"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="102, 102, 0"/> + </fields> + </theme> + + <theme name="LongitudinalSectionW_HQ50"> + <inherits> + <inherit from="LongitudinalSectionW"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="255, 0, 153"/> + </fields> + </theme> + + <theme name="LongitudinalSectionW_HQ100"> + <inherits> + <inherit from="LongitudinalSectionW"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0, 0, 255"/> + </fields> + </theme> + + <theme name="LongitudinalSectionW_HQ200"> + <inherits> + <inherit from="LongitudinalSectionW"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0, 255, 255"/> + </fields> + </theme> + + <theme name="LongitudinalSectionW_HQ500"> + <inherits> + <inherit from="LongitudinalSectionW"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="102, 102, 102"/> + </fields> + </theme> + + <theme name="LongitudinalSectionW_HQ1000"> + <inherits> + <inherit from="LongitudinalSectionW"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="255, 0, 0"/> + </fields> + </theme> + + <theme name="LongitudinalSectionW_HQRZ"> + <inherits> + <inherit from="LongitudinalSectionW"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0, 0, 102"/> + </fields> + </theme> + + <theme name="LongitudinalSectionW_HSQ"> + <inherits> + <inherit from="LongitudinalSectionW"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="253, 153, 255"/> + </fields> + </theme> + + <theme name="LongitudinalSectionW_MHQ"> + <inherits> + <inherit from="LongitudinalSectionW"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="102, 255, 0"/> + </fields> + </theme> + + <theme name="LongitudinalSectionW_MNQ"> + <inherits> + <inherit from="LongitudinalSectionW"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0, 255, 0"/> + </fields> + </theme> + + <theme name="LongitudinalSectionW_MQ"> + <inherits> + <inherit from="LongitudinalSectionW"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0, 51, 0"/> + </fields> + </theme> + + <theme name="LongitudinalSectionW_NQ"> + <inherits> + <inherit from="LongitudinalSectionW"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="153, 0, 255"/> + </fields> + </theme> + + <theme name="LongitudinalSectionW_HQExtrem"> + <inherits> + <inherit from="LongitudinalSectionW"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0, 0, 255"/> + </fields> + </theme> + + <theme name="LongitudinalSectionPoints"> + <inherits> + <inherit from="LongitudinalSectionW"/> + </inherits> + <fields> + <field name="showlines" type="boolean" display="Linie anzeigen" default="false"/> + <field name="showpoints" type="boolean" display="Punkte anzeigen" default="true"/> + </fields> + </theme> + + <theme name="LongitudinalSectionW_HQ1_Points"> + <inherits><inherit from="LongitudinalSectionPoints"/></inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0, 0, 0"/> + </fields> + </theme> + + <theme name="LongitudinalSectionW_HQ2_Points"> + <inherits><inherit from="LongitudinalSectionPoints"/></inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0, 0, 1"/> + </fields> + </theme> + + <theme name="LongitudinalSectionW_HQ5_Points"> + <inherits><inherit from="LongitudinalSectionPoints"/></inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0, 153, 0"/> + </fields> + </theme> + + <theme name="LongitudinalSectionW_HQ10_Points"> + <inherits><inherit from="LongitudinalSectionPoints"/></inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0, 204, 204"/> + </fields> + </theme> + + <theme name="LongitudinalSectionW_HQ20_Points"> + <inherits><inherit from="LongitudinalSectionPoints"/></inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="153, 153, 0"/> + </fields> + </theme> + + <theme name="LongitudinalSectionW_HQ25_Points"> + <inherits><inherit from="LongitudinalSectionPoints"/></inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="102, 51, 0"/> + </fields> + </theme> + + <theme name="LongitudinalSectionW_HQ50_Points"> + <inherits><inherit from="LongitudinalSectionPoints"/></inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="255, 153, 153"/> + </fields> + </theme> + + <theme name="LongitudinalSectionW_HQ100_Points"> + <inherits><inherit from="LongitudinalSectionPoints"/></inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="255, 0, 51"/> + </fields> + </theme> + + <theme name="LongitudinalSectionW_HQ200_Points"> + <inherits><inherit from="LongitudinalSectionPoints"/></inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="255, 0, 255"/> + </fields> + </theme> + + <theme name="LongitudinalSectionW_HQ500_Points"> + <inherits><inherit from="LongitudinalSectionPoints"/></inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="102, 0, 102"/> + </fields> + </theme> + + <theme name="LongitudinalSectionW_HQ1000_Points"> + <inherits><inherit from="LongitudinalSectionPoints"/></inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0, 0, 0"/> + </fields> + </theme> + + <theme name="LongitudinalSectionW_HQRZ_Points"> + <inherits><inherit from="LongitudinalSectionPoints"/></inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="102, 0, 102"/> + </fields> + </theme> + + <theme name="LongitudinalSectionW_HSQ_Points"> + <inherits><inherit from="LongitudinalSectionPoints"/></inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="253, 153, 0"/> + </fields> + </theme> + + <theme name="LongitudinalSectionW_MHQ_Points"> + <inherits><inherit from="LongitudinalSectionPoints"/></inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="102, 255, 102"/> + </fields> + </theme> + + <theme name="LongitudinalSectionW_MNQ_Points"> + <inherits><inherit from="LongitudinalSectionPoints"/></inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0, 255, 255"/> + </fields> + </theme> + + <theme name="LongitudinalSectionW_MQ_Points"> + <inherits><inherit from="LongitudinalSectionPoints"/></inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0, 51, 204"/> + </fields> + </theme> + + <theme name="LongitudinalSectionW_NQ_Points"> + <inherits><inherit from="LongitudinalSectionPoints"/></inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="153, 204, 255"/> + </fields> + </theme> + + <theme name="LongitudinalSectionW_HQExtrem_Points"> + <inherits><inherit from="LongitudinalSectionPoints"/></inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0, 0, 0"/> + </fields> + </theme> + + <!-- + Longitudinal Section Q's + --> + + <theme name="LongitudinalSectionQ"> + <inherits> + <inherit from="HiddenColorLines"/> + <inherit from="MinMaxPoints"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="204, 204, 204"/> + </fields> + </theme> + + <theme name="LongitudinalSectionQ_HQ1"> + <inherits> + <inherit from="LongitudinalSectionQ"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0, 0, 102"/> + </fields> + </theme> + + <theme name="LongitudinalSectionQ_HQ2"> + <inherits> + <inherit from="LongitudinalSectionQ"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0, 0, 102"/> + </fields> + </theme> + + <theme name="LongitudinalSectionQ_HQ5"> + <inherits> + <inherit from="LongitudinalSectionQ"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0, 153, 51"/> + </fields> + </theme> + + <theme name="LongitudinalSectionQ_HQ10"> + <inherits> + <inherit from="LongitudinalSectionQ"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0, 204, 204"/> + </fields> + </theme> + + <theme name="LongitudinalSectionQ_HQ20"> + <inherits> + <inherit from="LongitudinalSectionQ"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="153, 153, 0"/> + </fields> + </theme> + + <theme name="LongitudinalSectionQ_HQ25"> + <inherits> + <inherit from="LongitudinalSectionQ"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="102, 51, 0"/> + </fields> + </theme> + + <theme name="LongitudinalSectionQ_HQ50"> + <inherits> + <inherit from="LongitudinalSectionQ"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="255, 153, 153"/> + </fields> + </theme> + + <theme name="LongitudinalSectionQ_HQ100"> + <inherits> + <inherit from="LongitudinalSectionQ"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="255, 0, 51"/> + </fields> + </theme> + + <theme name="LongitudinalSectionQ_HQ200"> + <inherits> + <inherit from="LongitudinalSectionQ"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="255, 0, 255"/> + </fields> + </theme> + + <theme name="LongitudinalSectionQ_HQ500"> + <inherits> + <inherit from="LongitudinalSectionQ"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="102, 0, 102"/> + </fields> + </theme> + + <theme name="LongitudinalSectionQ_HQ1000"> + <inherits> + <inherit from="LongitudinalSectionQ"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0, 0, 0"/> + </fields> + </theme> + + <theme name="LongitudinalSectionQ_HQRZ"> + <inherits> + <inherit from="LongitudinalSectionQ"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="102, 0, 102"/> + </fields> + </theme> + + <theme name="LongitudinalSectionQ_HSQ"> + <inherits> + <inherit from="LongitudinalSectionQ"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="253, 153, 0"/> + </fields> + </theme> + + <theme name="LongitudinalSectionQ_MHQ"> + <inherits> + <inherit from="LongitudinalSectionQ"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="102, 255, 102"/> + </fields> + </theme> + + <theme name="LongitudinalSectionQ_MNQ"> + <inherits> + <inherit from="LongitudinalSectionQ"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0, 255, 255"/> + </fields> + </theme> + + <theme name="LongitudinalSectionQ_MQ"> + <inherits> + <inherit from="LongitudinalSectionQ"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0, 51, 204"/> + </fields> + </theme> + + <theme name="LongitudinalSectionQ_NQ"> + <inherits> + <inherit from="LongitudinalSectionQ"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="153, 204, 255"/> + </fields> + </theme> + + <theme name="LongitudinalSectionQ_HQExtrem"> + <inherits> + <inherit from="LongitudinalSectionQ"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0, 0, 0"/> + </fields> + </theme> + + + <!-- + Computed Discharge Curves + --> + <theme name="ComputedDischargeCurve"> + <inherits> + <inherit from="HiddenColorLines"/> + <inherit from="MinMaxPoints"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0, 0, 153"/> + <field name="linesize" type="int" display="Liniendicke" default="2" hints="h"/> + </fields> + </theme> + + <theme name="ComputedDischargeCurveQ"> + <inherits> + <inherit from="HiddenColorLines"/> + <inherit from="MinMaxPoints"/> + <inherit from="Text"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Farbe" default="200, 0, 15"/> + <field name="textcolor" type="Color" display="Farbe" default="200, 0, 15"/> + </fields> + </theme> + + <theme name="ComputedDischargeCurveW"> + <inherits> + <inherit from="HiddenColorLines"/> + <inherit from="MinMaxPoints"/> + <inherit from="Text"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Farbe" default="0, 215, 0"/> + <field name="textcolor" type="Color" display="Farbe" default="0, 215, 0"/> + <field name="textorientation" type="boolean" display="Textausrichtung" default="true"/> + </fields> + </theme> + + <!-- + Cross Sections + --> + <theme name="CrossSection"> + <inherits> + <inherit from="HiddenColorLines"/> + <inherit from="MinMaxPoints"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0,0,0"/> + <field name="linesize" type="int" display="Liniendicke" default="1" hints="h"/> + </fields> + </theme> + + <theme name="CrossSectionWaterLine"> + <inherits> + <inherit from="HiddenColorLines"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0,0,153"/> + <field name="linesize" type="int" display="Liniendicke" default="1" hints="h"/> + <field name="showwidth" type="boolean" display="Breite anzeigen" default="false"/> + <field name="showlevel" type="boolean" display="Wasserstand anzeigen" default="false"/> + <field name="showmiddleheight" type="boolean" display="Wasserstand anzeigen" default="false"/> + </fields> + </theme> + + <theme name="Hyk"> + <inherits> + <inherit from="Text"/> + </inherits> + <fields> + <field name="textorientation" type="boolean" display="Textausrichtung" default="true"/> + </fields> + </theme> + + <!-- + Duration Curves + --> + <theme name="DurationCurveW"> + <inherits> + <inherit from="HiddenColorLines"/> + <inherit from="MinMaxPoints"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0,51,204"/> + <field name="linesize" type="int" display="Liniendicke" default="2" hints="h"/> + </fields> + </theme> + + <theme name="DurationCurveQ"> + <inherits> + <inherit from="HiddenColorLines"/> + <inherit from="MinMaxPoints"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0,204,0"/> + <field name="linesize" type="int" display="Liniendicke" default="2" hints="h"/> + </fields> + </theme> + + <!-- Differences --> + <theme name="Differences"> + <inherits> + <inherit from="HiddenColorLines"/> + <inherit from="MinMaxPoints"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="204, 204, 204"/> + </fields> + </theme> + + <!-- Reference Curves --> + <theme name="ReferenceCurveNormalized"> + <inherits> + <inherit from="HiddenColorLines"/> + <inherit from="MinMaxPoints"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="204, 204, 204"/> + </fields> + </theme> + + <theme name="ReferenceCurve"> + <inherits> + <inherit from="HiddenColorLines"/> + <inherit from="MinMaxPoints"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="204, 204, 204"/> + </fields> + </theme> + + <!-- General --> + <theme name="WKms"> + <inherits> + <inherit from="HiddenColorLines"/> + <inherit from="MinMaxPoints"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="204, 204, 204"/> + </fields> + </theme> + + <theme name="WQKms"> + <inherits> + <inherit from="HiddenColorLines"/> + <inherit from="MinMaxPoints"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="204, 204, 204"/> + </fields> + </theme> + + <theme name="WQPoints"> + <inherits><inherit from="Points"/></inherits> + <fields> + <field name="showlines" type="boolean" display="Linie anzeigen" default="false"/> + <field name="showpoints" type="boolean" display="Punkte anzeigen" default="true"/> + <field name="linecolor" type="Color" display="Linienfarbe" default="204, 0, 0"/> + </fields> + </theme> + + <!-- + Discharge Longitudinal Section + --> + <theme name="DischargeLongitudinalSectionW"> + <inherits> + <inherit from="HiddenColorLines"/> + <inherit from="MinMaxPoints"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="204, 204, 204"/> + </fields> + </theme> + + + <theme name="DischargeLongitudinalSectionC"> + <inherits> + <inherit from="HiddenColorLines"/> + <inherit from="MinMaxPoints"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="255, 0 , 0"/> + </fields> + </theme> + + <theme name="DischargeLongitudinalSectionQ"> + <inherits> + <inherit from="HiddenColorLines"/> + <inherit from="MinMaxPoints"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="204, 204, 204"/> + </fields> + </theme> + + + <!-- Annotations --> + <theme name="Annotations"> + <inherits> + <inherit from="HiddenColorLines"/> + <inherit from="Text"/> + <inherit from="AnnotationText"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0, 0, 0"/> + </fields> + </theme> + + <!-- Manual Points --> + <theme name="ManualPoints"> + <inherits> + <inherit from="Points"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="250, 0, 0"/> + <field name="font" type="Font" display="Schriftart" default="arial"/> + <field name="textcolor" type="Color" display="Schriftfarbe" default="0, 0, 0"/> + <field name="textsize" type="int" display="Schriftgröße" default="10"/> + <field name="textstyle" type="Style" display="Schriftstil" default="standard"/> + <field name="pointsize" type="int" display="Punktdicke" default="3" hints="h"/> + <field name="backgroundcolor" type="Color" display="Texthintergrund" default="255, 255, 255"/> + <field name="textorientation" type="boolean" display="Textausrichtung" default="true"/> + <field name="showbackground" type="boolean" display="Hintergrund anzeigen" default="false"/> + </fields> + </theme> + + <!-- Height Marks --> + <theme name="heightmarks_points"> + <inherits> + <inherit from="Points"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0, 0, 0"/> + </fields> + </theme> + </themegroup> <!-- Virtual themes are following now! --> - <theme name="Lines" type="virtual"> - <fields> - <field name="showlines" type="boolean" display="Linie anzeigen" default="true"/> - <field name="linesize" type="int" display="Liniendicke" default="1"/> - <field name="linetype" type="Dash" display="Linienart" default="10"/> - <field name="showlinelabel" type="boolean" display="Beschriftung anzeigen" default="false" hints="h"/> - <field name="linelabelfont" type="Font" display="Beschriftung: Schriftart" default="arial"/> - <field name="linelabelcolor" type="Color" display="Beschriftung: Schriftfarbe" default="0, 0, 0"/> - <field name="linelabelsize" type="int" display="Beschriftung: Schriftgröße" default="10"/> - <field name="linelabelstyle" type="Style" display="Beschriftung: Schriftstil" default="standard"/> - <field name="linelabelbgcolor" type="Color" display="Beschriftung: Hintergrundfarbe" default="0, 0, 0"/> - <field name="linelabelshowbg" type="boolean" display="Beschriftung: Hintergrund füllen" default="false"/> - <!--orientation? --> - </fields> - </theme> - - <theme name="Points" type="virtual"> - <fields> - <field name="showlines" type="boolean" display="Linie anzeigen" default="false"/> - <field name="linesize" type="int" display="Liniendicke" default="1"/> - <field name="linetype" type="Dash" display="Linienart" default="10"/> - <field name="showpoints" type="boolean" display="Punkte anzeigen" default="true"/> - </fields> - </theme> - - <theme name="ColorLines" type="virtual"> - <inherits> - <inherit from="Lines"/> - </inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="Color.BLACK"/> - </fields> - </theme> + <themegroup name="virtual"> + <theme name="Lines" type="virtual"> + <fields> + <field name="showlines" type="boolean" display="Linie anzeigen" default="true"/> + <field name="linesize" type="int" display="Liniendicke" default="1"/> + <field name="linetype" type="Dash" display="Linienart" default="10"/> + <field name="showlinelabel" type="boolean" display="Beschriftung anzeigen" default="false" hints="h"/> + <field name="linelabelfont" type="Font" display="Beschriftung: Schriftart" default="arial"/> + <field name="linelabelcolor" type="Color" display="Beschriftung: Schriftfarbe" default="0, 0, 0"/> + <field name="linelabelsize" type="int" display="Beschriftung: Schriftgröße" default="10"/> + <field name="linelabelstyle" type="Style" display="Beschriftung: Schriftstil" default="standard"/> + <field name="linelabelbgcolor" type="Color" display="Beschriftung: Hintergrundfarbe" default="0, 0, 0"/> + <field name="linelabelshowbg" type="boolean" display="Beschriftung: Hintergrund füllen" default="false"/> + <!--orientation? --> + </fields> + </theme> - <theme name="HiddenColorLines" type="virtual"> - <inherits> - <inherit from="ColorLines"/> - </inherits> - <fields> - <field name="showlines" type="boolean" display="Linie anzeigen" default="true" hints="h"/> - <field name="linesize" type="int" display="Liniendicke" default="1" hints="h"/> - <field name="linetype" type="Dash" display="Linienart" default="10" hints="h"/> - <field name="showpoints" type="boolean" display="Datenpunkte anzeigen" default="false" hints="h"/> - <field name="pointsize" type="int" display="Punktdicke" default="5" hints="h"/> - </fields> - </theme> - - <theme name="MinMaxPoints" type="virtual"> - <fields> - <field name="showminimum" type="boolean" display="Minimum anzeigen" default="false" hints="h"/> - <field name="showmaximum" type="boolean" display="Minimum anzeigen" default="false" hints="h"/> - </fields> - </theme> + <theme name="Points" type="virtual"> + <fields> + <field name="showlines" type="boolean" display="Linie anzeigen" default="false"/> + <field name="linesize" type="int" display="Liniendicke" default="1"/> + <field name="linetype" type="Dash" display="Linienart" default="10"/> + <field name="showpoints" type="boolean" display="Punkte anzeigen" default="true"/> + </fields> + </theme> - <theme name="Text" type="virtual"> - <fields> - <field name="font" type="Font" display="Schriftart" default="arial"/> - <field name="textcolor" type="Color" display="Schriftfarbe" default="0, 0, 0"/> - <field name="textsize" type="int" display="Schriftgröße" default="10"/> - <field name="textstyle" type="Style" display="Schriftstil" default="standard"/> - </fields> - </theme> - - <theme name="AnnotationText" type="virtual"> - <fields> - <field name="backgroundcolor" type="Color" display="Texthintergrund" default="255, 255, 255"/> - <field name="textorientation" type="boolean" display="Textausrichtung" default="false"/> - <field name="showbackground" type="boolean" display="Hintergrund anzeigen" default="false"/> - </fields> - </theme> + <theme name="ColorLines" type="virtual"> + <inherits> + <inherit from="Lines"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="Color.BLACK"/> + </fields> + </theme> - <!-- Area relevant theme(s) --> - <theme name="Area"> - <inherits> - <inherit from="Text"/> - </inherits> - <fields> - <field name="backgroundcolor" type="Color" display="Texthintergrund" default="255, 255, 255"/> - <field name="showbackground" type="boolean" display="Hintergrund anzeigen" default="false"/> - <field name="linecolor" type="Color" display="Linienfarbe" default="Color.BLACK"/> - <field name="showlines" type="boolean" display="Linie anzeigen" default="true"/> - <field name="linesize" type="int" display="Liniendicke" default="1"/> - <field name="linetype" type="Dash" display="Linienart" default="10"/> - <field name="fillcolor" type="Color" display="Fuellfarbe" default="0, 100, 0"/> - <field name="showarea" type="boolean" display="Flaeche beschriften" default="false"/> - <field name="showborder" type="boolean" display="Flaechebegrenzungslinie anzeigen" default="false"/> - <field name="transparent" type="boolean" display="Transparenz" default="false"/> - </fields> - </theme> + <theme name="HiddenColorLines" type="virtual"> + <inherits> + <inherit from="ColorLines"/> + </inherits> + <fields> + <field name="showlines" type="boolean" display="Linie anzeigen" default="true" hints="h"/> + <field name="linesize" type="int" display="Liniendicke" default="1" hints="h"/> + <field name="linetype" type="Dash" display="Linienart" default="10" hints="h"/> + <field name="showpoints" type="boolean" display="Datenpunkte anzeigen" default="false" hints="h"/> + <field name="pointsize" type="int" display="Punktdicke" default="5" hints="h"/> + </fields> + </theme> + + <theme name="MinMaxPoints" type="virtual"> + <fields> + <field name="showminimum" type="boolean" display="Minimum anzeigen" default="false" hints="h"/> + <field name="showmaximum" type="boolean" display="Minimum anzeigen" default="false" hints="h"/> + </fields> + </theme> + + <theme name="Text" type="virtual"> + <fields> + <field name="font" type="Font" display="Schriftart" default="arial"/> + <field name="textcolor" type="Color" display="Schriftfarbe" default="0, 0, 0"/> + <field name="textsize" type="int" display="Schriftgröße" default="10"/> + <field name="textstyle" type="Style" display="Schriftstil" default="standard"/> + </fields> + </theme> + + <theme name="AnnotationText" type="virtual"> + <fields> + <field name="backgroundcolor" type="Color" display="Texthintergrund" default="255, 255, 255"/> + <field name="textorientation" type="boolean" display="Textausrichtung" default="false"/> + <field name="showbackground" type="boolean" display="Hintergrund anzeigen" default="false"/> + </fields> + </theme> + + <!-- Area relevant theme(s) --> + <theme name="Area"> + <inherits> + <inherit from="Text"/> + </inherits> + <fields> + <field name="backgroundcolor" type="Color" display="Texthintergrund" default="255, 255, 255"/> + <field name="showbackground" type="boolean" display="Hintergrund anzeigen" default="false"/> + <field name="linecolor" type="Color" display="Linienfarbe" default="Color.BLACK"/> + <field name="showlines" type="boolean" display="Linie anzeigen" default="true"/> + <field name="linesize" type="int" display="Liniendicke" default="1"/> + <field name="linetype" type="Dash" display="Linienart" default="10"/> + <field name="fillcolor" type="Color" display="Fuellfarbe" default="0, 100, 0"/> + <field name="showarea" type="boolean" display="Flaeche beschriften" default="false"/> + <field name="showborder" type="boolean" display="Flaechebegrenzungslinie anzeigen" default="false"/> + <field name="transparent" type="boolean" display="Transparenz" default="false"/> + </fields> + </theme> - <!-- MAP relevant themes --> - <theme name="WSPLGEN"> - <fields> - <field name="wsplgen_cat1" type="Color" display="Hintergrund" default="178, 201, 215"/> - <field name="wsplgen_cat2" type="Color" display="Hintergrund" default="111, 147, 170"/> - <field name="wsplgen_cat3" type="Color" display="Hintergrund" default="66, 111, 139"/> - <field name="wsplgen_cat4" type="Color" display="Hintergrund" default="33, 79, 108"/> - <field name="wsplgen_cat5" type="Color" display="Hintergrund" default="2, 27, 42"/> - </fields> - </theme> - - <theme name="RiverAxis"> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="0, 0, 205"/> - <field name="linesize" type="int" display="Liniendicke" default="3" hints="h"/> - </fields> - </theme> - - <theme name="Kms"> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="255, 0, 0"/> - <field name="linesize" type="int" display="Liniendicke" default="5" hints="h"/> - <field name="textcolor" type="Color" display="Schriftfarbe" default="0, 0, 0"/> - <field name="textsize" type="int" display="Schriftgröße" default="10"/> - <field name="symbol" type="Symbol" display="Symbol" default="square"/> - </fields> - </theme> - - <theme name="Fixpoints"> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="255, 0, 0"/> - <field name="linesize" type="int" display="Liniendicke" default="3" hints="h"/> - <field name="symbol" type="Symbol" display="Symbol" default="point"/> - </fields> - </theme> - - <theme name="Floodmaps"> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="0, 0, 0"/> - <field name="linesize" type="int" display="Liniendicke" default="1" hints="h"/> - <field name="backgroundcolor" type="Color" display="Hintergrund" default="140, 200, 130"/> - </fields> - </theme> - - <theme name="GaugeLocation"> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="0, 0, 0"/> - <field name="linesize" type="int" display="Liniendicke" default="1" hints="h"/> - <field name="symbol" type="Symbol" display="Symbol" default="point"/> - </fields> - </theme> + <!-- MAP relevant themes --> + <theme name="WSPLGEN"> + <fields> + <field name="wsplgen_cat1" type="Color" display="Hintergrund" default="178, 201, 215"/> + <field name="wsplgen_cat2" type="Color" display="Hintergrund" default="111, 147, 170"/> + <field name="wsplgen_cat3" type="Color" display="Hintergrund" default="66, 111, 139"/> + <field name="wsplgen_cat4" type="Color" display="Hintergrund" default="33, 79, 108"/> + <field name="wsplgen_cat5" type="Color" display="Hintergrund" default="2, 27, 42"/> + </fields> + </theme> - <theme name="Qps"> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="0, 0, 255"/> - <field name="linesize" type="int" display="Liniendicke" default="3" hints="h"/> - </fields> - </theme> - - <theme name="Hws"> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="255, 0, 0"/> - <field name="linesize" type="int" display="Liniendicke" default="3" hints="h"/> - </fields> - </theme> - - <theme name="Catchment"> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="0, 0, 0"/> - <field name="linesize" type="int" display="Liniendicke" default="1" hints="h"/> - <field name="backgroundcolor" type="Color" display="Hintergrund" default="140, 200, 130"/> - </fields> - </theme> + <theme name="RiverAxis"> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0, 0, 205"/> + <field name="linesize" type="int" display="Liniendicke" default="3" hints="h"/> + </fields> + </theme> - <theme name="Floodplain"> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="0, 0, 0"/> - <field name="linesize" type="int" display="Liniendicke" default="1" hints="h"/> - <field name="backgroundcolor" type="Color" display="Hintergrund" default="140, 200, 130"/> - </fields> - </theme> - - <theme name="FloodmapLines"> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="140, 200, 130"/> - <field name="linesize" type="int" display="Liniendicke" default="3" hints="h"/> - </fields> - </theme> + <theme name="Kms"> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="255, 0, 0"/> + <field name="linesize" type="int" display="Liniendicke" default="5" hints="h"/> + <field name="textcolor" type="Color" display="Schriftfarbe" default="0, 0, 0"/> + <field name="textsize" type="int" display="Schriftgröße" default="10"/> + <field name="symbol" type="Symbol" display="Symbol" default="square"/> + </fields> + </theme> - <theme name="Buildings"> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="255, 0, 0"/> - <field name="linesize" type="int" display="Liniendicke" default="5" hints="h"/> - </fields> - </theme> + <theme name="Fixpoints"> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="255, 0, 0"/> + <field name="linesize" type="int" display="Liniendicke" default="3" hints="h"/> + <field name="symbol" type="Symbol" display="Symbol" default="point"/> + </fields> + </theme> - <theme name="HydrBoundariesLines"> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="255, 0, 0"/> - <field name="linesize" type="int" display="Liniendicke" default="5" hints="h"/> - </fields> - </theme> + <theme name="Floodmaps"> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0, 0, 0"/> + <field name="linesize" type="int" display="Liniendicke" default="1" hints="h"/> + <field name="backgroundcolor" type="Color" display="Hintergrund" default="140, 200, 130"/> + </fields> + </theme> - <theme name="HydrBoundariesPolys"> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="255, 0, 0"/> - <field name="linesize" type="int" display="Liniendicke" default="5" hints="h"/> - <field name="backgroundcolor" type="Color" display="Hintergrund" default="140, 200, 130"/> - </fields> - </theme> + <theme name="GaugeLocation"> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0, 0, 0"/> + <field name="linesize" type="int" display="Liniendicke" default="1" hints="h"/> + <field name="symbol" type="Symbol" display="Symbol" default="point"/> + </fields> + </theme> + + <theme name="Qps"> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0, 0, 255"/> + <field name="linesize" type="int" display="Liniendicke" default="3" hints="h"/> + </fields> + </theme> + + <theme name="Hws"> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="255, 0, 0"/> + <field name="linesize" type="int" display="Liniendicke" default="3" hints="h"/> + </fields> + </theme> + + <theme name="Catchment"> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0, 0, 0"/> + <field name="linesize" type="int" display="Liniendicke" default="1" hints="h"/> + <field name="backgroundcolor" type="Color" display="Hintergrund" default="140, 200, 130"/> + </fields> + </theme> + + <theme name="Floodplain"> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0, 0, 0"/> + <field name="linesize" type="int" display="Liniendicke" default="1" hints="h"/> + <field name="backgroundcolor" type="Color" display="Hintergrund" default="140, 200, 130"/> + </fields> + </theme> + + <theme name="FloodmapLines"> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="140, 200, 130"/> + <field name="linesize" type="int" display="Liniendicke" default="3" hints="h"/> + </fields> + </theme> + + <theme name="Buildings"> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="255, 0, 0"/> + <field name="linesize" type="int" display="Liniendicke" default="5" hints="h"/> + </fields> + </theme> + + <theme name="HydrBoundariesLines"> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="255, 0, 0"/> + <field name="linesize" type="int" display="Liniendicke" default="5" hints="h"/> + </fields> + </theme> + + <theme name="HydrBoundariesPolys"> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="255, 0, 0"/> + <field name="linesize" type="int" display="Liniendicke" default="5" hints="h"/> + <field name="backgroundcolor" type="Color" display="Hintergrund" default="140, 200, 130"/> + </fields> + </theme> - <!-- - FLOW VELOCITY - --> - <theme name="FlowVelocityVMainChannel"> - <inherits> - <inherit from="HiddenColorLines"/> - <inherit from="MinMaxPoints"/> - </inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="204, 204, 204"/> - </fields> - </theme> + <!-- + FLOW VELOCITY + --> + <theme name="FlowVelocityVMainChannel"> + <inherits> + <inherit from="HiddenColorLines"/> + <inherit from="MinMaxPoints"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="204, 204, 204"/> + </fields> + </theme> - <theme name="FlowVelocityVTotalChannel"> - <inherits> - <inherit from="FlowVelocityVMainChannel"/> - </inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="0, 0, 102"/> - </fields> - </theme> + <theme name="FlowVelocityVTotalChannel"> + <inherits> + <inherit from="FlowVelocityVMainChannel"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0, 0, 102"/> + </fields> + </theme> - <theme name="FlowVelocityTau"> - <inherits> - <inherit from="HiddenColorLines"/> - <inherit from="MinMaxPoints"/> - </inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="0, 204, 204"/> - </fields> - </theme> + <theme name="FlowVelocityTau"> + <inherits> + <inherit from="HiddenColorLines"/> + <inherit from="MinMaxPoints"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0, 204, 204"/> + </fields> + </theme> - <!-- - MIDDLE BED HEIGHT - --> - <theme name="MiddleBedHeightSingle"> - <inherits> - <inherit from="HiddenColorLines"/> - <inherit from="MinMaxPoints"/> - </inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="204, 204, 204"/> - </fields> - </theme> + <!-- + MIDDLE BED HEIGHT + --> + <theme name="MiddleBedHeightSingle"> + <inherits> + <inherit from="HiddenColorLines"/> + <inherit from="MinMaxPoints"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="204, 204, 204"/> + </fields> + </theme> - <theme name="MiddleBedHeightEpoch"> - <inherits> - <inherit from="FlowVelocityVMainChannel"/> - </inherits> - <fields> - <field name="linecolor" type="Color" display="Linienfarbe" default="0, 0, 102"/> - </fields> - </theme> - + <theme name="MiddleBedHeightEpoch"> + <inherits> + <inherit from="FlowVelocityVMainChannel"/> + </inherits> + <fields> + <field name="linecolor" type="Color" display="Linienfarbe" default="0, 0, 102"/> + </fields> + </theme> + </themegroup> <!-- Mappings are following now. A mapping maps between a name of a facet
--- a/flys-artifacts/src/main/java/de/intevation/flys/artifacts/context/FLYSContextFactory.java Wed May 23 08:12:49 2012 +0000 +++ b/flys-artifacts/src/main/java/de/intevation/flys/artifacts/context/FLYSContextFactory.java Wed May 23 08:46:45 2012 +0000 @@ -29,6 +29,7 @@ import de.intevation.flys.artifacts.states.StateFactory; import de.intevation.flys.artifacts.transitions.TransitionFactory; import de.intevation.flys.themes.Theme; +import de.intevation.flys.themes.ThemeGroup; import de.intevation.flys.themes.ThemeFactory; import de.intevation.flys.themes.ThemeMapping; @@ -69,7 +70,10 @@ "/artifact-database/flys/themes/configuration/text()"; public static final String XPATH_THEMES = - "/themes/theme"; + "theme"; + + public static final String XPATH_THEME_GROUPS = + "/themes/themegroup"; public static final String XPATH_THEME_MAPPINGS = "/themes/mappings/mapping"; @@ -281,36 +285,49 @@ Document cfg = getThemeConfig(config); - NodeList themes = (NodeList) XMLUtils.xpath( - cfg, XPATH_THEMES, XPathConstants.NODESET); + NodeList themeGroups = (NodeList) XMLUtils.xpath( + cfg, XPATH_THEME_GROUPS, XPathConstants.NODESET); - int num = themes != null ? themes.getLength() : 0; + int groupNum = themeGroups != null ? themeGroups.getLength() : 0; - if (num == 0) { - logger.warn("There are no themes configured!"); - return; + if (groupNum == 0) { + logger.warn("There are no theme groups configured!"); } - logger.debug("Found " + num + " configured themes."); - - Map<String, Theme> theThemes = new HashMap<String, Theme>(); - - for (int i = 0; i < num; i++) { - Node theme = themes.item(i); - - Theme theTheme = ThemeFactory.createTheme(cfg, theme); + List<ThemeGroup> groups = new ArrayList<ThemeGroup>(); - if (theme != null) { - theThemes.put(theTheme.getName(), theTheme); - } - } + for (int g = 0; g < groupNum; g++) { + Element themeGroup = (Element) themeGroups.item(g); + NodeList themes = (NodeList) XMLUtils.xpath( + themeGroup, XPATH_THEMES, XPathConstants.NODESET); - logger.debug("Initialized " + theThemes.size() + "/" + num + " themes"); + int num = themes != null ? themes.getLength() : 0; - context.put(FLYSContext.THEMES, theThemes); + if (num == 0) { + logger.warn("There are no themes configured!"); + return; + } + + logger.debug("Found " + num + " configured theme groups."); + + Map<String, Theme> theThemes = new HashMap<String, Theme>(); + + for (int i = 0; i < num; i++) { + Node theme = themes.item(i); + + Theme theTheme = ThemeFactory.createTheme(cfg, theme); + + if (theme != null) { + theThemes.put(theTheme.getName(), theTheme); + } + } + String gName = themeGroup.getAttribute("name"); + groups.add(new ThemeGroup(gName, theThemes)); + logger.debug("Initialized " + theThemes.size() + "/" + num + " themes"); + } + context.put(FLYSContext.THEMES, groups); } - /** * This method is used to retrieve the theme configuration document. *
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/flys-artifacts/src/main/java/de/intevation/flys/artifacts/services/ThemeListingService.java Wed May 23 08:46:45 2012 +0000 @@ -0,0 +1,75 @@ +package de.intevation.flys.artifacts.services; + +import java.util.List; + +import org.apache.log4j.Logger; + +import org.w3c.dom.Document; +import org.w3c.dom.Element; +import org.w3c.dom.Node; + +import de.intevation.artifacts.CallMeta; +import de.intevation.artifacts.GlobalContext; + +import de.intevation.artifacts.common.ArtifactNamespaceContext; +import de.intevation.artifacts.common.utils.XMLUtils; + +import de.intevation.flys.themes.Theme; +import de.intevation.flys.themes.ThemeGroup; + +import de.intevation.flys.themes.ThemeFactory; +import de.intevation.flys.artifacts.context.FLYSContext; + +/** + * This service provides a list of themes filtered by the theme name. + * + * @author <a href="mailto:raimund.renkert@intevation.de">Raimund Renkert</a> + */ +public class ThemeListingService extends FLYSService { + + /** The logger used in this service.*/ + private static Logger logger = Logger.getLogger(ThemeListingService.class); + + private static final String XPATH_THEME_NAME = "/theme/@name"; + + protected Document doProcess( + Document data, + GlobalContext context, + CallMeta callMeta + ) { + logger.debug("ThemeListingService.process"); + String name = XMLUtils.xpathString(data, XPATH_THEME_NAME, null); + + if (name == null) { + logger.warn("No theme name provided."); + } + Document result = XMLUtils.newDocument(); + + XMLUtils.ElementCreator ec = new XMLUtils.ElementCreator( + result, + null, + null); + + List<ThemeGroup> tgs = + ThemeFactory.getThemeGroups((FLYSContext) context); + + Element te = ec.create("themes"); + + for (ThemeGroup tg: tgs) { + Element elem = ec.create("themegroup"); + if (tg.getName().equals("virtual")) { + continue; + } + ec.addAttr(elem, "name", tg.getName()); + Theme theme = tg.getThemeByName(name); + Document d = theme.toXML(); + Node imported = result.importNode(d.getDocumentElement(), true); + elem.appendChild(imported); + te.appendChild(elem); + } + + result.appendChild(te); + return result; + } +} +// vim:set ts=4 sw=4 si et sta sts=4 fenc=utf8 :
--- a/flys-artifacts/src/main/java/de/intevation/flys/collections/FLYSArtifactCollection.java Wed May 23 08:12:49 2012 +0000 +++ b/flys-artifacts/src/main/java/de/intevation/flys/collections/FLYSArtifactCollection.java Wed May 23 08:46:45 2012 +0000 @@ -955,7 +955,12 @@ log.error("Exception caught when trying to get art.", dbe); } - Theme t = ThemeFactory.getTheme(flysContext, facet, pattern, outName); + Theme t = ThemeFactory.getTheme( + flysContext, + facet, + pattern, + outName, + "default"); if (t != null) { t.setFacet(facet);
--- a/flys-artifacts/src/main/java/de/intevation/flys/themes/ThemeFactory.java Wed May 23 08:12:49 2012 +0000 +++ b/flys-artifacts/src/main/java/de/intevation/flys/themes/ThemeFactory.java Wed May 23 08:46:45 2012 +0000 @@ -2,6 +2,8 @@ import java.util.List; import java.util.Map; +import java.util.ArrayList; +import java.util.HashMap; import javax.xml.xpath.XPathConstants; @@ -11,6 +13,7 @@ import org.w3c.dom.NamedNodeMap; import org.w3c.dom.Node; import org.w3c.dom.NodeList; +import org.w3c.dom.Element; import de.intevation.artifacts.common.utils.XMLUtils; @@ -70,7 +73,8 @@ FLYSContext c, String name, String pattern, - String output) + String output, + String groupName) { logger.debug("Search theme for: " + name + " - pattern: " + pattern); @@ -83,9 +87,22 @@ Map<String, List<ThemeMapping>> map = (Map<String, List<ThemeMapping>>) c.get(FLYSContext.THEME_MAPPING); - Map<String, Theme> t = (Map<String, Theme>) + List<ThemeGroup> tgs = (List<ThemeGroup>) c.get(FLYSContext.THEMES); + ThemeGroup group = null; + for (ThemeGroup tg: tgs) { + if(tg.getName().equals(groupName)) { + group = tg; + } + } + + if (group == null) { + return null; + } + + Map<String, Theme> t = group.getThemes(); + FLYSArtifact artifact = (FLYSArtifact) c.get(FLYSContext.ARTIFACT_KEY); if (map == null || map.size() == 0 || t == null || t.size() == 0) { @@ -121,6 +138,27 @@ } + public static List<ThemeGroup> getThemeGroups(FLYSContext c) { + List<ThemeGroup> tgs = (List<ThemeGroup>) + c.get(FLYSContext.THEMES); + return tgs; + } + + + public static List<Theme> getThemes (FLYSContext c, String name) { + List<ThemeGroup> tgs = (List<ThemeGroup>) + c.get(FLYSContext.THEMES); + if (tgs == null) { + return null; + } + + List<Theme> themes = new ArrayList<Theme>(); + for (ThemeGroup tg: tgs) { + themes.add(tg.getThemeByName(name)); + } + return themes; + } + protected static String getName(Node config) { return (String) XMLUtils.xpath(config, "@name", XPathConstants.STRING); } @@ -132,6 +170,15 @@ protected static void parseInherits(Document themeCfg, Node cfg, Theme t) { + parseInherits(themeCfg, cfg, t, null); + } + + protected static void parseInherits( + Document themeCfg, + Node cfg, + Theme t, + Map<String, Node> themes + ) { logger.debug("ThemeFactory.parseInherits"); NodeList inherits = (NodeList) XMLUtils.xpath( @@ -146,30 +193,36 @@ logger.debug("Theme inherits from " + num + " other themes."); + if (themes == null) { + themes = buildThemeMap(themeCfg); + } + for (int i = 0; i < num; i++) { Node inherit = inherits.item(i); - String from = (String) XMLUtils.xpath( - inherit, "@from", XPathConstants.STRING); + String from = ((Element)inherit).getAttribute("from"); - Node tmp = getThemeNode(themeCfg, from); + Node tmp = themes.get(from); - parseInherits(themeCfg, tmp, t); + parseInherits(themeCfg, tmp, t, themes); parseFields(tmp, t); } } + protected static Map<String, Node> buildThemeMap(Document themeCfg) { + Map<String, Node> map = new HashMap<String, Node>(); + String xpath = "/themes/themegroup/theme"; - protected static Node getThemeNode(Document themeCfg, String name) { - if (name == null) { - logger.warn("Cannot search theme config without name!"); - return null; + NodeList nodes = (NodeList)XMLUtils.xpath( + themeCfg, xpath, XPathConstants.NODESET); + + if (nodes != null) { + for (int i = 0, N = nodes.getLength(); i < N; ++i) { + Node node = nodes.item(i); + String name = ((Element)node).getAttribute("name"); + map.put(name, node); + } } - - logger.debug("Search for theme: " + name); - - String xpath = "/themes/theme[@name='" + name + "']"; - - return (Node) XMLUtils.xpath(themeCfg, xpath, XPathConstants.NODE); + return map; } @@ -200,8 +253,7 @@ protected static void addField(Theme theme, Node field) { - String name = (String) XMLUtils.xpath( - field, "@name", XPathConstants.STRING); + String name = ((Element)field).getAttribute("name"); logger.debug("Add field: " + name);
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/flys-artifacts/src/main/java/de/intevation/flys/themes/ThemeGroup.java Wed May 23 08:46:45 2012 +0000 @@ -0,0 +1,35 @@ +package de.intevation.flys.themes; + +import java.util.Map; + +import org.w3c.dom.Document; +import org.w3c.dom.Node; + + +/** + * @author <a href="mailto:raimund.renkert@intevation.de">Raimund Renkert</a> + */ +public class ThemeGroup { + + protected String name; + + protected Map<String, Theme> themes; + + + public ThemeGroup(String name, Map<String, Theme> themes) { + this.name = name; + this.themes = themes; + } + + public String getName() { + return this.name; + } + + public Map<String, Theme> getThemes() { + return this.themes; + } + + public Theme getThemeByName(String name) { + return themes.get(name); + } +}