https://github.com/maximbilan/ios-frequency-table
iOS Frequency Table
https://github.com/maximbilan/ios-frequency-table
frequency-table ios ios-app objective-c ui ui-components uikit
Last synced: about 2 months ago
JSON representation
iOS Frequency Table
- Host: GitHub
- URL: https://github.com/maximbilan/ios-frequency-table
- Owner: maximbilan
- License: mit
- Created: 2014-01-25T13:26:46.000Z (over 12 years ago)
- Default Branch: master
- Last Pushed: 2018-09-21T13:33:18.000Z (almost 8 years ago)
- Last Synced: 2025-05-29T20:39:58.372Z (about 1 year ago)
- Topics: frequency-table, ios, ios-app, objective-c, ui, ui-components, uikit
- Language: Objective-C
- Homepage:
- Size: 229 KB
- Stars: 3
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
iOS Frequency Table
===================
A frequency simple table control.

## Installation
Add the next source files to your project:
FrequencyTable.h
FrequencyTable.m
## Using
You can add view in the Interface Builder and set a class to FrequencyTable or create in the code:
FrequencyTable *frequencyTable = [[FrequencyTable alloc] initWithPositionWithX:0
withY:0
isWideScreen:YES];
[self.view addSubview:frequencyTable];
For adding table data, you can use the following code:
NSMutableArray *array = [[NSMutableArray alloc] init];
float total = 0.0;
for (NSInteger i = 0; i < 50; ++i) {
FrequencyTableRecord *record = [[FrequencyTableRecord alloc] init];
record.name = [NSString stringWithFormat:@"Item %d", i];
record.value = RAND_FROM_TO(1, 500);
total += record.value;
[array addObject:record];
}
[self.frequencyTable setData:array withTotal:total];