mirror of
https://github.com/samuelclay/NewsBlur.git
synced 2025-09-18 21:50:56 +00:00
Fixing font size selector styling.
This commit is contained in:
parent
0482935e48
commit
24048a41e3
4 changed files with 14 additions and 9 deletions
|
@ -78,6 +78,10 @@
|
|||
|
||||
NSUserDefaults *userPreferences = [NSUserDefaults standardUserDefaults];
|
||||
|
||||
[self.fontSizeSegment
|
||||
setTitleTextAttributes:@{NSFontAttributeName:
|
||||
[UIFont fontWithName:@"Helvetica-Bold" size:11.0f]}
|
||||
forState:UIControlStateNormal];
|
||||
if([userPreferences stringForKey:@"feed_list_font_size"]){
|
||||
NSString *fontSize = [userPreferences stringForKey:@"feed_list_font_size"];
|
||||
if ([fontSize isEqualToString:@"xs"]) {
|
||||
|
@ -314,13 +318,12 @@
|
|||
cell.separatorInset = UIEdgeInsetsZero;
|
||||
cell.backgroundColor = UIColorFromRGB(0xffffff);
|
||||
|
||||
self.fontSizeSegment.frame = CGRectMake(8, 4, cell.frame.size.width - 8*2, kMenuOptionHeight - 4*2);
|
||||
self.fontSizeSegment.frame = CGRectMake(8, 7, cell.frame.size.width - 8*2, kMenuOptionHeight - 7*2);
|
||||
[self.fontSizeSegment setTitle:@"XS" forSegmentAtIndex:0];
|
||||
[self.fontSizeSegment setTitle:@"S" forSegmentAtIndex:1];
|
||||
[self.fontSizeSegment setTitle:@"M" forSegmentAtIndex:2];
|
||||
[self.fontSizeSegment setTitle:@"L" forSegmentAtIndex:3];
|
||||
[self.fontSizeSegment setTitle:@"XL" forSegmentAtIndex:4];
|
||||
[self.fontSizeSegment setTintColor:UIColorFromRGB(0x738570)];
|
||||
self.fontSizeSegment.backgroundColor = UIColorFromRGB(0xeeeeee);
|
||||
[self.fontSizeSegment setTitleTextAttributes:@{NSFontAttributeName:[UIFont fontWithName:@"Helvetica-Bold" size:11.0f]} forState:UIControlStateNormal];
|
||||
[self.fontSizeSegment setContentOffset:CGSizeMake(0, 1) forSegmentAtIndex:0];
|
||||
|
|
|
@ -78,6 +78,11 @@
|
|||
|
||||
NSUserDefaults *userPreferences = [NSUserDefaults standardUserDefaults];
|
||||
|
||||
[self.fontSizeSegment
|
||||
setTitleTextAttributes:@{NSFontAttributeName:
|
||||
[UIFont fontWithName:@"Helvetica-Bold" size:11.0f]}
|
||||
forState:UIControlStateNormal];
|
||||
|
||||
if([userPreferences stringForKey:@"feed_list_font_size"]){
|
||||
NSString *fontSize = [userPreferences stringForKey:@"feed_list_font_size"];
|
||||
if ([fontSize isEqualToString:@"xs"]) {
|
||||
|
@ -269,13 +274,12 @@
|
|||
cell.separatorInset = UIEdgeInsetsZero;
|
||||
cell.backgroundColor = UIColorFromRGB(0xffffff);
|
||||
|
||||
self.fontSizeSegment.frame = CGRectMake(8, 4, cell.frame.size.width - 8*2, kMenuOptionHeight - 4*2);
|
||||
self.fontSizeSegment.frame = CGRectMake(8, 7, cell.frame.size.width - 8*2, kMenuOptionHeight - 7*2);
|
||||
[self.fontSizeSegment setTitle:@"XS" forSegmentAtIndex:0];
|
||||
[self.fontSizeSegment setTitle:@"S" forSegmentAtIndex:1];
|
||||
[self.fontSizeSegment setTitle:@"M" forSegmentAtIndex:2];
|
||||
[self.fontSizeSegment setTitle:@"L" forSegmentAtIndex:3];
|
||||
[self.fontSizeSegment setTitle:@"XL" forSegmentAtIndex:4];
|
||||
[self.fontSizeSegment setTintColor:UIColorFromRGB(0x738570)];
|
||||
self.fontSizeSegment.backgroundColor = UIColorFromRGB(0xeeeeee);
|
||||
[self.fontSizeSegment setTitleTextAttributes:@{NSFontAttributeName:[UIFont fontWithName:@"Helvetica-Bold" size:11.0f]} forState:UIControlStateNormal];
|
||||
[self.fontSizeSegment setContentOffset:CGSizeMake(0, 1) forSegmentAtIndex:0];
|
||||
|
|
|
@ -357,13 +357,12 @@
|
|||
cell.separatorInset = UIEdgeInsetsZero;
|
||||
cell.backgroundColor = UIColorFromRGB(0xffffff);
|
||||
|
||||
self.fontSizeSegment.frame = CGRectMake(8, 4, cell.frame.size.width - 8*2, kMenuOptionHeight - 4*2);
|
||||
self.fontSizeSegment.frame = CGRectMake(8, 7, cell.frame.size.width - 8*2, kMenuOptionHeight - 7*2);
|
||||
[self.fontSizeSegment setTitle:@"XS" forSegmentAtIndex:0];
|
||||
[self.fontSizeSegment setTitle:@"S" forSegmentAtIndex:1];
|
||||
[self.fontSizeSegment setTitle:@"M" forSegmentAtIndex:2];
|
||||
[self.fontSizeSegment setTitle:@"L" forSegmentAtIndex:3];
|
||||
[self.fontSizeSegment setTitle:@"XL" forSegmentAtIndex:4];
|
||||
[self.fontSizeSegment setTintColor:UIColorFromRGB(0x738570)];
|
||||
self.fontSizeSegment.backgroundColor = UIColorFromRGB(0xeeeeee);
|
||||
[self.fontSizeSegment setTitleTextAttributes:@{NSFontAttributeName:[UIFont fontWithName:@"Helvetica-Bold" size:11.0f]} forState:UIControlStateNormal];
|
||||
[self.fontSizeSegment setContentOffset:CGSizeMake(0, 1) forSegmentAtIndex:0];
|
||||
|
@ -384,13 +383,12 @@
|
|||
cell.separatorInset = UIEdgeInsetsZero;
|
||||
cell.backgroundColor = UIColorFromRGB(0xffffff);
|
||||
|
||||
self.lineSpacingSegment.frame = CGRectMake(8, 4, cell.frame.size.width - 8*2, kMenuOptionHeight - 4*2);
|
||||
self.lineSpacingSegment.frame = CGRectMake(8, 7, cell.frame.size.width - 8*2, kMenuOptionHeight - 7*2);
|
||||
[self.lineSpacingSegment setImage:[UIImage imageNamed:@"line_spacing_xs"] forSegmentAtIndex:0];
|
||||
[self.lineSpacingSegment setImage:[UIImage imageNamed:@"line_spacing_s"] forSegmentAtIndex:1];
|
||||
[self.lineSpacingSegment setImage:[UIImage imageNamed:@"line_spacing_m"] forSegmentAtIndex:2];
|
||||
[self.lineSpacingSegment setImage:[UIImage imageNamed:@"line_spacing_l"] forSegmentAtIndex:3];
|
||||
[self.lineSpacingSegment setImage:[UIImage imageNamed:@"line_spacing_xl"] forSegmentAtIndex:4];
|
||||
[self.lineSpacingSegment setTintColor:UIColorFromRGB(0x738570)];
|
||||
self.lineSpacingSegment.backgroundColor = UIColorFromRGB(0xeeeeee);
|
||||
|
||||
[cell addSubview:self.lineSpacingSegment];
|
||||
|
|
|
@ -821,7 +821,7 @@ static UIFont *userLabelFont;
|
|||
[self.appDelegate.feedsMenuViewController view];
|
||||
NSInteger menuCount = [self.appDelegate.feedsMenuViewController.menuOptions count];
|
||||
|
||||
[self.appDelegate showPopoverWithViewController:self.appDelegate.feedsMenuViewController contentSize:CGSizeMake(220, 38 * (menuCount + 2)) barButtonItem:self.settingsBarButton];
|
||||
[self.appDelegate showPopoverWithViewController:self.appDelegate.feedsMenuViewController contentSize:CGSizeMake(250, 38 * (menuCount + 2)) barButtonItem:self.settingsBarButton];
|
||||
}
|
||||
|
||||
- (IBAction)showInteractionsPopover:(id)sender {
|
||||
|
|
Loading…
Add table
Reference in a new issue