@@ -7,48 +7,54 @@ import metaconfig.generic.Surface
7
7
/** @param openParenCallSite
8
8
* If true AND bin-packing is true, then call-site arguments won't be aligned
9
9
* by the opening parenthesis. For example, this output will be disallowed
10
- *
11
- * function(a, b, c)
10
+ * {{{
11
+ * function1(a,
12
+ * b,
13
+ * c)
14
+ * }}}
12
15
* @param openParenDefnSite
13
16
* Same as [[openParenCallSite ]], except definition site.
14
17
* @param tokens
15
18
* The tokens to vertically align by. The "owner" is the
16
19
* scala.meta.Tree.getClass.getName of the deepest tree node that "owns" the
17
20
* token to align by.
21
+ * - Examples:
22
+ * {{{
23
+ * align.tokens = ["="] // align = owned by any tree node (not recommended)
18
24
*
19
- * Examples:
20
- *
21
- * align.tokens = ["="] // align = owned by any tree node (not recommended)
22
- *
23
- * align.tokens = [ { code = "=", owner = "Param" } // align = when owned by
24
- * parameter tree nodes ]
25
- *
26
- * Pro tip. if you use for example
27
- *
28
- * preset = defaultWithAlign
29
- *
30
- * and want to add one extra token (for example "|>") to align by, write
31
- *
32
- * align.tokens."+" = [ "|> ]
33
- *
34
- * NOTE. Adding more alignment tokens may potentially decrease the vertical
35
- * alignment in formatted output. Customize at your own risk, I recommend you
36
- * try and stick to the default settings.
25
+ * align.tokens = [
26
+ * { code = "=", owner = "Param" } // align = when owned by parameter tree nodes
27
+ * ]
28
+ * }}}
29
+ * - Pro tip. if you use for example {{{preset = defaultWithAlign}}} and want
30
+ * to add one extra token (for example "|>") to align by, write
31
+ * {{{
32
+ * align.tokens."+" = [ "|> ]
33
+ * }}}
34
+ * - NOTE. Adding more alignment tokens may potentially decrease the vertical
35
+ * alignment in formatted output. Customize at your own risk, I recommend
36
+ * you try and stick to the default settings.
37
37
* @param arrowEnumeratorGenerator
38
38
* If true, aligns by `<-` in for comprehensions.
39
39
* @param openParenCtrlSite
40
40
* If true, aligns by ( in if/while/for. If false, indents by continuation
41
41
* indent at call site.
42
42
* @param tokenCategory
43
43
* Customize which token kinds can align together. By default, only tokens
44
- * with the same `Token.productPrefix` align. To for example align = and <-,
45
- * set the values to: Map("Equals" -> "Assign", "LeftArrow" -> "Assign")
46
- * Note. Requires mixedTokens to be true.
44
+ * with the same `Token.productPrefix` align. For example, to align = and <-,
45
+ * set the values to:
46
+ * {{{
47
+ * Map("Equals" -> "Assign", "LeftArrow" -> "Assign")
48
+ * }}}
49
+ * Note: Requires mixedTokens to be true.
47
50
* @param treeCategory
48
51
* Customize which tree kinds can align together. By default, only trees with
49
- * the same `Tree.productPrefix` align. To for example align Defn.Val and
50
- * Defn.Var, set the values to: Map("Defn.Var" -> "Assign", "Defn.Val" ->
51
- * "Assign") Note. Requires mixedOwners to be true.
52
+ * the same `Tree.productPrefix` align. For example, to align Defn.Val and
53
+ * Defn.Var, set the values to:
54
+ * {{{
55
+ * Map("Defn.Var" -> "Assign", "Defn.Val" -> "Assign")
56
+ * }}}
57
+ * Note. Requires mixedOwners to be true.
52
58
* @param stripMargin
53
59
* If set, indent lines with a strip-margin character in a multiline string
54
60
* constant relative to the opening quotes (or the strip-margin character if
0 commit comments