Search
 
SCRIPT & CODE EXAMPLE
 

CSHARP

unity gui style color button

#if UNITY_EDITOR
	[CustomEditor(typeof(MyClass))]
	public class MyClassEditor : Editor
	{
		public override void OnInspectorGUI()
		{
			DrawDefaultInspector();

			var style = new GUIStyle(GUI.skin.button);

			style.normal.textColor = Color.red;

			MyClass c = (MyClass)target;

			if (GUILayout.Button("Button Name", style))
			{
				c.MyMethod();
			}
		}
	}
#endif
Comment

PREVIOUS NEXT
Code Example
Csharp :: linq query select where c# 
Csharp :: .net core identity get user id 
Csharp :: how to concatenate two arrays in c# 
Csharp :: pyautogui not odwnloading 
Csharp :: c# remove duplicates from list 
Csharp :: export list to excel c# 
Csharp :: And this is how can you deserialize your XML file in your C# code: 
Csharp :: Reverse Coding Challenge 1 
Csharp :: simple code to call rest api c# 
Csharp :: char array 
Csharp :: unity game object remove parent 
Csharp :: TimeZone in asp.net core 
Csharp :: meaning immutable and mutable 
Csharp :: Map Range Clamped unity 
Csharp :: c# yield 
Csharp :: asp .net core 3 mvc select with default value 
Csharp :: linq foreach c# 
Csharp :: if list does not contain then add c# 
Csharp :: c# convert string to uri 
Csharp :: C# domain name to ip address 
Csharp :: declare enum c# 
Csharp :: convert c# string to int 
Csharp :: c# method returns multiple values 
Csharp :: new list/array with values c# 
Csharp :: c# make a automapper 
Csharp :: get key in dictionary c# 
Csharp :: c# xmldocument from file 
Csharp :: c# console delete last character 
Csharp :: itext7 pdfwriter outputstream c# 
Csharp :: moq set delay to return 
ADD CONTENT
Topic
Content
Source link
Name
6+6 =