Function: indent-bars--create-stipple-remaps

indent-bars--create-stipple-remaps is a natively compiled function defined in indent-bars.el.

Signature

(indent-bars--create-stipple-remaps W H ROT)

Documentation

Create and store stipple remaps for the given font size and pixel start.

W is the space font width in pixels, H is the corresponding height, and ROT is the number of bits to rotate the pattern start. An entry is created for each active style, for both :main[-styletag] and
:current[-styletag] highlight contexts.

Source Code

;; Defined in /nix/store/zkcdcnmcj3605fj09x584bf58d85brax-emacs-packages-deps/share/emacs/site-lisp/elpa/indent-bars-1.0.1/indent-bars.el
(defun indent-bars--create-stipple-remaps (w h rot)
  "Create and store stipple remaps for the given font size and pixel start.
W is the space font width in pixels, H is the corresponding height, and
ROT is the number of bits to rotate the pattern start.  An entry is
created for each active style, for both :main[-styletag] and
:current[-styletag] highlight contexts."
  (let* ((whr (indent-bars--whr w h rot))
	 (filter `(:window indent-bars-whr ,whr))
	 remap)
    (dolist (s indent-bars--styles)
      ;; Main stipple face
      (when (ibs/stipple-face s)
	(setq remap
	      (plist-put
	       remap (indent-bars--tag ":main%s" s)
	       (face-remap-add-relative
		(ibs/stipple-face s)
		`( :filtered ,filter
		   (:stipple ,(indent-bars--stipple w h rot s)))))))
      ;; Currently highlighted stipple face
      (when (ibs/current-stipple-face s)
	(setq remap
	      (plist-put
	       remap (indent-bars--tag ":current%s" s)
	       (face-remap-add-relative
		(ibs/current-stipple-face s)
		`( :filtered ,filter
		   (:stipple ,(indent-bars--current-depth-stipple w h rot s))))))
	(indent-bars--compute-and-highlight-current-depth 'force)))
    (puthash whr remap indent-bars--stipple-remaps)))