protected override void OnSelectionChanged(string selected)
 {
     base.OnSelectionChanged(selected);
     // und weiterleiten
     if (LinePatternChangedEvent != null)
     {
         LinePatternChangedEvent(linePatternList.Find(selected));
     }
     if (iLinePattern != null)
     {
         iLinePattern.LinePattern = linePatternList.Find(selected);
     }
 }
        public LinePatternSelectionProperty(string ResourceID, LinePatternList linePatternList, ILinePattern iLinePattern, bool includeUndefined)
        {
            this.linePatternList = linePatternList;
            resourceId           = ResourceID;
            LinePattern select = iLinePattern.LinePattern;

            if (includeUndefined)
            {
                choices = new string[linePatternList.Count + 1];
                for (int i = 0; i < linePatternList.Count; ++i)
                {
                    choices[i + 1] = linePatternList[i].Name;
                }
                string undef = StringTable.GetString("LinePattern.Undefined");
                // sollte es den Namen schon geben, werden solange - davor und dahintergemacht, bis es den Namen mehr gibt
                while (linePatternList.Find(undef) != null)
                {
                    undef = "-" + undef + "-";
                }
                choices[0] = undef;
                if (select != null)
                {
                    base.selectedText = select.Name;
                }
                else
                {
                    base.selectedText = undef;
                }
            }
            else
            {
                choices = new string[linePatternList.Count];
                for (int i = 0; i < linePatternList.Count; ++i)
                {
                    choices[i] = linePatternList[i].Name;
                }
                if (select != null)
                {
                    base.selectedText = select.Name;
                }
            }
            this.iLinePattern = iLinePattern;
            toWatch           = iLinePattern as IGeoObject;
        }