Skip to content

Commit

Permalink
Updated to version 1.1.6
Browse files Browse the repository at this point in the history
  • Loading branch information
tobihagemann committed Nov 21, 2013
1 parent 2281a88 commit b1a719c
Show file tree
Hide file tree
Showing 6 changed files with 10 additions and 7 deletions.
2 changes: 1 addition & 1 deletion LICENSE.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
THLabel

Version 1.1.5, November 6th, 2013
Version 1.1.6, November 21st, 2013

Copyright (c) 2013 Tobias Hagemann, tobiha.de

Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ And drag these files into your project:
- `THLabel.h`
- `THLabel.m`

You can create THLabels programmatically, or create them in Interface Builder by dragging an ordinary UILabel into your view and setting its class to THLabel.
You can create THLabels programmatically, or create them in Interface Builder by dragging an ordinary UILabel into your view and setting its *Custom Class* to THLabel.

## Properties

Expand Down
4 changes: 4 additions & 0 deletions RELEASE NOTES.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
Version 1.1.6

- Fixed memory related crash.

Version 1.1.5

- Fixed text alignment for multi-line texts.
Expand Down
2 changes: 1 addition & 1 deletion THLabel.podspec
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Pod::Spec.new do |s|
s.name = 'THLabel'
s.version = '1.1.5'
s.version = '1.1.6'
s.summary = 'THLabel is a subclass of UILabel, which additionally allows shadow blur, stroke text and fill gradient.'
s.homepage = 'https://github.com/MuscleRumble/THLabel'
s.screenshots = 'https://github.com/MuscleRumble/THLabel/blob/master/screenshot.png'
Expand Down
2 changes: 1 addition & 1 deletion THLabel/THLabel.h
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
//
// THLabel.h
//
// Version 1.1.5
// Version 1.1.6
//
// Created by Tobias Hagemann on 11/25/12.
// Copyright (c) 2013 tobiha.de. All rights reserved.
Expand Down
5 changes: 2 additions & 3 deletions THLabel/THLabel.m
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
//
// THLabel.m
//
// Version 1.1.5
// Version 1.1.6
//
// Created by Tobias Hagemann on 11/25/12.
// Copyright (c) 2013 tobiha.de. All rights reserved.
Expand Down Expand Up @@ -319,13 +319,12 @@ - (CTFrameRef)setupFrameForDrawingOutTextRect:(CGRect *)textRect {
// Set up font.
CTFontRef fontRef = CTFontCreateWithName((__bridge CFStringRef)self.font.fontName, self.font.pointSize, NULL);
CTTextAlignment alignment = NSTextAlignmentToCTTextAlignment ? NSTextAlignmentToCTTextAlignment(self.textAlignment) : [self CTTextAlignmentFromNSTextAlignment:self.textAlignment];
CTLineBreakMode lineBreakMode = self.lineBreakMode;
CTLineBreakMode lineBreakMode = (CTLineBreakMode)self.lineBreakMode;
CTParagraphStyleSetting paragraphStyleSettings[] = {
{kCTParagraphStyleSpecifierAlignment, sizeof(CTTextAlignment), &alignment},
{kCTParagraphStyleSpecifierLineBreakMode, sizeof(CTLineBreakMode), &lineBreakMode}
};
CTParagraphStyleRef paragraphStyleRef = CTParagraphStyleCreate(paragraphStyleSettings, 2);
CFRelease(paragraphStyleSettings);

// Set up attributed string.
CFStringRef keys[] = {kCTFontAttributeName, kCTParagraphStyleAttributeName, kCTForegroundColorAttributeName};
Expand Down

0 comments on commit b1a719c

Please sign in to comment.