Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

想按照原图大小进行展示,没成功 #2

Open
aWhalefall opened this issue Aug 26, 2019 · 1 comment
Open

想按照原图大小进行展示,没成功 #2

aWhalefall opened this issue Aug 26, 2019 · 1 comment

Comments

@aWhalefall
Copy link

No description provided.

@yuruiyin
Copy link
Owner

@yatou252303 你好, 先把编辑器升级新版本到 0.2.2。然后按如下方式即可按原图大小进行展示:

val blockImageSpanVm = BlockImageSpanVm(blockImageSpanObtainObject)
richEditText.insertBlockImage(realImagePath, blockImageSpanVm) { blockImageSpan ->
    // TODO your code
}

具体可以参考demo
注意:为了避免音图片过大而无法绘制的问题,组件内部做了最大高度的限制,最大高度不会超过图片显示宽度的3倍,请知晓。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants