diff options
| author | Benjamin J. Culkin <bjculkin@mix.wvu.edu> | 2019-08-13 05:56:40 -0300 |
|---|---|---|
| committer | Benjamin J. Culkin <bjculkin@mix.wvu.edu> | 2019-08-13 05:56:40 -0300 |
| commit | 8b4c2708e3e1ecf93449c8e4552ce576376cf240 (patch) | |
| tree | 514e4703676b58f3c6239a13d283a81b9e0f59e8 /clformat/src/main | |
| parent | c4377d66f77d3a71a73f3d58ad5838c4b990126d (diff) | |
Remove old format code from IndentDirective
Diffstat (limited to 'clformat/src/main')
| -rw-r--r-- | clformat/src/main/java/bjc/utils/ioutils/format/directives/IndentDirective.java | 36 |
1 files changed, 0 insertions, 36 deletions
diff --git a/clformat/src/main/java/bjc/utils/ioutils/format/directives/IndentDirective.java b/clformat/src/main/java/bjc/utils/ioutils/format/directives/IndentDirective.java index 0898cc1..c4c757a 100644 --- a/clformat/src/main/java/bjc/utils/ioutils/format/directives/IndentDirective.java +++ b/clformat/src/main/java/bjc/utils/ioutils/format/directives/IndentDirective.java @@ -18,42 +18,6 @@ public class IndentDirective implements Directive { edt.format(dirParams.toFormatCTX()); } - public void formatF(FormatParameters dirParams) throws IOException { - Tape<Object> itemTape = dirParams.tParams; - - CLModifiers mods = dirParams.getMods(); - CLParameters params = dirParams.getParams(); - - // Dollar mod is indent configuration - if (mods.dollarMod) { - return; - } - - int nIndents = 1; - - if(params.length() >= 1) { - params.mapIndices("count"); - - nIndents = params.getInt(itemTape, "count", "indent count", "I", 1); - } - - boolean dedent = false; - if (nIndents < 0) { - nIndents = -nIndents; - - dedent = true; - } - - if (mods.colonMod) { - if (dedent) dirParams.rw.dedent(nIndents); - else dirParams.rw.indent(nIndents); - } else { - if (dedent) throw new IllegalArgumentException("Cannot have negative indent level"); - - dirParams.rw.setLevel(nIndents); - } - } - @Override public Edict compile(CompileContext compCTX) { CLParameters params = compCTX.decr.parameters; |
