(window.webpackJsonp=window.webpackJsonp||[]).push([[30],{278:function(t,n,a){"use strict";a.r(n);var s=a(0),e=Object(s.a)({},function(){var t=this,n=t.$createElement,a=t._self._c||n;return a("div",{staticClass:"content"},[t._m(0),t._v(" "),a("LegacyWarning"),t._v(" "),a("MavenBadge2xx",{attrs:{artifact:"markwon-view"}}),t._v(" "),a("p",[t._v("This is simple library containing 2 views that are able to display markdown:")]),t._v(" "),t._m(1),t._v(" "),t._m(2),t._v(" "),t._m(3),a("p",[t._v("Both views support layout-preview in Android Studio (with some exceptions, for example, bold span is not rendered due to some limitations of layout preview).\nThese are XML attributes:")]),t._v(" "),t._m(4),t._m(5),t._v(" "),t._m(6),t._v(" "),a("p",[t._v("Please note that those views parse markdown in main thread, so their usage must be for relatively small markdown portions only")])],1)},[function(){var t=this.$createElement,n=this._self._c||t;return n("h1",{attrs:{id:"markwonview"}},[n("a",{staticClass:"header-anchor",attrs:{href:"#markwonview","aria-hidden":"true"}},[this._v("#")]),this._v(" MarkwonView")])},function(){var t=this.$createElement,n=this._self._c||t;return n("ul",[n("li",[this._v("MarkwonView - extends "),n("code",[this._v("android.view.TextView")])]),this._v(" "),n("li",[this._v("MarkwonViewCompat - extends "),n("code",[this._v("android.support.v7.widget.AppCompatTextView")])])])},function(){var t=this.$createElement,n=this._self._c||t;return n("p",[this._v("Both of them implement common "),n("code",[this._v("IMarkwonView")]),this._v(" interface:")])},function(){var t=this,n=t.$createElement,a=t._self._c||n;return a("div",{staticClass:"language-java extra-class"},[a("pre",{pre:!0,attrs:{class:"language-java"}},[a("code",[a("span",{attrs:{class:"token keyword"}},[t._v("public")]),t._v(" "),a("span",{attrs:{class:"token keyword"}},[t._v("interface")]),t._v(" "),a("span",{attrs:{class:"token class-name"}},[t._v("IMarkwonView")]),t._v(" "),a("span",{attrs:{class:"token punctuation"}},[t._v("{")]),t._v("\n\n "),a("span",{attrs:{class:"token keyword"}},[t._v("interface")]),t._v(" "),a("span",{attrs:{class:"token class-name"}},[t._v("ConfigurationProvider")]),t._v(" "),a("span",{attrs:{class:"token punctuation"}},[t._v("{")]),t._v("\n "),a("span",{attrs:{class:"token annotation punctuation"}},[t._v("@NonNull")]),t._v("\n SpannableConfiguration "),a("span",{attrs:{class:"token function"}},[t._v("provide")]),a("span",{attrs:{class:"token punctuation"}},[t._v("(")]),a("span",{attrs:{class:"token annotation punctuation"}},[t._v("@NonNull")]),t._v(" Context context"),a("span",{attrs:{class:"token punctuation"}},[t._v(")")]),a("span",{attrs:{class:"token punctuation"}},[t._v(";")]),t._v("\n "),a("span",{attrs:{class:"token punctuation"}},[t._v("}")]),t._v("\n\n "),a("span",{attrs:{class:"token keyword"}},[t._v("void")]),t._v(" "),a("span",{attrs:{class:"token function"}},[t._v("setConfigurationProvider")]),a("span",{attrs:{class:"token punctuation"}},[t._v("(")]),a("span",{attrs:{class:"token annotation punctuation"}},[t._v("@NonNull")]),t._v(" ConfigurationProvider provider"),a("span",{attrs:{class:"token punctuation"}},[t._v(")")]),a("span",{attrs:{class:"token punctuation"}},[t._v(";")]),t._v("\n\n "),a("span",{attrs:{class:"token keyword"}},[t._v("void")]),t._v(" "),a("span",{attrs:{class:"token function"}},[t._v("setMarkdown")]),a("span",{attrs:{class:"token punctuation"}},[t._v("(")]),a("span",{attrs:{class:"token annotation punctuation"}},[t._v("@Nullable")]),t._v(" String markdown"),a("span",{attrs:{class:"token punctuation"}},[t._v(")")]),a("span",{attrs:{class:"token punctuation"}},[t._v(";")]),t._v("\n "),a("span",{attrs:{class:"token keyword"}},[t._v("void")]),t._v(" "),a("span",{attrs:{class:"token function"}},[t._v("setMarkdown")]),a("span",{attrs:{class:"token punctuation"}},[t._v("(")]),a("span",{attrs:{class:"token annotation punctuation"}},[t._v("@Nullable")]),t._v(" SpannableConfiguration configuration"),a("span",{attrs:{class:"token punctuation"}},[t._v(",")]),t._v(" "),a("span",{attrs:{class:"token annotation punctuation"}},[t._v("@Nullable")]),t._v(" String markdown"),a("span",{attrs:{class:"token punctuation"}},[t._v(")")]),a("span",{attrs:{class:"token punctuation"}},[t._v(";")]),t._v("\n\n "),a("span",{attrs:{class:"token annotation punctuation"}},[t._v("@Nullable")]),t._v("\n String "),a("span",{attrs:{class:"token function"}},[t._v("getMarkdown")]),a("span",{attrs:{class:"token punctuation"}},[t._v("(")]),a("span",{attrs:{class:"token punctuation"}},[t._v(")")]),a("span",{attrs:{class:"token punctuation"}},[t._v(";")]),t._v("\n"),a("span",{attrs:{class:"token punctuation"}},[t._v("}")]),t._v("\n")])])])},function(){var t=this.$createElement,n=this._self._c||t;return n("div",{staticClass:"language-xml extra-class"},[n("pre",{pre:!0,attrs:{class:"language-xml"}},[n("code",[this._v('app:mv_markdown="string"\napp:mv_configurationProvider="string"\n')])])])},function(){var t=this.$createElement,n=this._self._c||t;return n("p",[n("code",[this._v("mv_markdown")]),this._v(" accepts a string and represents raw markdown")])},function(){var t=this.$createElement,n=this._self._c||t;return n("p",[n("code",[this._v("mv_configurationProvider")]),this._v(" accepts a string and represents a full class name of a class of type "),n("code",[this._v("ConfigurationProvider")]),this._v(",\nfor example: "),n("code",[this._v("com.example.my.package.MyConfigurationProvider")]),this._v(" (this class must have an empty constructor\nin order to be instantiated via reflection).")])}],!1,null,null,null);e.options.__file="view.md";n.default=e.exports}}]);