utf8ify"

Format text

Use utf8_text_*() functions to format text (using Utf8)

library(utf8ify)
text <- "\nHello World"

cat(
  text,
  utf8_text_bold(text),
  utf8_text_bold2(text),
  utf8_text_italic(text),
  utf8_text_bolditalic(text),
  utf8_text_cursive(text),
  utf8_text_gothic(text),
  utf8_text_circle(text)
)

Not all characters can be formatted. In this example the letter öis not formatted bold (as there is no corresponding Utf8 bold character)

utf8_text_bold("Heute ist ein schöner Tag")

Format number

utf8_number_box(123.45)

Collection

{utf8ify} comes with a collection of Utf8 symbols & emojis. They are structured as a list.

u <- utf8_collection()

fav (favorites)

u$fav |> unlist()

animal

u$animal |> unlist()

celebrate

u$celebrate |> unlist()

clock

u$clock |> unlist()

eat

u$eat |> unlist()

drink

u$drink |> unlist()

list

u$list |> unlist()

office

u$office |> unlist()

person

u$person |> unlist()

Block

Use utf8_block() to show a complete Utf8 block:

utf8_block(from = "0x1F600", to = "0x1F64F", show_names = FALSE)
utf8_block(from = "0x2600", to = "0x26FF", show_names = FALSE)
utf8_block(from = "0x16A0", to = "0x16F0", show_names = FALSE)

Inspect

If you found an Utf8 character on the internet, you can inspect it using utf8_inspect()

utf8_inspect("❤️")

Here you can see, that this heard symbol is a combination of two Utf8 characters.



Try the utf8ify package in your browser

Any scripts or data that you put into this service are public.

utf8ify documentation built on April 3, 2025, 6:20 p.m.