Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Corrected Spelling errors in README.md #67

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 6 additions & 8 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
# android-ago

This library provides `RelativeTimeTextView`, a custom `TextView` that takes a reference time and always displays the relative time with respect to the reference point, **automatically refreshing the display text as needed**. This is a common pattern seen in several apps like chat apps, social networking, email etc.
This library provides `RelativeTimeTextView`, a custom `TextView` that takes a reference time and always displays the relative time with respect to the reference point, **automatically refreshing the display text as needed**. This is a common pattern seen in several apps like chat apps, social networking, email, etc.

![Here is a screenshot from the sample app][1]

This library can be seen as a wrapper on top of the excellent `android.text.format.DateUtils` class. Note that the library does _not_ expose all the options provided by the `DateUtils` class. I have left out many features because I couldn't decide what would be the best way to achieve the flexibility - dozens of XML attributes? Contributions in this regard are welcome.
This library can be seen as a wrapper on top of the excellent `android.text.format.DateUtils` class. Note that the library does _not_ expose all the options provided by the `DateUtils` class. I have left out many features because I couldn't decide what would be the best way to achieve flexibility - dozens of XML attributes? Contributions in this regard are welcome.

## Why should I use this instead of DateUtils class?

Because this library **automatically refreshes the display text as needed**. It internally uses `DateUtils` class.
Because this library **automatically refreshes the display text as needed**. It internally uses the `DateUtils` class.

Imagine you use `DateUtils` directly without using this library.
- Imagine that it is **9 am** now. You set a reference time of **9:05 am**. Your TextView displays `in 5 mins`
Expand All @@ -29,7 +29,7 @@ Add the following to your build.gradle
compile 'com.github.curioustechizen.android-ago:library:1.4.0'
}

**Important:** v1.3.4 Fixed a major bug (#47). If you are using an older version, please update to at least 1.3.4 now.
**Important:** v1.3.4 Fixed a major bug (#47). If you are using an older version, please update it to at least 1.3.4 now.

### Eclipse+ADT
1. Clone the repo
Expand Down Expand Up @@ -118,12 +118,12 @@ See [here](https://github.com/curioustechizen/android-ago/wiki/Apps-using-androi

The library has been tested on API 11 and above. However, theoretically, it works on API 3 and above since all it uses is [DateUtils#getRelativeTimeSpanString](http://developer.android.com/reference/android/text/format/DateUtils.html#getRelativeTimeSpanString(long, long, long, int)).

The minSdkVersion has been set to 8, however do not expect support from me for API version < 11.
The minSdkVersion has been set to 8, however, do not expect support from me for API version < 11.


# Usage with Data Binding

See `android-ago-sample-databinding` for an example of how to use this library with the Android data binding library. Thanks to @Dev-IL for providing this sample.
See `android-ago-sample-data binding` for an example of how to use this library with the Android data binding library. Thanks to @Dev-IL for providing this sample.


### License
Expand All @@ -145,5 +145,3 @@ See `android-ago-sample-databinding` for an example of how to use this library w


[1]: screenshots/android-ago-sample-screenshot_1.4.0.png "screenshot.png"