Пример #1
0
		protected override void DrawPropertyLayout(GUIContent label)
		{
			BoxGUI.BeginBox(new Color(0, 0, 0, 0.15f));
			CallNextDrawer(label);

			BoxGUI.EndBox(Attribute.withBorders ? Color : (Color?) null);
		}
Пример #2
0
		protected override void DrawPropertyLayout(GUIContent label)
		{
			// float h = 0;
			// for (int i = 0; i < Property.Index; i++)
			// {
			// h += GOLDEN_RATIO;
			// while (h > 1) h -= 1;
			// }

			int hashCode = Property.ValueEntry.TypeOfValue.Name.GetHashCode();
			var h        = (float) ((hashCode + (double) int.MaxValue) / uint.MaxValue);
			_color   = Color.HSVToRGB(h, 0.95f, 0.75f);
			_color.a = 0.15f;
			BoxGUI.BeginBox(_color);
			CallNextDrawer(label);
			BoxGUI.EndBox();
		}