title: How to set delete icon instead of Delete text for editing table view mode in iOS?
body: <p>I have added a table view using XIB, by default i am getting Delete text after swiping on my custom table view cell, that text title we can change using method. I don't want to use "SWTableViewCell" source code. how can i replace Delete title from any icon image as i have mention in below image :</p>
  
  <p><img src="https://i.stack.imgur.com/srCC1.png" alt="enter image description here"></p>
  
  <p>I have tried with custom editingAccessoryView.</p>
  
  <p>here is the code (in table cellForRowAtIndexPath):</p>
  
  <pre><code>   UIView *editingCategoryAccessoryView = [[UIView alloc] initWithFrame:CGRectMake(0,0,320,80)];
      editingCategoryAccessoryView.backgroundColor = [UIColor colorWithPatternImage:[UIImage imageNamed:@"cell_highlighted.png"]];
  
      UIButton *deleteButton = [UIButton buttonWithType:UIButtonTypeRoundedRect];
      deleteButton.backgroundColor = [UIColor clearColor];
  
      NSMutableAttributedString *attributedString1 = [[NSMutableAttributedString alloc] initWithString:@"DELETE"];
  
      [attributedString1 addAttribute:NSKernAttributeName
                               value:@(1.5)
                               range:NSMakeRange(0, [@"DELETE" length])];
  
      deleteButton.contentHorizontalAlignment = UIControlContentHorizontalAlignmentLeft;
      UIColor *btnTextColor = [UIColor whiteColor];
  
      // Set up attributes
      NSDictionary *btnAttrs = [NSDictionary dictionaryWithObjectsAndKeys:
                                [UIFont fontWithName:@"Cabin-Bold" size:17.0f], NSFontAttributeName,
                                btnTextColor, NSForegroundColorAttributeName,
                                nil, NSKernAttributeName, nil];
  
      [attributedString1 setAttributes:btnAttrs
                              range:NSMakeRange(0, attributedString1.length)];
  
      [attributedString1 addAttribute:NSKernAttributeName
                                value:@(1.5)
                                range:NSMakeRange(0, [@"DELETE" length])];
  
      [deleteButton setAttributedTitle:attributedString1 forState:UIControlStateNormal];
  
  
      [deleteButton setFrame:cell.frame];
      [deleteButton setTag:indexPath.row];
      [deleteButton addTarget:self action:@selector(removeCategoryClicked:) forControlEvents:UIControlEventTouchUpInside];
  
     // UIImageView
  
      UIImageView *ivDeleteIcon = [[UIImageView alloc] initWithFrame:CGRectMake(21, 31, 13, 15)];
      ivDeleteIcon.image = [UIImage imageNamed:@"Delete-White.png"];
      ivDeleteIcon.highlightedImage = [UIImage imageNamed:@"Delete-Grey.png"];
      [editingCategoryAccessoryView addSubview:ivDeleteIcon];
      [editingCategoryAccessoryView addSubview:deleteButton];
  
      cell.editingAccessoryView = editingCategoryAccessoryView;
  
  
  // Override to support conditional editing of the table view.
  - (BOOL)tableView:(UITableView *)tableView canEditRowAtIndexPath:(NSIndexPath *)indexPath
  {
      // Return NO if you do not want the specified item to be editable.
      return YES; //YES here makes a red delete button appear when I swipe
  }
  
  - (void)setEditing:(BOOL)editing animated:(BOOL)animated {
      if (editing)
          editingFromEditButton = YES;
      [super setEditing:(BOOL)editing animated:(BOOL)animated];
      editingFromEditButton = NO;
      // Other code you may want at this point...
  }
  
  - (UITableViewCellEditingStyle)tableView:(UITableView *)tableView editingStyleForRowAtIndexPath:(NSIndexPath *)indexPath
  {
      if (editingFromEditButton){
          //editCell = YES;
          return UITableViewCellEditingStyleNone;
      }
      // Otherwise, we are at swipe to delete
      [[tableView cellForRowAtIndexPath:indexPath] setEditing:YES animated:YES];
  
      return UITableViewCellEditingStyleNone;
  }
  
  // Override to support editing the table view.
  - (void)tableView:(UITableView *)tableView commitEditingStyle:(UITableViewCellEditingStyle)editingStyle forRowAtIndexPath:(NSIndexPath *)indexPath
  {
      if (editingStyle == UITableViewCellEditingStyleDelete) {
          // Delete the row from the data source
           [tableView deleteRowsAtIndexPaths:[NSArray arrayWithObject:indexPath] withRowAnimation:UITableViewRowAnimationFade];
      }
      else if (editingStyle == UITableViewCellEditingStyleInsert) {
          // Create a new instance of the appropriate class, insert it into the array, and add a new row to the table view
      }
  }
  </code></pre>
  
  <p>Above code is working fine, but only it's not getting dismissed properly.
  Please help me to achieve this. Thanks!</p>