Skip to content

Commit

Permalink
Cleanup of Code & Eraser functionality (#23)
Browse files Browse the repository at this point in the history
* Cleaned up Stroke and StrokeSettings. Starting on TouchDrawView

* Removed three internal variables and infer their values

* Removed tempImageView

* Removed some more variables

* Keep track of current stroke in TouchDrawView

* Switched Stroke to be Settings

* Removed internalClear

* Capitalized some words

* Applied linting suggestions

* Removed whitespace

* Added erasing

* Updated for 2.1.0

* some more files 2.1.0

* performance improvements

* Created a function for common functionality

* Added some tests

* Added encoder test

* Added some open source documents

* Updated demo screenshot

* Added swiftlint build step

* Update CODE_OF_CONDUCT.md

* made install_swiftlint executable
  • Loading branch information
dehli authored Jun 29, 2017
1 parent 429c9f2 commit 6f303a4
Show file tree
Hide file tree
Showing 32 changed files with 849 additions and 578 deletions.
7 changes: 6 additions & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,4 +13,9 @@ xcode_scheme: TouchDraw
# Specify the last iOS sdk
xcode_sdk: iphonesimulator

script: set -o pipefail && xcodebuild -workspace $TRAVIS_XCODE_WORKSPACE -scheme $TRAVIS_XCODE_SCHEME -sdk $TRAVIS_XCODE_SDK -destination 'OS=10.1,name=iPhone 6' build test | xcpretty
install:
- ./install_swiftlint.sh

script:
- swiftlint
- set -o pipefail && xcodebuild -workspace $TRAVIS_XCODE_WORKSPACE -scheme $TRAVIS_XCODE_SCHEME -sdk $TRAVIS_XCODE_SDK -destination 'OS=10.1,name=iPhone 6' build test | xcpretty
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
# 2.1.0

- Cleaned up a lot of the library's logic
- Added eraser functionality (`touchDrawView.setColor(nil)`)
- Significant performance improvements!

# 2.0.0

- Upgraded project to Swift 3.0.1 (thanks to @sirnacnud!)
Expand Down
74 changes: 74 additions & 0 deletions CODE_OF_CONDUCT.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,74 @@
# Contributor Covenant Code of Conduct

## Our Pledge

In the interest of fostering an open and welcoming environment, we as
contributors and maintainers pledge to making participation in our project and
our community a harassment-free experience for everyone, regardless of age, body
size, disability, ethnicity, gender identity and expression, level of experience,
nationality, personal appearance, race, religion, or sexual identity and
orientation.

## Our Standards

Examples of behavior that contributes to creating a positive environment
include:

* Using welcoming and inclusive language
* Being respectful of differing viewpoints and experiences
* Gracefully accepting constructive criticism
* Focusing on what is best for the community
* Showing empathy towards other community members

Examples of unacceptable behavior by participants include:

* The use of sexualized language or imagery and unwelcome sexual attention or
advances
* Trolling, insulting/derogatory comments, and personal or political attacks
* Public or private harassment
* Publishing others' private information, such as a physical or electronic
address, without explicit permission
* Other conduct which could reasonably be considered inappropriate in a
professional setting

## Our Responsibilities

Project maintainers are responsible for clarifying the standards of acceptable
behavior and are expected to take appropriate and fair corrective action in
response to any instances of unacceptable behavior.

Project maintainers have the right and responsibility to remove, edit, or
reject comments, commits, code, wiki edits, issues, and other contributions
that are not aligned to this Code of Conduct, or to ban temporarily or
permanently any contributor for other behaviors that they deem inappropriate,
threatening, offensive, or harmful.

## Scope

This Code of Conduct applies both within project spaces and in public spaces
when an individual is representing the project or its community. Examples of
representing a project or community include using an official project e-mail
address, posting via an official social media account, or acting as an appointed
representative at an online or offline event. Representation of a project may be
further defined and clarified by project maintainers.

## Enforcement

Instances of abusive, harassing, or otherwise unacceptable behavior may be
reported by contacting the project team at [email protected]. All
complaints will be reviewed and investigated and will result in a response that
is deemed necessary and appropriate to the circumstances. The project team is
obligated to maintain confidentiality with regard to the reporter of an incident.
Further details of specific enforcement policies may be posted separately.

Project maintainers who do not follow or enforce the Code of Conduct in good
faith may face temporary or permanent repercussions as determined by other
members of the project's leadership.

## Attribution

This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 1.4,
available at [http://contributor-covenant.org/version/1/4][version]

[homepage]: http://contributor-covenant.org
[version]: http://contributor-covenant.org/version/1/4/
25 changes: 25 additions & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
# Contributing to TouchDraw

First off, thank you for wanting to contribute! You rock!

When contributing to this repository, please first discuss the change
you wish to make via issue before making a change.

Please note we have a [Code of Conduct](/CODE_OF_CONDUCT.md), please follow it in all your interactions with the project.

## Example Contributions

1. Report a bug by opening an issue.
2. Request a feature by opening an issue.
3. Discuss a feature you want to implement by opening an issue.
4. Implement a feature, by submitting a pull request.
5. Ask a question, by submitting an issue.

## Pull Request Process

1. Update `README.md` with the changes you made.
2. Add a `master` release to the top of `CHANGELOG.md`
if it doesn't exist.
3. Update `CHANGELOG.md` with the changes you made
under the `master` release (feel free to tag yourself!)
4. Make sure your public functions and variables are documented.
3 changes: 2 additions & 1 deletion Demo/Podfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,5 @@ use_frameworks!

target "TouchDrawDemo" do
pod 'TouchDraw', path: '../'
end
platform :ios, '8.1'
end
10 changes: 5 additions & 5 deletions Demo/Podfile.lock
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
PODS:
- TouchDraw (2.0.0)
- TouchDraw (2.1.0)

DEPENDENCIES:
- TouchDraw (from `../`)

EXTERNAL SOURCES:
TouchDraw:
:path: ../
:path: "../"

SPEC CHECKSUMS:
TouchDraw: bc0e17b0c7739313fda2a0d325a7d3a15cb15c5b
TouchDraw: d09a10cfb210902fff0a047c69ec1c26193bcfb8

PODFILE CHECKSUM: 128c20294ac26c273a7852d89e7a811f030aef02
PODFILE CHECKSUM: f850bd72d12b5fb4f18cad822d3a3481b9ad2931

COCOAPODS: 1.0.1
COCOAPODS: 1.2.1
4 changes: 2 additions & 2 deletions Demo/Pods/Local Podspecs/TouchDraw.podspec.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

10 changes: 5 additions & 5 deletions Demo/Pods/Manifest.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit 6f303a4

Please sign in to comment.