|
1 /* |
|
2 * Copyright (c) 2004-2008 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: Poly line class. |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 #ifndef AKNSALPOLYLINE_H |
|
20 #define AKNSALPOLYLINE_H |
|
21 |
|
22 #include "AknsAlPolyBase.h" |
|
23 #include "AknsAlFixed.h" |
|
24 |
|
25 |
|
26 /** |
|
27 * Poly line class. |
|
28 * The class is not intended for derivation outside the library. |
|
29 * |
|
30 * @since 3.0 |
|
31 */ |
|
32 class CAknsAlPolyLine : public CAknsAlPolyBase |
|
33 { |
|
34 public: // Constructors |
|
35 |
|
36 static CAknsAlPolyLine* NewL(); |
|
37 |
|
38 /** |
|
39 * Destructor |
|
40 * |
|
41 * @since 3.0 |
|
42 */ |
|
43 ~CAknsAlPolyLine(); |
|
44 |
|
45 public: // New functions |
|
46 |
|
47 /** |
|
48 * Returns the point in poly(line/spline) in scaled area. |
|
49 * |
|
50 * @param aPosition 32-bit integer representing the position in poly(line/spline). |
|
51 * If aPosition is 0, starting point is returned and if aPosition is 0xffffffff, |
|
52 * the last point is returned. |
|
53 * |
|
54 * @return Point in poly(line/spline) scaled to the set area or if no |
|
55 * area is set, returned values are in scale from 0 to 1. |
|
56 * |
|
57 * @since 3.0 |
|
58 */ |
|
59 TPoint GetPolyPoint( const TUint32 aPosition ); |
|
60 |
|
61 /** |
|
62 * Calculates and sets the lengths of poly segments. This is automatically |
|
63 * called after the points have been set. |
|
64 * |
|
65 * @return Returns KErrNoMemory if the lengths couldn't be saved. |
|
66 */ |
|
67 void CalculateLengthsL( ); |
|
68 |
|
69 private: |
|
70 |
|
71 /** |
|
72 * Default constructor. |
|
73 * |
|
74 * @since 3.0 |
|
75 */ |
|
76 CAknsAlPolyLine(); |
|
77 }; |
|
78 |
|
79 #endif //AKNSALPOLYLINE_H |
|
80 |
|
81 // End of file |