From 1a2dfd9d8578e6ee0230a909207ae9d51d56e251 Mon Sep 17 00:00:00 2001 From: PoiScript Date: Fri, 28 Jun 2019 16:03:38 +0800 Subject: [PATCH] fix(docs): fix some typo and grammar errors --- README.md | 10 +++++++--- src/lib.rs | 6 +++--- 2 files changed, 10 insertions(+), 6 deletions(-) diff --git a/README.md b/README.md index b26a206..d173c09 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,9 @@ # Orgize +[![Build Status](https://travis-ci.org/PoiScript/orgize.svg?branch=master)](https://travis-ci.org/PoiScript/orgize) +[![Crates.io](https://img.shields.io/crates/v/orgize.svg)](https://crates.io/crates/orgize) +[![Document](https://docs.rs/orgize/badge.svg)](https://docs.rs/orgize) + A Rust library for parsing orgmode files. ## Parse @@ -21,7 +25,7 @@ _Section 2_ ## Iter -`Org::iter` function will return a iteractor of `Event`s, which is +`Org::iter` function will returns an iteractor of `Event`s, which is a simple wrapper of `Element`. ```rust @@ -30,7 +34,7 @@ for event in org.iter() { } ``` -**Note**: whether an element is container or not, it will appears two times in a loop. +**Note**: whether an element is container or not, it will appears twice in one loop. One as `Event::Start(element)`, one as `Event::End(element)`. ## Render html @@ -53,7 +57,7 @@ assert_eq!( ## Render html with custom HtmlHandler -To customize html rending, simply implementing `HtmlHandler` trait and passing +To customize html rendering, simply implementing `HtmlHandler` trait and passing it to the `Org::html` function. The following code demonstrates how to add a id for every headline and return diff --git a/src/lib.rs b/src/lib.rs index 1d71c09..724ee86 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -21,7 +21,7 @@ //! //! # Iter //! -//! [`Org::iter`] function will return a iteractor of [`Event`]s, which is +//! [`Org::iter`] function will returns an iteractor of [`Event`]s, which is //! a simple wrapper of [`Element`]. //! //! [`Org::iter`]: org/struct.Org.html#method.iter @@ -45,7 +45,7 @@ //! } //! ``` //! -//! **Note**: whether an element is container or not, it will appears two times in a loop. +//! **Note**: whether an element is container or not, it will appears twice in one loop. //! One as [`Event::Start(element)`], one as [`Event::End(element)`]. //! //! [`Event::Start(element)`]: iter/enum.Event.html#variant.Start @@ -85,7 +85,7 @@ //! //! # Render html with custom HtmlHandler //! -//! To customize html rending, simply implementing [`HtmlHandler`] trait and passing +//! To customize html rendering, simply implementing [`HtmlHandler`] trait and passing //! it to the [`Org::html`] function. //! //! [`HtmlHandler`]: export/html/trait.HtmlHandler.html