#import <UIKit/UIKit.h>

@interface UIFont (APCAppearance)

+ (UIFont*) appRegularFontWithSize: (CGFloat) size;

+ (UIFont*) appMediumFontWithSize: (CGFloat) size;

+ (UIFont*) appLightFontWithSize: (CGFloat) size;

+ (UIFont*) appNavBarTitleFont;

+ (UIFont*) appQuestionLabelFont;

+ (UIFont*) appQuestionOptionFont;

@end

#import "UIFont+APCAppearance.h"

#import "APCAppearanceInfo.h"

#import "APCConstants.h"

@implementation UIFont (APCAppearance)

+ (UIFont*) appRegularFontWithSize: (CGFloat) size

{

return [UIFont fontWithName:[APCAppearanceInfo valueForAppearanceKey:kRegularFontNameKey] size:size];

}

+ (UIFont*) appMediumFontWithSize: (CGFloat) size

{

return [UIFont fontWithName:[APCAppearanceInfo valueForAppearanceKey:kMediumFontNameKey] size:size];

}

+ (UIFont*) appLightFontWithSize: (CGFloat) size

{

return [UIFont fontWithName:[APCAppearanceInfo valueForAppearanceKey:kLightFontNameKey] size:size];

}

+ (UIFont*) appNavBarTitleFont {

return [UIFont appMediumFontWithSize:17.0f];

}

+ (UIFont*) appQuestionLabelFont {

return [UIFont appRegularFontWithSize:17.0f];

}

+ (UIFont*) appQuestionOptionFont {

return [UIFont appRegularFontWithSize:44.0f];

}

@end

UI常用字体定义和继承的实例,ResearchKitCode的更多相关文章

  1. 背水一战 Windows 10 (6) - 控件 UI: 字体的自动继承的特性, Style, ControlTemplate

    [源码下载] 背水一战 Windows 10 (6) - 控件 UI: 字体的自动继承的特性, Style, ControlTemplate 作者:webabcd 介绍背水一战 Windows 10 ...

  2. 控件 UI: 字体的自动继承的特性, Style, ControlTemplate

    字体的自动继承的特性 Style 样式 ControlTemplate 控件模板 示例1.演示字体的自动继承的特性Controls/UI/FontInherit.xaml <Page x:Cla ...

  3. Web中常用字体介绍(转)

    1.在Web编码中,CSS默认应用的Web字体是有限的,虽然在新版本的CSS3,我们可以通过新增的@font-face属性来引入特殊的浏览器加载字体. 浏览器中展示网页文字内容时,文字字体都会按照设计 ...

  4. Web中常用字体介绍

    1.在Web编码中,CSS默认应用的Web字体是有限的,虽然在新版本的CSS3,我们可以通过新增的@font-face属性来引入特殊的浏览器加载字体. 浏览器中展示网页文字内容时,文字字体都会按照设计 ...

  5. 使用 Kendo UI 库实现对象的继承

    使用 Kendo UI 库实现对象的继承 javaScript 也是一种面向对象的开发语言,但和 C++,Java,C# 所不同的是,它的对象不是基于类(Class),而是基于对象原型(ProtoTy ...

  6. iOS之常用宏定义

    下面我为大家提供一些常用的宏定义! 将这些宏定义 加入到.pch使用 再也不用 用一次写一次这么长的程序了 //-------------------获取设备大小------------------- ...

  7. iOS常用宏 定义

    总结了iOS开发过程中的一些常用宏,以后会陆陆续续添加进来. 字符串是否为空 1   #define kStringIsEmpty(str) ([str isKindOfClass:[NSNull c ...

  8. 第18讲- UI常用组件之EditText

    第18讲UI常用组件之EditText 三.文本输入框EditText EditTex类继承自TextView.EditText是接受用户输入信息的最重要控件.在html当中,相当于<input ...

  9. UI常用控件

    UICommonlyUsedControls [UI常用控件] 不需要学习多么深入,但是要知道系统提供的有用的控件. 一.UISwitch(开关) 二.UIActivityIndicatorView( ...

随机推荐

  1. Android 代码设置RelativeLayout元素居中

    RelativeLayout relativeLayout= new RelativeLayout(this); RelativeLayout.LayoutParams rlp=new Relativ ...

  2. 花式GCD

    #include<iostream> #include<stdio.h> #include<string.h> #include<algorithm> ...

  3. Ubuntu bitnami gitlab 安装

    /************************************************************************************** * Ubuntu bit ...

  4. [USACO 2016Dec] Team Building

    [题目链接] https://www.lydsy.com/JudgeOnline/problem.php?id=4742 [算法] 动态规划 用Fi,j,k表示约翰的前i头牛和保罗的前j头牛匹配 , ...

  5. Spring中Bean获取IOC容器服务的方法

    Spring 依赖注入可以让所有的Bean对其IOC容器的存在是没有意识的,甚至可以将容器换成其它的.但实际开发中如果某个Bean对象要用到Spring 容器本身的功能资源,需要意识到IOC容器的存在 ...

  6. .NETFramework:Cache

    ylbtech-.NETFramework:Cache 1.返回顶部 1. #region 程序集 System.Web, Version=4.0.0.0, Culture=neutral, Publ ...

  7. ccflow_005.请假流程-傻瓜表单-审核组件模式

    ccflow_005.请假流程-傻瓜表单-审核组件模式 ' 用审核组件演示各个流程应用 首先设置节点,填写请假单的 表单方案.选择内置傻瓜表单.我们之前创建的表单就回来了. 可以点击下面的设计傻瓜表单 ...

  8. HDU 1713 相遇周期 (最小公倍数)

    题意:... 析:求周期就是这两个分数的最小公倍数,可以先通分,再计算分子的最小倍数. 代码如下: #pragma comment(linker, "/STACK:1024000000,10 ...

  9. 腾讯QQ团队开源分布式后台毫秒服务引擎全解析:引擎架构、RPC、灰度……

    腾讯QQ团队将于12月4日开源一个服务开发运营框架,叫做毫秒服务引擎(Mass Service Engine in Cluster,MSEC),它集RPC.名字发现服务.负载均衡.业务监控.灰度发布. ...

  10. SQL Server 查询入门

    普通查询跟带条件的查询 声明:这里我将用通俗易懂的语言去教大家如何理解 SQL Server里的代码. 实例: 1.查询学生表中所有的信息 select * from Student 下面是我的理解 ...