mirror of
https://github.com/xiaoyifang/goldendict-ng.git
synced 2024-11-27 19:24:08 +00:00
Tune headwords presentation in xdxf dictionaries
This commit is contained in:
parent
64bb5c00ca
commit
7fc5f59f77
|
@ -210,6 +210,7 @@ div.xdxf
|
||||||
|
|
||||||
.xdxf_headwords
|
.xdxf_headwords
|
||||||
{
|
{
|
||||||
|
font-size: 116%;
|
||||||
font-weight: bold;
|
font-weight: bold;
|
||||||
margin-top: 10px;
|
margin-top: 10px;
|
||||||
margin-bottom: 10px;
|
margin-bottom: 10px;
|
||||||
|
|
17
xdxf.cc
17
xdxf.cc
|
@ -168,7 +168,6 @@ private:
|
||||||
/// Loads the article, storing its headword and formatting the data it has
|
/// Loads the article, storing its headword and formatting the data it has
|
||||||
/// into an html.
|
/// into an html.
|
||||||
void loadArticle( uint32_t address,
|
void loadArticle( uint32_t address,
|
||||||
string & headword,
|
|
||||||
string & articleText );
|
string & articleText );
|
||||||
|
|
||||||
friend class XdxfArticleRequest;
|
friend class XdxfArticleRequest;
|
||||||
|
@ -446,7 +445,8 @@ void XdxfArticleRequest::run()
|
||||||
|
|
||||||
string headword, articleText;
|
string headword, articleText;
|
||||||
|
|
||||||
dict.loadArticle( chain[ x ].articleOffset, headword, articleText );
|
headword = chain[ x ].word;
|
||||||
|
dict.loadArticle( chain[ x ].articleOffset, articleText );
|
||||||
|
|
||||||
// Ok. Now, does it go to main articles, or to alternate ones? We list
|
// Ok. Now, does it go to main articles, or to alternate ones? We list
|
||||||
// main ones first, and alternates after.
|
// main ones first, and alternates after.
|
||||||
|
@ -485,18 +485,18 @@ void XdxfArticleRequest::run()
|
||||||
|
|
||||||
for( i = mainArticles.begin(); i != mainArticles.end(); ++i )
|
for( i = mainArticles.begin(); i != mainArticles.end(); ++i )
|
||||||
{
|
{
|
||||||
result += "<h3>";
|
// result += "<h3>";
|
||||||
result += i->second.first;
|
// result += i->second.first;
|
||||||
result += "</h3>";
|
// result += "</h3>";
|
||||||
result += i->second.second;
|
result += i->second.second;
|
||||||
result += cleaner;
|
result += cleaner;
|
||||||
}
|
}
|
||||||
|
|
||||||
for( i = alternateArticles.begin(); i != alternateArticles.end(); ++i )
|
for( i = alternateArticles.begin(); i != alternateArticles.end(); ++i )
|
||||||
{
|
{
|
||||||
result += "<h3>";
|
// result += "<h3>";
|
||||||
result += i->second.first;
|
// result += i->second.first;
|
||||||
result += "</h3>";
|
// result += "</h3>";
|
||||||
result += i->second.second;
|
result += i->second.second;
|
||||||
result += cleaner;
|
result += cleaner;
|
||||||
}
|
}
|
||||||
|
@ -521,7 +521,6 @@ sptr< Dictionary::DataRequest > XdxfDictionary::getArticle( wstring const & word
|
||||||
}
|
}
|
||||||
|
|
||||||
void XdxfDictionary::loadArticle( uint32_t address,
|
void XdxfDictionary::loadArticle( uint32_t address,
|
||||||
string & headword,
|
|
||||||
string & articleText )
|
string & articleText )
|
||||||
{
|
{
|
||||||
// Read the properties
|
// Read the properties
|
||||||
|
|
Loading…
Reference in a new issue