Skip to content
This repository has been archived by the owner on Nov 27, 2020. It is now read-only.
/ little-braces Public archive

A Visual Studio editor extension that shrinks lines of C, C++ and C# code that contain only curly braces

License

Notifications You must be signed in to change notification settings

lukesdm/little-braces

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Little Braces

A Visual Studio editor extension that shrinks lines of C, C++ and C# code that contain only curly braces.

UPDATE: An update to the Productivity Power Tools extension added a similar feature for VS 2013. They've called it 'Syntactic Line Compression'.

###Requirements Visual Studio 2010. 2012 should also work, but is untested.

Download/Installation

Download, then double-click/activate the VSIX file in Explorer.

Usage

Once installed, the effect is enabled immediately. Note: lines containing only }; are also shrunk, e.g. object initializers.

By default, the lines are shrunk to 0.3x the standard size. If this isn't satisfactory, you can edit the 'BraceLineScale.txt' file in the extension's install directory - it contains just the scale factor as a decimal. Changes will be applied the next time Visual Studio is started.

Caveats

  • If line numbers are visible, they look a bit messy for the shrunken lines.
  • The same goes for breakpoints on those lines
  • As the lines are shrunken, selecting them is tricker.

Uninstallation

In VS, open the Extension Manager, select Little Braces, then click uninstall. A restart of VS is required.

Development Info

This is a very simple extension. There's just a single 69-line source file. It uses a LineTransformSource.

License

Eclipse Public License v1.0. See license text for details.

About

A Visual Studio editor extension that shrinks lines of C, C++ and C# code that contain only curly braces

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages