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

kig

  • sources
  • kde-4.12
  • kdeedu
  • kig
  • modes
macro.h
Go to the documentation of this file.
1 // Copyright (C) 2002 Dominique Devriese <devriese@kde.org>
2 
3 // This program is free software; you can redistribute it and/or
4 // modify it under the terms of the GNU General Public License
5 // as published by the Free Software Foundation; either version 2
6 // of the License, or (at your option) any later version.
7 
8 // This program is distributed in the hope that it will be useful,
9 // but WITHOUT ANY WARRANTY; without even the implied warranty of
10 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11 // GNU General Public License for more details.
12 
13 // You should have received a copy of the GNU General Public License
14 // along with this program; if not, write to the Free Software
15 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
16 // 02110-1301, USA.
17 
18 #ifndef KIG_MODES_MACRO_H
19 #define KIG_MODES_MACRO_H
20 
21 #include "base_mode.h"
22 
23 #include <qobject.h>
24 
25 class MacroWizard;
26 
27 class DefineMacroMode
28  : public BaseMode
29 {
30 public:
31  DefineMacroMode( KigPart& );
32  ~DefineMacroMode();
33 
34  void dragRect( const QPoint& p, KigWidget& w );
35  void leftClickedObject( ObjectHolder* o, const QPoint& p,
36  KigWidget& w, bool ctrlOrShiftDown );
37  using BaseMode::midClicked;
38  using BaseMode::rightClicked;
39  using BaseMode::mouseMoved;
40 
41  // called by MacroWizard class
42  void givenPageEntered();
43  void finalPageEntered();
44  bool validateObjects();
45  void finishPressed();
46  void cancelPressed();
47 
48  bool hasGivenArgs() const;
49  bool hasFinalArgs() const;
50 
51 protected:
52  void rightClicked( const std::vector<ObjectHolder*>& oco, const QPoint& p, KigWidget& w );
53  void midClicked( const QPoint& p, KigWidget& w );
54  void mouseMoved( const std::vector<ObjectHolder*>& os, const QPoint& p, KigWidget& w, bool shiftpressed );
55  void enableActions();
59  void abandonMacro();
60 
61  QPoint plc;
62  MacroWizard* mwizard;
63 
64  // we can't use a set for this because the order is important
65  std::vector<ObjectHolder*> mgiven;
66  std::vector<ObjectHolder*> mfinal;
67 };
68 
69 #endif
DefineMacroMode::cancelPressed
void cancelPressed()
Definition: macro.cc:138
DefineMacroMode::rightClicked
void rightClicked(const std::vector< ObjectHolder * > &oco, const QPoint &p, KigWidget &w)
Definition: macro.cc:223
DefineMacroMode::mgiven
std::vector< ObjectHolder * > mgiven
Definition: macro.h:65
DefineMacroMode::~DefineMacroMode
~DefineMacroMode()
Definition: macro.cc:48
BaseMode::mouseMoved
void mouseMoved(QMouseEvent *e, KigWidget *v)
mouse moved without any buttons down...
Definition: base_mode.cc:128
DefineMacroMode::abandonMacro
void abandonMacro()
quit this mode...
Definition: macro.cc:53
DefineMacroMode
Definition: macro.h:27
DefineMacroMode::hasFinalArgs
bool hasFinalArgs() const
Definition: macro.cc:236
BaseMode
The BaseMode is a particular mode that allows an easy mapping of the mouse actions to real...
Definition: base_mode.h:33
DefineMacroMode::dragRect
void dragRect(const QPoint &p, KigWidget &w)
Definition: macro.cc:143
BaseMode::oco
std::vector< ObjectHolder * > oco()
Definition: base_mode.cc:153
DefineMacroMode::hasGivenArgs
bool hasGivenArgs() const
Definition: macro.cc:231
ObjectHolder
An ObjectHolder represents an object as it is known to the document.
Definition: object_holder.h:40
DefineMacroMode::leftClickedObject
void leftClickedObject(ObjectHolder *o, const QPoint &p, KigWidget &w, bool ctrlOrShiftDown)
Definition: macro.cc:171
DefineMacroMode::DefineMacroMode
DefineMacroMode(KigPart &)
Definition: macro.cc:41
DefineMacroMode::mwizard
MacroWizard * mwizard
Definition: macro.h:62
DefineMacroMode::enableActions
void enableActions()
actions: we enable the actions we want when our mode is made active.
Definition: macro.cc:58
KigWidget
This class is the real widget showing the document.
Definition: kig_view.h:50
DefineMacroMode::finalPageEntered
void finalPageEntered()
Definition: macro.cc:70
base_mode.h
BaseMode::midClicked
void midClicked(QMouseEvent *e, KigWidget *v)
Definition: base_mode.cc:97
DefineMacroMode::givenPageEntered
void givenPageEntered()
Definition: macro.cc:64
DefineMacroMode::validateObjects
bool validateObjects()
Definition: macro.cc:76
DefineMacroMode::mfinal
std::vector< ObjectHolder * > mfinal
Definition: macro.h:66
MacroWizard
Definition: macrowizard.h:27
DefineMacroMode::plc
QPoint plc
Definition: macro.h:61
DefineMacroMode::mouseMoved
void mouseMoved(const std::vector< ObjectHolder * > &os, const QPoint &p, KigWidget &w, bool shiftpressed)
Definition: macro.cc:192
DefineMacroMode::finishPressed
void finishPressed()
Definition: macro.cc:115
KigPart
This is a "Part".
Definition: kig_part.h:68
BaseMode::rightClicked
void rightClicked(QMouseEvent *, KigWidget *)
Definition: base_mode.cc:114
DefineMacroMode::midClicked
void midClicked(const QPoint &p, KigWidget &w)
Definition: macro.cc:227
This file is part of the KDE documentation.
Documentation copyright © 1996-2014 The KDE developers.
Generated on Tue Oct 14 2014 22:35:39 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.

kig

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

kdeedu API Reference

Skip menu "kdeedu API Reference"
  • Analitza
  •     lib
  • kalgebra
  • kalzium
  •   libscience
  • kanagram
  • kig
  •   lib
  • klettres
  • kstars
  • libkdeedu
  •   keduvocdocument
  • marble
  • parley
  • rocs
  •   App
  •   RocsCore
  •   VisualEditor
  •   stepcore

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