XG_TitleView.h 623 B

12345678910111213141516171819202122232425262728
  1. //
  2. // XG_TitleView.h
  3. // MyApp
  4. //
  5. // Created by huxinguang on 2018/9/11.
  6. // Copyright © 2018年 huxinguang. All rights reserved.
  7. //
  8. #import <UIKit/UIKit.h>
  9. typedef NS_ENUM(NSInteger,XG_TitleViewStyle) {
  10. XG_TitleViewStyleNormal,
  11. XG_TitleViewStyleSegement
  12. };
  13. @protocol XG_TitleViewDelegate<NSObject>
  14. - (void)onTitleClick;
  15. @end
  16. @interface XG_TitleView : UIView
  17. @property (nonatomic, weak) id<XG_TitleViewDelegate> delegate;
  18. @property (nonatomic, strong) UILabel *titleLabel;
  19. @property (nonatomic, copy) NSString *titleString;
  20. - (instancetype)initWithFrame:(CGRect)frame style:(XG_TitleViewStyle)style;
  21. @end