Step through code | Qt Creator Documentation

- Qt Creator Documentation
- Step through code
- Qt Creator 15.0.0

How To

# Step through code

The following table summarizes the functions that you can use to step through the code and examine the changes in variables.

Button | Function | Keyboard Shortcut | Description
--- | --- | --- | ---
| Stop Debugger | Shift+F5 | Stops the debugger.
| Step Over | F10 (Command+Shift+O on macOS) | Steps over the next line inside the function being debugged. It executes the call and moves to the next line to be executed in the function.
| Step Into | F11 (Command+Shift+I on macOS) | Steps into the line that it is currently on. For a function call, goes into the function and is ready to continue.
| Step Out | Shift+F11 (Command+Shift+T on macOS) | Finishes executing the function and exits to the function that it was called from.
| Run to Line | Ctrl+F10 (Shift+F8 on macOS) | Runs to the line that has the cursor. You can also directly jump to a line instead of executing until the end of the line, to avoid a variable getting modified or a function getting called, for example.
| Run to Selected Function | Ctrl+F6 | Runs to the selected function when you are stepping into a nested function.
| Continue | F5 | Resumes application execution at the address where it last stopped.

## Compress steps in GDB

When using GDB as the debugging backend, you can compress several steps into one step for less noisy debugging. For more information, see GDB.

The extended GDB settings have the option to step backwards in code, but this option should be used with care, as it is slow and unstable on the GDB side. For more information, see GDB.

## Step into Frameworks in macOS

In macOS, external libraries are usually built into so-called Frameworks, which may have both release and debug versions of the library. When you run applications on the macOS desktop, the release version of Frameworks is used by default. To step into Frameworks, select the Use debug versions of Frameworks option in the project run settings.

See also How To: Debug, Debugging, Debuggers, Debugger, and Debugger Views.

How To