Function: erc-controls-propertize

erc-controls-propertize is a byte-compiled function defined in erc-goodies.el.gz.

Signature

(erc-controls-propertize FROM TO BOLDP ITALICP INVERSEP UNDERLINEP FG BG &optional STR)

Documentation

Prepend properties from IRC control characters between FROM and TO.

If optional argument STR is provided, apply to STR, otherwise prepend properties to a region in the current buffer.

Source Code

;; Defined in /usr/src/emacs/lisp/erc/erc-goodies.el.gz
(defun erc-controls-propertize (from to boldp italicp inversep underlinep fg bg
                                     &optional str)
  "Prepend properties from IRC control characters between FROM and TO.
If optional argument STR is provided, apply to STR, otherwise prepend properties
to a region in the current buffer."
  (font-lock-prepend-text-property
   from
   to
   'font-lock-face
   (append (if boldp
               '(erc-bold-face)
             nil)
           (if italicp
               '(erc-italic-face)
             nil)
           (if inversep
               '(erc-inverse-face)
             nil)
           (if underlinep
               '(erc-underline-face)
             nil)
           (if fg
               (list (erc-get-fg-color-face fg))
             nil)
           (if bg
               (list (erc-get-bg-color-face bg))
             nil))
   str)
  str)