Variable: indent-bars-zigzag

indent-bars-zigzag is a customizable variable defined in indent-bars.el.

Value

nil

Documentation

The zigzag to apply to the bar pattern.

If non-nil, an alternating zigzag offset will be applied to consecutive groups of identical non-space characters in indent-bars-pattern. Starting from the top of the pattern, positive values will zigzag (right, left, right, ..) and negative values (left, right, left, ...).

Example:

  pattern: " .**."
  width: 0.5
  pad: 0.25
  zigzag: -0.25

would produce a zigzag pattern which differs from the normal bar pattern as follows:

    | | | |
    | .. | =========> |.. |
    | .. | | ..|
    | .. | apply zig- | ..|
    | .. | zag -0.25 |.. |

Note that the pattern will be truncated at both left and right boundaries, so (although this is not required) achieving an equal zigzag left and right requires leaving sufficient padding on each side of the bar; see indent-bars-pad-frac and indent-bars-width-frac. Applies to stipple-based bars only.

Source Code

;; Defined in /nix/store/zkcdcnmcj3605fj09x584bf58d85brax-emacs-packages-deps/share/emacs/site-lisp/elpa/indent-bars-1.0.1/indent-bars.el
(defcustom indent-bars-zigzag nil
  "The zigzag to apply to the bar pattern.
If non-nil, an alternating zigzag offset will be applied to
consecutive groups of identical non-space characters in
`indent-bars-pattern'.  Starting from the top of the pattern,
positive values will zigzag (right, left, right, ..) and negative
values (left, right, left, ...).

Example:

  pattern: \" .**.\"
  width:   0.5
  pad:     0.25
  zigzag: -0.25

would produce a zigzag pattern which differs from the normal
bar pattern as follows:

    |    |            |    |
    | .. | =========> |..  |
    | .. |            |  ..|
    | .. | apply zig- |  ..|
    | .. | zag -0.25  |..  |

Note that the pattern will be truncated at both left and right
boundaries, so (although this is not required) achieving an equal
zigzag left and right requires leaving sufficient padding on each
side of the bar; see `indent-bars-pad-frac' and
`indent-bars-width-frac'.  Applies to stipple-based bars only."
  :type '(choice :tag "Zigzag Options"
		 (const :tag "No Zigzag" :value nil)
		 (float :value 0.1 :tag "Zigzag Fraction"
			:match (lambda (_ val) (and val (<= val 1) (>= val -1)))
			:type-error "Fraction must be between -1 and 1"))
  :group 'indent-bars-style
  :set #'indent-bars--custom-set
  :initialize #'custom-initialize-default)