从 Text Tab Types Text Tab Constants Text Tab Creation Text Tab Access学习
more >>我们从 Run Delegate Types Run Delegate Callbacks Run Delegate Versions Run Delegate Creation Run Delegate Access 五个方面来学习
more >>从 Paragraph Style Types Paragraph Style Values Paragraph Style Creation Paragraph Style Access 四个方面来学习 CTParagraphStyle 样式
more >>我们从 Glyph Info Types Glyph Info Values Glyph Info Creation Glyph Info Access四个方面来学习。 该类的函数具体效果不明,以后研究。
more >>
|
|
富文本离不开文字,下面我们学下字体Font
字体内容较多,我们从以下方面学下。
|
|
| kCTFontCopyrightNameKey | 版权key |
|---|---|
| kCTFontFamilyNameKey | family(家族) key |
| kCTFontSubFamilyNameKey | subfamily(子家族)key |
| kCTFontStyleNameKey | 字体style key |
| kCTFontUniqueNameKey | 独一无二key(value不是真的独一无二,不应该假设唯一) |
| kCTFontFullNameKey | 字体全名key |
| kCTFontVersionNameKey | 字体版本号key |
| kCTFontPostScriptNameKey | 字体补充说明key |
| kCTFontTrademarkNameKey | 商标key |
| kCTFontManufacturerNameKey | 制造商key |
| kCTFontDesignerNameKey | 设计者key |
| kCTFontDescriptionNameKey | 字体描述key |
| kCTFontVendorURLNameKey | 供应商url key |
| kCTFontLicenseNameKey | 许可证key |
| kCTFontLicenseURLNameKey | 许可证url key |
| kCTFontSampleTextNameKey | 简单text key |
| kCTFontPostScriptCIDNameKey | 补充说明CID key |
这些key 暂时不知道干嘛用的。
more >>该类从以下四个方面来学习。
|
|
| ke’y | value | 解释 |
|---|---|---|
| kCTFontURLAttribute | CFURLRef | 通过 descriptor 访问字体的url |
| kCTFontNameAttribute | CFStringRef | 先从 PostScript arr 中找, 没发现在从 family 数字找,没发现 用 display name 。, 如果还是从字体列表中没找到,默认返回 Helvetica 字体 |
| kCTFontDisplayNameAttribute | CFStringRef | 这个返回display name 大多数是 the full name。 |
| kCTFontFamilyNameAttribute | CFStringRef | 返回 family name |
| kCTFontStyleNameAttribute | CFStringRef | 返回 the style name of the font。代表设计者对该字体样式的描述。 |
| kCTFontTraitsAttribute | CFDictionaryRef | 返回改字体的特性 traits 字典。 |
| kCTFontVariationAttribute | CFDictionaryRef | 不知道啥用 |
| kCTFontSizeAttribute | CFNumberRef | 返回字体的大小 |
| kCTFontMatrixAttribute | CFDataRef | 该data是 CGAffineTransform信息 |
| kCTFontCascadeListAttribute | CFArrayRef | 级联表格数组,具体干嘛的不知道。看结果在说 |
| kCTFontCharacterSetAttribute | CFCharacterSetRef | |
| kCTFontLanguagesAttribute | CFArrayRef | |
| kCTFontBaselineAdjustAttribute | CFNumberRef | |
| kCTFontMacintoshEncodingsAttribute | CFNumberRef | |
| kCTFontFeaturesAttribute | CFArrayRef | |
| kCTFontFeatureSettingsAttribute | ||
| kCTFontFixedAdvanceAttribute | CFNumberRef | |
| kCTFontOrientationAttribute | CFNumberRef | |
| kCTFontFormatAttribute | CFNumber | |
| kCTFontRegistrationScopeAttribute | CTFontManagerScope | |
| kCTFontPriorityAttribute | ||
| kCTFontEnabledAttribute | ||
| kCTFontDownloadableAttribute | ||
| kCTFontDownloadedAttribute |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
keys for progressParameter dictionary
| key | value | |
|---|---|---|
| kCTFontDescriptorMatchingSourceDescriptor | ||
| kCTFontDescriptorMatchingDescriptors | ||
| kCTFontDescriptorMatchingResult | ||
| kCTFontDescriptorMatchingPercentage | ||
| kCTFontDescriptorMatchingCurrentAssetSize | ||
| kCTFontDescriptorMatchingTotalDownloadedSize | ||
| kCTFontDescriptorMatchingTotalAssetSize | ||
| kCTFontDescriptorMatchingError |
|
|
|
|
|
|
###
|
|
|
|
| key | value | 解释 |
|---|---|---|
| kCTFontCollectionRemoveDuplicatesOption | a non-zero value | collection过滤相同的 duplicate font descriptors |
| kCTFontCollectionIncludeDisabledFontsOption | a non-zero value | 匹配禁用字体 |
| kCTFontCollectionDisallowAutoActivationOption | a non-zero value | 不匹配丢失的字体 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
tag:
缺失模块。
1、在博客根目录(注意不是yilia根目录)执行以下命令:
npm i hexo-generator-json-content --save
2、在根目录_config.yml里添加配置:
jsonContent:
meta: false
pages: false
posts:
title: true
date: true
path: true
text: true
raw: false
content: false
slug: false
updated: false
comments: false
link: false
permalink: false
excerpt: false
categories: false
tags: true