89
|
1 |
/*
|
|
2 |
* Copyright (c) 2002-2004 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 : Class looking after alarm fields for forms.
|
|
15 |
*
|
|
16 |
*/
|
|
17 |
|
|
18 |
#ifndef __CALENEXTRAROWFORMATTER_H__
|
|
19 |
#define __CALENEXTRAROWFORMATTER_H__
|
|
20 |
|
|
21 |
// INCLUDES
|
|
22 |
#include <e32base.h>
|
|
23 |
|
|
24 |
#include "CalenLunarLocalizedInfo.h"
|
|
25 |
#include "calendarvariant.hrh"
|
|
26 |
|
|
27 |
// FORWARD DECLARATION
|
|
28 |
class CFont;
|
|
29 |
|
|
30 |
/**
|
|
31 |
* Class declaration for Extra row formatter
|
|
32 |
*/
|
|
33 |
class CCalenExtraRowFormatter : public CBase
|
|
34 |
{
|
|
35 |
public: // public API
|
|
36 |
/**
|
|
37 |
* Two phased constructor.
|
|
38 |
*/
|
|
39 |
static CCalenExtraRowFormatter* NewL();
|
|
40 |
/**
|
|
41 |
* destructor
|
|
42 |
*/
|
|
43 |
virtual ~CCalenExtraRowFormatter();
|
|
44 |
/**
|
|
45 |
* Formats lunar based information
|
|
46 |
*/
|
|
47 |
TPtrC FormatExtraRowInformationL( CCalenLunarLocalizedInfo& aLocInfo,
|
|
48 |
RArray<CCalenLunarLocalizedInfo::TField>& aPrioritizedFields,
|
|
49 |
TInt aMaxWidth,
|
|
50 |
const CFont& aFont
|
|
51 |
#ifdef RD_CALENDAR_PREVIEW
|
|
52 |
, TBool aTwoLines
|
|
53 |
#endif // RD_CALENDAR_PREVIEW
|
|
54 |
);
|
|
55 |
|
|
56 |
private:
|
|
57 |
TBool TryToFitL( const TDesC& aStr, TInt aMaxWidth, const CFont& aFont
|
|
58 |
#ifdef RD_CALENDAR_PREVIEW
|
|
59 |
, TBool aTwoLines
|
|
60 |
#endif // RD_CALENDAR_PREVIEW
|
|
61 |
);
|
|
62 |
|
|
63 |
|
|
64 |
private: // own methods
|
|
65 |
CCalenExtraRowFormatter();
|
|
66 |
|
|
67 |
void ConstructL();
|
|
68 |
|
|
69 |
|
|
70 |
private: // data
|
|
71 |
TBuf<500> iText;
|
|
72 |
};
|
|
73 |
|
|
74 |
#endif // __CALENEXTRAROWFORMATTER_H__
|