Left-justified Split Line for IOS 8 UITableView

Source: Internet
Author: User
<span id="Label3"></p><span id="OSC_h4_1"><span id="OSC_h4_1"></span></span>1. Solve the problem of UITableView dividing line distance from the left<p style="margin-top: 0px; margin-bottom: 25px; text-align: justify; word-break: break-word; color: rgb(47, 47, 47); font-family: ‘lucida grande‘, ‘lucida sans unicode‘, lucida, helvetica, ‘Hiragino Sans GB‘, ‘Microsoft YaHei‘, ‘WenQuanYi Micro Hei‘, sans-serif; font-size: 16px; line-height: 21.7600002288818px; white-space: normal; background-color: rgb(255, 255, 255);"><p style="margin-top: 0px; margin-bottom: 25px; text-align: justify; word-break: break-word; color: rgb(47, 47, 47); font-family: ‘lucida grande‘, ‘lucida sans unicode‘, lucida, helvetica, ‘Hiragino Sans GB‘, ‘Microsoft YaHei‘, ‘WenQuanYi Micro Hei‘, sans-serif; font-size: 16px; line-height: 21.7600002288818px; white-space: normal; background-color: rgb(255, 255, 255);">When we use tableview, we find that the left side of the split line is shorter and can usually be solved using setseparatorinset:uiedgeinsetszero. But after upgrading to XCode6, the iOS8 found no effect. Here are the Solutions:</p></p> <p style="margin-top: 0px; margin-bottom: 25px; text-align: justify; word-break: break-word; color: rgb(47, 47, 47); font-family: ‘lucida grande‘, ‘lucida sans unicode‘, lucida, helvetica, ‘Hiragino Sans GB‘, ‘Microsoft YaHei‘, ‘WenQuanYi Micro Hei‘, sans-serif; font-size: 16px; line-height: 21.7600002288818px; white-space: normal; background-color: rgb(255, 255, 255);"><p style="margin-top: 0px; margin-bottom: 25px; text-align: justify; word-break: break-word; color: rgb(47, 47, 47); font-family: ‘lucida grande‘, ‘lucida sans unicode‘, lucida, helvetica, ‘Hiragino Sans GB‘, ‘Microsoft YaHei‘, ‘WenQuanYi Micro Hei‘, sans-serif; font-size: 16px; line-height: 21.7600002288818px; white-space: normal; background-color: rgb(255, 255, 255);"><span style="line-height: 21.7600002288818px;">Viewdidload Methods and</span> <span style="line-height: 21.7600002288818px;">Willdisplaycell</span> <span style="line-height: 21.7600002288818px;">Add the following code:</span></p></p> <pre><pre>If ([self.tableview respondstoselector: @selector (setseparatorinset:)]) {[self.tableview setseparatorinset: uiedgeinsetszero];} If ([self.tableview respondstoselector: @selector (setlayoutmargins:)]) {[self.tableview setlayoutmargins: uiedgeinsetszero];}</pre></pre><p><p>Left-justified Split Line for IOS 8 UITableView</p></p></span>

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.