<commit_before>using UnityEngine;
using UnityEditor;
using RelationsInspector.Extensions;

namespace RelationsInspector.Backend
{
	public static class DrawUtil
	{
		public static float sqrt2 = Mathf.Sqrt(2f);
		public static Vector2 boxIconSize = new Vector2(16, 16);

		// draw the content in a rect or circle widget, depending on context
		public static Rect DrawContent(GUIContent content, EntityDrawContext context)
		{
			switch (context.widgetType)
			{
				case EntityWidgetType.Circle:
					return DrawCircleWidget(content, context);

				case EntityWidgetType.Rect:
				default:
					return DrawRectWidget(content, context);
			}
		}

        // draw content box background, outline and selection/unexplored aura
        public static void DrawBoxAndBackground(Rect contentRect, EntityDrawContext context )
        {
            Rect outlineRect = contentRect.AddBorder( 1 );

            // selected items get highlighted
            if ( context.isSelected )
            {
                var auraRect = outlineRect.AddBorder( context.style.highlightStrength );
                EditorGUI.DrawRect( auraRect, context.style.highlightColor );
            }
            else if ( context.isUnexlored )
            {
                var auraRect = outlineRect.AddBorder( context.style.highlightStrength );
                EditorGUI.DrawRect( auraRect, context.style.unexploredColor );
            }

            // draw outline rect
            EditorGUI.DrawRect( outlineRect, Color.black );

            // draw content rect
            EditorGUI.DrawRect( contentRect, context.isTarget ? context.style.targetBackgroundColor : context.style.backgroundColor );
        }

		// draw content in rect widget
		public static Rect DrawRectWidget(GUIContent content, EntityDrawContext context)
		{<commit_msg>added shadow to box widget<commit_after>using UnityEngine;
using UnityEditor;
using RelationsInspector.Extensions;

namespace RelationsInspector.Backend
{
	public static class DrawUtil
	{
		public static float sqrt2 = Mathf.Sqrt(2f);
		public static Vector2 boxIconSize = new Vector2(16, 16);
        static Vector2 shadowOffset = new Vector2( 2, 2);

		// draw the content in a rect or circle widget, depending on context
		public static Rect DrawContent(GUIContent content, EntityDrawContext context)
		{
			switch (context.widgetType)
			{
				case EntityWidgetType.Circle:
					return DrawCircleWidget(content, context);

				case EntityWidgetType.Rect:
				default:
					return DrawRectWidget(content, context);
			}
		}

        // draw content box background, outline and selection/unexplored aura
        public static void DrawBoxAndBackground(Rect contentRect, EntityDrawContext context )
        {
            Rect outlineRect = contentRect.AddBorder( 1 );

            // selected items get highlighted
            if ( context.isSelected )
            {
                var auraRect = outlineRect.AddBorder( context.style.highlightStrength );
                EditorGUI.DrawRect( auraRect, context.style.highlightColor );
            }
            else if ( context.isUnexlored )
            {
                var auraRect = outlineRect.AddBorder( context.style.highlightStrength );
                EditorGUI.DrawRect( auraRect, context.style.unexploredColor );
            }
            else
            {
                // draw shadow
                EditorGUI.DrawRect( outlineRect.Move( shadowOffset ), context.style.shadowColor );
            }

            // draw outline rect
            EditorGUI.DrawRect( outlineRect, Color.black );

            // draw content rect
            EditorGUI.DrawRect( contentRect, context.isTarget ? context.style.targetBackgroundColor : context.style.backgroundColor );
        }

		// draw content in rect widget
		public static Rect DrawRectWidget(GUIContent content, EntityDrawContext context)
		{
{'fraction_non_alphanumeric': 0.07113295395757889, 'fraction_numerical': 0.005690636316606311, 'mean_word_length': 2.4806480648064806, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3333818', 'n_tokens_mistral': 1064, 'n_tokens_neox': 949, 'n_words': 266}