File tree Expand file tree Collapse file tree 1 file changed +7
-7
lines changed
Expand file tree Collapse file tree 1 file changed +7
-7
lines changed Original file line number Diff line number Diff line change @@ -7,42 +7,42 @@ pub struct RenderOpts {
77 /// width of each indent
88 pub indent_width : usize ,
99 /// current indent depth
10- pub ident_count : usize ,
10+ pub indent_count : usize ,
1111}
1212
1313impl Default for RenderOpts {
1414 fn default ( ) -> Self {
1515 Self {
1616 indent_width : 2 ,
17- ident_count : 0 ,
17+ indent_count : 0 ,
1818 }
1919 }
2020}
2121
2222impl RenderOpts {
2323 /// Indent
2424 ///
25- /// This will clone Self, and increment self.ident_count .
25+ /// This will clone Self, and increment self.indent_count .
2626 pub fn indent ( & self ) -> Self {
2727 Self {
2828 indent_width : self . indent_width ,
29- ident_count : self . ident_count + 1 ,
29+ indent_count : self . indent_count + 1 ,
3030 }
3131 }
3232
3333 /// Outdent
3434 ///
35- /// This will clone Self, and decrement self.ident_count .
35+ /// This will clone Self, and decrement self.indent_count .
3636 pub fn outdent ( & self ) -> Self {
3737 Self {
3838 indent_width : self . indent_width ,
39- ident_count : self . ident_count - 1 ,
39+ indent_count : self . indent_count - 1 ,
4040 }
4141 }
4242
4343 /// Get the actual characters
4444 pub fn spaces ( & self ) -> String {
45- let space_count = self . indent_width * self . ident_count ;
45+ let space_count = self . indent_width * self . indent_count ;
4646 " " . repeat ( space_count)
4747 }
4848}
You can’t perform that action at this time.
0 commit comments