NSAttributedString 的使用

字體

// UIFont, default Helvetica(Neue) 12
// 設置字體这弧,默認是  Helvetica(Neue) 12
public let NSFontAttributeName: String 
let attributeString = NSMutableAttributedString(string: "Hello world!")
// let font = UIFont(name: "ArialMT", size: 25)  這樣設置就可以使用對應的字體集娃闲。
// 當系統(tǒng)中不存在的時候,可能會報錯匾浪。
let font = UIFont.systemFont(ofSize: 25)

// 這個 range 會決定 font 影響的字符范圍
//(最能體現(xiàn)個性化的地方)
let range = NSRange(location: 0, length: attributeString.length)
attributeString.addAttribute(NSFontAttributeName, value: font, range:  range)

// 設置 label 的屬性文本 
label.attributedText = attributeString

將 attributeString 添加到 Label 或者 TextView 的 attributedText 的上面就可以顯示出來皇帮。

Snip20160927_3.png

段落樣式的設置


// NSParagraphStyle, default defaultParagraphStyle
// 段落樣式
public let NSParagraphStyleAttributeName: String 

NSParagraphStyleAttributeName key 對應的 Value 是 NSMutableParagraphStyle與NSParagraphStyle
相關參考博客:
NSMutableParagraphStyle與NSParagraphStyle的使用

NSParagraphStyle 主要是用來獲取 default 的段落樣式(NSParagraphStyle.default 來獲取默認段落樣式),不具有可操作性蛋辈,CoreText 開發(fā)中主要使用的是 NSMutableParagraphStyle

// 段落樣式實例
open class NSMutableParagraphStyle : NSParagraphStyle {
    open var lineSpacing: CGFloat                    // 行間距
    open var paragraphSpacing: CGFloat               // 段間隙
    open var alignment: NSTextAlignment              // 文本排列 (對齊方式)
    open var firstLineHeadIndent: CGFloat            // 首行縮進
    open var headIndent: CGFloat                     // 整體縮進(首行除外)
    open var tailIndent: CGFloat
    open var lineBreakMode: NSLineBreakMode          // 換行模式
    open var minimumLineHeight: CGFloat              // 最小行高 
    open var maximumLineHeight: CGFloat              // 最大行高
    open var baseWritingDirection: NSWritingDirection    // 文本的書寫方向(方向有三個属拾,從左到右,從右到做冷溶,從上到下)
    open var lineHeightMultiple: CGFloat
    open var paragraphSpacingBefore: CGFloat         //段首行空白空
    open var hyphenationFactor: Float                // 連字屬性 在iOS渐白,唯一支持的值分別為0和1 
    @available(iOS 7.0, *)
    open var tabStops: [NSTextTab]!
    @available(iOS 7.0, *)
    open var defaultTabInterval: CGFloat
    @available(iOS 9.0, *)
    open var allowsDefaultTighteningForTruncation: Bool
    @available(iOS 9.0, *)
    open func addTabStop(_ anObject: NSTextTab)
    @available(iOS 9.0, *)
    open func removeTabStop(_ anObject: NSTextTab)
    @available(iOS 9.0, *)
    open func setParagraphStyle(_ obj: NSParagraphStyle)
}
沒有設置的時候
// 加載字符串 并 創(chuàng)建屬性文本
let strPath = Bundle.main.path(forResource: "CoreText.txt", ofType: nil)
var str: String = ""
// 這里寫的稍稍有點累贅
do {
    if let tempPath = strPath {
    try str = String(contentsOf: URL(fileURLWithPath: tempPath))
    } else {
         fatalError("文件沒有找到")
    }
} catch {
     fatalError("文件價值失敗")
}
let attributeString = NSMutableAttributedString(string: str)
        
// 設置字符屬性  設置段落樣式
let style = NSMutableParagraphStyle()
style.lineSpacing = 3               // 設置行間距
style.firstLineHeadIndent = 20.0    // 設置首行縮進
style.paragraphSpacing = 3          // 設置段落之間的間距
        
