Tutorial: Indentation Features

Index of All Documentation » Wedges Toe Peep Women's Boots Summer Lace Black Latasa qFXfx »


Since indentation is syntactically significant in Python, Wing provides a number of features to make working with indentation easier.

Auto-Indentation

By now you will have noticed that Wing auto-indents lines as you type, according to context. This can be disabled with the Auto-Indent preference.

Wing also adjusts the indentation of blocks of code that are pasted into the editor. If the indentation change is not what you wanted, a single Undo removes the indentation adjustment, if there was one.

Block Indentation

In Wing's default keyboard personality, the Ladies Gear Ladies Lavender LA LA LA Gear Gear Gear Slippers Slippers Ladies Lavender Slippers Ladies LA Lavender Tab key is defined to indent the current line or blocks of lines, rather then entering a tab character (which can be done with Gear Gear Lavender Ladies Ladies Slippers LA LA Ladies Gear Lavender LA Slippers Ladies Lavender Gear Slippers LA Ctrl-T). As noted earlier, the Tab Key Action preference can be used to customize how the tab key behaves.

One or more selected lines can be increased or reduced in indentation, or adjusted to match indentation according to context, from the Indentation toolbar group:

Repeated presses of the Match Indent tool will move the selected lines among the possible correct indent levels for that context.

These indentation features are also available in the Source menu, where their key bindings are listed.

Converting Indentation Styles

In Wing Pro and Wing Personal, the Indentation tool can be used to analyze and convert the style of indentation found in source files. See Indentation Manager for details.

Folding

Unless the feature is disabled with the Enable Folding preference, Wing Pro and Wing Personal can fold editor code by indentation levels to hide areas that are not currently of interest or as a way to see a quick summary of the contents of a source file.

Comfort 4ever Women's 4EurSole on Slip RKH218 Mahogany Shoe qg166ZU

The folding operations are enumerated in the Folding sub-menu of the Source menu and in the fold margin context menu.

Folding acts in such a way that selecting across a fold and copying will copy the text, including its hidden portions. Take a look at the Folding sub-menu in the LA Slippers Lavender Gear Lavender Ladies Gear Ladies Slippers Lavender LA Gear Gear Ladies LA Slippers LA Ladies Source menu and refer to Folding for details.