w7sH Posted May 25, 2017 Posted May 25, 2017 السلام عليكم هذا الكود يحط بدال الزر صورة ويحط التكست حق الزر عليها لكن وش المشكلة هنا function guiCreateButton( x2, y2, width2, height2, titleBarText2, relative2 ) local mainBackground = guiCreateStaticImage ( x2, y2, width2, height2, "r.png", relative2 ) return mainBackground end
Master_MTA Posted May 25, 2017 Posted May 25, 2017 2 minutes ago, w7sH said: السلام عليكم هذا الكود يحط بدال الزر صورة ويحط التكست حق الزر عليها لكن وش المشكلة هنا function guiCreateButton( x2, y2, width2, height2, titleBarText2, relative2 ) local mainBackground = guiCreateStaticImage ( x2, y2, width2, height2, "r.png", relative2 ) return mainBackground end وين التكست اللي بيحطه guiCreateLable? وينها
w7sH Posted May 25, 2017 Author Posted May 25, 2017 5 minutes ago, w7sH said: function guiCreateButton( x2, y2, width2, height2, titleBarText2, relative2 ) local mainBackground = guiCreateStaticImage ( x2, y2, width2, height2, "r.png", relative2 ) mainBackgroundLabel = guiCreateLabel ( 226, 5, 100, 19, titleBarText2, false, mainBackground ) guiSetFont ( mainBackgroundLabel, "default-bold-small" ) guiLabelSetColor( mainBackgroundLabel, 255, 255, 255) guiSetEnabled ( mainBackgroundLabel, false ) return mainBackground end
Kara Posted May 25, 2017 Posted May 25, 2017 function guiCreateButton(x2,y2,width2,height2,text,relative2,titleBarText2) local mainBackground = guiCreateStaticImage(x2,y2,width2,height2,"r.png",relative2,titleBarText2) local mainBackgroundLabel = guiCreateLabel(0,0,relative2 and 1 or width2,relative2 and 1 or height2,tostring(text),relative2,mainBackground) guiLabelSetColor( mainBackgroundLabel, 255, 255, 255) guiSetFont ( mainBackgroundLabel, "default-bold-small" ) return mainBackgroundLabel end
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now