attributeString.addAttribute(NSParagraphStyleAttributeName, value: style, range: range)
調(diào)整后的

相對來說已經(jīng)美觀很多了。

文字顏色和背景顏色的處理

// UIColor, default blackColor
// 設置文字顏色逞频, 默認為黑色
public let NSForegroundColorAttributeName: String 

// UIColor, default nil: no background
// 設置文字的背景顏色纯衍,默認是沒有顏色的
public let NSBackgroundColorAttributeName: String 

// 設置字體顏色
attributeString.addAttribute(NSForegroundColorAttributeName, value: UIColor.red, range: range)
        
// 設置字體背景顏色
attributeString.addAttribute(NSBackgroundColorAttributeName, value: UIColor.blue, range: range)
Snip20160927_6.png

連字符

連體字符是指某些連在一起的字符,它們采用 單個的圖元符號苗胀。0 表示沒有連體字符襟诸。1 表示使用默認的連體字符瓦堵。2表示使用所有連體符號。默認值為 1(注意歌亲,iOS 不支持值為 2)挑宠。

(不是使用了 1 后 所有的字符都會連起來)


// NSNumber containing integer, default 1: default ligatures, 0: no ligatures
// 設置連體字(只有 0 和 1 可以設置设江,1 表示連體字,0 表示非連體字)
public let NSLigatureAttributeName: String 

設置字符間距

值為 0 表示不使用字母緊排。默認值為0健田。 正數(shù)虹脯,間距增加淑仆,負數(shù)漆诽,間距減小。

// NSNumber containing floating point value, in points; amount to modify default kerning. 0 means kerning is disabled.
// 設置文字間的間距(字符之間的間距)(正數(shù)扮休,間距增加迎卤,負數(shù),間距減戌枳埂)
public let NSKernAttributeName: String 

設置刪除線

刪除線的樣式可以參考 NSUnderlineStyle進行設置

 // NSNumber containing integer, default 0: no strikethrough
 // 設置文字刪除線的樣式
public let NSStrikethroughStyleAttributeName: String

// UIColor, default nil: same as foreground color
// 設置文字刪除線的顏色
public let NSStrikethroughColorAttributeName: String 

下劃線的設置

// NSNumber containing integer, default 0: no underline
// 設置下劃線的樣式 
public let NSUnderlineStyleAttributeName: String 

// UIColor, default nil: same as foreground color
// 設置下劃線顏色 , 默認和文字顏色是一樣的
public let NSUnderlineColorAttributeName: String 

// 下劃線的樣式
public enum NSUnderlineStyle : Int {
    case styleNone
    case styleSingle

    @available(iOS 7.0, *)
    case styleThick
    @available(iOS 7.0, *)
    case styleDouble

    @available(iOS 7.0, *)
    public static var patternSolid: NSUnderlineStyle { get }

    @available(iOS 7.0, *)
    case patternDot

    @available(iOS 7.0, *)
    case patternDash

    @available(iOS 7.0, *)
    case patternDashDot

    @available(iOS 7.0, *)
    case patternDashDotDot

    @available(iOS 7.0, *)
    case byWord
}

// 設置下劃線  (寫 NSUnderlineStyle.styleSingle 編譯不通過蜗搔,但是寫 1 編譯通過,效果是等效的八堡。 )
attributeString.addAttribute(NSUnderlineStyleAttributeName, value: 1, range: range)

attributeString.addAttribute(NSUnderlineColorAttributeName, value: UIColor.green, range: range)
Snip20160928_7.png

設置文字的描邊

NSStrokeColorAttributeName 和 NSStrokeWidthAttributeName 配合使用才會有效果樟凄。單獨使用時不會有效果的。
使用兩個屬性兄渺,會讓文字產(chǎn)生鏤空的效果缝龄。

屬性不指定(默認),則等同于 NSForegroundColorAttributeName挂谍。否則叔壤,指定為刪除線或下劃線顏色。

