External Tools

You can configure EmEditor to run your favorite external applications via toolbar buttons or keyboard shortcuts. Use this feature to quickly test HTML files in a browser, build your latest C++ program, or easily access other applications.

External tools are displayed on the Tools Toolbar. To customize external tools, right click the Tools Toolbar and select Customize Tools (or go to Tools > External Tools > Customize Tools). Click New to start configuring a new tool.

Let’s see some examples of External Tools configurations.

Suppose you want to use Google to search for a word at cursor or selected text when you are using EmEditor to edit a document. Instead of copying and pasting the text to Google, how about integrating Google search with EmEditor? In External Tools Properties, enter the following command:

http://google.com/search?q=$(CurText)

If you want to customize the external tool icon, enter the file name you sampled the icon from in Icon Path text box. If Icon Path is not specified, EmEditor will use a Hammer icon (as the one used for Associated Program) by default.

You can now search Google for the selected text by clicking Google Search button.

If you are working on HTML/XML documents or CSS documents then you may want to use CSS HTML Validator to validate them. EmEditor can easily invoke CSS HTML Validator with the current document. In External Tools Properties, enter the options as shown below:

  • Command: C:\Program Files (x86)\HTMLValidator160\cmdlineprocessor.exe
    Arguments: -e,(stdout),0,128 "$(Path)"
    Initial Directory: $(Dir)
    Icon Path: (Optional)
    Check Save File and Use Output Bar
    Select None under Input
    Select UTF-8 under Encoding

With EmEditor v16.0.0 or later, you can accept the column number in addition to the line number by specifying the arguments like below:

  • Command: C:\Program Files (x86)\HTMLValidator160\cmdlineprocessor.exe
    Arguments: -e,(stdout),0,128,"%file%(%linenum%:%charnum%): %category2%%msgtext%" "$(Path)"
    Initial Directory: $(Dir)
    Icon Path: (Optional)
    Check Save File and Use Output Bar
    Select None under Input
    Select UTF-8 under Encoding

For more information about EmEditor’s integration with CSS HTML Validator, please refer to:

You can also use an external tool, such as HTML Tidy, to fix and clean up HTML documents in EmEditor. In External tool Properties, specify the entire document as the standard input, and EmEditor replaces the document with the standard output.

  • Command: C:\Program Files (x86)\tidy 5.0.0\bin\tidy.exe
    Arguments:
    Initial Directory:
    Icon Path:
    Check Use Output Bar and Close on Exit
    Select Document under Input
    Select Replace Document under Output and Discard under Standard Error

As you can see, external tools feature allows you to extend EmEditor’s functions. Integrating EmEditor with your favorite programs to make your work more productive!