pulsar/packages/wrap-guide
2023-03-26 04:05:01 -07:00
..
lib Manual decaf of wrap-guide 2023-03-26 04:05:01 -07:00
spec Bundle wrap-guide 2023-02-07 20:17:52 -08:00
styles Bundle wrap-guide 2023-02-07 20:17:52 -08:00
.gitignore Bundle wrap-guide 2023-02-07 20:17:52 -08:00
package-lock.json Bundle wrap-guide 2023-02-07 20:17:52 -08:00
package.json Fix repository key in every new bundled package 2023-02-07 20:22:23 -08:00
README.md Bundle wrap-guide 2023-02-07 20:17:52 -08:00

Wrap Guide package

The wrap-guide package places a vertical line in each editor at a certain column to guide your formatting, so lines do not exceed a certain width.

By default, the wrap-guide is placed at the value of editor.preferredLineLength config setting. The 80th column is used as the fallback if the config value is unset.

Configuration

You can customize where the column is placed for different file types by opening the Settings View and configuring the "Preferred Line Length" value. If you do not want the guide to show for a particular language, that can be set using scoped configuration. For example, to turn off the guide for GitHub-Flavored Markdown, you can add the following to your config.cson:

'.source.gfm':
  'wrap-guide':
    'enabled': false

It is possible to configure the color and/or width of the line by adding the following CSS/LESS to your styles.less:

atom-text-editor .wrap-guide {
  width: 10px;
  background-color: red;
}

Multiple guide lines are also supported. For example, add the following to your config.cson to create four columns at the indicated positions:

'wrap-guide':
  'columns': [72, 80, 100, 120]

Note: When using multiple guide lines, the right-most guide line functions as your editor.preferredLineLength setting.