ModdingFox / OpenFuraffinityClient

A toy project of mine to build an unofficial furaffinity client for android
11 stars 1 forks source link

Embeded view for Story/Poetry content #124

Closed ModdingFox closed 3 years ago

ModdingFox commented 3 years ago

Need to assess an embedded view for content with the below Mime Types.

text/plain, text/rtf, application/msword, application/vnd.openxmlformats-officedocument.wordprocessingml.document, application/vnd.oasis.opendocument.text, application/pdf

ModdingFox commented 3 years ago

Simplest solution is to have the app convert data to 1 format and build a display for that. PDF seems to have some libs out there to easily display content.

text/plain, text/rtf, application/pdf: There are all pretty reasonable to work with and I have some fairly decent ways of dealing with them. For txt the conversion is simple just paragraph on \n. Stripping out formatting from rtf and then treating it like txt should be enough for the most common cases. Can return to edge cases later but the chosen libs for reading rtf data and the libs for generating pdf's should be abel to handle whatever may be needed in the future as it comes up. Since pdf is the native view libs expected format nothing special will need to be done there.

Looking around I can seem to find any libs to lazily deal with application/msword, application/vnd.openxmlformats-officedocument.wordprocessingml.document, application/vnd.oasis.opendocument.text. All the libs I looked at seem to require an open/ms office installation to perform their tasks. If I recall correctly these are zip files that have some xml content in em or at least word does things that way. I may be able to take some code I built for another thing sometime ago and port it over. Likely ill have to do something similar to rtf and generate a non pretty version just to start with,

This issues is gunna ignore open/ms office docs and for now we will just call them unsupported.