Example #1
0
 public static GUIStyle ContentOffset(this GUIStyle current, float x, float y, bool asCopy = true)
 {
     return(current.ContentOffset(new Vector2(x, y), asCopy));
 }
        //==============================================================================

        /**
         *	@brief	Set float x,y contentOffsets to GUIStyle and return it.
         *
         *	@param	style	If null then create new GUIStyle. Otherwise return direct it.
         *	@param	offsetx	contentOffsetx.
         *	@param	offsety	contentOffsety.
         *
         *	@return	Builded GUIStyle
         */
        //==============================================================================
        public static GUIStyle ContentOffset(this GUIStyle style, float offsetx = 0, float offsety = 0)
        {
            return(style.ContentOffset(new Vector2(offsetx, offsety)));
        }