{"id":1173,"url":"https://github.com/IFTTT/jot","last_synced_at":"2025-07-30T20:32:55.276Z","repository":{"id":31882092,"uuid":"35450676","full_name":"IFTTT/jot","owner":"IFTTT","description":"An iOS framework for easily adding drawings and text to images.","archived":false,"fork":false,"pushed_at":"2023-10-11T20:39:45.000Z","size":6194,"stargazers_count":1774,"open_issues_count":14,"forks_count":155,"subscribers_count":53,"default_branch":"main","last_synced_at":"2024-11-29T06:35:22.753Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"http://ifttt.github.io","language":"Objective-C","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/IFTTT.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null}},"created_at":"2015-05-11T21:19:50.000Z","updated_at":"2024-11-07T05:47:30.000Z","dependencies_parsed_at":"2024-01-26T21:07:17.413Z","dependency_job_id":"3bedafb1-7740-4d99-add5-dc2b1c4b0b46","html_url":"https://github.com/IFTTT/jot","commit_stats":{"total_commits":30,"total_committers":4,"mean_commits":7.5,"dds":"0.16666666666666663","last_synced_commit":"2c457eccb240c3e66b70ef346d15c0ca4029450b"},"previous_names":[],"tags_count":6,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/IFTTT%2Fjot","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/IFTTT%2Fjot/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/IFTTT%2Fjot/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/IFTTT%2Fjot/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/IFTTT","download_url":"https://codeload.github.com/IFTTT/jot/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":228187591,"owners_count":17882330,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-01-05T20:15:40.504Z","updated_at":"2024-12-04T20:31:08.112Z","avatar_url":"https://github.com/IFTTT.png","language":"Objective-C","funding_links":[],"categories":["Graphics","Objective-C","UI","Objective-C  Stars 1000以内排名整理"],"sub_categories":["Getting Started","Other free courses","Linter"],"readme":"[![Open Source at IFTTT](http://ifttt.github.io/images/open-source-ifttt.svg)](http://ifttt.github.io)\n\n![jot Logo](./Docs/jotbanner.jpg)\n\n[![CocoaPods Version](https://img.shields.io/cocoapods/v/jot.svg)](http://cocoadocs.org/docsets/jot) [![Build Status](https://travis-ci.org/IFTTT/jot.svg?branch=master)](https://travis-ci.org/IFTTT/jot) [![Coverage Status](https://coveralls.io/repos/IFTTT/jot/badge.svg?branch=master)](https://coveralls.io/r/IFTTT/jot?branch=master)\n\n`jot` is an easy way to add touch-controlled drawings and text to images in your iOS app.\n\n![FastttCamera](./Docs/jot-demo.gif)\n\n## What's `jot` for?\n### Annotating Images\n`jot` is the easiest way to add annotations to images with a touch interface. You can draw arrows or circle important things, as well as add resizable, rotatable text captions, and easily save the notes on top of a image using `drawOnImage:`.\n\n### Whiteboard or Drawing Apps\n`jot` is perfect for quick sketches and notes in your whiteboard or drawing app. It's easy to change the drawing color or stroke width, and when you're done, you can call `renderImageOnColor:` to save the sketch.\n\n### Signatures\n`jot` is a great solution if you need to collect user signatures through a touch interface. Set the `drawingColor` to black, set the state to `JotViewStateDrawing`, and save the signature when the user is done by calling `renderImageOnColor:`.\n\n## Installation\n\n`jot` is available through [CocoaPods](http://cocoapods.org). To install\nit, simply add the following line to your `Podfile`:\n\n```\npod \"jot\"\n```\n\n## Example Project\n\nTo run the example project, clone the repo, and run `pod install` from the `Example` directory.\n\n## Usage\n\nAdd an instance of `JotViewController` as a child of your view controller. Adjust the size and layout of `JotViewController `'s view however you'd like.\n\n```objc\n#import \"ExampleViewController.h\"\n#import \u003cjot/jot.h\u003e\n\n@interface ExampleViewController ()\n@property (nonatomic, strong) JotViewController *jotViewController;\n@end\n\n@implementation ExampleViewController\n\n- (void)viewDidLoad\n{\n    [super viewDidLoad];\n    _jotViewController = [JotViewController new];\n    self.jotViewController.delegate = self;\n    \n    [self addChildViewController:self.jotViewController];\n    [self.view addSubview:self.jotViewController.view];\n    [self.jotViewController didMoveToParentViewController:self];\n    self.jotViewController.view.frame = self.view.frame;\n}\n```\nSwitch between drawing, text manipulation, and text edit mode.\n\n```objc\n- (void)switchToDrawMode\n{\n\tself.jotViewController.state = JotViewStateDrawing;\n}\n\n- (void)switchToTextMode\n{\n\tself.jotViewController.state = JotViewStateText;\n}\n\n- (void)switchToTextEditMode\n{\n\tself.jotViewController.state = JotViewStateEditingText;\n}\n```\nClear the drawing.\n\n```objc\n// Clears text and drawing\n[self.jotViewController clearAll];\n\n// Clears only text\n[self.jotViewController clearText];\n\n// Clears only drawing\n[self.jotViewController clearDrawing];\n```\n\n### Image Output\n\nDraw on a background image.\n\n```objc\n- (UIImage *)imageWithDrawing\n{\n\tUIImage *myImage = self.imageView.image;\n\treturn [self.jotViewController drawOnImage:myImage];\n}\n```\n\nDraw on a color.\n\n```objc\n- (UIImage *)imageOnColorWithDrawing\n{\n\tUIColor *backgroundColor = self.view.backgroundColor;\n\treturn [self.jotViewController renderImageOnColor:backgroundColor];\n}\n```\n\nDraw on a transparent background.\n\n```objc\n- (UIImage *)imageOnColorWithDrawing\n{\n\tUIColor *backgroundColor = self.view.backgroundColor;\n\treturn [self.jotViewController renderImage];\n}\n```\n\n### Basic Configuration\n\n#### Text Settings\n\nChange the font.\n\n```objc\nself.jotViewController.font = [UIFont boldSystemFontOfSize:64.f];\n```\nChange the font size.\n\n```objc\nself.jotViewController.fontSize = 64.f;\n```\nChange the text color.\n\n```objc\nself.jotViewController.textColor = [UIColor redColor];\n```\nSet the initial text string.\n\n```objc\nself.jotViewController.textString = @\"Hello World\";\n```\n\n#### Drawing Settings\n\nChange the drawing stroke color.\n\n```objc\nself.jotViewController.drawingColor = [UIColor magentaColor];\n```\nChange the drawing stroke width.\n\n```objc\nself.jotViewController.drawingStrokeWidth = 10.f;\n```\nMake the drawing stroke a constant width, instead of the default dynamically variable width.\n\n```objc\nself.jotViewController.drawingConstantStrokeWidth = YES;\n```\n\n### Advanced Configuration\n\n#### Text Settings\n\nSet the text to wrap to the width of the view.\n\n```objc\nself.jotViewController.fitOriginalFontSizeToViewWidth = YES;\n```\nSet the text alignment (only applies if text is set to wrap).\n\n```objc\nself.jotViewController.textAlignment = NSTextAlignmentRight;\n```\nSet the text insets (only applies if text is set to wrap).\n\n```objc\nself.jotViewController.initialTextInsets = UIEdgeInsetsMake(10.f, 10.f, 10.f, 10.f);\n```\nSet the text editing insets.\n\n```objc\nself.jotViewController.textEditingInsets = UIEdgeInsetsMake(10.f, 10.f, 10.f, 10.f);\n```\nSet the text edit view to clip text to the text editing insets (instead of fading out with a gradient).\n\n```objc\nself.jotViewController.clipBoundsToEditingInsets = YES;\n```\n\n## Contributors\n\n* [Laura Skelton](https://github.com/lauraskelton), creator.\n\n## License\n\n`jot` is available under the MIT license. See the LICENSE file for more info.\n\nCopyright 2015 IFTTT Inc.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FIFTTT%2Fjot","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FIFTTT%2Fjot","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FIFTTT%2Fjot/lists"}