Пример #1
0
        public SpectreToDoResult(SpectreToDoData stdd) : base(stdd.Header, "", "I am a happy ToDo List") {
            this.stdd = stdd;
            //convert from Collection to List
            this.entriesNames = new List<string>();
            Dictionary<string, bool>.KeyCollection col = stdd.entries.Keys;
            foreach (string name in col) {
                this.entriesNames.Add(name);
            }

            Commons();

        }
Пример #2
0
        public SpectreToDo(string text, SpectreToDoData stdd) : base() {
            this.stdd = stdd;

            this.Dock = DockStyle.Fill;
            this.Anchor = (AnchorStyles.Top | AnchorStyles.Right | AnchorStyles.Bottom | AnchorStyles.Left);
            this.Location = new Point(0, 0);
            this.Size = new Size(0, 25);
            this.Text = text;
            this.TextAlign = ContentAlignment.MiddleLeft;
            this.FlatStyle = FlatStyle.Flat;
            this.FlatAppearance.BorderSize = 0;
            this.Margin = new Padding(0);
            this.FlatAppearance.MouseOverBackColor = Color.LightGray;
            this.FlatAppearance.MouseDownBackColor = Color.Transparent;
            this.ForeColor = Color.Gray;
            this.Font = new Font("Century Gothic", 12);
            this.MouseClick += new MouseEventHandler(entryClicked);

            //check if the entry is set a done
            try {
                if (this.stdd.IsDone(this.Text)) {
                    this.Font = new Font("Century Gothic", 12, FontStyle.Strikeout);
                }
            } catch (Exception) { }

        }
Пример #3
0
        public SpectreToDoResult(string header, List<string> entries) : base(header, "", "I am a happy ToDo List") {

            this.stdd = new SpectreToDoData(header, entries);
            this.entriesNames = entries;

            Commons();

        }