設置描邊效果后 Width > 0 NSForegroundColorAttributeName 字符屬性的設置就會失效口叙。

// UIColor, default nil: same as foreground color
// 設置文字繪制顏色(和 foreground color 一樣)
public let NSStrokeColorAttributeName: String 

// NSNumber containing floating point value, in percent of font point size, default 0: no stroke; positive for stroke alone, negative for stroke and fill (a typical value for outlined text would be 3.0)
// 設置文字筆畫寬度的百分比, 相對于字體size 的百分比.
// 正數(shù)只改變描邊寬度炼绘。負數(shù)同時改變文字的描邊和填充寬度。例如妄田,對于常見的空心字俺亮,這個值通常為3.0。(空心文字)
public let NSStrokeWidthAttributeName: String 
let str: String = "Hello world!"
let attributeString = NSMutableAttributedString(string: str)

//  設置字符屬性
let font = UIFont.systemFont(ofSize: 35)

// 這個 range 會決定 font 影響的字符范圍
let range = NSRange(location: 0, length: attributeString.length)
attributeString.addAttribute(NSFontAttributeName, value: font, range:  range)

attributeString.addAttribute(NSStrokeColorAttributeName, value: UIColor.green, range: range)

//  value 的值為 3 疟呐。 這個時候文字是鏤空的
attributeString.addAttribute(NSStrokeWidthAttributeName, value: 3, range: range)
鏤空效果
//  value 的值為 -3
attributeString.addAttribute(NSStrokeWidthAttributeName, value: -3, range: range)
Snip20160928_9.png
attributeString.addAttribute(NSForegroundColorAttributeName, value: UIColor.red, range: range)

描邊后脚曾,文字的填充顏色是由文字的顏色決定的。


Snip20160928_10.png

文字陰影

文字陰影對應的是 NSShadow 對象萨醒。默認情況下是 nil
(我發(fā)現(xiàn)單獨使用是不會有效果的)

// NSShadow, default nil: no shadow
// 設置文字陰影
public let NSShadowAttributeName: String 

圖版印刷效果

// NSString, default nil: no text effect
// 設置文本效果 目前只有圖版印刷效果可用
public let NSTextEffectAttributeName: String 

圖文混排列

// NSTextAttachment, default nil
// 設置文本附件(圖文混排相關)
public let NSAttachmentAttributeName: String 

網(wǎng)絡連接的處理

// NSURL (preferred) or NSString
// 設置網(wǎng)絡連接(設置鏈接斟珊,點擊后用瀏覽器打開)
public let NSLinkAttributeName: String 

// NSNumber containing floating point value, in points; offset from baseline, default 0
// 設置文字基準線偏移量 ( 正值向上偏移苇倡,負值向下偏移)
public let NSBaselineOffsetAttributeName: String 


// NSNumber containing floating point value; skew to be applied to glyphs, default 0: no skew
// 設置文字的斜體效果(正值向左偏富纸,負值向右偏)
public let NSObliquenessAttributeName: String 

// NSNumber containing floating point value; log of expansion factor to be applied to glyphs, default 0: no expansion
// 設置文字擴充 (正數(shù)向左右拉伸囤踩,負數(shù) 向中間縮小)
public let NSExpansionAttributeName: String 

// NSArray of NSNumbers representing the nested levels of writing direction overrides as defined by Unicode LRE, RLE, LRO, and RLO characters.  The control characters can be obtained by masking NSWritingDirection and NSWritingDirectionFormatType values.  LRE: NSWritingDirectionLeftToRight|NSWritingDirectionEmbedding, RLE: NSWritingDirectionRightToLeft|NSWritingDirectionEmbedding, LRO: NSWritingDirectionLeftToRight|NSWritingDirectionOverride, RLO: NSWritingDirectionRightToLeft|NSWritingDirectionOverride,
// 設置文字的書寫方向(從左到右晓褪,從右到左)
public let NSWritingDirectionAttributeName: String 


字符排列

