我有這是一個包含HTML標記這樣如何在Android佈局中顯示Html內容?
<h4>Standard Web Browser Components</h4>
<p>Let’s lay out a few components of the modern day web browser:</p>
<ul>
<li>Parsing (HTML, XML, CSS, JavaScript)</li>
<li>Layout</li>
<li>Text and graphics rendering</li>
<li>Image decoding</li>
<li>GPU interaction</li>
<li>Network access</li>
<li>Hardware acceleration</li>
</ul>
<header>
<h1 class="entry-title"><a href="/2012/chrome-canary-for-developers/">Chrome Canary for Developers</a></h1>
<p class="meta">
<time datetime="2012-11-02T08:16:00+04:00" pubdate data-updated="true">Nov 2<span>nd</span>, 2012</time>
</p>
</header>
我想在我的Android佈局解析這個PHP文件。我是這樣做的
webtext.setText(Html.fromHtml(content));
但我失去了內容的風格和顏色。如何在不丟失樣式的情況下在我的佈局中顯示。
您的課程沒有定義。您可能會缺少樣式定義。 – Daniel