Jump to content

Recommended Posts

Hey, I have this button

class RscButton_1615: RscButton
		{
			idc = 1615;
			x = 0.224375 * safezoneW + safezoneX;
			y = 0.808 * safezoneH + safezoneY;
			w = 0.065625 * safezoneW;
			h = 0.042 * safezoneH;
		};

How can i set a pictur with ctrlSetText?

Share this post


Link to post
Share on other sites

You can't on a button. The trick is to make the button transparent and put a rsc picture under it.

  • Like 2
  • Thanks 1

Share this post


Link to post
Share on other sites

Thanks. How can I remove the Highlight when you move the mouse over the button ?

Share this post


Link to post
Share on other sites

I have no experience with this but I guess you have to show another picture on a mouse over event.

edit: sry i misread this. i thought u want to highlight something and not removing it.

Share this post


Link to post
Share on other sites

I mean removing the blackness when you move the mouse over the button

Share this post


Link to post
Share on other sites

You can define your rscButton like:

class RscButton
{
    access = 0;
    type = 1;
    text = "";
    colorText[] = {0, 0, 0, 0 };
    colorDisabled[] = {0, 0, 0, 0  };
    colorBackground[] = {0, 0, 0, 0 };
    colorBackgroundDisabled[] = {0, 0, 0, 0 };
    colorBackgroundActive[] = {0, 0, 0, 0 };
    colorFocused[] = {0, 0, 0, 0 };
    colorShadow[] = {0, 0, 0, 0 };
    colorBorder[] = {0, 0, 0, 0 };

.... and so on ... for button ...

};

 

In your case, I guess that's the colorBackgroundActive[] which must be customized like my example. (Sorry, I didn't make this kind of control for an age!)

  • Like 2
  • Thanks 1

Share this post


Link to post
Share on other sites
On 4/8/2019 at 1:01 AM, Mr H. said:

You can't on a button. The trick is to make the button transparent and put a rsc picture under it.

Or use a RscActivePicture/KeepAspect that can use ctrlSetText to set its picture, of which also behaves as a button.

  • Like 2

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now

×