// An NSNumber containing an integer value.  0 means horizontal text.  1 indicates vertical text.  
// If not specified, it could follow higher-level vertical orientation settings.  Currently on iOS, it's always horizontal.  
// The behavior for any other value is undefined.
// 設置文字的垂直樣式(測試只對中文標點起作用堵漱,0 橫排列,1 豎直排列) iOS 一般使用 0 
public let NSVerticalGlyphFormAttributeName: String 

// This defines currently supported values for NSUnderlineStyleAttributeName and NSStrikethroughStyleAttributeName. 
// NSUnderlineStyle*, NSUnderlinePattern*, and NSUnderlineByWord are or'ed together to produce an underline style.



Attribute values

// NSWritingDirectionFormatType values used by NSWritingDirectionAttributeName. It is or'ed with either NSWritingDirectionLeftToRight or NSWritingDirectionRightToLeft. Can specify the formatting controls defined by Unicode Bidirectional Algorithm.
@available(iOS 9.0, *)
public enum NSWritingDirectionFormatType : Int {

    case embedding

    case override
}

// NSTextEffectAttributeName values
@available(iOS 7.0, *)
public let NSTextEffectLetterpressStyle: String

Attribute fixing


/************************ Attribute fixing ************************/
extension NSMutableAttributedString {

    // This method fixes attribute inconsistencies inside range.  It ensures NSFontAttributeName covers the characters, NSParagraphStyleAttributeName is only changing at paragraph boundaries, and NSTextAttachmentAttributeName is assigned to NSAttachmentCharacter.  NSTextStorage automatically invokes this method via -ensureAttributesAreFixedInRange:.
    @available(iOS 7.0, *)
    open func fixAttributes(in range: NSRange)
}


// Supported document types for the NSDocumentTypeDocumentAttribute key in the document attributes dictionary.
/************************ Document formats ************************/
@available(iOS 7.0, *)
public let NSPlainTextDocumentType: String
@available(iOS 7.0, *)
public let NSRTFTextDocumentType: String
@available(iOS 7.0, *)
public let NSRTFDTextDocumentType: String
@available(iOS 7.0, *)
public let NSHTMLTextDocumentType: String

// Keys for NSLayoutOrientationSectionsAttribute.
@available(iOS 7.0, *)
public let NSTextLayoutSectionOrientation: String // NSNumber containing NSTextLayoutOrientation value. default: NSTextLayoutOrientationHorizontal
@available(iOS 7.0, *)
public let NSTextLayoutSectionRange: String // NSValue containing NSRange representing a character range. default: a range covering the whole document

// Keys for options and document attributes dictionaries.  They are in and out document properties used by both read/write methods.

@available(iOS 7.0, *)
public let NSDocumentTypeDocumentAttribute: String // @"DocumentType", one of the document types declared above.  For reader methods, this key in options can specify the document type for interpreting the contents.  Upon return, the document attributes can contain this key for indicating the actual format used to read the contents.  For write methods, this key specifies the format for generating the data.

// NSPlainTextDocumentType document attributes
@available(iOS 7.0, *)
public let NSCharacterEncodingDocumentAttribute: String // @"CharacterEncoding", NSNumber containing integer specifying NSStringEncoding for the file; default for plain text is the default encoding.  This key in options can specify the string encoding for reading the data.  Upon return, the document attributes can contain the actual encoding used.  For writing methods, this value is used for generating the plain text data.
@available(iOS 7.0, *)
public let NSDefaultAttributesDocumentAttribute: String // @"DefaultAttributes", NSDictionary containing attributes to be applied to plain files.  Used by reader methods.  This key in options can specify the default attributes applied to the entire document contents.  The document attributes can contain this key indicating the actual attributes used.

// NSRTFTextDocumentType and NSRTFDTextDocumentType document attributes
// Document dimension
// They are document attributes used by read/write methods.
@available(iOS 7.0, *)
public let NSPaperSizeDocumentAttribute: String // @"PaperSize", NSValue containing CGSize (in points)
@available(iOS 7.0, *)
public let NSPaperMarginDocumentAttribute: String // @"PaperMargin", NSValue containing UIEdgeInsets

