Analyzes a journal fine to get the most popular keyboard shortcuts and commands Author: Rod Howarth http://www.rodhowarth.com
Exemplo n.º 1
0
        private void btnStartAnalysis_Click(object sender, EventArgs e)
        {
            KeyboardShortcutAnalyzer analyzer = new KeyboardShortcutAnalyzer(this.txtJournalFile.Text, this.txtShortcutsFile.Text);

            IEnumerable<string> topShortcuts = analyzer.GetTopShortcutsUsed();
            IEnumerable<string> topCommands = analyzer.GetTopRibbonCommandsUsed(this.chkbIncludeContext.Checked);

            string outputMessage = "";
            foreach (string shortcut in topShortcuts)
            {
                outputMessage += shortcut + Environment.NewLine;
            }
            this.txtTopShortcuts.Text = outputMessage;

            outputMessage = "";
            foreach (string shortcut in topCommands)
            {
                outputMessage += shortcut + Environment.NewLine;
            }
            this.txtTopCommands.Text = outputMessage;
        }
Exemplo n.º 2
0
        private void btnStartAnalysis_Click(object sender, EventArgs e)
        {
            KeyboardShortcutAnalyzer analyzer = new KeyboardShortcutAnalyzer(this.txtJournalFile.Text, this.txtShortcutsFile.Text);

            IEnumerable <string> topShortcuts = analyzer.GetTopShortcutsUsed();
            IEnumerable <string> topCommands  = analyzer.GetTopRibbonCommandsUsed(this.chkbIncludeContext.Checked);

            string outputMessage = "";

            foreach (string shortcut in topShortcuts)
            {
                outputMessage += shortcut + Environment.NewLine;
            }
            this.txtTopShortcuts.Text = outputMessage;

            outputMessage = "";
            foreach (string shortcut in topCommands)
            {
                outputMessage += shortcut + Environment.NewLine;
            }
            this.txtTopCommands.Text = outputMessage;
        }