summaryrefslogtreecommitdiff
path: root/devdocs/elisp/customizing-bitmaps.html
blob: 1b249b529c4d8ee82b92ad18b0de9f20b9901bee (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
 <h4 class="subsection">Customizing Fringe Bitmaps</h4>  <dl> <dt id="define-fringe-bitmap">Function: <strong>define-fringe-bitmap</strong> <em>bitmap bits &amp;optional height width align</em>
</dt> <dd>
<p>This function defines the symbol <var>bitmap</var> as a new fringe bitmap, or replaces an existing bitmap with that name. </p> <p>The argument <var>bits</var> specifies the image to use. It should be either a string or a vector of integers, where each element (an integer) corresponds to one row of the bitmap. Each bit of an integer corresponds to one pixel of the bitmap, where the low bit corresponds to the rightmost pixel of the bitmap. (Note that this order of bits is opposite of the order in XBM images; see <a href="xbm-images">XBM Images</a>.) </p> <p>The height is normally the length of <var>bits</var>. However, you can specify a different height with non-<code>nil</code> <var>height</var>. The width is normally 8, but you can specify a different width with non-<code>nil</code> <var>width</var>. The width must be an integer between 1 and 16. </p> <p>The argument <var>align</var> specifies the positioning of the bitmap relative to the range of rows where it is used; the default is to center the bitmap. The allowed values are <code>top</code>, <code>center</code>, or <code>bottom</code>. </p> <p>The <var>align</var> argument may also be a list <code>(<var>align</var>
<var>periodic</var>)</code> where <var>align</var> is interpreted as described above. If <var>periodic</var> is non-<code>nil</code>, it specifies that the rows in <code>bits</code> should be repeated enough times to reach the specified height. </p>
</dd>
</dl> <dl> <dt id="destroy-fringe-bitmap">Function: <strong>destroy-fringe-bitmap</strong> <em>bitmap</em>
</dt> <dd><p>This function destroys the fringe bitmap identified by <var>bitmap</var>. If <var>bitmap</var> identifies a standard fringe bitmap, it actually restores the standard definition of that bitmap, instead of eliminating it entirely. </p></dd>
</dl> <dl> <dt id="set-fringe-bitmap-face">Function: <strong>set-fringe-bitmap-face</strong> <em>bitmap &amp;optional face</em>
</dt> <dd>
<p>This sets the face for the fringe bitmap <var>bitmap</var> to <var>face</var>. If <var>face</var> is <code>nil</code>, it selects the <code>fringe</code> face. The bitmap’s face controls the color to draw it in. </p> <p><var>face</var> is merged with the <code>fringe</code> face, so normally <var>face</var> should specify only the foreground color. </p>
</dd>
</dl><div class="_attribution">
  <p class="_attribution-p">
    Copyright &copy; 1990-1996, 1998-2022 Free Software Foundation, Inc. <br>Licensed under the GNU GPL license.<br>
    <a href="https://www.gnu.org/software/emacs/manual/html_node/elisp/Customizing-Bitmaps.html" class="_attribution-link">https://www.gnu.org/software/emacs/manual/html_node/elisp/Customizing-Bitmaps.html</a>
  </p>
</div>