[hackers] [libgrapheme] Add README and change title and introduction in Makefile and manuals || Laslo Hunhold

From: <git_AT_suckless.org>
Date: Wed, 22 Dec 2021 13:46:58 +0100 (CET)

commit c7021f101ce95bff58157fb32c50d204cf8569b2
Author: Laslo Hunhold <dev_AT_frign.de>
AuthorDate: Wed Dec 22 13:46:07 2021 +0100
Commit: Laslo Hunhold <dev_AT_frign.de>
CommitDate: Wed Dec 22 13:46:07 2021 +0100

    Add README and change title and introduction in Makefile and manuals
    
    Signed-off-by: Laslo Hunhold <dev_AT_frign.de>

diff --git a/Makefile b/Makefile
index aca57a1..f883ab8 100644
--- a/Makefile
+++ b/Makefile
_AT_@ -1,5 +1,5 @@
 # See LICENSE file for copyright and license details
-# libgrapheme - grapheme cluster utility library
+# libgrapheme - unicode string library
 .POSIX:
 
 include config.mk
diff --git a/README b/README
new file mode 100644
index 0000000..3b82a29
--- /dev/null
+++ b/README
_AT_@ -0,0 +1,38 @@
+libgrapheme
+===========
+
+The libgrapheme library provides functions to properly handle Unicode
+strings according to the Unicode specification. Unicode strings are made
+up of user-perceived characters (so-called "grapheme clusters") that are
+made up of one or more Unicode codepoints, which in turn are encoded in
+one or more bytes in an encoding like UTF-8.
+
+Despite the complicated multilevel structure of Unicode strings,
+libgrapheme provides methods to work with them at the byte-level (i.e.
+UTF-8 ‘char’ arrays) while also providing codepoint-level methods.
+
+See libgrapheme(7) to get started and try out the self-contained examples
+given on the manual pages for each function.
+
+Requirements
+------------
+A C99-compiler and POSIX make.
+
+Installation
+------------
+Edit config.mk to match your local setup (usually not necessary, the
+default prefix is /usr/local).
+
+Afterwards enter the following command to build and install libgrapheme
+(if necessary as root):
+
+ make install
+
+Usage
+-----
+Include the header grapheme.h in your code and link against libgrapheme
+with "-lgrapheme" either statically ("-static") or dynamically.
+
+Author
+------
+Laslo Hunhold <dev_AT_frign.de>
diff --git a/man/libgrapheme.7 b/man/libgrapheme.7
index f10797e..2d33112 100644
--- a/man/libgrapheme.7
+++ b/man/libgrapheme.7
_AT_@ -3,17 +3,26 @@
 .Os suckless.org
 .Sh NAME
 .Nm libgrapheme
-.Nd unicode library
+.Nd unicode string library
 .Sh SYNOPSIS
 .In grapheme.h
 .Sh DESCRIPTION
 The
 .Nm
-library provides functions to properly handle user-perceived characters
-.Dq ( grapheme clusters ,
+library provides functions to properly handle Unicode strings according
+to the Unicode specification.
+Unicode strings are made up of user-perceived characters (so-called
+.Dq grapheme clusters ,
 see
 .Sx MOTIVATION )
-according to the Unicode specification.
+that are made up of one or more Unicode codepoints, which in turn
+are encoded in one or more bytes in an encoding like UTF-8.
+.Pp
+Despite this complicated multilevel structure of Unicode strings,
+.Nm
+provides methods to work with them at the byte-level (i.e. UTF-8
+.Sq char
+arrays) while also offering codepoint-level methods.
 .Sh SEE ALSO
 .Xr grapheme_decode_utf8 3 ,
 .Xr grapheme_encode_utf8 3 ,
Received on Wed Dec 22 2021 - 13:46:58 CET

This archive was generated by hypermail 2.3.0 : Wed Dec 22 2021 - 13:48:32 CET