Attempt to represent the S^2->S^3 header reorganisation as a series of "hg rename" operations
1 // Copyright (c) 1997-2009 Nokia Corporation and/or its subsidiary(-ies).
2 // All rights reserved.
3 // This component and the accompanying materials are made available
4 // under the terms of the License "Symbian Foundation License v1.0" to Symbian Foundation members and "Symbian Foundation End User License Agreement v1.0" to non-members
5 // which accompanies this distribution, and is available
6 // at the URL "http://www.symbianfoundation.org/legal/licencesv10.html".
8 // Initial Contributors:
9 // Nokia Corporation - initial contribution.
18 inline void CGridLay::SetGridTable(const MGridTable* aGridTable)
19 /** Sets the specified grid table object.
21 @param aGridTable The grid table object. */
22 { iGridTable = aGridTable; }
24 inline TRangeRef CGridLay::VisibleRange() const
25 /** Gets the range of cells that are currently visible.
27 @return The visible cell range. Note that the TRangeRef::iFrom member is the
28 cell that is visible at the top of the window, and the TRangeRef::iTo member
29 is the cell that is partially visible at the bottom right of the window. */
30 { return iVisibleRange; }
32 inline TRangeRef CGridLay::TitleRange() const
33 /** Gets the range of cells that form the grid titles.
35 @return The range of cells that form the grid titles. */
36 { return iTitleRange; }
38 inline TRangeRef CGridLay::GridRange() const
39 /** Gets the range of cells that defines the grid boundary.
41 @return The range of cells that defines the grid boundary. */
42 { return iGridRange; }
44 inline TBool CGridLay::IsSideLabels() const
45 /** Tests whether side grid labels are printed.
47 @return True, if the side labels are printed; false, otherwise. */
48 { return (iFlags&EIsSideLabels); }
50 inline TBool CGridLay::IsTopLabels() const
51 /** Tests whether top labels are printed.
53 @return True, if the top labels are printed; false, otherwise. */
54 { return (iFlags&EIsTopLabels); }
56 inline TBool CGridLay::IsVerticalGridLines() const
57 /** Tests whether vertical grid lines are to be drawn.
59 @return True, if vertical grid lines are to be drawn; false, otherwise. */
60 { return (iFlags&EIsVerticalGridLines); }
62 inline TBool CGridLay::IsHorizontalGridLines() const
63 /** Tests whether horizontal grid lines are to be drawn.
65 @return True, if horizontal grid lines are to be drawn; false, otherwise. */
66 { return (iFlags&EIsHorizontalGridLines); }
68 inline TBool CGridLay::IsGridLabelSeparators() const
69 /** Tests whether label separators are to be drawn.
71 @return True, if label separators are to be drawn; false, otherwise. */
72 { return (iFlags&EIsGridLabelSeparators); }
74 inline TBool CGridLay::IsColumnBursting() const
75 /** Tests whether column bursting is permitted.
77 Column bursting occurs when the contents of a cell are too wide; adjacent
78 cells are then overwritten, provided they are empty.
80 @return True, if column bursting is permitted; false, otherwise. */
81 { return (iFlags&EIsColumnBursting); }
83 inline TBool CGridLay::IsCursorVisible() const
84 /** Tests whether the cursor is visible.
86 @return True, if the cursor is visible; false, otherwise. */
87 { return (iFlags&EIsCursorVisible); }
89 inline TBool CGridLay::IsHighlightVisible() const
90 /** Tests whether selected cells are highlighted.
92 @return True, if selected cells are highlighted; false, otherwise. */
93 { return (iFlags&EIsHighlightVisible); }
95 inline TBool CGridLay::IsRowPermanentlySelected() const
96 /** Tests whether rows are permanently selected.
98 @return True, if rows are permanently selected; false, otherwise. */
99 { return (iFlags&EIsRowPermanentlySelected); }
101 inline TBool CGridLay::IsTitleLines() const
102 /** Tests whether the grid has both horizontal and vertical title lines.
104 @return True, if the grid has both a horizontal and vertical title line; false,
106 { return (iFlags&(EIsHorizontalTitleLine|EIsVerticalTitleLine)); }
108 inline TBool CGridLay::IsHorizontalTitleLine() const
109 /** Tests whether the grid has a horizontal title line.
111 @return True, if the grid is to have a horizontal title line; false otherwise. */
112 { return (iFlags&EIsHorizontalTitleLine); }
114 inline TBool CGridLay::IsVerticalTitleLine() const
115 /** Tests whether the grid has a vertical title line.
117 @return True, if the grid is to have a vertical title line; false otherwise. */
118 { return (iFlags&EIsVerticalTitleLine); }
120 inline TBool CGridLay::IsIndefiniteRowBoundaries() const
121 /** Tests whether the grid has indefinite row boundaries.
123 @return True, if the grid has indefinite row boundaries; false, otherwise. */
124 { return (iFlags&EIsIndefiniteRowBoundaries); }
126 inline TBool CGridLay::IsUniformRowHeight() const
127 /** Tests whether all the rows have the same height.
129 @return True, if all rows have the same height; false, otherwise. */
130 { return (iFlags&EIsUniformRowHeight); }
132 inline TBool CGridLay::IsUniformColumnWidth() const
133 /** Tests whether all columns have the same width.
135 @return True, if all columns have the same width; false, otherwise. */
136 { return (iFlags&EIsUniformColumnWidth); }
138 inline TBool CGridLay::IsTopLabelDragDisabled() const
139 /** Tests whether a drag operation on the boundary between two columns is permitted.
141 @return True, if a drag operation on a column boundary is permitted; false otherwise. */
142 { return (iFlags&EIsTopLabelDragDisabled); }
144 inline TBool CGridLay::IsSideLabelDragDisabled() const
145 /** Tests whether a drag operation on the boundary between two rows is permitted.
147 @return True, if a drag operation on a row boundary is permitted; false otherwise. */
148 { return (iFlags&EIsSideLabelDragDisabled); }
150 inline TBool CGridLay::IsPrintedLabels() const
151 /** Tests whether labels are printed.
153 @return True, if labels are printed; false, otherwise. */
154 { return (iFlags&EIsPrintedLabels); }
156 inline TBool CGridLay::IsPrintedGridLines() const
157 /** Tests whether grid lines are printed.
159 @return True, if grid lines are printed; false, otherwise. */
160 { return (iFlags&EIsPrintedGridLines); }
162 inline TBool CGridLay::IsVisibleToRowFullyVisible() const
163 { return (iFlags&EIsVisibleToRowFullyVisible); }
165 inline TBool CGridLay::IsVisibleToColumnFullyVisible() const
166 { return (iFlags&EIsVisibleToColumnFullyVisible); }
168 inline TBool CGridLay::IsEncroachingCellBorders() const
169 /** Tests whether encroaching cell borders are permitted.
171 Encroaching cell borders are where cell borders wider than one pixel are drawn
172 inside the cell, as opposed to outside.
174 @return True, if encroaching cells borders are permitted; false, otherwise. */
175 { return (iFlags&EIsEncroachingCellBorders); }
177 inline TBool CGridLay::IsRowSelectionDisabled() const
178 /** Tests whether row selection is disabled.
180 @return True, if row selection is disabled; false, otherwise. */
181 { return (iFlags&EIsRowSelectionDisabled); }
183 inline TBool CGridLay::IsColumnSelectionDisabled() const
184 /** Tests whether column selection is disabled.
186 @return True, if column selection is disabled; false, otherwise. */
187 { return (iFlags&EIsColumnSelectionDisabled); }
189 inline TBool CGridLay::IsAutoClearGridCells() const
190 /** Tests whether automatic clearing of grid cells is done.
192 Automatic clearing of grid cells is where all cells are cleared on redraw,
193 in case drawing the contents doesn't guarantee to write to every pixel (the
194 usual way of doing flicker-free redraws).
196 @return True, if automatic clearing of grid cells is done; false, otherwise. */
197 { return (iFlags&EIsAutoClearGridCells); }
199 inline TBool CGridLay::IsPageBreakLinesHidden() const
200 /** Tests whether lines marking page breaks are hidden.
202 @return True, if lines marking page breaks are hidden; false, otherwise. */
203 { return (iFlags&EIsPageBreakLinesHidden); }
205 inline TBool CGridLay::HasChanged() const
206 /** Tests whether any change has occurred to the grid layout.
208 Such changes include alterations to the height of a row or the
209 width of a column, additions or deletions of rows or columns,
210 and changes to the visibility of grid lines.
211 Note that this list is not exhaustive.
213 @return True, if the grid layout has changed; false, otherwise. */
214 { return iHasChanged; }
216 inline void CGridLay::SetHasChanged(TBool aHasChanged)
217 /** Sets whether any change has occurred to the grid layout.
219 @param aHasChanged ETrue, if any change has occurred to the grid layout; EFalse,
221 { iHasChanged=aHasChanged; }
223 inline void CGridLay::SetGridEdgeColor(TRgb aColor)
224 /** Defines the colour that the edges of the grid beyond the grid range are to
227 If not changed by this function, the default colour is white.
229 @param aColor The colour value. */
230 { iGridEdgeColor=aColor; }
232 inline TBool CGridLay::IsPaginated() const
233 /** Tests whether the grid has been paginated.
235 @return True, if the grid has been paginated; false, otherwise. */
236 { return (iFlags&EIsPaginated); }
238 inline void CGridLay::SetPrintRange(const TRangeRef& aPrintRange)
239 /** Sets the range of cells that are visible for printing.
241 @param aPrintRange The cell range. */
242 { iVisibleRange=aPrintRange; }
244 inline TSize CGridLay::PageSizeInTwips() const
245 /** Gets the size of a page.
247 @return The size of a page, in twips. */
248 { return iPageSizeInTwips; }
250 inline TBool CGridLay::IsAutoPagination() const
251 /** Tests whether automatic pagination is in effect.
253 @return True, if automatic pagination is in effect, false, otherwise. */
254 { return (iFlags&EIsAutoPagination); }
258 inline void CGridLabelImg::SetGraphicsDeviceMap(MGraphicsDeviceMap* aGraphicsDeviceMap)
259 /** Supplies a new interface object for mapping between twips and device-specific
262 Note that the caller must call ReleaseFont() before calling this function,
263 and must call NotifyGraphicsDeviceMapChangeL() afterwards.
265 @param aGraphicsDeviceMap A new interface object for mapping between twips
266 and device-specific units. */
268 iGraphicsDeviceMap=aGraphicsDeviceMap;
271 inline TFontSpec CGridLabelImg::FontSpec() const
272 /** Gets the font specification.
274 @return The font specification. */
279 inline void CGridLabelImg::SetGridColors(const TGridColors& aGridColors)
280 /** Sets the colours to be used when drawing the label.
282 @param aGridColors The object containing the grid colours specification. */
284 iGridColors = aGridColors;
289 inline TInt CGridCellImg::BurstColOffset() const
290 /** Gets the bursting column offset.
292 @return The burst column offset */
293 { return iBurstColOffset; }
295 inline TInt CGridCellImg::BurstLeft() const
296 /** Gets the left hand bursting value.
298 @return The burst value. */
299 { return iBurstLeft; }
301 inline TInt CGridCellImg::BurstRight() const
302 /** Gets the right hand bursting value.
304 @return The burst value */
305 { return iBurstRight; }
307 inline TBool CGridCellImg::IsHorizontalGridLines() const
308 /** Tests whether horizontal grid lines are drawn.
310 This function is set by the CGridImg object and allows classes derived from
311 CGridCellImg to modify or restrict the area into which they draw.
313 @return True, if horizontal grid lines are drawn; false, otherwise. */
314 { return iGridLineFlags&EIsHorizontalGridLines; }
316 inline TBool CGridCellImg::IsVerticalGridLines() const
317 /** Tests whether vertical grid lines are drawn.
319 This function is set by the CGridImg object and allows classes derived from
320 CGridCellImg to modify or restrict the area into which they draw.
322 @return True, if vertical grid lines are drawn; false, otherwise. */
323 { return iGridLineFlags&EIsVerticalGridLines; }
325 inline void CGridCellImg::SetGridColors(const TGridColors& aGridColors)
326 /** Sets the colours to be used when drawing.
328 @param aGridColors The object containing the grid colours specification. */
330 iGridColors = aGridColors;
335 inline void CGridImg::SetGridLay(CGridLay* aGridLay)
336 /** Sets the specified grid layout object.
338 @param aGridLay A pointer to the object that controls the layout of rows and
340 { iGridLay = aGridLay; }
342 inline void CGridImg::SetWindow(RWindow *aWin)
343 /** Sets the specified window.
345 @param aWin A pointer to the currently active window. */
348 ////////////////////////->
349 //inline void CGridImg::SetGridLabelImg(CGridLabelImg *aGridLabelImg)
350 // { iGridLabelImg = aGridLabelImg; }
351 ////////////////////////->
353 inline void CGridImg::SetCursorMoveCallBack(MGridCursorMoveCallBack *aCursorMoveCallBack)
354 /** Sets the cursor moved call-back object.
356 The call-back object encapsulates the implementation of a call-back function
357 that is called whenever there is a change to the cursor position.
359 @param aCursorMoveCallBack A pointer to the callback object. */
360 { iCursorMoveCallBack = aCursorMoveCallBack; }
362 inline const CGridCellRegion* CGridImg::Selected() const
363 /** Gets the currently selected region.
365 @return A pointer to the selected region object. */
366 { return iSelected; }
368 inline const CGridLabelImg* CGridImg::GridLabelImg() const
369 /** Gets the the object that is used to draw a cell label.
371 @return A pointer to the object that is used to draw a cell label. */
372 { return iGridLabelImg; }
374 inline TCellRef CGridImg::CursorPos() const
375 /** Gets the current position of the cursor.
377 @return The cell reference of the current cursor position. */
378 { return iCursorPos; }
380 inline TCellRef CGridImg::AnchorPos() const
381 /** Gets the cursor's anchor position.
383 This is the cell reference of the position that the cursor must return to
384 after a series of selected movements have been made.
386 @return The cell reference of the cursor's anchor position. */
387 { return iAnchorPos; }
389 inline TCellRef CGridImg::NewCursorPos() const
390 /** Gets the new position of the cursor.
392 @return The cell reference of the new cursor position.
393 @see SetCursorPosL() */
394 { return iNewCursorPos; }
396 inline TRect CGridImg::GridRect() const
397 /** Gets the rectangle containing the grid.
399 @return The rectangle containing the grid. */
400 { return iGridRect; }
402 inline TPoint CGridImg::TitlePoint() const
403 /** Gets the position of the title.
405 This is the point at the top left of the grid excluding the labels.
407 @return The position of the title. */
408 { return iTitlePoint; }
410 inline TPoint CGridImg::MainPoint() const
411 // Returns the most commonly used point in the grid (usually same as TitlePoint()).
412 /** Gets the position at which the visible range starts.
414 @return The position at which the visible range starts. */
415 { return iMainPoint; }
417 inline TRect CGridImg::MainRect() const
418 /** Gets the rectangle that corresponds to the visible range.
420 @return The rectangle that corresponds to the visible range. */
421 { return TRect(iMainPoint,iGridRect.iBr); }