refine Chinese translations

This commit is contained in:
Le Tan 2018-03-21 21:01:39 +08:00
parent b8a8ed974b
commit 507568ae2c
5 changed files with 1474 additions and 611 deletions

Binary file not shown.

File diff suppressed because it is too large Load Diff

View File

@ -185,7 +185,7 @@ void VSearcher::setupUI()
connect(m_cancelBtn, &QPushButton::clicked, connect(m_cancelBtn, &QPushButton::clicked,
this, [this]() { this, [this]() {
if (m_inSearch) { if (m_inSearch) {
appendLogLine(tr("Cancelling the export...")); appendLogLine(tr("Cancelling the search..."));
m_askedToStop = true; m_askedToStop = true;
m_search.stop(); m_search.stop();
} }

View File

@ -7,12 +7,9 @@
#include "vbuttonwithwidget.h" #include "vbuttonwithwidget.h"
#include "vwordcountinfo.h" #include "vwordcountinfo.h"
class VWordCountPanel : public QWidget VWordCountPanel::VWordCountPanel(QWidget *p_parent)
{
public:
VWordCountPanel(QWidget *p_parent)
: QWidget(p_parent) : QWidget(p_parent)
{ {
m_wordLabel = new QLabel(); m_wordLabel = new QLabel();
m_wordLabel->setAlignment(Qt::AlignRight | Qt::AlignVCenter); m_wordLabel->setAlignment(Qt::AlignRight | Qt::AlignVCenter);
m_charWithoutSpacesLabel = new QLabel(); m_charWithoutSpacesLabel = new QLabel();
@ -54,10 +51,10 @@ public:
setLayout(mainLayout); setLayout(mainLayout);
setMinimumWidth(300); setMinimumWidth(300);
} }
void updateReadInfo(const VWordCountInfo &p_readInfo) void VWordCountPanel::updateReadInfo(const VWordCountInfo &p_readInfo)
{ {
if (p_readInfo.isNull()) { if (p_readInfo.isNull()) {
m_wordLabel->clear(); m_wordLabel->clear();
m_charWithoutSpacesLabel->clear(); m_charWithoutSpacesLabel->clear();
@ -67,10 +64,10 @@ public:
m_charWithoutSpacesLabel->setText(QString::number(p_readInfo.m_charWithoutSpacesCount)); m_charWithoutSpacesLabel->setText(QString::number(p_readInfo.m_charWithoutSpacesCount));
m_charWithSpacesLabel->setText(QString::number(p_readInfo.m_charWithSpacesCount)); m_charWithSpacesLabel->setText(QString::number(p_readInfo.m_charWithSpacesCount));
} }
} }
void updateEditInfo(const VWordCountInfo &p_editInfo) void VWordCountPanel::updateEditInfo(const VWordCountInfo &p_editInfo)
{ {
if (p_editInfo.isNull()) { if (p_editInfo.isNull()) {
m_wordEditLabel->clear(); m_wordEditLabel->clear();
m_charWithoutSpacesEditLabel->clear(); m_charWithoutSpacesEditLabel->clear();
@ -80,10 +77,10 @@ public:
m_charWithoutSpacesEditLabel->setText(QString::number(p_editInfo.m_charWithoutSpacesCount)); m_charWithoutSpacesEditLabel->setText(QString::number(p_editInfo.m_charWithoutSpacesCount));
m_charWithSpacesEditLabel->setText(QString::number(p_editInfo.m_charWithSpacesCount)); m_charWithSpacesEditLabel->setText(QString::number(p_editInfo.m_charWithSpacesCount));
} }
} }
void clear() void VWordCountPanel::clear()
{ {
m_wordLabel->clear(); m_wordLabel->clear();
m_charWithoutSpacesLabel->clear(); m_charWithoutSpacesLabel->clear();
m_charWithSpacesLabel->clear(); m_charWithSpacesLabel->clear();
@ -91,20 +88,8 @@ public:
m_wordEditLabel->clear(); m_wordEditLabel->clear();
m_charWithoutSpacesEditLabel->clear(); m_charWithoutSpacesEditLabel->clear();
m_charWithSpacesEditLabel->clear(); m_charWithSpacesEditLabel->clear();
} }
private:
QLabel *m_wordLabel;
QLabel *m_charWithoutSpacesLabel;
QLabel *m_charWithSpacesLabel;
QLabel *m_wordEditLabel;
QLabel *m_charWithoutSpacesEditLabel;
QLabel *m_charWithSpacesEditLabel;
QGroupBox *m_readBox;
QGroupBox *m_editBox;
};
VTabIndicator::VTabIndicator(QWidget *p_parent) VTabIndicator::VTabIndicator(QWidget *p_parent)
: QWidget(p_parent), : QWidget(p_parent),

View File

@ -8,6 +8,33 @@ class QLabel;
class VButtonWithWidget; class VButtonWithWidget;
class VEditTab; class VEditTab;
class VWordCountPanel; class VWordCountPanel;
class QGroupBox;
class VWordCountPanel : public QWidget
{
Q_OBJECT
public:
VWordCountPanel(QWidget *p_parent = nullptr);
void updateReadInfo(const VWordCountInfo &p_readInfo);
void updateEditInfo(const VWordCountInfo &p_editInfo);
void clear();
private:
QLabel *m_wordLabel;
QLabel *m_charWithoutSpacesLabel;
QLabel *m_charWithSpacesLabel;
QLabel *m_wordEditLabel;
QLabel *m_charWithoutSpacesEditLabel;
QLabel *m_charWithSpacesEditLabel;
QGroupBox *m_readBox;
QGroupBox *m_editBox;
};
class VTabIndicator : public QWidget class VTabIndicator : public QWidget
{ {