Skip to main content

head

Function head 

Source
pub fn head(
    format: Format,
    encoding: Encoding,
    source: &[u8],
) -> Result<Window, AxError>
Expand description

The first window of a whole version.

A version that fits is given whole. One that does not ends at the last block that fits, so the first screen a reader sees holds no half paragraph; when not even the first block fits, at the last character boundary that does. Blocks are read only in the UTF-8 encodings, whose line endings are the bytes the layout looks for.

ยงErrors

The Encoding::decode refusal, for bytes that are not text in encoding.