• Skip to content
  • Skip to link menu
KDE API Reference
  • KDE API Reference
  • kdesdk API Reference
  • KDE Home
  • Contact Us
 

lokalize

  • sources
  • kde-4.14
  • kdesdk
  • lokalize
  • src
alttransview.h
Go to the documentation of this file.
1 /* ****************************************************************************
2  This file is part of Lokalize
3 
4  Copyright (C) 2007-2008 by Nick Shaforostoff <shafff@ukr.net>
5 
6  This program is free software; you can redistribute it and/or
7  modify it under the terms of the GNU General Public License as
8  published by the Free Software Foundation; either version 2 of
9  the License or (at your option) version 3 or any later version
10  accepted by the membership of KDE e.V. (or its successor approved
11  by the membership of KDE e.V.), which shall act as a proxy
12  defined in Section 14 of version 3 of the license.
13 
14  This program is distributed in the hope that it will be useful,
15  but WITHOUT ANY WARRANTY; without even the implied warranty of
16  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17  GNU General Public License for more details.
18 
19  You should have received a copy of the GNU General Public License
20  along with this program. If not, see <http://www.gnu.org/licenses/>.
21 
22 **************************************************************************** */
23 
24 #ifndef ALTTRANSVIEW_H
25 #define ALTTRANSVIEW_H
26 
27 #define ALTTRANS_SHORTCUTS 9
28 
29 #include "pos.h"
30 #include "alttrans.h"
31 #include <QDockWidget>
32 namespace TM{class TextBrowser;}
33 class Catalog;
34 class KAction;
35 
36 class AltTransView: public QDockWidget
37 {
38  Q_OBJECT
39 
40 public:
41  AltTransView(QWidget*,Catalog*,const QVector<KAction*>&);
42  ~AltTransView();
43 
44 
45 public slots:
46  void slotNewEntryDisplayed(const DocPosition&);
47  void fileLoaded();
48  void attachAltTransFile(const QString&);
49  void addAlternateTranslation(int entry, const QString&, bool temp=true);
50 
51 private slots:
52  //void contextMenu(const QPoint & pos);
53  void process();
54  void initLater();
55  void slotUseSuggestion(int);
56 
57 signals:
58  void refreshRequested();
59  void textInsertRequested(const QString&);
60 
61 private:
62  void dragEnterEvent(QDragEnterEvent* event);
63  void dropEvent(QDropEvent *event);
64  bool event(QEvent *event);
65 
66 
67 private:
68  TM::TextBrowser* m_browser;
69  Catalog* m_catalog;
70  QString m_normTitle;
71  QString m_hasInfoTitle;
72  bool m_hasInfo;
73  DocPos m_entry;
74  DocPos m_prevEntry;
75  bool m_everShown;
76 
77  QVector<AltTrans> m_entries;
78  QMap<int, int> m_entryPositions;
79  QVector<KAction*> m_actions;//need them to get shortcuts
80 };
81 
82 #endif
AltTransView::addAlternateTranslation
void addAlternateTranslation(int entry, const QString &, bool temp=true)
Definition: alttransview.cpp:116
QEvent
QWidget
QDockWidget
pos.h
QMap< int, int >
AltTransView::textInsertRequested
void textInsertRequested(const QString &)
AltTransView::AltTransView
AltTransView(QWidget *, Catalog *, const QVector< KAction * > &)
Definition: alttransview.cpp:48
alttrans.h
DocPosition
This struct represents a position in a catalog.
Definition: pos.h:38
AltTransView::~AltTransView
~AltTransView()
Definition: alttransview.cpp:89
AltTransView::fileLoaded
void fileLoaded()
Definition: alttransview.cpp:127
QDropEvent
QString
AltTransView::slotNewEntryDisplayed
void slotNewEntryDisplayed(const DocPosition &)
Definition: alttransview.cpp:140
TM::TextBrowser
Definition: tmview.h:113
QVector< KAction * >
QDragEnterEvent
DocPos
simpler version of DocPosition for use in QMap
Definition: pos.h:82
AltTransView::refreshRequested
void refreshRequested()
Catalog
This class represents a catalog It uses CatalogStorage interface to work with catalogs in different f...
Definition: catalog.h:74
AltTransView
Definition: alttransview.h:36
AltTransView::attachAltTransFile
void attachAltTransFile(const QString &)
Definition: alttransview.cpp:109
This file is part of the KDE documentation.
Documentation copyright © 1996-2020 The KDE developers.
Generated on Mon Jun 22 2020 13:40:06 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.

lokalize

Skip menu "lokalize"
  • Main Page
  • Namespace List
  • Namespace Members
  • Alphabetical List
  • Class List
  • Class Hierarchy
  • Class Members
  • File List
  • File Members

kdesdk API Reference

Skip menu "kdesdk API Reference"
  • kapptemplate
  • kcachegrind
  • kompare
  • lokalize
  • umbrello
  •   umbrello

Search



Report problems with this website to our bug tracking system.
Contact the specific authors with questions and comments about the page contents.

KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal