tiagohm / markdownview Goto Github PK
View Code? Open in Web Editor NEWAndroid library to display markdown text.
License: Apache License 2.0
Android library to display markdown text.
License: Apache License 2.0
I wanted to get the internal webview from the markdown view, so that I will be able to provent the links from opening on the browser (I'll catch the event and then, open the tapped link in a chrome tab). Is there any way to do this? Or maybe an way to open links directly on chrome tabs?
Are there any Proguard rules that need to be added when using this library? I'm seeing warnings related to Flexmark, like:
Warning: com.vladsch.flexmark.util.ImageUtils: can't find referenced class javax.swing.ImageIcon
MarkdownView markdownView = (MarkdownView)rootView.findViewById(R.id.goldcoasttour_detail);
Gives me "Unexpected castdown to MarkdownView: layout tag was TextView .... "
I'm importing:
import android.support.v4.app.Fragment;
Runtime exception:
Caused by: java.lang.ClassCastException: android.support.v7.widget.AppCompatTextView cannot be cast to br.tiagohm.markdownview.MarkdownView
at org.goldrushtrail.TourDetailFragment.onCreateView(TourDetailFragment.java:73)
at android.support.v4.app.Fragment.performCreateView(Fragment.java:2189)
at android.support.v4.app.FragmentManagerImpl.moveToState(FragmentManager.java:1299)
at android.support.v4.app.FragmentManagerImpl.moveFragmentToExpectedState(FragmentManager.java:1528)
at android.support.v4.app.FragmentManagerImpl.moveToState(FragmentManager.java:1595)
at android.support.v4.app.BackStackRecord.executeOps(BackStackRecord.java:757)
at android.support.v4.app.FragmentManagerImpl.executeOps(FragmentManager.java:2355)
at android.support.v4.app.FragmentManagerImpl.executeOpsTogether(FragmentManager.java:2146)
at android.support.v4.app.FragmentManagerImpl.optimizeAndExecuteOps(FragmentManager.java:2098)
at android.support.v4.app.FragmentManagerImpl.execPendingActions(FragmentManager.java:2008)
at android.support.v4.app.FragmentController.execPendingActions(FragmentController.java:388)
at android.support.v4.app.FragmentActivity.onStart(FragmentActivity.java:607)
at android.support.v7.app.AppCompatActivity.onStart(AppCompatActivity.java:178)
at android.app.Instrumentation.callActivityOnStart(Instrumentation.java:1248)
at android.app.Activity.performStart(Activity.java:6679)
Hello,
First of all thanks for the library. It's working great! I have one question though:
Cheers,
This library is working great. I would like to request, for the addition of following features. They might be helpful to many (not sure if everything would be possible, though).
Thanks again for this nice library.
How to capture events?
Init load conent
Generating...
Finished renderized content
This is library and having "app_name" doesn't make sense here. Furthermore it makes problems in applications that uses this library.
Please remove that "app_name" from strings.xml
Can this library be used without wanting JavaScript? Does this use webview?
Hi
Is there a way to make paragraph text to appear as rtl for languges that start from right to left? I tried: addRule("body", "direction: rtl", "padding: 0px");
it makes all element rtl except the paragraph. Also, I don't want the user to type {.text-right }
in all his paragraphs.
Thanks for this awesome library 😙
Something like
mMarkdownView.loadMarkdownFromFile(FileName, STYLE);
mMarkdownView.loadMarkdownFromUrl(Url, STYLE);
Would be great to provide the two features. Would really help.
Thanks
Can i disable the FAB?
NO mMarkdownView.setOnElementListener?
O Android Studio atualizou o Gradle para 3.3 mas o JitPack usa a versão 3.1 como padrão.
How do i load images that are present inside the assets folder?
It seems that this library doesn't support mathjax expression like
Example:
For expression $$A = \int_{a}^{b} \vec F \cdot d \vec r$$
,
current result is: <p><span class="math" a="" b="">$$A = \int_^ \vec F \cdot d \vec r$$</span></p>
expected result is <p><span class="math">$$A = \int_{a}^{b} \vec F \cdot d \vec r$$</span></p>
.
Hi, thanks for this fabulous project, I am able to render markdown, but how to set the background to transparent? The android default background color is not white, you know, so, things get wired if the color not transparent, if you kindly give me a snippt I would be very thankful!
Hope friends can add the following functions.
I have attempted to test your library using instructions in the README. I get a manifest merge failure...
FAILURE: Build failed with an exception.
* What went wrong:
Execution failed for task ':processDebugManifest'.
> Manifest merger failed : Attribute application@label value=(@string/appName) from AndroidManifest.xml:41:7-38
is also present at [com.github.tiagohm.MarkdownView:library:0.16.0] AndroidManifest.xml:13:9-41 value=(@string/app_name).
Suggestion: add 'tools:replace="android:label"' to <application> element at AndroidManifest.xml:37:3-61:17 to override.
I have done that, it makes no difference...
<application
tools:ignore="AllowBackup"
android:allowBackup="true"
android:icon="@drawable/ic_launcher"
android:label="@string/appName"
android:theme="@style/AppTheme"
tools:replace="android:label">
There is no reason to have an android:label
in the manifest for a library, you don't need an application
section either. All you need is this:
<?xml version="1.0" encoding="utf-8"?>
<manifest
xmlns:android="http://schemas.android.com/apk/res/android"
package="org.billthefarmer.mididriver" />
Substitute the package name for your library.
eg:
Is posible add support for aligment paragraph?
text align left (default)
text align center
text align right
text align justify
I found the MarkdownView parses markdown article in android main thread and would cause device lag. It'll be better to parse the markdown article in a new thread.
I have a feed where multiple markdown views are displayed. But it hangs while rendering. No issue in logs file.
There are no uses Android API above 15 in the code, so minSdk can be downgraded.
As the title says. Right now it adds extra unneeded clutter to the webpage.
使用这个控件会造成内存WebView的内存泄露 。
Hello,
Can MarkDownView support Dark and Light Themes?
Thanks
Can you add a simple dark mode theme?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.