-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathcreatelexicalentrydialog.h
68 lines (51 loc) · 1.7 KB
/
createlexicalentrydialog.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
/*!
\class CreateLexicalEntryDialog
\ingroup MorphologicalAnalysis
\brief A form for creating a lexical entry in the database. See createlexicalentrydialog.ui. It is instantiated both in LexicalEntryForm and AnalysisWidget.
*/
#ifndef CREATELEXICALENTRYDIALOG_H
#define CREATELEXICALENTRYDIALOG_H
#include <QDialog>
#include <QList>
class DatabaseAdapter;
class GlossItem;
class LingEdit;
class Allomorph;
class Project;
class LexiconLineForm;
#include "allomorph.h"
namespace Ui {
class CreateLexicalEntryDialog;
}
class CreateLexicalEntryDialog : public QDialog
{
Q_OBJECT
public:
CreateLexicalEntryDialog(qlonglong lexicalEntryId, bool hideGuessButton, const GlossItem *glossItem, const Project *project, QWidget *parent = nullptr);
CreateLexicalEntryDialog(const TextBit & allomorphString, bool hideGuessButton, bool isMonomorphemic, const GlossItem *glossItem, const Project *project, QWidget *parent = nullptr);
~CreateLexicalEntryDialog();
qlonglong lexicalEntryId() const;
TextBitHash glosses() const;
QStringList grammaticalTags() const;
signals:
void linkToOther();
private:
Ui::CreateLexicalEntryDialog *ui;
TextBit mAllomorphString;
const Project * mProject;
const DatabaseAdapter * mDbAdapter;
const GlossItem * mGlossItem;
bool mIsMonomorphemic;
qlonglong mLexicalEntryId;
bool mHideGuessButton;
QList<LexiconLineForm*> mGlossEdits;
QList<LexiconLineForm*> mCitationFormEdits;
void addMorphemeTypes();
Allomorph::Type morphemeType() const;
private slots:
void guessAppropriateValues();
void fillFromDatabase();
void createLexicalEntry();
void changeLexicalEntry();
};
#endif // CREATELEXICALENTRYDIALOG_H