[go: up one dir, main page]

Menu

[r381]: / cwordtemplate.h  Maximize  Restore  History

Download this file

79 lines (69 with data), 2.5 kB

 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
69
70
71
72
73
74
75
76
77
78
/* Marcion
Copyright (C) 2009 - 2011 Milan Konvicka
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; version 2 of the License.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program */
#ifndef CWORDTEMPLATE_H
#define CWORDTEMPLATE_H
//
#include <QString>
#include <QFile>
#include <QTextStream>
#include "ctranslit.h"
//
class CWordTemplate
{
//Q_OBJECT
public:
CWordTemplate(bool,bool,
QString ,
QString ,
QString );
CWordTemplate(CWordTemplate const &);
CWordTemplate(){}
CWordTemplate & operator=(CWordTemplate const &);
enum Mode{
ReadWord,EditWord,ReadDeriv,EditDeriv,Header,Html
};
void setKey(int),
setKey(QString const &),
setType(short int),
setCrum(QString const &),
setQuality(short int),
setWord(QString const &),
setCzech(QString const &),
setEnglish(QString const &),
setGreek(QString const &),
setTable(QString const &),
setWordKey(QString const &),
setDerivCount(QString const &),
setCreatedBy(QString const &),
setCreatedAt(QString const &),
setUpdatedBy(QString const &),
setUpdatedAt(QString const &),
setNoDerivCount(),
setNoQuality();
void changeWord(QString const &);
void changeEn(QString const &);
void changeCz(QString const &);
QString wordTr() const {return word;}
QString czTr() const {return czech;}
QString enTr() const {return english;}
QString create(Mode mode);
static QString formatw(QString const &, bool brackets=true);
private:
void init();
QString header,editderiv,editword;
bool coptic_edit, show_czech;
QString border, padding, spacing;
static QString const c_header,c_editderiv,c_editword,c_html;
QString key,type,crum,quality,
word,czech,english,greek,wordkey,table,derivcount,crby,crat,updby,updat;
};
#endif