graphicsdeviceinterface/bitgdi/tbit/toutlineandshadowfonts.h
branchRCL_3
changeset 7 5e51caaeeb72
parent 0 5d03bc08d59c
equal deleted inserted replaced
6:de3d5b6102ac 7:5e51caaeeb72
   127 	{
   127 	{
   128 	TUint32 fSpecAndGcSettings; //flags/effects in gc and fontspec to be enabled
   128 	TUint32 fSpecAndGcSettings; //flags/effects in gc and fontspec to be enabled
   129 	TRgb brushColor; //brush colour will set the colour of the fill of the font
   129 	TRgb brushColor; //brush colour will set the colour of the fill of the font
   130 	TRgb penColor; //pen colour which will set the colour of the outline
   130 	TRgb penColor; //pen colour which will set the colour of the outline
   131 	TRgb shadowColor; //shadow colour which will set the colour of the shadow
   131 	TRgb shadowColor; //shadow colour which will set the colour of the shadow
       
   132 	TRgb backgroundColor; //colour of the target that the text is rendered onto
   132 	} STestFontParameters;
   133 	} STestFontParameters;
   133 
   134 
   134 // Test setting for TestOutlineandShadowFontsMetricsL() i.e. for test case 8
   135 // Test setting for TestOutlineandShadowFontsMetricsL() i.e. for test case 8
   135 // All the test case conditions are defined here and are called to test font metrics
   136 // All the test case conditions are defined here and are called to test font metrics
   136 // STestFontParameters Format: outline | shadow | bitmaptype, BrushColor, PenColor, ShadowColor
   137 // STestFontParameters Format: outline | shadow | bitmaptype, BrushColor, PenColor, ShadowColor
   143 	{EDropShadowOn | EOutlineOn | ESetAntiAliasedGlyphBitmap},
   144 	{EDropShadowOn | EOutlineOn | ESetAntiAliasedGlyphBitmap},
   144 	{EAntiAliasedGlyphBitmap}};
   145 	{EAntiAliasedGlyphBitmap}};
   145 
   146 
   146 // Test setting for TestDrawTextWithOutlineAndShadowL() i.e. for test case 10
   147 // Test setting for TestDrawTextWithOutlineAndShadowL() i.e. for test case 10
   147 // All test case conditions are defined here and are called to test outline and shadow effects
   148 // All test case conditions are defined here and are called to test outline and shadow effects
   148 // STestFontParameters Format: outline | shadow | bitmaptype, BrushColor, PenColor, ShadowColor
   149 // STestFontParameters Format: outline | shadow | bitmaptype, BrushColor, PenColor, ShadowColor, BackgroundColor
   149 const TInt KNumberOfSubTestsInTest0010 = 34;
   150 const TInt KNumberOfSubTestsInTest0010 = 35;
   150 _LIT(KTestName0010, "OutlineShadowWithDrawTextNormalAndVertical");//test case name to used to generate test case id
   151 _LIT(KTestName0010, "OutlineShadowWithDrawTextNormalAndVertical");//test case name to used to generate test case id
   151 const STestFontParameters KTestSettingsToTestOutlineAndShadow[KNumberOfSubTestsInTest0010] =
   152 const STestFontParameters KTestSettingsToTestOutlineAndShadow[KNumberOfSubTestsInTest0010] =
   152 	{
   153 	{
   153 	// test with EMonochromeGlyphBitmap and alpha value 255
   154 	// test with EMonochromeGlyphBitmap and alpha value 255
   154 	{EDropShadowOn | ESetMonochromeGlyphBitmap | EVerticalDraw | ERotate90Degrees, KRgbGreen, KRgbBlack, KRgbBlue},
   155 	{EDropShadowOn | ESetMonochromeGlyphBitmap | EVerticalDraw | ERotate90Degrees, KRgbGreen, KRgbBlack, KRgbBlue, KRgbWhite},
   155 	{EOutlineOn | ESetMonochromeGlyphBitmap |  EVerticalDraw | ERotate90Degrees, KRgbGreen, KRgbBlack, KRgbBlue},
   156 	{EOutlineOn | ESetMonochromeGlyphBitmap |  EVerticalDraw | ERotate90Degrees, KRgbGreen, KRgbBlack, KRgbBlue, KRgbWhite},
   156 	{EDropShadowOn | EOutlineOn | ESetMonochromeGlyphBitmap | EVerticalDraw | ERotate90Degrees, KRgbGreen, KRgbBlack, KRgbBlue},
   157 	{EDropShadowOn | EOutlineOn | ESetMonochromeGlyphBitmap | EVerticalDraw | ERotate90Degrees, KRgbGreen, KRgbBlack, KRgbBlue, KRgbWhite},
   157 	{EDropShadowOn | ESetMonochromeGlyphBitmap | EVerticalDraw, KRgbGreen, KRgbBlack, KRgbBlue},
   158 	{EDropShadowOn | ESetMonochromeGlyphBitmap | EVerticalDraw, KRgbGreen, KRgbBlack, KRgbBlue, KRgbWhite},
   158 	{EOutlineOn | ESetMonochromeGlyphBitmap | EVerticalDraw, KRgbGreen, KRgbBlack, KRgbBlue},
   159 	{EOutlineOn | ESetMonochromeGlyphBitmap | EVerticalDraw, KRgbGreen, KRgbBlack, KRgbBlue, KRgbWhite},
   159 	{EDropShadowOn | EOutlineOn | ESetMonochromeGlyphBitmap | EVerticalDraw, KRgbGreen, KRgbBlack, KRgbBlue},
   160 	{EDropShadowOn | EOutlineOn | ESetMonochromeGlyphBitmap | EVerticalDraw, KRgbGreen, KRgbBlack, KRgbBlue, KRgbWhite},
   160 	{EDropShadowOn | ESetMonochromeGlyphBitmap, KRgbGreen, KRgbBlack, KRgbBlue},
   161 	{EDropShadowOn | ESetMonochromeGlyphBitmap, KRgbGreen, KRgbBlack, KRgbBlue, KRgbWhite},
   161 	{EOutlineOn | ESetMonochromeGlyphBitmap, KRgbGreen, KRgbBlack, KRgbBlue},
   162 	{EOutlineOn | ESetMonochromeGlyphBitmap, KRgbGreen, KRgbBlack, KRgbBlue, KRgbWhite},
   162 	{EDropShadowOn | EOutlineOn | ESetMonochromeGlyphBitmap, KRgbGreen, KRgbBlack, KRgbBlue},
   163 	{EDropShadowOn | EOutlineOn | ESetMonochromeGlyphBitmap, KRgbGreen, KRgbBlack, KRgbBlue, KRgbWhite},
   163 
   164 
   164 	// test with EAntiAliasedGlyphBitmap and alpha value 255
   165 	// test with EAntiAliasedGlyphBitmap and alpha value 255
   165 	{EDropShadowOn | ESetAntiAliasedGlyphBitmap | EVerticalDraw | ERotate90Degrees, KRgbGreen, KRgbBlack, KRgbBlue},
   166 	{EDropShadowOn | ESetAntiAliasedGlyphBitmap | EVerticalDraw | ERotate90Degrees, KRgbGreen, KRgbBlack, KRgbBlue, KRgbWhite},
   166 	{EOutlineOn | ESetAntiAliasedGlyphBitmap | EVerticalDraw | ERotate90Degrees, KRgbGreen, KRgbBlack, KRgbBlue},
   167 	{EOutlineOn | ESetAntiAliasedGlyphBitmap | EVerticalDraw | ERotate90Degrees, KRgbGreen, KRgbBlack, KRgbBlue, KRgbWhite},
   167 	{EDropShadowOn | EOutlineOn | ESetAntiAliasedGlyphBitmap | EVerticalDraw | ERotate90Degrees, KRgbGreen, KRgbBlack, KRgbBlue},
   168 	{EDropShadowOn | EOutlineOn | ESetAntiAliasedGlyphBitmap | EVerticalDraw | ERotate90Degrees, KRgbGreen, KRgbBlack, KRgbBlue, KRgbWhite},
   168 	{EDropShadowOn | ESetAntiAliasedGlyphBitmap | EVerticalDraw, KRgbGreen, KRgbBlack, KRgbBlue},
   169 	{EDropShadowOn | ESetAntiAliasedGlyphBitmap | EVerticalDraw, KRgbGreen, KRgbBlack, KRgbBlue, KRgbWhite},
   169 	{EOutlineOn | ESetAntiAliasedGlyphBitmap | EVerticalDraw, KRgbGreen, KRgbBlack, KRgbBlue},
   170 	{EOutlineOn | ESetAntiAliasedGlyphBitmap | EVerticalDraw, KRgbGreen, KRgbBlack, KRgbBlue, KRgbWhite},
   170 	{EDropShadowOn | EOutlineOn | ESetAntiAliasedGlyphBitmap | EVerticalDraw, KRgbGreen, KRgbBlack, KRgbBlue},
   171 	{EDropShadowOn | EOutlineOn | ESetAntiAliasedGlyphBitmap | EVerticalDraw, KRgbGreen, KRgbBlack, KRgbBlue, KRgbWhite},
   171 	{EDropShadowOn | ESetAntiAliasedGlyphBitmap | EVerticalDraw | ERotate90Degrees, KRgbBlue, KRgbBlack, KRgbYellow},
   172 	{EDropShadowOn | ESetAntiAliasedGlyphBitmap | EVerticalDraw | ERotate90Degrees, KRgbBlue, KRgbBlack, KRgbYellow, KRgbWhite},
   172 	{EOutlineOn | ESetAntiAliasedGlyphBitmap | EVerticalDraw | ERotate90Degrees, KRgbBlue, KRgbBlack, KRgbYellow},
   173 	{EOutlineOn | ESetAntiAliasedGlyphBitmap | EVerticalDraw | ERotate90Degrees, KRgbBlue, KRgbBlack, KRgbYellow, KRgbWhite},
   173 	{EDropShadowOn | EOutlineOn | ESetAntiAliasedGlyphBitmap | EVerticalDraw | ERotate90Degrees, KRgbBlue, KRgbBlack, KRgbYellow},
   174 	{EDropShadowOn | EOutlineOn | ESetAntiAliasedGlyphBitmap | EVerticalDraw | ERotate90Degrees, KRgbBlue, KRgbBlack, KRgbYellow, KRgbWhite},
   174 	{EDropShadowOn | ESetAntiAliasedGlyphBitmap | EVerticalDraw, KRgbBlue, KRgbBlack, KRgbYellow},
   175 	{EDropShadowOn | ESetAntiAliasedGlyphBitmap | EVerticalDraw, KRgbBlue, KRgbBlack, KRgbYellow, KRgbWhite},
   175 	{EOutlineOn | ESetAntiAliasedGlyphBitmap | EVerticalDraw, KRgbBlue, KRgbBlack, KRgbYellow},
   176 	{EOutlineOn | ESetAntiAliasedGlyphBitmap | EVerticalDraw, KRgbBlue, KRgbBlack, KRgbYellow, KRgbWhite},
   176 	{EDropShadowOn | EOutlineOn | ESetAntiAliasedGlyphBitmap | EVerticalDraw, KRgbBlue, KRgbBlack, KRgbYellow},
   177 	{EDropShadowOn | EOutlineOn | ESetAntiAliasedGlyphBitmap | EVerticalDraw, KRgbBlue, KRgbBlack, KRgbYellow, KRgbWhite},
   177 	{EDropShadowOn | ESetAntiAliasedGlyphBitmap, KRgbGreen, KRgbBlack, KRgbBlue},
   178 	{EDropShadowOn | ESetAntiAliasedGlyphBitmap, KRgbGreen, KRgbBlack, KRgbBlue, KRgbWhite},
   178 	{EOutlineOn | ESetAntiAliasedGlyphBitmap, KRgbGreen, KRgbBlack, KRgbBlue},
   179 	{EOutlineOn | ESetAntiAliasedGlyphBitmap, KRgbGreen, KRgbBlack, KRgbBlue, KRgbWhite},
   179 	{EDropShadowOn |EOutlineOn | ESetAntiAliasedGlyphBitmap, KRgbGreen, KRgbBlack, KRgbBlue},
   180 	{EDropShadowOn |EOutlineOn | ESetAntiAliasedGlyphBitmap, KRgbGreen, KRgbBlack, KRgbBlue, KRgbWhite},
   180 	{EDropShadowOn | ESetAntiAliasedGlyphBitmap, KRgbBlue, KRgbGreen, KRgbYellow},
   181 	{EDropShadowOn | ESetAntiAliasedGlyphBitmap, KRgbBlue, KRgbGreen, KRgbYellow, KRgbWhite},
   181 	{EOutlineOn | ESetAntiAliasedGlyphBitmap, KRgbBlue, KRgbGreen, KRgbYellow},
   182 	{EOutlineOn | ESetAntiAliasedGlyphBitmap, KRgbBlue, KRgbGreen, KRgbYellow, KRgbWhite},
   182 	{EDropShadowOn | EOutlineOn | ESetAntiAliasedGlyphBitmap, KRgbBlue, KRgbGreen, KRgbYellow},
   183 	{EDropShadowOn | EOutlineOn | ESetAntiAliasedGlyphBitmap, KRgbBlue, KRgbGreen, KRgbYellow, KRgbWhite},
   183 	{ESetAntiAliasedGlyphBitmap, KRgbBlue, KRgbGreen, KRgbYellow},
   184 	{ESetAntiAliasedGlyphBitmap, KRgbBlue, KRgbGreen, KRgbYellow, KRgbWhite},
   184 	{ESetAntiAliasedGlyphBitmap | EVerticalDraw | ERotate90Degrees, KRgbBlue, KRgbGreen, KRgbYellow},
   185 	{ESetAntiAliasedGlyphBitmap | EVerticalDraw | ERotate90Degrees, KRgbBlue, KRgbGreen, KRgbYellow, KRgbWhite},
   185 	
   186 	
   186 	// test with EAntiAliasedGlyphBitmap and alpha value < 255 (transparency)
   187 	// test with EAntiAliasedGlyphBitmap and alpha value < 255 (transparency)
   187 	{EDropShadowOn | ESetAntiAliasedGlyphBitmap | EVerticalDraw | ERotate90Degrees, KRgbBlue, TRgb(128,255,100,0), KRgbMagenta},
   188 	{EDropShadowOn | ESetAntiAliasedGlyphBitmap | EVerticalDraw | ERotate90Degrees, KRgbBlue, TRgb(128,255,100,0), KRgbMagenta, KRgbWhite},
   188 	{EOutlineOn | ESetAntiAliasedGlyphBitmap, KRgbGreen, TRgb(128,200,100,32), KRgbYellow},
   189 	{EOutlineOn | ESetAntiAliasedGlyphBitmap, KRgbGreen, TRgb(128,200,100,32), KRgbYellow, KRgbWhite},
   189 	{EDropShadowOn | EOutlineOn | ESetAntiAliasedGlyphBitmap | EVerticalDraw, KRgbYellow, TRgb(100,200,100,64), KRgbGray},
   190 	{EDropShadowOn | EOutlineOn | ESetAntiAliasedGlyphBitmap | EVerticalDraw, KRgbYellow, TRgb(100,200,100,64), KRgbGray, KRgbWhite},
   190 	{EDropShadowOn | ESetAntiAliasedGlyphBitmap | EVerticalDraw | ERotate90Degrees, KRgbWhite, TRgb(128,200,50,128), KRgbYellow},
   191 	{EDropShadowOn | ESetAntiAliasedGlyphBitmap | EVerticalDraw | ERotate90Degrees, KRgbWhite, TRgb(128,200,50,128), KRgbYellow, KRgbWhite},
   191 	{EOutlineOn | ESetAntiAliasedGlyphBitmap, KRgbBlack, TRgb(12,20,50,255), KRgbWhite}
   192 	{EOutlineOn | ESetAntiAliasedGlyphBitmap, KRgbBlack, TRgb(12,20,50,255), KRgbWhite, KRgbWhite},
       
   193 	{EOutlineOn | ESetAntiAliasedGlyphBitmap, KRgbGreen, TRgb(255,0,0,127), KRgbYellow, TRgb(127, 127, 127, 0)}
   192 	};
   194 	};
   193 
   195 
   194 // Test setting for TestDrawTextWithStrikeThroughL() i.e. for test case 11
   196 // Test setting for TestDrawTextWithStrikeThroughL() i.e. for test case 11
   195 // All test case conditions are defined here and are called to test outline and shadow with strikethrough and underline effects.
   197 // All test case conditions are defined here and are called to test outline and shadow with strikethrough and underline effects.
   196 // STestFontParameters Format: outline | shadow | bitmaptype | strikethroughon | underlineon, BrushColor, PenColor, ShadowColor
   198 // STestFontParameters Format: outline | shadow | bitmaptype | strikethroughon | underlineon, BrushColor, PenColor, ShadowColor