This page was last modified 01:16, 15 July 2008.
TSS000510 - Using SVG icons in Avkon tabs
From Forum Nokia Wiki
Subject:
| Using SVG icons in Avkon tabs
| TSS000510
|
| Platform(s):
| Device(s), SW version(s):
|
| S60 3rd Edition
|
|
Category:
| Symbian C++
|
Subcategory:
| -
|
Description:
| Overview It is possible to display custom SVG icons in the Avkon tab group for each tab. There are some restrictions on the SVG files that can be used with tabs, these are described below. Solution CAknTabGroup::AddTabL() can be used for creating a tab with a custom SVG icon. However, only the mask (i.e., alpha or transparency) layer of the icon is used for generating the icon, rest of the image data is ignored. As an example, consider a white SVG with the following line: a black ellipse with a white background (fill): <ellipse fill="#FFFFFF" stroke="#000000" stroke-width="5" cx="25" cy="25" rx="20" ry="20"/> In order to get an ellipse displayed on the tab, the fill parameter must be modified: <ellipse fill="none" stroke="#000000" stroke-width="5" cx="25" cy="25" rx="20" ry="20"/>. After the replacement, the mask of the image will have a white ellipse on a black background. When the SVG is used as the tab icon, the ellipse is displayed in black color and the rest of the image becomes transparent. Note: It is not possible to draw colored SVG in the TAB, as the mask is always used for generating the icon.
|
Creation date:
| November 30, 2006
|
Last modified:
| -
|