Rev 159 | Rev 249 | Go to most recent revision | Details | Compare with Previous | Last modification | View Log | RSS feed
Rev | Author | Line No. | Line |
---|---|---|---|
3 | paul | 1 | #ifndef HYPLUG_H |
2 | #define HYPLUG_H |
||
3 | |||
4 | #include <qobject.h> |
||
106 | Franz | 5 | #include <qtextcodec.h> |
3 | paul | 6 | #include "hyphen.h" |
7 | class ScribusDoc; |
||
8 | class ScribusApp; |
||
9 | class PageItem; |
||
10 | |||
159 | Franz | 11 | /*! |
12 | This class is the core of the Scribus hyphenation system. |
||
13 | */ |
||
14 | |||
3 | paul | 15 | class Hyphenator : public QObject |
16 | { |
||
17 | Q_OBJECT |
||
18 | |||
19 | public: |
||
20 | Hyphenator(QWidget* parent, ScribusDoc *dok, ScribusApp* app); |
||
21 | ~Hyphenator(); |
||
159 | Franz | 22 | /*! There are languages having rule not to hyphen word shorter than |
23 | MinWordLen */ |
||
168 | Franz | 24 | int MinWordLen; |
159 | Franz | 25 | /*! Language in use */ |
168 | Franz | 26 | QString Language; |
159 | Franz | 27 | /*! Flag - if user set auto hyphen processing.*/ |
168 | Franz | 28 | bool Automatic; |
159 | Franz | 29 | /*! Flag - obsolete? */ |
168 | Franz | 30 | bool AutoCheck; |
159 | Franz | 31 | /*! Reference to the hyphen dictionary structure. */ |
168 | Franz | 32 | HyphenDict *hdict; |
159 | Franz | 33 | /*! Embeded reference to the \see ScribusDoc filled by \a dok */ |
168 | Franz | 34 | ScribusDoc *doc; |
159 | Franz | 35 | /*! Embeded reference to the \see ScribusApp filled by \a app */ |
168 | Franz | 36 | ScribusApp *Sap; |
159 | Franz | 37 | /*! Flag - if is the dictionary without errors etc. If is it 'false' |
38 | hyphen aborted. */ |
||
168 | Franz | 39 | bool useAble; |
159 | Franz | 40 | /*! Qt text codec which handles local characters. */ |
168 | Franz | 41 | QTextCodec *codec; |
3 | paul | 42 | |
43 | public slots: |
||
168 | Franz | 44 | void slotNewDict(QString name); |
45 | void slotNewSettings(int Wordlen, bool Autom, bool ACheck); |
||
46 | void slotHyphenateWord(PageItem* it, QString text, int firstC); |
||
47 | void slotHyphenate(PageItem *it); |
||
3 | paul | 48 | }; |
49 | #endif |