@available(iOS 7.0, *)
public let NSViewSizeDocumentAttribute: String // @"ViewSize", NSValue containing CGSize (in points)
@available(iOS 7.0, *)
public let NSViewZoomDocumentAttribute: String // @"ViewZoom", NSNumber containing floating point value (100 == 100% zoom)
@available(iOS 7.0, *)
public let NSViewModeDocumentAttribute: String // @"ViewMode", NSNumber containing integer; 0 = normal; 1 = page layout

// Document settings
// They are document attributes used by read/write methods.
@available(iOS 7.0, *)
public let NSReadOnlyDocumentAttribute: String // @"ReadOnly", NSNumber containing integer; if missing, or 0 or negative, not readonly; 1 or more, readonly. Note that this has nothing to do with the file system protection on the file, but instead, on how the file should be displayed to the user
@available(iOS 7.0, *)
public let NSBackgroundColorDocumentAttribute: String // @"BackgroundColor", UIColor, representing the document-wide page background color
@available(iOS 7.0, *)
public let NSHyphenationFactorDocumentAttribute: String // @"HyphenationFactor", NSNumber containing floating point value (0=off, 1=full hyphenation)
@available(iOS 7.0, *)
public let NSDefaultTabIntervalDocumentAttribute: String // @"DefaultTabInterval", NSNumber containing floating point value, representing the document-wide default tab stop interval, in points
@available(iOS 7.0, *)
public let NSTextLayoutSectionsAttribute: String // NSArray of dictionaries.  Each dictionary describing a layout orientation section.  The dictionary can have two attributes: NSTextLayoutSectionOrientation and NSTextLayoutSectionRange.  When there is a gap between sections, it's assumed to have NSTextLayoutOrientationHorizontal.

extension NSAttributedString {

    // Methods initializing the receiver contents with an external document data.  options specify document attributes for interpreting the document contents.  NSDocumentTypeDocumentAttribute, NSCharacterEncodingDocumentAttribute, and NSDefaultAttributesDocumentAttribute are supported options key.  When they are not specified, these methods will examine the data and do their best to detect the appropriate attributes.  If dict is non-NULL, it will return a dictionary with various document-wide attributes accessible via NS...DocumentAttribute keys.
    @available(iOS 9.0, *)
    public init(url: URL, options: [String : Any] = [:], documentAttributes dict: AutoreleasingUnsafeMutablePointer<NSDictionary?>?) throws

    @available(iOS 7.0, *)
    public init(data: Data, options: [String : Any] = [:], documentAttributes dict: AutoreleasingUnsafeMutablePointer<NSDictionary?>?) throws

    
    // Generates an NSData object for the receiver contents in range.  It requires a document attributes dict specifying at least the NSDocumentTypeDocumentAttribute to determine the format to be written.
    @available(iOS 7.0, *)
    open func data(from range: NSRange, documentAttributes dict: [String : Any] = [:]) throws -> Data

    
    // Returns an NSFileWrapper object for the receiver contents in range.  It requires a document attributes dict specifying at least the NSDocumentTypeDocumentAttribute to determine the format to be written.  The method returns a directory file wrapper for those document types represented by a file package such as NSRTFDTextDocumentType; otherwise, it returns a regular-file file wrapper.
    @available(iOS 7.0, *)
    open func fileWrapper(from range: NSRange, documentAttributes dict: [String : Any] = [:]) throws -> FileWrapper
}

extension NSMutableAttributedString {

    // Methods replacing the receiver contents with an external document data.  options specify document attributes for interpreting the document contents.  NSDocumentTypeDocumentAttribute, NSCharacterEncodingDocumentAttribute, and NSDefaultAttributesDocumentAttribute are supported options key.  When they are not specified, these methods will examine the data and do their best to detect the appropriate attributes.  If dict is non-NULL, it will return a dictionary with various document-wide attributes accessible via NS...DocumentAttribute keys.
    @available(iOS 9.0, *)
    open func read(from url: URL, options opts: [String : Any] = [:], documentAttributes dict: AutoreleasingUnsafeMutablePointer<NSDictionary?>?) throws

