Skip to content

Commit

Permalink
Update version, README, help
Browse files Browse the repository at this point in the history
  • Loading branch information
billthefarmer committed Jun 11, 2018
1 parent 5ff8372 commit 7c512f2
Show file tree
Hide file tree
Showing 5 changed files with 44 additions and 4 deletions.
6 changes: 4 additions & 2 deletions README.md
Expand Up @@ -19,9 +19,11 @@ and [here](https://github.com/billthefarmer/diary/releases).
There is a
[help](https://github.com/billthefarmer/diary/blob/master/data/help.md),
a
[test](https://github.com/billthefarmer/diary/blob/master/data/test.md)
and an example
[test](https://github.com/billthefarmer/diary/blob/master/data/test.md),
an example
[styles](https://github.com/billthefarmer/diary/blob/master/data/styles.md)
file and an example
[script](https://github.com/billthefarmer/diary/blob/master/data/script.md)
file, which may be copied in to an entry for reference if required.

### Caution - check diary folder
Expand Down
15 changes: 15 additions & 0 deletions data/help.md
Expand Up @@ -30,6 +30,7 @@ The toolbar icons are, from left to right:
* **Find all** - find all diary entries containing search text
* **Add media** - show a media picker to select media
* **Edit styles** - show an editor to edit the custom styles
* **Edit script** - show an editor to edit custom javascript
* **Settings** - show the settings

Depending on the device and orientation, some items may be on the
Expand Down Expand Up @@ -146,6 +147,20 @@ You may include the built in styles file with an `@import` statement
`@import url("file:///android_asset/styles.css");`, which should be on
the first line.

## Javascript
You may add custom javascript to be loaded into all diary pages by
placing a `script.js` file in the `Diary/js` folder. Use the built in
editor to create a script file. Errors in the script will be logged by
the
[WebView](https://developer.android.com/reference/android/webkit/WebView)
which displays the page. See
[Javascript tutorial](https://www.w3schools.com/js).

If you want to use javascript libraries or write a large script it
might be a good idea to use the Google
[Closure Compiler](https://developers.google.com/closure/compiler) to
check and minimise your code. It will handle multiple input files.

## Settings
* **Use custom calendar** - Use custom calendar that shows diary
entries rather than date picker calendar
Expand Down
8 changes: 8 additions & 0 deletions data/script.md
@@ -0,0 +1,8 @@
## Example javascript

window.onload = function() {
let l = document.querySelectorAll('p');
for (let e of l) {
e.style.backgroundColor = 'gold';
}
}
4 changes: 2 additions & 2 deletions src/main/AndroidManifest.xml
Expand Up @@ -22,8 +22,8 @@
xmlns:tools="http://schemas.android.com/tools"
package="org.billthefarmer.diary"
tools:ignore="GoogleAppIndexingWarning"
android:versionCode="129"
android:versionName="1.29"
android:versionCode="130"
android:versionName="1.30"
android:installLocation="auto">

<uses-sdk
Expand Down
15 changes: 15 additions & 0 deletions src/main/assets/help.md
Expand Up @@ -30,6 +30,7 @@ The toolbar icons are, from left to right:
* **Find all** - find all diary entries containing search text
* **Add media** - show a media picker to select media
* **Edit styles** - show an editor to edit the custom styles
* **Edit script** - show an editor to edit custom javascript
* **Settings** - show the settings

Depending on the device and orientation, some items may be on the
Expand Down Expand Up @@ -146,6 +147,20 @@ You may include the built in styles file with an `@import` statement
`@import url("file:///android_asset/styles.css");`, which should be on
the first line.

## Javascript
You may add custom javascript to be loaded into all diary pages by
placing a `script.js` file in the `Diary/js` folder. Use the built in
editor to create a script file. Errors in the script will be logged by
the
[WebView](https://developer.android.com/reference/android/webkit/WebView)
which displays the page. See
[Javascript tutorial](https://www.w3schools.com/js).

If you want to use javascript libraries or write a large script it
might be a good idea to use the Google
[Closure Compiler](https://developers.google.com/closure/compiler) to
check and minimise your code. It will handle multiple input files.

## Settings
* **Use custom calendar** - Use custom calendar that shows diary
entries rather than date picker calendar
Expand Down

0 comments on commit 7c512f2

Please sign in to comment.