{"id":18338447,"url":"https://github.com/crowd-studio/circulartimer","last_synced_at":"2025-10-18T06:38:42.223Z","repository":{"id":6496157,"uuid":"7736598","full_name":"crowd-studio/circulartimer","owner":"crowd-studio","description":"Objective-C custom class that creates a circular timer for iOS.","archived":false,"fork":false,"pushed_at":"2016-10-28T07:54:29.000Z","size":94,"stargazers_count":105,"open_issues_count":2,"forks_count":25,"subscribers_count":9,"default_branch":"master","last_synced_at":"2025-03-21T17:56:34.936Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Objective-C","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/crowd-studio.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2013-01-21T17:14:50.000Z","updated_at":"2024-12-18T11:57:13.000Z","dependencies_parsed_at":"2022-09-13T11:21:36.251Z","dependency_job_id":null,"html_url":"https://github.com/crowd-studio/circulartimer","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/crowd-studio%2Fcirculartimer","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/crowd-studio%2Fcirculartimer/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/crowd-studio%2Fcirculartimer/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/crowd-studio%2Fcirculartimer/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/crowd-studio","download_url":"https://codeload.github.com/crowd-studio/circulartimer/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247440346,"owners_count":20939221,"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-11-05T20:14:11.367Z","updated_at":"2025-10-18T06:38:37.178Z","avatar_url":"https://github.com/crowd-studio.png","language":"Objective-C","funding_links":[],"categories":[],"sub_categories":[],"readme":"# CircularTimer\n\nCircularTimer is a class that creates a custom circular timer, showing the percentage completed between two dates.\n\n## Installation\n===\n\nDrop the files `CircularTimer.h` and `CircularTimer.m` into your Xcode project.\n\n## Usage\n===\n\nIn your ViewController import the header file `CircularTimer.h`, and create a CircularTimer property to keep a reference:\n\n`@property (nonatomic, strong) CircularTimer *circularTimer;`\n\nThen, to create the object use a code like this:\n\n```\nself.circularTimer = \n[[CircularTimer alloc] initWithPosition:CGPointMake(0.0f, 0.0f)\n                                 radius:radius\n                         internalRadius:internalRadius\n                      circleStrokeColor:circleStrokeColor\n                activeCircleStrokeColor:activeCircleStrokeColor\n                            initialDate:initialDate\n                              finalDate:finalDate\n                          startCallback:^{\n                              //do something\n                          }\n                            endCallback:^{\n                                //do something\n                            }];\n```                              \n\nand add it as subview\n\n```\n[self.view addSubview:self.circularTimer];\n```\n\n## Methods\n===\n\nCreate a CircularTimer using:\n\n```\n- (id)initWithPosition:(CGPoint)position\n                radius:(float)radius\n        internalRadius:(float)internalRadius\n     circleStrokeColor:(UIColor *)circleStrokeColor\nactiveCircleStrokeColor:(UIColor *)activeCircleStrokeColor\n           initialDate:(NSDate *)initialDate\n             finalDate:(NSDate *)finalDate\n         startCallback:(void (^)(void))startBlock\n           endCallback:(void (^)(void))endBlock;       \n```\n\nYou can see the meaning of `radius`, `internalRadius`, `circleStrokeColor` and `activeCircleStrokeColor` in this image:\n\n![image](https://github.com/crowd-studio/circulartimer/blob/master/Assets/circleinfo.png?raw=true)\n\n```\n- (BOOL)isRunning;\n```\nIndicates if the CircularTimer is currently running.\n\n```\n- (BOOL)willRun;\n```\nIndicates if the CircularTimer will run (in other words, if the current time is smaller than the CircularTimer `finalDate`).\n\n```\n- (void)stop;\n```\nStops the CircularTimer.\n\n```\n- (NSTimeInterval)intervalLength;\n```\nReturns the interval between the `initialDate` and the `finalDate`.\n\n```\n- (NSTimeInterval)runningElapsedTime;\n```\nReturns the interval of time elapsed since the CircularTimer started running.\n\n## Demo\n\nYou can find a demo project in this repository. Meanwhile, you can watch a teaser:\n\n[https://vimeo.com/57868337](https://vimeo.com/57868337)\n\n## About us\n===\n\n##### CROWD STUDIO\n\n[@crowdstudio_](http://twitter.com/crowdstudio_)\n\n[http://crowd-studio.com/](http://crowd-studio.com/)\n\n[http://facebook.com/thisiscrowd](http://facebook.com/thisiscrowd)\n\n## Licence\n===\n  \nCopyright (C) 2013 CROWD STUDIO\n\nPermission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the \"Software\"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:\n\nThe above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcrowd-studio%2Fcirculartimer","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcrowd-studio%2Fcirculartimer","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcrowd-studio%2Fcirculartimer/lists"}