Sie sind nicht angemeldet.

tommo77funk

Fortgeschrittener

  • »tommo77funk« ist der Autor dieses Themas

Beiträge: 159

Wohnort: London

Beruf: Photographer

  • Nachricht senden

1

Montag, 25. Mai 2009, 14:35

textstyle background alpha

Hi all,

I don't suppose there is a way to give the background in textstyle alpha without effecting the alpha of the text ? I have tried numerous things today, and the only solution I can come up with is to use the textfield.swf - but that would mean writing html="data:for all of my buttons" and an awful lot of code with specific background sizes to fit around differant text, basically an awful lot of work for quite a simple effect I'm trying to acheive. I wish I could use settings similar to glow effect, so like this backgroundcolor="0x000000,0.3,4,2"

I'd be very grateful for any advice,

Many thanks,

tom

2

Montag, 25. Mai 2009, 15:22

Hi,

thanks for this note, I will add a "backgroundalpha" parameter for the textstyles in the next release

about textfield usage - you can also create a textfield dynamically via an action,
this will reduce the code when a lot of attributes are the same,

for example - have a look at this xml:
http://krpano.com/examples/108b7/krpano.xml
http://krpano.com/examples/108b7/krpano.html

there all buttons are created via the "createbutton" action,

best regards,
Klaus

tommo77funk

Fortgeschrittener

  • »tommo77funk« ist der Autor dieses Themas

Beiträge: 159

Wohnort: London

Beruf: Photographer

  • Nachricht senden

3

Dienstag, 26. Mai 2009, 00:11

Great, thanks Klaus ! I'll give it a try.... the link you gave is a treasure trove of examples :)

Many thanks,

tom

4

Freitag, 4. September 2009, 15:16

Hi,
I tried to set a alpha < 1 in a textstyle but it still displays it as a full color. My style looks like this:

Quellcode

1
2
<textstyle name="RED" font="Arial" fontsize="12" bold="false" italic="false" background="true" backgroundcolor="0xFF0000" border="true"
       	bordercolor="0xFF0000" textcolor="0xFFFFFF" alpha="0.8"  blendmode="normal"   />


Text-color and background-color are correct, but it doesn't have an alpha. When I change background to false the whole background disappears.
I'm using the latest beta

Graydon

Profi

Beiträge: 614

Wohnort: Texas

Beruf: Industrial gas turbine services.

  • Nachricht senden

5

Freitag, 11. September 2009, 07:13

The difference between 0.8 and 1.0 in alpha is really very little.

The "alpha" parameter is applied to both the text and the background... and I didn't see in the release notes where a backgroundalpha was implemented (but I actually have not tried just using it).

Try changing your alpha to 0.5 or less to see the effect and if it's working.

You can play around with this sample as well... http://www.krpano.com/examples/textstyles/ ... it's using the 1.0.7 stable release though.

Graydon