public void configureGui()
        {
            result_Panel.visible(false);
            executeButton.enabled(false);

            commandsToExecute.textEditor().showInvalidLines(false);

            swapGeneratedCodeViewMode();                // make it not visible by default

            executeButton.onClick(execute);
            commandsToExecute.onTextChanged(onTextChanged);

            commandsToExecute.editor().vScroolBar_Enabled(false);
            commandsToExecute.editor().hScroolBar_Enabled(false);
            commandsToExecute.set_ColorsForCSharp();

            commandsToExecute.allowCompile(false);
            sourceCodeViewer.allowCompile(false);

            sourceCodeViewer.astDetails(false);
            commandsToExecute.astDetails(false);

            //remove original ContextMenu and add new one
            sourceCodeViewer.textEditorControl().remove_ContextMenu();
            var contextMenu = commandsToExecute.textEditorControl().add_ContextMenu();

            commandsToExecute.textArea().KeyUp           += (sender, e) => handlePressedKeys(e);
            commandsToExecute.textArea().KeyEventHandler += handleKeyEventHandler;

            contextMenu.add_MenuItem("current source code")
            .add_MenuItem("compile", (menuitem) => compile())
            .add_MenuItem("copy to clipboard", (menuitem) => currentCode().toClipboard())
            .add_MenuItem("save", (menuitem) => saveScript())
            .add_MenuItem("save As", (menuitem) => saveAsScript())
            .add_MenuItem("what is the current loaded filename", (menuitem) => "The path of the currently loaded file is: {0}".info(currentSourceCodeFilePath()))
            .add_MenuItem("force compilation", (menuitem) => forceCompilation())
            .add_MenuItem("replace with generated source code", (menuitem) => replaceMainCodeWithGeneratedSource())
            .add_MenuItem("show/hide generated source code", (menuitem) => swapGeneratedCodeViewMode())
            .add_MenuItem("-------------------------------")
            .add_MenuItem("clear AssembliesCheckedIfExists list", (menuitem) => O2GitHub.clear_AssembliesCheckedIfExists())
            .add_MenuItem("clear CachedCompiledAssemblies list", (menuitem) => CompileEngine.clearCompilationCache())
            .add_MenuItem("clear LocalScriptFileMappings list", (menuitem) => CompileEngine.clearLocalScriptFileMappings())
            .add_MenuItem("clear CompilationPathMappings list", (menuitem) => CompileEngine.clearCompilationPathMappings());

            contextMenu.add_MenuItem("selected text")
            .add_MenuItem("cut", () => commandsToExecute.editor().clipboard_Cut())
            .add_MenuItem("copy", () => commandsToExecute.editor().clipboard_Copy())
            .add_MenuItem("paste", () => commandsToExecute.editor().clipboard_Paste())
            .add_MenuItem("(if a local file) open selected text in code Editor", () => openSelectedTextInCodeEditor());
            contextMenu.add_MenuItem("execution options")
            .add_MenuItem("execute", (menuitem) => execute())
            .add_MenuItem("enable /disable Execute on compile", (menuitem) => ExecuteOnCompile = !ExecuteOnCompile)
            .add_MenuItem("enable /disable Execute on enter", (menuitem) => ExecuteOnEnter     = !ExecuteOnEnter)
            .add_MenuItem("disable / enabled Auto compile on code change", (menuitem) => AutoCompileOnCodeChange = !AutoCompileOnCodeChange);
            contextMenu.add_MenuItem("auto saved scripts")
            .add_MenuItem("show auto saved scripts", (menuitem) => showAutoSavedScripts())
            .add_MenuItem("enable / disable Auto Save on compile success", (menuitem) => AutoSaveOnCompileSuccess = !AutoSaveOnCompileSuccess);
            contextMenu.add_MenuItem("code complete")
            .add_MenuItem("enable Code Complete", (menuitem) => commandsToExecute.enableCodeComplete())
            .add_MenuItem("enable /disabled 'Only Show Code Complete Results From O2 Namespace'", (menuitem) => enableDisableFullCodeComplete());
            contextMenu.add_MenuItem("code snippets (helper)")
            .add_MenuItem("when compiling: Dont use Cached Assembly if available", (menuitem) => insertCodeSnipptet(menuitem.Text))
            .add_MenuItem("when compiling: remove all auto references to O2 scripts and dlls (same as next two options)", (menuitem) => insertCodeSnipptet(menuitem.Text))
            //.add_MenuItem("when compiling: don't include extra cs file (with extension methods)", (menuitem) => insertCodeSnipptet(menuitem.Text))
            .add_MenuItem("when compiling, only add referenced assemblies", (menuitem) => insertCodeSnipptet(menuitem.Text))
            .add_MenuItem("when compiling, set InvocationParameters to dynamic", (menuitem) => insertCodeSnipptet(menuitem.Text))
            .add_MenuItem("generate debug symbols (and create temp assembly)", (menuitem) => insertCodeSnipptet(menuitem.Text))
            .add_MenuItem("add using statement", (menuitem) => insertCodeSnipptet(menuitem.Text))
            .add_MenuItem("add additional source code (when compile)", (menuitem) => insertCodeSnipptet(menuitem.Text))
            .add_MenuItem("add external reference (dll or exe or GAC assembly)", (menuitem) => insertCodeSnipptet(menuitem.Text))
            .add_MenuItem("run in STA thread (when invoke)", (menuitem) => insertCodeSnipptet(menuitem.Text))
            .add_MenuItem("run in MTA thread (when invoke)", (menuitem) => insertCodeSnipptet(menuitem.Text))
            .add_MenuItem("clear 'AssembliesCheckedIfExists' cache", (menuitem) => insertCodeSnipptet(menuitem.Text));
            contextMenu.add_MenuItem("This Script Editor")
            .add_MenuItem("REPL script this Script", scriptTheCurrentScript)
            .add_MenuItem("REPL script this Script's codeComplete object", scriptTheCurrentScript_CodeComplete);
            contextMenu.add_MenuItem("O2 Scripts")
            //.add_MenuItem("Download/Update O2 Scripts (via http)", O2Scripts.downloadO2Scripts)
            .add_MenuItem("O2 Script: find WinForms Control and REPL it ", () => "Util - Find WinForms Control and REPL it.h2".local().executeH2Script())
            .add_MenuItem("O2 Script: new C# Script Editor", () => open.scriptEditor())
            .add_MenuItem("O2 Script: Find Script to execute", () => "Util - O2 Available scripts.h2".local().executeH2Script())
            .add_MenuItem("O2 Script: open Main O2 GUI", () => "Main O2 Gui.h2".local().executeH2Script())
            .add_MenuItem("O2 Script: open ConsoleOut", () => "Util - ConsoleOut.h2".local().executeH2Script());

            contextMenu.add_MenuItem("package current Script as StandAlone Exe", () => packageCurrentScriptAsStandAloneExe());
            contextMenu.add_MenuItem("show O2 Object Model", () => open.o2ObjectModel());
            contextMenu.add_MenuItem("report a bug to O2 developers", () => ReportBug.showGui(commandsToExecute));
            contextMenu.add_MenuItem("show Log Viewer", (menuitem) => showLogViewer());
        }
/*        private void relauchThisO2ModuleToolStripMenuItem_Click(object sender, EventArgs e)
 *      {
 *          Processes.reLaunchCurrentProcess();
 *      }*/

        private void requestHelpFromO2SupportToolStripMenuItem1_Click(object sender, EventArgs e)
        {
            ReportBug.showGui(this);
        }