Skip to content

Commit 528f245

Browse files
cormulliontecosaur
authored andcommitted
Docs: minor index copyedits, and americanizations
A few minor copy edits, and some Americanizations for consistency.
1 parent 9c015e2 commit 528f245

File tree

1 file changed

+13
-13
lines changed

1 file changed

+13
-13
lines changed

docs/src/index.md

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -12,19 +12,19 @@ in the output, when outputting HTML styling constructs (`<span style="...">`,
1212
etc.) serve a similar purpose, and so on. It is possible to simply insert the
1313
raw styling constructs into the string next to the content itself, but it
1414
quickly becomes apparent that this is not well suited for anything but the most
15-
basic use-cases. Not all terminals support the same ANSI codes, the styling
15+
basic use cases. Not all terminals support the same ANSI codes, the styling
1616
constructs need to be painstakingly removed when calculating the width of
1717
already-styled content, and that's before you even get into handling multiple
1818
output formats.
1919

2020
Instead of leaving this headache to be widely experienced downstream, it is
2121
tackled head-on by the introduction of a special string type
2222
([`AnnotatedString`](@ref Base.AnnotatedString)). This string type wraps any other
23-
[`AbstractString`](@ref) type and allows for formating information to be applied to regions (e.g.
23+
[`AbstractString`](@ref) type and allows for formatting information to be applied to regions (e.g.
2424
characters 1 through to 7 are bold and red).
2525

2626
Regions of a string are styled by applying [`Face`](@ref StyledStrings.Face)s
27-
(think "typeface") to them — a structure that holds styling information . As a
27+
(think "typeface") to them — a structure that holds styling information. As a
2828
convenience, faces in the global faces dictionary (e.g. `shadow`) can just be
2929
named instead of giving the [`Face`](@ref StyledStrings.Face) directly.
3030

@@ -44,7 +44,7 @@ styled"{yellow:hello} {blue:there}"
4444
### The `Face` type
4545

4646
A [`Face`](@ref StyledStrings.Face) specifies details of a typeface that text can be set in. It
47-
covers a set of basic attributes that generalise well across different formats,
47+
covers a set of basic attributes that generalize well across different formats,
4848
namely:
4949

5050
- `font`
@@ -68,7 +68,7 @@ To make referring to particular styles more convenient, there is a global
6868
`Dict{Symbol, Face}` that allows for [`Face`](@ref StyledStrings.Face)s to be
6969
referred to simply by name. Packages can add faces to this dictionary via the
7070
[`addface!`](@ref StyledStrings.addface!) function, and the loaded faces can be
71-
easily [customised](@ref stdlib-styledstrings-face-toml).
71+
easily [customized](@ref stdlib-styledstrings-face-toml).
7272

7373
!!! warning "Appropriate face naming"
7474
Any package registering new faces should ensure that they are prefixed
@@ -80,12 +80,12 @@ faces that are part of the default value of the faces dictionary.
8080

8181
#### [Basic faces](@id stdlib-styledstrings-basic-faces)
8282

83-
Basic faces are intended represent a general idea, that is widely applicable.
83+
Basic faces are intended to represent a general idea that is widely applicable.
8484

8585
For setting some text with a certain attribute, we have the `bold`, `light`,
8686
`italic`, `underline`, `strikethrough`, and `inverse` faces.
8787

88-
There are also named faces for the 16 terminal colours: `black`, `red`, `green`,
88+
There are also named faces for the 16 terminal colors: `black`, `red`, `green`,
8989
`yellow`, `blue`, `magenta`, `cyan`, `white`, `bright_black`/`grey`/`gray`,
9090
`bright_red`, `bright_green`, `bright_blue`, `bright_magenta`, `bright_cyan`,
9191
and `bright_white`.
@@ -95,7 +95,7 @@ selected region, there is the `region` face. Similarly for emphasis and
9595
highlighting the `emphasis` and `highlight` faces are defined. There is also
9696
`code` for code-like text.
9797

98-
For visually indicating the severity of messages the `error`, `warning`,
98+
For visually indicating the severity of messages, the `error`, `warning`,
9999
`success`, `info`, `note`, and `tip` faces are defined.
100100

101101
### [Customisation of faces (`Faces.toml`)](@id stdlib-styledstrings-face-toml)
@@ -124,7 +124,7 @@ like so:
124124
foreground = "white"
125125
```
126126

127-
On initialisation, the `config/faces.toml` file under the first Julia depot (usually `~/.julia`) is loaded.
127+
On initialization, the `config/faces.toml` file under the first Julia depot (usually `~/.julia`) is loaded.
128128

129129
### Applying faces to a `AnnotatedString`
130130

@@ -156,7 +156,7 @@ To ease construction of [`AnnotatedString`](@ref Base.AnnotatedString)s with [`F
156156
the [`styled"..."`](@ref @styled_str) styled string literal allows for the content and
157157
attributes to be easily expressed together via a custom grammar.
158158

159-
Within a [`styled"..."`](@ref @styled_str) literal, curly parenthesis are considered
159+
Within a [`styled"..."`](@ref @styled_str) literal, curly braces are considered
160160
special characters and must be escaped in normal usage (`\{`, `\}`). This allows
161161
them to be used to express annotations with (nestable) `{annotations...:text}`
162162
constructs.
@@ -195,7 +195,7 @@ As above, {code:code} is used for code-like text.
195195
Lastly, we have the 'message severity' faces: {error:error}, {warning:warning},
196196
{success:success}, {info:info}, {note:note}, and {tip:tip}.
197197
198-
Remember that all these faces (and any user or package-defined ones), can
198+
Remember that all these faces (and any user or package-defined ones) can
199199
arbitrarily nest and overlap, {region,tip:like {bold,italic:so}}.")
200200
```
201201

@@ -225,7 +225,7 @@ Documenter doesn't properly represent all the styling above, so I've converted i
225225
Lastly, we have the 'message severity' faces: <span style="color: #ed333b;">error</span>, <span style="color: #e5a509;">warning</span>,
226226
<span style="color: #25a268;">success</span>, <span style="color: #26c6da;">info</span>, <span style="color: #76757a;">note</span>, and <span style="color: #33d079;">tip</span>.
227227
228-
Remember that all these faces (and any user or package-defined ones), can
228+
Remember that all these faces (and any user or package-defined ones) can
229229
arbitrarily nest and overlap, <span style="color: #33d079;background-color: #3a3a3a;">like <span style="font-weight: 700;font-style: italic;">so</span></span>.</pre>
230230
```
231231

@@ -257,7 +257,7 @@ As above, {\color[HTML]{0097a7}code} is used for code-like text.
257257
Lastly, we have the 'message severity' faces: {\color[HTML]{ed333b}error}, {\color[HTML]{e5a509}warning},\\
258258
{\color[HTML]{25a268}success}, {\color[HTML]{26c6da}info}, {\color[HTML]{76757a}note}, and {\color[HTML]{33d079}tip}.
259259
260-
Remember that all these faces (and any user or package-defined ones), can\\
260+
Remember that all these faces (and any user or package-defined ones) can\\
261261
arbitrarily nest and overlap, \colorbox[HTML]{3a3a3a}{\color[HTML]{33d079}like
262262
{\fontseries{b}\fontshape{it}\selectfont so}}.
263263
\endgroup

0 commit comments

Comments
 (0)