I want to read text from assets folder and then format(text size and color) the text and display in text view. I know how to read from assets folder but I don't know how to format the text. This is solution I figured out. But don't know if is the best solution. In my task I have Word documents with some text format and I want to store them (read-only). And then if user what to display this text. Display in the same format as is in the word document.
Asked
Active
Viewed 399 times
1
-
Android does not have anything built in that handles any word processor format. Perhaps you should save your document as HTML, then use that to populate an `WebView`. – CommonsWare Feb 19 '17 at 22:55
1 Answers
1
You can use HTML directly in a textview in Android, so you do not need to use a webview.
Here is a tutorial for using HTML in an Android textview: http://alvinalexander.com/android/how-show-html-string-in-android-textview-webview
Also, there seem to be some libraries for handling Word documents under Android:
But I have never tried them myself.

anti_gone
- 973
- 8
- 18