Exemple #1
0
        public DocumentMenu(IMenuHandler menuHandler)
        {
            var metaCatagory     = new MetaCatagoryProfileGenerator(this.Undo, this.Redo, this.Revert, this.Save);
            var profileGenerator = new DocumentMenuProfileGenerator(metaCatagory);

            this.textScoper = new TextScoper();
            var elementFrameFactory = new ElementFrameFactory();
            var pageProperties      = new PageProperties()
            {
                Width = 550, Height = 750,
            };

            this.elementFactory = new ElementFactory(textScoper, elementFrameFactory, pageProperties);

            //this.elementFactory = new ElementFactory() // TODO
            this.inputProvider = new TextBoxInputInterpreter();
            this.cursor        = new Cursor();

            this.menu = menuHandler.CreateMenu(profileGenerator.GenerateMenuProfile());
            this.SetupDocumentArea(this.menu.GetFrameById(DocumentMenuLabels.DocumentArea) as IFrame);
        }
 public DocumentMenuProfileGenerator(MetaCatagoryProfileGenerator metaCatagory)
 {
     this.metaCatagory = metaCatagory;
 }