<commit_before>//
//  TransparentNavigationBar.swift
//  Pageboy-Example
//
//  Created by <NAME> on 15/02/2017.
//  Copyright © 2017 <NAME>. All rights reserved.
//

import UIKit

class TransparentNavigationBar: UINavigationBar {
    
    private var separatorView: UIView!
    
    override func awakeFromNib() {
        super.awakeFromNib()
        
        self.titleTextAttributes = [NSForegroundColorAttributeName : UIColor.white,
                                    NSFontAttributeName : UIFont.systemFont(ofSize: 18.0, weight: UIFontWeightRegular)]
        self.tintColor = UIColor.white.withAlphaComponent(0.7)
        
        self.setBackgroundImage(UIImage(), for: .default)
        self.shadowImage = UIImage()
        self.isTranslucent = true
        
        let separatorView = UIView()
        separatorView.backgroundColor = UIColor.white.withAlphaComponent(0.5)
        self.addSubview(separatorView)<commit_msg>Add iOS 8 compatibility to example app<commit_after>//
//  TransparentNavigationBar.swift
//  Pageboy-Example
//
//  Created by <NAME> on 15/02/2017.
//  Copyright © 2017 <NAME>. All rights reserved.
//

import UIKit

class TransparentNavigationBar: UINavigationBar {
    
    private var separatorView: UIView!
    
    override func awakeFromNib() {
        super.awakeFromNib()
        
        var titleTextAttributes: [String : Any] = [NSForegroundColorAttributeName : UIColor.white]
        if #available(iOS 8.2, *) {
            titleTextAttributes[NSFontAttributeName] = UIFont.systemFont(ofSize: 18.0, weight: UIFontWeightRegular)
        }
        self.titleTextAttributes = titleTextAttributes
        self.tintColor = UIColor.white.withAlphaComponent(0.7)
        
        self.setBackgroundImage(UIImage(), for: .default)
        self.shadowImage = UIImage()
        self.isTranslucent = true
        
        let separatorView = UIView()
        separatorView.backgroundColor = UIColor.white.withAlphaComponent(0.5)
        self.addSubview(separatorView)
{'fraction_non_alphanumeric': 0.09495252373813093, 'fraction_numerical': 0.02048975512243878, 'mean_word_length': 2.6466302367941714, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 7, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 1, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5007826', 'n_tokens_mistral': 613, 'n_tokens_neox': 577, 'n_words': 115}