IntelliJ IDEA 2016.2 Help

Debug Tool Window. Logcat

The Logcat tab is only available for Android applications (see Debugging with Logcat for details). It displays a log of all processes currently running on the connected device or the emulator.

The logcat functionality is also available from the Android tool window. The only difference is that while the Logcat tab in the Debug tool window shows a log of all processes, in the Android tool window you can filter log messages by a specific process.

Toolbar

Use the toolbar controls and buttons to configure the scope and the presentation of log data, and to navigate through the log.

ItemTooltip and shortcutDescription
Log Level N/A From this drop-down list, select the priority of log messages to be displayed. The available options are:
  • Verbose
  • Debug
  • Info
  • Warn
  • Error
  • Assert
find1.gif FindUse this text box to search through the list of messages. As you type a search string, the messages that match the search pattern are displayed with the matching character strings highlighted. To finalize the search, press Enter. Search patterns are stored in the search history list. To clear the search history, click the clear button.
FiltersN/A From this list, select an existing filter configuration, or create a new one.

A filter configuration is a set of filtering parameters. The use of filter configurations provides more flexible control over the type and amount of log data displayed than just specifying the information type by choosing a message priority in the Log level drop-down list.

  • To display messages related to the selected process, select Show only selected application.
  • If you want full log data to be displayed, select No Filters from the drop-down list.
  • To apply a filter, select it from the drop-down list.
  • To create a new filter configuration, select Edit Filter Configuration. In the Create New Logcat Filter dialog box that opens, click the Add toolbar button add.png and specify the following filtering parameters:
    • Log Tag: use this parameter if you only want messages from a certain system component to be displayed. Type a regular expression to specify the tag that indicates the relevant system component, such as ActivityManager, AudioService, etc., or a user-defined tag. For more details, see Filtering Log Output.
    • Log Message: use this parameter if you only want messages that contain certain elements or character strings to be displayed. Type a regular expression that defines the character string to be detected.
    • Package Name: use this parameter if you only want messages that refer to a specific Java package (class path) to be displayed.
    • PID: use this parameter if you only want messages that refer to a specific process (process ID) to be displayed.
    • Log Level: use this parameter if you only want messages with a certain priority level to be displayed.
  • To update a filter, select Edit Filter Configuration, then in the Create New Logcat Filter dialog that opens select a filter from the list and edit the filter values.

  • To remove a filter configuration from the list, choose Edit Filter Configuration. In the Create New Logcat Filter dialog box that opens, select the filter and click the Delete toolbar button delete.png.
arrowUp Up the Stack Trace
Ctrl+Alt+Up
Click this button to navigate up in the stack trace and have the cursor jump to the corresponding location in the source code.
arrowDown Down the Stack Trace
Ctrl+Alt+Down
Click this button to navigate down in the stack trace and have the cursor jump to the corresponding location in the source code.
icon_softWrap Use Soft Wraps Click this button to toggle the soft wrap mode of the output.
icon_end_of_output.png Scroll to the end Click this button to move the caret to the last line of the console output.
print Print Click this button to print the logs.
clear_all Clear logcat Click this button to remove log data from previous sessions on the selected device.
rerunConsole.png Restart Click this button to restart logging.

See Also

Last modified: 20 July 2016