{"id":18270472,"url":"https://github.com/KieranLafferty/KLHorizontalSelect","last_synced_at":"2025-04-05T01:30:38.776Z","repository":{"id":5462960,"uuid":"6658159","full_name":"KieranLafferty/KLHorizontalSelect","owner":"KieranLafferty","description":"A UI Control based on 8tracks home screen section select","archived":false,"fork":false,"pushed_at":"2016-05-01T00:00:28.000Z","size":4217,"stargazers_count":352,"open_issues_count":3,"forks_count":62,"subscribers_count":45,"default_branch":"master","last_synced_at":"2025-03-14T21:15:40.418Z","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":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/KieranLafferty.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}},"created_at":"2012-11-12T18:20:16.000Z","updated_at":"2024-02-15T22:42:25.000Z","dependencies_parsed_at":"2022-09-15T02:40:50.153Z","dependency_job_id":null,"html_url":"https://github.com/KieranLafferty/KLHorizontalSelect","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/KieranLafferty%2FKLHorizontalSelect","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/KieranLafferty%2FKLHorizontalSelect/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/KieranLafferty%2FKLHorizontalSelect/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/KieranLafferty%2FKLHorizontalSelect/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/KieranLafferty","download_url":"https://codeload.github.com/KieranLafferty/KLHorizontalSelect/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247276022,"owners_count":20912285,"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-05T11:38:39.738Z","updated_at":"2025-04-05T01:30:37.502Z","avatar_url":"https://github.com/KieranLafferty.png","language":"Objective-C","readme":"KLHorizontalSelect\n=======\n\n\u003cimg src=\"https://raw.github.com/KieranLafferty/KLHorizontalSelect/master/KLHorizontalSelect/iPhoneScreenshot.png\" width=\"50%\"/\u003e\n\nScroll left and right on the section scroller to make a selection. Inspiration for this project came from 8tracks iPhone application\n\nNote: KLHorizontalSelect is intended for use with portrait orientation on iPhone/iPad/iPod Touch.\n\n[Check out the Demo](http://www.youtube.com/watch?v=uzWZG99SAF0\u0026feature=youtube_gdata_player) *Excuse the graphics glitches and lag due to my slow computer.*\n\n\u003c!-- MacBuildServer Install Button --\u003e\n\u003cdiv class=\"macbuildserver-block\"\u003e\n    \u003ca class=\"macbuildserver-button\" href=\"http://macbuildserver.com/project/github/build/?xcode_project=KLHorizontalSelect.xcodeproj\u0026amp;target=KLHorizontalSelect\u0026amp;repo_url=https%3A%2F%2Fgithub.com%2FKieranLafferty%2FKLHorizontalSelect\u0026amp;build_conf=Release\" target=\"_blank\"\u003e\u003cimg src=\"http://com.macbuildserver.github.s3-website-us-east-1.amazonaws.com/button_up.png\"/\u003e\u003c/a\u003e\u003cbr/\u003e\u003csup\u003e\u003ca href=\"http://macbuildserver.com/github/opensource/\" target=\"_blank\"\u003eby MacBuildServer\u003c/a\u003e\u003c/sup\u003e\n\u003c/div\u003e\n\u003c!-- MacBuildServer Install Button --\u003e\n\n## Installation ##\n\nDrag the included \u003ccode\u003eKLHorizontalSelect.h, KLHorizontalSelect.m\u003c/code\u003e files into your project. Then, include the following frameworks under *Link Binary With Libraries*:\n\n* QuartzCore.framework\n\nInstall via Cocoapods by adding the following line to your podfile\n\n\tpod 'KLHorizontalSelect'\n\n## Usage ##\n\nImport the required file and declare your controller to conform to the KLHorizontalSelect delegate to recieve callbacks\n\n\t#import \"KLHorizontalSelect.h\"\n\t@interface KLViewController : UIViewController \u003cKLHorizontalSelectDelegate\u003e\n\t@property (nonatomic, strong) KLHorizontalSelect* horizontalSelect;\n\t@end\n\nInitialize the control and set the table data with an array of dictionaries (See provided Plist for sample protocol)\n\n\t- (void)viewDidLoad\n\t{\n\t    [super viewDidLoad];\n\t    // Do any additional setup after loading the view.\n\t    [self.navigationController.navigationBar setTintColor:[UIColor colorWithRed:10/255.0 green:37/255.0 blue:70/255.0 alpha:1]];\n    \n\t    //Initialize the informtion to feed the control\n\t    NSString* plistPath = [[NSBundle mainBundle] pathForResource: @\"SectionData\"\n\t                                                          ofType: @\"plist\"];\n\t    // Build the array from the plist\n\t    NSArray* controlData = [[NSArray alloc] initWithContentsOfFile:plistPath];\n    \n\t\t// Do any additional setup after loading the view, typically from a nib.\n\t    self.horizontalSelect = [[KLHorizontalSelect alloc] initWithFrame: self.view.bounds];\n\t    [self.horizontalSelect setTableData: controlData];\n\t    [self.view addSubview: self.horizontalSelect];\n    \n\t}\n\nImplement the optional delegate method to be notified when a new item is selected\n\n\t- (void) horizontalSelect:(id)horizontalSelect didSelectCell:(KLHorizontalSelectCell *)cell {\n\t    NSLog(@\"Selected Cell: %@\", cell.label.text);\n\t}\n\n## Config ##\nThe visual appearance can be tweaked by changing the constants in \u003ccode\u003eKLHorizontalSelect.m\u003c/code\u003e:\n\n\t//Control Properties\n\t#define kDefaultCellWidth 80.0      //The width of each of the items\n\t#define kDefaultCellHeight 90       //Height of the items/control\n\t#define kDefaultGradientTopColor  [UIColor colorWithRed: 242/255.0 green: 243/255.0 blue: 246/255.0 alpha: 1]   //Top Gradient Color\n\t#define kDefaultGradientBottomColor  [UIColor colorWithRed: 197/255.0 green: 201/255.0 blue: 204/255.0 alpha: 1]    //Bottom Gradient Color\n\t#define kDefaultLabelHeight 20.0    //Adjusts the height of the label\n\t#define kDefaultImageHeight 60.0    //Adjusts the height of the image\n\n\t//Arrow properties\n\t#define kHeaderArrowWidth 40.0      //Adjusts the width of the selection arrow\n\t#define kHeaderArrowHeight 15.0     //Adjusts the width of the selection arrow\n\n\t//Shadow properties\n\t#define kDefaultShadowColor [UIColor blackColor]\n\t#define kDefaultShadowOffset CGSizeMake(0.0, 3.0)\n\t#define kDefaultShadowOpacity 0.96\n\n## Contact ##\n\n* [@kieran_lafferty](https://twitter.com/kieran_lafferty) on Twitter\n* [@kieranlafferty](https://github.com/kieranlafferty) on Github\n* \u003ca href=\"mailTo:kieran.lafferty@gmail.com\"\u003ekieran.lafferty [at] gmail [dot] com\u003c/a\u003e\n\n## License ##\n\nCopyright (c) 2012 Kieran Lafferty\n\nPermission is hereby granted, free of charge, to any person obtaining a copy\nof this software and associated documentation files (the \"Software\"), to deal\nin the Software without restriction, including without limitation the rights\nto use, copy, modify, merge, publish, distribute, sublicense, and/or sell\ncopies of the Software, and to permit persons to whom the Software is\nfurnished to do so, subject to the following conditions:\n\nThe above copyright notice and this permission notice shall be included in\nall copies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\nIMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\nFITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\nAUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\nLIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\nOUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\nTHE SOFTWARE.","funding_links":[],"categories":["etc"],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FKieranLafferty%2FKLHorizontalSelect","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FKieranLafferty%2FKLHorizontalSelect","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FKieranLafferty%2FKLHorizontalSelect/lists"}