• 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
  • objects
point_imp.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_OBJECTS_POINT_IMP_H
19 #define KIG_OBJECTS_POINT_IMP_H
20 
21 #include "object_imp.h"
22 #include "../misc/coordinate.h"
23 
27 class PointImp
28  : public ObjectImp
29 {
30  Coordinate mc;
31 public:
32  typedef ObjectImp Parent;
36  static const ObjectImpType* stype();
37 
41  PointImp( const Coordinate& c );
42  ~PointImp();
43 
44  Rect surroundingRect() const;
45  Coordinate attachPoint() const;
46 
50  const Coordinate& coordinate() const { return mc; }
54  void setCoordinate( const Coordinate& c );
55 
56  void draw( KigPainter& p ) const;
57  bool contains( const Coordinate& p, int width, const KigWidget& ) const;
58  bool inRect( const Rect& r, int width, const KigWidget& ) const;
59 
60  int numberOfProperties() const;
61  const QByteArrayList properties() const;
62  const QByteArrayList propertiesInternalNames() const;
63  ObjectImp* property( int which, const KigDocument& d ) const;
64  const char* iconForProperty( int which ) const;
65  const ObjectImpType* impRequirementForProperty( int which ) const;
66  bool isPropertyDefinedOnOrThroughThisImp( int which ) const;
67 
68  ObjectImp* transform( const Transformation& ) const;
69 
70  PointImp* copy() const;
71 
72  const ObjectImpType* type() const;
73  void visit( ObjectImpVisitor* vtor ) const;
74 
75  void fillInNextEscape( QString& s, const KigDocument& ) const;
76  bool canFillInNextEscape() const;
77 
78  bool equals( const ObjectImp& rhs ) const;
79 };
80 
81 class BogusPointImp
82  : public PointImp
83 {
84 public:
85  BogusPointImp( const Coordinate& c );
86  ~BogusPointImp();
87  static const ObjectImpType* stype();
88  const ObjectImpType* type() const;
89 };
90 
91 #endif
object_imp.h
ObjectImpType
Instances of this class represent a certain ObjectImp type.
Definition: object_imp.h:95
PointImp::iconForProperty
const char * iconForProperty(int which) const
Definition: point_imp.cc:89
PointImp::isPropertyDefinedOnOrThroughThisImp
bool isPropertyDefinedOnOrThroughThisImp(int which) const
Definition: point_imp.cc:181
PointImp::~PointImp
~PointImp()
Definition: point_imp.cc:117
PointImp::equals
bool equals(const ObjectImp &rhs) const
Returns true if this ObjectImp is equal to rhs.
Definition: point_imp.cc:148
PointImp::property
ObjectImp * property(int which, const KigDocument &d) const
Definition: point_imp.cc:103
PointImp::attachPoint
Coordinate attachPoint() const
Returns a reference point where to attach labels; when this returns an invalidCoord then the attachme...
Definition: point_imp.cc:34
BogusPointImp::stype
static const ObjectImpType * stype()
Definition: point_imp.cc:203
PointImp::propertiesInternalNames
const QByteArrayList propertiesInternalNames() const
Definition: point_imp.cc:62
Rect
This file is part of Kig, a KDE program for Interactive Geometry...
Definition: rect.h:34
PointImp::PointImp
PointImp(const Coordinate &c)
Construct a PointImp with coordinate c.
Definition: point_imp.cc:29
PointImp::surroundingRect
Rect surroundingRect() const
Definition: point_imp.cc:186
PointImp::coordinate
const Coordinate & coordinate() const
Get the coordinate of this PointImp.
Definition: point_imp.h:50
PointImp::impRequirementForProperty
const ObjectImpType * impRequirementForProperty(int which) const
Definition: point_imp.cc:82
Coordinate
The Coordinate class is the basic class representing a 2D location by its x and y components...
Definition: coordinate.h:33
PointImp::setCoordinate
void setCoordinate(const Coordinate &c)
Set the coordinate of this PointImp.
Definition: point_imp.cc:133
BogusPointImp::~BogusPointImp
~BogusPointImp()
Definition: point_imp.cc:199
PointImp::fillInNextEscape
void fillInNextEscape(QString &s, const KigDocument &) const
Definition: point_imp.cc:138
PointImp::type
const ObjectImpType * type() const
Returns the lowermost ObjectImpType that this object is an instantiation of.
Definition: point_imp.cc:176
KigPainter
KigPainter is an extended QPainter.
Definition: kigpainter.h:51
PointImp::numberOfProperties
int numberOfProperties() const
Definition: point_imp.cc:57
PointImp
An ObjectImp representing a point.
Definition: point_imp.h:27
Transformation
Class representing a transformation.
Definition: kigtransform.h:37
KigWidget
This class is the real widget showing the document.
Definition: kig_view.h:50
PointImp::Parent
ObjectImp Parent
Definition: point_imp.h:32
BogusPointImp::BogusPointImp
BogusPointImp(const Coordinate &c)
Definition: point_imp.cc:194
BogusPointImp
Definition: point_imp.h:81
PointImp::stype
static const ObjectImpType * stype()
Returns the ObjectImpType representing PointImp's.
Definition: point_imp.cc:159
BogusPointImp::type
const ObjectImpType * type() const
Returns the lowermost ObjectImpType that this object is an instantiation of.
Definition: point_imp.cc:220
PointImp::visit
void visit(ObjectImpVisitor *vtor) const
Definition: point_imp.cc:143
PointImp::draw
void draw(KigPainter &p) const
Definition: point_imp.cc:40
KigDocument
KigDocument is the class holding the real data in a Kig document.
Definition: kig_document.h:36
PointImp::copy
PointImp * copy() const
Returns a copy of this ObjectImp.
Definition: point_imp.cc:121
QByteArrayList
QList< QByteArray > QByteArrayList
Definition: objects/common.h:50
PointImp::transform
ObjectImp * transform(const Transformation &) const
Return this ObjectImp, transformed by the transformation t.
Definition: point_imp.cc:126
ObjectImp
The ObjectImp class represents the behaviour of an object after it is calculated. ...
Definition: object_imp.h:226
PointImp::inRect
bool inRect(const Rect &r, int width, const KigWidget &) const
Definition: point_imp.cc:51
PointImp::contains
bool contains(const Coordinate &p, int width, const KigWidget &) const
Definition: point_imp.cc:45
ObjectImpVisitor
Definition: object_imp.h:56
PointImp::properties
const QByteArrayList properties() const
Definition: point_imp.cc:72
PointImp::canFillInNextEscape
bool canFillInNextEscape() const
Definition: point_imp.cc:154
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