Mikael Sand
d0a9cbaceb
Fix caching of text
2018-08-25 00:17:36 +03:00
Mikael Sand
f225d0648d
[ios] Restore ability to disable kerning
2018-07-02 09:10:15 +03:00
Mikael Sand
85729ee658
[ios] Fix kerning for Korean and Chinese characters. Issue #719
2018-07-02 08:16:05 +03:00
Mikael Sand
13fcdf6f15
Merge remote-tracking branch 'msand/NestedSvg' into merge-test
...
# Conflicts:
# ios/Elements/RNSVGGroup.m
# ios/RNSVGNode.h
# ios/RNSVGNode.m
2018-03-19 00:27:01 +02:00
Nikolay Demyankov
f7c81ef368
Remove getAlignmentBaseline and getBaselineShift methods, use property methods instead.
2018-03-14 17:00:38 +01:00
Nikolay Demyankov
ef8b687ff0
Fix retain cycle for the textRoot property.
2018-03-14 15:31:02 +01:00
Nikolay Demyankov
26964598fc
Fix retain cycle for nested views.
2018-03-14 11:05:20 +01:00
Mikael Sand
b5eeb1ee72
Allow nesting React-Native View components inside svg
2018-02-21 12:17:12 +02:00
Ben Roth
5f74c92a58
Namespaces or un-globalifies a handful more iOS globals
2018-02-16 17:14:10 -08:00
Ben Roth
b217dcaff8
Prefix iOS symbols with RNSVG
...
fixes https://github.com/react-native-community/react-native-svg/issues/603
2018-02-14 19:04:32 -08:00
James Ide
10f8134dab
Add "typedef" to NS_ENUM declarations, fix duplicate symbol error
...
NS_ENUM is designed to go with typedef c.f. Apple docs: https://developer.apple.com/library/content/releasenotes/ObjectiveC/ModernizationObjC/AdoptingModernObjective-C/AdoptingModernObjective-C.html#//apple_ref/doc/uid/TP40014150-CH1-SW6
Fixes #579
2018-02-12 18:14:04 -08:00
Mikael Sand
83d00d09db
Optimize and improve accuracy of textPath.
2018-01-02 23:39:58 +02:00
Mikael Sand
4a8808b0fb
Fix handling of combined ligatures and kerning.
...
Remove hasGlyph helper and ligature tracking array.
Use single call to:
- CFAttributedStringCreate
- CTLineCreateWithAttributedString
and a call per bi-di/layout run to:
- CTRunGetGlyphs for glyphs
- CTFontGetAdvancesForGlyphs for advances
- CTRunGetStringIndices for indices of ligatures
And an efficient loop over the substituted characters of ligatures,
to make glyph context calls for incrementing the attribute indices.
2018-01-02 23:17:04 +02:00
Mikael Sand
17a66f3c2c
Fix ligature glyph advance value calculation on ios
2017-12-31 15:36:26 +02:00
Mikael Sand
f8b0d34c6a
Fix types and glyph context nextX spacing handling.
2017-12-31 04:23:58 +02:00
Mikael Sand
9ab405cbec
Add binary search for text paths with lineCount >= 16
2017-12-31 01:38:28 +02:00
Mikael Sand
f07e8f041c
Allow TextPath to reference any RNSVGNode instead of only RNSVGPath.
...
Remove unused RNSVGTextAnchor
2017-12-30 03:35:58 +02:00
Mikael Sand
7088d52b71
Refactor and simplify, cache path properties.
...
Remove use of UIBezierPath and categories.
2017-12-29 23:04:24 +02:00
Mikael Sand
b9959c779c
Implement tailor made data structure and logic for text on a path rendering.
...
Remove postinstall script and dependencies on PerformanceBezier & QuartzBookPack.
2017-12-28 06:25:07 +02:00
Mikael Sand
ec2a967592
Implement getAlignmentBaseline and getBaselineShift in ios. ( #527 )
...
* Implement correct transform parser
* Implement getAlignmentBaseline and getBaselineShift in ios.
Add comments to glyphcontext and align with android.
Implement correct isWordSeparator predicate.
Cleanup GlyphContext j2objc remnants.
* Fix getBaselineShift bugs and font data invalidation.
2017-12-16 08:57:53 -08:00
szakhlypa
ffea98f863
Fix memory leak in iOS RNSVGTSpan ( #521 )
2017-11-23 13:46:48 -08:00
Horcrux
177f71c801
import QuartzBookPack as framework
2017-11-07 21:03:53 +08:00
Horcrux
6081b27822
Fix fontWeight and fontStyle
2017-11-07 19:29:36 +08:00
magicismight
be8797be52
Add PerformanceBezier as a submodule
2017-09-24 23:44:17 +08:00
Mikael Sand
5a01d672b9
Optimize and simplify hasGlyph.
2017-08-29 03:16:52 +03:00
Mikael Sand
04887af278
Implement kerning, ligatures, etc., and cleanup; in ios.
...
Implement hasGlyph ligature helper.
Export view property setters for:
text: textLength, baselineShift, lengthAdjust, alignmentBaseline,
textPath: side, method, midLine, spacing.
Attempt to fix alignmentBaseline and baselineShift,
but both properties are nil at all times, I must be missing something.
2017-08-29 02:34:56 +03:00
Mikael Sand
8dd795bdd7
Fix text on a path rendering accuracy
2017-08-27 01:09:01 +03:00
Mikael Sand
c6028e825d
Fix rotate and G element font settings.
2017-08-25 13:46:03 +03:00
Mikael Sand
95736f2f69
Disable ligatures on ios (doesn't account for per character advance width correctly yet)
2017-08-24 21:43:34 +03:00
Mikael Sand
e604d7fb8f
Simplify enum parsing
2017-08-24 19:14:11 +03:00
Mikael Sand
5372a3078e
Cleanup headers
2017-08-24 12:42:18 +03:00
Mikael Sand
13d5157fc1
Cleanup.
2017-08-23 16:22:49 +03:00
Mikael Sand
ccb8729917
Port new GlyphContext, FontData, enums, props, Bezier and text rendering
2017-08-23 05:41:35 +03:00
Mikael Sand
3cafc34cb2
Fix ViewBox, images, transforms, and, gradients; on ios.
...
Make getContextWidth/Height and setupGlyphContext take clip bounding box and affine transform matrix into consideration.
2017-08-16 19:06:23 +03:00
Mikael Sand
f1657d9ddf
Prepare for new GlyphContext.
2017-08-15 19:50:50 +03:00
Mikael Sand
f3cd34f2e1
Fix ios/objective-c types and errors/red boxes.
2017-08-11 02:27:33 +03:00
Horcrux
601d15a686
Fix warnings on iOS
2017-01-22 20:35:26 +08:00
Horcrux
1db96aaa07
Fix warnings
2017-01-22 19:45:50 +08:00
Horcrux
738b9a1536
Update TSpan if content changes
2017-01-20 18:23:33 +08:00
Horcrux
5075a0f67d
Fix memory leaks
2017-01-20 18:15:05 +08:00
Horcrux
af6db7039f
Finish percentage props refactor on iOS
2017-01-20 17:47:57 +08:00
Horcrux
66bed807c5
Fix #215
2017-01-15 20:51:25 +08:00
Horcrux
742d557029
Fix startOffset on iOS
2017-01-12 21:48:45 +08:00
Horcrux
e0c3e15294
Finish TextPath and TSpan in Android
2017-01-12 20:36:20 +08:00
Horcrux
e3026c0bb5
Fix TextPath bug when using lines
2017-01-12 20:09:57 +08:00
Horcrux
dcc39c4b67
Fix memory leaks
2017-01-11 19:31:42 +08:00
Horcrux
6e81ecf147
Fix touch events on Text elements
2017-01-11 18:55:42 +08:00
Horcrux
d7daee343c
Fix ClipPath with Text
2017-01-11 18:18:51 +08:00
Horcrux
1381cd8fca
Refactor Text related elements
2017-01-11 17:02:40 +08:00
Horcrux
155ce27594
BezierPath => BezierTransformer
2017-01-10 13:14:51 +08:00