Author Topic: Using Buttons  (Read 1354 times)

badbeat

  • Full Member
  • ***
  • Posts: 114
    • View Profile
Using Buttons
« on: June 26, 2008, 05:48:43 AM »
Hi, I've tried using buttons on my templates and all was ok until I tried to use my own images. The buttons work ok and images are there, but there's a grey box around the image. Am I doing something wrong, or is it always like that? (I have used transparency around the image.)

Any help would be great, thanks.

Corey Cooper

  • Administrator
  • Hero Member
  • *****
  • Posts: 6220
    • View Profile
Re: Using Buttons
« Reply #1 on: June 26, 2008, 01:55:23 PM »
That's the way it is.  The image has been superimposed on an actual button.  At least, that's what I think is happening.

There's an attribute that is implemented for the <tdbutton> token, that I inadvertently omitted from the descriptor file, so if you use the "Insert Token" dialog from the Cell Dialog, you won't see an option for using a "link" instead of a button.  Sound confusing?  Does to me, too.

OK, your <tdbutton> token probably looks similar to this:

<tdbutton type="nextround" image="C:\Program Files\The Tournament Director 2\images\right-arrow.jpg">

Insert the "link" attribute like this:

<tdbutton type="nextround" image="C:\Program Files\The Tournament Director 2\images\right-arrow.jpg" link="true">

This will make it behave like a link instead of a button, and should remove the "gray" around the image.  Of course, this also removes the "push" effect of a button, but that may not matter to you.

Alternatively, if you want to keep the "push" effect, you can change the styles of the button to remove the gray:

<tdbutton type="nextround" image="C:\Program Files\The Tournament Director 2\images\right-arrow.jpg" style="border: none; background: transparent">

badbeat

  • Full Member
  • ***
  • Posts: 114
    • View Profile
Re: Using Buttons
« Reply #2 on: June 26, 2008, 02:46:43 PM »
Cheers Corey, works a treat.
« Last Edit: June 27, 2008, 09:00:42 AM by badbeat »