         })
     }
 
-    override func textRectForBounds(bounds:CGRect) -> CGRect {
+    override public func textRectForBounds(bounds:CGRect) -> CGRect {
         var r = super.textRectForBounds(bounds)
         var top = ceil(nameLabel.font.lineHeight)
         r = UIEdgeInsetsInsetRect(r, UIEdgeInsetsMake(top + topMargin + marginForContent, 0.0, -marginForContent, 0.0))
         return CGRectIntegral(r)
     }
 
-    override func editingRectForBounds(bounds:CGRect) -> CGRect {
+    override public func editingRectForBounds(bounds:CGRect) -> CGRect {
         var r = super.editingRectForBounds(bounds)
         var top = ceil(nameLabel.font.lineHeight)
         r = UIEdgeInsetsInsetRect(r, UIEdgeInsetsMake(top + topMargin + marginForContent, 0.0, -marginForContent, 0.0))


    // MARK: Appearance

    override func tintColorDidChange() {
        super.tintColorDidChange()
        nameLabel.textColor = tintColor
    }

    // MARK: Initialize

    required init(coder aDecoder: NSCoder) {
        super.init(coder: aDecoder)
        sharedInit()
    }

    override init(frame: CGRect) {
        super.init(frame: frame)
        sharedInit()
    }


import UIKit

public class NamedTextField: UITextField {

    let nameLabel = UILabel()

    public var nameFont :UIFont = UIFont.systemFontOfSize(12) {
        didSet {
            nameLabel.font = nameFont
            validationLabel.font = nameFont
