Skip to content

Objective C text highlighting library using Levenshtein algorithm. Highlighting search keywords in search results is made easy

Notifications You must be signed in to change notification settings

mjm918/BTextHighlighting

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 

Repository files navigation

BTextHighlighting

Usage

  1. Add the two files in your project

  2. Create a NSMutableAttributedString string :

     NSMutableAttributedString *hl = [[NSMutableAttributedString alloc]initWithString:@"Hello world"];
    
  3. And highlight by passing the substring and the color:

     [hl setColorForText:key withColor:[UIColor redColor]];
    

Available methods:

-(void)setColorForText:(NSString*) textToFind withColor:(UIColor*) color;

About

Objective C text highlighting library using Levenshtein algorithm. Highlighting search keywords in search results is made easy

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published