Function unicode_line_stacker::bits_to_char[][src]

pub fn bits_to_char(bits: u32) -> char

Convert a bitset to a line-drawing char.

This crate’s representation of each line-drawing char is a u32 representing a bitset: starting from least significant bit, the bits represent up, right, down, left, in that order.

Examples

assert_eq!('┤', unicode_line_stacker::bits_to_char(0b1101));

Panics

Panics if bits >= 16.