Emoji:   emoji terminal output for Racket
1 Getting Started
2 Emojizing String
emojize
3 Writing
write/  emoji
writeln/  emoji
display/  emoji
displayln/  emoji
print/  emoji
println/  emoji
7.4

Emoji: emoji terminal output for Racket

 (require emoji) package: emoji

This is a simple package for emoji terminal output.

1 Getting Started

You can use emoji aliases to produce emoji characters.

Example:
> (require emoji)
> (displayln (emojize "Hello :cat2:!"))

Hello 🐈!

2 Emojizing String

procedure

(emojize str [#:delimiter delimiter])  string?

  str : string?
  delimiter : (or/c char? string?) = #\:
Returns an emojized string.

Examples:
> (require emoji)
> (emojize "Lost in :tv:")

"Lost in 📺"

> (emojize "This __cyclone__ bring strange loyalties and skies"
           #:delimiter "__")

"This 🌀 bring strange loyalties and skies"

3 Writing

procedure

(write/emoji str [out #:delimiter delimiter])  void?

  str : string?
  out : output-port? = (current-output-port)
  delimiter : (or/c char? string?) = #\:
Similar to write, but supports emoji aliases.

Example:
> (require emoji)
> (write/emoji "Am I just a cat:question:")

"Am I just a cat❓"

procedure

(writeln/emoji str    
  [out    
  #:delimiter delimiter])  void?
  str : string?
  out : output-port? = (current-output-port)
  delimiter : (or/c char? string?) = #\:
Similar to writeln, but supports emoji aliases.

Example:
> (require emoji)
> (writeln/emoji "Am I just a cat:question:")

"Am I just a cat❓"

procedure

(display/emoji str    
  [out    
  #:delimiter delimiter])  void?
  str : string?
  out : output-port? = (current-output-port)
  delimiter : (or/c char? string?) = #\:
Similar to display, but supports emoji aliases.

Example:
> (require emoji)
> (display/emoji "Am I just a cat:question:")

Am I just a cat❓

procedure

(displayln/emoji str    
  [out    
  #:delimiter delimiter])  void?
  str : string?
  out : output-port? = (current-output-port)
  delimiter : (or/c char? string?) = #\:
Similar to displayln, but supports emoji aliases.

Example:
> (require emoji)
> (displayln/emoji "Am I just a cat:question:")

Am I just a cat❓

procedure

(print/emoji str [out #:delimiter delimiter])  void?

  str : string?
  out : output-port? = (current-output-port)
  delimiter : (or/c char? string?) = #\:
Similar to print, but supports emoji aliases.

Example:
> (require emoji)
> (print/emoji "Am I just a cat:question:")

"Am I just a cat❓"

procedure

(println/emoji str    
  [out    
  #:delimiter delimiter])  void?
  str : string?
  out : output-port? = (current-output-port)
  delimiter : (or/c char? string?) = #\:
Similar to println, but supports emoji aliases.

Example:
> (require emoji)
> (println/emoji "Am I just a cat:question:")

"Am I just a cat❓"