Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

High performance UITableViewCell subclass with a customizable badge view on the right

branch: master

Fetching latest commit…

Octocat-spinner-32-eaf2f5

Cannot retrieve the latest commit at this time

Octocat-spinner-32 Sample
Octocat-spinner-32 .gitignore
Octocat-spinner-32 DDBadgeViewCell.h
Octocat-spinner-32 DDBadgeViewCell.m
Octocat-spinner-32 README.markdown
Octocat-spinner-32 screenshot.png
Octocat-spinner-32 screenshot2.png
README.markdown

DDBadgeViewCell for UITableView

DDBadgeViewCell is a UITableViewCell subclass that has a customizable badge view on the right. With fast Quartz 2D path drawing and blending, one can use this with very large data set and still keep great performance when scrolling.

Requirement

  1. iPhone SDK 3.1 or later (Sample project was created in iPhone SDK 4).
  2. QuartzCore.framework should be included in your project.

Usage

Like regular UITableViewCell, you create them in - (UITableViewCell *)tableView:cellForRowAtIndexPath:

DDBadgeViewCell *cell = (DDBadgeViewCell *)[tableView dequeueReusableCellWithIdentifier:CellIdentifier];
if (cell == nil) {
    cell = [[[DDBadgeViewCell alloc] initWithStyle:UITableViewCellStyleDefault reuseIdentifier:CellIdentifier] autorelease];
}

And configure the cell through its properties below:

cell.summary = @"Summary";
cell.detail = @"Detail text goes here";
cell.badgeText = @"Badge Text";
cell.badgeColor = [UIColor orangeColor];
cell.badgeHighlightedColor = [UIColor lightGrayColor];

License

DDBadgeViewCell is released under MIT License.

Something went wrong with that request. Please try again.