[Typo3-dev] Feature Request: Enable coloring the shadow mask on gifbuilder/modify white halo on GB texts

Carlos Chiari (DE) ccho at dimension-e.net
Sat Nov 13 18:19:17 CET 2004


Hi List:

Sorry, but the bug tracker has an "open_base" restriction in effect, so it's
not working right now.

-----------------------------
This is a FEATURE REQUEST

Title: Enable coloring the shadow mask on gifbuilder

Description: Line  1268 on class.t3lib_stdgraphic.php hardcode the color of
the mask being used by the makeShadow( ) function to black background:

Line 1268:  ImageColorAllocate($blurTextImg, 0,0,0);		// black
background

When the page background is not solid, for example with background images,
an ugly white halo can be seen around the shadow, when the image has been
set to transparent background.

A fix could be to add a property to the gifbuilder Shadow  object, named,
for example "blurmaskcolor", that could be used via typoscript like this:

Typoscript SETUP: 
          
          myGifText.file.10.shadow {          
          ...
          blurmaskcolor =  blue
          ...
          }


The proposed modification is on class. t3lib_stdgraphic.php:

New Line 1268 and following: 
$blurmaskcolor=$this->convertColor($conf['blurmaskcolor']);

ImageColorAllocate($blurTextImg,$blurmaskcolor[0],$blurmaskcolor[1],$blurmas
kcolor[2]); 


We could then play with mask colors until a better colored halo is produced.

Seems that when this background color of the shadow's mask is set to a
complementary color of the perceived average color of the page background
image, the halo would not be noticed, allowing the nice shadow effect on
gifbuilder texts.

Right now I am extending the t3lib_stdgraphic class via XCLASS method,
anyway.

Thanks and best regards,

Carlos





More information about the TYPO3-dev mailing list