translation improvement 6
This commit is contained in:
@@ -248,6 +248,8 @@ ScanFormWidget::ScanFormWidget(QWidget* parent) : TabFormWidget(parent) {
|
||||
lbl_Protocol->setText(tr("Protocol"));
|
||||
lblPreview->setText(tr("Preview Parameters"));
|
||||
lblParams->setText(tr("Scan Parameters"));
|
||||
lbl_e->setText(tr("some settings\n\nparameters\n"));
|
||||
lbl_e2->setText(tr("some settings\n\nparameters\n"));
|
||||
});
|
||||
|
||||
|
||||
|
||||
@@ -1,62 +1,68 @@
|
||||
#include "patientinformationform.h"
|
||||
#include "ui_patientinformationform.h"
|
||||
#include "json/cJSON.h"
|
||||
PatientInformationForm::PatientInformationForm(QWidget *parent) :
|
||||
QWidget(parent),
|
||||
ui(new Ui::PatientInformationForm)
|
||||
#include "event/EventCenter.h"
|
||||
|
||||
PatientInformationForm::PatientInformationForm(QWidget* parent) :
|
||||
QWidget(parent),
|
||||
ui(new Ui::PatientInformationForm)
|
||||
{
|
||||
ui->setupUi(this);
|
||||
ui->lbl_ID->setText("");
|
||||
ui->lbl_Date->setText("");
|
||||
ui->lbl_Name->setText("");
|
||||
ui->lbl_Sex->setText("");
|
||||
ui->lbl_Acc->setText("");
|
||||
ui->setupUi(this);
|
||||
//ui->lbl_ID->setText(tr(""));
|
||||
//ui->lbl_Date->setText(tr(""));
|
||||
//ui->lbl_Name->setText(tr(""));
|
||||
//ui->lbl_Sex->setText(tr(""));
|
||||
//ui->lbl_Acc->setText(tr(""));
|
||||
|
||||
connect(EventCenter::Default(), &EventCenter::ReloadLanguage, [=]() {
|
||||
ui->retranslateUi(this);
|
||||
});
|
||||
}
|
||||
|
||||
PatientInformationForm::~PatientInformationForm()
|
||||
{
|
||||
delete ui;
|
||||
delete inf;
|
||||
delete jsonstr;
|
||||
delete ui;
|
||||
delete inf;
|
||||
delete jsonstr;
|
||||
}
|
||||
|
||||
void PatientInformationForm::setPatientInformation(PatientInformation* information) {
|
||||
ui->lbl_ID->setText(information->ID);
|
||||
ui->lbl_Date->setText(information->BirthDate);
|
||||
ui->lbl_Name->setText(information->Name);
|
||||
ui->lbl_Sex->setText(information->Sex);
|
||||
inf = information;
|
||||
ui->lbl_ID->setText(information->ID);
|
||||
ui->lbl_Date->setText(information->BirthDate);
|
||||
ui->lbl_Name->setText(information->Name);
|
||||
ui->lbl_Sex->setText(information->Sex);
|
||||
inf = information;
|
||||
}
|
||||
|
||||
void PatientInformationForm::setProtocol(int type) {
|
||||
currentProtocol = type;
|
||||
switch(type)
|
||||
{
|
||||
case 0:
|
||||
ui->lbl_Protocol->setText("LEFT ONLY");
|
||||
break;
|
||||
case 1:
|
||||
default:
|
||||
ui->lbl_Protocol->setText("RIGHT ONLY");
|
||||
break;
|
||||
}
|
||||
currentProtocol = type;
|
||||
switch (type)
|
||||
{
|
||||
case 0:
|
||||
ui->lbl_Protocol->setText(tr("LEFT ONLY"));
|
||||
break;
|
||||
case 1:
|
||||
default:
|
||||
ui->lbl_Protocol->setText(tr("RIGHT ONLY"));
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
const char *PatientInformationForm::getCurrentPatientJsonString(bool empty) {
|
||||
cJSON* root=cJSON_CreateObject();
|
||||
cJSON_AddItemToObject(root, "PatientName",cJSON_CreateString(ui->lbl_Name->text().replace(' ','_').toStdString().data()));
|
||||
cJSON_AddItemToObject(root, "PatientID",cJSON_CreateString(ui->lbl_ID->text().replace(' ','_').toStdString().data()));
|
||||
cJSON_AddItemToObject(root, "PatientSex",cJSON_CreateString(ui->lbl_Sex->text().toStdString().data()));
|
||||
cJSON_AddItemToObject(root, "PatientBirthDate",
|
||||
cJSON_CreateString(ui->lbl_Date->text().replace("/","").replace("-","").replace(' ','.').toStdString().data()));
|
||||
cJSON_AddItemToObject(root, "Laterality",cJSON_CreateString(currentProtocol?"R":"L"));
|
||||
cJSON_AddItemToObject(root, "IsEmptyData",cJSON_CreateNumber(empty?1:0));
|
||||
cJSON_AddItemToObject(root, "OperatorName",cJSON_CreateString("Bob"));
|
||||
cJSON_AddItemToObject(root, "ReferringPhysicianName",cJSON_CreateString("XX"));
|
||||
cJSON_AddItemToObject(root, "InstitutionName",cJSON_CreateString("EQ9"));
|
||||
cJSON_AddItemToObject(root, "InstitutionAddress",cJSON_CreateString("HZ"));
|
||||
delete jsonstr;
|
||||
jsonstr = cJSON_Print(root);
|
||||
cJSON_Delete(root);
|
||||
return jsonstr;
|
||||
const char* PatientInformationForm::getCurrentPatientJsonString(bool empty) {
|
||||
cJSON* root = cJSON_CreateObject();
|
||||
cJSON_AddItemToObject(root, "PatientName", cJSON_CreateString(ui->lbl_Name->text().replace(' ', '_').toStdString().data()));
|
||||
cJSON_AddItemToObject(root, "PatientID", cJSON_CreateString(ui->lbl_ID->text().replace(' ', '_').toStdString().data()));
|
||||
cJSON_AddItemToObject(root, "PatientSex", cJSON_CreateString(ui->lbl_Sex->text().toStdString().data()));
|
||||
cJSON_AddItemToObject(root, "PatientBirthDate",
|
||||
cJSON_CreateString(ui->lbl_Date->text().replace("/", "").replace("-", "").replace(' ', '.').toStdString().data()));
|
||||
cJSON_AddItemToObject(root, "Laterality", cJSON_CreateString(currentProtocol ? "R" : "L"));
|
||||
cJSON_AddItemToObject(root, "IsEmptyData", cJSON_CreateNumber(empty ? 1 : 0));
|
||||
cJSON_AddItemToObject(root, "OperatorName", cJSON_CreateString("Bob"));
|
||||
cJSON_AddItemToObject(root, "ReferringPhysicianName", cJSON_CreateString("XX"));
|
||||
cJSON_AddItemToObject(root, "InstitutionName", cJSON_CreateString("EQ9"));
|
||||
cJSON_AddItemToObject(root, "InstitutionAddress", cJSON_CreateString("HZ"));
|
||||
delete jsonstr;
|
||||
jsonstr = cJSON_Print(root);
|
||||
cJSON_Delete(root);
|
||||
return jsonstr;
|
||||
}
|
||||
|
||||
@@ -424,6 +424,10 @@
|
||||
<source>LEFT ONLY</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>RIGHT ONLY</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
</context>
|
||||
<context>
|
||||
<name>RollingMessageWidget</name>
|
||||
@@ -600,6 +604,10 @@ parameters
|
||||
<source>DICOM Settings</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>...</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
</context>
|
||||
<context>
|
||||
<name>networkCfgDialog</name>
|
||||
|
||||
@@ -424,6 +424,10 @@
|
||||
<source>LEFT ONLY</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>RIGHT ONLY</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
</context>
|
||||
<context>
|
||||
<name>RollingMessageWidget</name>
|
||||
|
||||
Binary file not shown.
@@ -588,12 +588,22 @@
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../../out/build/x64-Debug/ui_patientinformationform.h" line="128"/>
|
||||
<location filename="../patientinformationform.cpp" line="42"/>
|
||||
<source>LEFT ONLY</source>
|
||||
<translation>左侧</translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>Name</source>
|
||||
<translation type="obsolete">姓名</translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>Gender</source>
|
||||
<translation type="obsolete">性别</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../patientinformationform.cpp" line="46"/>
|
||||
<source>RIGHT ONLY</source>
|
||||
<translation type="vanished">右侧</translation>
|
||||
<translation>右侧</translation>
|
||||
</message>
|
||||
</context>
|
||||
<context>
|
||||
@@ -662,6 +672,8 @@
|
||||
<message>
|
||||
<location filename="../ScanFormWidget.cpp" line="101"/>
|
||||
<location filename="../ScanFormWidget.cpp" line="113"/>
|
||||
<location filename="../ScanFormWidget.cpp" line="251"/>
|
||||
<location filename="../ScanFormWidget.cpp" line="252"/>
|
||||
<source>some settings
|
||||
|
||||
parameters
|
||||
@@ -827,7 +839,7 @@ parameters
|
||||
<location filename="../../out/build/x64-Debug/ui_dicomcfgdialog.h" line="333"/>
|
||||
<location filename="../../out/build/x64-Debug/ui_dicomcfgdialog.h" line="339"/>
|
||||
<source>...</source>
|
||||
<translation type="unfinished">DICOM</translation>
|
||||
<translation>DICOM</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../../out/build/x64-Debug/ui_dicomcfgdialog.h" line="334"/>
|
||||
@@ -1001,7 +1013,7 @@ parameters
|
||||
<message>
|
||||
<location filename="../../out/build/x64-Debug/ui_systemsettingform.h" line="231"/>
|
||||
<source>Protocal</source>
|
||||
<translation>扫描协议</translation>
|
||||
<translation>默认扫描协议</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../../out/build/x64-Debug/ui_systemsettingform.h" line="235"/>
|
||||
|
||||
@@ -588,12 +588,22 @@
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../../out/build/x64-Debug/ui_patientinformationform.h" line="128"/>
|
||||
<location filename="../patientinformationform.cpp" line="42"/>
|
||||
<source>LEFT ONLY</source>
|
||||
<translation>左侧</translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>Name</source>
|
||||
<translation type="obsolete">姓名</translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>Gender</source>
|
||||
<translation type="obsolete">性别</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../patientinformationform.cpp" line="46"/>
|
||||
<source>RIGHT ONLY</source>
|
||||
<translation type="vanished">右侧</translation>
|
||||
<translation>右侧</translation>
|
||||
</message>
|
||||
</context>
|
||||
<context>
|
||||
@@ -662,6 +672,8 @@
|
||||
<message>
|
||||
<location filename="../ScanFormWidget.cpp" line="101"/>
|
||||
<location filename="../ScanFormWidget.cpp" line="113"/>
|
||||
<location filename="../ScanFormWidget.cpp" line="251"/>
|
||||
<location filename="../ScanFormWidget.cpp" line="252"/>
|
||||
<source>some settings
|
||||
|
||||
parameters
|
||||
@@ -827,7 +839,7 @@ parameters
|
||||
<location filename="../../out/build/x64-Debug/ui_dicomcfgdialog.h" line="333"/>
|
||||
<location filename="../../out/build/x64-Debug/ui_dicomcfgdialog.h" line="339"/>
|
||||
<source>...</source>
|
||||
<translation type="unfinished">DICOM</translation>
|
||||
<translation>DICOM</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../../out/build/x64-Debug/ui_dicomcfgdialog.h" line="334"/>
|
||||
@@ -1001,7 +1013,7 @@ parameters
|
||||
<message>
|
||||
<location filename="../../out/build/x64-Debug/ui_systemsettingform.h" line="231"/>
|
||||
<source>Protocal</source>
|
||||
<translation>扫描协议</translation>
|
||||
<translation>默认扫描协议</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../../out/build/x64-Debug/ui_systemsettingform.h" line="235"/>
|
||||
|
||||
Reference in New Issue
Block a user