flex-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From aha...@apache.org
Subject [3/4] git commit: [flex-asjs] [refs/heads/develop] - change coordinate space to something expected but different from the way Flash textLine works
Date Tue, 08 Aug 2017 17:01:23 GMT
change coordinate space to something expected but different from the way Flash textLine works


Project: http://git-wip-us.apache.org/repos/asf/flex-asjs/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-asjs/commit/367f8b97
Tree: http://git-wip-us.apache.org/repos/asf/flex-asjs/tree/367f8b97
Diff: http://git-wip-us.apache.org/repos/asf/flex-asjs/diff/367f8b97

Branch: refs/heads/develop
Commit: 367f8b9793641cbc43d88c4bb8184d136b5a3d09
Parents: 3bb3f41
Author: Alex Harui <aharui@apache.org>
Authored: Tue Aug 8 10:00:20 2017 -0700
Committer: Alex Harui <aharui@apache.org>
Committed: Tue Aug 8 10:01:16 2017 -0700

----------------------------------------------------------------------
 .../Text/src/main/flex/org/apache/flex/text/html/TextLine.as     | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/367f8b97/frameworks/projects/Text/src/main/flex/org/apache/flex/text/html/TextLine.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/Text/src/main/flex/org/apache/flex/text/html/TextLine.as
b/frameworks/projects/Text/src/main/flex/org/apache/flex/text/html/TextLine.as
index 440ae30..c260c0c 100644
--- a/frameworks/projects/Text/src/main/flex/org/apache/flex/text/html/TextLine.as
+++ b/frameworks/projects/Text/src/main/flex/org/apache/flex/text/html/TextLine.as
@@ -356,7 +356,7 @@ package org.apache.flex.text.html
 				if (atomIndex == element.firstChild.textContent.length - 1)
 				{
 					w = (element.firstChild as HTMLElement).getClientRects()[0].width;
-					return new Rectangle(w, 1.2 - _textBlock.content.elementFormat.fontSize, 3, 1.2);
+					return new Rectangle(w, 1.2, 3, 1.2 + _textBlock.content.elementFormat.fontSize);
 				}
 				else
 				{
@@ -372,7 +372,7 @@ package org.apache.flex.text.html
                     span.innerHTML = s.substring(0, atomIndex + 1);
                     w = span.getClientRects()[0].width;
 					element.removeChild(span);
-					return new Rectangle(w1, 1.2 - _textBlock.content.elementFormat.fontSize, w - w1, 1.2);
+					return new Rectangle(w1, 1.2, w - w1, 1.2 + _textBlock.content.elementFormat.fontSize);
 				}
 			}
 		}


Mime
View raw message