Simple RichText Editor in Android
Found some quick solutions :
- droid-writer
- cwac-richedit
Also check following discussions:
- Rich Text Box in android
- Implementing a rich text editor in Android?
How did Evernote implement their rich text editor on Android?
here are some links that should help you get started:
http://code.google.com/p/android-richtexteditor/
Rich Text Box in android
Android Edittext Rich Text Formatting
Here are two awesome libraries which helped me out. Both of them are implementation of WYSIWYG.
Android RTEditor:
https://github.com/1gravity/Android-RTEditor
RichEditor-Android:
https://github.com/wasabeef/richeditor-android
Their implementation code is also provided.
How to store rich text data?
As from the documents they have following methods to get the contents and render
render(); //Render the editor. This method must be called to render the editor.
render(String html); //Render the editor with HTML as parameter.
render(EditorState state); //Render the editor with the state as a parameter
getContent(); //returns the content in the editor as EditorState
getContentAsSerialized(); //returns the content as serialized form of EditorState
getContentAsSerialized(EditorState state); //returns the provided parameter as serialized.
getContentAsHTML(); //returns the editor content in HTML format.
So you can use getContent()
as per your requirement and directly store the content and use render method while displaying.
You can search how to store Serialised Objects inside Firebase to store EditorState
object or directly store HTML text as String
.
Create a simple text editor in Android
Look at this github project source code.
SUMMARY
Simple notepad app to open, edit and save text files to and from the SD card.
** Some features
-- open email attachments
-- change font size, type and color
-- delete/rename in file browser
-- email as text or attachment
-- Search using "search" button
Another Project Source Code . Android Ted
You can create new text file, open existing files and of course save them. You can also display line numbers and open recent files. Now you can also search for text inside the openned file.
Another Project Source Code - Qute Text Editor for Android
Related Topics
Using Service to Run Background and Create Notification
Get All Messages from Whatsapp
Designing an Android Tablet-Only App
How to 'Restart' an Android Application Programmatically
Get Certificate Fingerprint from Android App
Pairing Android and Wear Emulators
How to Get the Uuid of My Android Phone in an Application
Android Download Manager Completed
Gatt Callback Fails to Register
How to Draw Rounded Rectangle in Android Ui
Update Listview Dynamically with Adapter
Get JSON Data from Url Using Android
Gradle Version 2.2 Is Required. Current Version Is 2.10
Android Viewmodel Additional Arguments
"Id Cannot Be Resolved or Is Not a Field" Error