|
1 /* |
|
2 * Copyright (c) 2003-2006 Nokia Corporation and/or its subsidiary(-ies). |
|
3 * All rights reserved. |
|
4 * This component and the accompanying materials are made available |
|
5 * under the terms of "Eclipse Public License v1.0" |
|
6 * which accompanies this distribution, and is available |
|
7 * at the URL "http://www.eclipse.org/legal/epl-v10.html". |
|
8 * |
|
9 * Initial Contributors: |
|
10 * Nokia Corporation - initial contribution. |
|
11 * |
|
12 * Contributors: |
|
13 * |
|
14 * Description: trpoint declaration |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 #ifndef TRPOINT_H |
|
20 #define TRPOINT_H |
|
21 |
|
22 // INCLUDES |
|
23 #include <e32std.h> |
|
24 |
|
25 // CLASS DECLARATION |
|
26 |
|
27 /** |
|
28 * Coord class with TReal iX and iY |
|
29 * |
|
30 * |
|
31 * @lib smiltran.dll |
|
32 * @since S60 2.1 |
|
33 */ |
|
34 NONSHARABLE_CLASS( TRPoint ) |
|
35 { |
|
36 public: // Constructors and destructor |
|
37 |
|
38 /** |
|
39 * C++ default contructor. |
|
40 */ |
|
41 TRPoint(); |
|
42 |
|
43 /** |
|
44 * C++ contructor. |
|
45 */ |
|
46 TRPoint(TReal aX,TReal aY); |
|
47 |
|
48 public: // New functions |
|
49 |
|
50 TInt operator==( const TRPoint& aPoint ) const; |
|
51 TInt operator!=( const TRPoint& aPoint ) const; |
|
52 |
|
53 TRPoint& operator-=( const TRPoint& aPoint ); |
|
54 TRPoint& operator+=( const TRPoint& aPoint ); |
|
55 |
|
56 TRPoint operator-( const TRPoint& aPoint ) const; |
|
57 TRPoint operator+( const TRPoint& aPoint ) const; |
|
58 |
|
59 TRPoint operator-() const; |
|
60 |
|
61 TRPoint& operator*=( const TReal aVal ); |
|
62 TRPoint& operator/=( const TReal aVal ); |
|
63 |
|
64 TRPoint operator*( const TReal aVal ) const; |
|
65 TRPoint operator/( const TReal aVal ) const; |
|
66 |
|
67 TRPoint& operator-=( const TReal aVal ); |
|
68 TRPoint& operator+=( const TReal aVal ); |
|
69 |
|
70 TRPoint operator-( const TReal aVal ) const; |
|
71 TRPoint operator+( const TReal aVal ) const; |
|
72 |
|
73 void SetXY( TInt aX, TInt aY ); |
|
74 |
|
75 public: // Data |
|
76 |
|
77 // X - coordinate. |
|
78 TReal iX; |
|
79 |
|
80 // Y - coordinate. |
|
81 TReal iY; |
|
82 }; |
|
83 |
|
84 #endif // TRPOINT_H |
|
85 |
|
86 // End of File |