    @available(iOS 7.0, *)
    open func read(from data: Data, options opts: [String : Any] = [:], documentAttributes dict: AutoreleasingUnsafeMutablePointer<NSDictionary?>?) throws
}

/************ Misc methods(混合方法) ****************/
extension NSAttributedString {

    // Returns YES if the receiver contains a property configured (NSAttachmentAttributeName with NSAttachmentCharacter) in range
    @available(iOS 9.0, *)
    open func containsAttachments(in range: NSRange) -> Bool
}


/************* Deprecated 廢棄(不建議使用)*****************/
@available(iOS, introduced: 7.0, deprecated: 9.0, message: "Use NSWritingDirectionFormatType instead")
public enum NSTextWritingDirection : Int {

    
    case embedding

    case override
}

extension NSAttributedString {

    @available(iOS, introduced: 7.0, deprecated: 9.0, message: "Use -initWithURL:options:documentAttributes:error: instead")
    public init(fileURL url: URL, options: [AnyHashable : Any] = [:], documentAttributes dict: AutoreleasingUnsafeMutablePointer<NSDictionary?>?) throws
}

extension NSMutableAttributedString {

    @available(iOS, introduced: 7.0, deprecated: 9.0, message: "Use -readFromURL:options:documentAttributes:error: instead")
    open func read(fromFileURL url: URL, options opts: [AnyHashable : Any] = [:], documentAttributes dict: AutoreleasingUnsafeMutablePointer<NSDictionary?>?) throws
}

http://www.itnose.net/detail/6177538.html

