mirror of
https://github.com/xiaoyifang/goldendict-ng.git
synced 2024-11-30 17:24:08 +00:00
Use <div> tag instead of <span> to enclose articles
This commit is contained in:
parent
3adc5c0f42
commit
71ddc5c323
|
@ -623,7 +623,7 @@ void ArticleRequest::bodyFinished()
|
|||
|
||||
if ( closePrevSpan )
|
||||
{
|
||||
head += "</span></span><div style=\"clear:both;\"></div><span class=\"gdarticleseparator\"></span>";
|
||||
head += "</div></div><div style=\"clear:both;\"></div><span class=\"gdarticleseparator\"></span>";
|
||||
}
|
||||
else
|
||||
{
|
||||
|
@ -675,7 +675,7 @@ void ArticleRequest::bodyFinished()
|
|||
"if ( !gdArticleContents ) gdArticleContents = \"" + jsVal +" \"; "
|
||||
"else gdArticleContents += \"" + jsVal + " \";</script>";
|
||||
|
||||
head += string( "<span class=\"gdarticle" ) +
|
||||
head += string( "<div style=\"display:inline;\" class=\"gdarticle" ) +
|
||||
( closePrevSpan ? "" : " gdactivearticle" ) +
|
||||
( collapse ? " gdcollapsedarticle" : "" ) +
|
||||
"\" id=\"" + gdFrom +
|
||||
|
@ -701,7 +701,7 @@ void ArticleRequest::bodyFinished()
|
|||
|
||||
head += "<div class=\"gddictnamebodyseparator\"></div>";
|
||||
|
||||
head += "<span class=\"gdarticlebody gdlangfrom-";
|
||||
head += "<div class=\"gdarticlebody gdlangfrom-";
|
||||
head += LangCoder::intToCode2( activeDict->getLangFrom() ).toLatin1().data();
|
||||
head += "\" lang=\"";
|
||||
head += LangCoder::intToCode2( activeDict->getLangTo() ).toLatin1().data();
|
||||
|
@ -762,7 +762,7 @@ void ArticleRequest::bodyFinished()
|
|||
|
||||
if ( closePrevSpan )
|
||||
{
|
||||
footer += "</span></span>";
|
||||
footer += "</div></div>";
|
||||
closePrevSpan = false;
|
||||
}
|
||||
|
||||
|
|
6
dsl.cc
6
dsl.cc
|
@ -814,7 +814,7 @@ string DslDictionary::nodeToHtml( ArticleDom::Node const & node )
|
|||
string id = "O" + getId().substr( 0, 7 ) + "_" +
|
||||
QString::number( articleNom ).toStdString() +
|
||||
"_opt_" + QString::number( optionalPartNom++ ).toStdString();
|
||||
result += "<div class=\"dsl_opt\" id=\"" + id + "\">" + processNodeChildren( node ) + "</div>";
|
||||
result += "<span class=\"dsl_opt\" id=\"" + id + "\">" + processNodeChildren( node ) + "</span>";
|
||||
}
|
||||
else
|
||||
if ( node.tagName == GD_NATIVE_TO_WS( L"m" ) )
|
||||
|
@ -1662,7 +1662,7 @@ void DslArticleRequest::run()
|
|||
if( displayedHeadword.empty() || isDslWs( displayedHeadword[ 0 ] ) )
|
||||
displayedHeadword = word; // Special case - insided card
|
||||
|
||||
articleText += "<span class=\"dsl_article\">";
|
||||
articleText += "<div style=\"display:inline;\" class=\"dsl_article\">";
|
||||
articleText += "<div class=\"dsl_headwords\"";
|
||||
if( dict.isFromLanguageRTL() )
|
||||
articleText += " dir=\"rtl\"";
|
||||
|
@ -1686,7 +1686,7 @@ void DslArticleRequest::run()
|
|||
|
||||
articleAfter += dict.dslToHtml( articleBody, displayedHeadword );
|
||||
articleAfter += "</div>";
|
||||
articleAfter += "</span>";
|
||||
articleAfter += "</div>";
|
||||
|
||||
if( dict.hasHiddenZones() )
|
||||
{
|
||||
|
|
|
@ -609,7 +609,7 @@ void EpwingArticleRequest::run()
|
|||
return;
|
||||
}
|
||||
|
||||
string result = "<span class=\"epwing_article\">";
|
||||
string result = "<div style=\"display:inline;\" class=\"epwing_article\">";
|
||||
|
||||
multimap< wstring, pair< string, string > >::const_iterator i;
|
||||
|
||||
|
@ -629,7 +629,7 @@ void EpwingArticleRequest::run()
|
|||
result += i->second.second;
|
||||
}
|
||||
|
||||
result += "</span>";
|
||||
result += "</div>";
|
||||
|
||||
Mutex::Lock _( dataMutex );
|
||||
|
||||
|
|
4
gls.cc
4
gls.cc
|
@ -794,13 +794,13 @@ void GlsDictionary::loadArticle( uint32_t address,
|
|||
}
|
||||
|
||||
if( isToLanguageRTL() )
|
||||
article += "<span dir=\"rtl\">";
|
||||
article += "<div style=\"display:inline;\" dir=\"rtl\">";
|
||||
|
||||
QString text = QString::fromUtf8( articleBody.c_str(), articleBody.size() );
|
||||
article += filterResource( text );
|
||||
|
||||
if( isToLanguageRTL() )
|
||||
article += "</span>";
|
||||
article += "</div>";
|
||||
|
||||
article +="</div>";
|
||||
|
||||
|
|
|
@ -1296,11 +1296,11 @@ void StardictArticleRequest::run()
|
|||
result += i->second.first;
|
||||
result += "</h3>";
|
||||
if( dict.isToLanguageRTL() )
|
||||
result += "<span dir=\"rtl\">";
|
||||
result += "<div style=\"display:inline;\" dir=\"rtl\">";
|
||||
result += i->second.second;
|
||||
result += cleaner;
|
||||
if( dict.isToLanguageRTL() )
|
||||
result += "</span>";
|
||||
result += "</div>";
|
||||
}
|
||||
|
||||
for( i = alternateArticles.begin(); i != alternateArticles.end(); ++i )
|
||||
|
@ -1309,11 +1309,11 @@ void StardictArticleRequest::run()
|
|||
result += i->second.first;
|
||||
result += "</h3>";
|
||||
if( dict.isToLanguageRTL() )
|
||||
result += "<span dir=\"rtl\">";
|
||||
result += "<div style=\"display:inline;\" dir=\"rtl\">";
|
||||
result += i->second.second;
|
||||
result += cleaner;
|
||||
if( dict.isToLanguageRTL() )
|
||||
result += "</span>";
|
||||
result += "</div>";
|
||||
}
|
||||
|
||||
Mutex::Lock _( dataMutex );
|
||||
|
|
Loading…
Reference in a new issue