public override RmlElementEditor openEditor(Element element, GuiFrameworkUICallback uiCallback, int left, int top)
        {
            elementStyle          = new TextElementStyle(element, true);
            elementStyle.Changed += elementStyle_Changed;
            String rml = DecodeFromHtml(element.InnerRml);

            textEditor       = new ElementTextEditor(rml);
            appearanceEditor = new EditInterfaceEditor("Appearance", elementStyle.getEditInterface(), uiCallback);
            RmlElementEditor editor = RmlElementEditor.openEditor(element, left, top, this);

            editor.addElementEditor(textEditor);
            editor.addElementEditor(appearanceEditor);
            return(editor);
        }
Example #2
0
        public override RmlElementEditor openEditor(Element element, GuiFrameworkUICallback uiCallback, int left, int top)
        {
            elementStyle          = new TextElementStyle(element, true);
            elementStyle.Changed += elementStyle_Changed;
            appearanceEditor      = new EditInterfaceEditor("Appearance", elementStyle.getEditInterface(), uiCallback);

            dataElementEditor = new DataElementEditor(element);
            EditInterface editInterface = dataElementEditor.EditInterface;

            editInterfaceEditor = new EditInterfaceEditor("Data Display Properties", editInterface, uiCallback);
            dataElementEditor.EditInterfaceEditor = editInterfaceEditor;
            RmlElementEditor editor = RmlElementEditor.openEditor(element, left, top, this);

            editor.addElementEditor(editInterfaceEditor);
            editor.addElementEditor(appearanceEditor);

            return(editor);
        }
Example #3
0
        public override RmlElementEditor openEditor(Element element, GuiFrameworkUICallback uiCallback, int left, int top)
        {
            elementStyle          = new TextElementStyle(element, false);
            elementStyle.Changed += elementStyle_Changed;
            String rml = TextElementStrategy.DecodeFromHtml(element.InnerRml);

            textEditor = new ElementTextEditor(rml);
            String actionName = element.GetAttribute("onclick").StringValue;

            if (String.IsNullOrEmpty(actionName))
            {
                actionName = Guid.NewGuid().ToString();
                element.SetAttribute("onclick", actionName);
            }
            SlideAction action = slide.getAction(actionName);

            if (action == null)
            {
                action = ((Func <String, SlideAction>)actionTypeBrowser.DefaultSelection.Value)(actionName);
                slide.addAction(action);
            }

            //Make copy of action, this is really important, a lot of the function of this editor assumes this
            //is copied.
            SlideAction editingAction = CopySaver.Default.copy(action);

            EditInterface editInterface = setupEditInterface(editingAction, slide);

            actionEditor     = new EditInterfaceEditor("Action", editInterface, uiCallback);
            appearanceEditor = new EditInterfaceEditor("Appearance", elementStyle.getEditInterface(), uiCallback);
            RmlElementEditor editor = RmlElementEditor.openEditor(element, left, top, this);

            editor.addElementEditor(textEditor);
            editor.addElementEditor(actionEditor);
            editor.addElementEditor(appearanceEditor);
            return(editor);
        }