Legend

Class
Struct
Enum
Interface
Delegate
Constructor
Method
Property
Event
Field

Extension method: string Unindent(this string)

Declaration

public static string Unindent(
    this string str
)

Summary

Removes the overall indentation of the specified string while maintaining the relative indentation of each line.

Parameters

this stringstr String to remove indentation from.

Returns

A string in which every line that isn’t all whitespace has had spaces removed from the beginning equal to the least amount of spaces at the beginning of any line.