最后編輯于
?著作權(quán)歸作者所有,轉(zhuǎn)載或內(nèi)容合作請聯(lián)系作者
  • 序言:七十年代末涣仿,一起剝皮案震驚了整個濱河市勤庐,隨后出現(xiàn)的幾起案子,更是在濱河造成了極大的恐慌好港,老刑警劉巖愉镰,帶你破解...
    沈念sama閱讀 219,427評論 6 508
  • 序言:濱河連續(xù)發(fā)生了三起死亡事件,死亡現(xiàn)場離奇詭異钧汹,居然都是意外死亡丈探,警方通過查閱死者的電腦和手機,發(fā)現(xiàn)死者居然都...
    沈念sama閱讀 93,551評論 3 395
  • 文/潘曉璐 我一進店門拔莱,熙熙樓的掌柜王于貴愁眉苦臉地迎上來碗降,“玉大人,你說我怎么就攤上這事塘秦∷显ǎ” “怎么了?”我有些...
    開封第一講書人閱讀 165,747評論 0 356
  • 文/不壞的土叔 我叫張陵尊剔,是天一觀的道長爪幻。 經(jīng)常有香客問我,道長须误,這世上最難降的妖魔是什么笔咽? 我笑而不...
    開封第一講書人閱讀 58,939評論 1 295
  • 正文 為了忘掉前任,我火速辦了婚禮霹期,結(jié)果婚禮上叶组,老公的妹妹穿的比我還像新娘。我一直安慰自己历造,他們只是感情好甩十,可當我...
    茶點故事閱讀 67,955評論 6 392
  • 文/花漫 我一把揭開白布。 她就那樣靜靜地躺著吭产,像睡著了一般侣监。 火紅的嫁衣襯著肌膚如雪。 梳的紋絲不亂的頭發(fā)上臣淤,一...
    開封第一講書人閱讀 51,737評論 1 305
  • 那天橄霉,我揣著相機與錄音,去河邊找鬼邑蒋。 笑死姓蜂,一個胖子當著我的面吹牛按厘,可吹牛的內(nèi)容都是我干的。 我是一名探鬼主播钱慢,決...
    沈念sama閱讀 40,448評論 3 420
  • 文/蒼蘭香墨 我猛地睜開眼逮京,長吁一口氣:“原來是場噩夢啊……” “哼!你這毒婦竟也來了束莫?” 一聲冷哼從身側(cè)響起懒棉,我...
    開封第一講書人閱讀 39,352評論 0 276
  • 序言:老撾萬榮一對情侶失蹤,失蹤者是張志新(化名)和其女友劉穎览绿,沒想到半個月后策严,有當?shù)厝嗽跇淞掷锇l(fā)現(xiàn)了一具尸體,經(jīng)...
    沈念sama閱讀 45,834評論 1 317
  • 正文 獨居荒郊野嶺守林人離奇死亡饿敲,尸身上長有42處帶血的膿包…… 初始之章·張勛 以下內(nèi)容為張勛視角 年9月15日...
    茶點故事閱讀 37,992評論 3 338
  • 正文 我和宋清朗相戀三年享钞,在試婚紗的時候發(fā)現(xiàn)自己被綠了。 大學時的朋友給我發(fā)了我未婚夫和他白月光在一起吃飯的照片诀蓉。...
    茶點故事閱讀 40,133評論 1 351
  • 序言:一個原本活蹦亂跳的男人離奇死亡栗竖,死狀恐怖,靈堂內(nèi)的尸體忽然破棺而出渠啤,到底是詐尸還是另有隱情狐肢,我是刑警寧澤,帶...
    沈念sama閱讀 35,815評論 5 346
  • 正文 年R本政府宣布沥曹,位于F島的核電站份名,受9級特大地震影響,放射性物質(zhì)發(fā)生泄漏妓美。R本人自食惡果不足惜僵腺,卻給世界環(huán)境...
    茶點故事閱讀 41,477評論 3 331
  • 文/蒙蒙 一、第九天 我趴在偏房一處隱蔽的房頂上張望壶栋。 院中可真熱鬧辰如,春花似錦、人聲如沸贵试。這莊子的主人今日做“春日...
    開封第一講書人閱讀 32,022評論 0 22
  • 文/蒼蘭香墨 我抬頭看了看天上的太陽毙玻。三九已至豌蟋,卻和暖如春,著一層夾襖步出監(jiān)牢的瞬間桑滩,已是汗流浹背梧疲。 一陣腳步聲響...
    開封第一講書人閱讀 33,147評論 1 272
  • 我被黑心中介騙來泰國打工, 沒想到剛下飛機就差點兒被人妖公主榨干…… 1. 我叫王不留,地道東北人幌氮。 一個月前我還...
    沈念sama閱讀 48,398評論 3 373
  • 正文 我出身青樓缭受,卻偏偏與公主長得像,于是被迫代替她去往敵國和親浩销。 傳聞我的和親對象是個殘疾皇子,可洞房花燭夜當晚...
    茶點故事閱讀 45,077評論 2 355

推薦閱讀更多精彩內(nèi)容

  • 與NSString類似听哭,在iOS中AttributedString也分為NSAttributedString和 N...
    錢十六閱讀 775評論 0 0
  • 轉(zhuǎn)載:http://blog.csdn.net/u010330109/article/details/518821...
    F麥子閱讀 4,176評論 0 3
  • Spring Cloud為開發(fā)人員提供了快速構(gòu)建分布式系統(tǒng)中一些常見模式的工具(例如配置管理慢洋,服務發(fā)現(xiàn),斷路器陆盘,智...
    卡卡羅2017閱讀 134,672評論 18 139
  • { 24普筹、Sqlite數(shù)據(jù)庫 1、存儲大數(shù)據(jù)量隘马,增刪改查太防,常見管理系統(tǒng):Oracle、MSSQLServer酸员、DB...
    CYC666閱讀 940評論 0 1
  • 第十五節(jié)蜒车。主力盤口語言 本節(jié)大家要了解一下就好。就當聽了個傳說幔嗦。但這卻是真實發(fā)生的事情酿愧。莊家們在許多時候為了不被查...
    精彩飛神閱讀 387評論 0 2