WIP - Pinch to zoom TextView handling #202
Closed
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Fixes #153
This PR aims at responding to the pinch to zoom gesture on Emoji / TextView with a combination of
scale
and changing the view'swidth
andheight
.There's various parts to this PR:
frmBorder
andimgClose
handling on views, which were hidden and therefore lacked any specific useview_photo_editor_text
layout further and is now just the minimum needed: aTextView
withapp:autoSizeTextType="uniform"
to signal we want it to change it's font Size according to the view sizeViewType.TEXT
after we get Emoji right), as it's of particular interest thatAutosizing TextViews
need thewidth
andheight
to be set in a specific way (and that in turn as well depends on the layout where the views are being placed, in our casephotoEditorView
is aRelativeLayout
, take a look into theaddViewToParent
method), special note on this comment:=============
Issues found
Known issues found with TextViewCompat's Autosizeable TextViews
https://issuetracker.google.com/issues/68787108
https://issuetracker.google.com/issues/38468964
The first one in particular is not good as I can see it's not working well when shrinking on width on emoji
https://cloudup.com/ccGNffHgmKZ
TextView’s autosizeable feature doesn’t seem to work well with emoji when shrinking on width (although it does work well when shrinking on height, as can be seen in the video)
This is work in progress.