Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1386)

Unified Diff: packages/charcode/README.md

Issue 1400473008: Roll Observatory packages and add a roll script (Closed) Base URL: git@github.com:dart-lang/observatory_pub_packages.git@master
Patch Set: Created 5 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « packages/charcode/LICENSE ('k') | packages/charcode/lib/ascii.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: packages/charcode/README.md
diff --git a/packages/charcode/README.md b/packages/charcode/README.md
new file mode 100644
index 0000000000000000000000000000000000000000..35c4818656b588c5e093b579493495570138a6f4
--- /dev/null
+++ b/packages/charcode/README.md
@@ -0,0 +1,51 @@
+Character code constants.
+
+These libraries define symbolic names for some character codes.
+
+This is not an official Goggle package, and is not supported by Google.
+
+## Using
+
+Import either one of the libraries:
+
+ import "package:charcode/ascii.dart"
+ import "package:charcode/html_entity.dart"
+
+or import both libraries using the `charcode.dart` library:
+
+ import "package:charcode/charcode.dart"
+
+# Naming
+
+The character names are preceded by a `$` to avoid conflicting with other
+variables due to the short and common names (for example "$i").
+
+The characters that are valid in a Dart identifier directly follow the `$`.
+Examples: `$_`, `$a`, `$B` and `$3`. Other characters are given symbolic names.
+
+The names of letters are lower-case for lower-case letters, and mixed- or
+upper-case for upper-case letters. The names of symbols are all lower-case,
+and omit suffixes like "sign", "symbol" and "mark". E
+xamples: `$plus`, `$exclamation`
+
+The `ascii.dart` library defines a symbolic name for each ASCII character.
+For some chraceters, it has more than one name. For example the common `$tab`
+and the official `$ht` for the horisontal tab.
+
+The `html_entity.dart` library defines a constant for each HTML 4.01 character
+entity, using the standard entity abbreviation, incluing its case.
+Examples: `$nbsp` for `&nbps;`, `$aring` for the lower-case `å`
+and `$Aring` for the upper-case `Å`.
+
+The HTML entities includes all characters in the Latin-1 code page, greek
+letters and some mathematical symbols.
+
+The `charcode.dart` library just exports both `ascii.dart` and
+`html_entity.dart`.
+
+# Rationale
+
+The Dart language doesn't have character literals. If that ever happens, this
+library will be irrelevant. Until then, this library can be used for the most
+common characters.
+See [http://dartbug.com/4415](request for character literals).
« no previous file with comments | « packages/charcode/LICENSE ('k') | packages/charcode/lib/ascii.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698