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

kig

  • sources
  • kde-4.14
  • kdeedu
  • kig
  • objects
line_type.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_LINE_TYPE_H
19 #define KIG_OBJECTS_LINE_TYPE_H
20 
21 #include "base_type.h"
22 
23 class LineData;
24 
25 class SegmentABType
26  : public ObjectABType
27 {
28  SegmentABType();
29  ~SegmentABType();
30 public:
31  static const SegmentABType* instance();
32 
33  ObjectImp* calcx( const Coordinate& a, const Coordinate& b ) const;
34  const ObjectImpType* resultId() const;
35 
36  QStringList specialActions() const;
40  void executeAction( int i, ObjectHolder& o, ObjectTypeCalcer& c,
41  KigPart& d, KigWidget& w, NormalMode& m ) const;
42 };
43 
44 class LineABType
45  : public ObjectABType
46 {
47  LineABType();
48  ~LineABType();
49 public:
50  static const LineABType* instance();
51  ObjectImp* calcx( const Coordinate& a, const Coordinate& b ) const;
52  const ObjectImpType* resultId() const;
53 };
54 
55 class RayABType
56  : public ObjectABType
57 {
58  RayABType();
59  ~RayABType();
60 public:
61  static const RayABType* instance();
62  ObjectImp* calcx( const Coordinate& a, const Coordinate& b ) const;
63  const ObjectImpType* resultId() const;
64 };
65 
66 class SegmentAxisType
67  : public ArgsParserObjectType
68 {
69  SegmentAxisType();
70  ~SegmentAxisType();
71 public:
72  static const SegmentAxisType* instance();
73  ObjectImp* calc( const Args& parents, const KigDocument& d ) const;
74  const ObjectImpType* resultId() const;
75 };
76 
77 class LinePerpendLPType
78  : public ObjectLPType
79 {
80  LinePerpendLPType();
81  ~LinePerpendLPType();
82 public:
83  static LinePerpendLPType* instance();
84  using ObjectLPType::calc;
85  ObjectImp* calc( const LineData& a, const Coordinate& b ) const;
86  const ObjectImpType* resultId() const;
87 };
88 
89 class LineParallelLPType
90  : public ObjectLPType
91 {
92  LineParallelLPType();
93  ~LineParallelLPType();
94 public:
95  static LineParallelLPType* instance();
96  using ObjectLPType::calc;
97  ObjectImp* calc( const LineData& a, const Coordinate& b ) const;
98  const ObjectImpType* resultId() const;
99 };
100 
101 class LineByVectorType
102  : public ArgsParserObjectType
103 {
104  LineByVectorType();
105  ~LineByVectorType();
106 public:
107  static const LineByVectorType* instance();
108  ObjectImp* calc( const Args& args, const KigDocument& ) const;
109  const ObjectImpType* resultId() const;
110 };
111 
112 class HalflineByVectorType
113  : public ArgsParserObjectType
114 {
115  HalflineByVectorType();
116  ~HalflineByVectorType();
117 public:
118  static const HalflineByVectorType* instance();
119  ObjectImp* calc( const Args& args, const KigDocument& ) const;
120  const ObjectImpType* resultId() const;
121 };
122 
123 #endif
HalflineByVectorType::resultId
const ObjectImpType * resultId() const
returns the ObjectImp id of the ObjectImp's produced by this ObjectType.
Definition: line_type.cc:372
LineABType::resultId
const ObjectImpType * resultId() const
returns the ObjectImp id of the ObjectImp's produced by this ObjectType.
Definition: line_type.cc:242
LinePerpendLPType::calc
ObjectImp * calc(const LineData &a, const Coordinate &b) const
Definition: line_type.cc:177
ObjectImpType
Instances of this class represent a certain ObjectImp type.
Definition: object_imp.h:95
ObjectABType
Definition: base_type.h:27
ArgsParserObjectType
This is a convenience subclass of ObjectType that a type should inherit from if its parents can be sp...
Definition: object_type.h:113
LineByVectorType
Definition: line_type.h:101
LineData
Simple class representing a line.
Definition: misc/common.h:49
SegmentABType::specialActions
QStringList specialActions() const
return i18n'd names for the special actions.
Definition: line_type.cc:262
LineParallelLPType::calc
ObjectImp * calc(const LineData &a, const Coordinate &b) const
Definition: line_type.cc:210
LinePerpendLPType::instance
static LinePerpendLPType * instance()
Definition: line_type.cc:171
HalflineByVectorType::calc
ObjectImp * calc(const Args &args, const KigDocument &) const
Definition: line_type.cc:362
SegmentABType::executeAction
void executeAction(int i, ObjectHolder &o, ObjectTypeCalcer &c, KigPart &d, KigWidget &w, NormalMode &m) const
execute the i 'th action from the specialActions above.
Definition: line_type.cc:269
LineABType
Definition: line_type.h:44
RayABType::instance
static const RayABType * instance()
Definition: line_type.cc:119
ObjectLPType
Definition: base_type.h:46
ObjectTypeCalcer
This is an ObjectCalcer that uses one of the various ObjectType's to calculate its ObjectImp...
Definition: object_calcer.h:183
Coordinate
The Coordinate class is the basic class representing a 2D location by its x and y components...
Definition: coordinate.h:33
SegmentAxisType
Definition: line_type.h:66
SegmentABType::resultId
const ObjectImpType * resultId() const
returns the ObjectImp id of the ObjectImp's produced by this ObjectType.
Definition: line_type.cc:237
RayABType::resultId
const ObjectImpType * resultId() const
returns the ObjectImp id of the ObjectImp's produced by this ObjectType.
Definition: line_type.cc:247
ObjectHolder
An ObjectHolder represents an object as it is known to the document.
Definition: object_holder.h:40
LineParallelLPType::instance
static LineParallelLPType * instance()
Definition: line_type.cc:204
Args
std::vector< const ObjectImp * > Args
Definition: objects/common.h:47
SegmentAxisType::instance
static const SegmentAxisType * instance()
Definition: line_type.cc:147
RayABType
Definition: line_type.h:55
HalflineByVectorType
Definition: line_type.h:112
SegmentAxisType::calc
ObjectImp * calc(const Args &parents, const KigDocument &d) const
Definition: line_type.cc:153
LineABType::calcx
ObjectImp * calcx(const Coordinate &a, const Coordinate &b) const
Definition: line_type.cc:93
KigWidget
This class is the real widget showing the document.
Definition: kig_view.h:50
QStringList
LinePerpendLPType
Definition: line_type.h:77
LineByVectorType::calc
ObjectImp * calc(const Args &args, const KigDocument &) const
Definition: line_type.cc:322
SegmentABType::calcx
ObjectImp * calcx(const Coordinate &a, const Coordinate &b) const
Definition: line_type.cc:61
SegmentABType
Definition: line_type.h:25
LineByVectorType::instance
static const LineByVectorType * instance()
Definition: line_type.cc:316
RayABType::calcx
ObjectImp * calcx(const Coordinate &a, const Coordinate &b) const
Definition: line_type.cc:125
LineParallelLPType::resultId
const ObjectImpType * resultId() const
returns the ObjectImp id of the ObjectImp's produced by this ObjectType.
Definition: line_type.cc:257
LinePerpendLPType::resultId
const ObjectImpType * resultId() const
returns the ObjectImp id of the ObjectImp's produced by this ObjectType.
Definition: line_type.cc:252
SegmentAxisType::resultId
const ObjectImpType * resultId() const
returns the ObjectImp id of the ObjectImp's produced by this ObjectType.
Definition: line_type.cc:166
HalflineByVectorType::instance
static const HalflineByVectorType * instance()
Definition: line_type.cc:356
KigDocument
KigDocument is the class holding the real data in a Kig document.
Definition: kig_document.h:36
LineByVectorType::resultId
const ObjectImpType * resultId() const
returns the ObjectImp id of the ObjectImp's produced by this ObjectType.
Definition: line_type.cc:332
ObjectImp
The ObjectImp class represents the behaviour of an object after it is calculated. ...
Definition: object_imp.h:226
KigPart
This is a "Part".
Definition: kig_part.h:68
SegmentABType::instance
static const SegmentABType * instance()
Definition: line_type.cc:55
base_type.h
LineParallelLPType
Definition: line_type.h:89
NormalMode
Definition: normal.h:26
ObjectLPType::calc
ObjectImp * calc(const Args &args, const KigDocument &) const
Definition: base_type.cc:87
LineABType::instance
static const LineABType * instance()
Definition: line_type.cc:87
This file is part of the KDE documentation.
Documentation copyright © 1996-2020 The KDE developers.
Generated on Mon Jun 22 2020 13:12:05 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
  • 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