11 Commits

Author SHA1 Message Date
Adlai Holler
9c3b688a87 Remove textStorageCreationBlock API (#2142)
* Remove textStorageCreationBlock API

* Remove layoutManagerCreationBlock also
2016-08-26 11:42:20 -07:00
Hannah Troisi
c857e809f4 Clean up header comments (for consistent Facebook licensing info) (#1741)
[Licensing] Clean up header comments (for consistent Facebook licensing info)
2016-06-11 23:31:39 -07:00
Scott Goodson
8308a4ce49 [AsyncDisplayKit] Adopt #pragma once, remove last remaining dispatch_sync (UIScreen scale). 2016-03-19 19:56:41 -07:00
Eric Jensen
14a389c5e0 Replace ASTextKitAttributes' objectsEqual with the shared ASObjectIsEqual 2016-03-17 10:36:35 -07:00
Eric Jensen
33fda7ab49 - Use modern Objective-C syntax.
-  Simplify comparisons.
-  Remove dead stores.
2016-03-15 22:34:29 -07:00
rcancro
878fedd8f3 Stopped trying to cache the currentScaleFactor
Was running into issues where the scale factor would get cleared when setting a new atributedString on a textNode.

I was clearing out the currentScaleFactor when setting an attributedString into a textNode. It appears that `_calculateSize` isn't always called when setting a new string into a ASTextNode. It can be the case that only `drawInContext:bounds:` is called. With _currentScaleFactor cleared out the renderer that calls`drawInContext...` was being called with a scaleFactor of 0.

It could be the case that the fix could be to remove the clearing of `currentScaleFactor` from `setAttributedString`, but this seems like a safer fix to me. It does, however, require an extra run through the font adjuster when enabled.
2016-02-23 16:51:10 -08:00
rcancro
00b0968bf7 Add ability to customize NSLayoutManager and NSTextStorage when created in the ASTextKitContext 2016-02-22 13:00:02 -08:00
rcancro
a920e353c6 adjust font size to make text fit within constrained size
# Conflicts:
#	AsyncDisplayKit/ASTextNode.mm
2016-02-16 16:16:22 -08:00
rcancro
7f6f2fed11 Added ASTextNodeWordKerner support to ASTextNode
* Added a member to `ASTextKitAttributes` that is an optional delegate to the struct's NSLayoutManager.
* Changed ASTextNode to set this delegate to an instance of ASTextNodeWordKerner.
* Updated init method of `ASTextKitContext` to take an optional NSLayoutManager delegate
* Added the files in TextKit folder to the public headers (so we can include ASTextNodeTypes.h)
2016-01-28 08:38:22 -08:00
Luke Zhao
f413a618e0 add ASTextKitFontSizeAdjuster 2016-01-25 19:07:28 -08:00
Levi McCallum
a0c05ebffc Rename CK classes to AS classes 2015-11-30 06:44:53 -08:00